idnits 2.17.1 draft-jones-ace-cwt-proof-of-possession-00.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 : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (April 20, 2017) is 2563 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) == Unused Reference: 'RFC3629' is defined on line 480, but no explicit reference was found in the text == Unused Reference: 'RFC3986' is defined on line 484, but no explicit reference was found in the text == Unused Reference: 'RFC5246' is defined on line 494, but no explicit reference was found in the text == Unused Reference: 'RFC6125' is defined on line 499, but no explicit reference was found in the text == Outdated reference: A later version (-15) exists of draft-ietf-ace-cbor-web-token-04 ** Obsolete normative reference: RFC 5226 (Obsoleted by RFC 8126) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 6125 (Obsoleted by RFC 9525) ** Obsolete normative reference: RFC 7049 (Obsoleted by RFC 8949) -- Obsolete informational reference (is this intentional?): RFC 7159 (Obsoleted by RFC 8259) Summary: 4 errors (**), 0 flaws (~~), 6 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 ACE Working Group M. Jones 3 Internet-Draft Microsoft 4 Intended status: Standards Track April 20, 2017 5 Expires: October 22, 2017 7 Proof-of-Possession Key Semantics for CBOR Web Tokens (CWTs) 8 draft-jones-ace-cwt-proof-of-possession-00 10 Abstract 12 This specification describes how to declare in a CBOR Web Token (CWT) 13 that the presenter of the CWT possesses a particular proof-of- 14 possession key and how the recipient can cryptographically confirm 15 proof of possession of the key by the presenter. Being able to prove 16 possession of a key is also sometimes described as the presenter 17 being a holder-of-key. This specification is a profile of "Proof-of- 18 Possession Key Semantics for JSON Web Tokens (JWTs)" (RFC 7800), but 19 using CBOR and CWTs rather than JSON and JWTs. 21 Status of This Memo 23 This Internet-Draft is submitted in full conformance with the 24 provisions of BCP 78 and BCP 79. 26 Internet-Drafts are working documents of the Internet Engineering 27 Task Force (IETF). Note that other groups may also distribute 28 working documents as Internet-Drafts. The list of current Internet- 29 Drafts is at http://datatracker.ietf.org/drafts/current/. 31 Internet-Drafts are draft documents valid for a maximum of six months 32 and may be updated, replaced, or obsoleted by other documents at any 33 time. It is inappropriate to use Internet-Drafts as reference 34 material or to cite them other than as "work in progress." 36 This Internet-Draft will expire on October 22, 2017. 38 Copyright Notice 40 Copyright (c) 2017 IETF Trust and the persons identified as the 41 document authors. All rights reserved. 43 This document is subject to BCP 78 and the IETF Trust's Legal 44 Provisions Relating to IETF Documents 45 (http://trustee.ietf.org/license-info) in effect on the date of 46 publication of this document. Please review these documents 47 carefully, as they describe your rights and restrictions with respect 48 to this document. Code Components extracted from this document must 49 include Simplified BSD License text as described in Section 4.e of 50 the Trust Legal Provisions and are provided without warranty as 51 described in the Simplified BSD License. 53 Table of Contents 55 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 56 1.1. Notational Conventions . . . . . . . . . . . . . . . . . 3 57 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 3 58 3. Representations for Proof-of-Possession Keys . . . . . . . . 3 59 3.1. Confirmation Claim . . . . . . . . . . . . . . . . . . . 4 60 3.2. Representation of an Asymmetric Proof-of-Possession Key . 4 61 3.3. Representation of an Encrypted Symmetric Proof-of- 62 Possession Key . . . . . . . . . . . . . . . . . . . . . 5 63 3.4. Representation of a Key ID for a Proof-of-Possession Key 6 64 3.5. Specifics Intentionally Not Specified . . . . . . . . . . 6 65 4. Security Considerations . . . . . . . . . . . . . . . . . . . 7 66 5. Privacy Considerations . . . . . . . . . . . . . . . . . . . 8 67 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 68 6.1. CBOR Web Token Claims Registration . . . . . . . . . . . 8 69 6.1.1. Registry Contents . . . . . . . . . . . . . . . . . . 9 70 6.2. CWT Confirmation Methods Registry . . . . . . . . . . . . 9 71 6.2.1. Registration Template . . . . . . . . . . . . . . . . 9 72 6.2.2. Initial Registry Contents . . . . . . . . . . . . . . 10 73 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 10 74 7.1. Normative References . . . . . . . . . . . . . . . . . . 10 75 7.2. Informative References . . . . . . . . . . . . . . . . . 11 76 Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . 12 77 Open Issues . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 78 Document History . . . . . . . . . . . . . . . . . . . . . . . . 12 79 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 12 81 1. Introduction 83 This specification describes how a CBOR Web Token [CWT] can declare 84 that the presenter of the CWT possesses a particular proof-of- 85 possession (PoP) key and how the recipient can cryptographically 86 confirm proof of possession of the key by the presenter. Proof of 87 possession of a key is also sometimes described as the presenter 88 being a holder-of-key. This specification is a profile of "Proof-of- 89 Possession Key Semantics for JSON Web Tokens (JWTs)" [RFC7800], but 90 using CBOR [RFC7049] and CWTs [CWT] rather than JSON [RFC7159] and 91 JWTs [JWT]. 93 1.1. Notational Conventions 95 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 96 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 97 "OPTIONAL" in this document are to be interpreted as described in 98 [RFC2119]. 100 Unless otherwise noted, all the protocol parameter names and values 101 are case sensitive. 103 2. Terminology 105 This specification uses terms defined in the CBOR Web Token [CWT], 106 [I-D.ietf-cose-msg], and Concise Binary Object Representation (CBOR) 107 [RFC7049] specifications. 109 These terms are defined by this specification: 111 Issuer 112 Party that creates the CWT and binds the proof-of-possession key 113 to it. 115 Presenter 116 Party that proves possession of a private key (for asymmetric key 117 cryptography) or secret key (for symmetric key cryptography) to a 118 recipient. 120 Recipient 121 Party that receives the CWT containing the proof-of-possession key 122 information from the presenter. 124 3. Representations for Proof-of-Possession Keys 126 By including a "cnf" (confirmation) claim in a CWT, the issuer of the 127 CWT declares that the presenter possesses a particular key and that 128 the recipient can cryptographically confirm that the presenter has 129 possession of that key. The value of the "cnf" claim is a JSON 130 object and the members of that object identify the proof-of- 131 possession key. 133 The presenter can be identified in one of several ways by the CWT 134 depending upon the application requirements. If the CWT contains a 135 "sub" (subject) claim [CWT], the presenter is normally the subject 136 identified by the CWT. (In some applications, the subject identifier 137 will be relative to the issuer identified by the "iss" (issuer) claim 138 [CWT].) If the CWT contains no "sub" claim, the presenter is 139 normally the issuer identified by the CWT using the "iss" claim. The 140 case in which the presenter is the subject of the CWT is analogous to 141 Security Assertion Markup Language (SAML) 2.0 142 [OASIS.saml-core-2.0-os] SubjectConfirmation usage. At least one of 143 the "sub" and "iss" claims MUST be present in the CWT. Some use 144 cases may require that both be present. 146 3.1. Confirmation Claim 148 The "cnf" claim is used in the CWT to contain members used to 149 identify the proof-of-possession key. Other members of the "cnf" 150 object may be defined because a proof-of-possession key may not be 151 the only means of confirming the authenticity of the token. This is 152 analogous to the SAML 2.0 [OASIS.saml-core-2.0-os] 153 SubjectConfirmation element in which a number of different subject 154 confirmation methods can be included (including proof-of-possession 155 key information). 157 The set of confirmation members that a CWT must contain to be 158 considered valid is context dependent and is outside the scope of 159 this specification. Specific applications of CWTs will require 160 implementations to understand and process some confirmation members 161 in particular ways. However, in the absence of such requirements, 162 all confirmation members that are not understood by implementations 163 MUST be ignored. 165 This specification establishes the IANA "CWT Confirmation Methods" 166 registry for these members in Section 6.2 and registers the members 167 defined by this specification. Other specifications can register 168 other members used for confirmation, including other members for 169 conveying proof-of-possession keys using different key 170 representations. 172 The "cnf" claim value MUST represent only a single proof-of- 173 possession key; thus, at most one of the "COSE_Key" and 174 "Encrypted_COSE_Key" confirmation values defined below may be 175 present. Note that if an application needs to represent multiple 176 proof-of-possession keys in the same CWT, one way for it to achieve 177 this is to use other claim names, in addition to "cnf", to hold the 178 additional proof-of-possession key information. These claims could 179 use the same syntax and semantics as the "cnf" claim. Those claims 180 would be defined by applications or other specifications and could be 181 registered in the IANA "CBOR Web Token Claims" registry 182 [IANA.CWT.Claims]. 184 3.2. Representation of an Asymmetric Proof-of-Possession Key 186 When the key held by the presenter is an asymmetric private key, the 187 "COSE_Key" member is a COSE_Key [I-D.ietf-cose-msg] representing the 188 corresponding asymmetric public key. The following example 189 demonstrates such a declaration in the CWT Claims Set of a CWT: 191 { 192 "iss": "https://server.example.com", 193 "aud": "https://client.example.org", 194 "exp": 1361398824, 195 "cnf":{ 196 "COSE_Key":{ 197 "kty": "EC", 198 "crv": "P-256", 199 "x": "18wHLeIgW9wVN6VD1Txgpqy2LszYkMf6J8njVAibvhM", 200 "y": "-V4dS4UaLMgP_4fY4j8ir7cl1TXlFdAgcx55o7TkcSA" 201 } 202 } 203 } 205 The COSE_Key MUST contain the required key members for a COSE_Key of 206 that key type and MAY contain other COSE_Key members, including the 207 "kid" (Key ID) member. 209 The "COSE_Key" member MAY also be used for a COSE_Key representing a 210 symmetric key, provided that the CWT is encrypted so that the key is 211 not revealed to unintended parties. The means of encrypting a CWT is 212 explained in [CWT]. If the CWT is not encrypted, the symmetric key 213 MUST be encrypted as described below. 215 3.3. Representation of an Encrypted Symmetric Proof-of-Possession Key 217 When the key held by the presenter is a symmetric key, the 218 "Encrypted_COSE_Key" member is an encrypted COSE_Key 219 [I-D.ietf-cose-msg] representing the symmetric key encrypted to a key 220 known to the recipient using COSE_Encrypt or COSE_Encrypt0. 222 The following example illustrates a symmetric key that could 223 subsequently be encrypted for use in the "Encrypted_COSE_Key" member: 225 { 226 "kty": "oct", 227 "alg": "HS256", 228 "k": "ZoRSOrFzN_FzUA5XKMYoVHyzff5oRJxl-IXRtztJ6uE" 229 } 231 The COSE_Key representation is used as the plaintext when encrypting 232 the key. The COSE_Key could, for instance, be encrypted using a 233 COSE_Encrypt0 representation using the AES-CCM-16-64-128 algorithm. 235 The following example CWT Claims Set of a CWT illustrates the use of 236 an encrypted symmetric key as the "Encrypted_COSE_Key" member value: 238 { 239 "iss": "https://server.example.com", 240 "sub": "24400320", 241 "aud": "s6BhdRkqt3", 242 "exp": 1311281970, 243 "iat": 1311280970, 244 "cnf":{ 245 "Encrypted_COSE_Key": 246 "(TBD)" 247 } 248 } 250 3.4. Representation of a Key ID for a Proof-of-Possession Key 252 The proof-of-possession key can also be identified by the use of a 253 Key ID instead of communicating the actual key, provided the 254 recipient is able to obtain the identified key using the Key ID. In 255 this case, the issuer of a CWT declares that the presenter possesses 256 a particular key and that the recipient can cryptographically confirm 257 proof of possession of the key by the presenter by including a "cnf" 258 claim in the CWT whose value is a JSON object with the JSON object 259 containing a "kid" member identifying the key. 261 The following example demonstrates such a declaration in the CWT 262 Claims Set of a CWT: 264 { 265 "iss": "https://server.example.com", 266 "aud": "https://client.example.org", 267 "exp": 1361398824, 268 "cnf":{ 269 "kid": "dfd1aa97-6d8d-4575-a0fe-34b96de2bfad" 270 } 271 } 273 The content of the "kid" value is application specific. For 274 instance, some applications may choose to use a cryptographic hash of 275 the public key value as the "kid" value. 277 3.5. Specifics Intentionally Not Specified 279 Proof of possession is typically demonstrated by having the presenter 280 sign a value determined by the recipient using the key possessed by 281 the presenter. This value is sometimes called a "nonce" or a 282 "challenge". 284 The means of communicating the nonce and the nature of its contents 285 are intentionally not described in this specification, as different 286 protocols will communicate this information in different ways. 287 Likewise, the means of communicating the signed nonce is also not 288 specified, as this is also protocol specific. 290 Note that another means of proving possession of the key when it is a 291 symmetric key is to encrypt the key to the recipient. The means of 292 obtaining a key for the recipient is likewise protocol specific. 294 4. Security Considerations 296 All of the security considerations that are discussed in [CWT] also 297 apply here. In addition, proof of possession introduces its own 298 unique security issues. Possessing a key is only valuable if it is 299 kept secret. Appropriate means must be used to ensure that 300 unintended parties do not learn private key or symmetric key values. 302 Applications utilizing proof of possession should also utilize 303 audience restriction, as described in Section 4.1.3 of [JWT], as it 304 provides different protections. Proof of possession can be used by 305 recipients to reject messages from unauthorized senders. Audience 306 restriction can be used by recipients to reject messages intended for 307 different recipients. 309 A recipient might not understand the "cnf" claim. Applications that 310 require the proof-of-possession keys communicated with it to be 311 understood and processed must ensure that the parts of this 312 specification that they use are implemented. 314 Proof of possession via encrypted symmetric secrets is subject to 315 replay attacks. This attack can, for example, be avoided when a 316 signed nonce or challenge is used since the recipient can use a 317 distinct nonce or challenge for each interaction. Replay can also be 318 avoided if a sub-key is derived from a shared secret that is specific 319 to the instance of the PoP demonstration. 321 As is the case with other information included in a CWT, it is 322 necessary to apply data origin authentication and integrity 323 protection (via a keyed message digest or a digital signature). Data 324 origin authentication ensures that the recipient of the CWT learns 325 about the entity that created the CWT since this will be important 326 for any policy decisions. Integrity protection prevents an adversary 327 from changing any elements conveyed within the CWT payload. Special 328 care has to be applied when carrying symmetric keys inside the CWT 329 since those not only require integrity protection but also 330 confidentiality protection. 332 5. Privacy Considerations 334 A proof-of-possession key can be used as a correlation handle if the 335 same key is used with multiple parties. Thus, for privacy reasons, 336 it is recommended that different proof-of-possession keys be used 337 when interacting with different parties. 339 6. IANA Considerations 341 The following registration procedure is used for all the registries 342 established by this specification. 344 Values are registered on a Specification Required [RFC5226] basis 345 after a three-week review period on the cwt-reg-review@ietf.org 346 mailing list, on the advice of one or more Designated Experts. 347 However, to allow for the allocation of values prior to publication, 348 the Designated Experts may approve registration once they are 349 satisfied that such a specification will be published. [[ Note to 350 the RFC Editor: The name of the mailing list should be determined in 351 consultation with the IESG and IANA. Suggested name: cwt-reg- 352 review@ietf.org. ]] 354 Registration requests sent to the mailing list for review should use 355 an appropriate subject (e.g., "Request to Register CWT Confirmation 356 Method: example"). Registration requests that are undetermined for a 357 period longer than 21 days can be brought to the IESG's attention 358 (using the iesg@ietf.org mailing list) for resolution. 360 Criteria that should be applied by the Designated Experts include 361 determining whether the proposed registration duplicates existing 362 functionality, determining whether it is likely to be of general 363 applicability or whether it is useful only for a single application, 364 and evaluating the security properties of the item being registered 365 and whether the registration makes sense. 367 It is suggested that multiple Designated Experts be appointed who are 368 able to represent the perspectives of different applications using 369 this specification in order to enable broadly informed review of 370 registration decisions. In cases where a registration decision could 371 be perceived as creating a conflict of interest for a particular 372 Expert, that Expert should defer to the judgment of the other 373 Experts. 375 6.1. CBOR Web Token Claims Registration 377 This specification registers the "cnf" claim in the IANA "CBOR Web 378 Token Claims" registry [IANA.CWT.Claims] established by [CWT]. 380 6.1.1. Registry Contents 382 o Claim Name: "cnf" 383 o Claim Description: Confirmation 384 o JWT Claim Name: "cnf" 385 o CBOR Key Value: TBD (maybe 8) 386 o CBOR Major Type: 5 387 o Change Controller: IESG 388 o Specification Document(s): Section 3.1 of [[ this document ]] 390 6.2. CWT Confirmation Methods Registry 392 This specification establishes the IANA "CWT Confirmation Methods" 393 registry for CWT "cnf" member values. The registry records the 394 confirmation method member and a reference to the specification that 395 defines it. 397 6.2.1. Registration Template 399 Confirmation Method Name: 400 The human-readable name requested (e.g., "kid"). 402 Confirmation Method Description: 403 Brief description of the confirmation method (e.g., "Key 404 Identifier"). 406 JWT Conformation Method Name: 407 Claim Name of the equivalent JWT confirmation method value, as 408 registered in [IANA.JWT.Claims]. CWT claims should normally have 409 a corresponding JWT claim. If a corresponding JWT claim would not 410 make sense, the Designated Experts can choose to accept 411 registrations for which the JWT Claim Name is listed as "N/A". 413 CBOR Key Value: 414 Key value for the confirmation method. The key value MUST be an 415 integer in the range of 1 to 65536. 417 CBOR Major Type: 418 CBOR major type and, when applicable, minor type for the claim. 420 Change Controller: 421 For Standards Track RFCs, list the "IESG". For others, give the 422 name of the responsible party. Other details (e.g., postal 423 address, email address, home page URI) may also be included. 425 Specification Document(s): 426 Reference to the document or documents that specify the parameter, 427 preferably including URIs that can be used to retrieve copies of 428 the documents. An indication of the relevant sections may also be 429 included but is not required. 431 6.2.2. Initial Registry Contents 433 o Confirmation Method Name: "COSE_Key" 434 o Confirmation Method Description: COSE_Key Representing Public Key 435 o JWT Confirmation Method Name: "jwk" 436 o CBOR Key Value: 1 437 o CBOR Major Type: 5 438 o Change Controller: IESG 439 o Specification Document(s): Section 3.2 of [[ this document ]] 441 o Confirmation Method Name: "Encrypted_COSE_Key" 442 o Confirmation Method Description: Encrypted COSE_Key 443 o JWT Confirmation Method Name: "jwe" 444 o CBOR Key Value: 2 445 o CBOR Major Type: 4 (with an optional 6 tag prefix) 446 o Change Controller: IESG 447 o Specification Document(s): Section 3.3 of [[ this document ]] 449 o Confirmation Method Name: "kid" 450 o Confirmation Method Description: Key Identifier 451 o JWT Confirmation Method Name: "kid" 452 o CBOR Key Value: 3 453 o CBOR Major Type: 2 454 o Change Controller: IESG 455 o Specification Document(s): Section 3.4 of [[ this document ]] 457 7. References 459 7.1. Normative References 461 [CWT] Jones, M., Wahlstroem, E., Erdtman, S., and H. Tschofenig, 462 "CBOR Web Token (CWT)", Work in Progress, draft-ietf-ace- 463 cbor-web-token-04, April 2017, 464 . 467 [I-D.ietf-cose-msg] 468 Schaad, J., "CBOR Object Signing and Encryption (COSE)", 469 draft-ietf-cose-msg-24 (work in progress), November 2016. 471 [IANA.CWT.Claims] 472 IANA, "CBOR Web Token Claims", 473 . 475 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 476 Requirement Levels", BCP 14, RFC 2119, 477 DOI 10.17487/RFC2119, March 1997, 478 . 480 [RFC3629] Yergeau, F., "UTF-8, a transformation format of ISO 481 10646", STD 63, RFC 3629, DOI 10.17487/RFC3629, November 482 2003, . 484 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 485 Resource Identifier (URI): Generic Syntax", STD 66, 486 RFC 3986, DOI 10.17487/RFC3986, January 2005, 487 . 489 [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an 490 IANA Considerations Section in RFCs", BCP 26, RFC 5226, 491 DOI 10.17487/RFC5226, May 2008, 492 . 494 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 495 (TLS) Protocol Version 1.2", RFC 5246, 496 DOI 10.17487/RFC5246, August 2008, 497 . 499 [RFC6125] Saint-Andre, P. and J. Hodges, "Representation and 500 Verification of Domain-Based Application Service Identity 501 within Internet Public Key Infrastructure Using X.509 502 (PKIX) Certificates in the Context of Transport Layer 503 Security (TLS)", RFC 6125, DOI 10.17487/RFC6125, March 504 2011, . 506 [RFC7049] Bormann, C. and P. Hoffman, "Concise Binary Object 507 Representation (CBOR)", RFC 7049, DOI 10.17487/RFC7049, 508 October 2013, . 510 7.2. Informative References 512 [IANA.JWT.Claims] 513 IANA, "JSON Web Token Claims", 514 . 516 [JWT] Jones, M., Bradley, J., and N. Sakimura, "JSON Web Token 517 (JWT)", RFC 7519, DOI 10.17487/RFC7159, May 2015, 518 . 520 [OASIS.saml-core-2.0-os] 521 Cantor, S., Kemp, J., Philpott, R., and E. Maler, 522 "Assertions and Protocol for the OASIS Security Assertion 523 Markup Language (SAML) V2.0", OASIS Standard saml-core- 524 2.0-os, March 2005, 525 . 527 [RFC7159] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data 528 Interchange Format", RFC 7159, DOI 10.17487/RFC7159, March 529 2014, . 531 [RFC7800] Jones, M., Bradley, J., and H. Tschofenig, "Proof-of- 532 Possession Key Semantics for JSON Web Tokens (JWTs)", 533 RFC 7800, DOI 10.17487/RFC7800, April 2016, 534 . 536 Acknowledgements 538 TBD 540 Open Issues 542 o Convert the examples from JSON/JWT to CBOR/CWT. 544 Document History 546 [[ to be removed by the RFC Editor before publication as an RFC ]] 548 -00 550 o Created the initial draft from RFC 7800. 552 Author's Address 554 Michael B. Jones 555 Microsoft 557 Email: mbj@microsoft.com 558 URI: http://self-issued.info/