idnits 2.17.1 draft-ietf-ice-dualstack-fairness-02.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 1 instance of lines with non-RFC6890-compliant IPv4 addresses in the document. If these are example addresses, they should be changed. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (April 7, 2016) is 2941 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- ** Obsolete normative reference: RFC 3484 (Obsoleted by RFC 6724) ** Obsolete normative reference: RFC 5245 (Obsoleted by RFC 8445, RFC 8839) ** Obsolete normative reference: RFC 6555 (Obsoleted by RFC 8305) ** Obsolete normative reference: RFC 6982 (Obsoleted by RFC 7942) Summary: 4 errors (**), 0 flaws (~~), 2 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 ICE P. Martinsen 3 Internet-Draft T. Reddy 4 Intended status: Informational P. Patil 5 Expires: October 9, 2016 Cisco 6 April 7, 2016 8 ICE Multihomed and IPv4/IPv6 Dual Stack Fairness 9 draft-ietf-ice-dualstack-fairness-02 11 Abstract 13 This document provides guidelines on how to make Interactive 14 Connectivity Establishment (ICE) conclude faster in multihomed and 15 IPv4/IPv6 dual-stack scenarios where broken paths exist. The 16 provided guidelines are backwards compatible with the original ICE 17 specification. 19 Status of This Memo 21 This Internet-Draft is submitted in full conformance with the 22 provisions of BCP 78 and BCP 79. 24 Internet-Drafts are working documents of the Internet Engineering 25 Task Force (IETF). Note that other groups may also distribute 26 working documents as Internet-Drafts. The list of current Internet- 27 Drafts is at http://datatracker.ietf.org/drafts/current/. 29 Internet-Drafts are draft documents valid for a maximum of six months 30 and may be updated, replaced, or obsoleted by other documents at any 31 time. It is inappropriate to use Internet-Drafts as reference 32 material or to cite them other than as "work in progress." 34 This Internet-Draft will expire on October 9, 2016. 36 Copyright Notice 38 Copyright (c) 2016 IETF Trust and the persons identified as the 39 document authors. All rights reserved. 41 This document is subject to BCP 78 and the IETF Trust's Legal 42 Provisions Relating to IETF Documents 43 (http://trustee.ietf.org/license-info) in effect on the date of 44 publication of this document. Please review these documents 45 carefully, as they describe your rights and restrictions with respect 46 to this document. Code Components extracted from this document must 47 include Simplified BSD License text as described in Section 4.e of 48 the Trust Legal Provisions and are provided without warranty as 49 described in the Simplified BSD License. 51 Table of Contents 53 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 54 2. Notational Conventions . . . . . . . . . . . . . . . . . . . 3 55 3. Improving ICE Multihomed Fairness . . . . . . . . . . . . . . 3 56 4. Improving ICE Dual Stack Fairness . . . . . . . . . . . . . . 4 57 5. Compatibility . . . . . . . . . . . . . . . . . . . . . . . . 4 58 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 7 59 7. Implementation Status . . . . . . . . . . . . . . . . . . . . 7 60 7.1. ICE-Dual Starck Fairness Test code . . . . . . . . . . . 8 61 7.2. ICE-Dual Starck Fairness Test code . . . . . . . . . . . 8 62 8. Security Considerations . . . . . . . . . . . . . . . . . . . 8 63 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 9 64 10. References . . . . . . . . . . . . . . . . . . . . . . . . . 9 65 10.1. Normative References . . . . . . . . . . . . . . . . . . 9 66 10.2. Informative References . . . . . . . . . . . . . . . . . 9 67 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 69 1. Introduction 71 Applications should take special care to deprioritize network 72 interfaces known to provide unreliable connectivity when operating in 73 a multihomed environment. For example, certain tunnel services might 74 provide unreliable connectivity. Doing so will ensure a more fair 75 distribution of the connectivity checks across available network 76 interfaces on the device. The simple guidelines presented here 77 describes how to deprioritize interfaces known by the application to 78 provide unreliable connectivity. 80 There is also a need to introduce more fairness when handling 81 connectivity checks for different IP address families in dual-stack 82 IPv4/IPv6 ICE scenarios. Section 4.1.2.1 of ICE [RFC5245] points to 83 [RFC3484] for prioritizing among the different IP families. 84 [RFC3484] is obsoleted by [RFC6724] but following the recommendations 85 from the updated RFC will lead to prioritization of IPv6 over IPv4 86 for the same candidate type. Due to this, connectivity checks for 87 candidates of the same type (host, reflexive or relay) are sent such 88 that an IP address family is completely depleted before checks from 89 the other address family are started. This results in user 90 noticeable setup delays if the path for the prioritized address 91 family is broken. 93 To avoid such user noticeable delays when either IPv6 or IPv4 path is 94 broken or excessively slow, this specification encourages 95 intermingling the different address families when connectivity checks 96 are performed. Introducing IP address family fairness into ICE 97 connectivity checks will lead to more sustained dual-stack IPv4/IPv6 98 deployment as users will no longer have an incentive to disable IPv6. 99 The cost is a small penalty to the address type that otherwise would 100 have been prioritized. 102 This document describes how to fairly order the candidates in 103 multihomed and dual-stack environments, thus affecting the sending 104 order of the connectivity checks. If aggressive nomination is in 105 use, this will have an effect on what candidate pair ends up as the 106 active one. Ultimately it should be up to the agent to decide what 107 candidate pair is best suited for transporting media. 109 The guidelines outlined in this specification are backward compatible 110 with a standard ICE implementation. This specification only alters 111 the values used to create the resulting checklists in such a way that 112 the core mechanisms from ICE [RFC5245] are still in effect. The 113 introduced fairness might be better, but not worse than what exists 114 today. 116 2. Notational Conventions 118 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 119 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 120 document are to be interpreted as described in [RFC2119]. 122 This document uses terminology defined in [RFC5245]. 124 3. Improving ICE Multihomed Fairness 126 A multihomed ICE agent can potentially send and receive connectivity 127 checks on all available interfaces and IP addresses. It is possible 128 for an interface to have several IP addresses associated with it. To 129 avoid unnecessary delay when performing connectivity checks it would 130 be beneficial to prioritize interfaces and IP addresses known by the 131 agent to provide stable connectivity. If the agent has access to 132 information about the physical network it is connected to (Like SSID 133 in a WiFi Network) this can be used as information regarding how that 134 network interface should be prioritized at this point in time. 136 The application knowledge regarding the reliability of an interface 137 can also be based on simple metrics like previous connection success/ 138 failure rates or a more static model based on interface types like 139 wired, wireless, cellular, virtual, tunneled and so on. 141 Candidates from an interface known to the application to provide 142 unreliable connectivity SHOULD get a low candidate priority. This 143 ensures they appear near the end of the candidate list, and would be 144 the last to be tested during the connectivity check phase. This 145 allows candidate pairs more likely to succeed to be tested first. 147 If the application is unable to get any interface information 148 regarding type or unable to store any relevant metrics, it SHOULD 149 treat all interfaces as if they have reliable connectivity. This 150 ensures all interfaces gets their fair chance to perform their 151 connectivity checks. 153 4. Improving ICE Dual Stack Fairness 155 Candidates SHOULD be prioritized such that a long sequence of 156 candidates belonging to the same address family will be intermingled 157 with candidates from an alternate IP family. For example, promoting 158 IPv4 candidates in the presence of many IPv6 candidates such that an 159 IPv4 address candidate is always present after a small sequence of 160 IPv6 candidates, i.e., reordering candidates such that both IPv6 and 161 IPv4 candidates get a fair chance during the connectivity check 162 phase. This makes ICE connectivity checks more responsive to broken 163 path failures of an address family. 165 An ICE agent can choose an algorithm or a technique of its choice to 166 ensure that the resulting check lists have a fair intermingled mix of 167 IPv4 and IPv6 address families. However, modifying the check list 168 directly can lead to uncoordinated local and remote check lists that 169 result in ICE taking longer to complete or in the worst case scenario 170 fail. The best approach is to modify the formula for calculating the 171 candidate priority value described in ICE [RFC5245] section 4.1.2.1. 173 Implementations SHOULD prioritize IPv6 candidates by putting some of 174 them first in the intermingled checklist. This increases the chance 175 of IPv6 connectivity checks to complete first and be ready for 176 nomination or usage. This enables implementations to follow the 177 intent of [RFC6555] "Happy Eyeballs: Success with Dual-Stack Hosts". 178 It is worth noting that the timing recommendations in [RFC6555] are 179 too excessive for ICE usage. 181 5. Compatibility 183 ICE [RFC5245] section 4.1.2 states that the formula in section 184 4.1.2.1 SHOULD be used to calculate the candidate priority. The 185 formula is as follows: 187 priority = (2^24)*(type preference) + 188 (2^8)*(local preference) + 189 (2^0)*(256 - component ID) 191 ICE [RFC5245] section 4.1.2.2 has guidelines for how the type 192 preference and local preference value should be chosen. Instead of 193 having a static local preference value for IPv4 and IPv6 addresses, 194 it is possible to choose this value dynamically in such a way that 195 IPv4 and IPv6 address candidate priorities end up intermingled within 196 the same candidate type. It is also possible to assign lower 197 priorities to IP addresses derived from unreliable interfaces using 198 the local preference value. 200 It is worth mentioning that [RFC5245] section 4.1.2 says that; "if 201 there are multiple candidates for a particular component for a 202 particular media stream that has the same type, the local preference 203 MUST be unique for each one". 205 The local type preference can be dynamically changed in such a way 206 that IPv4 and IPv6 address candidates end up intermingled regardless 207 of candidate type. This is useful if there are a lot of IPv6 host 208 candidates effectively blocking connectivity checks for IPv4 server 209 reflexive candidates. 211 Candidates with IP addresses from an unreliable interface SHOULD be 212 ordered at the end of the checklist, i.e., not intermingled as the 213 dual-stack candidates. 215 The list below shows a sorted local candidate list where the priority 216 is calculated in such a way that the IPv4 and IPv6 candidates are 217 intermingled (No multihomed candidates). To allow for earlier 218 connectivity checks for the IPv4 server reflexive candidates, some of 219 the IPv6 host candidates are demoted. This is just an example of how 220 a candidate priorities can be calculated to provide better fairness 221 between IPv4 and IPv6 candidates without breaking any of the ICE 222 connectivity checks. 224 Candidate Address Component 225 Type Type ID Priority 226 ------------------------------------------- 227 (1) HOST IPv6 (1) 2129289471 228 (2) HOST IPv6 (2) 2129289470 229 (3) HOST IPv4 (1) 2129033471 230 (4) HOST IPv4 (2) 2129033470 231 (5) HOST IPv6 (1) 2128777471 232 (6) HOST IPv6 (2) 2128777470 233 (7) HOST IPv4 (1) 2128521471 234 (8) HOST IPv4 (2) 2128521470 235 (9) HOST IPv6 (1) 2127753471 236 (10) HOST IPv6 (2) 2127753470 237 (11) SRFLX IPv6 (1) 1693081855 238 (12) SRFLX IPv6 (2) 1693081854 239 (13) SRFLX IPv4 (1) 1692825855 240 (14) SRFLX IPv4 (2) 1692825854 241 (15) HOST IPv6 (1) 1692057855 242 (16) HOST IPv6 (2) 1692057854 243 (17) RELAY IPv6 (1) 15360255 244 (18) RELAY IPv6 (2) 15360254 245 (19) RELAY IPv4 (1) 15104255 246 (20) RELAY IPv4 (2) 15104254 248 SRFLX = server reflexive 250 Note that the list does not alter the component ID part of the 251 formula. This keeps the different components (RTP and RTCP) close in 252 the list. What matters is the ordering of the candidates with 253 component ID 1. Once the checklist is formed for a media stream the 254 candidate pair with component ID 1 will be tested first. If ICE 255 connectivity check is successful then other candidate pairs with the 256 same foundation will be unfrozen ([RFC5245] section 5.7.4. Computing 257 States). 259 The local and remote agent can have different algorithms for choosing 260 the local preference and type preference values without impacting the 261 synchronization between the local and remote check lists. 263 The check list is made up of candidate pairs. A candidate pair is 264 two candidates paired up and given a candidate pair priority as 265 described in [RFC5245] section 5.7.2. Using the pair priority 266 formula: 268 pair priority = 2^32*MIN(G,D) + 2*MAX(G,D) + (G>D?1:0) 270 Where G is the candidate priority provided by the controlling agent 271 and D the candidate priority provided by the controlled agent. This 272 ensures that the local and remote check lists are coordinated. 274 Even if the two agents have different algorithms for choosing the 275 candidate priority value to get an intermingled set of IPv4 and IPv6 276 candidates, the resulting checklist, that is a list sorted by the 277 pair priority value, will be identical on the two agents. 279 The agent that has promoted IPv4 cautiously i.e. lower IPv4 candidate 280 priority values compared to the other agent, will influence the check 281 list the most due to (2^32*MIN(G,D)) in the formula. 283 These recommendations are backward compatible with a standard ICE 284 implementation. The resulting local and remote checklist will still 285 be synchronized. The introduced fairness might be better, but not 286 worse than what exists today 288 If aggressive nomination is in use the procedures described in this 289 document might change what candidate pair ends up as the active one. 291 A test implementation of an example algorithm is available at 292 [ICE_dualstack_imp]. 294 6. IANA Considerations 296 None. 298 7. Implementation Status 300 [Note to RFC Editor: Please remove this section and reference to 301 [RFC6982] prior to publication.] 303 This section records the status of known implementations of the 304 protocol defined by this specification at the time of posting of this 305 Internet-Draft, and is based on a proposal described in [RFC6982]. 306 The description of implementations in this section is intended to 307 assist the IETF in its decision processes in progressing drafts to 308 RFCs. Please note that the listing of any individual implementation 309 here does not imply endorsement by the IETF. Furthermore, no effort 310 has been spent to verify the information presented here that was 311 supplied by IETF contributors. This is not intended as, and must not 312 be construed to be, a catalog of available implementations or their 313 features. Readers are advised to note that other implementations may 314 exist. 316 According to [RFC6982], "this will allow reviewers and working groups 317 to assign due consideration to documents that have the benefit of 318 running code, which may serve as evidence of valuable experimentation 319 and feedback that have made the implemented protocols more mature. 320 It is up to the individual working groups to use this information as 321 they see fit". 323 7.1. ICE-Dual Starck Fairness Test code 325 Organization: Cisco 327 Description: Open-Source ICE, TURN and STUN implementation. 329 Implementation: https://github.com/palerikm/ICE-DualStackFairness 331 Level of maturity: Code is stable. Tests 333 Coverage: Follows the recommendations in this document 335 Licensing: BSD 337 Implementation experience: Straightforward as there are no 338 compatibility issues. 340 Contact: Paal-Erik Martinsen palmarti@cisco.com 342 7.2. ICE-Dual Starck Fairness Test code 344 Organization: Others 346 Description: Major ICE implementations, browser based and stand- 347 alone ICE, TURN and STUN implementations. 349 Implementation: Product specific. 351 Level of maturity: Code is stable and available in the wild. 353 Coverage: Implements the recommendations in this document. 355 Licensing: Some open source, some close source 357 Implementation experience: Already implemented in some of the 358 implementations. This document describes what needs to be done to 359 achieve the desired fairness. 361 8. Security Considerations 363 STUN connectivity check using MAC computed during key exchanged in 364 the signaling channel provides message integrity and data origin 365 authentication as described in section 2.5 of [RFC5245] apply to this 366 use. 368 9. Acknowledgements 370 Authors would like to thank Dan Wing, Ari Keranen, Bernard Aboba, 371 Martin Thomson, Jonathan Lennox, Balint Menyhart, Ole Troan and Simon 372 Perreault for their comments and review. 374 10. References 376 10.1. Normative References 378 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 379 Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/ 380 RFC2119, March 1997, 381 . 383 [RFC3484] Draves, R., "Default Address Selection for Internet 384 Protocol version 6 (IPv6)", RFC 3484, DOI 10.17487/ 385 RFC3484, February 2003, 386 . 388 [RFC5245] Rosenberg, J., "Interactive Connectivity Establishment 389 (ICE): A Protocol for Network Address Translator (NAT) 390 Traversal for Offer/Answer Protocols", RFC 5245, DOI 391 10.17487/RFC5245, April 2010, 392 . 394 [RFC6555] Wing, D. and A. Yourtchenko, "Happy Eyeballs: Success with 395 Dual-Stack Hosts", RFC 6555, DOI 10.17487/RFC6555, April 396 2012, . 398 [RFC6724] Thaler, D., Ed., Draves, R., Matsumoto, A., and T. Chown, 399 "Default Address Selection for Internet Protocol Version 6 400 (IPv6)", RFC 6724, DOI 10.17487/RFC6724, September 2012, 401 . 403 [RFC6982] Sheffer, Y. and A. Farrel, "Improving Awareness of Running 404 Code: The Implementation Status Section", RFC 6982, DOI 405 10.17487/RFC6982, July 2013, 406 . 408 10.2. Informative References 410 [ICE_dualstack_imp] 411 Martinsen, P., "ICE DualStack Test Implementation github 412 repo", . 415 Authors' Addresses 417 Paal-Erik Martinsen 418 Cisco Systems, Inc. 419 Philip Pedersens Vei 22 420 Lysaker, Akershus 1325 421 Norway 423 Email: palmarti@cisco.com 425 Tirumaleswar Reddy 426 Cisco Systems, Inc. 427 Cessna Business Park, Varthur Hobli 428 Sarjapur Marathalli Outer Ring Road 429 Bangalore, Karnataka 560103 430 India 432 Email: tireddy@cisco.com 434 Prashanth Patil 435 Cisco Systems, Inc. 436 Bangalore 437 India 439 Email: praspati@cisco.com