idnits 2.17.1
draft-ietf-rats-yang-tpm-charra-11.txt:
Checking boilerplate required by RFC 5378 and the IETF Trust (see
https://trustee.ietf.org/license-info):
----------------------------------------------------------------------------
No issues found here.
Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt:
----------------------------------------------------------------------------
No issues found here.
Checking nits according to https://www.ietf.org/id-info/checklist :
----------------------------------------------------------------------------
** There are 60 instances of too long lines in the document, the longest
one being 3 characters in excess of 72.
Miscellaneous warnings:
----------------------------------------------------------------------------
== The copyright year in the IETF Trust and authors Copyright Line does not
match the current year
== Line 183 has weird spacing: '...te-name cer...'
== Line 212 has weird spacing: '...r-index pcr...'
== Line 296 has weird spacing: '...-number uin...'
== Line 355 has weird spacing: '...version ide...'
== Line 359 has weird spacing: '...sh-algo ide...'
-- The document date (26 August 2021) is 971 days in the past. Is this
intentional?
Checking references for intended status: Proposed Standard
----------------------------------------------------------------------------
(See RFCs 3967 and 4897 for information about using normative references
to lower-maturity documents in RFCs)
== Outdated reference: A later version (-35) exists of
draft-ietf-netconf-keystore-22
== Outdated reference: A later version (-22) exists of
draft-ietf-rats-architecture-12
** Downref: Normative reference to an Informational draft:
draft-ietf-rats-architecture (ref. 'I-D.ietf-rats-architecture')
== Outdated reference: A later version (-14) exists of
draft-ietf-rats-tpm-based-network-device-attest-08
** Downref: Normative reference to an Informational draft:
draft-ietf-rats-tpm-based-network-device-attest (ref.
'I-D.ietf-rats-tpm-based-network-device-attest')
-- Possible downref: Non-RFC (?) normative reference: ref. 'TCG-Algos'
== Outdated reference: A later version (-09) exists of
draft-ietf-rats-reference-interaction-models-04
Summary: 3 errors (**), 0 flaws (~~), 10 warnings (==), 2 comments (--).
Run idnits with the --verbose option for more detailed information about
the items above.
--------------------------------------------------------------------------------
2 RATS Working Group H. Birkholz
3 Internet-Draft M. Eckel
4 Intended status: Standards Track Fraunhofer SIT
5 Expires: 27 February 2022 S. Bhandari
6 ThoughtSpot
7 E. Voit
8 B. Sulzen
9 Cisco
10 L. Xia
11 Huawei
12 T. Laffey
13 HPE
14 G. Fedorkow
15 Juniper
16 26 August 2021
18 A YANG Data Model for Challenge-Response-based Remote Attestation
19 Procedures using TPMs
20 draft-ietf-rats-yang-tpm-charra-11
22 Abstract
24 This document defines YANG RPCs and a small number of configuration
25 nodes required to retrieve attestation evidence about integrity
26 measurements from a device, following the operational context defined
27 in TPM-based Network Device Remote Integrity Verification.
28 Complementary measurement logs are also provided by the YANG RPCs,
29 originating from one or more roots of trust for measurement (RTMs).
30 The module defined requires at least one TPM 1.2 or TPM 2.0 as well
31 as a corresponding TPM Software Stack (TSS), included in the device
32 components of the composite device the YANG server is running on.
34 Status of This Memo
36 This Internet-Draft is submitted in full conformance with the
37 provisions of BCP 78 and BCP 79.
39 Internet-Drafts are working documents of the Internet Engineering
40 Task Force (IETF). Note that other groups may also distribute
41 working documents as Internet-Drafts. The list of current Internet-
42 Drafts is at https://datatracker.ietf.org/drafts/current/.
44 Internet-Drafts are draft documents valid for a maximum of six months
45 and may be updated, replaced, or obsoleted by other documents at any
46 time. It is inappropriate to use Internet-Drafts as reference
47 material or to cite them other than as "work in progress."
48 This Internet-Draft will expire on 27 February 2022.
50 Copyright Notice
52 Copyright (c) 2021 IETF Trust and the persons identified as the
53 document authors. All rights reserved.
55 This document is subject to BCP 78 and the IETF Trust's Legal
56 Provisions Relating to IETF Documents (https://trustee.ietf.org/
57 license-info) in effect on the date of publication of this document.
58 Please review these documents carefully, as they describe your rights
59 and restrictions with respect to this document. Code Components
60 extracted from this document must include Simplified BSD License text
61 as described in Section 4.e of the Trust Legal Provisions and are
62 provided without warranty as described in the Simplified BSD License.
64 Table of Contents
66 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
67 1.1. Requirements notation . . . . . . . . . . . . . . . . . . 3
68 2. The YANG Module for Basic Remote Attestation Procedures . . . 4
69 2.1. YANG Modules . . . . . . . . . . . . . . . . . . . . . . 4
70 2.1.1. 'ietf-tpm-remote-attestation' . . . . . . . . . . . . 4
71 2.1.2. 'ietf-tcg-algs' . . . . . . . . . . . . . . . . . . . 33
72 3. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 48
73 4. Security Considerations . . . . . . . . . . . . . . . . . . . 49
74 5. Change Log . . . . . . . . . . . . . . . . . . . . . . . . . 50
75 6. References . . . . . . . . . . . . . . . . . . . . . . . . . 51
76 6.1. Normative References . . . . . . . . . . . . . . . . . . 51
77 6.2. Informative References . . . . . . . . . . . . . . . . . 53
78 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 53
80 1. Introduction
82 This document is based on the general terminology defined in the
83 [I-D.ietf-rats-architecture] and uses the operational context defined
84 in [I-D.ietf-rats-tpm-based-network-device-attest] as well as the
85 interaction model and information elements defined in
86 [I-D.ietf-rats-reference-interaction-models]. The currently
87 supported hardware security modules (HSMs) are the Trusted Platform
88 Modules (TPMs) [TPM1.2] and [TPM2.0] as specified by the Trusted
89 Computing Group (TCG). One or more TPMs embedded in the components
90 of a Composite Device are required in order to use the YANG module
91 defined in this document. A TPM is used as a root of trust for
92 reporting (RTR) in order to retrieve attestation Evidence from a
93 composite device (_TPM Quote_ primitive operation). Additionally, it
94 is used as a root of trust for storage (RTS) in order to retain
95 shielded secrets and store system measurements using a folding hash
96 function (_TPM PCR Extend_ primitive operation).
98 Specific terms imported from [I-D.ietf-rats-architecture] and used in
99 this document include: Attester, Composite Device, Evidence.
101 Specific terms imported from [TPM2.0-Key] and used in this document
102 include: Endorsement Key (EK), Initial Attestation Key (IAK), Local
103 Attestation Key (LAK).
105 1.1. Requirements notation
107 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
108 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
109 "OPTIONAL" in this document are to be interpreted as described in
110 BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all
111 capitals, as shown here.
113 2. The YANG Module for Basic Remote Attestation Procedures
115 One or more TPMs MUST be embedded in a Composite Device that provides
116 attestation evidence via the YANG module defined in this document.
117 The ietf-basic-remote-attestation YANG module enables a composite
118 device to take on the role of an Attester, in accordance with the
119 Remote Attestation Procedures (RATS) architecture
120 [I-D.ietf-rats-architecture], and the corresponding challenge-
121 response interaction model defined in the
122 [I-D.ietf-rats-reference-interaction-models] document. A fresh nonce
123 with an appropriate amount of entropy MUST be supplied by the YANG
124 client in order to enable a proof-of-freshness with respect to the
125 attestation Evidence provided by the Attester running the YANG
126 datastore. Further, this nonce is used to prevent replay attacks.
127 The functions of this YANG module are restricted to 0-1 TPMs per
128 hardware component.
130 2.1. YANG Modules
132 In this section the several YANG modules are defined.
134 2.1.1. 'ietf-tpm-remote-attestation'
136 This YANG module imports modules from [RFC6991], [RFC8348],
137 [I-D.ietf-netconf-keystore], and "ietf-tcg-algs.yang"
138 Section 2.1.2.3.
140 2.1.1.1. Features
142 This module supports the following features:
144 * 'TPMs': Indicates that multiple TPMs on the device can support
145 remote attestation. This feature is applicable in cases where
146 multiple line cards are present, each with its own TPM.
148 * 'bios': Indicates that the device supports the retrieval of BIOS/
149 UEFI event logs.
151 * 'ima': Indicates that the device supports the retrieval of event
152 logs from the Linux Integrity Measurement Architecture (IMA).
154 * 'netequip_boot': Indicates that the device supports the retrieval
155 of netequip boot event logs.
157 2.1.1.2. Identities
159 This module supports the following types of attestation event logs:
160 'bios', 'ima', and 'netequip_boot'.
162 2.1.1.3. Remote Procedure Calls (RPCs)
164 In the following, RPCs for both TPM 1.2 and TPM 2.0 attestation
165 procedures are defined.
167 2.1.1.3.1. 'tpm12-challenge-response-attestation'
169 This RPC allows a Verifier to request signed TPM PCRs (_TPM Quote_
170 operation) from a TPM 1.2 compliant cryptoprocessor. Where the
171 feature 'TPMs' is active, and one or more 'certificate-name' is not
172 provided, all TPM 1.2 compliant cryptoprocessors will respond. A
173 YANG tree diagram of this RPC is as follows:
175 +---x tpm12-challenge-response-attestation {taa:TPM12}?
176 +---w input
177 | +---w tpm12-attestation-challenge
178 | +---w pcr-index* pcr
179 | +---w nonce-value binary
180 | +---w certificate-name* certificate-name-ref {tpm:TPMs}?
181 +--ro output
182 +--ro tpm12-attestation-response* []
183 +--ro certificate-name certificate-name-ref
184 +--ro up-time? uint32
185 +--ro TPM_QUOTE2? binary
187 2.1.1.3.2. 'tpm20-challenge-response-attestation'
189 This RPC allows a Verifier to request signed TPM PCRs (_TPM Quote_
190 operation) from a TPM 2.0 compliant cryptoprocessor. Where the
191 feature 'TPMs' is active, and one or more 'certificate-name' is not
192 provided, all TPM 2.0 compliant cryptoprocessors will respond. A
193 YANG tree diagram of this RPC is as follows:
195 +---x tpm20-challenge-response-attestation {taa:tpm}?
196 +---w input
197 | +---w tpm20-attestation-challenge
198 | +---w nonce-value binary
199 | +---w tpm20-pcr-selection* []
200 | | +---w TPM20-hash-algo? identityref
201 | | +---w pcr-index* tpm:pcr
202 | +---w certificate-name* certificate-name-ref {tpm:TPMs}?
203 +--ro output
204 +--ro tpm20-attestation-response* []
205 +--ro certificate-name certificate-name-ref
206 +--ro TPMS_QUOTE_INFO binary
207 +--ro quote-signature? binary
208 +--ro up-time? uint32
209 +--ro unsigned-pcr-values* []
210 +--ro TPM20-hash-algo? identityref
211 +--ro pcr-values* [pcr-index]
212 +--ro pcr-index pcr
213 +--ro pcr-value? binary
215 An example of an RPC challenge requesting PCRs 0-7 from a SHA-256
216 bank could look like the following:
218
219
220 xmlns="urn:ietf:params:xml:ns:yang:ietf-tpm-remote-attestation">
221
222 (identifier of a TPM signature key with which the Verifier is
223 supposed to sign the attestation data)
224
225
226 0xe041307208d9f78f5b1bbecd19e2d152ad49de2fc5a7d8dbf769f6b8ffdeab9
227
228
229
231 taa:TPM_ALG_SHA256
232
233 0
234 1
235 2
236 3
237 4
238 5
239 6
240 7
241
242
243
245 A successful response could be formatted as follows:
247
249
251
253 ks:(instance of Certificate name in the Keystore)
254
255
256 (raw attestation data, i.e. the TPM quote; this includes
257 a composite digest of requested PCRs, the nonce,
258 and TPM 2.0 time information.)
259
260
261 (signature over attestation-data using the TPM key
262 identified by sig-key-id)
263
264
265
267 2.1.1.4. 'log-retrieval'
269 This RPC allows a Verifier to acquire the evidence which was extended
270 into specific TPM PCRs. A YANG tree diagram of this RPC is as
271 follows:
273 +---x log-retrieval
274 +---w input
275 | +---w log-selector* []
276 | | +---w name* string
277 | | +---w (index-type)?
278 | | | +--:(last-entry)
279 | | | | +---w last-entry-value? binary
280 | | | +--:(index)
281 | | | | +---w last-index-number? uint64
282 | | | +--:(timestamp)
283 | | | +---w timestamp? yang:date-and-time
284 | | +---w log-entry-quantity? uint16
285 | +---w log-type identityref
286 +--ro output
287 +--ro system-event-logs
288 +--ro node-data* []
289 +--ro name? string
290 +--ro up-time? uint32
291 +--ro log-result
292 +--ro (attested_event_log_type)
293 +--:(bios) {bios}?
294 | +--ro bios-event-logs
295 | +--ro bios-event-entry* [event-number]
296 | +--ro event-number uint32
297 | +--ro event-type? uint32
298 | +--ro pcr-index? pcr
299 | +--ro digest-list* []
300 | | +--ro hash-algo? identityref
301 | | +--ro digest* binary
302 | +--ro event-size? uint32
303 | +--ro event-data* uint8
304 +--:(ima) {ima}?
305 | +--ro ima-event-logs
306 | +--ro ima-event-entry* [event-number]
307 | +--ro event-number uint64
308 | +--ro ima-template? string
309 | +--ro filename-hint? string
310 | +--ro filedata-hash? binary
311 | +--ro filedata-hash-algorithm? string
312 | +--ro template-hash-algorithm? string
313 | +--ro template-hash? binary
314 | +--ro pcr-index? pcr
315 | +--ro signature? binary
316 +--:(netequip_boot) {netequip_boot}?
317 +--ro boot-event-logs
318 +--ro boot-event-entry* [event-number]
319 +--ro event-number uint64
320 +--ro ima-template? string
321 +--ro filename-hint? string
322 +--ro filedata-hash? binary
323 +--ro filedata-hash-algorithm? string
324 +--ro template-hash-algorithm? string
325 +--ro template-hash? binary
326 +--ro pcr-index? pcr
327 +--ro signature? binary
329 2.1.1.5. Data Nodes
331 This section provides a high level description of the data nodes
332 containing the configuration and operational objects with the YANG
333 model. For more details, please see the YANG model itself in
334 Figure 1.
336 Container 'rats-support-structures': This houses the set of
337 information relating to a device's TPM(s).
339 Container 'tpms': Provides configuration and operational details for
340 each supported TPM, including the tpm-firmware-version, PCRs which
341 may be quoted, certificates which are associated with that TPM,
342 and the current operational status. Of note are the certificates
343 which are associated with that TPM. As a certificate is
344 associated with a particular TPM attestation key, knowledge of the
345 certificate allows a specific TPM to be identified.
347 +--rw tpms
348 +--rw tpm* [name]
349 +--rw name string
350 +--ro hardware-based? boolean
351 +--ro physical-index? int32 {ietfhw:entity-mib}?
352 +--ro path? string
353 +--ro compute-node compute-node-ref {tpm:tpms}?
354 +--ro manufacturer? string
355 +--rw firmware-version identityref
356 +--rw tpm12-hash-algo? identityref
357 +--rw tpm12-pcrs* pcr
358 +--rw tpm20-pcr-bank* [tpm20-hash-algo]
359 | +--rw tpm20-hash-algo identityref
360 | +--rw pcr-index* tpm:pcr
361 +--ro status enumeration
362 +--rw certificates
363 +--rw certificate* [name]
364 +--rw name string
365 +--rw keystore-ref? leafref
366 +--rw type? enumeration
368 container 'attester-supported-algos' - Identifies which TCG hash
369 algorithms are available for use on the Attesting platform. This
370 allows an operator to limit algorithms available for use by RPCs to
371 just a desired set from the universe of all allowed hash algorithms
372 by the TCG.
374 +--rw attester-supported-algos
375 +--rw tpm12-asymmetric-signing* identityref
376 +--rw tpm12-hash* identityref
377 +--rw tpm20-asymmetric-signing* identityref
378 +--rw tpm20-hash* identityref
380 container 'compute-nodes' - When there is more than one TPM
381 supported, this container maintains the set of information related to
382 the compute node associated with a specific TPM. This allows each
383 specific TPM to identify to which 'compute-node' it belongs.
385 +--rw compute-nodes {tpm:TPMs}?
386 +--ro compute-node* [node-id]
387 +--ro node-id string
388 +--ro node-physical-index? int32 {ietfhw:entity-mib}?
389 +--ro node-name? string
390 +--ro node-location? string
392 2.1.1.6. YANG Module
393 file "ietf-tpm-remote-attestation@2021-05-11.yang"
394 module ietf-tpm-remote-attestation {
395 namespace "urn:ietf:params:xml:ns:yang:ietf-tpm-remote-attestation";
396 prefix tpm;
398 import ietf-yang-types {
399 prefix yang;
400 }
401 import ietf-hardware {
402 prefix ietfhw;
403 }
404 import ietf-keystore {
405 prefix ks;
406 }
407 import ietf-tcg-algs {
408 prefix taa;
409 }
411 organization
412 "IETF RATS (Remote ATtestation procedureS) Working Group";
413 contact
414 "WG Web :
415 WG List :
416 Author : Eric Voit
417 Author : Henk Birkholz
418 Author : Michael Eckel
419 Author : Shwetha Bhandari
420 Author : Bill Sulzen
421 Author : Liang Xia (Frank)
422 Author : Tom Laffey
423 Author : Guy Fedorkow ";
424 description
425 "A YANG module to enable a TPM 1.2 and TPM 2.0 based
426 remote attestation procedure using a challenge-response
427 interaction model and the TPM 1.2 and TPM 2.0 Quote
428 primitive operations.
429 Copyright (c) 2021 IETF Trust and the persons identified
430 as authors of the code. All rights reserved.
431 Redistribution and use in source and binary forms, with
432 or without modification, is permitted pursuant to, and
433 subject to the license terms contained in, the Simplified
434 BSD License set forth in Section 4.c of the IETF Trust's
435 Legal Provisions Relating to IETF Documents
436 (https://trustee.ietf.org/license-info).
437 This version of this YANG module is part of RFC XXXX
438 (https://www.rfc-editor.org/info/rfcXXXX); see the RFC
439 itself for full legal notices.
441 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL',
442 'SHALL NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED',
443 'NOT RECOMMENDED', 'MAY', and 'OPTIONAL' in this document
444 are to be interpreted as described in BCP 14 (RFC 2119)
445 (RFC 8174) when, and only when, they appear in all
446 capitals, as shown here.";
448 revision 2021-08-11 {
449 description
450 "Initial version";
451 reference
452 "draft-ietf-rats-yang-tpm-charra";
453 }
455 /*****************/
456 /* Features */
457 /*****************/
459 feature tpms {
460 description
461 "The device supports the remote attestation of multiple
462 TPM based cryptoprocessors.";
463 }
465 feature bios {
466 description
467 "The device supports the bios logs.";
468 reference
469 "https://trustedcomputinggroup.org/wp-content/uploads/
470 PC-ClientSpecific_Platform_Profile_for_TPM_2p0_Systems_v51.pdf
471 Section 9.4.5.2";
472 }
474 feature ima {
475 description
476 "The device supports Integrity Measurement Architecture logs.";
477 reference
478 "https://www.trustedcomputinggroup.org/wp-content/uploads/
479 TCG_IWG_CEL_v1_r0p30_13feb2021.pdf Section 4.3";
480 }
482 feature netequip_boot {
483 description
484 "The device supports the netequip_boot logs.";
485 }
487 /*****************/
488 /* Typedefs */
489 /*****************/
491 typedef pcr {
492 type uint8 {
493 range "0..31";
494 }
495 description
496 "Valid index number for a PCR. At this point 0-31 is viable.";
497 }
499 typedef compute-node-ref {
500 type leafref {
501 path "/tpm:rats-support-structures/tpm:compute-nodes"
502 + "/tpm:compute-node/tpm:node-name";
503 }
504 description
505 "This type is used to reference a hardware node. It is quite
506 possible this leafref will eventually point to another YANG
507 module's node.";
508 }
510 typedef certificate-name-ref {
511 type leafref {
512 path "/tpm:rats-support-structures/tpm:tpms/tpm:tpm"
513 + "/tpm:certificates/tpm:certificate/tpm:name";
514 }
515 description
516 "A type which allows identification of a TPM based certificate.";
517 }
519 /******************/
520 /* Identities */
521 /******************/
523 identity attested_event_log_type {
524 description
525 "Base identity allowing categorization of the reasons why and
526 attested measurement has been taken on an Attester.";
527 }
529 identity ima {
530 base attested_event_log_type;
531 description
532 "An event type recorded in IMA.";
533 }
535 identity bios {
536 base attested_event_log_type;
537 description
538 "An event type associated with BIOS/UEFI.";
539 }
541 identity netequip_boot {
542 base attested_event_log_type;
543 description
544 "An event type associated with Network Equipment Boot.";
545 }
547 /*****************/
548 /* Groupings */
549 /*****************/
551 grouping tpm20-hash-algo {
552 description
553 "The cryptographic algorithm used to hash the TPM2 PCRs. This
554 must be from the list of platform supported options.";
555 leaf tpm20-hash-algo {
556 type identityref {
557 base taa:hash;
558 }
559 must '/tpm:rats-support-structures/tpm:attester-supported-algos'
560 + '/tpm:tpm20-hash' {
561 error-message "This platform does not support tpm20-hash-algo";
562 }
563 default "taa:TPM_ALG_SHA256";
564 description
565 "The hash scheme that is used to hash a TPM1.2 PCR. This
566 must be one of those supported by a platform.";
567 }
568 }
570 grouping tpm12-hash-algo {
571 description
572 "The cryptographic algorithm used to hash the TPM1.2 PCRs.";
573 leaf tpm12-hash-algo {
574 type identityref {
575 base taa:hash;
576 }
577 must '/tpm:rats-support-structures/tpm:attester-supported-algos'
578 + '/tpm:tpm12-hash' {
579 error-message "This platform does not support tpm12-hash-algo";
580 }
581 default "taa:TPM_ALG_SHA1";
582 description
583 "The hash scheme that is used to hash a TPM1.2 PCR. This
584 MUST be one of those supported by a platform. This assumes
585 that an algorithm other than SHA1 can be supported on some
586 TPM1.2 cryptoprocessor variant.";
587 }
588 }
590 grouping nonce {
591 description
592 "A random number intended to be used once to show freshness
593 and to allow the detection of replay attacks.";
594 leaf nonce-value {
595 type binary;
596 mandatory true;
597 description
598 "A cryptographically generated random number which should
599 not be predictable prior to its issuance from a random
600 number generation function. The random number MUST be
601 derived from an entropy source external to the Attester.";
602 }
603 }
605 grouping tpm12-pcr-selection {
606 description
607 "A Verifier can request one or more PCR values using its
608 individually created Attestation Key Certificate (AC).
609 The corresponding selection filter is represented in this
610 grouping.
611 Requesting a PCR value that is not in scope of the AC used,
612 detailed exposure via error msg should be avoided.";
613 leaf-list pcr-index {
614 type pcr;
615 description
616 "The numbers/indexes of the PCRs. At the moment this is limited
617 to 32. In addition, any selection of PCRs MUST verify that
618 the set of PCRs requested are a subset the set of PCRs
619 exposed by in the leaf-list /tpm:rats-support-structures
620 /tpm:tpms/tpm:tpm[name=current()]/tpm:tpm12-pcrs";
621 }
622 }
624 grouping tpm20-pcr-selection {
625 description
626 "A Verifier can acquire one or more PCR values, which are hashed
627 together in a TPM2B_DIGEST coming from the TPM2. The selection
628 list of desired PCRs and the Hash Algorithm is represented in
629 this grouping.";
630 list tpm20-pcr-selection {
631 unique "tpm20-hash-algo";
632 description
633 "Specifies the list of PCRs and Hash Algorithms that can be
634 returned within a TPM2B_DIGEST.";
635 reference
636 "https://www.trustedcomputinggroup.org/wp-content/uploads/
637 TPM-Rev-2.0-Part-2-Structures-01.38.pdf Section 10.9.7";
638 uses tpm20-hash-algo;
639 leaf-list pcr-index {
640 type pcr;
641 must '/tpm:rats-support-structures/tpm:tpms'
642 + '/tpm:tpm[name = current()] and '
643 + '/tpm:rats-support-structures/tpm:tpms/tpm:tpm'
644 + '/tpm:tpm20-pcr-bank[pcr-index = current()]' {
645 error-message "Acquiring this PCR index is not supported";
646 }
647 description
648 "The numbers of the PCRs that which are being tracked
649 with a hash based on the tpm20-hash-algo. In addition,
650 any selection of PCRs MUST verify that the set of PCRs
651 requested are a subset the set of PCR indexes exposed
652 within /tpm:rats-support-structures/tpm:tpms
653 /tpm:tpm[name=current()]/tpm:tpm20-pcr-bank
654 /tpm:pcr-index";
655 }
656 }
657 }
659 grouping certificate-name-ref {
660 description
661 "Identifies a certificate in a keystore.";
662 leaf certificate-name {
663 type certificate-name-ref;
664 mandatory true;
665 description
666 "Identifies a certificate in a keystore.";
667 }
668 }
670 grouping tpm-name {
671 description
672 "A unique TPM on a device.";
673 leaf name {
674 type string;
675 description
676 "Unique system generated name for a TPM on a device.";
677 }
678 }
680 grouping tpm-name-selector {
681 description
682 "One or more TPM on a device.";
683 leaf-list name {
684 type string;
685 config false;
686 description
687 "Name of one or more unique TPMs on a device. If this object
688 exists, a selection should pull only the objects related to
689 these TPM(s). If it does not exist, all qualifying TPMs that
690 are 'hardware-based' equals true on the device are selected.";
691 }
692 }
694 grouping node-uptime {
695 description
696 "Uptime in seconds of the node.";
697 leaf up-time {
698 type uint32;
699 description
700 "Uptime in seconds of this node reporting its data";
701 }
702 }
704 grouping tpm12-attestation {
705 description
706 "Contains an instance of TPM1.2 style signed cryptoprocessor
707 measurements. It is supplemented by unsigned Attester
708 information.";
709 uses node-uptime;
710 leaf TPM_QUOTE2 {
711 type binary;
712 description
713 "Result of a TPM1.2 Quote2 operation. This includes PCRs,
714 signatures, locality, the provided nonce and other data which
715 can be further parsed to appraise the Attester.";
716 reference
717 "TPM1.2 commands rev116 July 2007, Section 16.5";
718 }
719 }
721 grouping tpm20-attestation {
722 description
723 "Contains an instance of TPM2 style signed cryptoprocessor
724 measurements. It is supplemented by unsigned Attester
725 information.";
726 leaf TPMS_QUOTE_INFO {
727 type binary;
728 mandatory true;
729 description
730 "A hash of the latest PCR values (and the hash algorithm used)
731 which have been returned from a Verifier for the selected PCRs
732 and Hash Algorithms.";
733 reference
734 "https://www.trustedcomputinggroup.org/wp-content/uploads/
735 TPM-Rev-2.0-Part-2-Structures-01.38.pdf Section 10.12.1";
736 }
737 leaf quote-signature {
738 type binary;
739 description
740 "Quote signature returned by TPM Quote. The signature was
741 generated using the key associated with the
742 certificate 'name'.";
743 reference
744 "https://www.trustedcomputinggroup.org/wp-content/uploads/
745 TPM-Rev-2.0-Part-2-Structures-01.38.pdf Section 11.2.1";
746 }
747 uses node-uptime;
748 list unsigned-pcr-values {
749 description
750 "PCR values in each PCR bank. This might appear redundant with
751 the TPM2B_DIGEST, but that digest is calculated across multiple
752 PCRs. Having to verify across multiple PCRs does not
753 necessarily make it easy for a Verifier to appraise just the
754 minimum set of PCR information which has changed since the last
755 received TPM2B_DIGEST. Put another way, why should a Verifier
756 reconstruct the proper value of all PCR Quotes when only a
757 single PCR has changed?
758 To help this happen, if the Attester does know specific PCR
759 values, the Attester can provide these individual values via
760 'unsigned-pcr-values'. By comparing this information to the
761 what has previously been validated, it is possible for a
762 Verifier to confirm the Attester's signature while eliminating
763 significant processing.";
764 uses tpm20-hash-algo;
765 list pcr-values {
766 key "pcr-index";
767 description
768 "List of one PCR bank.";
769 leaf pcr-index {
770 type pcr;
771 description
772 "PCR index number.";
773 }
774 leaf pcr-value {
775 type binary;
776 description
777 "PCR value.";
778 reference
779 "https://www.trustedcomputinggroup.org/wp-content/uploads/
780 TPM-Rev-2.0-Part-2-Structures-01.38.pdf Section 10.9.7";
781 }
782 }
783 }
784 }
786 grouping log-identifier {
787 description
788 "Identifier for type of log to be retrieved.";
789 leaf log-type {
790 type identityref {
791 base attested_event_log_type;
792 }
793 mandatory true;
794 description
795 "The corresponding measurement log type identity.";
796 }
797 }
798 grouping boot-event-log {
799 description
800 "Defines an event log corresponding to the event that extended
801 the PCR";
802 leaf event-number {
803 type uint32;
804 description
805 "Unique event number of this event";
806 }
807 leaf event-type {
808 type uint32;
809 description
810 "log event type";
811 }
812 leaf pcr-index {
813 type pcr;
814 description
815 "Defines the PCR index that this event extended";
816 }
817 list digest-list {
818 description
819 "Hash of event data";
820 leaf hash-algo {
821 type identityref {
822 base taa:hash;
823 }
824 description
825 "The hash scheme that is used to compress the event data in
826 each of the leaf-list digest items.";
827 }
828 leaf-list digest {
829 type binary;
830 description
831 "The hash of the event data using the algorithm of the
832 'hash-algo' against 'event data'.";
833 }
834 }
835 leaf event-size {
836 type uint32;
837 description
838 "Size of the event data";
839 }
840 leaf-list event-data {
841 type uint8;
842 description
843 "The event data size determined by event-size";
844 }
845 }
846 grouping bios-event-log {
847 description
848 "Measurement log created by the BIOS/UEFI.";
849 list bios-event-entry {
850 key event-number;
851 description
852 "Ordered list of TCG described event log
853 that extended the PCRs in the order they
854 were logged";
855 uses boot-event-log;
856 }
857 }
858 grouping ima-event {
859 description
860 "Defines an hash log extend event for IMA measurements";
861 reference
862 "https://www.trustedcomputinggroup.org/wp-content/uploads/
863 TCG_IWG_CEL_v1_r0p30_13feb2021.pdf Section 4.3";
864 leaf event-number {
865 type uint64;
866 description
867 "Unique number for this event for sequencing";
868 }
869 leaf ima-template {
870 type string;
871 description
872 "Name of the template used for event logs
873 for e.g. ima, ima-ng, ima-sig";
874 }
875 leaf filename-hint {
876 type string;
877 description
878 "File that was measured";
879 }
880 leaf filedata-hash {
881 type binary;
882 description
883 "Hash of filedata";
884 }
885 leaf filedata-hash-algorithm {
886 type string;
887 description
888 "Algorithm used for filedata-hash";
889 }
890 leaf template-hash-algorithm {
891 type string;
892 description
893 "Algorithm used for template-hash";
894 }
895 leaf template-hash {
896 type binary;
897 description
898 "hash(filedata-hash, filename-hint)";
899 }
900 leaf pcr-index {
901 type pcr;
902 description
903 "Defines the PCR index that this event extended";
904 }
905 leaf signature {
906 type binary;
907 description
908 "The file signature";
909 }
910 }
911 grouping ima-event-log {
912 description
913 "Measurement log created by IMA.";
914 list ima-event-entry {
915 key event-number;
916 description
917 "Ordered list of ima event logs by event-number";
918 uses ima-event;
919 }
920 }
921 grouping network-equipment-boot-event-log {
922 description
923 "Measurement log created by Network Equipment Boot. The Network
924 Equipment Boot format is identical to the IMA format. In
925 contrast to the IMA log, the Network Equipment Boot log
926 includes every measurable event from an Attester, including
927 the boot stages of BIOS, Bootloader, etc. In essence, the scope
928 of events represented in this format combines the scope of BIOS
929 events and IMA events.";
930 list boot-event-entry {
931 key event-number;
932 description
933 "Ordered list of Network Equipment Boot event logs
934 by event-number, using the IMA event format.";
935 uses ima-event;
936 }
937 }
938 grouping event-logs {
939 description
940 "A selector for the log and its type.";
941 choice attested_event_log_type {
942 mandatory true;
943 description
944 "Event log type determines the event logs content.";
945 case bios {
946 if-feature "bios";
947 description
948 "BIOS/UEFI event logs";
949 container bios-event-logs {
950 description
951 "BIOS/UEFI event logs";
952 uses bios-event-log;
953 }
954 }
955 case ima {
956 if-feature "ima";
957 description
958 "IMA event logs.";
959 container ima-event-logs {
960 description
961 "IMA event logs.";
962 uses ima-event-log;
963 }
964 }
965 case netequip_boot {
966 if-feature "netequip_boot";
967 description
968 "Network Equipment Boot event logs";
970 container boot-event-logs {
971 description
972 "Network equipment boot event logs.";
973 uses network-equipment-boot-event-log;
974 }
975 }
976 }
977 }
979 /**********************/
980 /* RPC operations */
981 /**********************/
983 rpc tpm12-challenge-response-attestation {
984 if-feature "taa:tpm12";
985 description
986 "This RPC accepts the input for TSS TPM 1.2 commands made to the
987 attesting device.";
988 input {
989 container tpm12-attestation-challenge {
990 description
991 "This container includes every information element defined
992 in the reference challenge-response interaction model for
993 remote attestation. Corresponding values are based on
994 TPM 1.2 structure definitions";
995 uses tpm12-pcr-selection;
996 uses nonce;
997 leaf-list certificate-name {
998 if-feature "tpm:tpms";
999 type certificate-name-ref;
1000 must "/tpm:rats-support-structures/tpm:tpms"
1001 + "/tpm:tpm[tpm:firmware-version='taa:tpm12']"
1002 + "/tpm:certificates/"
1003 + "/tpm:certificate[name=current()]" {
1004 error-message "Not an available TPM1.2 AIK certificate.";
1005 }
1006 description
1007 "When populated, the RPC will only get a Quote for the
1008 TPMs associated with these certificate(s).";
1009 }
1010 }
1011 }
1012 output {
1013 list tpm12-attestation-response {
1014 unique "certificate-name";
1015 description
1016 "The binary output of TPM 1.2 TPM_Quote/TPM_Quote2, including
1017 the PCR selection and other associated attestation evidence
1018 metadata";
1019 uses certificate-name-ref {
1020 description
1021 "Certificate associated with this tpm12-attestation.";
1022 }
1023 uses tpm12-attestation;
1024 }
1025 }
1026 }
1028 rpc tpm20-challenge-response-attestation {
1029 if-feature "taa:tpm20";
1030 description
1031 "This RPC accepts the input for TSS TPM 2.0 commands of the
1032 managed device. ComponentIndex from the hardware manager YANG
1033 module to refer to dedicated TPM in composite devices,
1034 e.g. smart NICs, is still a TODO.";
1035 input {
1036 container tpm20-attestation-challenge {
1037 description
1038 "This container includes every information element defined
1039 in the reference challenge-response interaction model for
1040 remote attestation. Corresponding values are based on
1041 TPM 2.0 structure definitions";
1042 uses nonce;
1043 uses tpm20-pcr-selection;
1044 leaf-list certificate-name {
1045 if-feature "tpm:tpms";
1046 type certificate-name-ref;
1047 must "/tpm:rats-support-structures/tpm:tpms"
1048 + "/tpm:tpm[tpm:firmware-version='taa:tpm20']"
1049 + "/tpm:certificates/"
1050 + "/tpm:certificate[name=current()]" {
1051 error-message "Not an available TPM2.0 AIK certificate.";
1052 }
1053 description
1054 "When populated, the RPC will only get a Quote for the
1055 TPMs associated with the certificates.";
1056 }
1057 }
1058 }
1059 output {
1060 list tpm20-attestation-response {
1061 unique "certificate-name";
1062 description
1063 "The binary output of TPM2b_Quote in one TPM chip of the
1064 node which identified by node-id. An TPMS_ATTEST structure
1065 including a length, encapsulated in a signature";
1067 uses certificate-name-ref {
1068 description
1069 "Certificate associated with this tpm20-attestation.";
1070 }
1071 uses tpm20-attestation;
1072 }
1073 }
1074 }
1076 rpc log-retrieval {
1077 description
1078 "Logs Entries are either identified via indices or via providing
1079 the last line received. The number of lines returned can be
1080 limited. The type of log is a choice that can be augmented.";
1081 input {
1082 list log-selector {
1083 description
1084 "Selection of log entries to be reported.";
1085 uses tpm-name-selector;
1086 choice index-type {
1087 description
1088 "Last log entry received, log index number, or timestamp.";
1089 case last-entry {
1090 description
1091 "The last entry of the log already retrieved.";
1092 leaf last-entry-value {
1093 type binary;
1094 description
1095 "Content of an log event which matches 1:1 with a
1096 unique event record contained within the log. Log
1097 entries subsequent to this will be passed to the
1098 requester. Note: if log entry values are not unique,
1099 this MUST return an error.";
1100 }
1101 }
1102 case index {
1103 description
1104 "Numeric index of the last log entry retrieved, or
1105 zero.";
1106 leaf last-index-number {
1107 type uint64;
1108 description
1109 "The last numeric index number of a log entry.
1110 Zero means to start at the beginning of the log.
1111 Entries subsequent to this will be passed to the
1112 requester.";
1113 }
1114 }
1115 case timestamp {
1116 leaf timestamp {
1117 type yang:date-and-time;
1118 description
1119 "Timestamp from which to start the extraction. The
1120 next log entry subsequent to this timestamp is to
1121 be sent.";
1122 }
1123 description
1124 "Timestamp from which to start the extraction.";
1125 }
1126 }
1127 leaf log-entry-quantity {
1128 type uint16;
1129 description
1130 "The number of log entries to be returned. If omitted, it
1131 means all of them.";
1132 }
1133 }
1134 uses log-identifier;
1135 }
1136 output {
1137 container system-event-logs {
1138 description
1139 "The requested data of the measurement event logs";
1140 list node-data {
1141 unique "name";
1142 description
1143 "Event logs of a node in a distributed system
1144 identified by the node name";
1145 uses tpm-name;
1146 uses node-uptime;
1147 container log-result {
1148 description
1149 "The requested entries of the corresponding log.";
1150 uses event-logs;
1151 }
1152 }
1153 }
1154 }
1155 }
1157 /**************************************/
1158 /* Config & Oper accessible nodes */
1159 /**************************************/
1161 container rats-support-structures {
1162 description
1163 "The datastore definition enabling verifiers or relying
1164 parties to discover the information necessary to use the
1165 remote attestation RPCs appropriately.";
1166 container compute-nodes {
1167 if-feature "tpm:tpms";
1168 description
1169 "Holds the set device subsystems/components in this composite
1170 device that support TPM operations.";
1171 list compute-node {
1172 key "node-id";
1173 config false;
1174 min-elements 2;
1175 description
1176 "A component within this composite device which
1177 supports TPM operations.";
1178 leaf node-id {
1179 type string;
1180 description
1181 "ID of the compute node, such as Board Serial Number.";
1182 }
1183 leaf node-physical-index {
1184 if-feature "ietfhw:entity-mib";
1185 type int32 {
1186 range "1..2147483647";
1187 }
1188 config false;
1189 description
1190 "The entPhysicalIndex for the compute node.";
1191 reference
1192 "RFC 6933: Entity MIB (Version 4) - entPhysicalIndex";
1193 }
1194 leaf node-name {
1195 type string;
1196 description
1197 "Name of the compute node.";
1198 }
1199 leaf node-location {
1200 type string;
1201 description
1202 "Location of the compute node, such as slot number.";
1203 }
1204 }
1205 }
1206 container tpms {
1207 description
1208 "Holds the set of TPMs within an Attester.";
1209 list tpm {
1210 key "name";
1211 unique "path";
1212 description
1213 "A list of TPMs in this composite device that RATS
1214 can be conducted with.";
1215 uses tpm-name;
1216 leaf hardware-based {
1217 type boolean;
1218 config false;
1219 description
1220 "Answers the question: is this TPM is a hardware based
1221 TPM?";
1222 }
1223 leaf physical-index {
1224 if-feature "ietfhw:entity-mib";
1225 type int32 {
1226 range "1..2147483647";
1227 }
1228 config false;
1229 description
1230 "The entPhysicalIndex for the TPM.";
1231 reference
1232 "RFC 6933: Entity MIB (Version 4) - entPhysicalIndex";
1233 }
1234 leaf path {
1235 type string;
1236 config false;
1237 description
1238 "Path to a unique TPM on a device. This can change across
1239 reboots.";
1240 }
1241 leaf compute-node {
1242 if-feature "tpm:tpms";
1243 type compute-node-ref;
1244 config false;
1245 mandatory true;
1246 description
1247 "Indicates the compute node measured by this TPM.";
1248 }
1249 leaf manufacturer {
1250 type string;
1251 config false;
1252 description
1253 "TPM manufacturer name.";
1254 }
1255 leaf firmware-version {
1256 type identityref {
1257 base taa:cryptoprocessor;
1258 }
1259 mandatory true;
1260 description
1261 "Identifies the cryptoprocessor API set supported. This
1262 is automatically configured by the device and should not
1263 be changed.";
1264 }
1265 uses tpm12-hash-algo {
1266 when "firmware-version = 'taa:tpm12'";
1267 refine "tpm12-hash-algo" {
1268 description
1269 "The hash algorithm overwrites the default used for PCRs
1270 on this TPM1.2 compliant cryptoprocessor.";
1271 }
1272 }
1273 leaf-list tpm12-pcrs {
1274 when "../firmware-version = 'taa:tpm12'";
1275 type pcr;
1276 description
1277 "The PCRs which may be extracted from this TPM1.2
1278 compliant cryptoprocessor.";
1279 }
1280 list tpm20-pcr-bank {
1281 when "../firmware-version = 'taa:tpm20'";
1282 key "tpm20-hash-algo";
1283 description
1284 "Specifies the list of PCRs that may be extracted for
1285 a specific Hash Algorithm on this TPM2 compliant
1286 cryptoprocessor. A bank is a set of PCRs which are
1287 extended using a particular hash algorithm.";
1288 reference
1289 "https://www.trustedcomputinggroup.org/wp-content/uploads/
1290 TPM-Rev-2.0-Part-2-Structures-01.38.pdf Section 10.9.7";
1291 leaf tpm20-hash-algo {
1292 type identityref {
1293 base taa:hash;
1294 }
1295 must '/tpm:rats-support-structures'
1296 + '/tpm:attester-supported-algos'
1297 + '/tpm:tpm20-hash' {
1298 error-message
1299 "This platform does not support tpm20-hash-algo";
1300 }
1301 description
1302 "The hash scheme actively being used to hash a
1303 one or more TPM2.0 PCRs.";
1304 }
1305 leaf-list pcr-index {
1306 type tpm:pcr;
1307 description
1308 "Defines what TPM2 PCRs are available to be extracted.";
1309 }
1310 }
1311 leaf status {
1312 type enumeration {
1313 enum operational {
1314 value 0;
1315 description
1316 "The TPM currently is currently running normally and
1317 is ready to accept and process TPM quotes.";
1318 reference
1319 "TPM-Rev-2.0-Part-1-Architecture-01.07-2014-03-13.pdf
1320 Section 12";
1321 }
1322 enum non-operational {
1323 value 1;
1324 description
1325 "TPM is in a state such as startup or shutdown which
1326 precludes the processing of TPM quotes.";
1327 }
1328 }
1329 config false;
1330 mandatory true;
1331 description
1332 "TPM chip self-test status.";
1333 }
1334 container certificates {
1335 description
1336 "The TPM's certificates, including EK certificates
1337 and AK certificates.";
1338 list certificate {
1339 key "name";
1340 description
1341 "Three types of certificates can be accessed via
1342 this statement, including Initial Attestation
1343 Key Certificate, Local Attestation Key Certificate or
1344 Endorsement Key Certificate.";
1345 leaf name {
1346 type string;
1347 description
1348 "An arbitrary name uniquely identifying a certificate
1349 associated within key within a TPM.";
1350 }
1351 leaf keystore-ref {
1352 type leafref {
1353 path "/ks:keystore/ks:asymmetric-keys/ks:asymmetric-key"
1354 + "/ks:certificates/ks:certificate/ks:name";
1356 }
1357 description
1358 "A reference to a specific certificate of an
1359 asymmetric key in the Keystore.";
1360 }
1361 leaf type {
1362 type enumeration {
1363 enum endorsement-certificate {
1364 value 0;
1365 description
1366 "Endorsement Key (EK) Certificate type.";
1367 reference
1368 "https://trustedcomputinggroup.org/wp-content/
1369 uploads/TCG_IWG_DevID_v1r2_02dec2020.pdf
1370 Section 3.11";
1371 }
1372 enum initial-attestation-certificate {
1373 value 1;
1374 description
1375 "Initial Attestation key (IAK) Certificate type.";
1376 reference
1377 "https://trustedcomputinggroup.org/wp-content/
1378 uploads/TCG_IWG_DevID_v1r2_02dec2020.pdf
1379 Section 3.2";
1380 }
1381 enum local-attestation-certificate {
1382 value 2;
1383 description
1384 "Local Attestation Key (LAK) Certificate type.";
1385 reference
1386 "https://trustedcomputinggroup.org/wp-content/
1387 uploads/TCG_IWG_DevID_v1r2_02dec2020.pdf
1388 Section 3.2";
1389 }
1390 }
1391 description
1392 "Function supported by this certificate from within the
1393 TPM.";
1394 }
1395 }
1396 }
1397 }
1398 }
1399 container attester-supported-algos {
1400 description
1401 "Identifies which TPM algorithms are available for use on an
1402 attesting platform.";
1403 leaf-list tpm12-asymmetric-signing {
1404 when "../../tpm:tpms"
1405 + "/tpm:tpm[tpm:firmware-version='taa:tpm12']";
1406 type identityref {
1407 base taa:asymmetric;
1408 }
1409 description
1410 "Platform Supported TPM12 asymmetric algorithms.";
1411 }
1412 leaf-list tpm12-hash {
1413 when "../../tpm:tpms"
1414 + "/tpm:tpm[tpm:firmware-version='taa:tpm12']";
1415 type identityref {
1416 base taa:hash;
1417 }
1418 description
1419 "Platform supported TPM12 hash algorithms.";
1420 }
1421 leaf-list tpm20-asymmetric-signing {
1422 when "../../tpm:tpms"
1423 + "/tpm:tpm[tpm:firmware-version='taa:tpm20']";
1424 type identityref {
1425 base taa:asymmetric;
1426 }
1427 description
1428 "Platform Supported TPM20 asymmetric algorithms.";
1429 }
1430 leaf-list tpm20-hash {
1431 when "../../tpm:tpms"
1432 + "/tpm:tpm[tpm:firmware-version='taa:tpm20']";
1433 type identityref {
1434 base taa:hash;
1435 }
1436 description
1437 "Platform supported TPM20 hash algorithms.";
1438 }
1439 }
1440 }
1441 }
1442
1444 Figure 1
1446 2.1.2. 'ietf-tcg-algs'
1448 Cryptographic algorithm types were initially included within -v14
1449 NETCONF's iana-crypto-types.yang. Unfortunately, all this content
1450 including the algorithms needed here failed to make the -v15 used
1451 WGLC. As a result, this document has encoded the TCG Algorithm
1452 definitions of [TCG-Algos], revision 1.32. By including this full
1453 table as a separate YANG file within this document, it is possible
1454 for other YANG models to leverage the contents of this model.
1456 2.1.2.1. Features
1458 There are two types of features supported: 'TPM12' and 'TPM20'.
1459 Support for either of these features indicates that a cryptoprocessor
1460 supporting the corresponding type of TCG TPM API is present on an
1461 Attester. Most commonly, only one type of cryptoprocessor will be
1462 available on an Attester.
1464 2.1.2.2. Identities
1466 There are three types of identities in this model:
1468 1. *Cryptographic functions* supported by a TPM algorithm; these
1469 include: 'asymmetric', 'symmetric', 'hash', 'signing',
1470 'anonymous_signing', 'encryption_mode', 'method', and
1471 'object_type'. The definitions of each of these are in Table 2
1472 of [TCG-Algos].
1474 2. *API specifications* for TPMs: 'tpm12' and 'tpm20'
1476 3. *Specific algorithm types*: Each algorithm type defines what
1477 cryptographic functions may be supported, and on which type of
1478 API specification. It is not required that an implementation of
1479 a specific TPM will support all algorithm types. The contents of
1480 each specific algorithm mirrors what is in Table 3 of
1481 [TCG-Algos].
1483 2.1.2.3. YANG Module
1485 file "ietf-tcg-algs@2021-05-11.yang"
1486 module ietf-tcg-algs {
1487 yang-version 1.1;
1488 namespace "urn:ietf:params:xml:ns:yang:ietf-tcg-algs";
1489 prefix taa;
1491 organization
1492 "IETF RATS Working Group";
1494 contact
1495 "WG Web:
1496 WG List:
1497 Author: Eric Voit ";
1499 description
1500 "This module defines a identities for asymmetric algorithms.
1502 Copyright (c) 2021 IETF Trust and the persons identified
1503 as authors of the code. All rights reserved.
1504 Redistribution and use in source and binary forms, with
1505 or without modification, is permitted pursuant to, and
1506 subject to the license terms contained in, the Simplified
1507 BSD License set forth in Section 4.c of the IETF Trust's
1508 Legal Provisions Relating to IETF Documents
1509 (https://trustee.ietf.org/license-info).
1510 This version of this YANG module is part of RFC XXXX
1511 (https://www.rfc-editor.org/info/rfcXXXX); see the RFC
1512 itself for full legal notices.
1513 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL',
1514 'SHALL NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED',
1515 'NOT RECOMMENDED', 'MAY', and 'OPTIONAL' in this document
1516 are to be interpreted as described in BCP 14 (RFC 2119)
1517 (RFC 8174) when, and only when, they appear in all
1518 capitals, as shown here.";
1520 revision 2021-05-11 {
1521 description
1522 "Initial version";
1523 reference
1524 "RFC XXXX: tbd";
1525 }
1527 /*****************/
1528 /* Features */
1529 /*****************/
1531 feature tpm12 {
1532 description
1533 "This feature indicates algorithm support for the TPM 1.2 API
1534 as per TPM-main-1.2-Rev94-part-2, Section 4.8.";
1535 }
1537 feature tpm20 {
1538 description
1539 "This feature indicates algorithm support for the TPM 2.0 API
1540 as per TPM-Rev-2.0-Part-1-Architecture-01.38 Section 11.4.";
1541 }
1542 /*****************/
1543 /* Identities */
1544 /*****************/
1546 /* There needs to be collasping/verification of some of the identity
1547 types between the various algorithm types listed below */
1549 identity asymmetric {
1550 description
1551 "A TCG recognized asymmetric algorithm with a public and
1552 private key.";
1553 reference
1554 "http://trustedcomputinggroup.org/resource/tcg-algorithm-registry/
1555 TCG_Algorithm_Registry_r1p32_pub Table 2";
1556 }
1558 identity symmetric {
1559 description
1560 "A TCG recognized symmetric algorithm with only a private key.";
1561 reference
1562 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1563 }
1565 identity hash {
1566 description
1567 "A TCG recognized hash algorithm that compresses input data to
1568 a digest value or indicates a method that uses a hash.";
1569 reference
1570 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1571 }
1573 identity signing {
1574 description
1575 "A TCG recognized signing algorithm";
1576 reference
1577 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1578 }
1580 identity anonymous_signing {
1581 description
1582 "A TCG recognized anonymous signing algorithm.";
1583 reference
1584 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1585 }
1587 identity encryption_mode {
1588 description
1589 "A TCG recognized encryption mode.";
1591 reference
1592 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1593 }
1595 identity method {
1596 description
1597 "A TCG recognized method such as a mask generation function.";
1598 reference
1599 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1600 }
1602 identity object_type {
1603 description
1604 "A TCG recognized object type.";
1605 reference
1606 "TCG_Algorithm_Registry_r1p32_pub Table 2";
1607 }
1609 identity cryptoprocessor {
1610 description
1611 "Base identity identifying a crytoprocessor.";
1612 }
1614 identity tpm12 {
1615 if-feature "tpm12";
1616 base cryptoprocessor;
1617 description
1618 "Supportable by a TPM1.2.";
1619 reference
1620 "TPM-Main-Part-2-TPM-Structures_v1.2_rev116_01032011.pdf
1621 TPM_ALGORITHM_ID values, page 18";
1622 }
1624 identity tpm20 {
1625 if-feature "tpm12";
1626 base cryptoprocessor;
1627 description
1628 "Supportable by a TPM2.";
1629 reference
1630 "TPM-Rev-2.0-Part-2-Structures-01.38.pdf
1631 The TCG Algorithm Registry. Table 9";
1632 }
1634 identity TPM_ALG_RSA {
1635 if-feature "tpm12 or tpm20";
1636 base tpm12;
1637 base tpm20;
1638 base asymmetric;
1639 base object_type;
1640 description
1641 "RSA algorithm";
1642 reference
1643 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1644 RFC 8017. ALG_ID: 0x0001";
1645 }
1647 identity TPM_ALG_TDES {
1648 if-feature "tpm12";
1649 base tpm12;
1650 base symmetric;
1651 description
1652 "Block cipher with various key sizes (Triple Data Encryption
1653 Algorithm, commonly called Triple Data Encryption Standard)
1654 Note: was banned in TPM1.2 v94";
1655 reference
1656 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1657 ISO/IEC 18033-3. ALG_ID: 0x0003";
1658 }
1660 identity TPM_ALG_SHA1 {
1661 if-feature "tpm12 or tpm20";
1662 base hash;
1663 base tpm12;
1664 base tpm20;
1665 description
1666 "SHA1 algorithm - Deprecated due to insufficient cryptographic
1667 protection. However it is still useful for hash algorithms
1668 where protection is not required.";
1669 reference
1670 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1671 ISO/IEC 10118-3. ALG_ID: 0x0004";
1672 }
1674 identity TPM_ALG_HMAC {
1675 if-feature "tpm12 or tpm20";
1676 base tpm12;
1677 base tpm20;
1678 base hash;
1679 base signing;
1680 description
1681 "Hash Message Authentication Code (HMAC) algorithm";
1682 reference
1683 "TCG_Algorithm_Registry_r1p32_pub Table 3,
1684 ISO/IEC 9797-2 and RFC2014. ALG_ID: 0x0005";
1685 }
1686 identity TPM_ALG_AES {
1687 if-feature "tpm12";
1688 base tpm12;
1689 base symmetric;
1690 description
1691 "The AES algorithm with various key sizes";
1692 reference
1693 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1694 ISO/IEC 18033-3. ALG_ID: 0x0006";
1695 }
1697 identity TPM_ALG_MGF1 {
1698 if-feature "tpm20";
1699 base tpm20;
1700 base hash;
1701 base method;
1702 description
1703 "hash-based mask-generation function";
1704 reference
1705 "TCG_Algorithm_Registry_r1p32_pub Table 3,
1706 IEEE Std 1363-2000 and IEEE Std 1363a -2004.
1707 ALG_ID: 0x0007";
1708 }
1710 identity TPM_ALG_KEYEDHASH {
1711 if-feature "tpm20";
1712 base tpm20;
1713 base hash;
1714 base object_type;
1715 description
1716 "An encryption or signing algorithm using a keyed hash. These
1717 may use XOR for encryption or an HMAC for signing and may
1718 also refer to a data object that is neither signing nor
1719 encrypting.";
1720 reference
1721 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1722 TCG TPM 2.0 library specification. . ALG_ID: 0x0008";
1723 }
1725 identity TPM_ALG_XOR {
1726 if-feature "tpm12 or tpm20";
1727 base tpm12;
1728 base tpm20;
1729 base hash;
1730 base symmetric;
1731 description
1732 "The XOR encryption algorithm.";
1733 reference
1734 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1735 TCG TPM 2.0 library specification. ALG_ID: 0x000A";
1736 }
1738 identity TPM_ALG_SHA256 {
1739 if-feature "tpm20";
1740 base tpm20;
1741 base hash;
1742 description
1743 "The SHA 256 algorithm";
1744 reference
1745 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1746 ISO/IEC 10118-3. ALG_ID: 0x000B";
1747 }
1749 identity TPM_ALG_SHA384 {
1750 if-feature "tpm20";
1751 base tpm20;
1752 base hash;
1753 description
1754 "The SHA 384 algorithm";
1755 reference
1756 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1757 ISO/IEC 10118-3. ALG_ID: 0x000C";
1758 }
1760 identity TPM_ALG_SHA512 {
1761 if-feature "tpm20";
1762 base tpm20;
1763 base hash;
1764 description
1765 "The SHA 512 algorithm";
1766 reference
1767 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1768 ISO/IEC 10118-3. ALG_ID: 0x000D";
1769 }
1771 identity TPM_ALG_NULL {
1772 if-feature "tpm20";
1773 base tpm20;
1774 description
1775 "NULL algorithm";
1776 reference
1777 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1778 TCG TPM 2.0 library specification. ALG_ID: 0x0010";
1779 }
1781 identity TPM_ALG_SM3_256 {
1782 if-feature "tpm20";
1783 base tpm20;
1784 base hash;
1785 description
1786 "The SM3 hash algorithm.";
1787 reference
1788 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1789 GM/T 0004-2012 - SM3_256. ALG_ID: 0x0012";
1790 }
1792 identity TPM_ALG_SM4 {
1793 if-feature "tpm20";
1794 base tpm20;
1795 base symmetric;
1796 description
1797 "SM4 symmetric block cipher";
1798 reference
1799 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1800 GB/T 32907-2016. ALG_ID: 0x0013";
1801 }
1803 identity TPM_ALG_RSASSA {
1804 if-feature "tpm20";
1805 base tpm20;
1806 base asymmetric;
1807 base signing;
1808 description
1809 "Signature algorithm defined in section 8.2 (RSASSAPKCS1-v1_5)";
1810 reference
1811 "TCG_Algorithm_Registry_r1p32_pub Table 3 and RFC 8017.
1812 ALG_ID: 0x0014";
1813 }
1815 identity TPM_ALG_RSAES {
1816 if-feature "tpm20";
1817 base tpm20;
1818 base asymmetric;
1819 base encryption_mode;
1820 description
1821 "Signature algorithm defined in section 7.2 (RSAES-PKCS1-v1_5)";
1822 reference
1823 "TCG_Algorithm_Registry_r1p32_pub Table 3 and RFC 8017
1824 ALG_ID: 0x0015";
1825 }
1827 identity TPM_ALG_RSAPSS {
1828 if-feature "tpm20";
1829 base tpm20;
1830 base asymmetric;
1831 base signing;
1832 description
1833 "Padding algorithm defined in section 8.1 (RSASSA PSS)";
1834 reference
1835 "TCG_Algorithm_Registry_r1p32_pub Table 3 and RFC 8017.
1836 ALG_ID: 0x0016";
1837 }
1839 identity TPM_ALG_OAEP {
1840 if-feature "tpm20";
1841 base tpm20;
1842 base asymmetric;
1843 base encryption_mode;
1844 description
1845 "Padding algorithm defined in section 7.1 (RSASSA OAEP)";
1846 reference
1847 "TCG_Algorithm_Registry_r1p32_pub Table 3 and RFC 8017.
1848 ALG_ID: 0x0017";
1849 }
1851 identity TPM_ALG_ECDSA {
1852 if-feature "tpm20";
1853 base tpm20;
1854 base asymmetric;
1855 base signing;
1856 description
1857 "Signature algorithm using elliptic curve cryptography (ECC)";
1858 reference
1859 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1860 ISO/IEC 14888-3. ALG_ID: 0x0018";
1861 }
1863 identity TPM_ALG_ECDH {
1864 if-feature "tpm20";
1865 base tpm20;
1866 base asymmetric;
1867 base method;
1868 description
1869 "Secret sharing using ECC";
1870 reference
1871 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1872 NIST SP800-56A and RFC 7748. ALG_ID: 0x0019";
1873 }
1875 identity TPM_ALG_ECDAA {
1876 if-feature "tpm20";
1877 base tpm20;
1878 base asymmetric;
1879 base signing;
1880 base anonymous_signing;
1881 description
1882 "Elliptic-curve based anonymous signing scheme";
1883 reference
1884 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1885 TCG TPM 2.0 library specification. ALG_ID: 0x001A";
1886 }
1888 identity TPM_ALG_SM2 {
1889 if-feature "tpm20";
1890 base tpm20;
1891 base asymmetric;
1892 base signing;
1893 base encryption_mode;
1894 base method;
1895 description
1896 "SM2 - depending on context, either an elliptic-curve based,
1897 signature algorithm, an encryption scheme, or a key exchange
1898 protocol";
1899 reference
1900 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1901 A GM/T 0003.1-2012, GM/T 0003.2-2012, GM/T 0003.3-2012,
1902 GM/T 0003.5-2012 SM2. ALG_ID: 0x001B";
1903 }
1905 identity TPM_ALG_ECSCHNORR {
1906 if-feature "tpm20";
1907 base tpm20;
1908 base asymmetric;
1909 base signing;
1910 description
1911 "Elliptic-curve based Schnorr signature";
1912 reference
1913 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1914 TCG TPM 2.0 library specification. ALG_ID: 0x001C";
1915 }
1917 identity TPM_ALG_ECMQV {
1918 if-feature "tpm20";
1919 base tpm20;
1920 base asymmetric;
1921 base method;
1922 description
1923 "Two-phase elliptic-curve key";
1924 reference
1925 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1926 NIST SP800-56A. ALG_ID: 0x001D";
1927 }
1929 identity TPM_ALG_KDF1_SP800_56A {
1930 if-feature "tpm20";
1931 base tpm20;
1932 base hash;
1933 base method;
1934 description
1935 "Concatenation key derivation function";
1936 reference
1937 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1938 NIST SP800-56A (approved alternative1) section 5.8.1.
1939 ALG_ID: 0x0020";
1940 }
1942 identity TPM_ALG_KDF2 {
1943 if-feature "tpm20";
1944 base tpm20;
1945 base hash;
1946 base method;
1947 description
1948 "Key derivation function";
1949 reference
1950 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1951 IEEE 1363a-2004 KDF2 section 13.2. ALG_ID: 0x0021";
1952 }
1954 identity TPM_ALG_KDF1_SP800_108 {
1955 base TPM_ALG_KDF2;
1956 description
1957 "A key derivation method";
1958 reference
1959 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1960 NIST SP800-108 - Section 5.1 KDF. ALG_ID: 0x0022";
1961 }
1963 identity TPM_ALG_ECC {
1964 if-feature "tpm20";
1965 base tpm20;
1966 base asymmetric;
1967 base object_type;
1968 description
1969 "Prime field ECC";
1970 reference
1971 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1972 ISO/IEC 15946-1. ALG_ID: 0x0023";
1973 }
1974 identity TPM_ALG_SYMCIPHER {
1975 if-feature "tpm20";
1976 base tpm20;
1977 description
1978 "Object type for a symmetric block cipher";
1979 reference
1980 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1981 TCG TPM 2.0 library specification. ALG_ID: 0x0025";
1982 }
1984 identity TPM_ALG_CAMELLIA {
1985 if-feature "tpm20";
1986 base tpm20;
1987 base symmetric;
1988 description
1989 "The Camellia algorithm";
1990 reference
1991 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
1992 ISO/IEC 18033-3. ALG_ID: 0x0026";
1993 }
1995 identity TPM_ALG_SHA3_256 {
1996 if-feature "tpm20";
1997 base tpm20;
1998 base hash;
1999 description
2000 "ISO/IEC 10118-3 - the SHA 256 algorithm";
2001 reference
2002 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2003 NIST PUB FIPS 202. ALG_ID: 0x0027";
2004 }
2006 identity TPM_ALG_SHA3_384 {
2007 if-feature "tpm20";
2008 base tpm20;
2009 base hash;
2010 description
2011 "The SHA 384 algorithm";
2012 reference
2013 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2014 NIST PUB FIPS 202. ALG_ID: 0x0028";
2015 }
2017 identity TPM_ALG_SHA3_512 {
2018 if-feature "tpm20";
2019 base tpm20;
2020 base hash;
2021 description
2022 "The SHA 512 algorithm";
2023 reference
2024 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2025 NIST PUB FIPS 202. ALG_ID: 0x0029";
2026 }
2028 identity TPM_ALG_CMAC {
2029 if-feature "tpm20";
2030 base tpm20;
2031 base symmetric;
2032 base signing;
2033 description
2034 "block Cipher-based Message Authentication Code (CMAC)";
2035 reference
2036 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2037 ISO/IEC 9797-1:2011 Algorithm 5. ALG_ID: 0x003F";
2038 }
2040 identity TPM_ALG_CTR {
2041 if-feature "tpm20";
2042 base tpm20;
2043 base symmetric;
2044 base encryption_mode;
2045 description
2046 "Counter mode";
2047 reference
2048 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2049 ISO/IEC 10116. ALG_ID: 0x0040";
2050 }
2052 identity TPM_ALG_OFB {
2053 base tpm20;
2054 base symmetric;
2055 base encryption_mode;
2056 description
2057 "Output Feedback mode";
2058 reference
2059 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2060 ISO/IEC 10116. ALG_ID: 0x0041";
2061 }
2063 identity TPM_ALG_CBC {
2064 if-feature "tpm20";
2065 base tpm20;
2066 base symmetric;
2067 base encryption_mode;
2068 description
2069 "Cipher Block Chaining mode";
2071 reference
2072 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2073 ISO/IEC 10116. ALG_ID: 0x0042";
2074 }
2076 identity TPM_ALG_CFB {
2077 if-feature "tpm20";
2078 base tpm20;
2079 base symmetric;
2080 base encryption_mode;
2081 description
2082 "Cipher Feedback mode";
2083 reference
2084 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2085 ISO/IEC 10116. ALG_ID: 0x0043";
2086 }
2088 identity TPM_ALG_ECB {
2089 if-feature "tpm20";
2090 base tpm20;
2091 base symmetric;
2092 base encryption_mode;
2093 description
2094 "Electronic Codebook mode";
2095 reference
2096 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2097 ISO/IEC 10116. ALG_ID: 0x0044";
2098 }
2100 identity TPM_ALG_CCM {
2101 if-feature "tpm20";
2102 base tpm20;
2103 base symmetric;
2104 base signing;
2105 base encryption_mode;
2106 description
2107 "Counter with Cipher Block Chaining-Message Authentication
2108 Code (CCM)";
2109 reference
2110 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2111 NIST SP800-38C. ALG_ID: 0x0050";
2112 }
2114 identity TPM_ALG_GCM {
2115 if-feature "tpm20";
2116 base tpm20;
2117 base symmetric;
2118 base signing;
2119 base encryption_mode;
2120 description
2121 "Galois/Counter Mode (GCM)";
2122 reference
2123 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2124 NIST SP800-38D. ALG_ID: 0x0051";
2125 }
2127 identity TPM_ALG_KW {
2128 if-feature "tpm20";
2129 base tpm20;
2130 base symmetric;
2131 base signing;
2132 base encryption_mode;
2133 description
2134 "AES Key Wrap (KW)";
2135 reference
2136 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2137 NIST SP800-38F. ALG_ID: 0x0052";
2138 }
2140 identity TPM_ALG_KWP {
2141 if-feature "tpm20";
2142 base tpm20;
2143 base symmetric;
2144 base signing;
2145 base encryption_mode;
2146 description
2147 "AES Key Wrap with Padding (KWP)";
2148 reference
2149 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2150 NIST SP800-38F. ALG_ID: 0x0053";
2151 }
2153 identity TPM_ALG_EAX {
2154 if-feature "tpm20";
2155 base tpm20;
2156 base symmetric;
2157 base signing;
2158 base encryption_mode;
2159 description
2160 "Authenticated-Encryption Mode";
2161 reference
2162 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2163 NIST SP800-38F. ALG_ID: 0x0054";
2164 }
2166 identity TPM_ALG_EDDSA {
2167 if-feature "tpm20";
2168 base tpm20;
2169 base asymmetric;
2170 base signing;
2171 description
2172 "Edwards-curve Digital Signature Algorithm (PureEdDSA)";
2173 reference
2174 "TCG_Algorithm_Registry_r1p32_pub Table 3 and
2175 RFC 8032. ALG_ID: 0x0060";
2176 }
2177 }
2178
2180 Note that not all cryptographic functions are required for use by
2181 "ietf-tpm-remote-attestation.yang". However the full definition of
2182 Table 3 of [TCG-Algos] will allow use by additional YANG
2183 specifications.
2185 3. IANA Considerations
2187 This document registers the following namespace URIs in the "ns"
2188 class of the IETF XML Registry [IANA.xml-registry] as per [RFC3688]:
2190 URI: urn:ietf:params:xml:ns:yang:ietf-tpm-remote-attestation
2192 Registrant Contact: The IESG.
2194 XML: N/A; the requested URI is an XML namespace.
2196 URI: urn:ietf:params:xml:ns:yang:ietf-tcg-algs
2198 Registrant Contact: The IESG.
2200 XML: N/A; the requested URI is an XML namespace.
2202 This document registers the following YANG modules in the "YANG
2203 Module Names" registry [IANA.yang-parameters] as per Section 14 of
2204 [RFC6020]:
2206 Name: ietf-tpm-remote-attestation
2208 Namespace: urn:ietf:params:xml:ns:yang:ietf-tpm-remote-
2209 attestation
2211 Prefix: tpm
2213 Reference: draft-ietf-rats-yang-tpm-charra (RFC form)
2215 Name: ietf-tcg-algs
2217 Namespace: urn:ietf:params:xml:ns:yang:ietf-tcg-algs
2219 Prefix: taa
2221 Reference: draft-ietf-rats-yang-tpm-charra (RFC form)
2223 4. Security Considerations
2225 The YANG module specified in this document defines a schema for data
2226 that is designed to be accessed via network management protocols such
2227 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer
2228 is the secure transport layer, and the mandatory-to-implement secure
2229 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer
2230 is HTTPS, and the mandatory-to-implement secure transport is TLS
2231 [RFC8446].
2233 There are a number of data nodes defined in this YANG module that are
2234 writable/creatable/deletable (i.e., _config true_, which is the
2235 default). These data nodes may be considered sensitive or vulnerable
2236 in some network environments. Write operations (e.g., _edit-config_)
2237 to these data nodes without proper protection can have a negative
2238 effect on network operations. These are the subtrees and data nodes
2239 as well as their sensitivity/vulnerability:
2241 Container '/rats-support-structures/attester-supported-algos': 'tpm1
2242 2-asymmetric-signing', 'tpm12-hash', 'tpm20-asymmetric-signing',
2243 and 'tpm20-hash'. All could be populated with algorithms that are
2244 not supported by the underlying physical TPM installed by the
2245 equipment vendor.
2247 Container: '/rats-support-structures/tpms': 'name': Although shown
2248 as 'rw', it is system generated. Therefore it should not be
2249 possible for an operator to add or remove a TPM from the
2250 configuration.
2252 'tpm20-pcr-bank': It is possible to configure PCRs for extraction
2253 which are not being extended by system software. This could
2254 unnecessarily use TPM resources.
2256 'certificates': It is possible to provision a certificate which
2257 does not correspond to an Attestation Identity Key (AIK) within
2258 the TPM 1.2, or an Attestation Key (AK) within the TPM 2.0
2259 respectively.
2261 RPC 'tpm12-challenge-response-attestation': It must be verified that
2262 the certificate is for an active AIK, i. e. the certificate
2263 provided is able to support Attestation on the targeted TPM 1.2.
2265 RPC 'tpm20-challenge-response-attestation': It must be verified that
2266 the certificate is for an active AK, i. e. the certificate
2267 provided is able to support Attestation on the targeted TPM 2.0.
2269 RPC 'log-retrieval': Pulling lots of logs can chew up system
2270 resources.
2272 5. Change Log
2274 Changes from version 08 to version 09:
2276 * Minor formatting tweaks for shepherd. IANA registered.
2278 Changes from version 05 to version 06:
2280 * More YANG Dr comments covered
2282 Changes from version 04 to version 05:
2284 * YANG Dr comments covered
2286 Changes from version 03 to version 04:
2288 * TPM1.2 Quote1 eliminated
2290 * YANG model simplifications so redundant info isn't exposed
2292 Changes from version 02 to version 03:
2294 * moved to tcg-algs
2296 * cleaned up model to eliminate sources of errors
2298 * removed key establishment RPC
2300 * added lots of XPATH which must all be scrubbed still
2302 * Descriptive text added on model contents.
2304 Changes from version 01 to version 02:
2306 * Extracted Crypto-types into a separate YANG file
2308 * Mades the algorithms explicit, not strings
2309 * Hash Algo as key the selected TPM2 PCRs
2311 * PCR numbers are their own type
2313 * Eliminated nested keys for node-id plus tpm-name
2315 * Eliminated TPM-Name of "ALL"
2317 * Added TPM-Path
2319 Changes from version 00 to version 01:
2321 * Addressed author's comments
2323 * Extended complementary details about attestation-certificates
2325 * Relabeled chunk-size to log-entry-quantity
2327 * Relabeled location with compute-node or tpm-name where appropriate
2329 * Added a valid entity-mib physical-index to compute-node and tpm-
2330 name to map it back to hardware inventory
2332 * Relabeled name to tpm_name
2334 * Removed event-string in last-entry
2336 6. References
2338 6.1. Normative References
2340 [I-D.ietf-netconf-keystore]
2341 Watsen, K., "A YANG Data Model for a Keystore", Work in
2342 Progress, Internet-Draft, draft-ietf-netconf-keystore-22,
2343 18 May 2021, .
2346 [I-D.ietf-rats-architecture]
2347 Birkholz, H., Thaler, D., Richardson, M., Smith, N., and
2348 W. Pan, "Remote Attestation Procedures Architecture", Work
2349 in Progress, Internet-Draft, draft-ietf-rats-architecture-
2350 12, 23 April 2021, .
2353 [I-D.ietf-rats-tpm-based-network-device-attest]
2354 Fedorkow, G., Voit, E., and J. Fitzgerald-McKay, "TPM-
2355 based Network Device Remote Integrity Verification", Work
2356 in Progress, Internet-Draft, draft-ietf-rats-tpm-based-
2357 network-device-attest-08, 26 July 2021,
2358 .
2361 [IANA.xml-registry]
2362 IANA, "IETF XML Registry",
2363 .
2365 [IANA.yang-parameters]
2366 IANA, "YANG Parameters",
2367 .
2369 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
2370 Requirement Levels", BCP 14, RFC 2119,
2371 DOI 10.17487/RFC2119, March 1997,
2372 .
2374 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688,
2375 DOI 10.17487/RFC3688, January 2004,
2376 .
2378 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for
2379 the Network Configuration Protocol (NETCONF)", RFC 6020,
2380 DOI 10.17487/RFC6020, October 2010,
2381 .
2383 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types",
2384 RFC 6991, DOI 10.17487/RFC6991, July 2013,
2385 .
2387 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC
2388 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174,
2389 May 2017, .
2391 [RFC8348] Bierman, A., Bjorklund, M., Dong, J., and D. Romascanu, "A
2392 YANG Data Model for Hardware Management", RFC 8348,
2393 DOI 10.17487/RFC8348, March 2018,
2394 .
2396 [TCG-Algos]
2397 "TCG_Algorithm_Registry_r1p32_pub", n.d.,
2398 .
2401 [TPM1.2] TCG, ., "TPM 1.2 Main Specification", 2 October 2003,
2402 .
2405 [TPM2.0] TCG, ., "TPM 2.0 Library Specification", 15 March 2013,
2406 .
2409 [TPM2.0-Key]
2410 TCG, ., "TPM 2.0 Keys for Device Identity and Attestation,
2411 Rev10", 14 April 2021, .
2414 6.2. Informative References
2416 [I-D.ietf-rats-reference-interaction-models]
2417 Birkholz, H., Eckel, M., Pan, W., and E. Voit, "Reference
2418 Interaction Models for Remote Attestation Procedures",
2419 Work in Progress, Internet-Draft, draft-ietf-rats-
2420 reference-interaction-models-04, 26 July 2021,
2421 .
2424 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed.,
2425 and A. Bierman, Ed., "Network Configuration Protocol
2426 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011,
2427 .
2429 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure
2430 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011,
2431 .
2433 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF
2434 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017,
2435 .
2437 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol
2438 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018,
2439 .
2441 Authors' Addresses
2443 Henk Birkholz
2444 Fraunhofer SIT
2445 Rheinstrasse 75
2446 64295 Darmstadt
2447 Germany
2449 Email: henk.birkholz@sit.fraunhofer.de
2450 Michael Eckel
2451 Fraunhofer SIT
2452 Rheinstrasse 75
2453 64295 Darmstadt
2454 Germany
2456 Email: michael.eckel@sit.fraunhofer.de
2458 Shwetha Bhandari
2459 ThoughtSpot
2461 Email: shwetha.bhandari@thoughtspot.com
2463 Eric Voit
2464 Cisco Systems
2466 Email: evoit@cisco.com
2468 Bill Sulzen
2469 Cisco Systems
2471 Email: bsulzen@cisco.com
2473 Liang Xia (Frank)
2474 Huawei Technologies
2475 101 Software Avenue, Yuhuatai District
2476 Nanjing
2477 Jiangsu, 210012
2478 China
2480 Email: Frank.Xialiang@huawei.com
2482 Tom Laffey
2483 Hewlett Packard Enterprise
2485 Email: tom.laffey@hpe.com
2487 Guy C. Fedorkow
2488 Juniper Networks
2489 10 Technology Park Drive
2490 Westford
2491 Email: gfedorkow@juniper.net