idnits 2.17.1 draft-ietf-shim6-proto-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** It looks like you're using RFC 3978 boilerplate. You should update this to the boilerplate described in the IETF Trust License Policy document (see https://trustee.ietf.org/license-info), which is required now. -- Found old boilerplate from RFC 3978, Section 5.1 on line 16. -- Found old boilerplate from RFC 3978, Section 5.5 on line 5228. -- Found old boilerplate from RFC 3979, Section 5, paragraph 1 on line 5205. -- Found old boilerplate from RFC 3979, Section 5, paragraph 2 on line 5212. -- Found old boilerplate from RFC 3979, Section 5, paragraph 3 on line 5218. ** This document has an original RFC 3978 Section 5.4 Copyright Line, instead of the newer IETF Trust Copyright according to RFC 4748. ** This document has an original RFC 3978 Section 5.5 Disclaimer, instead of the newer disclaimer which includes the IETF Trust according to RFC 4748. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- == No 'Intended status' indicated for this document; assuming Proposed Standard Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the RFC 3978 Section 5.4 Copyright Line does not match the current year == Line 3140 has weird spacing: '...payload exten...' == The document seems to lack the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. (The document does seem to have the reference to RFC 2119 which the ID-Checklist requires). -- The document seems to lack a disclaimer for pre-RFC5378 work, but may have content which was first submitted before 10 November 2008. If you have contacted all the original authors and they are all willing to grant the BCP78 rights to the IETF Trust, then this is fine, and you can ignore this comment. If not, you may need to add the pre-RFC5378 disclaimer. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (October 23, 2006) is 6387 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Looks like a reference, but probably isn't: 'CGA' on line 3805 -- Looks like a reference, but probably isn't: 'FII' on line 2216 == Unused Reference: '4' is defined on line 5092, but no explicit reference was found in the text == Unused Reference: '11' is defined on line 5120, but no explicit reference was found in the text == Unused Reference: '23' is defined on line 5159, but no explicit reference was found in the text == Unused Reference: '24' is defined on line 5164, but no explicit reference was found in the text == Unused Reference: '26' is defined on line 5171, but no explicit reference was found in the text ** Obsolete normative reference: RFC 2460 (ref. '2') (Obsoleted by RFC 8200) ** Obsolete normative reference: RFC 2461 (ref. '3') (Obsoleted by RFC 4861) ** Obsolete normative reference: RFC 2462 (ref. '4') (Obsoleted by RFC 4862) ** Obsolete normative reference: RFC 2463 (ref. '5') (Obsoleted by RFC 4443) == Outdated reference: A later version (-05) exists of draft-ietf-shim6-hba-01 == Outdated reference: A later version (-13) exists of draft-ietf-shim6-failure-detection-06 -- Obsolete informational reference (is this intentional?): RFC 3041 (ref. '11') (Obsoleted by RFC 4941) -- Obsolete informational reference (is this intentional?): RFC 3484 (ref. '12') (Obsoleted by RFC 6724) -- Obsolete informational reference (is this intentional?): RFC 3697 (ref. '16') (Obsoleted by RFC 6437) == Outdated reference: A later version (-08) exists of draft-ietf-shim6-applicability-01 == Outdated reference: A later version (-10) exists of draft-ietf-hip-base-06 Summary: 7 errors (**), 0 flaws (~~), 13 warnings (==), 12 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 SHIM6 WG E. Nordmark 3 Internet-Draft Sun Microsystems 4 Expires: April 26, 2007 M. Bagnulo 5 UC3M 6 October 23, 2006 8 Level 3 multihoming shim protocol 9 draft-ietf-shim6-proto-06.txt 11 Status of this Memo 13 By submitting this Internet-Draft, each author represents that any 14 applicable patent or other IPR claims of which he or she is aware 15 have been or will be disclosed, and any of which he or she becomes 16 aware will be disclosed, in accordance with Section 6 of BCP 79. 18 Internet-Drafts are working documents of the Internet Engineering 19 Task Force (IETF), its areas, and its working groups. Note that 20 other groups may also distribute working documents as Internet- 21 Drafts. 23 Internet-Drafts are draft documents valid for a maximum of six months 24 and may be updated, replaced, or obsoleted by other documents at any 25 time. It is inappropriate to use Internet-Drafts as reference 26 material or to cite them other than as "work in progress." 28 The list of current Internet-Drafts can be accessed at 29 http://www.ietf.org/ietf/1id-abstracts.txt. 31 The list of Internet-Draft Shadow Directories can be accessed at 32 http://www.ietf.org/shadow.html. 34 This Internet-Draft will expire on April 26, 2007. 36 Copyright Notice 38 Copyright (C) The Internet Society (2006). 40 Abstract 42 The SHIM6 protocol is a layer 3 shim for providing locator agility 43 below the transport protocols, so that multihoming can be provided 44 for IPv6 with failover and load sharing properties, without assuming 45 that a multihomed site will have a provider independent IPv6 address 46 prefix which is announced in the global IPv6 routing table. The 47 hosts in a site which has multiple provider allocated IPv6 address 48 prefixes, will use the shim6 protocol specified in this document to 49 setup state with peer hosts, so that the state can later be used to 50 failover to a different locator pair, should the original one stop 51 working. 53 Table of Contents 55 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 5 56 1.1. Goals . . . . . . . . . . . . . . . . . . . . . . . . . . 5 57 1.2. Non-Goals . . . . . . . . . . . . . . . . . . . . . . . . 6 58 1.3. Locators as Upper-layer Identifiers . . . . . . . . . . . 6 59 1.4. IP Multicast . . . . . . . . . . . . . . . . . . . . . . 7 60 1.5. Renumbering Implications . . . . . . . . . . . . . . . . 8 61 1.6. Placement of the shim . . . . . . . . . . . . . . . . . . 9 62 1.7. Traffic Engineering . . . . . . . . . . . . . . . . . . . 10 63 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 12 64 2.1. Definitions . . . . . . . . . . . . . . . . . . . . . . . 12 65 2.2. Notational Conventions . . . . . . . . . . . . . . . . . 15 66 3. Assumptions . . . . . . . . . . . . . . . . . . . . . . . . . 16 67 4. Protocol Overview . . . . . . . . . . . . . . . . . . . . . . 17 68 4.1. Context Tags . . . . . . . . . . . . . . . . . . . . . . 19 69 4.2. Context Forking . . . . . . . . . . . . . . . . . . . . . 19 70 4.3. API Extensions . . . . . . . . . . . . . . . . . . . . . 20 71 4.4. Securing shim6 . . . . . . . . . . . . . . . . . . . . . 20 72 4.5. Overview of Shim Control Messages . . . . . . . . . . . . 21 73 4.6. Extension Header Order . . . . . . . . . . . . . . . . . 22 74 5. Message Formats . . . . . . . . . . . . . . . . . . . . . . . 24 75 5.1. Common shim6 Message Format . . . . . . . . . . . . . . . 24 76 5.2. Payload Extension Header Format . . . . . . . . . . . . . 24 77 5.3. Common Shim6 Control header . . . . . . . . . . . . . . . 25 78 5.4. I1 Message Format . . . . . . . . . . . . . . . . . . . . 27 79 5.5. R1 Message Format . . . . . . . . . . . . . . . . . . . . 28 80 5.6. I2 Message Format . . . . . . . . . . . . . . . . . . . . 29 81 5.7. R2 Message Format . . . . . . . . . . . . . . . . . . . . 31 82 5.8. R1bis Message Format . . . . . . . . . . . . . . . . . . 33 83 5.9. I2bis Message Format . . . . . . . . . . . . . . . . . . 34 84 5.10. Update Request Message Format . . . . . . . . . . . . . . 36 85 5.11. Update Acknowledgement Message Format . . . . . . . . . . 38 86 5.12. Keepalive Message Format . . . . . . . . . . . . . . . . 39 87 5.13. Probe Message Format . . . . . . . . . . . . . . . . . . 39 88 5.14. Option Formats . . . . . . . . . . . . . . . . . . . . . 40 89 5.14.1. Responder Validator Option Format . . . . . . . . . 42 90 5.14.2. Locator List Option Format . . . . . . . . . . . . . 42 91 5.14.3. Locator Preferences Option Format . . . . . . . . . 44 92 5.14.4. CGA Parameter Data Structure Option Format . . . . . 46 93 5.14.5. CGA Signature Option Format . . . . . . . . . . . . 46 94 5.14.6. ULID Pair Option Format . . . . . . . . . . . . . . 47 95 5.14.7. Forked Instance Identifier Option Format . . . . . . 48 96 5.14.8. Probe Option Format . . . . . . . . . . . . . . . . 48 97 5.14.9. Reachability Option Format . . . . . . . . . . . . . 49 98 5.14.10. Payload Reception Report Option Format . . . . . . . 49 99 6. Conceptual Model of a Host . . . . . . . . . . . . . . . . . 50 100 6.1. Conceptual Data Structures . . . . . . . . . . . . . . . 50 101 6.2. Context States . . . . . . . . . . . . . . . . . . . . . 51 102 7. Establishing ULID-Pair Contexts . . . . . . . . . . . . . . . 53 103 7.1. Uniqueness of Context Tags . . . . . . . . . . . . . . . 53 104 7.2. Locator Verification . . . . . . . . . . . . . . . . . . 53 105 7.3. Normal context establishment . . . . . . . . . . . . . . 54 106 7.4. Concurrent context establishment . . . . . . . . . . . . 54 107 7.5. Context recovery . . . . . . . . . . . . . . . . . . . . 56 108 7.6. Context confusion . . . . . . . . . . . . . . . . . . . . 58 109 7.7. Sending I1 messages . . . . . . . . . . . . . . . . . . . 59 110 7.8. Retransmitting I1 messages . . . . . . . . . . . . . . . 59 111 7.9. Receiving I1 messages . . . . . . . . . . . . . . . . . . 60 112 7.10. Sending R1 messages . . . . . . . . . . . . . . . . . . . 61 113 7.10.1. Generating the R1 Validator . . . . . . . . . . . . 61 114 7.11. Receiving R1 messages and sending I2 messages . . . . . . 62 115 7.12. Retransmitting I2 messages . . . . . . . . . . . . . . . 63 116 7.13. Receiving I2 messages . . . . . . . . . . . . . . . . . . 63 117 7.14. Sending R2 messages . . . . . . . . . . . . . . . . . . . 65 118 7.15. Match for Context Confusion . . . . . . . . . . . . . . . 65 119 7.16. Receiving R2 messages . . . . . . . . . . . . . . . . . . 66 120 7.17. Sending R1bis messages . . . . . . . . . . . . . . . . . 67 121 7.17.1. Generating the R1bis Validator . . . . . . . . . . . 67 122 7.18. Receiving R1bis messages and sending I2bis messages . . . 68 123 7.19. Retransmitting I2bis messages . . . . . . . . . . . . . . 69 124 7.20. Receiving I2bis messages and sending R2 messages . . . . 69 125 8. Handling ICMP Error Messages . . . . . . . . . . . . . . . . 71 126 9. Teardown of the ULID-Pair Context . . . . . . . . . . . . . . 73 127 10. Updating the Peer . . . . . . . . . . . . . . . . . . . . . . 74 128 10.1. Sending Update Request messages . . . . . . . . . . . . . 74 129 10.2. Retransmitting Update Request messages . . . . . . . . . 74 130 10.3. Newer Information While Retransmitting . . . . . . . . . 75 131 10.4. Receiving Update Request messages . . . . . . . . . . . . 75 132 10.5. Receiving Update Acknowledgement messages . . . . . . . . 77 133 11. Sending ULP Payloads . . . . . . . . . . . . . . . . . . . . 78 134 11.1. Sending ULP Payload after a Switch . . . . . . . . . . . 78 135 12. Receiving Packets . . . . . . . . . . . . . . . . . . . . . . 80 136 12.1. Receiving Payload Extension Headers . . . . . . . . . . . 80 137 12.2. Receiving Shim Control messages . . . . . . . . . . . . . 80 138 12.3. Context Lookup . . . . . . . . . . . . . . . . . . . . . 81 139 13. Initial Contact . . . . . . . . . . . . . . . . . . . . . . . 83 140 14. Protocol constants . . . . . . . . . . . . . . . . . . . . . 84 141 15. Implications Elsewhere . . . . . . . . . . . . . . . . . . . 85 142 16. Security Considerations . . . . . . . . . . . . . . . . . . . 87 143 17. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 89 144 18. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 91 145 Appendix A. Possible Protocol Extensions . . . . . . . . . . 92 146 Appendix B. Simplified State Machine . . . . . . . . . . . . 94 147 Appendix B.1. Simplified State Machine diagram . . . . . . . . 100 148 Appendix C. Context Tag Reuse . . . . . . . . . . . . . . . . 101 149 Appendix C.1. Context Recovery . . . . . . . . . . . . . . . . 101 150 Appendix C.2. Context Confusion . . . . . . . . . . . . . . . . 101 151 Appendix C.3. Three Party Context Confusion . . . . . . . . . . 102 152 Appendix D. Design Alternatives . . . . . . . . . . . . . . . 103 153 Appendix D.1. Context granularity . . . . . . . . . . . . . . . 103 154 Appendix D.2. Demultiplexing of data packets in shim6 155 communications . . . . . . . . . . . . . . . . . 103 156 Appendix D.2.1. Flow-label . . . . . . . . . . . . . . . . . . . 104 157 Appendix D.2.2. Extension Header . . . . . . . . . . . . . . . . 106 158 Appendix D.3. Context Loss Detection . . . . . . . . . . . . . 107 159 Appendix D.4. Securing locator sets . . . . . . . . . . . . . . 109 160 Appendix D.5. ULID-pair context establishment exchange . . . . 112 161 Appendix D.6. Updating locator sets . . . . . . . . . . . . . . 113 162 Appendix D.7. State Cleanup . . . . . . . . . . . . . . . . . . 113 163 Appendix E. Change Log . . . . . . . . . . . . . . . . . . . 116 164 19. References . . . . . . . . . . . . . . . . . . . . . . . . . 120 165 19.1. Normative References . . . . . . . . . . . . . . . . . . 120 166 19.2. Informative References . . . . . . . . . . . . . . . . . 120 167 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 122 168 Intellectual Property and Copyright Statements . . . . . . . . . 123 170 1. Introduction 172 This document describes a layer 3 shim approach and protocol for 173 providing locator agility below the transport protocols, so that 174 multihoming can be provided for IPv6 with failover and load sharing 175 properties [15], without assuming that a multihomed site will have a 176 provider independent IPv6 address which is announced in the global 177 IPv6 routing table. The hosts in a site which has multiple provider 178 allocated IPv6 address prefixes, will use the shim6 protocol 179 specified in this document to setup state with peer hosts, so that 180 the state can later be used to failover to a different locator pair, 181 should the original one stop working. 183 We assume that redirection attacks are prevented using the mechanism 184 specified in HBA [7]. 186 The reachability and failure detection mechanisms, including how a 187 new working locator pair is discovered after a failure, is specified 188 in a separate document [8] This document allocates message types and 189 option types for that sub-protocol, and leaves the specification of 190 the message and option formats as well as the protocol behavior to 191 that document. 193 1.1. Goals 195 The goals for this approach is to: 197 o Preserve established communications in the presence of certain 198 classes of failures, for example, TCP connections and UDP streams. 200 o Have minimal impact on upper layer protocols in general and on 201 transport protocols in particular. 203 o Address the security threats in [19] through the combination of 204 the HBA/CGA approach specified in a separate document [7] and 205 techniques described in this document. 207 o Not require extra roundtrip up front to setup shim specific state. 208 Instead allow the upper layer traffic (e.g., TCP) to flow as 209 normal and defer the setup of the shim state until some number of 210 packets have been exchanged. 212 o Take advantage of multiple locators/addresses for load spreading 213 so that different sets of communication to a host (e.g., different 214 connections) might use different locators of the host. Note that 215 this might cause load to be spread unevenly, thus we use the term 216 "load spreading" instead of "load balancing". This capability 217 might enable some forms of traffic engineering, but the details 218 for traffic engineering, including what requirements can be 219 satisfied, are not specified in this document, and form part of a 220 potential extensions to this protocol. 222 1.2. Non-Goals 224 The assumption is that the problem we are trying to solve is site 225 multihoming, with the ability to have the set of site prefixes change 226 over time due to site renumbering. Further, we assume that such 227 changes to the set of locator prefixes can be relatively slow and 228 managed; slow enough to allow updates to the DNS to propagate (since 229 the protocol defined in this document depends on the DNS to find the 230 appropriate locator sets). Note, however that it is an explicit non- 231 goal to make communication survive a renumbering event (which causes 232 all the locators of a host to change to a new set of locators). This 233 proposal does not attempt to solve the related problem of host 234 mobility. However, it might turn out that the shim6 protocol can be 235 a useful component for future host mobility solutions, e.g., for 236 route optimization. 238 Finally, this proposal also does not try to provide a new network 239 level or transport level identifier name space distinct from the 240 current IP address name space. Even though such a concept would be 241 useful to Upper Layer Protocols (ULPs) and applications, especially 242 if the management burden for such a name space was negligible and 243 there was an efficient yet secure mechanism to map from identifiers 244 to locators, such a name space isn't necessary (and furthermore 245 doesn't seem to help) to solve the multihoming problem. 247 1.3. Locators as Upper-layer Identifiers 249 The approach described in this document does not introduce a new 250 identifier name space but instead uses the locator that is selected 251 in the initial contact with the remote peer as the preserved Upper- 252 Layer Identifier (ULID). While there may be subsequent changes in 253 the selected network level locators over time in response to failures 254 in using the original locator, the upper level protocol stack 255 elements will continue to use this upper level identifier without 256 change. 258 This implies that the ULID selection is performed as today's default 259 address selection as specified in RFC 3484 [12]. Some extensions are 260 needed to RFC 3484 to try different source addresses, whether or not 261 the shim6 protocol is used, as outlined in [13]. Underneath, and 262 transparently, the multihoming shim selects working locator pairs 263 with the initial locator pair being the ULID pair. If communication 264 subsequently fails the shim can test and select alternate locators. 265 A subsequent section discusses the issues when the selected ULID is 266 not initially working hence there is a need to switch locators up 267 front. 269 Using one of the locators as the ULID has certain benefits for 270 applications which have long-lived session state or performs 271 callbacks or referrals, because both the FQDN and the 128-bit ULID 272 work as handles for the applications. However, using a single 128- 273 bit ULID doesn't provide seamless communication when that locator is 274 unreachable. See [22] for further discussion of the application 275 implications. 277 There has been some discussion of using non-routable addresses, such 278 as Unique-Local Addresses (ULAs) [18], as ULIDs in a multihoming 279 solution. While this document doesn't specify all aspects of this, 280 it is believed that the approach can be extended to handle the non- 281 routable address case.. For example, the protocol already needs to 282 handle ULIDs that are not initially reachable. Thus the same 283 mechanism can handle ULIDs that are permanently unreachable from 284 outside their site. The issue becomes how to make the protocol 285 perform well when the ULID is known a priori to be not reachable 286 (e.g., the ULID is a ULA), for instance, avoiding any timeout and 287 retries in this case. In addition one would need to understand how 288 the ULAs would be entered in the DNS to avoid a performance impact on 289 existing, non-shim6 aware, IPv6 hosts potentially trying to 290 communicate to the (unreachable) ULA. 292 1.4. IP Multicast 294 IP Multicast requires that the IP source address field contain a 295 topologically correct locator for interface that is used to send the 296 packet, since IP multicast routing uses both the source address and 297 the destination group to determine where to forward the packet. In 298 particular, it need to be able to do the RPF check. (This isn't much 299 different than the situation with widely implemented ingress 300 filtering [10] for unicast.) 302 While in theory it would be possible to apply the shim re-mapping of 303 the IP address fields between ULIDs and locators, the fact that all 304 the multicast receivers would need to know the mapping to perform, 305 makes such an approach difficult in practice. Thus it makes sense to 306 have multicast ULPs operate directly on locators and not use the 307 shim. This is quite a natural fit for protocols which use RTP [14], 308 since RTP already has an explicit identifier in the form of the SSRC 309 field in the RTP headers. Thus the actual IP address fields are not 310 important to the application. 312 In summary, IP multicast will not need the shim to remap the IP 313 addresses. 315 This doesn't prevent the receiver of multicast to change its 316 locators, since the receiver is not explicitly identified; the 317 destination address is a multicast address and not the unicast 318 locator of the receiver. 320 1.5. Renumbering Implications 322 As stated above, this approach does not try to make communication 323 survive renumbering in the general case. 325 When a host is renumbered, the effect is that one or more locators 326 become invalid, and zero or more locators are added to the host's 327 network interface. This means that the set of locators that is used 328 in the shim will change, which the shim can handle as long as not all 329 the original locators become invalid at the same time and depending 330 on the time that is required to update the DNS and for those updates 331 to propagate. 333 But IP addresses are also used as ULID, and making the communication 334 survive locators becoming invalid can potentially cause some 335 confusion at the upper layers. The fact that a ULID might be used 336 with a different locator over time open up the possibility that 337 communication between two ULIDs might continue to work after one or 338 both of those ULIDs are no longer reachable as locators, for example 339 due to a renumbering event. This opens up the possibility that the 340 ULID (or at least the prefix on which it is based) is reassigned to 341 another site while it is still being used (with another locator) for 342 existing communication. 344 In the worst case we could end up with two separate hosts using the 345 same ULID while both of them are communicating with the same host. 347 This potential source for confusion can be avoided if we require that 348 any communication using a ULID must be terminated when the ULID 349 becomes invalid (due to the underlying prefix becoming invalid). If 350 that behavior is desired, it can be accomplished by explicitly 351 discarding the shim state when the ULID becomes invalid. The context 352 recovery mechanism will then make the peer aware that the context is 353 gone, and that the ULID is no longer present at the same locator(s). 355 1.6. Placement of the shim 357 ----------------------- 358 | Transport Protocols | 359 ----------------------- 361 ------ ------- -------------- ------------- IP endpoint 362 | AH | | ESP | | Frag/reass | | Dest opts | sub-layer 363 ------ ------- -------------- ------------- 365 --------------------- 366 | shim6 shim layer | 367 --------------------- 369 ------ IP routing 370 | IP | sub-layer 371 ------ 373 Figure 1: Protocol stack 375 The proposal uses a multihoming shim layer within the IP layer, i.e., 376 below the ULPs, as shown in Figure 1, in order to provide ULP 377 independence. The multihoming shim layer behaves as if it is 378 associated with an extension header, which would be placed after any 379 routing-related headers in the packet (such as any hop-by-hop 380 options, or routing header). However, when the locator pair is the 381 ULID pair there is no data that needs to be carried in an extension 382 header, thus none is needed in that case. 384 Layering AH and ESP above the multihoming shim means that IPsec can 385 be made to be unaware of locator changes the same way that transport 386 protocols can be unaware. Thus the IPsec security associations 387 remain stable even though the locators are changing. This means that 388 the IP addresses specified in the selectors should be the ULIDs. 390 Layering the fragmentation header above the multihoming shim makes 391 reassembly robust in the case that there is broken multi-path routing 392 which results in using different paths, hence potentially different 393 source locators, for different fragments. Thus, effectively the 394 multihoming shim layer is placed between the IP endpoint sublayer, 395 which handles fragmentation, reassembly, and IPsec, and the IP 396 routing sublayer, which selects which next hop and interface to use 397 for sending out packets. 399 Applications and upper layer protocols use ULIDs which the shim6 400 layer map to/from different locators. The shim6 layer maintains 401 state, called ULID-pair context, per ULID pairs (that is, applies to 402 all ULP connections between the ULID pair) in order to perform this 403 mapping. The mapping is performed consistently at the sender and the 404 receiver so that ULPs see packets that appear to be sent using ULIDs 405 from end to end. This property is maintained even though the packets 406 travel through the network containing locators in the IP address 407 fields, and even though those locators may be changed by the 408 transmitting shim6 layer. . 410 The context state is maintained per remote ULID i.e. approximately 411 per peer host, and not at any finer granularity. In particular, it 412 is independent of the ULPs and any ULP connections. However, the 413 forking capability enables shim-aware ULPs to use more than one 414 locator pair at a time for an single ULID pair. 416 ---------------------------- ---------------------------- 417 | Sender A | | Receiver B | 418 | | | | 419 | ULP | | ULP | 420 | | src ULID(A)=L1(A) | | ^ | 421 | | dst ULID(B)=L1(B) | | | src ULID(A)=L1(A) | 422 | v | | | dst ULID(B)=L1(B) | 423 | multihoming shim | | multihoming shim | 424 | | src L2(A) | | ^ | 425 | | dst L3(B) | | | src L2(A) | 426 | v | | | dst L3(B) | 427 | IP | | IP | 428 ---------------------------- ---------------------------- 429 | ^ 430 ------- cloud with some routers ------- 432 Figure 2: Mapping with changed locators 434 The result of this consistent mapping is that there is no impact on 435 the ULPs. In particular, there is no impact on pseudo-header 436 checksums and connection identification. 438 Conceptually, one could view this approach as if both ULIDs and 439 locators are being present in every packet, and with a header 440 compression mechanism applied that removes the need for the ULIDs to 441 be carried in the packets once the compression state has been 442 established. In order for the receiver to recreate a packet with the 443 correct ULIDs there is a need to include some "compression tag" in 444 the data packets. This serves to indicate the correct context to use 445 for decompression when the locator pair in the packet is insufficient 446 to uniquely identify the context. 448 1.7. Traffic Engineering 450 At the time of this writing it is not clear what requirements for 451 traffic engineering make sense for the shim6 protocol, since the 452 requirements must both result in some useful behavior as well as be 453 implementable using a host-to-host locator agility mechanism like 454 shim6. 456 Inherent in a scalable multihoming mechanism that separates locators 457 from identifiers is that each host ends up with multiple locators. 458 This means that at least for initial contact, it is the remote peer 459 that needs to select which peer locator to try first. In the case of 460 shim6 this is performed by applying RFC 3484 address selection. 462 This is quite different than the common case of IPv4 multihoming 463 where the site has a single IP address prefix, since in that case the 464 peer performs no destination address selection. 466 Thus in "single prefix multihoming" the site, and in many cases its 467 upstream ISPs, can use BGP to exert some control of the ingress path 468 used to reach the site. This capability can't easily be recreated in 469 "multiple prefix multihoming" such as shim6. 471 The protocol provides a placeholder, in the form of the Locator 472 Preferences option, which can be used by hosts to express priority 473 and weight values for each locator. This is intentionally made 474 identical to the DNS SRV [9] specification of priority and weight, so 475 that DNS SRV records can be used for initial contact and the shim for 476 failover, and they can use the same way to describe the preferences. 477 But the Locator Preference option is merely a place holder when it 478 comes to providing traffic engineering; in order to use this in a 479 large site there would have to be a mechanism by which the host can 480 find out what preference values to use, either statically (e.g., some 481 new DHCPv6 option) or dynamically. 483 Thus traffic engineering is listed as a possible extension in 484 Appendix A. 486 2. Terminology 488 This document uses the terms MUST, SHOULD, RECOMMENDED, MAY, SHOULD 489 NOT and MUST NOT defined in RFC 2119 [1]. The terms defined in RFC 490 2460 [2] are also used. 492 2.1. Definitions 494 This document introduces the following terms: 496 upper layer protocol (ULP) 497 A protocol layer immediately above IP. Examples 498 are transport protocols such as TCP and UDP, 499 control protocols such as ICMP, routing protocols 500 such as OSPF, and internet or lower-layer 501 protocols being "tunneled" over (i.e., 502 encapsulated in) IP such as IPX, AppleTalk, or IP 503 itself. 505 interface A node's attachment to a link. 507 address An IP layer name that contains both topological 508 significance and acts as a unique identifier for 509 an interface. 128 bits. This document only uses 510 the "address" term in the case where it isn't 511 specific whether it is a locator or an 512 identifier. 514 locator An IP layer topological name for an interface or 515 a set of interfaces. 128 bits. The locators are 516 carried in the IP address fields as the packets 517 traverse the network. 519 identifier An IP layer name for an IP layer endpoint. The 520 transport endpoint name is a function of the 521 transport protocol and would typically include 522 the IP identifier plus a port number. 523 NOTE: This proposal does not specify any new form 524 of IP layer identifier, but still separates the 525 identifying and locating properties of the IP 526 addresses. 528 upper-layer identifier (ULID) 529 An IP address which has been selected for 530 communication with a peer to be used by the upper 531 layer protocol. 128 bits. This is used for 532 pseudo-header checksum computation and connection 533 identification in the ULP. Different sets of 534 communication to a host (e.g., different 535 connections) might use different ULIDs in order 536 to enable load spreading. 538 Since the ULID is just one of the IP locators/ 539 addresses of the node, there is no need for a 540 separate name space and allocation mechanisms. 542 address field The source and destination address fields in the 543 IPv6 header. As IPv6 is currently specified this 544 fields carry "addresses". If identifiers and 545 locators are separated these fields will contain 546 locators for packets on the wire. 548 FQDN Fully Qualified Domain Name 550 ULID-pair context The state that the multihoming shim maintains 551 between a pair of Upper-layer identifiers. The 552 context is identified by a context tag for each 553 direction of the communication, and also 554 identified by the pair of ULID and a Forked 555 Instance Identifier (see below). 557 Context tag Each end of the context allocates a context tag 558 for the context. This is used to uniquely 559 associate both received control packets and 560 payload extension headers as belonging to the 561 context. 563 Current locator pair 564 Each end of the context has a current locator 565 pair which is used to send packets to the peer. 566 The two ends might use different current locator 567 pairs though. 569 Default context At the sending end, the shim uses the ULID pair 570 (passed down from the ULP) to find the context 571 for that pair. Thus, normally, a host can have 572 at most one context for a ULID pair. We call 573 this the "default context". 575 Context forking A mechanism which allows ULPs that are aware of 576 multiple locators to use separate contexts for 577 the same ULID pair, in order to be able use 578 different locator pairs for different 579 communication to the same ULID. Context forking 580 causes more than just the default context to be 581 created for a ULID pair. 583 Forked Instance Identifier (FII) 584 In order to handle context forking, a context is 585 identified by a ULID-pair and a forked context 586 identifier. The default context has a FII of 587 zero. 589 Initial contact We use this term to refer to the pre-shim 590 communication when some ULP decides to start 591 communicating with a peer by sending and 592 receiving ULP packets. Typically this would not 593 invoke any operations in the shim, since the shim 594 can defer the context establishment until some 595 arbitrary later point in time. 597 Hash Based Addresses (HBA) 598 A form of IPv6 address where the interface ID is 599 derived from a cryptographic hash of all the 600 prefixes assigned to the host. See [7]. 602 Cryptographically Generated Addresses (CGA) 603 A form of IPv6 address where the interface ID is 604 derived from a cryptographic hash of the public 605 key. See [6]. 607 CGA Parameter Data Structure (PDS) 608 The information that CGA and HBA exchanges in 609 order to inform the peer of how the interface ID 610 was computed. See [6]., [7]. 612 2.2. Notational Conventions 614 A, B, and C are hosts. X is a potentially malicious host. 616 FQDN(A) is the Fully qualified Domain Name for A. 618 Ls(A) is the locator set for A, which consists of the locators L1(A), 619 L2(A), ... Ln(A). The locator set in not ordered in any particular 620 way other than maybe what is returned by the DNS. 622 ULID(A) is an upper-layer ID for A. In this proposal, ULID(A) is 623 always one member of A's locator set. 625 CT(X) is a context tag assigned by X. 627 This document also makes use of internal conceptual variables to 628 describe protocol behavior and external variables that an 629 implementation must allow system administrators to change. The 630 specific variable names, how their values change, and how their 631 settings influence protocol behavior are provided to demonstrate 632 protocol behavior. An implementation is not required to have them in 633 the exact form described here, so long as its external behavior is 634 consistent with that described in this document. See Section 6 for a 635 description of the conceptual data structures. 637 3. Assumptions 639 The design intent is to ensure that the shim6 protocol is capable of 640 handling path failures independently of the number of IP addresses 641 (locators) available to the two communicating hosts, and 642 independently of which host detects the failure condition. 644 Consider, for example, the case in which both A and B have active 645 shim6 state and where A has only one locator while B has multiple 646 locators. In this case, it might be that B is trying to send a 647 packet to A, and has detected a failure condition with the current 648 locator pair. Since B has multiple locators it presumably has 649 multiple ISPs, and consequently likely has alternate egress paths 650 toward A. However, B cannot vary the destination address (i.e., A's 651 locator), since A has only one locator. 653 The above scenario leads to the assumption that a host should be able 654 to cause different egress paths from its site to be used. The most 655 reasonable approach to accomplish this is to have the host use 656 different source addresses and have the source address affect the 657 selection of the site egress. The details of how this can be 658 accomplished is beyond the scope of this document, but without this 659 capability the ability of the shim to try different "paths" by trying 660 different locator pairs will have limited utility. 662 The above assumption applies whether or not the ISPs perform ingress 663 filtering. 665 In addition, when the site's ISPs perform ingress filtering based on 666 packet source addresses, shim6 assumes that packets sent with 667 different source and destination combinations have a reasonable 668 chance of making it through the relevant ISP's ingress filters. This 669 can be accomplished in several ways (all outside the scope of this 670 document), such as having the ISPs relax there ingress filters, or 671 selecting the egress such that it matches the IP source address 672 prefix. 674 Further discussion of this issue is captured in [20]. 676 The shim6 approach assumes that there are no IPv6-to-IPv6 NATs on the 677 paths, i.e., that the two ends can exchange their own notion of their 678 IPv6 addresses and that those addresses will also make sense to their 679 peer. 681 4. Protocol Overview 683 The shim6 protocol operates in several phases over time. The 684 following sequence illustrates the concepts: 686 o An application on host A decides to contact an application on host 687 B using some upper-layer protocol. This results in the ULP on 688 host A sending packets to host B. We call this the initial 689 contact. Assuming the IP addresses selected by Default Address 690 Selection [12] and its extensions [13] work, then there is no 691 action by the shim at this point in time. Any shim context 692 establishment can be deferred until later. 694 o Some heuristic on A or B (or both) determine that it is 695 appropriate to pay the shim6 overhead to make this host-to-host 696 communication robust against locator failures. For instance, this 697 heuristic might be that more than 50 packets have been sent or 698 received, or a timer expiration while active packet exchange is in 699 place. This makes the shim initiate the 4-way context 700 establishment exchange. 702 As a result of this exchange, both A and B will know a list of 703 locators for each other. 705 If the context establishment exchange fails, the initiator will 706 then know that the other end does not support shim6, and will 707 continue with standard unicast behavior for the session. 709 o Communication continues without any change for the ULP packets. 710 In particular, there are no shim extension headers added to the 711 ULP packets, since the ULID pair is the same as the locator pair. 712 In addition, there might be some messages exchanged between the 713 shim sub-layers for (un)reachability detection. 715 o At some point in time something fails. Depending on the approach 716 to reachability detection, there might be some advice from the 717 ULP, or the shim (un)reachability detection might discover that 718 there is a problem. 720 At this point in time one or both ends of the communication need 721 to probe the different alternate locator pairs until a working 722 pair is found, and switch to using that locator pair. 724 o Once a working alternative locator pair has been found, the shim 725 will rewrite the packets on transmit, and tag the packets with 726 shim6 Payload extension header, which contains the receiver's 727 context tag. The receiver will use the context tag to find the 728 context state which will indicate which addresses to place in the 729 IPv6 header before passing the packet up to the ULP. The result 730 is that from the perspective of the ULP the packet passes 731 unmodified end-to-end, even though the IP routing infrastructure 732 sends the packet to a different locator. 734 o The shim (un)reachability detection will monitor the new locator 735 pair as it monitored the original locator pair, so that subsequent 736 failures can be detected. 738 o In addition to failures detected based on end-to-end observations, 739 one endpoint might know for certain that one or more of its 740 locators is not working. For instance, the network interface 741 might have failed or gone down (at layer 2), or an IPv6 address 742 might have become deprecated or invalid. In such cases the host 743 can signal its peer that this address is no longer recommended to 744 try. This triggers something similar to a failure handling and a 745 new working locator pair must be found. 747 The protocol also has the ability to express other forms of 748 locator preferences. A change in any preferences can be signaled 749 to the peer, which will have made the peer record the new 750 preferences. A change in the preferences might optionally make 751 the peer want to use a different locator pair. In this case, the 752 peer follows the same locator switching procedure as after a 753 failure (by verifying that its peer is indeed present at the 754 alternate locator, etc). 756 o When the shim thinks that the context state is no longer used, it 757 can garbage collect the state; there is no coordination necessary 758 with the peer host before the state is removed. There is a 759 recovery message defined to be able to signal when there is no 760 context state, which can be used to detect and recover from both 761 premature garbage collection, as well as complete state loss 762 (crash and reboot) of a peer. 764 The exact mechanism to determine when the context state is no 765 longer used is implementation dependent. For example, an 766 implementation might use the existence of ULP state (where known 767 to the implementation) as an indication that the state is still 768 used, combined with a timer (to handle ULP state that might not be 769 known to the shim sub-layer) to determine when the state is likely 770 to no longer be used. 772 NOTE: The ULP packets in shim6 can be carried completely unmodified 773 as long as the ULID pair is used as the locator pair. After a switch 774 to a different locator pair the packets are "tagged" with a shim6 775 extension header, so that the receiver can always determine the 776 context to which they belong. This is accomplished by including an 777 8-octet shim6 Payload Extension header before the (extension) headers 778 that are processed by the IP endpoint sublayer and ULPs. If 779 subsequently the original ULIDs are selected as the active locator 780 pair then the tagging of packets with the shim6 extension header is 781 no longer necesary. 783 4.1. Context Tags 785 A context between two hosts is actually a context between two ULIDs. 786 The context is identified by a pair of context tags. Each end gets 787 to allocate a context tag, and once the context is established, most 788 shim6 control messages contain the context tag that the receiver of 789 the message allocated. Thus at a minimum the combination of have to uniquely identify one 791 context. But since the Payload extension headers are demultiplexed 792 without looking at the locators in the packet, the receiver will need 793 to allocate context tags that are unique for all its contexts. The 794 context tag is a 47-bit number (the largest which can fit in an 795 8-octet extension header). 797 The mechanism for detecting a loss of context state at the peer 798 assumes that the receiver can tell the packets that need locator 799 rewriting, even after it has lost all state (e.g., due to a crash 800 followed by a reboot). This is achieved because after a rehoming 801 event the packets that need receive-side rewriting, carry the Payload 802 extension header. 804 4.2. Context Forking 806 It has been asserted that it will be important for future ULPs, in 807 particular, future transport protocols, to be able to control which 808 locator pairs are used for different communication. For instance, 809 host A and host B might communicate using both VoIP traffic and ftp 810 traffic, and those communications might benefit from using different 811 locator pairs. However, the basic shim6 mechanism uses a single 812 current locator pair for each context, thus a single context cannot 813 accomplish this. 815 For this reason, the shim6 protocol supports the notion of context 816 forking. This is a mechanism by which a ULP can specify (using some 817 API not yet defined) that a context for e.g., the ULID pair 818 should be forked into two contexts. In this case the forked-off 819 context will be assigned a non-zero Forked Instance Identifier, while 820 the default context has FII zero. 822 The Forked Instance Identifier (FII) is a 32-bit identifier which has 823 no semantics in the protocol other then being part of the tuple which 824 identifies the context. For example, a host migth allocate FIIs as 825 sequential numbers for any given ULID pair. 827 No other special considerations are needed in the shim6 protocol to 828 handle forked contexts. 830 Note that forking as specified does NOT allow A to be able to tell B 831 that certain traffic (a 5-tuple?) should be forked for the reverse 832 direction. The shim6 forking mechanism as specified applies only to 833 the sending of ULP packets. If some ULP wants to fork for both 834 directions, it is up to the ULP to set this up, and then instruct the 835 shim at each end to transmit using the forked context. 837 4.3. API Extensions 839 Several API extensions have been discussed for shim6, but their 840 actual specification is out of scope for this document. The simplest 841 one would be to add a socket option to be able to have traffic bypass 842 the shim (not create any state, and not use any state created by 843 other traffic). This could be an IPV6_DONTSHIM socket option. Such 844 an option would be useful for protocols, such as DNS, where the 845 application has its own failover mechanism (multiple NS records in 846 the case of DNS) and using the shim could potentially add extra 847 latency with no added benefits. 849 Some other API extensions are discussed in Appendix A 851 4.4. Securing shim6 853 The mechanisms are secured using a combination of techniques: 855 o The HBA technique [7] for verifying the locators to prevent an 856 attacker from redirecting the packet stream to somewhere else. 858 o Requiring a Reachability Probe+Reply before a new locator is used 859 as the destination, in order to prevent 3rd party flooding 860 attacks. 862 o The first message does not create any state on the responder. 863 Essentially a 3-way exchange is required before the responder 864 creates any state. This means that a state-based DoS attack 865 (trying to use up all of memory on the responder) at least 866 provides an IPv6 address that the attacker was using. 868 o The context establishment messages use nonces to prevent replay 869 attacks, and to prevent off-path attackers from interfering with 870 the establishment. 872 o Every control message of the shim6 protocol, past the context 873 establishment, carry the context tag assigned to the particular 874 context. This implies that an attacker needs to discover that 875 context tag before being able to spoof any shim6 control message. 876 Such discovery probably requires to be along the path in order to 877 be sniff the context tag value. The result is that through this 878 technique, the shim6 protocol is protected against off-path 879 attackers. 881 4.5. Overview of Shim Control Messages 883 The shim6 context establishment is accomplished using four messages; 884 I1, R1, I2, R2. Normally they are sent in that order from initiator 885 and responder, respectively. Should both ends attempt to set up 886 context state at the same time (for the same ULID pair), then their 887 I1 messages might cross in flight, and result in an immediate R2 888 message. [The names of these messages are borrowed from HIP [25].] 890 R1bis and I2bis messages are defined, which are used to recover a 891 context after it has been lost. A R1bis message is sent when a shim6 892 control or Payload extension header arrives and there is no matching 893 context state at the receiver. When such a message is received, it 894 will result in the re-creation of the shim6 context using the I2bis 895 and R2 messages. 897 The peers' lists of locators are normally exchanged as part of the 898 context establishment exchange. But the set of locators might be 899 dynamic. For this reason there is a Update Request and Update 900 Acknowledgement messages, and a Locator List option. 902 Even when the list of locators is fixed, a host might determine that 903 some preferences might have changed. For instance, it might 904 determine that there is a locally visible failure that implies that 905 some locator(s) are no longer usable. This uses a Locator 906 Preferences option in the Update Request message. 908 The mechanism for (un)reachability detection is called Forced 909 Bidirectional Communication (FBD). FBD uses a Keepalive message 910 which is sent when a host has received packets from its peer but has 911 not yet sent any packets from its ULP to the peer. The message type 912 is reserved in this document, but the message format and processing 913 rules are specified in [8]. 915 In addition, when the context is established and there is a 916 subsequent failure there needs to be a way to probe the set of 917 locator pairs to efficiently find a working pair. This document 918 reserves an Probe message type, with the packet format and processing 919 rules specified in [8]. 921 The above probe and keepalive messages assume we have an established 922 ULID-pair context. However, communication might fail during the 923 initial contact (that is, when the application or transport protocol 924 is trying to setup some communication). This is handled using the 925 mechanisms in the ULP to try different address pairs as specified in 926 [12] [13]. In the future versions of the protocol, and with a richer 927 API between the ULP and the shim, the shim might be help optimize 928 discovering a working locator pair during initial contact. This is 929 for further study. 931 4.6. Extension Header Order 933 Since the shim is placed between the IP endpoint sub-layer and the IP 934 routing sub-layer, the shim header will be placed before any endpoint 935 extension headers (fragmentation headers, destination options header, 936 AH, ESP), but after any routing related headers (hop-by-hop 937 extensions header, routing header, a destinations options header 938 which precedes a routing header). When tunneling is used, whether 939 IP-in-IP tunneling or the special form of tunneling that Mobile IPv6 940 uses (with Home Address Options and Routing header type 2), there is 941 a choice whether the shim applies inside the tunnel or outside the 942 tunnel, which affects the location of the shim6 header. 944 In most cases IP-in-IP tunnels are used as a routing technique, thus 945 it makes sense to apply them on the locators which means that the 946 sender would insert the shim6 header after any IP-in-IP 947 encapsulation; this is what occurs naturally when routers apply IP- 948 in-IP encapsulation. Thus the packets would have: 950 o Outer IP header 952 o Inner IP header 954 o Shim6 extension header (if needed) 956 o ULP 958 But the shim can also be used to create "shimmed tunnels" i.e., where 959 an IP-in-IP tunnel uses the shim to be able to switch the tunnel 960 endpoint addresses between different locators. In such a case the 961 packets would have: 963 o Outer IP header 965 o Shim6 extension header (if needed) 967 o Inner IP header 969 o ULP 971 In any case, the receiver behavior is well-defined; a receiver 972 processes the extension headers in order. However, the precise 973 interaction between Mobile IPv6 and shim6 is for further study, but 974 it might make sense to have Mobile IPv6 operate on locators as well, 975 meaning that the shim would be layered on top of the MIPv6 mechanism. 977 5. Message Formats 979 The shim6 messages are all carried using a new IP protocol number [to 980 be assigned by IANA]. The shim6 messages have a common header, 981 defined below, with some fixed fields, followed by type specific 982 fields. 984 The shim6 messages are structured as an IPv6 extension header since 985 the Payload extension header is used to carry the ULP packets after a 986 locator switch. The shim6 control messages use the same extension 987 header formats so that a single "protocol number" needs to be allowed 988 through firewalls in order for shim6 to function across the firewall. 990 5.1. Common shim6 Message Format 992 The first 17 bits of the shim6 header is common for the Payload 993 extension header and the control messages and looks as follows: 995 0 1 996 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 997 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 998 | Next Header | Hdr Ext Len |P| 999 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1001 Fields: 1003 Next Header: The payload which follows this header. 1005 Hdr Ext Len: 8-bit unsigned integer. Length of the shim6 header in 1006 8-octet units, not including the first 8 octets. 1008 P: A single bit to distinguish Payload extension headers 1009 from control messages. 1011 5.2. Payload Extension Header Format 1013 The payload extension headers is used to carry ULP packets where the 1014 receiver must replace the content of the source and/or destination 1015 fields in the IPv6 header before passing the packet to the ULP. Thus 1016 this extension header is required when the locators pair that is used 1017 is not the same as the ULID pair. 1019 0 1 2 3 1020 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1021 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1022 | Next Header | 0 |1| | 1023 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1024 | Receiver Context Tag | 1025 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1027 Fields: 1029 Next Header: The payload which follows this header. 1031 Hdr Ext Len: 0 (since the header is 8 octets). 1033 P: Set to one. A single bit to distinguish this from the 1034 shim6 control messages. 1036 Receiver Context Tag: 47-bit unsigned integer. Allocated by the 1037 receiver for use to identify the context. 1039 5.3. Common Shim6 Control header 1041 The common part of the header has a next header and header extension 1042 length field which is consistent with the other IPv6 extension 1043 headers, even if the next header value is always "NO NEXT HEADER" for 1044 the control messages; only the payload extension header use the Next 1045 Header field. 1047 The shim6 headers must be a multiple of 8 octets, hence the minimum 1048 size is 8 octets. 1050 The common shim control message header is as follows: 1052 0 1 2 3 1053 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1054 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1055 | Next Header | Hdr Ext Len |0| Type |Type-specific|0| 1056 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1057 | Checksum | | 1058 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1059 | Type-specific format | 1060 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1062 Fields: 1064 Next Header: 8-bit selector. Normally set to NO_NXT_HDR (59). 1066 Hdr Ext Len: 8-bit unsigned integer. Length of the shim6 header in 1067 8-octet units, not including the first 8 octets. 1069 P: Set to zero. A single bit to distinguish this from 1070 the shim6 payload extension header. 1072 Type: 7-bit unsigned integer. Identifies the actual message 1073 from the table below. Type codes 0-63 will not 1074 trigger R1bis messages on a missing context, while 64- 1075 127 will trigger R1bis. 1077 0: A single bit (set to zero) which allows shim6 and HIP 1078 to have a common header format yet telling shim6 and 1079 HIP messages apart. 1081 Checksum: 16-bit unsigned integer. The checksum is the 16-bit 1082 one's complement of the one's complement sum of the 1083 entire shim6 header message starting with the shim6 1084 next header field, and ending as indicated by the Hdr 1085 Ext Len. Thus when there is a payload following the 1086 shim6 header, the payload is NOT included in the shim6 1087 checksum. Note that unlike protocol like ICMPv6, 1088 there is no pseudo-header checksum part of the 1089 checksum, in order to provide locator agility without 1090 having to change the checksum. 1092 Type-specific: Part of message that is different for different 1093 message types. 1095 +------------+-----------------------------------------------------+ 1096 | Type Value | Message | 1097 +------------+-----------------------------------------------------+ 1098 | 1 | I1 (first establishment message from the initiator) | 1099 | | | 1100 | 2 | R1 (first establishment message from the responder) | 1101 | | | 1102 | 3 | I2 (2nd establishment message from the initiator) | 1103 | | | 1104 | 4 | R2 (2nd establishment message from the responder) | 1105 | | | 1106 | 5 | R1bis (Reply to reference to non-existent context) | 1107 | | | 1108 | 6 | I2bis (Reply to a R1bis message) | 1109 | | | 1110 | 64 | Update Request | 1111 | | | 1112 | 65 | Update Acknowledgement | 1113 | | | 1114 | 66 | Keepalive | 1115 | | | 1116 | 67 | Probe Message | 1117 +------------+-----------------------------------------------------+ 1119 Table 1 1121 5.4. I1 Message Format 1123 The I1 message is the first message in the context establishment 1124 exchange. 1126 0 1 2 3 1127 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1128 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1129 | 59 | Hdr Ext Len |0| Type = 1 | Reserved1 |0| 1130 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1131 | Checksum |R| | 1132 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1133 | Initiator Context Tag | 1134 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1135 | Initiator Nonce | 1136 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1137 | | 1138 + Options + 1139 | | 1140 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1142 Fields: 1144 Next Header: NO_NXT_HDR (59). 1146 Hdr Ext Len: At least 1, since the header is 16 octets when there 1147 are no options. 1149 Type: 1 1151 Reserved1: 7-bit field. Reserved for future use. Zero on 1152 transmit. MUST be ignored on receipt. 1154 R: 1-bit field. Reserved for future use. Zero on 1155 transmit. MUST be ignored on receipt. 1157 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1158 has allocated for the context. 1160 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1161 the initiator which the responder will return in the 1162 R1 message. 1164 The following options are defined for this message: 1166 ULID pair: When the IPv6 source and destination addresses in the 1167 IPv6 header does not match the ULID pair, this option 1168 MUST be included. An example of this is when 1169 recovering from a lost context. 1171 Forked Instance Identifier: When another instance of an existent 1172 context with the same ULID pair is being created, a 1173 Forked Instance Identifier option is included to 1174 distinguish this new instance from the existent one. 1176 Future protocol extensions might define additional options for this 1177 message. The C-bit in the option format defines how such a new 1178 option will be handled by an implementation. See Section 5.14. 1180 5.5. R1 Message Format 1182 The R1 message is the second message in the context establishment 1183 exchange. The responder sends this in response to an I1 message, 1184 without creating any state specific to the initiator. 1186 0 1 2 3 1187 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1188 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1189 | 59 | Hdr Ext Len |0| Type = 2 | Reserved1 |0| 1190 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1191 | Checksum | Reserved2 | 1192 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1193 | Initiator Nonce | 1194 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1195 | Responder Nonce | 1196 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1197 | | 1198 + Options + 1199 | | 1200 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1202 Fields: 1204 Next Header: NO_NXT_HDR (59). 1206 Hdr Ext Len: At least 1, since the header is 16 octets when there 1207 are no options. 1209 Type: 2 1210 Reserved1: 7-bit field. Reserved for future use. Zero on 1211 transmit. MUST be ignored on receipt. 1213 Reserved2: 16-bit field. Reserved for future use. Zero on 1214 transmit. MUST be ignored on receipt. 1216 Initiator Nonce: 32-bit unsigned integer. Copied from the I1 1217 message. 1219 Responder Nonce: 32-bit unsigned integer. A number picked by the 1220 responder which the initiator will return in the I2 1221 message. 1223 The following options are defined for this message: 1225 Responder Validator: Variable length option. Typically a hash 1226 generated by the responder, which the responder uses 1227 together with the Responder Nonce value to verify that 1228 an I2 message is indeed sent in response to a R1 1229 message, and that the parameters in the I2 message are 1230 the same as those in the I1 message. 1232 Future protocol extensions might define additional options for this 1233 message. The C-bit in the option format defines how such a new 1234 option will be handled by an implementation. See Section 5.14. 1236 5.6. I2 Message Format 1238 The I2 message is the third message in the context establishment 1239 exchange. The initiator sends this in response to a R1 message, 1240 after checking the Initiator Nonce, etc. 1242 0 1 2 3 1243 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1244 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1245 | 59 | Hdr Ext Len |0| Type = 3 | Reserved1 |0| 1246 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1247 | Checksum |R| | 1248 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1249 | Initiator Context Tag | 1250 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1251 | Initiator Nonce | 1252 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1253 | Responder Nonce | 1254 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1255 | Reserved2 | 1256 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1257 | | 1258 + Options + 1259 | | 1260 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1262 Fields: 1264 Next Header: NO_NXT_HDR (59). 1266 Hdr Ext Len: At least 2, since the header is 24 octets when there 1267 are no options. 1269 Type: 3 1271 Reserved1: 7-bit field. Reserved for future use. Zero on 1272 transmit. MUST be ignored on receipt. 1274 R: 1-bit field. Reserved for future use. Zero on 1275 transmit. MUST be ignored on receipt. 1277 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1278 has allocated for the context. 1280 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1281 the initiator which the responder will return in the 1282 R2 message. 1284 Responder Nonce: 32-bit unsigned integer. Copied from the R1 1285 message. 1287 Reserved2: 32-bit field. Reserved for future use. Zero on 1288 transmit. MUST be ignored on receipt. (Needed to 1289 make the options start on a multiple of 8 octet 1290 boundary.) 1292 The following options are defined for this message: 1294 Responder Validator: Variable length option. Just a copy of the 1295 Responder Validator option in the R1 message. 1297 ULID pair: When the IPv6 source and destination addresses in the 1298 IPv6 header does not match the ULID pair, this option 1299 MUST be included. An example of this is when 1300 recovering from a lost context. 1302 Forked Instance Identifier: When another instance of an existent 1303 context with the same ULID pair is being created, a 1304 Forked Instance Identifier option is included to 1305 distinguish this new instance from the existent one. 1307 Locator list: Optionally sent when the initiator immediately wants 1308 to tell the responder its list of locators. When it 1309 is sent, the necessary HBA/CGA information for 1310 verifying the locator list MUST also be included. 1312 Locator Preferences: Optionally sent when the locators don't all have 1313 equal preference. 1315 CGA Parameter Data Structure: Included when the locator list is 1316 included so the receiver can verify the locator list. 1318 CGA Signature: Included when the some of the locators in the list use 1319 CGA (and not HBA) for verification. 1321 Future protocol extensions might define additional options for this 1322 message. The C-bit in the option format defines how such a new 1323 option will be handled by an implementation. See Section 5.14. 1325 5.7. R2 Message Format 1327 The R2 message is the fourth message in the context establishment 1328 exchange. The responder sends this in response to an I2 message. 1329 The R2 message is also used when both hosts send I1 messages at the 1330 same time and the I1 messages cross in flight. 1332 0 1 2 3 1333 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1334 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1335 | 59 | Hdr Ext Len |0| Type = 4 | Reserved1 |0| 1336 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1337 | Checksum |R| | 1338 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1339 | Responder Context Tag | 1340 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1341 | Initiator Nonce | 1342 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1343 | | 1344 + Options + 1345 | | 1346 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1348 Fields: 1350 Next Header: NO_NXT_HDR (59). 1352 Hdr Ext Len: At least 1, since the header is 16 octets when there 1353 are no options. 1355 Type: 4 1357 Reserved1: 7-bit field. Reserved for future use. Zero on 1358 transmit. MUST be ignored on receipt. 1360 R: 1-bit field. Reserved for future use. Zero on 1361 transmit. MUST be ignored on receipt. 1363 Responder Context Tag: 47-bit field. The Context Tag the responder 1364 has allocated for the context. 1366 Initiator Nonce: 32-bit unsigned integer. Copied from the I2 1367 message. 1369 The following options are defined for this message: 1371 Locator List: Optionally sent when the responder immediately wants 1372 to tell the initiator its list of locators. When it 1373 is sent, the necessary HBA/CGA information for 1374 verifying the locator list MUST also be included. 1376 Locator Preferences: Optionally sent when the locators don't all have 1377 equal preference. 1379 CGA Parameter Data Structure: Included when the locator list is 1380 included so the receiver can verify the locator list. 1382 CGA Signature: Included when the some of the locators in the list use 1383 CGA (and not HBA) for verification. 1385 Future protocol extensions might define additional options for this 1386 message. The C-bit in the option format defines how such a new 1387 option will be handled by an implementation. See Section 5.14. 1389 5.8. R1bis Message Format 1391 Should a host receive a packet with a shim Payload extension header 1392 or shim6 control message with type code 64-127 (such as an Update or 1393 Probe message), and the host does not have any context state for the 1394 received context tag, then it will generate a R1bis message. 1396 This message allows the sender of the packet referring to the non- 1397 existent context to re-establish the context with a reduced context 1398 establishment exchange. Upon the reception of the R1bis message, the 1399 receiver can proceed reestablishing the lost context by directly 1400 sending an I2bis message. 1402 0 1 2 3 1403 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1404 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1405 | 59 | Hdr Ext Len |0| Type = 5 | Reserved1 |0| 1406 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1407 | Checksum |R| | 1408 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1409 | Packet Context Tag | 1410 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1411 | Responder Nonce | 1412 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1413 | | 1414 + Options + 1415 | | 1416 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1418 Fields: 1420 Next Header: NO_NXT_HDR (59). 1422 Hdr Ext Len: At least 1, since the header is 16 octets when there 1423 are no options. 1425 Type: 5 1427 Reserved1: 7-bit field. Reserved for future use. Zero on 1428 transmit. MUST be ignored on receipt. 1430 R: 1-bit field. Reserved for future use. Zero on 1431 transmit. MUST be ignored on receipt. 1433 Packet Context Tag: 47-bit unsigned integer. The context tag 1434 contained in the received packet that triggered the 1435 generation of the R1bis message. 1437 Responder Nonce: 32-bit unsigned integer. A number picked by the 1438 responder which the initiator will return in the I2bis 1439 message. 1441 The following options are defined for this message: 1443 Responder Validator: Variable length option. Typically a hash 1444 generated by the responder, which the responder uses 1445 together with the Responder Nonce value to verify that 1446 an I2bis message is indeed sent in response to a R1bis 1447 message. 1449 Future protocol extensions might define additional options for this 1450 message. The C-bit in the option format defines how such a new 1451 option will be handled by an implementation. See Section 5.14. 1453 5.9. I2bis Message Format 1455 The I2bis message is the third message in the context recovery 1456 exchange. This is sent in response to a R1bis message, after 1457 checking that the R1bis message refers to an existing context, etc. 1459 0 1 2 3 1460 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1461 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1462 | 59 | Hdr Ext Len |0| Type = 6 | Reserved1 |0| 1463 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1464 | Checksum |R| | 1465 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1466 | Initiator Context Tag | 1467 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1468 | Initiator Nonce | 1469 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1470 | Responder Nonce | 1471 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1472 | Reserved2 | 1473 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1474 | | | 1475 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1476 | Packet Context Tag | 1477 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1478 | | 1479 + Options + 1480 | | 1481 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1483 Fields: 1485 Next Header: NO_NXT_HDR (59). 1487 Hdr Ext Len: At least 3, since the header is 32 octets when there 1488 are no options. 1490 Type: 6 1492 Reserved1: 7-bit field. Reserved for future use. Zero on 1493 transmit. MUST be ignored on receipt. 1495 R: 1-bit field. Reserved for future use. Zero on 1496 transmit. MUST be ignored on receipt. 1498 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1499 has allocated for the context. 1501 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1502 the initiator which the responder will return in the 1503 R2 message. 1505 Responder Nonce: 32-bit unsigned integer. Copied from the R1bis 1506 message. 1508 Reserved2: 49-bit field. Reserved for future use. Zero on 1509 transmit. MUST be ignored on receipt. (Note that 17 1510 bits are not sufficient since the options need start 1511 on a multiple of 8 octet boundary.) 1513 Packet Context Tag: 47-bit unsigned integer. Copied from the Packet 1514 Context Tag contained in the received R1bis. 1516 The following options are defined for this message: 1518 Responder Validator: Variable length option. Just a copy of the 1519 Responder Validator option in the R1bis message. 1521 ULID pair: When the IPv6 source and destination addresses in the 1522 IPv6 header does not match the ULID pair, this option 1523 MUST be included. 1525 Forked Instance Identifier: When another instance of an existent 1526 context with the same ULID pair is being created, a 1527 Forked Instance Identifier option is included to 1528 distinguish this new instance from the existent one. 1530 Locator list: Optionally sent when the initiator immediately wants 1531 to tell the responder its list of locators. When it 1532 is sent, the necessary HBA/CGA information for 1533 verifying the locator list MUST also be included. 1535 Locator Preferences: Optionally sent when the locators don't all have 1536 equal preference. 1538 CGA Parameter Data Structure: Included when the locator list is 1539 included so the receiver can verify the locator list. 1541 CGA Signature: Included when the some of the locators in the list use 1542 CGA (and not HBA) for verification. 1544 Future protocol extensions might define additional options for this 1545 message. The C-bit in the option format defines how such a new 1546 option will be handled by an implementation. See Section 5.14. 1548 5.10. Update Request Message Format 1550 The Update Request Message is used to update either the list of 1551 locators, the locator preferences, and both. When the list of 1552 locators is updated, the message also contains the option(s) 1553 necessary for HBA/CGA to secure this. The basic sanity check that 1554 prevents off-path attackers from generating bogus updates is the 1555 context tag in the message. 1557 The update message contains options (the Locator List and the Locator 1558 Preferences) that, when included, completely replace the previous 1559 locator list and locator preferences, respectively. Thus there is no 1560 mechanism to just send deltas to the locator list. 1562 0 1 2 3 1563 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1564 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1565 | 59 | Hdr Ext Len |0| Type = 64 | Reserved1 |0| 1566 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1567 | Checksum |R| | 1568 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1569 | Receiver Context Tag | 1570 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1571 | Request Nonce | 1572 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1573 | | 1574 + Options + 1575 | | 1576 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1578 Fields: 1580 Next Header: NO_NXT_HDR (59). 1582 Hdr Ext Len: At least 1, since the header is 16 octets when there 1583 are no options. 1585 Type: 64 1587 Reserved1: 7-bit field. Reserved for future use. Zero on 1588 transmit. MUST be ignored on receipt. 1590 R: 1-bit field. Reserved for future use. Zero on 1591 transmit. MUST be ignored on receipt. 1593 Receiver Context Tag: 47-bit field. The Context Tag the receiver has 1594 allocated for the context. 1596 Request Nonce: 32-bit unsigned integer. A random number picked by 1597 the initiator which the peer will return in the 1598 acknowledgement message. 1600 The following options are defined for this message: 1602 Locator List: The list of the sender's (new) locators. The locators 1603 might be unchanged and only the preferences have 1604 changed. 1606 Locator Preferences: Optionally sent when the locators don't all have 1607 equal preference. 1609 CGA Parameter Data Structure (PDS): Included when the locator list is 1610 included and the PDS was not included in the 1611 I2/I2bis/R2 messages, so the receiver can verify the 1612 locator list. 1614 CGA Signature: Included when the some of the locators in the list use 1615 CGA (and not HBA) for verification. 1617 Future protocol extensions might define additional options for this 1618 message. The C-bit in the option format defines how such a new 1619 option will be handled by an implementation. See Section 5.14. 1621 5.11. Update Acknowledgement Message Format 1623 This message is sent in response to a Update Request message. It 1624 implies that the Update Request has been received, and that any new 1625 locators in the Update Request can now be used as the source locators 1626 of packets. But it does not imply that the (new) locators have been 1627 verified to be used as a destination, since the host might defer the 1628 verification of a locator until it sees a need to use a locator as 1629 the destination. 1631 0 1 2 3 1632 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1633 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1634 | 59 | Hdr Ext Len |0| Type = 65 | Reserved1 |0| 1635 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1636 | Checksum |R| | 1637 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1638 | Receiver Context Tag | 1639 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1640 | Request Nonce | 1641 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1642 | | 1643 + Options + 1644 | | 1645 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1647 Fields: 1649 Next Header: NO_NXT_HDR (59). 1651 Hdr Ext Len: At least 1, since the header is 16 octets when there 1652 are no options. 1654 Type: 65 1656 Reserved1: 7-bit field. Reserved for future use. Zero on 1657 transmit. MUST be ignored on receipt. 1659 R: 1-bit field. Reserved for future use. Zero on 1660 transmit. MUST be ignored on receipt. 1662 Receiver Context Tag: 47-bit field. The Context Tag the receiver has 1663 allocated for the context. 1665 Request Nonce: 32-bit unsigned integer. Copied from the Update 1666 Request message. 1668 No options are currently defined for this message. 1670 Future protocol extensions might define additional options for this 1671 message. The C-bit in the option format defines how such a new 1672 option will be handled by an implementation. See Section 5.14. 1674 5.12. Keepalive Message Format 1676 This message format is defined in [8]. 1678 The message is used to ensure that when a peer is sending ULP packets 1679 on a context, it always receives some packets in the reverse 1680 direction. When the ULP is sending bidirectional traffic, no extra 1681 packets need to be inserted. But for a unidirectional ULP traffic 1682 pattern, the shim will send back some Keepalive messages when it is 1683 receiving ULP packets. 1685 5.13. Probe Message Format 1687 This message and its semantics are defined in [8]. 1689 The idea behind that mechanism is to be able to handle the case when 1690 one locator pair works in from A to B, and another locator pair works 1691 from B to A, but there is no locator pair which works in both 1692 directions. The protocol mechanism is that as A is sending probe 1693 messages to B, B will observe which locator pairs it has received 1694 from and report that back in probe messages it is sending to A. 1696 5.14. Option Formats 1698 The format of the options is a snapshot of the current HIP option 1699 format [25]. However, there is no intention to track any changes to 1700 the HIP option format, nor is there an intent to use the same name 1701 space for the option type values. But using the same format will 1702 hopefully make it easier to import HIP capabilities into shim6 as 1703 extensions to shim6, should this turn out to be useful. 1705 All of the TLV parameters have a length (including Type and Length 1706 fields) which is a multiple of 8 bytes. When needed, padding MUST be 1707 added to the end of the parameter so that the total length becomes a 1708 multiple of 8 bytes. This rule ensures proper alignment of data. If 1709 padding is added, the Length field MUST NOT include the padding. Any 1710 added padding bytes MUST be zeroed by the sender, and their values 1711 SHOULD NOT be checked by the receiver. 1713 Consequently, the Length field indicates the length of the Contents 1714 field (in bytes). The total length of the TLV parameter (including 1715 Type, Length, Contents, and Padding) is related to the Length field 1716 according to the following formula: 1718 Total Length = 11 + Length - (Length + 3) % 8; 1720 0 1 2 3 1721 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1722 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1723 | Type |C| Length | 1724 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1725 ~ ~ 1726 ~ Contents ~ 1727 ~ +-+-+-+-+-+-+-+-+ 1728 ~ | Padding | 1729 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1731 Fields: 1733 Type: 15-bit identifier of the type of option. The options 1734 defined in this document are below. 1736 C: Critical. One if this parameter is critical, and MUST 1737 be recognized by the recipient, zero otherwise. An 1738 implementation might view the C bit as part of the 1739 Type field, by multiplying the type values in this 1740 specification by two. 1742 Length: Length of the Contents, in bytes. 1744 Contents: Parameter specific, defined by Type. 1746 Padding: Padding, 0-7 bytes, added if needed. 1748 +------+---------------------------------+ 1749 | Type | Option Name | 1750 +------+---------------------------------+ 1751 | 1 | Responder Validator | 1752 | | | 1753 | 2 | Locator List | 1754 | | | 1755 | 3 | Locator Preferences | 1756 | | | 1757 | 4 | CGA Parameter Data Structure | 1758 | | | 1759 | 5 | CGA Signature | 1760 | | | 1761 | 6 | ULID Pair | 1762 | | | 1763 | 7 | Forked Instance Identifier | 1764 | | | 1765 | 10 | Probe Option | 1766 | | | 1767 | 11 | Reachability Option | 1768 | | | 1769 | 12 | Payload Reception Report Option | 1770 +------+---------------------------------+ 1772 Table 2 1774 Future protocol extensions might define additional options for the 1775 SHIM6 messages. The C-bit in the option format defines how such a 1776 new option will be handled by an implementation. 1778 If a host receives an option that it does not understand (an option 1779 that was defined in some future extension to this protocol) or is not 1780 listed as a valid option for the different message types above, then 1781 the Critical bit in the option determines the outcome. 1783 o If C=0 then the option is silently ignored, and the rest of the 1784 message is processed. 1786 o If C=1 then the host SHOULD send back an ICMP parameter problem 1787 (type 4, code 1), with the Pointer referencing the first octet in 1788 the option Type field. When C=1 the message MUST NOT be 1789 processed. 1791 5.14.1. Responder Validator Option Format 1793 The responder can choose exactly what input is used to compute the 1794 validator, and what one-way function (MD5, SHA1) it uses, as long as 1795 the responder can check that the validator it receives back in the I2 1796 or I2bis message is indeed one that: 1798 1)- it computed, 1800 2)- it computed for the particular context, and 1802 3)- that it isn't a replayed I2/I2bis message. 1804 Some suggestions on how to generate the validators are captured in 1805 Section 7.10.1 and Section 7.17.1. 1807 0 1 2 3 1808 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1809 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1810 | Type = 1 |0| Length | 1811 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1812 ~ Validator ~ 1813 ~ +-+-+-+-+-+-+-+-+ 1814 ~ | Padding | 1815 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1817 Fields: 1819 Validator: Variable length content whose interpretation is local 1820 to the responder. 1822 Padding: Padding, 0-7 bytes, added if needed. See 1823 Section 5.14. 1825 5.14.2. Locator List Option Format 1827 The Locator List Option is used to carry all the locators of the 1828 sender. Note that the order of the locators is important, since the 1829 Locator Preferences refers to the locators by using the index in the 1830 list. 1832 Note that we carry all the locators in this option even though some 1833 of them can be created automatically from the CGA Parameter Data 1834 Structure. 1836 0 1 2 3 1837 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1838 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1839 | Type = 2 |0| Length | 1840 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1841 | Locator List Generation | 1842 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1843 | Num Locators | N Octets of Verification Method | 1844 +-+-+-+-+-+-+-+-+ | 1845 ~ ~ 1846 ~ +-+-+-+-+-+-+-+-+ 1847 ~ | Padding | 1848 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1849 ~ Locators 1 through N ~ 1850 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1852 Fields: 1854 Locator List Generation: 32-bit unsigned integer. Indicates a 1855 generation number which is increased by one for each 1856 new locator list. This is used to ensure that the 1857 index in the Locator Preferences refer to the right 1858 version of the locator list. 1860 Num Locators: 8-bit unsigned integer. The number of locators that 1861 are included in the option. We call this number "N" 1862 below. 1864 Verification Method: N octets. The i'th octet specifies the 1865 verification method for the i'th locator. 1867 Padding: Padding, 0-7 bytes, added if needed so that the 1868 Locators start on a multiple of 8 octet boundary. 1869 NOTE that for this option there is never a need to pad 1870 at the end, since the locators are a multiple of 8 1871 octets in length. This internal padding is included 1872 in the length field. 1874 Locators: N 128-bit locators. 1876 The defined verification methods are: 1878 +-------+----------+ 1879 | Value | Method | 1880 +-------+----------+ 1881 | 0 | Reserved | 1882 | | | 1883 | 1 | HBA | 1884 | | | 1885 | 2 | CGA | 1886 | | | 1887 | 3-255 | Reserved | 1888 +-------+----------+ 1890 Table 3 1892 5.14.3. Locator Preferences Option Format 1894 The Locator Preferences option can have some flags to indicate 1895 whether or not a locator is known to work. In addition, the sender 1896 can include a notion of preferences. It might make sense to define 1897 "preferences" as a combination of priority and weight the same way 1898 that DNS SRV records has such information. The priority would 1899 provide a way to rank the locators, and within a given priority, the 1900 weight would provide a way to do some load sharing. See [9] for how 1901 SRV defines the interaction of priority and weight. 1903 The minimum notion of preferences we need is to be able to indicate 1904 that a locator is "dead". We can handle this using a single octet 1905 flag for each locator. 1907 We can extend that by carrying a larger "element" for each locator. 1908 This document presently also defines 2-octet and 3-octet elements, 1909 and we can add more information by having even larger elements if 1910 need be. 1912 The locators are not included in the preference list. Instead, the 1913 first element refers to locator that was in the first element in the 1914 Locator List option. The generation number carried in this option 1915 and the Locator List option is used to verify that they refer to the 1916 same version of the locator list. 1918 0 1 2 3 1919 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1920 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1921 | Type = 3 |0| Length | 1922 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1923 | Locator List Generation | 1924 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1925 | Element Len | Element[1] | Element[2] | Element[3] | 1926 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1927 ~ ... ~ 1928 ~ +-+-+-+-+-+-+-+-+ 1929 ~ | Padding | 1930 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1932 Case of Element Len = 1 is depicted. 1934 Fields: 1936 Locator List Generation: 32-bit unsigned integer. Indicates a 1937 generation number for the locator list to which the 1938 elements should apply. 1940 Element Len: 8-bit unsigned integer. The length in octets of each 1941 element. This specification defines the cases when 1942 the length is 1, 2, or 3. 1944 Element[i]: A field with a number of octets defined by the Element 1945 Len field. Provides preferences for the i'th locator 1946 in the Locator List option that is in use. 1948 Padding: Padding, 0-7 bytes, added if needed. See 1949 Section 5.14. 1951 When the Element length equals one, then the element consists of only 1952 a one octet flags field. The currently defined set of flags are: 1954 BROKEN: 0x01 1956 TEMPORARY: 0x02 1958 The intent of the BROKEN flag is to inform the peer that a given 1959 locator is known to be not working. The intent of TEMPORARY is to 1960 allow the distinction between more stable addresses and less stable 1961 addresses when shim6 is combined with IP mobility, when we might have 1962 more stable home locators, and less stable care-of-locators. 1964 When the Element length equals two, then the element consists of a 1 1965 octet flags field followed by a 1 octet priority field. The priority 1966 has the same semantics as the priority in DNS SRV records. 1968 When the Element length equals three, then the element consists of a 1969 1 octet flags field followed by a 1 octet priority field, and a 1 1970 octet weight field. The weight has the same semantics as the weight 1971 in DNS SRV records. 1973 This document doesn't specify the format when the Element length is 1974 more than three, except that any such formats MUST be defined so that 1975 the first three octets are the same as in the above case, that is, a 1976 of a 1 octet flags field followed by a 1 octet priority field, and a 1977 1 octet weight field. 1979 5.14.4. CGA Parameter Data Structure Option Format 1981 This option contains the CGA Parameter Data Structure (PDS). When 1982 HBA is used to verify the locators, the PDS contains the HBA 1983 multiprefix extension. When CGA is used to verify the locators, in 1984 addition to the PDS option, the host also needs to include the 1985 signature in the form of a CGA Signature option. 1987 0 1 2 3 1988 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1989 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1990 | Type = 4 |0| Length | 1991 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1992 ~ CGA Parameter Data Structure ~ 1993 ~ +-+-+-+-+-+-+-+-+ 1994 ~ | Padding | 1995 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1997 Fields: 1999 CGA Parameter Data Structure: Variable length content. Content 2000 defined in [6] and [7]. 2002 Padding: Padding, 0-7 bytes, added if needed. See 2003 Section 5.14. 2005 5.14.5. CGA Signature Option Format 2007 When CGA is used for verification of one or more of the locators in 2008 the Locator List option, then the message in question will need to 2009 contain this option. 2011 0 1 2 3 2012 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2013 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2014 | Type = 5 |0| Length | 2015 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2016 ~ CGA Signature ~ 2017 ~ +-+-+-+-+-+-+-+-+ 2018 ~ | Padding | 2019 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2021 Fields: 2023 CGA Signature: A variable-length field containing a PKCS#1 v1.5 2024 signature, constructed by using the sender's private 2025 key over the following sequence of octets: 2027 1. The 128-bit CGA Message Type tag [CGA] value for 2028 SHIM6, 0x4A 30 5662 4858 574B 3655 416F 506A 6D48. 2029 (The tag value has been generated randomly by the 2030 editor of this specification.). 2032 2. The Locator List Generation value of the 2033 correspondent Locator List Option. 2035 3. The subset of locators included in the 2036 correspondent Locator List Option which 2037 verification method is set to CGA. The locators 2038 MUST be included in the order they are listed in 2039 the Locator List Option. 2041 Padding: Padding, 0-7 bytes, added if needed. See 2042 Section 5.14. 2044 5.14.6. ULID Pair Option Format 2046 I1, I2, and I2bis messages MUST contain the ULID pair; normally this 2047 is in the IPv6 source and destination fields. In case that the ULID 2048 for the context differ from the address pair included in the source 2049 and destination address fields of the IPv6 packet used to carry the 2050 I1/I2/I2bis message, the ULID pair option MUST be included in the I1/ 2051 I2/I2bis message. 2053 0 1 2 3 2054 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2055 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2056 | Type = 6 |0| Length = 36 | 2057 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2058 | Reserved2 | 2059 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2060 | | 2061 + Sender ULID + 2062 | | 2063 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2064 | | 2065 + Receiver ULID + 2066 | | 2067 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2069 Fields: 2071 Reserved2: 32-bit field. Reserved for future use. Zero on 2072 transmit. MUST be ignored on receipt. (Needed to 2073 make the ULIDs start on a multiple of 8 octet 2074 boundary.) 2076 Sender ULID: A 128-bit IPv6 address. 2078 Receiver ULID: A 128-bit IPv6 address. 2080 5.14.7. Forked Instance Identifier Option Format 2082 0 1 2 3 2083 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2084 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2085 | Type = 7 |0| Length = 4 | 2086 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2087 | Forked Instance Identifier | 2088 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2090 Fields: 2092 Forked Instance Identifier: 32-bit field containing the identifier of 2093 the particular forked instance. 2095 5.14.8. Probe Option Format 2097 This option is defined in [8]. 2099 5.14.9. Reachability Option Format 2101 This option is defined in [8]. 2103 5.14.10. Payload Reception Report Option Format 2105 This option is defined in [8]. 2107 6. Conceptual Model of a Host 2109 This section describes a conceptual model of one possible data 2110 structure organization that hosts will maintain for the purposes of 2111 shim6. The described organization is provided to facilitate the 2112 explanation of how the shim6 protocol should behave. This document 2113 does not mandate that implementations adhere to this model as long as 2114 their external behavior is consistent with that described in this 2115 document. 2117 6.1. Conceptual Data Structures 2119 The key conceptual data structure for the shim6 protocol is the ULID 2120 pair context. This is a data structure which contains the following 2121 information: 2123 o The state of the context. See Section 6.2. 2125 o The peer ULID; ULID(peer) 2127 o The local ULID; ULID(local) 2129 o The Forked Instance Identifier; FII. This is zero for the default 2130 context i.e., when there is no forking. 2132 o The list of peer locators, with their preferences; Ls(peer) 2134 o The generation number for the most recently received, verified 2135 peer locator list. 2137 o For each peer locator, the verification method to use (from the 2138 Locator List option). 2140 o For each peer locator, a bit whether it has been verified using 2141 HBA or CGA, and a bit whether the locator has been probed to 2142 verify that the ULID is present at that location. 2144 o The preferred peer locator - used as destination; Lp(peer) 2146 o The set of local locators and the preferences; Ls(local) 2148 o The generation number for the most recently sent Locator List 2149 option. 2151 o The preferred local locator - used as source; Lp(local) 2153 o The context tag used to transmit control messages and payload 2154 extension headers - allocated by the peer; CT(peer) 2156 o The context to expect in received control messages and payload 2157 extension headers - allocated by the local host; CT(local) 2159 o Timers for retransmission of the messages during context 2160 establishment and update messages. 2162 o Depending how an implementation determines whether a context is 2163 still in use, there might be a need to track the last time a 2164 packet was sent/received using the context. 2166 o Reachability state for the locator pairs as specified in [8]. 2168 o During pair exploration, information about the probe messages that 2169 have been sent and received as specified in [8]. 2171 6.2. Context States 2173 The states that are used to describe the shim6 protocol are as 2174 follows: 2176 +---------------------+---------------------------------------------+ 2177 | State | Explanation | 2178 +---------------------+---------------------------------------------+ 2179 | IDLE | State machine start | 2180 | | | 2181 | I1-SENT | Initiating context establishment exchange | 2182 | | | 2183 | I2-SENT | Waiting to complete context establishment | 2184 | | exchange | 2185 | | | 2186 | I2BIS-SENT | Potential context loss detected | 2187 | | | 2188 | | | 2189 | ESTABLISHED | SHIM context established | 2190 | | | 2191 | E-FAILED | Context establishment exchange failed | 2192 | | | 2193 | NO-SUPPORT | ICMP Unrecognized Next Header type | 2194 | | (type 4, code 1) received indicating | 2195 | | that shim6 is not supported | 2196 +---------------------+---------------------------------------------+ 2197 In addition, in each of the aforementioned states, the following 2198 state information is stored: 2200 +---------------------+---------------------------------------------+ 2201 | State | Information | 2202 +---------------------+---------------------------------------------+ 2203 | IDLE | None | 2204 | | | 2205 | I1-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2206 | | INIT nonce, Lp(local), Lp(peer), Ls(local) | 2207 | | | 2208 | I2-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2209 | | INIT nonce, RESP nonce, Lp(local), Lp(peer),| 2210 | | Ls(local) | 2211 | | | 2212 | ESTABLISHED | ULID(peer), ULID(local), [FII], CT(local), | 2213 | | CT(peer), Lp(local), Lp(peer), Ls(local) | 2214 | | Ls(peer), INIT nonce?(to receive late R2) | 2215 | | | 2216 | I2BIS-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2217 | | CT(peer), Lp(local), Lp(peer), Ls(local) | 2218 | | Ls(peer), CT(R1bis) | 2219 | | | 2220 | E-FAILED | ULID(peer), ULID(local) | 2221 | | | 2222 | NO-SUPPORT | ULID(peer), ULID(local) | 2223 +---------------------+---------------------------------------------+ 2225 7. Establishing ULID-Pair Contexts 2227 ULID-pair contexts are established using a 4-way exchange, which 2228 allows the responder to avoid creating state on the first packet. As 2229 part of this exchange each end allocates a context tag, and it shares 2230 this context tag and its set of locators with the peer. 2232 In some cases the 4-way exchange is not necessary, for instance when 2233 both ends try to setup the context at the same time, or when 2234 recovering from a context that has been garbage collected or lost at 2235 one of the hosts. 2237 7.1. Uniqueness of Context Tags 2239 As part of establishing a new context, each host has to assign a 2240 unique context tag. Since the Payload Extension headers are 2241 demultiplexed based solely on the context tag value (without using 2242 the locators), the context tag MUST be unique for each context. 2244 In addition, in order to minimize the reuse of context tags, the host 2245 SHOULD randomly cycle through the 2^47 context tag values,(e.g. 2246 following the guidelines described in [17]). 2248 7.2. Locator Verification 2250 The peer's locators might need to be verified during context 2251 establishment as well as when handling locator updates in Section 10. 2253 There are two separate aspects of locator verification. One is to 2254 verify that the locator is tied to the ULID, i.e., that the host 2255 which "owns" the ULID is also the one that is claiming the locator 2256 "ownership". The shim6 protocol uses the HBA or CGA techniques for 2257 doing this verification. The other is to verify that the host is 2258 indeed reachable at the claimed locator. Such verification is needed 2259 both to make sure communication can proceed, but also to prevent 3rd 2260 party flooding attacks [19]. These different verifications happen at 2261 different times, since the first might need to be performed before 2262 packets can be received by the peer with the source locator in 2263 question, but the latter verification is only needed before packets 2264 are sent to the locator. 2266 Before a host can use a locator (different than the ULID) as the 2267 source locator, it must know that the peer will accept packets with 2268 that source locator as being part of this context. Thus the HBA/CGA 2269 verification SHOULD be performed by the host before the host 2270 acknowledges the new locator, by sending an Update Acknowledgement 2271 message, or an R2 message. 2273 Before a host can use a locator (different than the ULID) as the 2274 destination locator it MUST perform the HBA/CGA verification if this 2275 was not performed before upon the reception of the locator set. In 2276 addition, it MUST verify that the ULID is indeed present at that 2277 locator. This verification is performed by doing a return- 2278 routability test as part of the Probe sub-protocol [8]. 2280 If the verification method in the Locator List option is not 2281 supported by the host, or if the verification method is not 2282 consistent with the CGA Parameter Data Structure (e.g., the Parameter 2283 Data Structure doesn't contain the multiprefix extension, and the 2284 verification method says to use HBA), then the host MUST ignore the 2285 Locator List and the message in which it is contained, and the host 2286 SHOULD generates an ICMP parameter problem (type 4, code 0), with the 2287 Pointer referencing the octet in the Verification method that was 2288 found inconsistent. 2290 7.3. Normal context establishment 2292 The normal context establishment consists of a 4 message exchange in 2293 the order of I1, R1, I2, R2 as can be seen in Figure 24. 2295 Initiator Responder 2297 IDLE IDLE 2298 ------------- I1 --------------> 2299 I1-SENT 2300 <------------ R1 --------------- 2301 IDLE 2302 ------------- I2 --------------> 2303 I2-SENT 2304 <------------ R2 --------------- 2305 ESTABLISHED ESTABLISHED 2307 Figure 24: Normal context establishment 2309 7.4. Concurrent context establishment 2311 When both ends try to initiate a context for the same ULID pair, then 2312 we might end up with crossing I1 messages. Alternatively, since no 2313 state is created when receiving the I1, a host might send a I1 after 2314 having sent a R1 message. 2316 Since a host remembers that it has sent an I1, it can respond to an 2317 I1 from the peer (for the same ULID-pair), with a R2, resulting in 2318 the message exchange shown in Figure 25. Such behavior is needed for 2319 other reasons such as to correctly respond to retransmitted I1 2320 messages, which occur when the R2 message has been lost. 2322 Host A Host B 2324 IDLE IDLE 2325 -\ 2326 I1-SENT---\ 2327 ---\ /--- 2328 --- I1 ---\ /--- I1-SENT 2329 ---\ 2330 /--- I1 ---/ ---\ 2331 /--- --> 2332 <--- 2334 -\ 2335 I1-SENT---\ 2336 ---\ /--- 2337 --- R2 ---\ /--- I1-SENT 2338 ---\ 2339 /--- R2 ---/ ---\ 2340 /--- --> 2341 <--- ESTABLISHED 2342 ESTABLISHED 2344 Figure 25: Crossing I1 messages 2346 If a host has received an I1 and sent an R1, it has no state to 2347 remember this. Thus if the ULP on the host sends down packets, this 2348 might trigger the host to send an I1 message itself. Thus while one 2349 end is sending an I1 the other is sending an I2 as can be seen in 2350 Figure 26. 2352 Host A Host B 2354 IDLE IDLE 2355 -\ 2356 ---\ 2357 I1-SENT ---\ 2358 --- I1 ---\ 2359 ---\ 2360 ---\ 2361 --> 2363 /--- 2364 /--- IDLE 2365 --- 2366 /--- R1--/ 2367 /--- 2368 <--- 2370 -\ 2371 I2-SENT---\ 2372 ---\ /--- 2373 --- I2---\ /--- I1-SENT 2374 ---\ 2375 /--- I1 ---/ ---\ 2376 /--- --> 2377 <--- ESTABLISHED 2379 -\ 2380 I2-SENT---\ 2381 ---\ /--- 2382 --- R2 ---\ /--- 2383 ---\ 2384 /--- R2 ---/ ---\ 2385 /--- --> 2386 <--- ESTABLISHED 2387 ESTABLISHED 2389 Figure 26: Crossing I2 and I1 2391 7.5. Context recovery 2393 Due to garbage collection, we can end up with one end having and 2394 using the context state, and the other end not having any state. We 2395 need to be able to recover this state at the end that has lost it, 2396 before we can use it. 2398 This need can arise in the following cases: 2400 o The communication is working using the ULID pair as the locator 2401 pair, but a problem arises, and the end that has retained the 2402 context state decides to probe alternate locator pairs. 2404 o The communication is working using a locator pair that is not the 2405 ULID pair, hence the ULP packets sent from a peer that has 2406 retained the context state use the shim6 Payload extension header. 2408 o The host that retained the state sends a control message (e.g. an 2409 Update Request message). 2411 In all the cases the result is that the peer without state receives a 2412 shim message for which it has to context for the context tag. 2414 In all of those cases we can recover the context by having the node 2415 which doesn't have a context state, send back an R1bis message, and 2416 have then complete the recovery with a I2bis and R2 message as can be 2417 seen in Figure 27. 2419 Host A Host B 2421 Context for 2422 CT(peer)=X Discards context for 2423 CT(local)=X 2425 ESTABLISHED IDLE 2427 ---- payload, probe, etc. -----> No context state 2428 for CT(local)=X 2430 <------------ R1bis ------------ 2431 IDLE 2433 ------------- I2bis -----------> 2434 I2BIS_SENT 2435 <------------ R2 --------------- 2436 ESTABLISHED ESTABLISHED 2438 Figure 27: Context loss at receiver 2440 If one end has garbage collected or lost the context state, it might 2441 try to create a new context state (for the same ULID pair), by 2442 sending an I1 message. The peer (that still has the context state) 2443 will reply with an R1 message and the full 4-way exchange will be 2444 performed again in this case as can be seen in Figure 28. 2446 Host A Host B 2448 Context for 2449 CT(peer)=X Discards context for 2450 ULIDs A1, B1 CT(local)=X 2452 ESTABLISHED IDLE 2454 Finds <------------ I1 --------------- Tries to setup 2455 existing for ULIDs A1, B1 2456 context, 2457 but CT(peer) I1-SENT 2458 doesn't match 2459 ------------- R1 ---------------> 2460 Left old context 2461 in ESTABLISHED 2463 <------------ I2 --------------- 2464 Recreate context 2466 with new CT(peer) I2-SENT 2467 and Ls(peer). 2469 ESTABLISHED 2470 ------------- R2 --------------> 2471 ESTABLISHED ESTABLISHED 2473 Figure 28: Context loss at sender 2475 7.6. Context confusion 2477 Since each end might garbage collect the context state we can have 2478 the case when one end has retained the context state and tries to use 2479 it, while the other end has lost the state. We discussed this in the 2480 previous section on recovery. But for the same reasons, when one 2481 host retains context tag X as CT(peer) for ULID pair , the 2482 other end might end up allocating that context tag as CT(local) for 2483 another ULID pair, e.g., between the same hosts. In this 2484 case we can not use the recovery mechanisms since there needs to be 2485 separate context tags for the two ULID pairs. 2487 This type of "confusion" can be observed in two cases (assuming it is 2488 A that has retained the state and B has dropped it): 2490 o B decides to create a context for ULID pair , and 2491 allocates X as its context tag for this, and sends an I1 to A. 2493 o A decides to create a context for ULID pair , and starts 2494 the exchange by sending I1 to B. When B receives the I2 message, 2495 it allocates X as the context tag for this context. 2497 In both cases, A can detect that B has allocated X for ULID pair even though that A still X as CT(peer) for ULID pair . 2499 Thus A can detect that B must have lost the context for . 2501 The confusion can be detected when I2/I2bis/R2 is received since we 2502 require that those messages MUST include a sufficiently large set of 2503 locators in a Locator List option that the peer can determine whether 2504 or not two contexts have the same host as the peer by comparing if 2505 there is any common locators in Ls(peer). 2507 The requirement is that the old context which used the context tag 2508 MUST be removed; it can no longer be used to send packets. Thus A 2509 would forcibly remove the context state for , so that it 2510 can accept the new context for . An implementation MAY 2511 re-create a context to replace the one that was removed; in this case 2512 for . The normal I1, R1, I2, R2 establishment exchange would 2513 then pick unique context tags for that replacement context. This re- 2514 creation is OPTIONAL, but might be useful when there is ULP 2515 communication which is using the ULID pair whose context was removed. 2517 Note that an I1 message with a duplicate context tag should not cause 2518 the removal of the old context state; this operation needs to be 2519 deferred until the reception of the I2 message. 2521 7.7. Sending I1 messages 2523 When the shim layer decides to setup a context for a ULID pair, it 2524 starts by allocating and initializing the context state for its end. 2525 As part of this it assigns a random context tag to the context that 2526 is not being used as CT(local) by any other context . In the case 2527 that a new API is used and the ULP requests a forked context, the 2528 Forked Instance Identifier value will be set to a non-zero value. 2529 Otherwise, the FII value is zero. Then the initiator can send an I1 2530 message and set the context state to I1-SENT. The I1 message MUST 2531 include the ULID pair; normally in the IPv6 source and destination 2532 fields. But if the ULID pair for the context is not used as locator 2533 pair for the I1 message, then a ULID option MUST be included in the 2534 I1 message. In addition, if a Forked Instance Identifier value is 2535 non-zero, the I1 message MUST include a Context Instance Identifier 2536 option containing the correspondent value. 2538 7.8. Retransmitting I1 messages 2540 If the host does not receive an I2 or R2 message in response to the 2541 I1 message after I1_TIMEOUT time, then it needs to retransmit the I1 2542 message. The retransmissions should use a retransmission timer with 2543 binary exponential backoff to avoid creating congestion issues for 2544 the network when lots of hosts perform I1 retransmissions. Also, the 2545 actual timeout value should be randomized between 0.5 and 1.5 of the 2546 nominal value to avoid self-synchronization. 2548 If, after I1_RETRIES_MAX retransmissions, there is no response, then 2549 most likely the peer does not implement the shim6 protocol, or there 2550 could be a firewall that blocks the protocol. In this case it makes 2551 sense for the host to remember to not try again to establish a 2552 context with that ULID. However, any such negative caching should 2553 retained for at most NO_R1_HOLDDOWN_TIME, to be able to later setup a 2554 context should the problem have been that the host was not reachable 2555 at all when the shim tried to establish the context. 2557 If the host receives an ICMP error with "Unrecognized Next Header" 2558 type (type 4, code 1) and the included packet is the I1 message it 2559 just sent, then this is a more reliable indication that the peer ULID 2560 does not implement shim6. Again, in this case, the host should 2561 remember to not try again to establish a context with that ULID. 2562 Such negative caching should retained for at most ICMP_HOLDDOWN_TIME, 2563 which should be significantly longer than the previous case. 2565 7.9. Receiving I1 messages 2567 A host MUST silently discard any received I1 messages that do not 2568 satisfy all of the following validity checks in addition to those 2569 specified in Section 12.2: 2571 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2572 16 octets. 2574 Upon the reception of an I1 message, the host extracts the ULID pair 2575 and the Forked Instance Identifier from the message. If there is no 2576 ULID-pair option, then the ULID pair is taken from the source and 2577 destination fields in the IPv6 header. If there is no FII option in 2578 the message, then the FII value is taken to be zero. 2580 Next the host looks for an existing context which matches the ULID 2581 pair and the FII. 2583 If no state is found (i.e., the state is IDLE), then the host replies 2584 with a R1 message as specified below. 2586 If such a context exists in ESTABLISHED state, the host verifies that 2587 the locator of the Initiator is included in Ls(peer) (This check is 2588 unnecessary if there is no ULID-pair option in the I1 message). 2590 If the state exists in ESTABLISHED state and the locators do not fall 2591 in the locator sets, then the host replies with a R1 message as 2592 specified below. This completes the I1 processing, with the context 2593 state being unchanged. 2595 If the state exists in ESTABLISHED state and the locators do fall in 2596 the sets, then the host compares CT(peer) for the context with the CT 2597 contained in the I1 message. 2599 o If the context tags match, then this probably means that the R2 2600 message was lost and this I1 is a retransmission. In this case, 2601 the host replies with a R2 message containing the information 2602 available for the existent context. 2604 o If the context tags do not match, then it probably means that the 2605 Initiator has lost the context information for this context and it 2606 is trying to establish a new one for the same ULID-pair. In this 2607 case, the host replies with a R1 message as specified below. This 2608 completes the I1 processing, with the context state being 2609 unchanged. 2611 If the state exists in other state (I1-SENT, I2-SENT, I2BIS-SENT), we 2612 are in the situation of Concurrent context establishment described in 2613 Section 7.4. In this case, the host leaves CT(peer) unchanged, and 2614 replies with a R2 message. This completes the I1 processing, with 2615 the context state being unchanged. 2617 7.10. Sending R1 messages 2619 When the host needs to send a R1 message in response to the I1 2620 message, it copies the Initiator Nonce from the I1 message to the R1 2621 message, generates a Responder Nonce and calculates a Responder 2622 Validator option as suggested in the following section. No state is 2623 created on the host in this case.(Note that the information used to 2624 generate the R1 reply message is either contained in the received I1 2625 message or it is global information that is not associated with the 2626 particular requested context (the S and the Responder nonce values)). 2628 When the host needs to send a R2 message in response to the I1 2629 message, it copies the Initiator Nonce from the I1 message to the R2 2630 message, and otherwise follows the normal rules for forming an R2 2631 message (see Section 7.14). 2633 7.10.1. Generating the R1 Validator 2635 One way for the responder to properly generate validators is to 2636 maintain a single secret (S) and a running counter for the Responder 2637 Nonce. 2639 In the case the validator is generated to be included in a R1 2640 message, for each I1 message. The responder can increase the 2641 counter, use the counter value as the responder nonce, and use the 2642 following information concatenated as input to the one-way function: 2644 o The the secret S 2646 o That Responder Nonce 2648 o The Initiator Context Tag from the I1 message 2650 o The ULIDs from the I1 message 2652 o The locators from the I1 message (strictly only needed if they are 2653 different from the ULIDs) 2655 o The forked instance identifier if such option was included in the 2656 I1 message 2658 and then the output of the hash function is used as the validator 2659 octet string. 2661 7.11. Receiving R1 messages and sending I2 messages 2663 A host MUST silently discard any received R1 messages that do not 2664 satisfy all of the following validity checks in addition to those 2665 specified in Section 12.2: 2667 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2668 16 octets. 2670 Upon the reception of an R1 message, the host extracts the Initiator 2671 Nonce and the Locator Pair from the message (the latter from the 2672 source and destination fields in the IPv6 header). Next the host 2673 looks for an existing context which matches the Initiator Nonce and 2674 where the locators are contained in Ls(peer) and Ls(local), 2675 respectively. If no such context is found, then the R1 message is 2676 silently discarded. 2678 If such a context is found, then the host looks at the state: 2680 o If the state is I1-SENT, then it sends an I2 message as specified 2681 below. 2683 o In any other state (I2-SENT, I2BIS-SENT, ESTABLISHED) then the 2684 host has already sent an I2 message then this is probably a reply 2685 to a retransmitted I1 message, so this R1 message MUST be silently 2686 discarded. 2688 When the host sends an I2 message, then it includes the Responder 2689 Validator option that was in the R1 message. The I2 message MUST 2690 include the ULID pair; normally in the IPv6 source and destination 2691 fields. If a ULID-pair option was included in the I1 message then it 2692 MUST be included in the I2 message as well. In addition, if the 2693 Forked Instance Identifier value for this context is non-zero, the I2 2694 message MUST contain a Forked Instance Identifier Option carrying 2695 this value. Besides, the I2 message contains an Initiator Nonce. 2696 This is not required to be the same than the one included in the 2697 previous I1 message. 2699 The I2 message also includes the Initiator's locator list and the CGA 2700 parameter data structure. If CGA (and not HBA) is used to verify the 2701 locator list, then Initiator also signs the key parts of the message 2702 and includes a CGA signature option containing the signature. 2704 When the I2 message has been sent, the state is set to I2-SENT. 2706 7.12. Retransmitting I2 messages 2708 If the initiator does not receive an R2 message after I2_TIMEOUT time 2709 after sending an I2 message it MAY retransmit the I2 message, using 2710 binary exponential backoff and randomized timers. The Responder 2711 Validator option might have a limited lifetime, that is, the peer 2712 might reject Responder Validator options that are older than 2713 VALIDATOR_MIN_LIFETIME to avoid replay attacks. Thus the initiator 2714 SHOULD fall back to retransmitting the I1 message when there is no R2 2715 received after retransmitting the I2 message I2_RETRIES_MAX times. 2717 7.13. Receiving I2 messages 2719 A host MUST silently discard any received I2 messages that do not 2720 satisfy all of the following validity checks in addition to those 2721 specified in Section 12.2: 2723 o The Hdr Ext Len field is at least 2, i.e., the length is at least 2724 24 octets. 2726 Upon the reception of an I2 message, the host extracts the ULID pair 2727 and the Forked Instance identifier from the message. If there is no 2728 ULID-pair option, then the ULID pair is taken from the source and 2729 destination fields in the IPv6 header. If there is no FII option in 2730 the message, then the FII value is taken to be zero. 2732 Next the host verifies that the Responder Nonce is a recent one 2733 (Nonces that are no older than VALIDATOR_MIN_LIFETIME SHOULD be 2734 considered recent), and that the Responder Validator option matches 2735 the validator the host would have computed for the ULID, locators, 2736 responder nonce, and FII. 2738 If a CGA Parameter Data Structure (PDS) is included in the message, 2739 then the host MUST verify if the actual PDS contained in the message 2740 corresponds to the ULID(peer). 2742 If any of the above verifications fails, then the host silently 2743 discards the message and it has completed the I2 processing. 2745 If all the above verifications are successful, then the host proceeds 2746 to look for a context state for the Initiator. The host looks for a 2747 context with the extracted ULID pair and FII. If none exist then 2748 state of the (non-existing) context is viewed as being IDLE, thus the 2749 actions depend on the state as follows: 2751 o If the state is IDLE (i.e., the context does not exist) the host 2752 allocates a context tag (CT(local)), creates the context state for 2753 the context, and sets its state to ESTABLISHED. It records 2754 CT(peer), and the peer's locator set as well as its own locator 2755 set in the context. It SHOULD perform the HBA/CGA verification of 2756 the peer's locator set at this point in time, as specified in 2757 Section 7.2. Then the host sends an R2 message back as specified 2758 below. 2760 o If the state is I1-SENT, then the host verifies if the source 2761 locator is included in Ls(peer) or, it is included in the Locator 2762 List contained in the the I2 message and the HBA/CGA verification 2763 for this specific locator is successful 2765 * If this is not the case, then the message is silently discarded 2766 and the context state remains unchanged. 2768 * If this is the case, then the host updates the context 2769 information (CT(peer), Ls(peer)) with the data contained in the 2770 I2 message and the host MUST send a R2 message back as 2771 specified below. Note that before updating Ls(peer) 2772 information, the host SHOULD perform the HBA/CGA validation of 2773 the peer's locator set at this point in time as specified in 2774 Section 7.2. The host moves to ESTABLISHED state. 2776 o If the state is ESTABLISHED, I2-SENT, or I2BIS-SENT, then the host 2777 verifies if the source locator is included in Ls(peer) or, it is 2778 included in the Locator List contained in the the I2 message and 2779 the HBA/CGA verification for this specific locator is successful 2781 * If this is not the case, then the message is silently discarded 2782 and the context state remains unchanged. 2784 * If this is the case, then the host updates the context 2785 information (CT(peer), Ls(peer)) with the data contained in the 2786 I2 message and the host MUST send a R2 message back as 2787 specified in Section 7.14. Note that before updating Ls(peer) 2788 information, the host SHOULD perform the HBA/CGA validation of 2789 the peer's locator set at this point in time as specified in 2790 Section 7.2. The context state remains unchanged. 2792 7.14. Sending R2 messages 2794 Before the host sends the R2 message it MUST look for a possible 2795 context confusion i.e. where it would end up with multiple contexts 2796 using the same CT(peer) for the same peer host. See Section 7.15. 2798 When the host needs to send an R2 message, the host forms the message 2799 using its locators and its context tag, copies the Initiator Nonce 2800 from the triggering message (I2, I2bis, or I1), and includes the 2801 necessary options so that the peer can verify the locators. In 2802 particular, the R2 message includes the Responder's locator list and 2803 the PDS option. If CGA (and not HBA) is used to verify the locator 2804 list, then the Responder also signs the key parts of the message and 2805 includes a CGA Signature option containing the signature. 2807 R2 messages are never retransmitted. If the R2 message is lost, then 2808 the initiator will retransmit either the I2/I2bis or I1 message. 2809 Either retransmission will cause the responder to find the context 2810 state and respond with an R2 message. 2812 7.15. Match for Context Confusion 2814 When the host receives an I2, I2bis, or R2 it MUST look for a 2815 possible context confusion i.e. where it would end up with multiple 2816 contexts using the same CT(peer) for the same peer host. This can 2817 happen when it has received the above messages since they create a 2818 new context with a new CT(peer). Same issue applies when CT(peer) is 2819 updated for an existing context. 2821 The host takes CT(peer) for the newly created or updated context, and 2822 looks for other contexts which: 2824 o Are in state ESTABLISHED or I2BIS-SENT. 2826 o Have the same CT(peer). 2828 o Where Ls(peer) has at least one locator in common with the newly 2829 created or updated context. 2831 If such a context is found, then the host checks if the ULID pair or 2832 the Forked Instance Identifier different than the ones in the newly 2833 created or updated context: 2835 o If either or both are different, then the peer is reusing the 2836 context tag for the creation of a context with different ULID pair 2837 or FII, which is an indication that the peer has lost the original 2838 context. In this case, we are in the Context confusion situation, 2839 and the host MUST NOT use the old context to send any packets. It 2840 MAY just discard the old context (after all, the peer has 2841 discarded it), or it MAY attempt to re-establish the old context 2842 by sending a new I1 message and moving its state to I1-SENT. In 2843 any case, once that this situation is detected, the host MUST NOT 2844 keep two contexts with overlapping Ls(peer) locator sets and the 2845 same context tag in ESTABLISHED state, since this would result in 2846 demultiplexing problems on the peer. 2848 o If both are the same, then this context is actually the context 2849 that is created or updated, hence there is no confusion. 2851 7.16. Receiving R2 messages 2853 A host MUST silently discard any received R2 messages that do not 2854 satisfy all of the following validity checks in addition to those 2855 specified in Section 12.2: 2857 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2858 16 octets. 2860 Upon the reception of an R2 message, the host extracts the Initiator 2861 Nonce and the Locator Pair from the message (the latter from the 2862 source and destination fields in the IPv6 header). Next the host 2863 looks for an existing context which matches the Initiator Nonce and 2864 where the locators are Lp(peer) and Lp(local), respectively. Based 2865 on the state: 2867 o If no such context is found, i.e., the state is IDLE, then the 2868 message is silently dropped. 2870 o If state is I1-SENT, I2-SENT, or I2BIS-SENT then the host performs 2871 the following actions: If a CGA Parameter Data Structure (PDS) is 2872 included in the message, then the host MUST verify that the actual 2873 PDS contained in the message corresponds to the ULID(peer) as 2874 specified in Section 7.2. If the verification fails, then the 2875 message is silently dropped. If the verification succeeds, then 2876 the host records the information from the R2 message in the 2877 context state; it records the peer's locator set and CT(peer). 2878 The host SHOULD perform the HBA/CGA verification of the peer's 2879 locator set at this point in time, as specified in Section 7.2. 2881 The host sets its state to ESTABLISHED. 2883 o If the state is ESTABLISHED, the R2 message is silently ignored, 2884 (since this is likely to be a reply to a retransmitted I2 2885 message). 2887 Before the host completes the R2 processing it MUST look for a 2888 possible context confusion i.e. where it would end up with multiple 2889 contexts using the same CT(peer) for the same peer host. See 2890 Section 7.15. 2892 7.17. Sending R1bis messages 2894 Upon the receipt of a shim6 payload extension header where there is 2895 no current SHIM6 context at the receiver, the receiver is to respond 2896 with an R1bis message in order to enable a fast re-establishment of 2897 the lost SHIM6 context. 2899 Also a host is to respond with a R1bis upon receipt of any control 2900 messages that has a message type in the range 64-127 (i.e., excluding 2901 the context setup messages such as I1, R1, R1bis, I2, I2bis, R2 and 2902 future extensions), where the control message refers to a non 2903 existent context. 2905 We assume that all the incoming packets that trigger the generation 2906 of an R1bis message contain a locator pair (in the address fields of 2907 the IPv6 header) and a Context Tag. 2909 Upon reception of any of the packets described above, the host will 2910 reply with an R1bis including the following information: 2912 o The Responder Nonce is a number picked by the responder which the 2913 initiator will return in the I2bis message. 2915 o Packet Context Tag is the context tag contained in the received 2916 packet that triggered the generation of the R1bis message. 2918 o The Responder Validator option is included, with a validator that 2919 is computed as suggested in the next section. 2921 7.17.1. Generating the R1bis Validator 2923 One way for the responder to properly generate validators is to 2924 maintain a single secret (S) and a running counter for the Responder 2925 Nonce. 2927 In the case the validator is generated to be included in a R1bis 2928 message, for each received payload extension header or control 2929 message, the responder can increase the counter, use the counter 2930 value as the responder nonce, and use the following information 2931 concatenated as input to the one-way function: 2933 o The the secret S 2935 o That Responder Nonce 2937 o The Receiver Context tag included in the received packet 2939 o The locators from the received packet 2941 and then the output of the hash function is used as the validator 2942 octet string. 2944 7.18. Receiving R1bis messages and sending I2bis messages 2946 A host MUST silently discard any received R1bis messages that do not 2947 satisfy all of the following validity checks in addition to those 2948 specified in Section 12.2: 2950 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2951 16 octets. 2953 Upon the reception of an R1bis message, the host extracts the Packet 2954 Context Tag and the Locator Pair from the message (the latter from 2955 the source and destination fields in the IPv6 header). Next the host 2956 looks for an existing context where the Packet Context Tag matches 2957 CT(peer) and where the locators match Lp(peer) and Lp(local), 2958 respectively. 2960 o If no such context is not found, i.e., the state is IDLE, then the 2961 R1bis message is silently discarded. 2963 o If the state is I1-SENT, I2-SENT, or I2BIS-SENT, then the R1bis 2964 message is silently discarded. 2966 o If the state is ESTABLISHED, then we are in the case where the 2967 peer has lost the context and the goal is to try to re-establish 2968 it. For that, the host leaves CT(peer) unchanged in the context 2969 state, transitions to I2BIS-SENT state, and sends a I2bis message, 2970 including the computed Responder Validator option, the Packet 2971 Context Tag, and the Responder Nonce received in the R1bis 2972 message. This I2bis message is sent using the locator pair 2973 included in the R1bis message. In the case that this locator pair 2974 differs from the ULID pair defined for this context, then an ULID 2975 option MUST be included in the I2bis message. In addition, if the 2976 Forked Instance Identifier for this context is non-zero, then a 2977 Forked Instance Identifier option carrying the instance identifier 2978 value for this context MUST be included in the I2bis message. 2980 7.19. Retransmitting I2bis messages 2982 If the initiator does not receive an R2 message after I2bis_TIMEOUT 2983 time after sending an I2bis message it MAY retransmit the I2bis 2984 message, using binary exponential backoff and randomized timers. The 2985 Responder Validator option might have a limited lifetime, that is, 2986 the peer might reject Responder Validator options that are older than 2987 VALIDATOR_MIN_LIFETIME to avoid replay attacks. Thus the initiator 2988 SHOULD fall back to retransmitting the I1 message when there is no R2 2989 received after retransmitting the I2bis message I2bis_RETRIES_MAX 2990 times. 2992 7.20. Receiving I2bis messages and sending R2 messages 2994 A host MUST silently discard any received I2bis messages that do not 2995 satisfy all of the following validity checks in addition to those 2996 specified in Section 12.2: 2998 o The Hdr Ext Len field is at least 3, i.e., the length is at least 2999 32 octets. 3001 Upon the reception of an I2bis message, the host extracts the ULID 3002 pair and the Forked Instance identifier from the message. If there 3003 is no ULID-pair option, then the ULID pair is taken from the source 3004 and destination fields in the IPv6 header. If there is no FII option 3005 in the message, then the FII value is taken to be zero. 3007 Next the host verifies that the Responder Nonce is a recent one 3008 (Nonces that are no older than VALIDATOR_MIN_LIFETIME SHOULD be 3009 considered recent), and that the Responder Validator option matches 3010 the validator the host would have computed for the ULID, locators, 3011 responder nonce, and FII as part of sending an R1bis message. 3013 If a CGA Parameter Data Structure (PDS) is included in the message, 3014 then the host MUST verify if the actual PDS contained in the message 3015 corresponds to the ULID(peer). 3017 If any of the above verifications fails, then the host silently 3018 discard the message and it has completed the I2bis processing. 3020 If both verifications are successful, then the host proceeds to look 3021 for a context state for the Initiator. The host looks for a context 3022 with the extracted ULID pair and FII. If none exist then state of 3023 the (non-existing) context is viewed as being IDLE, thus the actions 3024 depend on the state as follows: 3026 o If the state is IDLE (i.e., the context does not exist) the host 3027 allocates a context tag (CT(local)), creates the context state for 3028 the context, and sets its state to ESTABLISHED. The host SHOULD 3029 NOT use the Packet Context Tag in the I2bis message for CT(local); 3030 instead it should pick a new random context tag just as when it 3031 processes an I2 message. It records CT(peer), and the peer's 3032 locator set as well as its own locator set in the context. It 3033 SHOULD perform the HBA/CGA verification of the peer's locator set 3034 at this point in time as specified in Section 7.2. Then the host 3035 sends an R2 message back as specified in Section 7.14. 3037 o If the state is I1-SENT, then the host verifies if the source 3038 locator is included in Ls(peer) or, it is included in the Locator 3039 List contained in the the I2 message and the HBA/CGA verification 3040 for this specific locator is successful 3042 * If this is not the case, then the message is silently 3043 discarded. The the context state remains unchanged. 3045 * If this is the case, then the host updates the context 3046 information (CT(peer), Ls(peer)) with the data contained in the 3047 I2 message and the host MUST send a R2 message back as 3048 specified below. Note that before updating Ls(peer) 3049 information, the host SHOULD perform the HBA/CGA validation of 3050 the peer's locator set at this point in time as specified in 3051 Section 7.2. The host moves to ESTABLISHED state. 3053 o If the state is ESTABLISHED, I2-SENT, or I2BIS-SENT, then the host 3054 verifies if the source locator is included in Ls(peer) or, it is 3055 included in the Locator List contained in the the I2 message and 3056 the HBA/CGA verification for this specific locator is successful 3058 * If this is not the case, then the message is silently 3059 discarded. The the context state remains unchanged. 3061 * If this is the case, then the host updates the context 3062 information (CT(peer), Ls(peer)) with the data contained in the 3063 I2 message and the host MUST send a R2 message back as 3064 specified in Section 7.14. Note that before updating Ls(peer) 3065 information, the host SHOULD perform the HBA/CGA validation of 3066 the peer's locator set at this point in time as specified in 3067 Section 7.2. The context state remains unchanged. 3069 8. Handling ICMP Error Messages 3071 The routers in the path as well as the destination might generate 3072 various ICMP error messages, such as host unreachable, packet too 3073 big, and Unrecognized Next Header type. It is critical that these 3074 packets make it back up to the ULPs so that they can take appropriate 3075 action. 3077 This is an implementation issue in the sense that the mechanism is 3078 completely local to the host itself. But the issue of how ICMP 3079 errors are correctly dispatched to the ULP on the host are important, 3080 hence this section specifies the issue. 3082 +--------------+ 3083 | IPv6 Header | 3084 | | 3085 +--------------+ 3086 | ICMPv6 | 3087 | Header | 3088 - - +--------------+ - - 3089 | IPv6 Header | 3090 | src, dst as | Can be dispatched 3091 IPv6 | sent by ULP | unmodified to ULP 3092 | on host | ICMP error handler 3093 Packet +--------------+ 3094 | ULP | 3095 in | Header | 3096 +--------------+ 3097 Error | | 3098 ~ Data ~ 3099 | | 3100 - - +--------------+ - - 3102 Figure 29: ICMP error handling without payload extension header 3104 When the ULP packets are sent without the payload extension header, 3105 that is, while the initial locators=ULIDs are working, this 3106 introduces no new concerns; an implementation's existing mechanism 3107 for delivering these errors to the ULP will work. See Figure 29. 3109 But when the shim on the transmitting side inserts the payload 3110 extension header and replaces the ULIDs in the IP address fields with 3111 some other locators, then an ICMP error coming back will have a 3112 "packet in error" which is not a packet that the ULP sent. Thus the 3113 implementation will have to apply the reverse mapping to the "packet 3114 in error" before passing the ICMP error up to the ULP. See 3115 Figure 30. 3117 +--------------+ 3118 | IPv6 Header | 3119 | | 3120 +--------------+ 3121 | ICMPv6 | 3122 | Header | 3123 - - +--------------+ - - 3124 | IPv6 Header | 3125 | src, dst as | Needs to be 3126 IPv6 | modified by | transformed to 3127 | shim on host | have ULIDs 3128 +--------------+ in src, dst fields, 3129 Packet | SHIM6 ext. | and SHIM6 ext. 3130 | Header | header removed 3131 in +--------------+ before it can be 3132 | Transport | dispatched to the ULP 3133 Error | Header | ICMP error handler. 3134 +--------------+ 3135 | | 3136 ~ Data ~ 3137 | | 3138 - - +--------------+ - - 3140 Figure 30: ICMP error handling with payload extension header 3142 Note that this mapping is different than when receiving packets from 3143 the peer with a payload extension headers, because in that case the 3144 packets contain CT(local). But the ICMP errors have a "packet in 3145 error" with an payload extension header containing CT(peer). This is 3146 because they were intended to be received by the peer. In any case, 3147 since the has to be 3148 unique when received by the peer, the local host should also only be 3149 able to find one context that matches this tuple. 3151 If the ICMP error is a Packet Too Big, the reported MTU must be 3152 adjusted to be 8 octets less, since the shim will add 8 octets when 3153 sending packets. 3155 After the "packet in error" has had the original ULIDs inserted, then 3156 this payload extension header can be removed. The result is a 3157 "packet in error" that is passed to the ULP which looks as if the 3158 shim did not exist. 3160 9. Teardown of the ULID-Pair Context 3162 Each host can unilaterally decide when to tear down a ULID-pair 3163 context. It is RECOMMENDED that hosts do not tear down the context 3164 when they know that there is some upper layer protocol that might use 3165 the context. For example, an implementation might know this if there 3166 is an open socket which is connected to the ULID(peer). However, 3167 there might be cases when the knowledge is not readily available to 3168 the shim layer, for instance for UDP applications which do not 3169 connect their sockets, or any application which retains some higher 3170 level state across (TCP) connections and UDP packets. 3172 Thus it is RECOMMENDED that implementations minimize premature 3173 teardown by observing the amount of traffic that is sent and received 3174 using the context, and only after it appears quiescent, tear down the 3175 state. A reasonable approach would be not to tear down a context 3176 until at least 5 minutes have passed since the last message was sent 3177 or received using the context. 3179 Since there is no explicit, coordinated removal of the context state, 3180 there are potential issues around context tag reuse. One end might 3181 remove the state, and potentially reuse that context tag for some 3182 other communication, and the peer might later try to use the old 3183 context (which it didn't remove). The protocol has mechanisms to 3184 recover from this, which work whether the state removal was total and 3185 accidental (e.g., crash and reboot of the host), or just a garbage 3186 collection of shim state that didn't seem to be used. However, the 3187 host should try to minimize the reuse of context tags by trying to 3188 randomly cycle through the 2^47 context tag values. (See Appendix C 3189 for a summary how the recovery works in the different cases.) 3191 10. Updating the Peer 3193 The Update Request and Acknowledgement are used both to update the 3194 list of locators (only possible when CGA is used to verify the 3195 locator(s)), as well as updating the preferences associated with each 3196 locator. 3198 10.1. Sending Update Request messages 3200 When a host has a change in the locator set, then it can communicate 3201 this to the peer by sending an Update Request. When a host has a 3202 change in the preferences for its locator set, it can also 3203 communicate this to the peer. The Update Request message can include 3204 just a Locator List option, to convey the new set of locators (which 3205 requires a CGA signature option as well), just a Locator Preferences 3206 option, or both a new Locator List and new Locator Preferences. 3208 Should the host send a new Locator List, the host picks a new random 3209 local generation number, records this in the context, and puts it in 3210 the Locator List option. Any Locator Preference option, whether send 3211 in the same Update Request or in some future Update Request, will use 3212 that generation number to make sure the preferences get applied to 3213 the correct version of the locator list. 3215 The host picks a random Request Nonce for each update, and keeps the 3216 same nonce for any retransmissions of the Update Request. The nonce 3217 is used to match the acknowledgement with the request. 3219 10.2. Retransmitting Update Request messages 3221 If the host does not receive an Update Acknowledgement R2 message in 3222 response to the Update Request message after UPDATE_TIMEOUT time, 3223 then it needs to retransmit the Update Request message. The 3224 retransmissions should use a retransmission timer with binary 3225 exponential backoff to avoid creating congestion issues for the 3226 network when lots of hosts perform Update Request retransmissions. 3227 Also, the actual timeout value should be randomized between 0.5 and 3228 1.5 of the nominal value to avoid self-synchronization. 3230 Should there be no response, the retransmissions continue forever. 3231 The binary exponential backoff stops at MAX_UPDATE_TIMEOUT. But the 3232 only way the retransmissions would stop when there is no 3233 acknowledgement, is when the shim, through the Probe protocol or some 3234 other mechanism, decides to discard the context state due to lack of 3235 ULP usage in combination with no responses to the Probes. 3237 10.3. Newer Information While Retransmitting 3239 There can be at most one outstanding Update Request message at any 3240 time. Thus until e.g. an update with a new Locator List has been 3241 acknowledged, any even newer Locator List or new Locator Preferences 3242 can not just be sent. However, when there is newer information and 3243 the older information has not yet been acknowledged, the host can 3244 instead of waiting for an acknowledgement, abandon the previous 3245 update and construct a new Update Request (with a new Request Nonce) 3246 which includes the new information as well as the information that 3247 hadn't yet been acknowledged. 3249 For example, if the original locator list was just (A1, A2), and if 3250 an Update Request with the Locator List (A1, A3) is outstanding, and 3251 the host determines that it should both add A4 to the locator list, 3252 and mark A1 as BROKEN, then it would need to: 3254 o Pick a new random Request Nonce for the new Update Request. 3256 o Pick a new random Generation number for the new locator list. 3258 o Form the new locator list - (A1, A3, A4) 3260 o Form a Locator Preference option which uses the new generation 3261 number and has the BROKEN flag for the first locator. 3263 o Send the Update Request and start a retransmission timer. 3265 Any Update Acknowledgement which doesn't match the current request 3266 nonce, for instance an acknowledgement for the abandoned Update 3267 Request, will be silently ignored. 3269 10.4. Receiving Update Request messages 3271 A host MUST silently discard any received Update Request messages 3272 that do not satisfy all of the following validity checks in addition 3273 to those specified in Section 12.2: 3275 o The Hdr Ext Len field is at least 1, i.e., the length is at least 3276 16 octets. 3278 Upon the reception of an Update Request message, the host extracts 3279 the Context Tag from the message. It then looks for a context which 3280 has a CT(local) that matches the context tag. If no such context is 3281 found, it sends a R1bis message as specified in Section 7.17. 3283 Since context tags can be reused, the host MUST verify that the IPv6 3284 source address field is part of Ls(peer) and that the IPv6 3285 destination address field is part of Ls(local). If this is not the 3286 case, the sender of the Update Request has a stale context which 3287 happens to match the CT(local) for this context. In this case the 3288 host MUST send a R1bis message, and otherwise ignore the Update 3289 Request message. 3291 If a CGA Parameter Data Structure (PDS) is included in the message, 3292 then the host MUST verify if the actual PDS contained in the packet 3293 corresponds to the ULID(peer). If this verification fails, the 3294 message is silently discarded. 3296 Then, depending on the state of the context: 3298 o If ESTABLISHED: Proceed to process message. 3300 o If I1-SENT, discard the message and stay in I1-SENT. 3302 o If I2-SENT, then send R2 and proceed to process the message. 3304 o If I2BIS-SENT, then send R2 and proceed to process the message. 3306 The verification issues for the locators carried in the Locator 3307 Update message are specified in Section 7.2. If the locator list can 3308 not be verified, this procedure might send an ICMP Parameter Problem 3309 error. In any case, if it can not be verified, there is no further 3310 processing of the Update Request. 3312 Once any Locator List option in the Update Request has been verified, 3313 the peer generation number in the context is updated to be the one in 3314 the Locator List option. 3316 If the Update message contains a Locator Preference option, then the 3317 Generation number in the preference option is compared with the peer 3318 generation number in the context. If they do not match, then the 3319 host generates an ICMP parameter problem (type 4, code 0) with the 3320 Pointer field referring to the first octet in the Generation number 3321 in the Locator Preference option. In addition, if the number of 3322 elements in the Locator Preference option does not match the number 3323 of locators in Ls(peer), then an ICMP parameter problem is sent with 3324 the Pointer referring to the first octet of the Length field in the 3325 Locator Preference option. In both cases of failures, no further 3326 processing is performed for the Locator Update message. 3328 If the generation number matches, the locator preferences are 3329 recorded in the context. 3331 Once the Locator List option (if present) has been verified and any 3332 new locator list or locator preferences have been recorded, the host 3333 sends an Update Acknowledgement message, copying the nonce from the 3334 request, and using the CT(peer) in as the Receiver Context Tag. 3336 Any new locators, or more likely new locator preferences, might 3337 result in the host wanting to select a different locator pair for the 3338 context. For instance, if the Locator Preferences lists the current 3339 Lp(peer) as BROKEN. The host uses the Probe message in [8] to verify 3340 that the new locator is reachable before changing Lp(peer). 3342 10.5. Receiving Update Acknowledgement messages 3344 A host MUST silently discard any received Update Acknowledgement 3345 messages that do not satisfy all of the following validity checks in 3346 addition to those specified in Section 12.2: 3348 o The Hdr Ext Len field is at least 1, i.e., the length is at least 3349 16 octets. 3351 Upon the reception of an Update Acknowledgement message, the host 3352 extracts the Context Tag and the Request Nonce from the message. It 3353 then looks for a context which has a CT(local) that matches the 3354 context tag. If no such context is found, it sends a R1bis message 3355 as specified in Section 7.17. 3357 Since context tags can be reused, the host MUST verify that the IPv6 3358 source address field is part of Ls(peer) and that the IPv6 3359 destination address field is part of Ls(local). If this is not the 3360 case, the sender of the Update Acknowledgement has a stale context 3361 which happens to match the CT(local) for this context. In this case 3362 the host MUST send a R1bis message, and otherwise ignore the Update 3363 Acknowledgement message. 3365 Then, depending on the state of the context: 3367 o If ESTABLISHED: Proceed to process message. 3369 o If I1-SENT, discard the message and stay in I1-SENT. 3371 o If I2-SENT, then send R2 and proceed to process the message. 3373 o If I2BIS-SENT, then send R2 and proceed to process the message. 3375 If the Request Nonce doesn't match the Nonce for the last sent Update 3376 Request for the context, then the Update Acknowledgement is silently 3377 ignored. If the nonce matches, then the update has been completed 3378 and the Update retransmit timer can be reset. 3380 11. Sending ULP Payloads 3382 When there is no context state for the ULID pair on the sender, there 3383 is no effect on how ULP packets are sent. If the host is using some 3384 heuristic for determining when to perform a deferred context 3385 establishment, then the host might need to do some accounting (count 3386 the number of packets sent and received) even before there is a ULID- 3387 pair context. 3389 If the context is not in ESTABLISHED or I2BIS-SENT state, then it 3390 there is also no effect on how the ULP packets are sent. Only in the 3391 ESTABLISHED and I2BIS-SENT states does the host have CT(peer) and 3392 Ls(peer) set. 3394 If there is a ULID-pair context for the ULID pair, then the sender 3395 needs to verify whether context uses the ULIDs as locators, that is, 3396 whether Lp(peer) == ULID(peer) and Lp(local) == ULID(local). 3398 If this is the case, then packets can be sent unmodified by the shim. 3399 If it is not the case, then the logic in Section 11.1 will need to be 3400 used. 3402 There will also be some maintenance activity relating to 3403 (un)reachability detection, whether packets are sent with the 3404 original locators or not. The details of this is out of scope for 3405 this document and is specified in [8]. 3407 11.1. Sending ULP Payload after a Switch 3409 When sending packets, if there is a ULID-pair context for the ULID 3410 pair, and the ULID pair is no longer used as the locator pair, then 3411 the sender needs to transform the packet. Apart from replacing the 3412 IPv6 source and destination fields with a locator pair, an 8-octet 3413 header is added so that the receiver can find the context and inverse 3414 the transformation. 3416 If there has been a failure causing a switch, and later the context 3417 switches back to sending things using the ULID pair as the locator 3418 pair, then there is no longer a need to do any packet transformation 3419 by the sender, hence there is no need to include the 8-octet 3420 extension header. 3422 First, the IP address fields are replaced. The IPv6 source address 3423 field is set to Lp(local) and the destination address field is set to 3424 Lp(peer). NOTE that this MUST NOT cause any recalculation of the ULP 3425 checksums, since the ULP checksums are carried end-to-end and the ULP 3426 pseudo-header contains the ULIDs which are preserved end-to-end. 3428 The sender skips any "routing sub-layer extension headers" that the 3429 ULP might have included, thus it skips any hop-by-hop extension 3430 header, any routing header, and any destination options header that 3431 is followed by a routing header. After any such headers the shim6 3432 extension header will be added. This might be before a Fragment 3433 header, a Destination Options header, an ESP or AH header, or a ULP 3434 header. 3436 The inserted shim6 Payload extension header includes the peer's 3437 context tag. It takes on the next header value from the preceding 3438 extension header, since that extension header will have a next header 3439 value of SHIM6. 3441 12. Receiving Packets 3443 As in normal IPv6 receive side packet processing the receiver parses 3444 the (extension) headers in order. Should it find a shim6 extension 3445 header it will look at the "P" field in that header. If this bit is 3446 zero, then the packet must be passed to the shim6 payload handling 3447 for rewriting. Otherwise, the packet is passed to the shim6 control 3448 handling. 3450 12.1. Receiving Payload Extension Headers 3452 The receiver extracts the context tag from the payload extension 3453 header, and uses this to find a ULID-pair context. If no context is 3454 found, the receiver SHOULD generate a R1bis message (see 3455 Section 7.17). 3457 Then, depending on the state of the context: 3459 o If ESTABLISHED: Proceed to process message. 3461 o If I1-SENT, discard the message and stay in I1-SENT. 3463 o If I2-SENT, then send R2 and proceed to process the message. 3465 o If I2BIS-SENT, then send R2 and proceed to process the message. 3467 With the context in hand, the receiver can now replace the IP address 3468 fields with the ULIDs kept in the context. Finally, the Payload 3469 extension header is removed from the packet (so that the ULP doesn't 3470 get confused by it), and the next header value in the preceding 3471 header is set to be the actual protocol number for the payload. Then 3472 the packet can be passed to the protocol identified by the next 3473 header value (which might be some function associated with the IP 3474 endpoint sublayer, or a ULP). 3476 If the host is using some heuristic for determining when to perform a 3477 deferred context establishment, then the host might need to do some 3478 accounting (count the number of packets sent and received) for 3479 packets that does not have a shim6 extension header and for which 3480 there is no context. But the need for this depends on what 3481 heuristics the implementation has chosen. 3483 12.2. Receiving Shim Control messages 3485 A shim control message has the checksum field verified. The Shim 3486 header length field is also verified against the length of the IPv6 3487 packet to make sure that the shim message doesn't claim to end past 3488 the end of the IPv6 packet. Finally, it checks that the neither the 3489 IPv6 destination field nor the IPv6 source field is a multicast 3490 address. If any of those checks fail, the packet is silently 3491 dropped. 3493 The message is then dispatched based on the shim message type. Each 3494 message type is then processed as described elsewhere in this 3495 document. If the packet contains a shim message type which is 3496 unknown to the receiver, then an ICMPv6 Parameter Problem error is 3497 generated and sent back. The pointer field in the Parameter Problem 3498 is set to point at the first octet of the shim message type. The 3499 error is rate limited just like other ICMP errors [5]. 3501 All the control messages can contain any options with C=0. If there 3502 is any option in the message with C=1 that isn't known to the host, 3503 then the host MUST send an ICMPv6 Parameter Problem, with the Pointer 3504 field referencing the first octet of the Option Type. 3506 12.3. Context Lookup 3508 We assume that each shim context has its own state machine. We 3509 assume that a dispatcher delivers incoming packets to the state 3510 machine that it belongs to. Here we describe the rules used for the 3511 dispatcher to deliver packets to the correct shim context state 3512 machine. 3514 There is one state machine per context identified that is 3515 conceptually identified by ULID pair and Forked Instance Identifier 3516 (which is zero by default), or identified by CT(local). However, the 3517 detailed lookup rules are more complex, especially during context 3518 establishment. 3520 Clearly, if the required context is not established, it will be in 3521 IDLE state. 3523 During context establishment, the context is identified as follows: 3525 o I1 packets: Deliver to the context associated with the ULID pair 3526 and the Forked Instance Identifier. 3528 o I2 packets: Deliver to the context associated with the ULID pair 3529 and the Forked Instance Identifier. 3531 o R1 packets: Deliver to the context with the locator pair included 3532 in the packet and the Initiator nonce included in the packet (R1 3533 does not contain ULID pair nor the CT(local)). If no context 3534 exist with this locator pair and Initiator nonce, then silently 3535 discard. 3537 o R2 packets: Deliver to the context with the locator pair included 3538 in the packet and the Initiator nonce included in the packet (R2 3539 does not contain ULID pair nor the CT(local)). If no context 3540 exists with this locator pair and INIT nonce, then silently 3541 discard. 3543 o R1bis packet: deliver to the context that has the locator pair and 3544 the CT(peer) equal to the Packet Context Tag included in the R1bis 3545 packet. 3547 o I2bis packets: Deliver to the context associated with the ULID 3548 pair and the Forked Instance Identifier. 3550 o Payload extension headers: Deliver to the context with CT(local) 3551 equal to the Receiver Context Tag included in the packet. 3553 o Other control messages (Update, Keepalive, Probe): Deliver to the 3554 context with CT(local) equal to the Receiver Context Tag included 3555 in the packet. Verify that the IPv6 source address field is part 3556 of Ls(peer) and that the IPv6 destination address field is part of 3557 Ls(local). If not, send a R1bis message. 3559 o ICMP errors which contain a shim6 payload extension header or 3560 other shim control packet in the "packet in error": Use the 3561 "packet in error" for dispatching as follows. Deliver to the 3562 context with CT(peer) equal to the Receiver Context Tag, Lp(local) 3563 being the IPv6 source address, and Lp(peer) being the IPv6 3564 destination address. 3566 In addition, the shim on the sending side needs to be able to find 3567 the context state when a ULP packet is passed down from the ULP. In 3568 that case the lookup key is the pair of ULIDs and FII=0. If we have 3569 a ULP API that allows the ULP to do context forking, then presumably 3570 the ULP would pass down the Forked Instance Identifier. 3572 13. Initial Contact 3574 The initial contact is some non-shim communication between two ULIDs, 3575 as described in Section 2. At that point in time there is no 3576 activity in the shim. 3578 Whether the shim ends up being used or not (e.g., the peer might not 3579 support shim6) it is highly desirable that the initial contact can be 3580 established even if there is a failure for one or more IP addresses. 3582 The approach taken is to rely on the applications and the transport 3583 protocols to retry with different source and destination addresses, 3584 consistent with what is already specified in Default Address 3585 Selection [12], and some fixes to that specification [13] to make it 3586 try different source addresses and not only different destination 3587 addresses. 3589 The implementation of such an approach can potentially result in long 3590 timeouts. For instance, a naive implementation at the socket API 3591 which uses getaddrinfo() to retrieve all destination addresses and 3592 then tries to bind() and connect() to try all source and destination 3593 address combinations waiting for TCP to time out for each combination 3594 before trying the next one. 3596 However, if implementations encapsulate this in some new connect-by- 3597 name() API, and use non-blocking connect calls, it is possible to 3598 cycle through the available combinations in a more rapid manner until 3599 a working source and destination pair is found. Thus the issues in 3600 this domain are issues of implementations and the current socket API, 3601 and not issues of protocol specification. In all honesty, while 3602 providing an easy to use connect-by-name() API for TCP and other 3603 connection-oriented transports is easy; providing a similar 3604 capability at the API for UDP is hard due to the protocol itself not 3605 providing any "success" feedback. But even the UDP issue is one of 3606 APIs and implementation. 3608 14. Protocol constants 3610 The protocol uses the following constants: 3612 I1_RETRIES_MAX = 4 3614 I1_TIMEOUT = 4 seconds 3616 NO_R1_HOLDDOWN_TIME = 1 min 3618 ICMP_HOLDDOWN_TIME = 10 min 3620 I2_TIMEOUT = 4 seconds 3622 I2_RETRIES_MAX = 2 3624 I2bis_TIMEOUT = 4 seconds 3626 I2bis_RETRIES_MAX = 2 3628 VALIDATOR_MIN_LIFETIME = 30 seconds 3630 UPDATE_TIMEOUT = 4 seconds 3632 The retransmit timers (I1_TIMEOUT, I2_TIMEOUT, UPDATE_TIMEOUT) are 3633 subject to binary exponential backoff, as well as randomization 3634 across a range of 0.5 and 1.5 times the nominal (backed off) value. 3635 This removes any risk of synchronization between lots of hosts 3636 performing independent shim operations at the same time. 3638 The randomization is applied after the binary exponential backoff. 3639 Thus the first retransmission would happen based on a uniformly 3640 distributed random number in the range [0.5*4, 1.5*4] seconds, the 3641 second retransmission [0.5*8, 1.5*8] seconds after the first one, 3642 etc. 3644 15. Implications Elsewhere 3646 The general shim6 approach, as well as the specifics of this proposed 3647 solution, has implications elsewhere. The key implications are: 3649 o Applications that perform referrals, or callbacks using IP 3650 addresses as the 'identifiers' can still function in limited ways, 3651 as described in [22]. But in order for such applications to be 3652 able to take advantage of the multiple locators for redundancy, 3653 the applications need to be modified to either use fully qualified 3654 domain names as the 'identifiers', or they need to pass all the 3655 locators as the 'identifiers' i.e., the 'identifier' from the 3656 applications perspective becomes a set of IP addresses instead of 3657 a single IP address. 3659 o Firewalls that today pass limited traffic, e.g., outbound TCP 3660 connections, would presumably block the shim6 protocol. This 3661 means that even when shim6 capable hosts are communicating, the I1 3662 messages would be dropped, hence the hosts would not discover that 3663 their peer is shim6 capable. This is in fact a feature, since if 3664 the hosts managed to establish a ULID-pair context, then the 3665 firewall would probably drop the "different" packets that are sent 3666 after a failure (those using the shim6 payload extension header 3667 with a TCP packet inside it). Thus stateful firewalls that are 3668 modified to pass shim6 messages should also be modified to pass 3669 the payload extension header, so that the shim can use the 3670 alternate locators to recover from failures. This presumably 3671 implies that the firewall needs to track the set of locators in 3672 use by looking at the shim6 control exchanges. Such firewalls 3673 might even want to verify the locators using the HBA/CGA 3674 verification themselves, which they can do without modifying any 3675 of the shim6 packets they pass through. 3677 o Signaling protocols for QoS or other things that involve having 3678 devices in the network path look at IP addresses and port numbers, 3679 or IP addresses and Flow Labels, need to be invoked on the hosts 3680 when the locator pair changes due to a failure. At that point in 3681 time those protocols need to inform the devices that a new pair of 3682 IP addresses will be used for the flow. Note that this is the 3683 case even though this protocol, unlike some earlier proposals, 3684 does not overload the flow label as a context tag; the in-path 3685 devices need to know about the use of the new locators even though 3686 the flow label stays the same. 3688 o MTU implications. The path MTU mechanisms we use are robust 3689 against different packets taking different paths through the 3690 Internet, by computing a minimum over the recently observed path 3691 MTUs. When shim6 fails over from using one locator pair to 3692 another pair, this means that packets might travel over a 3693 different path through the Internet, hence the path MTU might be 3694 quite different. Perhaps such a path change would be a good hint 3695 to the path MTU mechanism to try a larger MTU? 3697 The fact that the shim will add an 8 octet payload extension 3698 header to the ULP packets after a locator switch, can also affect 3699 the usable path MTU for the ULPs. In this case the MTU change is 3700 local to the sending host, thus conveying the change to the ULPs 3701 is an implementation matter. 3703 o The precise interaction between Mobile IPv6 and shim6 is for 3704 further study, but it might make sense to have Mobile IPv6 operate 3705 on locators, meaning that the shim would be layered on top of the 3706 MIPv6 mechanism. 3708 16. Security Considerations 3710 This document satisfies the concerns specified in [19] as follows: 3712 o The HBA technique [7] for verifying the locators to prevent an 3713 attacker from redirecting the packet stream to somewhere else. 3715 o Requiring a Reachability Probe+Reply before a new locator is used 3716 as the destination, in order to prevent 3rd party flooding 3717 attacks. 3719 o The first message does not create any state on the responder. 3720 Essentially a 3-way exchange is required before the responder 3721 creates any state. This means that a state-based DoS attack 3722 (trying to use up all of memory on the responder) at least 3723 requires the attacker to create state, cosnuming his own resources 3724 and also it provides an IPv6 address that the attacker was using. 3726 o The context establishment messages use nonces to prevent replay 3727 attacks, and to prevent off-path attackers from interfering with 3728 the establishment. 3730 o Every control message of the shim6 protocol, past the context 3731 establishment, carry the context tag assigned to the particular 3732 context. This implies that an attacker needs to discover that 3733 context tag before being able to spoof any shim6 control message. 3734 Such discovery probably requires to be along the path in order to 3735 be sniff the context tag value. The result is that through this 3736 technique, the shim6 protocol is protected against off-path 3737 attackers. 3739 Some of the residual threats in this proposal are: 3741 o An attacker which arrives late on the path (after the context has 3742 been established) can use the R1bis message to cause one peer to 3743 recreate the context, and at that point in time the attacker can 3744 observe all of the exchange. But this doesn't seem to open any 3745 new doors for the attacker since such an attacker can observe the 3746 context tags that are being used, and once known it can use those 3747 to send bogus messages. 3749 o An attacker which is present on the path so that it can find out 3750 the context tags, can generate a R1bis message after it has moved 3751 off the path. For this packet to be effective it needs to have a 3752 source locator which belongs to the context, thus there can not be 3753 "too much" ingress filtering between the attackers new location 3754 and the communicating peers. But this doesn't seem to be that 3755 severe, because once the R1bis causes the context to be re- 3756 established, a new pair of context tags will be used, which will 3757 not be known to the attacker. If this is still a concern, we 3758 could require a 2-way handshake "did you really loose the state?" 3759 in response to the error message. 3761 o It might be possible for an attacker to try random 47-bit context 3762 tags and see if they can cause disruption for communication 3763 between two hosts. In particular, in the case of payload packets, 3764 the effects of such attack would be similar of those of an 3765 attacker sending packets with spoofed source address. In the case 3766 of control packets, it is not enough to find the correct context 3767 tag, but additional information is required (e.g. nonces, proper 3768 source addresses) (see previous bullet for the case of R1bis). If 3769 a 47-bit tag, which is the largest that fits in an 8-octet 3770 extension header, isn't sufficient, one could use an even larger 3771 tag in the shim6 control messages, and use the low-order 47 bits 3772 in the payload extension header. 3774 o When the payload extension header is used, an attacker that can 3775 guess the 47-bit random context tag, can inject packets into the 3776 context with any source locator. Thus if there is ingress 3777 filtering between the attacker, this could potentially allow to 3778 bypass the ingress filtering. However, in addition to guessing 3779 the 47-bit context tag, the attacker also needs to find a context 3780 where, after the receiver's replacement of the locators with the 3781 ULIDs, the the ULP checksum is correct. But even this wouldn't be 3782 sufficient with ULPs like TCP, since the TCP port numbers and 3783 sequence numbers must match an existing connection. Thus, even 3784 though the issues for off-path attackers injecting packets are 3785 different than today with ingress filtering, it is still very hard 3786 for an off-path attacker to guess. If IPsec is applied then the 3787 issue goes away completely. 3789 o The validator included in the R1 and R1bis packets are generated 3790 as a hash of several input parameters. However, most of the 3791 inputs are actually determined by the sender, and only the secret 3792 value S is unknown to the sender. However, the resulting 3793 protection is deemed to be enough since it would be easier for the 3794 attacker to just obtain a new validator sending a I1 packet than 3795 performing all the computations required to determine the secret 3796 S. However, it is recommended that the host changes the secret S 3797 periodically. 3799 17. IANA Considerations 3801 IANA is directed to allocate a new IP Protocol Number value for the 3802 SHIM6 Protocol. 3804 IANA is directed to record a CGA message type for the SHIM6 Protocol 3805 in the [CGA] namespace registry with the value 0x4A30 5662 4858 574B 3806 3655 416F 506A 6D48. 3808 IANA is directed to establish a SHIM6 Parameter Registry with two 3809 components: SHIM6 Type registrations and SHIM6 Options registrations. 3811 The initial contents of the SHIM6 Type registry are as follows: 3813 +------------+-----------------------------------------------------+ 3814 | Type Value | Message | 3815 +------------+-----------------------------------------------------+ 3816 | 0 | RESERVED | 3817 | | | 3818 | 1 | I1 (first establishment message from the initiator) | 3819 | | | 3820 | 2 | R1 (first establishment message from the responder) | 3821 | | | 3822 | 3 | I2 (2nd establishment message from the initiator) | 3823 | | | 3824 | 4 | R2 (2nd establishment message from the responder) | 3825 | | | 3826 | 5 | R1bis (Reply to reference to non-existent context) | 3827 | | | 3828 | 6 | I2bis (Reply to a R1bis message) | 3829 | | | 3830 | 7-59 | Can be allocated using Standards Action | 3831 | | | 3832 | 60-63 | For Experimental use | 3833 | | | 3834 | 64 | Update Request | 3835 | | | 3836 | 65 | Update Acknowledgement | 3837 | | | 3838 | 66 | Keepalive | 3839 | | | 3840 | 67 | Probe Message | 3841 | | | 3842 | 68-123 | Can be allocated using Standards Action | 3843 | | | 3844 | 124-127 | For Experimental use | 3845 +------------+-----------------------------------------------------+ 3846 The initial contents of the SHIM6 Options registry are as follows: 3848 +-------------+----------------------------------+ 3849 | Type | Option Name | 3850 +-------------+----------------------------------+ 3851 | 0 | RESERVED | 3852 | | | 3853 | 1 | Responder Validator | 3854 | | | 3855 | 2 | Locator List | 3856 | | | 3857 | 3 | Locator Preferences | 3858 | | | 3859 | 4 | CGA Parameter Data Structure | 3860 | | | 3861 | 5 | CGA Signature | 3862 | | | 3863 | 6 | ULID Pair | 3864 | | | 3865 | 7 | Forked Instance Identifier | 3866 | | | 3867 | 8-9 | Allocated using Standards action | 3868 | | | 3869 | 10 | Probe Option | 3870 | | | 3871 | 11 | Reachability Option | 3872 | | | 3873 | 12 | Payload Reception Report Option | 3874 | | | 3875 | 13-16383 | Allocated using Standards action | 3876 | | | 3877 | 16384-32767 | For Experimental use | 3878 +-------------+----------------------------------+ 3880 18. Acknowledgements 3882 Over the years many people active in the multi6 and shim6 WGs have 3883 contributed ideas a suggestions that are reflected in this 3884 specification. Special thanks to the careful comments from Geoff 3885 Huston, Shinta Sugimoto, Pekka Savola, Dave Meyer, Deguang Le and Jim 3886 Bound on earlier versions of this draft. 3888 Appendix A. Possible Protocol Extensions 3890 During the development of this protocol, several issues have been 3891 brought up as important one to address, but are ones that do not need 3892 to be in the base protocol itself but can instead be done as 3893 extensions to the protocol. The key ones are: 3895 o As stated in the assumptions in Section 3, the in order for the 3896 shim6 protocol to be able to recover from a wide range of 3897 failures, for instance when one of the communicating hosts is 3898 singly-homed, and cope with a site's ISPs that do ingress 3899 filtering based on the source IPv6 address, there is a need for 3900 the host to be able to influence the egress selection from its 3901 site. Further discussion of this issue is captured in [20]. 3903 o Is there need for keeping the list of locators private between the 3904 two communicating endpoints? We can potentially accomplish that 3905 when using CGA but not with HBA, but it comes at the cost of doing 3906 some public key encryption and decryption operations as part of 3907 the context establishment. The suggestion is to leave this for a 3908 future extension to the protocol. 3910 o Defining some form of end-to-end "compression" mechanism that 3911 removes the need for including the Shim6 Payload extension header 3912 when the locator pair is not the ULID pair. 3914 o Supporting the dynamic setting of locator preferences on a site- 3915 wide basis, and use the Locator Preference option in the shim6 3916 protocol to convey these preferences to remote communicating 3917 hosts. This could mirror the DNS SRV record's notion of priority 3918 and weight. 3920 o Potentially recommend that more application protocols use DNS SRV 3921 records to allow a site some influence on load spreading for the 3922 initial contact (before the shim6 context establishment) as well 3923 as for traffic which does not use the shim. 3925 o Specifying APIs for the ULPs to be aware of the locators the shim 3926 is using, and be able to influence the choice of locators 3927 (controlling preferences as well as triggering a locator pair 3928 switch). This includes providing APIs the ULPs can use to fork a 3929 shim context. 3931 o Whether it is feasible to relax the suggestions for when context 3932 state is removed, so that one can end up with an asymmetric 3933 distribution of the context state and still get (most of) the shim 3934 benefits. For example, the busy server would go through the 3935 context setup but would quickly remove the context state after 3936 this (in order to save memory) but the not-so-busy client would 3937 retain the context state. The context recovery mechanism 3938 presented in Section 7.5 would then be recreate the state should 3939 the client send either a shim control message (e.g., probe message 3940 because it sees a problem), or a ULP packet in an payload 3941 extension header (because it had earlier failed over to an 3942 alternative locator pair, but had been silent for a while). This 3943 seems to provide the benefits of the shim as long as the client 3944 can detect the failure. If the client doesn't send anything, and 3945 it is the server that tries to send, then it will not be able to 3946 recover because the shim on the server has no context state, hence 3947 doesn't know any alternate locator pairs. 3949 o Study whether a host explicitly fail communication when a ULID 3950 becomes invalid (based on RFC 2462 lifetimes or DHCPv6), or should 3951 we let the communication continue using the invalidated ULID (it 3952 can certainly work since other locators will be used). 3954 o Study what it would take to make the shim6 control protocol not 3955 rely at all on a stable source locator in the packets. This can 3956 probably be accomplished by having all the shim control messages 3957 include the ULID-pair option. 3959 o If each host might have lots of locators, then the currently 3960 requirement to include essentially all of them in the I2 and R2 3961 messages might be constraining. If this is the case we can look 3962 into using the CGA Parameter Data Structure for the comparison, 3963 instead of the prefix sets, to be able to detect context 3964 confusion. This would place some constraint on a (logical) only 3965 using e.g., one CGA public key, and would require some carefully 3966 crafted rules on how two PDSs are compared for "being the same 3967 host". But if we don't expect more than a handful locators per 3968 host, then we don't need this added complexity. 3970 o ULP specified timers for the reachability detection mechanism 3971 (which can be useful particularly when there are forked contexts). 3973 o Pre-verify some "backup" locator pair, so that the failover time 3974 can be shorter. 3976 o Study how shim6 and Mobile IPv6 might interact. There existing an 3977 initial draft on this topic [21]. 3979 Appendix B. Simplified State Machine 3981 The states are defined in Section 6.2. The intent is that the 3982 stylized description below be consistent with the textual description 3983 in the specification, but should they conflict, the textual 3984 description is normative. 3986 The following table describes the possible actions in state IDLE and 3987 their respective triggers: 3989 +---------------------+---------------------------------------------+ 3990 | Trigger | Action | 3991 +---------------------+---------------------------------------------+ 3992 | Receive I1 | Send R1 and stay in IDLE | 3993 | | | 3994 | Heuristics trigger | Send I1 and move to I1-SENT | 3995 | a new context | | 3996 | establishment | | 3997 | | | 3998 | Receive I2, verify | If successful, send R2 and move to | 3999 | validator and | ESTABLISHED | 4000 | RESP nonce | | 4001 | | If fail, stay in IDLE | 4002 | | | 4003 | Receive I2bis, | If successful, send R2 and move to | 4004 | verify validator | ESTABLISHED | 4005 | and RESP nonce | | 4006 | | If fail, stay in IDLE | 4007 | | | 4008 | R1, R1bis, R2 | N/A (This context lacks the required info | 4009 | | for the dispatcher to deliver them) | 4010 | | | 4011 | Receive payload | Send R1bis and stay in IDLE | 4012 | extension header | | 4013 | or other control | | 4014 | packet | | 4015 +---------------------+---------------------------------------------+ 4016 The following table describes the possible actions in state I1-SENT 4017 and their respective triggers: 4019 +---------------------+---------------------------------------------+ 4020 | Trigger | Action | 4021 +---------------------+---------------------------------------------+ 4022 | Receive R1, verify | If successful, send I2 and move to I2-SENT | 4023 | INIT nonce | | 4024 | | If fail, discard and stay in I1-SENT | 4025 | | | 4026 | Receive I1 | Send R2 and stay in I1-SENT | 4027 | | | 4028 | Receive R2, verify | If successful, move to ESTABLISHED | 4029 | INIT nonce | | 4030 | | If fail, discard and stay in I1-SENT | 4031 | | | 4032 | Receive I2, verify | If successful, send R2 and move to | 4033 | validator and RESP | ESTABLISHED | 4034 | nonce | | 4035 | | If fail, discard and stay in I1-SENT | 4036 | | | 4037 | Receive I2bis, | If successful, send R2 and move to | 4038 | verify validator | ESTABLISHED | 4039 | and RESP nonce | | 4040 | | If fail, discard and stay in I1-SENT | 4041 | | | 4042 | Timeout, increment | If counter =< I1_RETRIES_MAX, send I1 and | 4043 | timeout counter | stay in I1-SENT | 4044 | | | 4045 | | If counter > I1_RETRIES_MAX, go to E-FAILED | 4046 | | | 4047 | Receive ICMP payload| Move to E-FAILED | 4048 | unknown error | | 4049 | | | 4050 | R1bis | N/A (Dispatcher doesn't deliver since | 4051 | | CT(peer) is not set) | 4052 | | | 4053 | Receive Payload or | Discard and stay in I1-SENT | 4054 | extension header | | 4055 | or other control | | 4056 | packet | | 4057 +---------------------+---------------------------------------------+ 4058 The following table describes the possible actions in state I2-SENT 4059 and their respective triggers: 4061 +---------------------+---------------------------------------------+ 4062 | Trigger | Action | 4063 +---------------------+---------------------------------------------+ 4064 | Receive R2, verify | If successful move to ESTABLISHED | 4065 | INIT nonce | | 4066 | | If fail, stay in I2-SENT | 4067 | | | 4068 | Receive I1 | Send R2 and stay in I2-SENT | 4069 | | | 4070 | Receive I2 | Send R2 and stay in I2-SENT | 4071 | verify validator | | 4072 | and RESP nonce | | 4073 | | | 4074 | Receive I2bis | Send R2 and stay in I2-SENT | 4075 | verify validator | | 4076 | and RESP nonce | | 4077 | | | 4078 | Receive R1 | Discard and stay in I2-SENT | 4079 | | | 4080 | Timeout, increment | If counter =< I2_RETRIES_MAX, send I2 and | 4081 | timeout counter | stay in I2-SENT | 4082 | | | 4083 | | If counter > I2_RETRIES_MAX, send I1 and go | 4084 | | to I1-SENT | 4085 | | | 4086 | R1bis | N/A (Dispatcher doesn't deliver since | 4087 | | CT(peer) is not set) | 4088 | | | 4089 | Receive payload or | Accept and send I2 (probably R2 was sent | 4090 | extension header | by peer and lost) | 4091 | other control | | 4092 | packet | | 4093 +---------------------+---------------------------------------------+ 4094 The following table describes the possible actions in state I2BIS- 4095 SENT and their respective triggers: 4097 +---------------------+---------------------------------------------+ 4098 | Trigger | Action | 4099 +---------------------+---------------------------------------------+ 4100 | Receive R2, verify | If successful move to ESTABLISHED | 4101 | INIT nonce | | 4102 | | If fail, stay in I2BIS-SENT | 4103 | | | 4104 | Receive I1 | Send R2 and stay in I2BIS-SENT | 4105 | | | 4106 | Receive I2 | Send R2 and stay in I2BIS-SENT | 4107 | verify validator | | 4108 | and RESP nonce | | 4109 | | | 4110 | Receive I2bis | Send R2 and stay in I2BIS-SENT | 4111 | verify validator | | 4112 | and RESP nonce | | 4113 | | | 4114 | Receive R1 | Discard and stay in I2BIS-SENT | 4115 | | | 4116 | Timeout, increment | If counter =< I2_RETRIES_MAX, send I2bis | 4117 | timeout counter | and stay in I2BIS-SENT | 4118 | | | 4119 | | If counter > I2_RETRIES_MAX, send I1 and | 4120 | | go to I1-SENT | 4121 | | | 4122 | R1bis | N/A (Dispatcher doesn't deliver since | 4123 | | CT(peer) is not set) | 4124 | | | 4125 | Receive payload or | Accept and send I2bis (probably R2 was | 4126 | extension header | sent by peer and lost) | 4127 | other control | | 4128 | packet | | 4129 +---------------------+---------------------------------------------+ 4130 The following table describes the possible actions in state 4131 ESTABLISHED and their respective triggers: 4133 +---------------------+---------------------------------------------+ 4134 | Trigger | Action | 4135 +---------------------+---------------------------------------------+ 4136 | Receive I1, compare | If no match, send R1 and stay in ESTABLISHED| 4137 | CT(peer) with | | 4138 | received CT | If match, send R2 and stay in ESTABLISHED | 4139 | | | 4140 | | | 4141 | Receive I2, verify | If successful, then send R2 and stay in | 4142 | validator and RESP | ESTABLISHED | 4143 | nonce | | 4144 | | Otherwise, discard and stay in ESTABLISHED | 4145 | | | 4146 | Receive I2bis, | If successful, then send R2 and stay in | 4147 | verify validator | ESTABLISHED | 4148 | and RESP nonce | | 4149 | | Otherwise, discard and stay in ESTABLISHED | 4150 | | | 4151 | Receive R2 | Discard and stay in ESTABLISHED | 4152 | | | 4153 | Receive R1 | Discard and stay in ESTABLISHED | 4154 | | | 4155 | Receive R1bis | Send I2bis and move to I2BIS-SENT | 4156 | | | 4157 | | | 4158 | Receive payload or | Process and stay in ESTABLISHED | 4159 | extension header | | 4160 | other control | | 4161 | packet | | 4162 | | | 4163 | Implementation | Discard state and go to IDLE | 4164 | specific heuristic | | 4165 | (E.g., No open ULP | | 4166 | sockets and idle | | 4167 | for some time ) | | 4168 +---------------------+---------------------------------------------+ 4169 The following table describes the possible actions in state E-FAILED 4170 and their respective triggers: 4172 +---------------------+---------------------------------------------+ 4173 | Trigger | Action | 4174 +---------------------+---------------------------------------------+ 4175 | Wait for | Go to IDLE | 4176 | NO_R1_HOLDDOWN_TIME | | 4177 | | | 4178 | Any packet | Process as in IDLE | 4179 +---------------------+---------------------------------------------+ 4181 The following table describes the possible actions in state NO- 4182 SUPPORT and their respective triggers: 4184 +---------------------+---------------------------------------------+ 4185 | Trigger | Action | 4186 +---------------------+---------------------------------------------+ 4187 | Wait for | Go to IDLE | 4188 | ICMP_HOLDDOWN_TIME | | 4189 | | | 4190 | Any packet | Process as in IDLE | 4191 +---------------------+---------------------------------------------+ 4193 Appendix B.1. Simplified State Machine diagram 4195 Timeout/Null +------------+ 4196 I1/R1 +------------------| NO SUPPORT | 4197 Payload or Control/R1bis | +------------+ 4198 +---------+ | ^ 4199 | | | ICMP Error/Null| 4200 | V V | 4201 +-----------------+ Timeout/Null +----------+ | 4202 | |<---------------| E-FAILED | | 4203 +-| IDLE | +----------+ | 4204 I2 or I2bis/R2 | | | ^ | 4205 | +-----------------+ (Tiemout#>MAX)/Null| | 4206 | ^ | | | 4207 | | +------+ | | 4208 I2 or I2bis/R2 | | Heuristic/I1| I1/R2 | | 4209 Payload/Null | | | Control/Null | | 4210 I1/R1 or R2 | +--+ | Payload/Null | | 4211 R1 or R2/Null | |Heuristic/Null | (Tiemout#| | 4216 | ESTABLISHED |<----------------------------| I1-SENT | 4217 | | | | 4218 +-------------------+ +----------------+ 4219 | ^ ^ | ^ ^ 4220 | | |R2/Null +-------------+ | | 4221 | | +----------+ |R1/I2 | | 4222 | | | V | | 4223 | | +------------------+ | | 4224 | | | |-------------+ | 4225 | | | I2-SENT | (Timeout#>Max)/I1 | 4226 | | | | | 4227 | | +------------------+ | 4228 | | | ^ | 4229 | | +--------------+ | 4230 | | I1 or I2bis or I2 or Payload/R2 | 4231 | | (Timeout#Max)/I1 | 4234 | R2/Null| +------------------------------------------+ 4235 | V | 4236 | +-------------------+ 4237 | | |<-+ (Timeout#| I2bis-SENT | | I1 or I2 or I2bis/R2 4239 R1bis/I2bis | |--+ R1 or R1bis/Null 4240 +-------------------+ Payload/R2 4242 Appendix C. Context Tag Reuse 4244 The shim6 protocol doesn't have a mechanism for coordinated state 4245 removal between the peers, because such state removal doesn't seem to 4246 help given that a host can crash and reboot at any time. A result of 4247 this is that the protocol needs to be robust against a context tag 4248 being reused for some other context. This section summarizes the 4249 different cases in which a tag can be reused, and how the recovery 4250 works. 4252 The different cases are exemplified by the following case. Assume 4253 host A and B were communicating using a context with the ULID pair 4254 , and that B had assigned context tag X to this context. We 4255 assume that B uses only the context tag to demultiplex the received 4256 payload extension headers, since this is the more general case. 4257 Further we assume that B removes this context state, while A retains 4258 it. B might then at a later time assign CT(local)=X to some other 4259 context, and we have several cases: 4261 o The context tag is reassigned to a context for the same ULID pair 4262 . We've called this "Context Recovery" in this document. 4264 o The context tag is reassigned to a context for a different ULID 4265 pair between the same to hosts, e.g., . We've called this 4266 "Context Confusion" in this document. 4268 o The context tag is reassigned to a context between B and other 4269 host C, for instance for the ULID pair . That is a form 4270 of three party context confusion. 4272 Appendix C.1. Context Recovery 4274 This case is relatively simple, and is discussed in Section 7.5. The 4275 observation is that since the ULID pair is the same, when either A or 4276 B tries to establish the new context, A can keep the old context 4277 while B re-creates the context with the same context tag CT(B) = X. 4279 Appendix C.2. Context Confusion 4281 This cases is a bit more complex, and is discussed in Section 7.6. 4282 When the new context is created, whether A or B initiates it, host A 4283 can detect when it receives B's locator set (in the I2, or R2 4284 message), that it ends up with two contexts to the same peer host 4285 (overlapping Ls(peer) locator sets) that have the same context tag 4286 CT(peer) = X. At this point in time host A can clear up any 4287 possibility of causing confusion by not using the old context to send 4288 any more packets. It either just discards the old context (it might 4289 not be used by any ULP traffic, since B had discarded it), or it 4290 recreates a different context for the old ULID pair (), for 4291 which B will assign a unique CT(B) as part of the normal context 4292 establishment mechanism. 4294 Appendix C.3. Three Party Context Confusion 4296 The third case does not have a place where the old state on A can be 4297 verified, since the new context is established between B and C. Thus 4298 when B receives payload extension headers with X as the context tag, 4299 it will find the context for , hence rewrite the packets to 4300 have C3 in the source address field and B2 in the destination address 4301 field before passing them up to the ULP. This rewriting is correct 4302 when the packets are in fact sent by host C, but if host A ever 4303 happens to send a packet using the old context, then the ULP on A 4304 sends a packet with ULIDs and the packet arrives at the ULP 4305 on B with ULIDs . 4307 This is clearly an error, and the packet will most likely be rejected 4308 by the ULP on B due to a bad pseudo-header checksum. Even if the 4309 checksum is ok (probability 2^-16), the ULP isn't likely to have a 4310 connection for those ULIDs and port numbers. And if the ULP is 4311 connection-less, processing the packet is most likely harmless; such 4312 a ULP must be able to copy with random packets being sent by random 4313 peers in any case. 4315 This broken state, where packets sent from A to B using the old 4316 context on host A might persist for some time, but it will not remain 4317 for very long. The unreachability detection on host A will kick in, 4318 because it does not see any return traffic (payload or Keepalive 4319 messages) for the context. This will result in host A sending Probe 4320 messages to host B to find a working locator pair. The effect of 4321 this is that host B will notice that it does not have a context for 4322 the ULID pair and CT(B) = X, which will make host B send an 4323 R1bis packet to re-establish that context. The re-established 4324 context, just like in the previous section, will get a unique CT(B) 4325 assigned by host B, thus there will no longer be any confusion. 4327 In summary, there are cases where a context tag might be reused while 4328 some peer retains the state, but the protocol can recover from it. 4329 The probability of these events is low given the 47 bit context tag 4330 size. However, it is important that these recovery mechanisms be 4331 tested. Thus during development and testing it is recommended that 4332 implementations not use the full 47 bit space, but instead keep e.g. 4333 the top 40 bits as zero, only leaving the host with 128 unique 4334 context tags. This will help test the recovery mechanisms. 4336 Appendix D. Design Alternatives 4338 This document has picked a certain set of design choices in order to 4339 try to work out a bunch of the details, and stimulate discussion. 4340 But as has been discussed on the mailing list, there are other 4341 choices that make sense. This appendix tries to enumerate some 4342 alternatives. 4344 Appendix D.1. Context granularity 4346 Over the years various suggestions have been made whether the shim 4347 should, even if it operates at the IP layer, be aware of ULP 4348 connections and sessions, and as a result be able to make separate 4349 shim contexts for separate ULP connections and sessions. A few 4350 different options have been discussed: 4352 o Each ULP connection maps to its own shim context. 4354 o The shim is unaware of the ULP notion of connections and just 4355 operates on a host-to-host (IP address) granularity. 4357 o Hybrids where the shim is aware of some ULPs (such as TCP) and 4358 handles other ULPs on a host-to-host basis. 4360 Having shim state for every ULP connection potentially means higher 4361 overhead since the state setup overhead might become significant; 4362 there is utility in being able to amortize this over multiple 4363 connections. 4365 But being completely unaware of the ULP connections might hamper ULPs 4366 that want different communication to use different locator pairs, for 4367 instance for quality or cost reasons. 4369 The protocol has a shim which operates with host-level granularity 4370 (strictly speaking, with ULID-pair granularity, to be able to 4371 amortize the context establishment over multiple ULP connections. 4372 This is combined with the ability for shim-aware ULPs to request 4373 context forking so that different ULP traffic can use different 4374 locator pairs. 4376 Appendix D.2. Demultiplexing of data packets in shim6 communications 4378 Once a ULID-pair context is established between two hosts, packets 4379 may carry locators that differ from the ULIDs presented to the ULPs 4380 using the established context. One of main functions of the SHIM6 4381 layer is to perform the mapping between the locators used to forward 4382 packets through the network and the ULIDs presented to the ULP. In 4383 order to perform that translation for incoming packets, the SHIM6 4384 layer needs to first identify which of the incoming packets need to 4385 be translated and then perform the mapping between locators and ULIDs 4386 using the associated context. Such operation is called 4387 demultiplexing. It should be noted that because any address can be 4388 used both as a locator and as a ULID, additional information other 4389 than the addresses carried in packets, need to be taken into account 4390 for this operation. 4392 For example, if a host has address A1 and A2 and starts communicating 4393 with a peer with addresses B1 and B2, then some communication 4394 (connections) might use the pair as ULID and others might 4395 use e.g., . Initially there are no failures so these address 4396 pairs are used as locators i.e. in the IP address fields in the 4397 packets on the wire. But when there is a failure the shim6 layer on 4398 A might decide to send packets that used as ULIDs using as the locators. In this case B needs to be able to rewrite the 4400 IP address field for some packets and not others, but the packets all 4401 have the same locator pair. 4403 In order to accomplish the demultiplexing operation successfully, 4404 data packets carry a context tag that allows the receiver of the 4405 packet to determine the shim context to be used to perform the 4406 operation. 4408 Two mechanisms for carrying the context tag information have been 4409 considered in depth during the shim protocol design. Those carrying 4410 the context tag in the flow label field of the IPv6 header and the 4411 usage of a new extension header to carry the context tag. In this 4412 appendix we will describe the pros and cons of each approach and 4413 justify the selected option. 4415 Appendix D.2.1. Flow-label 4417 A possible approach is to carry the context tag in the Flow Label 4418 field of the IPv6 header. This means that when a shim6 context is 4419 established, a Flow Label value is associated with this context (and 4420 perhaps a separate flow label for each direction). 4422 The simplest approach that does this is to have the triple identify the context at 4424 the receiver. 4426 The problem with this approach is that because the locator sets are 4427 dynamic, it is not possible at any given moment to be sure that two 4428 contexts for which the same context tag is allocated will have 4429 disjoint locator sets during the lifetime of the contexts. 4431 Suppose that Node A has addresses IPA1, IPA2, IPA3 and IPA4 and that 4432 Host B has addresses IPB1 and IPB2. 4434 Suppose that two different contexts are established between HostA and 4435 HostB. 4437 Context #1 is using IPA1 and IPB1 as ULIDs. The locator set 4438 associated to IPA1 is IPA1 and IPA2 while the locator set associated 4439 to IPB1 is just IPB1. 4441 Context #2 uses IPA3 and IPB2 as ULIDs. The locator set associated 4442 to IPA3 is IPA3 and IPA4 and the locator set associated to IPB2 is 4443 just IPB2. 4445 Because the locator sets of the Context #1 and Context #2 are 4446 disjoint, hosts could think that the same context tag value can be 4447 assigned to both of them. The problem arrives when later on IPA3 is 4448 added as a valid locator for IPA1 and IPB2 is added as a valid 4449 locator for IPB1 in Context #1. In this case, the triple would not identify a 4451 unique context anymore and correct demultiplexing is no longer 4452 possible. 4454 A possible approach to overcome this limitation is simply not to 4455 repeat the Flow Label values for any communication established in a 4456 host. This basically means that each time a new communication that 4457 is using different ULIDs is established, a new Flow Label value is 4458 assigned to it. By this mean, each communication that is using 4459 different ULIDs can be differentiated because it has a different Flow 4460 Label value. 4462 The problem with such approach is that it requires that the receiver 4463 of the communication allocates the Flow Label value used for incoming 4464 packets, in order to assign them uniquely. For this, a shim 4465 negotiation of the Flow Label value to use in the communication is 4466 needed before exchanging data packets. This poses problems with non- 4467 shim capable hosts, since they would not be able to negotiate an 4468 acceptable value for the Flow Label. This limitation can be lifted 4469 by marking the packets that belong to shim sessions from those that 4470 do not. These marking would require at least a bit in the IPv6 4471 header that is not currently available, so more creative options 4472 would be required, for instance using new Next Header values to 4473 indicate that the packet belongs to a shim6 enabled communication and 4474 that the Flow Label carries context information as proposed in the 4475 now expired NOID draft. . However, even if this is done, this 4476 approach is incompatible with the deferred establishment capability 4477 of the shim protocol, which is a preferred function, since it 4478 suppresses the delay due to the shim context establishment prior to 4479 initiation of the communication and it also allows nodes to define at 4480 which stage of the communication they decide, based on their own 4481 policies, that a given communication requires to be protected by the 4482 shim. 4484 In order to cope with the identified limitations, an alternative 4485 approach that does not constraints the flow label values used by 4486 communications that are using ULIDs equal to the locators (i.e. no 4487 shim translation) is to only require that different flow label values 4488 are assigned to different shim contexts. In such approach 4489 communications start with unmodified flow label usage (could be zero, 4490 or as suggested in [16]). The packets sent after a failure when a 4491 different locator pair is used would use a completely different flow 4492 label, and this flow label could be allocated by the receiver as part 4493 of the shim context establishment. Since it is allocated during the 4494 context establishment, the receiver of the "failed over" packets can 4495 pick a flow label of its choosing (that is unique in the sense that 4496 no other context is using it as a context tag), without any 4497 performance impact, and respecting that for each locator pair, the 4498 flow label value used for a given locator pair doesn't change due to 4499 the operation of the multihoming shim. 4501 In this approach, the constraint is that Flow Label values being used 4502 as context identifiers cannot be used by other communications that 4503 use non-disjoint locator sets. This means that once that a given 4504 Flow Label value has been assigned to a shim context that has a 4505 certain locator sets associated, the same value cannot be used for 4506 other communications that use an address pair that is contained in 4507 the locator sets of the context. This is a constraint in the 4508 potential Flow Label allocation strategies. 4510 A possible workaround to this constraint is to mark shim packets that 4511 require translation, in order to differentiate them from regular IPv6 4512 packets, using the artificial Next Header values described above. In 4513 this case, the Flow Label values constrained are only those of the 4514 packets that are being translated by the shim. This last approach 4515 would be the preferred approach if the context tag is to be carried 4516 in the Flow Label field. This is not only because it imposes the 4517 minimum constraints to the Flow Label allocation strategies, limiting 4518 the restrictions only to those packets that need to be translated by 4519 the shim, but also because Context Loss detection mechanisms greatly 4520 benefit from the fact that shim data packets are identified as such, 4521 allowing the receiving end to identify if a shim context associated 4522 to a received packet is suppose to exist, as it will be discussed in 4523 the Context Loss detection appendix below. 4525 Appendix D.2.2. Extension Header 4527 Another approach, which is the one selected for this protocol, is to 4528 carry the context tag in a new Extension Header. These context tags 4529 are allocated by the receiving end during the shim6 protocol initial 4530 negotiation, implying that each context will have two context tags, 4531 one for each direction. Data packets will be demultiplexed using the 4532 context tag carried in the Extension Header. This seems a clean 4533 approach since it does not overload existing fields. However, it 4534 introduces additional overhead in the packet due to the additional 4535 header. The additional overhead introduced is 8 octets. However, it 4536 should be noted that the context tag is only required when a locator 4537 other than the one used as ULID is contained in the packet. Packets 4538 where both the source and destination address fields contain the 4539 ULIDs do not require a context tag, since no rewriting is necessary 4540 at the receiver. This approach would reduce the overhead, because 4541 the additional header is only required after a failure. On the other 4542 hand, this approach would cause changes in the available MTU for some 4543 packets, since packets that include the Extension Header will have an 4544 MTU 8 octets shorter. However, path changes through the network can 4545 result in different MTU in any case, thus having a locator change, 4546 which implies a path change, affect the MTU doesn't introduce any new 4547 issues. 4549 Appendix D.3. Context Loss Detection 4551 In this appendix we will present different approaches considered to 4552 detect context loss and potential context recovery strategies. The 4553 scenario being considered is the following: Node A and Node B are 4554 communicating using IPA1 and IPB1. Sometime later, a shim context is 4555 established between them, with IPA1 and IPB1 as ULIDs and 4556 IPA1,...,IPAn and IPB1,...,IPBm as locator set respectively. 4558 It may happen, that later on, one of the hosts, e.g. Host A looses 4559 the shim context. The reason for this can be that Host A has a more 4560 aggressive garbage collection policy than HostB or that an error 4561 occurred in the shim layer at host A resulting in the loss of the 4562 context state. 4564 The mechanisms considered in this appendix are aimed to deal with 4565 this problem. There are essentially two tasks that need to be 4566 performed in order to cope with this problem: first, the context loss 4567 must be detected and second the context needs to be recovered/ 4568 reestablished. 4570 Mechanisms for detecting context. loss 4572 These mechanisms basically consist in that each end of the context 4573 periodically sends a packet containing context-specific information 4574 to the other end. Upon reception of such packets, the receiver 4575 verifies that the required context exists. In case that the context 4576 does not exist, it sends a packet notifying the problem to the 4577 sender. 4579 An obvious alternative for this would be to create a specific context 4580 keepalive exchange, which consists in periodically sending packets 4581 with this purpose. This option was considered and discarded because 4582 it seemed an overkill to define a new packet exchange to deal with 4583 this issue. 4585 An alternative is to piggyback the context loss detection function in 4586 other existent packet exchanges. In particular, both shim control 4587 and data packets can be used for this. 4589 Shim control packets can be trivially used for this, because they 4590 carry context specific information, so that when a node receives one 4591 of such packets, it will verify if the context exists. However, shim 4592 control frequency may not be adequate for context loss detection 4593 since control packet exchanges can be very limited for a session in 4594 certain scenarios. 4596 Data packets, on the other hand, are expected to be exchanged with a 4597 higher frequency but they do not necessarily carry context specific 4598 information. In particular, packets flowing before a locator change 4599 (i.e. packet carrying the ULIDs in the address fields) do not need 4600 context information since they do not need any shim processing. 4601 Packets that carry locators that differ from the ULIDs carry context 4602 information. 4604 However, we need to make a distinction here between the different 4605 approaches considered to carry the context tag, in particular between 4606 those approaches where packets are explicitly marked as shim packets 4607 and those approaches where packets are not marked as such. For 4608 instance, in the case where the context tag is carried in the Flow 4609 Label and packets are not marked as shim packets (i.e. no new Next 4610 Header values are defined for shim), a receiver that has lost the 4611 associated context is not able to detect that the packet is 4612 associated with a missing context. The result is that the packet 4613 will be passed unchanged to the upper layer protocol, which in turn 4614 will probably silently discard it due to a checksum error. The 4615 resulting behavior is that the context loss is undetected. This is 4616 one additional reason to discard an approach that carries the context 4617 tag in the Flow Label field and does not explicitly mark the shim 4618 packets as such. On the other hand, approaches that mark shim data 4619 packets (like the Extension Header or the Flow Label with new Next 4620 Header values approaches) allow the receiver to detect if the context 4621 associated to the received packet is missing. In this case, data 4622 packets also perform the function of a context loss detection 4623 exchange. However, it must be noted that only those packets that 4624 carry a locator that differs form the ULID are marked. This 4625 basically means that context loss will be detected after an outage 4626 has occurred i.e. alternative locators are being used. 4628 Summarizing, the proposed context loss detection mechanisms uses shim 4629 control packets and payload extension headers to detect context loss. 4630 Shim control packets detect context loss during the whole lifetime of 4631 the context, but the expected frequency in some cases is very low. 4632 On the other hand, payload extension headers have a higher expected 4633 frequency in general, but they only detect context loss after an 4634 outage. This behavior implies that it will be common that context 4635 loss is detected after a failure i.e. once that it is actually 4636 needed. Because of that, a mechanism for recovering from context 4637 loss is required if this approach is used. 4639 Overall, the mechanism for detecting lost context would work as 4640 follows: the end that still has the context available sends a message 4641 referring to the context. Upon the reception of such message, the 4642 end that has lost the context identifies the situation and notifies 4643 the context loss event to the other end by sending a packet 4644 containing the lost context information extracted from the received 4645 packet. 4647 One option is to simply send an error message containing the received 4648 packets (or at least as much of the received packet that the MTU 4649 allows to fit in). One of the goals of this notification is to allow 4650 the other end that still retains context state, to reestablish the 4651 lost context. The mechanism to reestablish the loss context consists 4652 in performing the 4-way initial handshake. This is a time consuming 4653 exchange and at this point time may be critical since we are 4654 reestablishing a context that is currently needed (because context 4655 loss detection may occur after a failure). So, another option, which 4656 is the one used in this protocol, is to replace the error message by 4657 a modified R1 message, so that the time required to perform the 4658 context establishment exchange can be reduced. Upon the reception of 4659 this modified R1 message, the end that still has the context state 4660 can finish the context establishment exchange and restore the lost 4661 context. 4663 Appendix D.4. Securing locator sets 4665 The adoption of a protocol like SHIM that allows the binding of a 4666 given ULID with a set of locators opens the doors for different types 4667 of redirection attacks as described in [19]. The goal in terms of 4668 security for the design of the shim protocol is not to introduce any 4669 new vulnerability in the Internet architecture. It is a non-goal to 4670 provide additional protection than the currently available in the 4671 single-homed IPv6 Internet. 4673 Multiple security mechanisms were considered to protect the shim 4674 protocol. In this appendix we will present some of them. 4676 The simplest option to protect the shim protocol was to use cookies 4677 i.e. a randomly generated bit string that is negotiated during the 4678 context establishment phase and then it is included in following 4679 signaling messages. By this mean, it would be possible to verify 4680 that the party that was involved in the initial handshake is the same 4681 party that is introducing new locators. Moreover, before using a new 4682 locator, an exchange is performed through the new locator, verifying 4683 that the party located at the new locator knows the cookie i.e. that 4684 it is the same party that performed the initial handshake. 4686 While this security mechanisms does indeed provide a fair amount of 4687 protection, it does leave the door open for the so-called time 4688 shifted attacks. In these attacks, an attacker that once was on the 4689 path, it discovers the cookie by sniffing any signaling message. 4690 After that, the attacker can leave the path and still perform a 4691 redirection attack, since as he is in possession of the cookie, he 4692 can introduce a new locator in the locator set and he can also 4693 successfully perform the reachability exchange if he is able to 4694 receive packets at the new locator. The difference with the current 4695 single-homed IPv6 situation is that in the current situation the 4696 attacker needs to be on-path during the whole lifetime of the attack, 4697 while in this new situation where only cookie protection if provided, 4698 an attacker that once was on the path can perform attacks after he 4699 has left the on-path location. 4701 Moreover, because the cookie is included in signaling messages, the 4702 attacker can discover the cookie by sniffing any of them, making the 4703 protocol vulnerable during the whole lifetime of the shim context. A 4704 possible approach to increase the security was to use a shared secret 4705 i.e. a bit string that is negotiated during the initial handshake but 4706 that is used as a key to protect following messages. With this 4707 technique, the attacker must be present on the path sniffing packets 4708 during the initial handshake, since it is the only moment where the 4709 shared secret is exchanged. While this improves the security, it is 4710 still vulnerable to time shifted attacks, even though it imposes that 4711 the attacker must be on path at a very specific moment (the 4712 establishment phase) to actually be able to launch the attack. While 4713 this seems to substantially improve the situation, it should be noted 4714 that, depending on protocol details, an attacker may be able to force 4715 the recreation of the initial handshake (for instance by blocking 4716 messages and making the parties think that the context has been 4717 lost), so the resulting situation may not differ that much from the 4718 cookie based approach. 4720 Another option that was discussed during the design of the protocol 4721 was the possibility of using IPsec for protecting the shim protocol. 4722 Now, the problem under consideration in this scenario is how to 4723 securely bind an address that is being used as ULID with a locator 4724 set that can be used to exchange packets. The mechanism provided by 4725 IPsec to securely bind the address used with the cryptographic keys 4726 is the usage of digital certificates. This implies that an IPsec 4727 based solution would require that the generation of digital 4728 certificates that bind the key and the ULID by a common third trusted 4729 party for both parties involved in the communication. Considering 4730 that the scope of application of the shim protocol is global, this 4731 would imply a global public key infrastructure. The major issues 4732 with this approach are the deployment difficulties associated with a 4733 global PKI. 4735 Finally two different technologies were selected to protect the shim 4736 protocol: HBA [7] and CGA [6]. These two approaches provide a 4737 similar level of protection but they provide different functionality 4738 with a different computational cost. 4740 The HBA mechanism relies on the capability of generating all the 4741 addresses of a multihomed host as an unalterable set of intrinsically 4742 bound IPv6 addresses, known as an HBA set. In this approach, 4743 addresses incorporate a cryptographic one-way hash of the prefix-set 4744 available into the interface identifier part. The result is that the 4745 binding between all the available addresses is encoded within the 4746 addresses themselves, providing hijacking protection. Any peer using 4747 the shim protocol node can efficiently verify that the alternative 4748 addresses proposed for continuing the communication are bound to the 4749 initial address through a simple hash calculation. A limitation of 4750 the HBA technique is that once generated the address set is fixed and 4751 cannot be changed without also changing all the addresses of the HBA 4752 set. In other words, the HBA technique does not support dynamic 4753 addition of address to a previously generated HBA set. An advantage 4754 of this approach is that it requires only hash operations to verify a 4755 locator set, imposing very low computational cost to the protocol. 4757 In a CGA based approach the address used as ULID is a CGA that 4758 contains a hash of a public key in its interface identifier. The 4759 result is a secure binding between the ULID and the associated key 4760 pair. This allows each peer to use the corresponding private key to 4761 sign the shim messages that convey locator set information. The 4762 trust chain in this case is the following: the ULID used for the 4763 communication is securely bound to the key pair because it contains 4764 the hash of the public key, and the locator set is bound to the 4765 public key through the signature. The CGA approach then supports 4766 dynamic addition of new locators in the locator set, since in order 4767 to do that, the node only needs to sign the new locator with the 4768 private key associated with the CGA used as ULID. A limitation of 4769 this approach is that it imposes systematic usage of public key 4770 cryptography with its associate computational cost. 4772 Any of these two mechanisms HBA and CGA provide time-shifted attack 4773 protection, since the ULID is securely bound to a locator set that 4774 can only be defined by the owner of the ULID. 4776 So, the design decision adopted was that both mechanisms HBA and CGA 4777 are supported, so that when only stable address sets are required, 4778 the nodes can benefit from the low computational cost offered by HBA 4779 while when dynamic locator sets are required, this can be achieved 4780 through CGAs with an additional cost. Moreover, because HBAs are 4781 defined as a CGA extension, the addresses available in a node can 4782 simultaneously be CGAs and HBAs, allowing the usage of the HBA and 4783 CGA functionality when needed without requiring a change in the 4784 addresses used. 4786 Appendix D.5. ULID-pair context establishment exchange 4788 Two options were considered for the ULID-pair context establishment 4789 exchange: a 2-way handshake and a 4-way handshake. 4791 A key goal for the design of this exchange was that protection 4792 against DoS attacks. The attack under consideration was basically a 4793 situation where an attacker launches a great amount of ULID-pair 4794 establishment request packets, exhausting victim's resources, similar 4795 to TCP SYN flooding attacks. 4797 A 4 way-handshake exchange protects against these attacks because the 4798 receiver does not creates any state associate to a given context 4799 until the reception of the second packet which contains a prior 4800 contact proof in the form of a token. At this point the receiver can 4801 verify that at least the address used by the initiator is at some 4802 extent valid, since the initiator is able to receive packets at this 4803 address. In the worse case, the responder can track down the 4804 attacker using this address. The drawback of this approach is that 4805 it imposes a 4 packet exchange for any context establishment. This 4806 would be a great deal if the shim context needed to be established up 4807 front, before the communication can proceed. However, thanks to 4808 deferred context establishment capability of the shim protocol, this 4809 limitation has a reduced impact in the performance of the protocol. 4810 (It may however have a greater impact in the situation of context 4811 recover as discussed earlier, but in this case, it is possible to 4812 perform optimizations to reduce the number of packets as described 4813 above) 4815 The other option considered was a 2-way handshake with the 4816 possibility to fall back to a 4-way handshake in case of attack. In 4817 this approach, the ULID-pair establishment exchange normally consists 4818 in a 2-packet exchange and it does not verify that the initiator has 4819 performed a prior contact before creating context state. In case 4820 that a DoS attack is detected, the responder falls back to a 4-way 4821 handshake similar to the one described previously in order to prevent 4822 the detected attack to proceed. The main difficulty with this attack 4823 is how to detect that a responder is currently under attack. It 4824 should be noted, that because this is 2-way exchange, it is not 4825 possible to use the number of half open sessions (as in TCP) to 4826 detect an ongoing attack and different heuristics need to be 4827 considered. 4829 The design decision taken was that considering the current impact of 4830 DoS attacks and the low impact of the 4-way exchange in the shim 4831 protocol thanks to the deferred context establishment capability, a 4832 4-way exchange would be adopted for the base protocol. 4834 Appendix D.6. Updating locator sets 4836 There are two possible approaches to the addition and removal of 4837 locators: atomic and differential approaches. The atomic approach 4838 essentially send the complete locators set each time that a variation 4839 in the locator set occurs. The differential approach send the 4840 differences between the existing locator set and the new one. The 4841 atomic approach imposes additional overhead, since all the locator 4842 set has to be exchanged each time while the differential approach 4843 requires re-synchronization of both ends through changes i.e. that 4844 both ends have the same idea about what the current locator set is. 4846 Because of the difficulties imposed by the synchronization 4847 requirement, the atomic approach was selected. 4849 Appendix D.7. State Cleanup 4851 There are essentially two approaches for discarding an existing state 4852 about locators, keys and identifiers of a correspondent node: a 4853 coordinated approach and an unilateral approach. 4855 In the unilateral approach, each node discards the information about 4856 the other node without coordination with the other node based on some 4857 local timers and heuristics. No packet exchange is required for 4858 this. In this case, it would be possible that one of the nodes has 4859 discarded the state while the other node still hasn't. In this case, 4860 a No-Context error message may be required to inform about the 4861 situation and possibly a recovery mechanism is also needed. 4863 A coordinated approach would use an explicit CLOSE mechanism, akin to 4864 the one specified in HIP [25]. If an explicit CLOSE handshake and 4865 associated timer is used, then there would no longer be a need for 4866 the No Context Error message due to a peer having garbage collected 4867 its end of the context. However, there is still potentially a need 4868 to have a No Context Error message in the case of a complete state 4869 loss of the peer (also known as a crash followed by a reboot). Only 4870 if we assume that the reboot takes at least the CLOSE timer, or that 4871 it is ok to not provide complete service until CLOSE timer minutes 4872 after the crash, can we completely do away with the No Context Error 4873 message. 4875 In addition, other aspect that is relevant for this design choice is 4876 the context confusion issue. In particular, using an unilateral 4877 approach to discard context state clearly opens the possibility of 4878 context confusion, where one of the ends unilaterally discards the 4879 context state, while the peer does not. In this case, the end that 4880 has discarded the state can re-use the context tag value used for the 4881 discarded state for a another context, creating a potential context 4882 confusion situation. In order to illustrate the cases where problems 4883 would arise consider the following scenario: 4885 o Hosts A and B establish context 1 using CTA and CTB as context 4886 tags. 4888 o Later on, A discards context 1 and the context tag value CTA 4889 becomes available for reuse. 4891 o However, B still keeps context 1. 4893 This would become a context confusion situation in the following two 4894 cases: 4896 o A new context 2 is established between A and B with a different 4897 ULID pair (or Forked Instance Identifier), and A uses CTA as 4898 context tag, If the locator sets used for both contexts are not 4899 disjoint, we are in a context confusion situation. 4901 o A new context is established between A and C and A uses CTA as 4902 context tag value for this new context. Later on, B sends Payload 4903 extension header and/or control messages containing CTA, which 4904 could be interpreted by A as belonging to context 2 (if no proper 4905 care is taken). Again we are in a context confusion situation. 4907 One could think that using a coordinated approach would eliminate 4908 these context confusion situations, making the protocol much simpler. 4909 However, this is not the case, because even in the case of a 4910 coordinated approach using a CLOSE/CLOSE ACK exchange, there is still 4911 the possibility of a host rebooting without having the time to 4912 perform the CLOSE exchange. So, it is true that the coordinated 4913 approach eliminates the possibility of a context confusion situation 4914 because premature garbage collection, but it does not prevents the 4915 same situations due to a crash and reboot of one of the involved 4916 hosts. The result is that even if we went for a coordinated 4917 approach, we would still need to deal with context confusion and 4918 provide the means to detect and recover from this situations. 4920 Appendix E. Change Log 4922 [RFC Editor: please remove this section] 4924 The following changes have been made since draft-ietf-shim6-proto-05: 4926 o Removed the possibility to keep on uding the ULID after a 4927 renumbering event 4929 o Editorial corrections resulting from Dave Meyer's and Jim Bound's 4930 reviews. 4932 The following changes have been made since draft-ietf-shim6-proto-04: 4934 o Defined I1_RETRIES_MAX as 4. 4936 o Added text in section 7.9 clarifying the no per context state is 4937 stored at the receiver in order to reply an I1 message. 4939 o Added text in section 5 and in section 5.14 in particular, on 4940 defining additional options (including critical and non critical 4941 options). 4943 o Added text in the security considerations about threats related to 4944 secret S for generating the validators and recommendation to 4945 change S periodically. 4947 o Added text in the security considerations about the effects of 4948 attacks based on guessing the context tag being similar to 4949 spoofing source addresses in the case of payload packets. 4951 o Added clarification on what a recent nonce is in I2 and I2bis. 4953 o Removed (empty) open issues section. 4955 o Editorial corrections. 4957 The following changes have been made since draft-ietf-shim6-proto-03: 4959 o Editorial clarifications based on comments from Geoff, Shinta, 4960 Jari. 4962 o Added "no IPv6 NATs as an explicit assumption. 4964 o Moving some things out of the Introduction and Overview sections 4965 to remove all SHOULDs and MUSTs from there. 4967 o Added requirement that any Locator Preference options which use an 4968 element length greater than 3 octets have the already defined 4969 first 3 octets of flags, priority and weight. 4971 o Fixed security hole where a single message (I1) could cause 4972 CT(peer) to be updated. Now a three-way handshake is required 4973 before CT(peer) is updated for an existing context. 4975 The following changes have been made since draft-ietf-shim6-proto-02: 4977 o Replaced the Context Error message with the R1bis message. 4979 o Removed the Packet In Error option, since it was only used in the 4980 Context Error message. 4982 o Introduced a I2bis message which is sent in response to an I1bis 4983 message, since the responders processing is quite in this case 4984 than in the regular R1 case. 4986 o Moved the packet formats for the Keepalive and Probe message types 4987 and Event option to [8]. Only the message type values and option 4988 type value are specified for those in this document. 4990 o Removed the unused message types. 4992 o Added a state machine description as an appendix. 4994 o Filled in all the TBDs - except the IANA assignment of the 4995 protocol number. 4997 o Specified how context recovery and forked contexts work together. 4998 This required the introduction of a Forked Instance option to be 4999 able to tell which of possibly forked instances is being 5000 recovered. 5002 o Renamed the "host-pair context" to be "ULID-pair context". 5004 o Picked some initial retransmit timers for I1 and I2; 4 seconds. 5006 o Added timer values as protocol constants. The retransmit timers 5007 use binary exponential backoff and randomization (between .5 and 5008 1.5 of the nominal value). 5010 o Require that the R1/R1bis verifiers be usable for some minimum 5011 time so that the initiator knows for how long time it can safely 5012 retransmit I2 before it needs to go back to sending I1 again. 5013 Picked 30 seconds. 5015 o Split the message type codes into 0-63, which will not generate 5016 R1bis messages, and 64-127 which will generate R1bis messages. 5017 This allows extensibility of the protocol with new message types 5018 while being able to control when R1bis is generated. 5020 o Expanded the context tag from 32 to 47 bits. 5022 o Specified that enough locators need to be included in I2 and R2 5023 messages. Specified that the HBA/CGA verification must be 5024 performed when the locator set is received. 5026 o Specified that ICMP parameter problem errors are sent in certain 5027 error cases, for instance when the verification method is unknown 5028 to the receiver, or there is an unknown message type or option 5029 type. 5031 o Renamed "payload message" to be "payload extension header". 5033 o Many editorial clarifications suggested by Geoff Huston. 5035 o Modified the dispatching of payload extension header to only 5036 compare CT(local) i.e., not compare the source and destination 5037 IPv6 address fields. 5039 The following changes have been made since draft-ietf-shim6-proto-00: 5041 o Removed the use of the flow label and the overloading of the IP 5042 protocol numbers. Instead, when the locator pair is not the ULID 5043 pair, the ULP payloads will be carried with an 8 octet extension 5044 header. The belief is that it is possible to remove these extra 5045 bytes by defining future shim6 extensions that exchange more 5046 information between the hosts, without having to overload the flow 5047 label or the IP protocol numbers. 5049 o Grew the context tag from 20 bits to 32 bits, with the possibility 5050 to grow it to 47 bits. This implies changes to the message 5051 formats. 5053 o Almost by accident, the new shim6 message format is very close to 5054 the HIP message format. 5056 o Adopted the HIP format for the options, since this makes it easier 5057 to describe variable length options. The original, ND-style, 5058 option format requires internal padding in the options to make 5059 them 8 octet length in total, while the HIP format handles that 5060 using the option length field. 5062 o Removed some of the control messages, and renamed the other ones. 5064 o Added a "generation" number to the Locator List option, so that 5065 the peers can ensure that the preferences refer to the right 5066 "version" of the Locator List. 5068 o In order for FBD and exploration to work when there the use of the 5069 context is forked, that is different ULP messages are sent over 5070 different locator pairs, things are a lot easier if there is only 5071 one current locator pair used for each context. Thus the forking 5072 of the context is now causing a new context to be established for 5073 the same ULID; the new context having a new context tag. The 5074 original context is referred to as the "default" context for the 5075 ULID pair. 5077 o Added more background material and textual descriptions. 5079 19. References 5081 19.1. Normative References 5083 [1] Bradner, S., "Key words for use in RFCs to Indicate Requirement 5084 Levels", BCP 14, RFC 2119, March 1997. 5086 [2] Deering, S. and R. Hinden, "Internet Protocol, Version 6 (IPv6) 5087 Specification", RFC 2460, December 1998. 5089 [3] Narten, T., Nordmark, E., and W. Simpson, "Neighbor Discovery 5090 for IP Version 6 (IPv6)", RFC 2461, December 1998. 5092 [4] Thomson, S. and T. Narten, "IPv6 Stateless Address 5093 Autoconfiguration", RFC 2462, December 1998. 5095 [5] Conta, A. and S. Deering, "Internet Control Message Protocol 5096 (ICMPv6) for the Internet Protocol Version 6 (IPv6) 5097 Specification", RFC 2463, December 1998. 5099 [6] Aura, T., "Cryptographically Generated Addresses (CGA)", 5100 RFC 3972, March 2005. 5102 [7] Bagnulo, M., "Hash Based Addresses (HBA)", 5103 draft-ietf-shim6-hba-01 (work in progress), September 2006. 5105 [8] Arkko, J. and I. Beijnum, "Failure Detection and Locator Pair 5106 Exploration Protocol for IPv6 Multihoming", 5107 draft-ietf-shim6-failure-detection-06 (work in progress), 5108 September 2006. 5110 19.2. Informative References 5112 [9] Gulbrandsen, A., Vixie, P., and L. Esibov, "A DNS RR for 5113 specifying the location of services (DNS SRV)", RFC 2782, 5114 February 2000. 5116 [10] Ferguson, P. and D. Senie, "Network Ingress Filtering: 5117 Defeating Denial of Service Attacks which employ IP Source 5118 Address Spoofing", BCP 38, RFC 2827, May 2000. 5120 [11] Narten, T. and R. Draves, "Privacy Extensions for Stateless 5121 Address Autoconfiguration in IPv6", RFC 3041, January 2001. 5123 [12] Draves, R., "Default Address Selection for Internet Protocol 5124 version 6 (IPv6)", RFC 3484, February 2003. 5126 [13] Bagnulo, M., "Updating RFC 3484 for multihoming support", 5127 draft-bagnulo-ipv6-rfc3484-update-00 (work in progress), 5128 December 2005. 5130 [14] Schulzrinne, H., Casner, S., Frederick, R., and V. Jacobson, 5131 "RTP: A Transport Protocol for Real-Time Applications", STD 64, 5132 RFC 3550, July 2003. 5134 [15] Abley, J., Black, B., and V. Gill, "Goals for IPv6 Site- 5135 Multihoming Architectures", RFC 3582, August 2003. 5137 [16] Rajahalme, J., Conta, A., Carpenter, B., and S. Deering, "IPv6 5138 Flow Label Specification", RFC 3697, March 2004. 5140 [17] Eastlake, D., Schiller, J., and S. Crocker, "Randomness 5141 Requirements for Security", BCP 106, RFC 4086, June 2005. 5143 [18] Hinden, R. and B. Haberman, "Unique Local IPv6 Unicast 5144 Addresses", RFC 4193, October 2005. 5146 [19] Nordmark, E. and T. Li, "Threats Relating to IPv6 Multihoming 5147 Solutions", RFC 4218, October 2005. 5149 [20] Huitema, C., "Ingress filtering compatibility for IPv6 5150 multihomed sites", draft-huitema-shim6-ingress-filtering-00 5151 (work in progress), September 2005. 5153 [21] Bagnulo, M. and E. Nordmark, "SHIM - MIPv6 Interaction", 5154 draft-bagnulo-shim6-mip-00 (work in progress), July 2005. 5156 [22] Nordmark, E., "Shim6 Application Referral Issues", 5157 draft-ietf-shim6-app-refer-00 (work in progress), July 2005. 5159 [23] Bagnulo, M. and J. Abley, "Applicability Statement for the 5160 Level 3 Multihoming Shim Protocol (Shim6)", 5161 draft-ietf-shim6-applicability-01 (work in progress), 5162 June 2006. 5164 [24] Huston, G., "Architectural Commentary on Site Multi-homing 5165 using a Level 3 Shim", draft-ietf-shim6-arch-00 (work in 5166 progress), July 2005. 5168 [25] Moskowitz, R., "Host Identity Protocol", draft-ietf-hip-base-06 5169 (work in progress), June 2006. 5171 [26] Eronen, P., "IKEv2 Mobility and Multihoming Protocol (MOBIKE)", 5172 draft-ietf-mobike-protocol-08 (work in progress), 5173 February 2006. 5175 Authors' Addresses 5177 Erik Nordmark 5178 Sun Microsystems 5179 17 Network Circle 5180 Menlo Park, CA 94025 5181 USA 5183 Phone: +1 650 786 2921 5184 Email: erik.nordmark@sun.com 5186 Marcelo Bagnulo 5187 Universidad Carlos III de Madrid 5188 Av. Universidad 30 5189 Leganes, Madrid 28911 5190 SPAIN 5192 Phone: +34 91 6248814 5193 Email: marcelo@it.uc3m.es 5194 URI: http://www.it.uc3m.es 5196 Intellectual Property Statement 5198 The IETF takes no position regarding the validity or scope of any 5199 Intellectual Property Rights or other rights that might be claimed to 5200 pertain to the implementation or use of the technology described in 5201 this document or the extent to which any license under such rights 5202 might or might not be available; nor does it represent that it has 5203 made any independent effort to identify any such rights. Information 5204 on the procedures with respect to rights in RFC documents can be 5205 found in BCP 78 and BCP 79. 5207 Copies of IPR disclosures made to the IETF Secretariat and any 5208 assurances of licenses to be made available, or the result of an 5209 attempt made to obtain a general license or permission for the use of 5210 such proprietary rights by implementers or users of this 5211 specification can be obtained from the IETF on-line IPR repository at 5212 http://www.ietf.org/ipr. 5214 The IETF invites any interested party to bring to its attention any 5215 copyrights, patents or patent applications, or other proprietary 5216 rights that may cover technology that may be required to implement 5217 this standard. Please address the information to the IETF at 5218 ietf-ipr@ietf.org. 5220 Disclaimer of Validity 5222 This document and the information contained herein are provided on an 5223 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS 5224 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET 5225 ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, 5226 INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE 5227 INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 5228 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 5230 Copyright Statement 5232 Copyright (C) The Internet Society (2006). This document is subject 5233 to the rights, licenses and restrictions contained in BCP 78, and 5234 except as set forth therein, the authors retain all their rights. 5236 Acknowledgment 5238 Funding for the RFC Editor function is currently provided by the 5239 Internet Society.