idnits 2.17.1 draft-ietf-tls-rfc4366-bis-04.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** The document seems to lack a License Notice according IETF Trust Provisions of 28 Dec 2009, Section 6.b.i or Provisions of 12 Sep 2009 Section 6.b -- however, there's a paragraph with a matching beginning. Boilerplate error? (You're using the IETF Trust Provisions' Section 6.b License Notice from 12 Feb 2009 rather than one of the newer Notices. See https://trustee.ietf.org/license-info/.) 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 : ---------------------------------------------------------------------------- ** The abstract seems to contain references ([RFC5246]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. == The 'Obsoletes: ' line in the draft header should list only the _numbers_ of the RFCs which will be obsoleted by this document (if approved); it should not include the word 'RFC' in the list. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 574 has weird spacing: '...ensions reque...' -- The document seems to contain a disclaimer for pre-RFC5378 work, and may have content which was first submitted before 10 November 2008. The disclaimer is necessary when there are original authors that you have been unable to contact, or if some do not wish to grant the BCP78 rights to the IETF Trust. If you are able to get all authors (current and original) to grant those rights, you can and should remove the disclaimer; otherwise, the disclaimer is needed and you can ignore this comment. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (April 20, 2009) is 5456 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) -- Looks like a reference, but probably isn't: '20' on line 359 ** Downref: Normative reference to an Informational RFC: RFC 2104 ** Obsolete normative reference: RFC 2560 (Obsoleted by RFC 6960) ** Obsolete normative reference: RFC 2616 (Obsoleted by RFC 7230, RFC 7231, RFC 7232, RFC 7233, RFC 7234, RFC 7235) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) -- Obsolete informational reference (is this intentional?): RFC 2246 (Obsoleted by RFC 4346) -- Obsolete informational reference (is this intentional?): RFC 3268 (Obsoleted by RFC 5246) -- Obsolete informational reference (is this intentional?): RFC 4346 (Obsoleted by RFC 5246) -- Obsolete informational reference (is this intentional?): RFC 4366 (Obsoleted by RFC 5246, RFC 6066) Summary: 6 errors (**), 0 flaws (~~), 3 warnings (==), 8 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 TLS Working Group Donald Eastlake 3rd 2 INTERNET-DRAFT Stellar Switches 3 Obsoletes: RFC 4366 4 Intended status: Proposed Standard 5 Expires: October 19, 2009 April 20, 2009 7 Transport Layer Security (TLS) Extensions: Extension Definitions 8 10 Status of This Document 12 This Internet-Draft is submitted to IETF in full conformance with the 13 provisions of BCP 78 and BCP 79. This document may contain material 14 from IETF Documents or IETF Contributions published or made publicly 15 available before November 10, 2008. The person(s) controlling the 16 copyright in some of this material may not have granted the IETF 17 Trust the right to allow modifications of such material outside the 18 IETF Standards Process. Without obtaining an adequate license from 19 the person(s) controlling the copyright in such materials, this 20 document may not be modified outside the IETF Standards Process, and 21 derivative works of it may not be created outside the IETF Standards 22 Process, except to format it for publication as an RFC or to 23 translate it into languages other than English. 25 Distribution of this document is unlimited. Comments should be sent 26 to the TLS working group mailing list . 28 Internet-Drafts are working documents of the Internet Engineering 29 Task Force (IETF), its areas, and its working groups. Note that 30 other groups may also distribute working documents as Internet- 31 Drafts. 33 Internet-Drafts are draft documents valid for a maximum of six months 34 and may be updated, replaced, or obsoleted by other documents at any 35 time. It is inappropriate to use Internet-Drafts as reference 36 material or to cite them other than as "work in progress." 38 The list of current Internet-Drafts can be accessed at 39 http://www.ietf.org/1id-abstracts.html 41 The list of Internet-Draft Shadow Directories can be accessed at 42 http://www.ietf.org/shadow.html 44 Abstract 46 This document provides specifications for existing TLS extensions. It 47 is a companion document for the TLS 1.2 specification [RFC5246]. The 48 extensions specified are server_name, max_fragment_length, 49 client_certificate_url, trusted_ca_keys, truncated_hmac, and 50 status_request. 52 Acknowledgements 54 This draft is based on material from RFC 4366 for which the authors 55 were S. Blake-Wilson, M. Nystron, D. Hopwood, J. Mikkelsen, and T. 56 Wright. 58 Table of Contents 60 Status of This Document....................................1 61 Abstract...................................................1 62 Acknowledgements...........................................2 64 1. Introduction............................................3 65 1.1 Specific Extensions Covered............................3 66 1.2 Conventions Used in This Document......................4 67 2. Extensions to the Handshake Protocol....................5 68 3. Server Name Indication..................................6 69 4. Maximum Fragment Length Negotiation.....................8 70 5. Client Certificate URLs................................10 71 6. Trusted CA Indication..................................13 72 7. Truncated HMAC.........................................15 73 8. Certificate Status Request.............................16 74 9. Error Alerts...........................................18 75 10. IANA Considerations...................................19 76 11. Security Considerations...............................19 77 11.1 Security Considerations for server_name..............19 78 11.2 Security Considerations for max_fragment_length......19 79 11.3 Security Considerations for client_certificate_url...20 80 11.4 Security Considerations for trusted_ca_keys..........21 81 11.5 Security Considerations for truncated_hmac...........21 82 11.6 Security Considerations for status_request...........22 83 12. Normative References..................................23 84 13. Informative References................................23 86 Annex A: pkipath MIME Type Registration...................25 87 Author's Address..........................................27 88 Copyright and IPR Provisions..............................28 90 1. Introduction 92 The TLS (Transport Layer Security) Protocol Version 1.2 is specified 93 in [RFC5246]. That specification includes the framework for 94 extensions to TLS, considerations in designing such extensions (see 95 Section 7.4.1.4 of [RFC5246]), and IANA Considerations for the 96 allocation of new extension code points; however, it does not specify 97 any particular extensions other than Signature Algorithms (see 98 Section 7.4.1.4.1 of [RFC5246]). 100 This document provides the specifications for existing TLS 101 extensions. It is, for the most part, the adaptation and editing of 102 material from [RFC4366], which covered TLS extensions for TLS 1.0 103 [RFC2246] and TLS 1.1 [RFC4346]. 105 1.1 Specific Extensions Covered 107 The extensions described here focus on extending the functionality 108 provided by the TLS protocol message formats. Other issues, such as 109 the addition of new cipher suites, are deferred. 111 The extension types defined in this document are: 113 enum { 114 server_name(0), max_fragment_length(1), 115 client_certificate_url(2), trusted_ca_keys(3), 116 truncated_hmac(4), status_request(5), (65535) 117 } ExtensionType; 119 Specifically, the extensions described in this document: 121 - Allow TLS clients to provide to the TLS server the name of the 122 server they are contacting. This functionality is desirable in 123 order to facilitate secure connections to servers that host 124 multiple 'virtual' servers at a single underlying network address. 126 - Allow TLS clients and servers to negotiate the maximum fragment 127 length to be sent. This functionality is desirable as a result of 128 memory constraints among some clients, and bandwidth constraints 129 among some access networks. 131 - Allow TLS clients and servers to negotiate the use of client 132 certificate URLs. This functionality is desirable in order to 133 conserve memory on constrained clients. 135 - Allow TLS clients to indicate to TLS servers which CA root keys 136 they possess. This functionality is desirable in order to prevent 137 multiple handshake failures involving TLS clients that are only 138 able to store a small number of CA root keys due to memory 139 limitations. 141 - Allow TLS clients and servers to negotiate the use of truncated 142 MACs. This functionality is desirable in order to conserve 143 bandwidth in constrained access networks. 145 - Allow TLS clients and servers to negotiate that the server sends 146 the client certificate status information (e.g., an Online 147 Certificate Status Protocol (OCSP) [RFC2560] response) during a 148 TLS handshake. This functionality is desirable in order to avoid 149 sending a Certificate Revocation List (CRL) over a constrained 150 access network and therefore save bandwidth. 152 TLS clients and servers may use the extensions described in this 153 document. The extensions are designed to be backwards compatible, 154 meaning that TLS clients that support the extensions can talk to TLS 155 servers that do not support the extensions, and vice versa. 157 1.2 Conventions Used in This Document 159 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 160 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 161 document are to be interpreted as described in [RFC2119]. 163 2. Extensions to the Handshake Protocol 165 This document specifies the use of two new handshake messages, 166 "CertificateURL" and "CertificateStatus". These messages are 167 described in Section 5 and Section 8, respectively. The new 168 handshake message structure therefore becomes: 170 enum { 171 hello_request(0), client_hello(1), server_hello(2), 172 certificate(11), server_key_exchange (12), 173 certificate_request(13), server_hello_done(14), 174 certificate_verify(15), client_key_exchange(16), 175 finished(20), certificate_url(21), certificate_status(22), 176 (255) 177 } HandshakeType; 179 struct { 180 HandshakeType msg_type; /* handshake type */ 181 uint24 length; /* bytes in message */ 182 select (HandshakeType) { 183 case hello_request: HelloRequest; 184 case client_hello: ClientHello; 185 case server_hello: ServerHello; 186 case certificate: Certificate; 187 case server_key_exchange: ServerKeyExchange; 188 case certificate_request: CertificateRequest; 189 case server_hello_done: ServerHelloDone; 190 case certificate_verify: CertificateVerify; 191 case client_key_exchange: ClientKeyExchange; 192 case finished: Finished; 193 case certificate_url: CertificateURL; 194 case certificate_status: CertificateStatus; 195 } body; 196 } Handshake; 198 3. Server Name Indication 200 TLS does not provide a mechanism for a client to tell a server the 201 name of the server it is contacting. It may be desirable for clients 202 to provide this information to facilitate secure connections to 203 servers that host multiple 'virtual' servers at a single underlying 204 network address. 206 In order to provide the server name, clients MAY include an extension 207 of type "server_name" in the (extended) client hello. The 208 "extension_data" field of this extension SHALL contain 209 "ServerNameList" where: 211 struct { 212 NameType name_type; 213 select (name_type) { 214 case host_name: HostName; 215 } name; 216 } ServerName; 218 enum { 219 host_name(0), (255) 220 } NameType; 222 opaque HostName<1..2^16-1>; 224 struct { 225 ServerName server_name_list<1..2^16-1> 226 } ServerNameList; 228 If the server understood the client hello extension but does not 229 recognize any of the server names, it SHOULD send an 230 unrecognized_name(112) alert (which MAY be fatal). 232 Currently, the only server names supported are DNS hostnames; 233 however, this does not imply any dependency of TLS on DNS, and other 234 name types may be added in the future (by an RFC that updates this 235 document). TLS MAY treat provided server names as opaque data and 236 pass the names and types to the application. 238 "HostName" contains the fully qualified DNS hostname of the server, 239 as understood by the client. The hostname is represented as a byte 240 string using ASCII encoding without a trailing dot. 242 Literal IPv4 and IPv6 addresses are not permitted in "HostName". 244 It is RECOMMENDED that clients include an extension of type 245 "server_name" in the client hello whenever they locate a server by a 246 supported name type. 248 A server that receives a client hello containing the "server_name" 249 extension MAY use the information contained in the extension to guide 250 its selection of an appropriate certificate to return to the client, 251 and/or other aspects of security policy. In this event, the server 252 SHALL include an extension of type "server_name" in the (extended) 253 server hello. The "extension_data" field of this extension SHALL be 254 empty. 256 If an application negotiates a server name using an application 257 protocol and then upgrades to TLS, and if a server_name extension is 258 sent, then the extension SHOULD contain the same name that was 259 negotiated in the application protocol. If the server_name is 260 established in the TLS session handshake, the client SHOULD NOT 261 attempt to request a different server name at the application layer. 263 4. Maximum Fragment Length Negotiation 265 Without this extension, TLS specifies a fixed maximum plaintext 266 fragment length of 2^14 bytes. It may be desirable for constrained 267 clients to negotiate a smaller maximum fragment length due to memory 268 limitations or bandwidth limitations. 270 In order to negotiate smaller maximum fragment lengths, clients MAY 271 include an extension of type "max_fragment_length" in the (extended) 272 client hello. The "extension_data" field of this extension SHALL 273 contain: 275 enum{ 276 2^9(1), 2^10(2), 2^11(3), 2^12(4), (255) 277 } MaxFragmentLength; 279 whose value is the desired maximum fragment length. The allowed 280 values for this field are: 2^9, 2^10, 2^11, and 2^12. 282 Servers that receive an extended client hello containing a 283 "max_fragment_length" extension MAY accept the requested maximum 284 fragment length by including an extension of type 285 "max_fragment_length" in the (extended) server hello. The 286 "extension_data" field of this extension SHALL contain a 287 "MaxFragmentLength" whose value is the same as the requested maximum 288 fragment length. 290 If a server receives a maximum fragment length negotiation request 291 for a value other than the allowed values, it MUST abort the 292 handshake with an "illegal_parameter" alert. Similarly, if a client 293 receives a maximum fragment length negotiation response that differs 294 from the length it requested, it MUST also abort the handshake with 295 an "illegal_parameter" alert. 297 Once a maximum fragment length other than 2^14 has been successfully 298 negotiated, the client and server MUST immediately begin fragmenting 299 messages (including handshake messages), to ensure that no fragment 300 larger than the negotiated length is sent. Note that TLS already 301 requires clients and servers to support fragmentation of handshake 302 messages. 304 The negotiated length applies for the duration of the session 305 including session resumptions. 307 The negotiated length limits the input that the record layer may 308 process without fragmentation (that is, the maximum value of 309 TLSPlaintext.length; see [RFC5246], Section 6.2.1). Note that the 310 output of the record layer may be larger. For example, if the 311 negotiated length is 2^9=512, then for currently defined cipher 312 suites (those defined in [RFC5246], [RFC2712], and [RFC3268]), and 313 when null compression is used, the record layer output can be at most 314 805 bytes: 5 bytes of headers, 512 bytes of application data, 256 315 bytes of padding, and 32 bytes of MAC. This means that in this event 316 a TLS record layer peer receiving a TLS record layer message larger 317 than 805 bytes may discard the message and send a "record_overflow" 318 alert, without decrypting the message. 320 5. Client Certificate URLs 322 Without this extension, TLS specifies that when client authentication 323 is performed, client certificates are sent by clients to servers 324 during the TLS handshake. It may be desirable for constrained clients 325 to send certificate URLs in place of certificates, so that they do 326 not need to store their certificates and can therefore save memory. 328 In order to negotiate sending certificate URLs to a server, clients 329 MAY include an extension of type "client_certificate_url" in the 330 (extended) client hello. The "extension_data" field of this extension 331 SHALL be empty. 333 (Note that it is necessary to negotiate use of client certificate 334 URLs in order to avoid "breaking" existing TLS servers.) 336 Servers that receive an extended client hello containing a 337 "client_certificate_url" extension MAY indicate that they are willing 338 to accept certificate URLs by including an extension of type 339 "client_certificate_url" in the (extended) server hello. The 340 "extension_data" field of this extension SHALL be empty. 342 After negotiation of the use of client certificate URLs has been 343 successfully completed (by exchanging hellos including 344 "client_certificate_url" extensions), clients MAY send a 345 "CertificateURL" message in place of a "Certificate" message as 346 follows (see also Section 2): 348 enum { 349 individual_certs(0), pkipath(1), (255) 350 } CertChainType; 352 struct { 353 CertChainType type; 354 URLAndHash url_and_hash_list<1..2^16-1>; 355 } CertificateURL; 357 struct { 358 opaque url<1..2^16-1>; 359 opaque SHA1Hash[20]; 360 } URLAndHash; 362 Here "url_and_hash_list" contains a sequence of URLs and hashes. 363 Each "url" MUST be an absolute URI reference according to [RFC3986] 364 that can be immediately used to fetch the certificate(s). 366 When X.509 certificates are used, there are two possibilities: 368 - If CertificateURL.type is "individual_certs", each URL refers to a 369 single DER-encoded X.509v3 certificate, with the URL for the client's 370 certificate first. 372 - If CertificateURL.type is "pkipath", the list contains a single 373 URL referring to a DER-encoded certificate chain, using the type 374 PkiPath described in Annex A. 376 When any other certificate format is used, the specification that 377 describes use of that format in TLS should define the encoding format 378 of certificates or certificate chains, and any constraint on their 379 ordering. 381 The hash corresponding to each URL is the SHA-1 hash of the 382 certificate or certificate chain (in the case of X.509 certificates, 383 the DER-encoded certificate or the DER-encoded PkiPath). 385 Note that when a list of URLs for X.509 certificates is used, the 386 ordering of URLs is the same as that used in the TLS Certificate 387 message (see [RFC5246], Section 7.4.2), but opposite to the order in 388 which certificates are encoded in PkiPath. In either case, the self- 389 signed root certificate MAY be omitted from the chain, under the 390 assumption that the server must already possess it in order to 391 validate it. 393 Servers receiving "CertificateURL" SHALL attempt to retrieve the 394 client's certificate chain from the URLs and then process the 395 certificate chain as usual. A cached copy of the content of any URL 396 in the chain MAY be used, provided that the SHA-1 hash matches the 397 hash of the cached copy. 399 Servers that support this extension MUST support the 'http' URI 400 scheme for certificate URLs, and MAY support other schemes. Use of 401 other schemes than 'http', 'https', or 'ftp' may create unexpected 402 problems. 404 If the protocol used is HTTP, then the HTTP server can be configured 405 to use the Cache-Control and Expires directives described in 406 [RFC2616] to specify whether and for how long certificates or 407 certificate chains should be cached. 409 The TLS server is not required to follow HTTP redirects when 410 retrieving the certificates or certificate chain. The URLs used in 411 this extension SHOULD therefore be chosen not to depend on such 412 redirects. 414 If the protocol used to retrieve certificates or certificate chains 415 returns a MIME-formatted response (as HTTP does), then the following 416 MIME Content-Types SHALL be used: when a single X.509v3 certificate 417 is returned, the Content-Type is "application/pkix-cert" [RFC2585], 418 and when a chain of X.509v3 certificates is returned, the Content- 419 Type is "application/pkix-pkipath" Annex A. 421 The server MUST check that the SHA-1 hash of the contents of the 422 object retrieved from that URL (after decoding any MIME Content- 423 Transfer-Encoding) matches the given hash. If any retrieved object 424 does not have the correct SHA-1 hash, the server MUST abort the 425 handshake with a bad_certificate_hash_value(114) alert. This alert is 426 always fatal. 428 Clients may choose to send either "Certificate" or "CertificateURL" 429 after successfully negotiating the option to send certificate URLs. 430 The option to send a certificate is included to provide flexibility 431 to clients possessing multiple certificates. 433 If a server encounters an unreasonable delay in obtaining 434 certificates in a given CertificateURL, it SHOULD time out and signal 435 a certificate_unobtainable(111) error alert. This alert MAY be fatal; 436 for example, if client authentication is required by the server for 437 the handshake to continue. 439 6. Trusted CA Indication 441 Constrained clients that, due to memory limitations, possess only a 442 small number of CA root keys may wish to indicate to servers which 443 root keys they possess, in order to avoid repeated handshake 444 failures. 446 In order to indicate which CA root keys they possess, clients MAY 447 include an extension of type "trusted_ca_keys" in the (extended) 448 client hello. The "extension_data" field of this extension SHALL 449 contain "TrustedAuthorities" where: 451 struct { 452 TrustedAuthority trusted_authorities_list<0..2^16-1>; 453 } TrustedAuthorities; 455 struct { 456 IdentifierType identifier_type; 457 select (identifier_type) { 458 case pre_agreed: struct {}; 459 case key_sha1_hash: SHA1Hash; 460 case x509_name: DistinguishedName; 461 case cert_sha1_hash: SHA1Hash; 462 } identifier; 463 } TrustedAuthority; 465 enum { 466 pre_agreed(0), key_sha1_hash(1), x509_name(2), 467 cert_sha1_hash(3), (255) 468 } IdentifierType; 470 opaque DistinguishedName<1..2^16-1>; 472 Here "TrustedAuthorities" provides a list of CA root key identifiers 473 that the client possesses. Each CA root key is identified via either: 475 - "pre_agreed": no CA root key identity supplied. 477 - "key_sha1_hash": contains the SHA-1 hash of the CA root key. For 478 Digital Signature Algorithm (DSA) and Elliptic Curve Digital 479 Signature Algorithm (ECDSA) keys, this is the hash of the 480 "subjectPublicKey" value. For RSA keys, the hash is of the big- 481 endian byte string representation of the modulus without any 482 initial 0-valued bytes. (This copies the key hash formats deployed 483 in other environments.) 485 - "x509_name": contains the DER-encoded X.509 DistinguishedName of 486 the CA. 488 - "cert_sha1_hash": contains the SHA-1 hash of a DER-encoded 489 Certificate containing the CA root key. 491 Note that clients may include none, some, or all of the CA root keys 492 they possess in this extension. 494 Note also that it is possible that a key hash or a Distinguished Name 495 alone may not uniquely identify a certificate issuer (for example, if 496 a particular CA has multiple key pairs). However, here we assume this 497 is the case following the use of Distinguished Names to identify 498 certificate issuers in TLS. 500 The option to include no CA root keys is included to allow the client 501 to indicate possession of some pre-defined set of CA root keys. 503 Servers that receive a client hello containing the "trusted_ca_keys" 504 extension MAY use the information contained in the extension to guide 505 their selection of an appropriate certificate chain to return to the 506 client. In this event, the server SHALL include an extension of type 507 "trusted_ca_keys" in the (extended) server hello. The 508 "extension_data" field of this extension SHALL be empty. 510 7. Truncated HMAC 512 Currently defined TLS cipher suites use the MAC construction HMAC 513 with either MD5 or SHA-1 [RFC2104] to authenticate record layer 514 communications. In TLS, the entire output of the hash function is 515 used as the MAC tag. However, it may be desirable in constrained 516 environments to save bandwidth by truncating the output of the hash 517 function to 80 bits when forming MAC tags. 519 In order to negotiate the use of 80-bit truncated HMAC, clients MAY 520 include an extension of type "truncated_hmac" in the extended client 521 hello. The "extension_data" field of this extension SHALL be empty. 523 Servers that receive an extended hello containing a "truncated_hmac" 524 extension MAY agree to use a truncated HMAC by including an extension 525 of type "truncated_hmac", with empty "extension_data", in the 526 extended server hello. 528 Note that if new cipher suites are added that do not use HMAC, and 529 the session negotiates one of these cipher suites, this extension 530 will have no effect. It is strongly recommended that any new cipher 531 suites using other MACs consider the MAC size an integral part of the 532 cipher suite definition, taking into account both security and 533 bandwidth considerations. 535 If HMAC truncation has been successfully negotiated during a TLS 536 handshake, and the negotiated cipher suite uses HMAC, both the client 537 and the server pass this fact to the TLS record layer along with the 538 other negotiated security parameters. Subsequently during the 539 session, clients and servers MUST use truncated HMACs, calculated as 540 specified in [RFC2104]. That is, SecurityParameters.mac_length is 10 541 bytes, and only the first 10 bytes of the HMAC output are transmitted 542 and checked. Note that this extension does not affect the calculation 543 of the pseudo-random function (PRF) as part of handshaking or key 544 derivation. 546 The negotiated HMAC truncation size applies for the duration of the 547 session including session resumptions. 549 8. Certificate Status Request 551 Constrained clients may wish to use a certificate-status protocol 552 such as OCSP [RFC2560] to check the validity of server certificates, 553 in order to avoid transmission of CRLs and therefore save bandwidth 554 on constrained networks. This extension allows for such information 555 to be sent in the TLS handshake, saving roundtrips and resources. 557 In order to indicate their desire to receive certificate status 558 information, clients MAY include an extension of type 559 "status_request" in the (extended) client hello. The "extension_data" 560 field of this extension SHALL contain "CertificateStatusRequest" 561 where: 563 struct { 564 CertificateStatusType status_type; 565 select (status_type) { 566 case ocsp: OCSPStatusRequest; 567 } request; 568 } CertificateStatusRequest; 570 enum { ocsp(1), (255) } CertificateStatusType; 572 struct { 573 ResponderID responder_id_list<0..2^16-1>; 574 Extensions request_extensions; 575 } OCSPStatusRequest; 577 opaque ResponderID<1..2^16-1>; 578 opaque Extensions<0..2^16-1>; 580 In the OCSPStatusRequest, the "ResponderIDs" provides a list of OCSP 581 responders that the client trusts. A zero-length "responder_id_list" 582 sequence has the special meaning that the responders are implicitly 583 known to the server, e.g., by prior arrangement. "Extensions" is a 584 DER encoding of OCSP request extensions. 586 Both "ResponderID" and "Extensions" are DER-encoded ASN.1 types as 587 defined in [RFC2560]. "Extensions" is imported from [RFC5280]. A 588 zero-length "request_extensions" value means that there are no 589 extensions (as opposed to a zero-length ASN.1 SEQUENCE, which is not 590 valid for the "Extensions" type). 592 In the case of the "id-pkix-ocsp-nonce" OCSP extension, [RFC2560] is 593 unclear about its encoding; for clarification, the nonce MUST be a 594 DER-encoded OCTET STRING, which is encapsulated as another OCTET 595 STRING (note that implementations based on an existing OCSP client 596 will need to be checked for conformance to this requirement). 598 Servers that receive a client hello containing the "status_request" 599 extension MAY return a suitable certificate status response to the 600 client along with their certificate. If OCSP is requested, they 601 SHOULD use the information contained in the extension when selecting 602 an OCSP responder and SHOULD include request_extensions in the OCSP 603 request. 605 Servers return a certificate response along with their certificate by 606 sending a "CertificateStatus" message immediately after the 607 "Certificate" message (and before any "ServerKeyExchange" or 608 "CertificateRequest" messages). If a server returns a 609 "CertificateStatus" message, then the server MUST have included an 610 extension of type "status_request" with empty "extension_data" in the 611 extended server hello. The "CertificateStatus" message is conveyed 612 using the handshake message type "certificate_status" as follows (see 613 also Section 2): 615 struct { 616 CertificateStatusType status_type; 617 select (status_type) { 618 case ocsp: OCSPResponse; 619 } response; 620 } CertificateStatus; 622 opaque OCSPResponse<1..2^24-1>; 624 An "ocsp_response" contains a complete, DER-encoded OCSP response 625 (using the ASN.1 type OCSPResponse defined in [RFC2560]). Only one 626 OCSP response may be sent. 628 Note that a server MAY also choose not to send a "CertificateStatus" 629 message, even if has received a "status_request" extension in the 630 client hello message and has sent a "status_request" extension in the 631 server hello message. 633 Note in addition that a server MUST NOT send the "CertificateStatus" 634 message unless it received a "status_request" extension in the client 635 hello message and sent a "status_request" extension in the server 636 hello message. 638 Clients requesting an OCSP response and receiving an OCSP response in 639 a "CertificateStatus" message MUST check the OCSP response and abort 640 the handshake if the response is not satisfactory with 641 bad_certificate_status_response(113) alert. This alert is always 642 fatal. 644 9. Error Alerts 646 Four new error alerts are defined for use with the TLS extensions 647 defined in this document. To avoid "breaking" existing clients and 648 servers, these alerts MUST NOT be sent unless the sending party has 649 received an extended hello message from the party they are 650 communicating with. These error alerts are conveyed using the 651 following syntax. The new alerts are the last four, as indicated by 652 the comments on the same line as the error alert number. 654 enum { 655 close_notify(0), 656 unexpected_message(10), 657 bad_record_mac(20), 658 decryption_failed(21), 659 record_overflow(22), 660 decompression_failure(30), 661 handshake_failure(40), 662 /* 41 is not defined, for historical reasons */ 663 bad_certificate(42), 664 unsupported_certificate(43), 665 certificate_revoked(44), 666 certificate_expired(45), 667 certificate_unknown(46), 668 illegal_parameter(47), 669 unknown_ca(48), 670 access_denied(49), 671 decode_error(50), 672 decrypt_error(51), 673 export_restriction(60), 674 protocol_version(70), 675 insufficient_security(71), 676 internal_error(80), 677 user_canceled(90), 678 no_renegotiation(100), 679 unsupported_extension(110), 680 certificate_unobtainable(111), /* new */ 681 unrecognized_name(112), /* new */ 682 bad_certificate_status_response(113), /* new */ 683 bad_certificate_hash_value(114), /* new */ 684 (255) 685 } AlertDescription; 687 "certificate_unobtainable" is described in Section 5. 688 "unrecognized_name" is described in Section 3. 689 "bad_certificate_status_response" is described in Section 8. 690 "bad_certificate_hash_value" is described in Section 5. 692 10. IANA Considerations 694 IANA Considerations for TLS Extensions and the creation of a Registry 695 therefore are covered in Section 12 of [RFC5246] except for the 696 registration of MIME type application/pkix-pkipath. This MIME type 697 has already been registered but is reproduced in Annex A for 698 convenience. 700 The IANA TLS extensions registry entries that reference [RFC4366] 701 should be updated to reference this document on its publication as an 702 RFC. 704 11. Security Considerations 706 General Security Considerations for TLS Extensions are covered in 707 [RFC5246]. Security Considerations for particular extensions 708 specified in this document are given below. 710 In general, implementers should continue to monitor the state of the 711 art and address any weaknesses identified. 713 Additional security considerations are described in the TLS 1.0 RFC 714 [RFC2246] and the TLS 1.1 RFC [RFC4346]. 716 11.1 Security Considerations for server_name 718 If a single server hosts several domains, then clearly it is 719 necessary for the owners of each domain to ensure that this satisfies 720 their security needs. Apart from this, server_name does not appear to 721 introduce significant security issues. 723 Implementations MUST ensure that a buffer overflow does not occur, 724 whatever the values of the length fields in server_name. 726 11.2 Security Considerations for max_fragment_length 728 The maximum fragment length takes effect immediately, including for 729 handshake messages. However, that does not introduce any security 730 complications that are not already present in TLS, since TLS requires 731 implementations to be able to handle fragmented handshake messages. 733 Note that as described in Section 4, once a non-null cipher suite has 734 been activated, the effective maximum fragment length depends on the 735 cipher suite and compression method, as well as on the negotiated 736 max_fragment_length. This must be taken into account when sizing 737 buffers, and checking for buffer overflow. 739 11.3 Security Considerations for client_certificate_url 741 There were two major issues with this extension. 743 The first major issue was whether or not clients must include 744 certificate hashes when they send certificate URLs. 746 When client authentication is used *without* the 747 client_certificate_url extension, the client certificate chain is 748 covered by the Finished message hashes. The purpose of including 749 hashes and checking them against the retrieved certificate chain is 750 to ensure that the same property holds when this extension is used, 751 i.e., that all of the information in the certificate chain retrieved 752 by the server is as the client intended. 754 On the other hand, allowing the omission of certificate hashes 755 enables functionality that is desirable in some circumstances; for 756 example, clients could be issued daily certificates that are stored 757 at a fixed URL and need not be provided to the client. However, this 758 enables an attack in which the attacker obtains a valid certificate 759 on the client's key that is different from the certificate the client 760 intended to provide. It was decided to make hashes mandatory. Hash 761 agility was not believed to be necessary here. The property required 762 of SHA-1 is second pre-image resistance. 764 The second major issue is that support for client_certificate_url 765 involves the server's acting as a client in another URI scheme 766 dependent protocol. The server therefore becomes subject to many of 767 the same security concerns that clients of the URI scheme are subject 768 to, with the added concern that the client can attempt to prompt the 769 server to connect to some (possibly weird-looking) URL. 771 In general, this issue means that an attacker might use the server to 772 indirectly attack another host that is vulnerable to some security 773 flaw. It also introduces the possibility of denial of service attacks 774 in which an attacker makes many connections to the server, each of 775 which results in the server's attempting a connection to the target 776 of the attack. 778 Note that the server may be behind a firewall or otherwise able to 779 access hosts that would not be directly accessible from the public 780 Internet. This could exacerbate the potential security and denial of 781 service problems described above, as well as allow the existence of 782 internal hosts to be confirmed when they would otherwise be hidden. 784 The detailed security concerns involved will depend on the URI 785 schemes supported by the server. In the case of HTTP, the concerns 786 are similar to those that apply to a publicly accessible HTTP proxy 787 server. In the case of HTTPS, loops and deadlocks may be created, and 788 this should be addressed. In the case of FTP, attacks arise that are 789 similar to FTP bounce attacks. 791 As a result of this issue, it is RECOMMENDED that the 792 client_certificate_url extension should have to be specifically 793 enabled by a server administrator, rather than be enabled by default. 794 It is also RECOMMENDED that URI schemes be enabled by the 795 administrator individually, and only a minimal set of schemes be 796 enabled. Unusual protocols that offer limited security or whose 797 security is not well understood SHOULD be avoided. 799 As discussed in [RFC3986], URLs that specify ports other than the 800 default may cause problems, as may very long URLs (which are more 801 likely to be useful in exploiting buffer overflow bugs). 803 Also note that HTTP caching proxies are common on the Internet, and 804 some proxies do not check for the latest version of an object 805 correctly. If a request using HTTP (or another caching protocol) goes 806 through a misconfigured or otherwise broken proxy, the proxy may 807 return an out-of-date response. 809 11.4 Security Considerations for trusted_ca_keys 811 It is possible that which CA root keys a client possesses could be 812 regarded as confidential information. As a result, the CA root key 813 indication extension should be used with care. 815 The use of the SHA-1 certificate hash alternative ensures that each 816 certificate is specified unambiguously. As for the previous 817 extension, it was not believed necessary to use both MD5 and SHA-1 818 hashes. 820 11.5 Security Considerations for truncated_hmac 822 It is possible that truncated MACs are weaker than "un-truncated" 823 MACs. However, no significant weaknesses are currently known or 824 expected to exist for HMAC with MD5 or SHA-1, truncated to 80 bits. 826 Note that the output length of a MAC need not be as long as the 827 length of a symmetric cipher key, since forging of MAC values cannot 828 be done off-line: in TLS, a single failed MAC guess will cause the 829 immediate termination of the TLS session. 831 Since the MAC algorithm only takes effect after all handshake 832 messages that affect extension parameters have been authenticated by 833 the hashes in the Finished messages, it is not possible for an active 834 attacker to force negotiation of the truncated HMAC extension where 835 it would not otherwise be used (to the extent that the handshake 836 authentication is secure). Therefore, in the event that any security 837 problem were found with truncated HMAC in the future, if either the 838 client or the server for a given session were updated to take the 839 problem into account, it would be able to veto use of this extension. 841 11.6 Security Considerations for status_request 843 If a client requests an OCSP response, it must take into account that 844 an attacker's server using a compromised key could (and probably 845 would) pretend not to support the extension. In this case, a client 846 that requires OCSP validation of certificates SHOULD either contact 847 the OCSP server directly or abort the handshake. 849 Use of the OCSP nonce request extension (id-pkix-ocsp-nonce) may 850 improve security against attacks that attempt to replay OCSP 851 responses; see Section 4.4.1 of [RFC2560] for further details. 853 12. Normative References 855 [RFC2104] Krawczyk, H., Bellare, M., and R. Canetti, "HMAC: Keyed- 856 Hashing for Message Authentication", RFC 2104, February 1997. 858 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 859 Requirement Levels", BCP 14, RFC 2119, March 1997. 861 [RFC2560] Myers, M., Ankney, R., Malpani, A., Galperin, S., and C. 862 Adams, "X.509 Internet Public Key Infrastructure Online Certificate 863 Status Protocol - OCSP", RFC 2560, June 1999. 865 [RFC2585] Housley, R. and P. Hoffman, "Internet X.509 Public Key 866 Infrastructure Operational Protocols: FTP and HTTP", RFC 2585, May 867 1999. 869 [RFC2616] Fielding, R., Gettys, J., Mogul, J., Frystyk, H., Masinter, 870 L., Leach, P., and T. Berners-Lee, "Hypertext Transfer Protocol -- 871 HTTP/1.1", RFC 2616, June 1999. 873 [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform 874 Resource Identifier (URI): Generic Syntax", STD 66, RFC 3986, January 875 2005. 877 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 878 (TLS) Protocol Version 1.2", RFC 5246, August 2008. 880 [RFC5280] Cooper, D., Santesson, S., Farrell, S., Boeyen, S., 881 Housley, R., and W. Polk, "Internet X.509 Public Key Infrastructure 882 Certificate and Certificate Revocation List (CRL) Profile", RFC 5280, 883 May 2008 885 13. Informative References 887 [RFC2246] Dierks, T. and C. Allen, "The TLS Protocol Version 1.0", 888 RFC 2246, January 1999. 890 [RFC2712] Medvinsky, A. and M. Hur, "Addition of Kerberos Cipher 891 Suites to Transport Layer Security (TLS)", RFC 2712, October 1999. 893 [RFC3268] Chown, P., "Advanced Encryption Standard (AES) Ciphersuites 894 for Transport Layer Security (TLS)", RFC 3268, June 2002. 896 [RFC4346] Dierks, T. and E. Rescorla, "The Transport Layer Security 897 (TLS) Protocol Version 1.1", RFC 4346, April 2006. 899 [RFC4366] Blake-Wilson, S., Nystrom, M., Hopwood, D., Mikkelsen, J., 900 and T. Wright, "Transport Layer Security (TLS) Extensions", RFC 4366, 901 April 2006. 903 [X509-4th] ITU-T Recommendation X.509 (2000) | ISO/IEC 9594-8:2001, 904 "Information Systems - Open Systems Interconnection - The Directory: 905 Public key and attribute certificate frameworks." 907 [X509-4th-TC1] ITU-T Recommendation X.509(2000) Corrigendum 1(2001) | 908 ISO/IEC 9594-8:2001/Cor.1:2002, Technical Corrigendum 1 to ISO/IEC 909 9594:8:2001. 911 Annex A: pkipath MIME Type Registration 913 The MIME type application/pkix-pkipath has been registered. A copy 914 of its template is included here for convenience: 916 MIME media type name: application 917 MIME subtype name: pkix-pkipath 918 Required parameters: none 920 Optional parameters: version (default value is "1") 922 Encoding considerations: 923 This MIME type is a DER encoding of the ASN.1 type PkiPath, 924 defined as follows: 925 PkiPath ::= SEQUENCE OF Certificate 926 PkiPath is used to represent a certification path. Within the 927 sequence, the order of certificates is such that the subject of 928 the first certificate is the issuer of the second certificate, 929 etc. 930 This is identical to the definition published in [X509-4th-TC1]; 931 note that it is different from that in [X509-4th]. 933 All Certificates MUST conform to [RFC5280]. (This should be 934 interpreted as a requirement to encode only PKIX-conformant 935 certificates using this type. It does not necessarily require 936 that all certificates that are not strictly PKIX-conformant must 937 be rejected by relying parties, although the security consequences 938 of accepting any such certificates should be considered 939 carefully.) 941 DER (as opposed to BER) encoding MUST be used. If this type is 942 sent over a 7-bit transport, base64 encoding SHOULD be used. 944 Security considerations: 945 The security considerations of [X509-4th] and [RFC5280] (or any 946 updates to them) apply, as well as those of any protocol that uses 947 this type (e.g., TLS). 949 Note that this type only specifies a certificate chain that can be 950 assessed for validity according to the relying party's existing 951 configuration of trusted CAs; it is not intended to be used to 952 specify any change to that configuration. 954 Interoperability considerations: 955 No specific interoperability problems are known with this type, 956 but for recommendations relating to X.509 certificates in general, 957 see [RFC5280]. 959 Published specification: [RFC4366], and [RFC5280]. 961 Applications which use this media type: TLS. It may also be used by 962 other protocols, or for general interchange of PKIX certificate 963 chains. 965 Additional information: 966 Magic number(s): DER-encoded ASN.1 can be easily recognized. 967 Further parsing is required to distinguish it from other ASN.1 968 types. 969 File extension(s): .pkipath 970 Macintosh File Type Code(s): not specified 972 Person & email address to contact for further information: 973 Magnus Nystrom 975 Intended usage: COMMON 977 Change controller: IESG 979 Author's Address 981 Donald Eastlake 3rd 982 Stellar Switches, Inc. 983 155 Beaver Street 984 Milford, MA 01757 USA 986 Tel: +1-508-634-2066 987 Email: d3e3e3@gmail.com 989 Copyright and IPR Provisions 991 Copyright (c) 2009 IETF Trust and the persons identified as the 992 document authors. All rights reserved. 994 This document is subject to BCP 78 and the IETF Trust's Legal 995 Provisions Relating to IETF Documents in effect on the date of 996 publication of this document (http://trustee.ietf.org/license-info). 997 Please review these documents carefully, as they describe your rights 998 and restrictions with respect to this document. 1000 The definitive version of an IETF Document is that published by, or 1001 under the auspices of, the IETF. Versions of IETF Documents that are 1002 published by third parties, including those that are translated into 1003 other languages, should not be considered to be definitive versions 1004 of IETF Documents. The definitive version of these Legal Provisions 1005 is that published by, or under the auspices of, the IETF. Versions of 1006 these Legal Provisions that are published by third parties, including 1007 those that are translated into other languages, should not be 1008 considered to be definitive versions of these Legal Provisions. For 1009 the avoidance of doubt, each Contributor to the IETF Standards 1010 Process licenses each Contribution that he or she makes as part of 1011 the IETF Standards Process to the IETF Trust pursuant to the 1012 provisions of RFC 5378. No language to the contrary, or terms, 1013 conditions or rights that differ from or are inconsistent with the 1014 rights and licenses granted under RFC 5378, shall have any effect and 1015 shall be null and void, whether published or posted by such 1016 Contributor, or included with or in such Contribution.