idnits 2.17.1 draft-ietf-tokbind-protocol-10.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 2 instances of too long lines in the document, the longest one being 4 characters in excess of 72. ** The abstract seems to contain references ([RFC5246]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (September 2, 2016) is 2786 days in the past. Is this intentional? -- Found something which looks like a code comment -- if you have code sections in the document, please surround them with '' and '' lines. 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 (-18) exists of draft-ietf-tokbind-https-06 == Outdated reference: A later version (-14) exists of draft-ietf-tokbind-negotiation-04 ** Obsolete normative reference: RFC 3447 (Obsoleted by RFC 8017) ** Obsolete normative reference: RFC 5226 (Obsoleted by RFC 8126) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 7230 (Obsoleted by RFC 9110, RFC 9112) ** Obsolete normative reference: RFC 7540 (Obsoleted by RFC 9113) Summary: 7 errors (**), 0 flaws (~~), 3 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Internet Engineering Task Force A. Popov, Ed. 3 Internet-Draft M. Nystroem 4 Intended status: Standards Track Microsoft Corp. 5 Expires: March 6, 2017 D. Balfanz 6 A. Langley 7 Google Inc. 8 J. Hodges 9 Paypal 10 September 2, 2016 12 The Token Binding Protocol Version 1.0 13 draft-ietf-tokbind-protocol-10 15 Abstract 17 This document specifies Version 1.0 of the Token Binding protocol. 18 The Token Binding protocol allows client/server applications to 19 create long-lived, uniquely identifiable TLS [RFC5246] bindings 20 spanning multiple TLS sessions and connections. Applications are 21 then enabled to cryptographically bind security tokens to the TLS 22 layer, preventing token export and replay attacks. To protect 23 privacy, the Token Binding identifiers are only transmitted encrypted 24 and can be reset by the user at any time. 26 Status of This Memo 28 This Internet-Draft is submitted in full conformance with the 29 provisions of BCP 78 and BCP 79. 31 Internet-Drafts are working documents of the Internet Engineering 32 Task Force (IETF). Note that other groups may also distribute 33 working documents as Internet-Drafts. The list of current Internet- 34 Drafts is at http://datatracker.ietf.org/drafts/current/. 36 Internet-Drafts are draft documents valid for a maximum of six months 37 and may be updated, replaced, or obsoleted by other documents at any 38 time. It is inappropriate to use Internet-Drafts as reference 39 material or to cite them other than as "work in progress." 41 This Internet-Draft will expire on March 6, 2017. 43 Copyright Notice 45 Copyright (c) 2016 IETF Trust and the persons identified as the 46 document authors. All rights reserved. 48 This document is subject to BCP 78 and the IETF Trust's Legal 49 Provisions Relating to IETF Documents 50 (http://trustee.ietf.org/license-info) in effect on the date of 51 publication of this document. Please review these documents 52 carefully, as they describe your rights and restrictions with respect 53 to this document. Code Components extracted from this document must 54 include Simplified BSD License text as described in Section 4.e of 55 the Trust Legal Provisions and are provided without warranty as 56 described in the Simplified BSD License. 58 Table of Contents 60 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 61 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 3 62 2. Token Binding Protocol Overview . . . . . . . . . . . . . . . 3 63 3. Token Binding Protocol Message . . . . . . . . . . . . . . . 4 64 3.1. TokenBinding.tokenbinding_type . . . . . . . . . . . . . 6 65 3.2. TokenBinding.tokenbindingid . . . . . . . . . . . . . . . 6 66 3.3. TokenBinding.signature . . . . . . . . . . . . . . . . . 7 67 3.4. TokenBinding.extensions . . . . . . . . . . . . . . . . . 8 68 4. Establishing a Token Binding . . . . . . . . . . . . . . . . 8 69 4.1. Client Processing Rules . . . . . . . . . . . . . . . . . 8 70 4.2. Server Processing Rules . . . . . . . . . . . . . . . . . 9 71 5. Bound Security Token Creation and Validation . . . . . . . . 9 72 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 10 73 6.1. Token Binding Key Parameters Registry . . . . . . . . . . 10 74 6.2. Token Binding Types Registry . . . . . . . . . . . . . . 11 75 6.3. Token Binding Extensions Registry . . . . . . . . . . . . 12 76 6.4. Registration of Token Binding TLS Exporter Label . . . . 12 77 7. Security Considerations . . . . . . . . . . . . . . . . . . . 12 78 7.1. Security Token Replay . . . . . . . . . . . . . . . . . . 12 79 7.2. Downgrade Attacks . . . . . . . . . . . . . . . . . . . . 13 80 7.3. Privacy Considerations . . . . . . . . . . . . . . . . . 13 81 7.4. Token Binding Key Sharing Between Applications . . . . . 14 82 7.5. Triple Handshake Vulnerability in TLS 1.2 and Older TLS 83 Versions . . . . . . . . . . . . . . . . . . . . . . . . 14 84 8. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 14 85 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 14 86 9.1. Normative References . . . . . . . . . . . . . . . . . . 14 87 9.2. Informative References . . . . . . . . . . . . . . . . . 16 88 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 16 90 1. Introduction 92 Servers generate various security tokens (e.g. HTTP cookies, OAuth 93 tokens) for applications to access protected resources. Any party in 94 possession of such token gains access to the protected resource. 95 Attackers export bearer tokens from the user's machine, present them 96 to the servers, and impersonate authenticated users. The idea of 97 Token Binding is to prevent such attacks by cryptographically binding 98 security tokens to the TLS layer. 100 A Token Binding is established by the user agent generating a 101 private-public key pair (possibly within a secure hardware module, 102 such as TPM) per target server, and proving possession of the private 103 key on every TLS connection to the target server. The proof of 104 possession involves signing the exported keying material [RFC5705] 105 for the TLS connection with the private key. The corresponding 106 public key is included in the Token Binding identifier structure 107 (described in the Section 3.2 "TokenBinding.tokenbindingid"). Token 108 Bindings are long-lived, i.e. they encompass multiple TLS connections 109 and TLS sessions between a given client and server. To protect 110 privacy, Token Binding IDs are never transmitted in clear text and 111 can be reset by the user at any time, e.g. when clearing browser 112 cookies. 114 When issuing a security token to a client that supports Token 115 Binding, a server includes the client's Token Binding ID in the 116 token. Later on, when a client presents a security token containing 117 a Token Binding ID, the server makes sure the ID in the token matches 118 the ID of the Token Binding established with the client. In the case 119 of a mismatch, the server discards the token. 121 In order to successfully export and replay a bound security token, 122 the attacker needs to also be able to export the client's private 123 key, which is hard to do in the case of the key generated in a secure 124 hardware module. 126 1.1. Requirements Language 128 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 129 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 130 document are to be interpreted as described in [RFC2119]. 132 2. Token Binding Protocol Overview 134 The client and server use the Token Binding Negotiation TLS Extension 135 [I-D.ietf-tokbind-negotiation] to negotiate the Token Binding 136 protocol version and the parameters (signature algorithm, length) of 137 the Token Binding key. This negotiation does not require additional 138 round-trips. 140 The Token Binding protocol consists of one message sent by the client 141 to the server, proving possession of one or more client-generated 142 asymmetric keys. This message is only sent if the client and server 143 agree on the use of the Token Binding protocol and the key 144 parameters. The Token Binding message is sent with the application 145 protocol data in TLS application_data records. 147 A server receiving the Token Binding message verifies that the key 148 parameters in the message match the Token Binding parameters 149 negotiated via [I-D.ietf-tokbind-negotiation], and then validates the 150 signatures contained in the Token Binding message. If either of 151 these checks fails, the server terminates the connection, otherwise 152 the Token Binding is successfully established with the ID contained 153 in the Token Binding message. 155 When a server supporting the Token Binding protocol receives a bound 156 token, the server compares the Token Binding ID in the security token 157 with the Token Binding ID established with the client. If the bound 158 token came from a TLS connection without a Token Binding, or if the 159 IDs don't match, the token is discarded. 161 This document defines the format of the Token Binding protocol 162 message, the process of establishing a Token Binding, the format of 163 the Token Binding ID, and the process of validating a security token. 164 Token Binding Negotiation TLS Extension 165 [I-D.ietf-tokbind-negotiation] describes the negotiation of the Token 166 Binding protocol and key parameters. Token Binding over HTTP 167 [I-D.ietf-tokbind-https] explains how the Token Binding message is 168 encapsulated within HTTP/1.1 [RFC7230] or HTTP/2 [RFC7540] messages. 169 [I-D.ietf-tokbind-https] also describes Token Binding between 170 multiple communicating parties: User Agent, Identity Provider and 171 Relying Party. 173 3. Token Binding Protocol Message 175 The Token Binding message is sent by the client to prove possession 176 of one or more private keys held by the client. This message MUST be 177 sent if the client and server successfully negotiated the use of the 178 Token Binding protocol via [I-D.ietf-tokbind-negotiation], and MUST 179 NOT be sent otherwise. This message MUST be sent in the client's 180 first application protocol message. This message MAY also be sent in 181 subsequent application protocol messages, proving possession of 182 additional private keys held by the same client, which can be used to 183 facilitate token binding between more than two communicating parties. 184 For example, Token Binding over HTTP [I-D.ietf-tokbind-https] 185 specifies an encapsulation of the Token Binding message in HTTP 186 application protocol messages, as well as scenarios involving more 187 than two communicating parties. 189 The Token Binding message format is defined using TLS Presentation 190 Language (see Section 4 of [RFC5246]): 192 enum { 193 rsa2048_pkcs1.5(0), rsa2048_pss(1), ecdsap256(2), (255) 194 } TokenBindingKeyParameters; 196 struct { 197 opaque modulus<1..2^16-1>; 198 opaque publicexponent<1..2^8-1>; 199 } RSAPublicKey; 201 struct { 202 opaque point <1..2^8-1>; 203 } ECPoint; 205 struct { 206 TokenBindingKeyParameters key_parameters; 207 uint16 key_length; /* Length (in bytes) of the following 208 TokenBindingID.TokenBindingPublicKey */ 209 select (key_parameters) { 210 case rsa2048_pkcs1.5: 211 case rsa2048_pss: 212 RSAPublicKey rsapubkey; 213 case ecdsap256: 214 ECPoint point; 215 } TokenBindingPublicKey; 216 } TokenBindingID; 218 enum { 219 (255) /* No initial ExtensionType registrations */ 220 } ExtensionType; 222 struct { 223 ExtensionType extension_type; 224 opaque extension_data<0..2^16-1>; 225 } Extension; 227 enum { 228 provided_token_binding(0), referred_token_binding(1), (255) 229 } TokenBindingType; 231 struct { 232 TokenBindingType tokenbinding_type; 233 TokenBindingID tokenbindingid; 234 opaque signature<0..2^16-1>; /* Signature over the concatenation of 235 tokenbinding_type, key_parameters and 236 exported keying material (EKM) */ 237 Extension extensions<0..2^16-1>; 238 } TokenBinding; 239 struct { 240 TokenBinding tokenbindings<0..2^16-1>; 241 } TokenBindingMessage; 243 The Token Binding message consists of a series of TokenBinding 244 structures, each containing the type of the token binding, the 245 TokenBindingID, a signature using the Token Binding key, optionally 246 followed by Extension structures. 248 3.1. TokenBinding.tokenbinding_type 250 This document defines two Token Binding types: 252 o provided_token_binding - used to establish a Token Binding when 253 connecting to a server. 255 o referred_token_binding - used when requesting tokens to be 256 presented to a different server. 258 Token Binding over HTTP [I-D.ietf-tokbind-https] describes a use case 259 for referred_token_binding where Token Bindings are established 260 between multiple communicating parties: User Agent, Identity Provider 261 and Relying Party. User Agent sends referred_token_binding to the 262 Identity Provider in order to prove possession of the Token Binding 263 key it uses with the Relying Party. The Identity Provider can then 264 bind the token it is supplying (for presentation to the Relying 265 Party) to the Token Binding ID contained in the 266 referred_token_binding. Such bound token enjoys the protections 267 discussed below in Section 7 "Security Considerations". 269 3.2. TokenBinding.tokenbindingid 271 The ID of the Token Binding established as a result of Token Binding 272 message processing contains the identifier of the key parameters 273 negotiated via [I-D.ietf-tokbind-negotiation], the length (in bytes) 274 of the Token Binding public key, and the Token Binding public key 275 itself. Token Binding ID can be obtained from the TokenBinding 276 structure by discarding the Token Binding type, signature and 277 extensions. 279 When rsa2048_pkcs1.5 or rsa2048_pss is used, RSAPublicKey.modulus and 280 RSAPublicKey.publicexponent contain the modulus and exponent of the 281 2048-bit RSA public key represented in big-endian format, with 282 leading zero bytes omitted. 284 When ecdsap256 is used, ECPoint.point contains the X coordinate 285 followed by the Y coordinate of the Curve P-256 key. The X and Y 286 coordinates are unsigned 32-byte integers encoded in big-endian 287 format, preserving any leading zero bytes. Future specifications may 288 define Token Binding keys using other elliptic curves with their 289 corresponding signature and point formats. 291 Token Binding protocol implementations SHOULD make Token Binding IDs 292 available to the application as opaque byte sequences. E.g. server 293 applications will use Token Binding IDs when generating and verifying 294 bound tokens. 296 3.3. TokenBinding.signature 298 When rsa2048_pkcs1.5 is used, TokenBinding.signature contains the 299 signature generated using the RSASSA-PKCS1-v1_5 signature scheme 300 defined in [RFC3447] with SHA256 as the hash function. 302 When rsa2048_pss is used, TokenBinding.signature contains the 303 signature generated using the RSASSA-PSS signature scheme defined in 304 [RFC3447] with SHA256 as the hash function. MGF1 with SHA256 MUST be 305 used as the mask generation function, and the salt length MUST equal 306 32 bytes. 308 When ecdsap256 is used, TokenBinding.signature contains a pair of 309 32-byte integers, R followed by S, generated with ECDSA using Curve 310 P-256 and SHA256 as defined in [ANSI.X9-62.2005] and 311 [FIPS.186-4.2013]. R and S are encoded in big-endian format, 312 preserving any leading zero bytes. 314 The signature is computed over the byte string representing the 315 concatenation of: 317 o TokenBindingType value contained in the 318 TokenBinding.tokenbinding_type field; 320 o TokenBindingKeyParameters value contained in the 321 TokenBindingID.key_parameters field; 323 o Exported keying material (EKM) value obtained from the current TLS 324 connection. 326 The EKM is obtained using the Keying Material Exporters for TLS 327 defined in [RFC5705], by supplying the following input values: 329 o Label: The ASCII string "EXPORTER-Token-Binding" with no 330 terminating NUL. 332 o Context value: NULL (no application context supplied). 334 o Length: 32 bytes. 336 3.4. TokenBinding.extensions 338 A Token Binding message may optionally contain a series of Extension 339 structures, each consisting of an extension_type and extension_data. 340 The structure and meaning of extension_data depends on the specific 341 extension_type. 343 Initially, no extension types are defined (see Section 6.3 344 "Token Binding Extensions Registry"). One of the possible uses of 345 extensions envisioned at the time of this writing is attestation: 346 cryptographic proof that allows the server to verify that the Token 347 Binding key is hardware-bound. The definitions of such Token Binding 348 protocol extensions are outside the scope of this specification. 350 An implementation MUST ignore any unknown Token Binding types. 352 4. Establishing a Token Binding 354 4.1. Client Processing Rules 356 The client MUST include at least one TokenBinding structure in the 357 Token Binding message. The key parameters used in the 358 provided_token_binding MUST match those negotiated with the server 359 via [I-D.ietf-tokbind-negotiation]. 361 The client SHOULD generate and store Token Binding keys in a secure 362 manner that prevents key export. In order to prevent cooperating 363 servers from linking user identities, different keys SHOULD be used 364 by the client for connections to different servers, according to the 365 token scoping rules of the application protocol. 367 When the client needs to send a referred_token_binding to the 368 Identity Provider, the client SHALL construct the referred 369 TokenBinding structure in the following manner: 371 o Set TokenBinding.tokenbinding_type to referred_token_binding. 373 o Set TokenBinding.tokenbindingid to the Token Binding ID used with 374 the Relying Party. 376 o Generate TokenBinding.signature, using the EKM value of the TLS 377 connection to the Identity Provider, the Token Binding key 378 established with the Relying Party and the signature algorithm 379 indicated by the associated key parameters. Note that these key 380 parameters may differ from the key parameters negotiated with the 381 Identity Provider. 383 Conveying referred Token Bindings in this fashion allows the Identity 384 Provider to verify that the client controls the Token Binding key 385 used with the Relying Party. 387 4.2. Server Processing Rules 389 The triple handshake vulnerability in TLS 1.2 and older TLS versions 390 affects the security of the Token Binding protocol, as described in 391 Section 7 "Security Considerations". Therefore, the server MUST NOT 392 negotiate the use of the Token Binding protocol with these TLS 393 versions, unless the server also negotiates the Extended Master 394 Secret [RFC7627] TLS extension. In addition, the server MUST NOT 395 initiate or allow TLS renegotiation, unless the Renegotiation 396 Indication [RFC5746] TLS extension has been negotiated. 398 The server MUST terminate the connection if the use of the Token 399 Binding protocol was not negotiated, but the client sends the Token 400 Binding message. If the Token Binding type is 401 "provided_token_binding", the server MUST verify that the signature 402 algorithm (including elliptic curve in the case of ECDSA) and key 403 length in the Token Binding message match those negotiated via 404 [I-D.ietf-tokbind-negotiation]. In the case of a mismatch, the 405 server MUST terminate the connection. Token Bindings of type 406 "referred_token_binding" may use different key parameters than those 407 negotiated with this client. 409 If the Token Binding message does not contain at least one 410 TokenBinding structure, or if a signature contained in any 411 TokenBinding structure is invalid, the server MUST terminate the 412 connection. 414 Servers MUST ignore any unknown extensions. Initially, no extension 415 types are defined (see Section 6.3 416 "Token Binding Extensions Registry"). 418 If all checks defined above have passed successfully, the Token 419 Binding between this client and server is established. The Token 420 Binding ID(s) conveyed in the Token Binding Message can be provided 421 to the server-side application. The application may then use the 422 Token Binding IDs for bound security token creation and validation, 423 see Section 5. 425 5. Bound Security Token Creation and Validation 427 Security tokens can be bound to the TLS layer either by embedding the 428 Token Binding ID in the token, or by maintaining a database mapping 429 tokens to Token Binding IDs. The specific method of generating bound 430 security tokens is application-defined and beyond the scope of this 431 document. Note that applicable security considerations are outlined 432 in Section 7. 434 Either or both clients and servers MAY create bound security tokens. 435 For example, HTTPS servers employing Token Binding for securing their 436 HTTP cookies will bind the cookies. In the case of a server- 437 initiated challenge-response protocol employing Token Binding and 438 TLS, the client can, for example, incorporate the Token Binding ID 439 within the signed object it returns, thus binding the object. 441 Upon receipt of a security token, the server attempts to retrieve 442 Token Binding ID information from the token and from the TLS 443 connection with the client. Application-provided policy determines 444 whether to honor non-bound (bearer) tokens. If the token is bound 445 and a Token Binding has not been established for the client 446 connection, the server MUST discard the token. If the Token Binding 447 ID for the token does not match the Token Binding ID established for 448 the client connection, the server MUST discard the token. 450 6. IANA Considerations 452 This section establishes three IANA registries: "Token Binding Key 453 Parameters", "Token Binding Types" and "Token Binding Extensions". 454 It also registers a new TLS exporter label in the TLS Exporter Label 455 Registry. 457 6.1. Token Binding Key Parameters Registry 459 This document establishes a registry for identifiers of Token Binding 460 key parameters entitled "Token Binding Key Parameters" under the 461 "Token Binding Protocol" heading. 463 Entries in this registry require the following fields: 465 o Value: The octet value that identifies a set of Token Binding key 466 parameters (0-255). 468 o Description: The description of the Token Binding key parameters. 470 o Specification: A reference to a specification that defines the 471 Token Binding key parameters. 473 This registry operates under the "Expert Review" policy as defined in 474 [RFC5226]. The designated expert is advised to encourage the 475 inclusion of a reference to a permanent and readily available 476 specification that enables the creation of interoperable 477 implementations using the identified set of Token Binding key 478 parameters. 480 An initial set of registrations for this registry follows: 482 Value: 0 484 Description: rsa2048_pkcs1.5 486 Specification: this document 488 Value: 1 490 Description: rsa2048_pss 492 Specification: this document 494 Value: 2 496 Description: ecdsap256 498 Specification: this document 500 6.2. Token Binding Types Registry 502 This document establishes a registry for Token Binding type 503 identifiers entitled "Token Binding Types" under the "Token Binding 504 Protocol" heading. 506 Entries in this registry require the following fields: 508 o Value: The octet value that identifies the Token Binding type 509 (0-255). 511 o Description: The description of the Token Binding type. 513 o Specification: A reference to a specification that defines the 514 Token Binding type. 516 This registry operates under the "Expert Review" policy as defined in 517 [RFC5226]. The designated expert is advised to encourage the 518 inclusion of a reference to a permanent and readily available 519 specification that enables the creation of interoperable 520 implementations using the identified Token Binding type. 522 An initial set of registrations for this registry follows: 524 Value: 0 526 Description: provided_token_binding 527 Specification: this document 529 Value: 1 531 Description: referred_token_binding 533 Specification: this document 535 6.3. Token Binding Extensions Registry 537 This document establishes a registry for Token Binding extensions 538 entitled "Token Binding Extensions" under the "Token Binding 539 Protocol" heading. 541 Entries in this registry require the following fields: 543 o Value: The octet value that identifies the Token Binding extension 544 (0-255). 546 o Description: The description of the Token Binding extension. 548 o Specification: A reference to a specification that defines the 549 Token Binding extension. 551 This registry operates under the "Expert Review" policy as defined in 552 [RFC5226]. The designated expert is advised to encourage the 553 inclusion of a reference to a permanent and readily available 554 specification that enables the creation of interoperable 555 implementations using the identified Token Binding extension. This 556 document creates no initial registrations in the "Token Binding 557 Extensions" registry. 559 6.4. Registration of Token Binding TLS Exporter Label 561 This document adds a registration for the "EXPORTER-Token-Binding" 562 value in the TLS Exporter Label Registry to correspond to this 563 specification. 565 7. Security Considerations 567 7.1. Security Token Replay 569 The goal of the Token Binding protocol is to prevent attackers from 570 exporting and replaying security tokens, thereby impersonating 571 legitimate users and gaining access to protected resources. Bound 572 tokens can still be replayed by the malware present in the User 573 Agent. In order to export the token to another machine and 574 successfully replay it, the attacker also needs to export the 575 corresponding private key. Token Binding private keys are therefore 576 high-value assets and SHOULD be strongly protected, ideally by 577 generating them in a hardware security module that prevents key 578 export. 580 The manner in which a token is bound to the TLS layer is application- 581 defined and beyond the scope of this document. However, the 582 resulting bound token needs to be integrity-protected, so that an 583 attacker cannot remove the binding or substitute a Token Binding ID 584 of their choice without detection. 586 7.2. Downgrade Attacks 588 The Token Binding protocol is only used when negotiated via 589 [I-D.ietf-tokbind-negotiation] within the TLS handshake. TLS 590 prevents active attackers from modifying the messages of the TLS 591 handshake, therefore it is not possible for the attacker to remove or 592 modify the Token Binding Negotiation TLS Extension used to negotiate 593 the Token Binding protocol and key parameters. The signature 594 algorithm and key length used in the TokenBinding of type 595 "provided_token_binding" MUST match the parameters negotiated via 596 [I-D.ietf-tokbind-negotiation]. 598 7.3. Privacy Considerations 600 The Token Binding protocol uses persistent, long-lived Token Binding 601 IDs. To protect privacy, Token Binding IDs are never transmitted in 602 clear text and can be reset by the user at any time, e.g. when 603 clearing browser cookies. Some applications offer a special privacy 604 mode where they don't store or use tokens supplied by the server, 605 e.g. "in private" browsing. When operating in this special privacy 606 mode, applications SHOULD use newly generated Token Binding keys and 607 delete them when exiting this mode, or else SHOULD NOT negotiate 608 Token Binding at all. 610 In order to prevent cooperating servers from linking user identities, 611 different keys MUST be used by the client for connections to 612 different servers, according to the token scoping rules of the 613 application protocol. 615 A server can use tokens and Token Binding IDs to track clients. 616 Client applications that automatically limit the lifetime or scope of 617 tokens to maintain user privacy SHOULD apply the same validity time 618 and scope limits to Token Binding keys. 620 7.4. Token Binding Key Sharing Between Applications 622 Existing systems provide a variety of platform-specific mechanisms 623 for certain applications to share tokens, e.g. to enable single sign- 624 on scenarios. For these scenarios to keep working with bound tokens, 625 the applications that are allowed to share tokens will need to also 626 share Token Binding keys. Care must be taken to restrict the sharing 627 of Token Binding keys to the same group(s) of applications that share 628 the same tokens. 630 7.5. Triple Handshake Vulnerability in TLS 1.2 and Older TLS Versions 632 The Token Binding protocol relies on the exported keying material 633 (EKM) to associate a TLS connection with a Token Binding. The triple 634 handshake attack [TRIPLE-HS] is a known vulnerability in TLS 1.2 and 635 older TLS versions, allowing the attacker to synchronize keying 636 material between TLS connections. The attacker can then successfully 637 replay bound tokens. For this reason, the Token Binding protocol 638 MUST NOT be negotiated with these TLS versions, unless the Extended 639 Master Secret [RFC7627] TLS extension has also been negotiated. In 640 addition, TLS renegotiation MUST NOT be initiated or allowed, unless 641 the Renegotiation Indication [RFC5746] TLS extension has been 642 negotiated. 644 8. Acknowledgements 646 This document incorporates comments and suggestions offered by Eric 647 Rescorla, Gabriel Montenegro, Martin Thomson, Vinod Anupam, Anthony 648 Nadalin, Michael B. Jones, Bill Cox, Nick Harper, Brian Campbell, 649 and others. 651 9. References 653 9.1. Normative References 655 [ANSI.X9-62.2005] 656 American National Standards Institute, "Public Key 657 Cryptography for the Financial Services Industry, The 658 Elliptic Curve Digital Signature Algorithm (ECDSA)", 659 ANSI X9.62, 2005. 661 [FIPS.186-4.2013] 662 National Institute of Standards and Technology, "Digital 663 Signature Standard (DSS)", FIPS 186-4, 2013. 665 [I-D.ietf-tokbind-https] 666 Popov, A., Nystrom, M., Balfanz, D., Langley, A., and J. 667 Hodges, "Token Binding over HTTP", draft-ietf-tokbind- 668 https-06 (work in progress), August 2016. 670 [I-D.ietf-tokbind-negotiation] 671 Popov, A., Nystrom, M., Balfanz, D., and A. Langley, 672 "Transport Layer Security (TLS) Extension for Token 673 Binding Protocol Negotiation", draft-ietf-tokbind- 674 negotiation-04 (work in progress), August 2016. 676 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 677 Requirement Levels", BCP 14, RFC 2119, 678 DOI 10.17487/RFC2119, March 1997, 679 . 681 [RFC3447] Jonsson, J. and B. Kaliski, "Public-Key Cryptography 682 Standards (PKCS) #1: RSA Cryptography Specifications 683 Version 2.1", RFC 3447, DOI 10.17487/RFC3447, February 684 2003, . 686 [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an 687 IANA Considerations Section in RFCs", BCP 26, RFC 5226, 688 DOI 10.17487/RFC5226, May 2008, 689 . 691 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 692 (TLS) Protocol Version 1.2", RFC 5246, 693 DOI 10.17487/RFC5246, August 2008, 694 . 696 [RFC5705] Rescorla, E., "Keying Material Exporters for Transport 697 Layer Security (TLS)", RFC 5705, DOI 10.17487/RFC5705, 698 March 2010, . 700 [RFC5746] Rescorla, E., Ray, M., Dispensa, S., and N. Oskov, 701 "Transport Layer Security (TLS) Renegotiation Indication 702 Extension", RFC 5746, DOI 10.17487/RFC5746, February 2010, 703 . 705 [RFC7230] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer 706 Protocol (HTTP/1.1): Message Syntax and Routing", 707 RFC 7230, DOI 10.17487/RFC7230, June 2014, 708 . 710 [RFC7540] Belshe, M., Peon, R., and M. Thomson, Ed., "Hypertext 711 Transfer Protocol Version 2 (HTTP/2)", RFC 7540, 712 DOI 10.17487/RFC7540, May 2015, 713 . 715 [RFC7627] Bhargavan, K., Ed., Delignat-Lavaud, A., Pironti, A., 716 Langley, A., and M. Ray, "Transport Layer Security (TLS) 717 Session Hash and Extended Master Secret Extension", 718 RFC 7627, DOI 10.17487/RFC7627, September 2015, 719 . 721 9.2. Informative References 723 [TRIPLE-HS] 724 Bhargavan, K., Delignat-Lavaud, A., Fournet, C., Pironti, 725 A., and P. Strub, "Triple Handshakes and Cookie Cutters: 726 Breaking and Fixing Authentication over TLS. IEEE 727 Symposium on Security and Privacy", 2014. 729 Authors' Addresses 731 Andrei Popov (editor) 732 Microsoft Corp. 733 USA 735 Email: andreipo@microsoft.com 737 Magnus Nystroem 738 Microsoft Corp. 739 USA 741 Email: mnystrom@microsoft.com 743 Dirk Balfanz 744 Google Inc. 745 USA 747 Email: balfanz@google.com 749 Adam Langley 750 Google Inc. 751 USA 753 Email: agl@google.com 754 Jeff Hodges 755 Paypal 756 USA 758 Email: Jeff.Hodges@paypal.com