idnits 2.17.1 draft-ietf-tls-dtls-rrc-01.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 : ---------------------------------------------------------------------------- ** The document seems to lack a Security Considerations section. -- The draft header indicates that this document updates RFC6347, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC6347, updated by this document, for RFC5378 checks: 2008-06-09) -- 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 (25 October 2021) is 907 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 (-13) exists of draft-ietf-tls-tlsflags-06 Summary: 1 error (**), 0 flaws (~~), 2 warnings (==), 4 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 TLS H. Tschofenig, Ed. 3 Internet-Draft T. Fossati 4 Updates: 6347 (if approved) Arm Limited 5 Intended status: Standards Track 25 October 2021 6 Expires: 28 April 2022 8 Return Routability Check for DTLS 1.2 and DTLS 1.3 9 draft-ietf-tls-dtls-rrc-01 11 Abstract 13 This document specifies a return routability check for use in context 14 of the Connection ID (CID) construct for the Datagram Transport Layer 15 Security (DTLS) protocol versions 1.2 and 1.3. 17 Discussion Venues 19 This note is to be removed before publishing as an RFC. 21 Discussion of this document takes place on the Transport Layer 22 Security Working Group mailing list (tls@ietf.org), which is archived 23 at https://mailarchive.ietf.org/arch/browse/tls/. 25 Source for this draft and an issue tracker can be found at 26 https://github.com/tlswg/dtls-rrc. 28 Status of This Memo 30 This Internet-Draft is submitted in full conformance with the 31 provisions of BCP 78 and BCP 79. 33 Internet-Drafts are working documents of the Internet Engineering 34 Task Force (IETF). Note that other groups may also distribute 35 working documents as Internet-Drafts. The list of current Internet- 36 Drafts is at https://datatracker.ietf.org/drafts/current/. 38 Internet-Drafts are draft documents valid for a maximum of six months 39 and may be updated, replaced, or obsoleted by other documents at any 40 time. It is inappropriate to use Internet-Drafts as reference 41 material or to cite them other than as "work in progress." 43 This Internet-Draft will expire on 28 April 2022. 45 Copyright Notice 47 Copyright (c) 2021 IETF Trust and the persons identified as the 48 document authors. All rights reserved. 50 This document is subject to BCP 78 and the IETF Trust's Legal 51 Provisions Relating to IETF Documents (https://trustee.ietf.org/ 52 license-info) in effect on the date of publication of this document. 53 Please review these documents carefully, as they describe your rights 54 and restrictions with respect to this document. Code Components 55 extracted from this document must include Simplified BSD License text 56 as described in Section 4.e of the Trust Legal Provisions and are 57 provided without warranty as described in the Simplified BSD License. 59 This document may contain material from IETF Documents or IETF 60 Contributions published or made publicly available before November 61 10, 2008. The person(s) controlling the copyright in some of this 62 material may not have granted the IETF Trust the right to allow 63 modifications of such material outside the IETF Standards Process. 64 Without obtaining an adequate license from the person(s) controlling 65 the copyright in such materials, this document may not be modified 66 outside the IETF Standards Process, and derivative works of it may 67 not be created outside the IETF Standards Process, except to format 68 it for publication as an RFC or to translate it into languages other 69 than English. 71 Table of Contents 73 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 74 2. Conventions and Terminology . . . . . . . . . . . . . . . . . 3 75 3. RRC Extension . . . . . . . . . . . . . . . . . . . . . . . . 3 76 4. The Return Routability Check Message . . . . . . . . . . . . 4 77 5. Example . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 78 6. Security and Privacy Considerations . . . . . . . . . . . . . 8 79 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 80 8. Open Issues . . . . . . . . . . . . . . . . . . . . . . . . . 8 81 9. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 8 82 10. Normative References . . . . . . . . . . . . . . . . . . . . 8 83 Appendix A. History . . . . . . . . . . . . . . . . . . . . . . 9 84 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 86 1. Introduction 88 In "classical" DTLS, selecting a security context of an incoming DTLS 89 record is accomplished with the help of the 5-tuple, i.e. source IP 90 address, source port, transport protocol, destination IP address, and 91 destination port. Changes to this 5 tuple can happen for a variety 92 reasons over the lifetime of the DTLS session. In the IoT context, 93 NAT rebinding is common with sleepy devices. Other examples include 94 end host mobility and multi-homing. Without CID, if the source IP 95 address and/or source port changes during the lifetime of an ongoing 96 DTLS session then the receiver will be unable to locate the correct 97 security context. As a result, the DTLS handshake has to be re-run. 99 Of course, it is not necessary to re-run the full handshake if 100 session resumption is supported and negotiated. 102 A CID is an identifier carried in the record layer header of a DTLS 103 datagram that gives the receiver additional information for selecting 104 the appropriate security context. The CID mechanism has been 105 specified in [I-D.ietf-tls-dtls-connection-id] for DTLS 1.2 and in 106 [I-D.ietf-tls-dtls13] for DTLS 1.3. 108 Section 6 of [I-D.ietf-tls-dtls-connection-id] describes how the use 109 of CID increases the attack surface by providing both on-path and 110 off-path attackers an opportunity for (D)DoS. It then goes on 111 describing the steps a DTLS principal must take when a record with a 112 CID is received that has a source address (and/or port) different 113 from the one currently associated with the DTLS connection. However, 114 the actual mechanism for ensuring that the new peer address is 115 willing to receive and process DTLS records is left open. This 116 document standardizes a return routability check (RRC) as part of the 117 DTLS protocol itself. 119 The return routability check is performed by the receiving peer 120 before the CID-to-IP address/port binding is updated in that peer's 121 session state database. This is done in order to provide more 122 confidence to the receiving peer that the sending peer is reachable 123 at the indicated address and port. 125 2. Conventions and Terminology 127 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 128 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 129 "OPTIONAL" in this document are to be interpreted as described in 130 BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all 131 capitals, as shown here. 133 This document assumes familiarity with the CID format and protocol 134 defined for DTLS 1.2 [I-D.ietf-tls-dtls-connection-id] and for DTLS 135 1.3 [I-D.ietf-tls-dtls13]. The presentation language used in this 136 document is described in Section 4 of [RFC8446]. 138 3. RRC Extension 140 This specification uses the tls_flags extension defined in 141 [I-D.ietf-tls-tlsflags] to allow a client and a server to negotiate 142 support for this extension. 144 The RRC flag is assigned the value (TBD1) and is used in the 145 ClientHello (CH) and the ServerHello (SH). 147 4. The Return Routability Check Message 149 When a record with CID is received that has the source address of the 150 enclosing UDP datagram different from the one previously associated 151 with that CID, the receiver MUST NOT update its view of the peer's IP 152 address and port number with the source specified in the UDP datagram 153 before cryptographically validating the enclosed record(s) but 154 instead perform a return routability check. 156 enum { 157 invalid(0), 158 change_cipher_spec(20), 159 alert(21), 160 handshake(22), 161 application_data(23), 162 heartbeat(24), /* RFC 6520 */ 163 return_routability_check(TBD), /* NEW */ 164 (255) 165 } ContentType; 167 uint64 Cookie; 169 enum { 170 path_challenge(0), 171 path_response(1), 172 reserved(2..255) 173 } rrc_msg_type; 175 struct { 176 rrc_msg_type msg_type; 177 select (return_routability_check.msg_type) { 178 case path_challenge: Cookie; 179 case path_response: Cookie; 180 }; 181 } return_routability_check; 183 The newly introduced return_routability_check message contains a 184 cookie. The cookie is a 8-byte field containing arbitrary data. 186 The return_routability_check message MUST be authenticated and 187 encrypted using the currently active security context. 189 The receiver that observes the peer's address and or port update MUST 190 stop sending any buffered application data (or limit the data sent to 191 a TBD threshold) and initiate the return routability check that 192 proceeds as follows: 194 1. A cookie is placed in a return_routability_check message of type 195 path_challenge; 197 2. The message is sent to the observed new address and a timeout T 198 is started; 200 3. The peer endpoint, after successfully verifying the received 201 return_routability_check message echoes the cookie value in a 202 return_routability_check message of type path_response; 204 4. When the initiator receives and verifies the 205 return_routability_check message contains the sent cookie, it 206 updates the peer address binding; 208 5. If T expires, or the address confirmation fails, the peer address 209 binding is not updated. 211 After this point, any pending send operation is resumed to the bound 212 peer address. 214 5. Example 216 The example TLS 1.3 handshake shown in Figure 1 shows a client and a 217 server negotiating the support for CID and for the RRC extension. 219 Client Server 221 Key ^ ClientHello 222 Exch | + key_share 223 | + signature_algorithms 224 | + tls_flags (RRC) 225 v + connection_id=empty 226 --------> 227 ServerHello ^ Key 228 + key_share | Exch 229 + connection_id=100 | 230 + tls_flags (RRC) v 231 {EncryptedExtensions} ^ Server 232 {CertificateRequest} v Params 233 {Certificate} ^ 234 {CertificateVerify} | Auth 235 <-------- {Finished} v 237 ^ {Certificate} 238 Auth | {CertificateVerify} 239 v {Finished} --------> 240 [Application Data] <-------> [Application Data] 242 + Indicates noteworthy extensions sent in the 243 previously noted message. 245 * Indicates optional or situation-dependent 246 messages/extensions that are not always sent. 248 {} Indicates messages protected using keys 249 derived from a [sender]_handshake_traffic_secret. 251 [] Indicates messages protected using keys 252 derived from [sender]_application_traffic_secret_N. 254 Figure 1: Message Flow for Full TLS Handshake 256 Once a connection has been established the client and the server 257 exchange application payloads protected by DTLS with an unilaterally 258 used CIDs. In our case, the client is requested to use CID 100 for 259 records sent to the server. 261 At some point in the communication interaction the IP address used by 262 the client changes and, thanks to the CID usage, the security context 263 to interpret the record is successfully located by the server. 264 However, the server wants to test the reachability of the client at 265 his new IP address. 267 Client Server 268 ------ ------ 270 Application Data ========> 271 272 Src-IP=A 273 Dst-IP=Z 274 <======== Application Data 275 Src-IP=Z 276 Dst-IP=A 278 <<------------->> 279 << Some >> 280 << Time >> 281 << Later >> 282 <<------------->> 284 Application Data ========> 285 286 Src-IP=B 287 Dst-IP=Z 289 <<< Unverified IP 290 Address B >> 292 <-------- Return Routability Check 293 path_challenge(cookie) 294 Src-IP=Z 295 Dst-IP=B 297 Return Routability Check --------> 298 path_response(cookie) 299 Src-IP=B 300 Dst-IP=Z 302 <<< IP Address B 303 Verified >> 305 <======== Application Data 306 Src-IP=Z 307 Dst-IP=B 309 Figure 2: Return Routability Example 311 6. Security and Privacy Considerations 313 Note that the return routability checks do not protect against 314 flooding of third-parties if the attacker is on-path, as the attacker 315 can redirect the return routability checks to the real peer (even if 316 those datagrams are cryptographically authenticated). On-path 317 adversaries can, in general, pose a harm to connectivity. 319 7. IANA Considerations 321 IANA is requested to allocate an entry to the TLS "ContentType" 322 registry, for the return_routability_check(TBD) defined in this 323 document. 325 IANA is requested to allocate an entry to the TLS Flags registry in 326 the tls_flags type: 328 * Value: [[IANA please assign a value from the 32-63 value range.]] 330 * Flag Name: RRC 332 * Message: CH,SH 334 * Recommended: Y 336 * Reference: [[This document]] 338 8. Open Issues 340 Issues against this document are tracked at https://github.com/tlswg/ 341 dtls-rrc/issues 343 9. Acknowledgments 345 We would like to thank Achim Kraus, Hanno Becker, Hanno Boeck, Manuel 346 Pegourie-Gonnard, Mohit Sahni and Rich Salz for their input to this 347 document. 349 10. Normative References 351 [I-D.ietf-tls-dtls-connection-id] 352 Rescorla, E., Tschofenig, H., Fossati, T., and A. Kraus, 353 "Connection Identifiers for DTLS 1.2", Work in Progress, 354 Internet-Draft, draft-ietf-tls-dtls-connection-id-13, 22 355 June 2021, . 358 [I-D.ietf-tls-dtls13] 359 Rescorla, E., Tschofenig, H., and N. Modadugu, "The 360 Datagram Transport Layer Security (DTLS) Protocol Version 361 1.3", Work in Progress, Internet-Draft, draft-ietf-tls- 362 dtls13-43, 30 April 2021, 363 . 366 [I-D.ietf-tls-tlsflags] 367 Nir, Y., "A Flags Extension for TLS 1.3", Work in 368 Progress, Internet-Draft, draft-ietf-tls-tlsflags-06, 13 369 July 2021, . 372 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 373 Requirement Levels", BCP 14, RFC 2119, 374 DOI 10.17487/RFC2119, March 1997, 375 . 377 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 378 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 379 May 2017, . 381 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol 382 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018, 383 . 385 Appendix A. History 387 RFC EDITOR: PLEASE REMOVE THE THIS SECTION 389 draft-ietf-tls-dtls-rrc-01 391 * Use the TLS flags extension for negotiating RRC 393 * Enhanced IANA consideration section 395 * Expanded example section 397 * Revamp message layout: 399 - Use 8-byte fixed size cookies 401 - Explicitly separate path challenge from response 403 draft-ietf-tls-dtls-rrc-00 405 * Draft name changed after WG adoption 406 * Removed text that overlapped with draft-ietf-tls-dtls-connection- 407 id 409 draft-tschofenig-tls-dtls-rrc-00 411 * Initial version 413 Authors' Addresses 415 Hannes Tschofenig (editor) 416 Arm Limited 418 Email: hannes.tschofenig@arm.com 420 Thomas Fossati 421 Arm Limited 423 Email: thomas.fossati@arm.com