idnits 2.17.1 draft-ietf-shim6-proto-05.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 5226. -- Found old boilerplate from RFC 3979, Section 5, paragraph 1 on line 5203. -- Found old boilerplate from RFC 3979, Section 5, paragraph 2 on line 5210. -- Found old boilerplate from RFC 3979, Section 5, paragraph 3 on line 5216. ** 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 3148 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 (May 15, 2006) is 6556 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 3812 -- Looks like a reference, but probably isn't: 'FII' on line 2224 == Unused Reference: '4' is defined on line 5091, but no explicit reference was found in the text == Unused Reference: '23' is defined on line 5158, but no explicit reference was found in the text == Unused Reference: '24' is defined on line 5162, but no explicit reference was found in the text == Unused Reference: '26' is defined on line 5169, 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-03 -- 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-00 == Outdated reference: A later version (-10) exists of draft-ietf-hip-base-05 Summary: 7 errors (**), 0 flaws (~~), 12 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: November 16, 2006 M. Bagnulo 5 UC3M 6 May 15, 2006 8 Level 3 multihoming shim protocol 9 draft-ietf-shim6-proto-05.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 November 16, 2006. 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, including how a new working 187 locator pair is discovered after a failure, is specified in a 188 separate documents [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 through certain classes of 198 failures, for example, TCP connections and application 199 communications using UDP. 201 o Have minimal impact on upper layer protocols in general and on 202 transport protocols in particular. 204 o Address the security threats in [19] through the combination of 205 the HBA/CGA approach specified in a separate document [7], and 206 techniques described in this document. 208 o Not require extra roundtrip up front to setup shim specific state. 209 Instead allow the upper layer traffic (e.g., TCP) to flow as 210 normal and defer the setup of the shim state until some number of 211 packets have been exchanged. 213 o Take advantage of multiple locators/addresses for load spreading 214 so that different sets of communication to a host (e.g., different 215 connections) might use different locators of the host. Note that 216 this might cause load to be spread unevenly, thus we use the term 217 "load spreading" instead of "load balancing". This capability 218 might enable some forms of traffic engineering, but the details 219 for traffic engineering, including what requirements can be 220 satisfied, are not specified in this document, and form part of a 221 potential extensions to this protocol. 223 1.2. Non-Goals 225 The assumption is that the problem we are trying to solve is site 226 multihoming, with the ability to have the set of site locator 227 prefixes change over time due to site renumbering. Further, we 228 assume that such changes to the set of locator prefixes can be 229 relatively slow and managed; slow enough to allow updates to the DNS 230 to propagate. But it is not a goal to try to make communication 231 survive a renumbering event (which causes all the locators of a host 232 to change to a new set of locators). This proposal does not attempt 233 to solve the, perhaps related, problem of host mobility. However, it 234 might turn out that the shim6 protocol can be a useful component for 235 future host mobility solutions, e.g., for route optimization. 237 This proposal also does not try to provide a new network level or 238 transport level identifier namespace separated from the current IP 239 address namespace. Even though such a concept would be useful to 240 ULPs and applications, especially if the management burden for such a 241 name space was negligible and there was an efficient yet secure 242 mechanism to map from identifiers to locators, such a name space 243 isn't necessary (and furthermore doesn't seem to help) to solve the 244 multihoming problem. 246 1.3. Locators as Upper-layer Identifiers 248 This approach does not introduce a new identifier name space but 249 instead uses the locator that is selected in the initial contact with 250 the remote peer as the preserved upper-level identifier. While there 251 may be subsequent changes in the selected network level locators over 252 time in response to failures in using the original locator, the upper 253 level protocol stack elements will continue to use this upper level 254 identifier without change. 256 This implies that the ULID selection is performed as today's default 257 address selection as specified in RFC 3484 [12]. Some extensions are 258 needed to RFC 3484 to try different source addresses, whether or not 259 the shim6 protocol is used, as outlined in [13]. Underneath, and 260 transparently, the multihoming shim selects working locator pairs 261 with the initial locator pair being the ULID pair. When 262 communication fails the shim can test and select alternate locators. 263 A subsequent section discusses the issues when the selected ULID is 264 not initially working hence there is a need to switch locators up 265 front. 267 Using one of the locators as the ULID has certain benefits for 268 applications which have long-lived session state, or performs 269 callbacks or referrals, because both the FQDN and the 128-bit ULID 270 work as handles for the applications. However, using a single 128- 271 bit ULID doesn't provide seamless communication when that locator is 272 unreachable. See [22] for further discussion of the application 273 implications. 275 There has been some discussion of using non-routable locators, such 276 as unique-local addresses [18], as ULIDs in a multihoming solution. 277 While this document doesn't specify all aspects of this, it is 278 believed that the approach can be extended to handle such a case. 279 For example, the protocol already needs to handle ULIDs that are not 280 initially reachable. Thus the same mechanism can handle ULIDs that 281 are permanently unreachable from outside their site. The issue 282 becomes how to make the protocol perform well when the ULID is known 283 a priori to be not reachable (e.g., the ULID is a ULA), for instance, 284 avoiding any timeout and retries in this case. In addition one would 285 need to understand how the ULAs would be entered in the DNS to avoid 286 a performance impact on existing, non-shim6 aware, IPv6 hosts 287 potentially trying to communicate to the (unreachable) ULA. 289 1.4. IP Multicast 291 IP Multicast requires that the IP source address field contain a 292 topologically correct locator for interface that is used to send the 293 packet, since IP multicast routing uses both the source address and 294 the destination group to determine where to forward the packet. 295 (This isn't much different than the situation with widely implemented 296 ingress filtering [10] for unicast.) 298 While in theory it would be possible to apply the shim re-mapping of 299 the IP address fields between ULIDs and locators, the fact that all 300 the multicast receivers would need to know the mapping to perform, 301 makes such an approach difficult in practice. Thus it makes sense to 302 have multicast ULPs operate directly on locators and not use the 303 shim. This is quite a natural fit for protocols which use RTP [14], 304 since RTP already has an explicit identifier in the form of the SSRC 305 field in the RTP headers. Thus the actual IP address fields are not 306 important to the application. 308 In summary, IP multicast will not need the shim to remap the IP 309 addresses. 311 This doesn't prevent the receiver of multicast to change its 312 locators, since the receiver is not explicitly identified; the 313 destination address is a multicast address and not the unicast 314 locator of the receiver. 316 1.5. Renumbering Implications 318 As stated above, this approach does not try to make communication 319 survive renumbering in the general case. 321 When a host is renumbered, the effect is that one or more locators 322 become invalid, and zero or more locators are added to the host's 323 network interface. This means that the set of locators that is used 324 in the shim will change, which the shim can handle as long as not all 325 the original locators become invalid at the same time. 327 But IP addresses are also used as ULID, and making the communication 328 survive locators becoming invalid can potentially cause some 329 confusion at the upper layers. The fact that a ULID might be used 330 with a different locator over time open up the possibility that 331 communication between two ULIDs might continue to work after one or 332 both of those ULIDs are no longer reachable as locators, for example 333 due to a renumbering event. This opens up the possibility that the 334 ULID (or at least the prefix on which it is based) is reassigned to 335 another site while it is still being used (with another locator) for 336 existing communication. 338 In the worst case we could end up with two separate hosts using the 339 same ULID while both of them are communicating with the same host. 341 This potential source for confusion can be avoided if we require that 342 any communication using a ULID must be terminated when the ULID 343 becomes invalid (due to the underlying prefix becoming invalid). If 344 that behavior is desired, it can be accomplished by explicitly 345 discarding the shim state when the ULID becomes invalid. The context 346 recovery mechanism will then make the peer aware that the context is 347 gone, and that the ULID is no longer present at the same locator(s). 349 However, terminating the communication might be overkill. Even when 350 an IPv6 prefix is retired and reassigned to some other site, there is 351 a very small probability that another host in that site picks the 352 same 128 bit address (whether using DHCPv6, stateless address 353 autoconfiguration, or picking a random interface ID [11]). Should 354 the identical address be used by another host, then there still 355 wouldn't be a problem until that host attempts to communicate with 356 the same peer host with which the initial user of the IPv6 address 357 was communicating. 359 The protocol as specified in this document does not perform any 360 action when an address becomes invalid. As we gain further 361 understanding of the practical impact of renumbering this might 362 change in a future version of the protocol. 364 1.6. Placement of the shim 366 ----------------------- 367 | Transport Protocols | 368 ----------------------- 370 ------ ------- -------------- ------------- IP endpoint 371 | AH | | ESP | | Frag/reass | | Dest opts | sub-layer 372 ------ ------- -------------- ------------- 374 --------------------- 375 | shim6 shim layer | 376 --------------------- 378 ------ IP routing 379 | IP | sub-layer 380 ------ 382 Figure 1: Protocol stack 384 The proposal uses a multihoming shim layer within the IP layer, i.e., 385 below the ULPs, as shown in Figure 1, in order to provide ULP 386 independence. The multihoming shim layer behaves as if it is 387 associated with an extension header, which would be placed after any 388 routing-related headers in the packet (such as any hop-by-hop 389 options, or routing header). However, when the locator pair is the 390 ULID pair there is no data that needs to be carried in an extension 391 header, thus none is needed in that case. 393 Layering AH and ESP above the multihoming shim means that IPsec can 394 be made to be unaware of locator changes the same way that transport 395 protocols can be unaware. Thus the IPsec security associations 396 remain stable even though the locators are changing. This means that 397 the IP addresses specified in the selectors should be the ULIDs. 399 Layering the fragmentation header above the multihoming shim makes 400 reassembly robust in the case that there is broken multi-path routing 401 which results in using different paths, hence potentially different 402 source locators, for different fragments. Thus, effectively the 403 multihoming shim layer is placed between the IP endpoint sublayer, 404 which handles fragmentation, reassembly, and IPsec, and the IP 405 routing sublayer, which selects which next hop and interface to use 406 for sending out packets. 408 Applications and upper layer protocols use ULIDs which the shim6 409 layer will map to/from different locators. The shim6 layer maintains 410 state, called ULID-pair context, per ULID pairs (that is, applies to 411 all ULP connections between the ULID pair) in order to perform this 412 mapping. The mapping is performed consistently at the sender and the 413 receiver, thus from the perspective of the upper layer protocols, 414 packets appear to be sent using ULIDs from end to end, even though 415 the packets travel through the network containing locators in the IP 416 address fields, and even though those locators might be changed by 417 the transmitting shim6 layer. 419 The context state in this approach is maintained per remote ULID i.e. 420 approximately per peer host, and not at any finer granularity. In 421 particular, it is independent of the ULPs and any ULP connections. 422 However, the forking capability enables shim-aware ULPs to use more 423 than one locator pair at a time for an single ULID pair. 425 ---------------------------- ---------------------------- 426 | Sender A | | Receiver B | 427 | | | | 428 | ULP | | ULP | 429 | | src ULID(A)=L1(A) | | ^ | 430 | | dst ULID(B)=L1(B) | | | src ULID(A)=L1(A) | 431 | v | | | dst ULID(B)=L1(B) | 432 | multihoming shim | | multihoming shim | 433 | | src L2(A) | | ^ | 434 | | dst L3(B) | | | src L2(A) | 435 | v | | | dst L3(B) | 436 | IP | | IP | 437 ---------------------------- ---------------------------- 438 | ^ 439 ------- cloud with some routers ------- 441 Figure 2: Mapping with changed locators 443 The result of this consistent mapping is that there is no impact on 444 the ULPs. In particular, there is no impact on pseudo-header 445 checksums and connection identification. 447 Conceptually one could view this approach as if both ULIDs and 448 locators are being present in every packet, and with a header 449 compression mechanism applied that removes the need for the ULIDs to 450 be carried in the packets once the compression state has been 451 established. In order for the receiver to recreate a packet with the 452 correct ULIDs there is a need to include some "compression tag" in 453 the data packets. This serves to indicate the correct context to use 454 for decompression when the locator pair in the packet is insufficient 455 to uniquely identify the context. 457 1.7. Traffic Engineering 459 At the time of this writing it is not clear what requirements for 460 traffic engineering make sense for the shim6 protocol, since the 461 requirements must both result in some useful behavior as well as be 462 implementable using a host-to-host locator agility mechanism like 463 shim6. 465 Inherent in a scalable multihoming mechanism that separates locators 466 from identifiers is that each host ends up with multiple locators. 467 This means that at least for initial contact, it is the remote peer 468 that needs to select which peer locator to try first. In the case of 469 shim6 this is performed by applying RFC 3484 address selection. 471 This is quite different than the common case of IPv4 multihoming 472 where the site has a single IP address prefix, since in that case the 473 peer performs no destination address selection. 475 Thus in "single prefix multihoming" the site, and in many cases its 476 upstream ISPs, can use BGP to exert some control of the ingress used 477 to reach the site. This capability can't easily be recreated in 478 "multiple prefix multihoming" such as shim6. 480 The protocol provides a placeholder, in the form of the Locator 481 Preferences option, which can be used by hosts to express priority 482 and weight values for each locator. This is intentionally made 483 identical to the DNS SRV [9] specification of priority and weight, so 484 that DNS SRV records can be used for initial contact and the shim for 485 failover, and they can use the same way to describe the preferences. 486 The format allows adding additional notions of "metrics" over time. 487 But the Locator Preference option is merely a place holder when it 488 comes to providing traffic engineering; in order to use this in a 489 large site there would have to be a mechanism by which the host can 490 find out what preference values to use, either statically (e.g., some 491 new DHCPv6 option) or dynamically. 493 Thus traffic engineering is listed as a possible extension in 494 Appendix A. 496 2. Terminology 498 This document uses the terms MUST, SHOULD, RECOMMENDED, MAY, SHOULD 499 NOT and MUST NOT defined in RFC 2119 [1]. The terms defined in RFC 500 2460 [2] are also used. 502 2.1. Definitions 504 This document introduces the following terms: 506 upper layer protocol (ULP) 507 A protocol layer immediately above IP. Examples 508 are transport protocols such as TCP and UDP, 509 control protocols such as ICMP, routing protocols 510 such as OSPF, and internet or lower-layer 511 protocols being "tunneled" over (i.e., 512 encapsulated in) IP such as IPX, AppleTalk, or IP 513 itself. 515 interface A node's attachment to a link. 517 address An IP layer name that contains both topological 518 significance and acts as a unique identifier for 519 an interface. 128 bits. This document only uses 520 the "address" term in the case where it isn't 521 specific whether it is a locator or an 522 identifier. 524 locator An IP layer topological name for an interface or 525 a set of interfaces. 128 bits. The locators are 526 carried in the IP address fields as the packets 527 traverse the network. 529 identifier An IP layer name for an IP layer endpoint. The 530 transport endpoint name is a function of the 531 transport protocol and would typically include 532 the IP identifier plus a port number. 533 NOTE: This proposal does not specify any new form 534 of IP layer identifier, but still separates the 535 identifying and locating properties of the IP 536 addresses. 538 upper-layer identifier (ULID) 539 An IP address which has been selected for 540 communication with a peer to be used by the upper 541 layer protocol. 128 bits. This is used for 542 pseudo-header checksum computation and connection 543 identification in the ULP. Different sets of 544 communication to a host (e.g., different 545 connections) might use different ULIDs in order 546 to enable load spreading. 548 Since the ULID is just one of the IP locators/ 549 addresses of the node, there is no need for a 550 separate name space and allocation mechanisms. 552 address field The source and destination address fields in the 553 IPv6 header. As IPv6 is currently specified this 554 fields carry "addresses". If identifiers and 555 locators are separated these fields will contain 556 locators for packets on the wire. 558 FQDN Fully Qualified Domain Name 560 ULID-pair context The state that the multihoming shim maintains 561 between a pair of Upper-layer identifiers. The 562 context is identified by a context tag for each 563 direction of the communication, and also 564 identified by the pair of ULID and a Forked 565 Instance Identifier (see below). 567 Context tag Each end of the context allocates a context tag 568 for the context. This is used to uniquely 569 associate both received control packets and 570 payload extension headers as belonging to the 571 context. 573 Current locator pair 574 Each end of the context has a current locator 575 pair which is used to send packets to the peer. 576 The two ends might use different current locator 577 pairs though. 579 Default context At the sending end, the shim uses the ULID pair 580 (passed down from the ULP) to find the context 581 for that pair. Thus, normally, a host can have 582 at most one context for a ULID pair. We call 583 this the "default context". 585 Context forking A mechanism which allows ULPs that are aware of 586 multiple locators to use separate contexts for 587 the same ULID pair, in order to be able use 588 different locator pairs for different 589 communication to the same ULID. Context forking 590 causes more than just the default context to be 591 created for a ULID pair. 593 Forked Instance Identifier (FII) 594 In order to handle context forking, a context is 595 identified by a ULID-pair and a forked context 596 identifier. The default context has a FII of 597 zero. 599 Initial contact We use this term to refer to the pre-shim 600 communication when some ULP decides to start 601 communicating with a peer by sending and 602 receiving ULP packets. Typically this would not 603 invoke any operations in the shim, since the shim 604 can defer the context establishment until some 605 arbitrary later point in time. 607 Hash Based Addresses (HBA) 608 A form of IPv6 address where the interface ID is 609 derived from a cryptographic hash of all the 610 prefixes assigned to the host. See [7]. 612 Cryptographically Generated Addresses (CGA) 613 A form of IPv6 address where the interface ID is 614 derived from a cryptographic hash of the public 615 key. See [6]. 617 CGA Parameter Data Structure (PDS) 618 The information that CGA and HBA exchanges in 619 order to inform the peer of how the interface ID 620 was computed. See [6]., [7]. 622 2.2. Notational Conventions 624 A, B, and C are hosts. X is a potentially malicious host. 626 FQDN(A) is the domain name for A. 628 Ls(A) is the locator set for A, which consists of the locators L1(A), 629 L2(A), ... Ln(A). 631 ULID(A) is an upper-layer ID for A. In this proposal, ULID(A) is 632 always one member of A's locator set. 634 CT(X) is a context tag assigned by X. 636 This document also makes use of internal conceptual variables to 637 describe protocol behavior and external variables that an 638 implementation must allow system administrators to change. The 639 specific variable names, how their values change, and how their 640 settings influence protocol behavior are provided to demonstrate 641 protocol behavior. An implementation is not required to have them in 642 the exact form described here, so long as its external behavior is 643 consistent with that described in this document. See Section 6 for a 644 description of the conceptual data structures. 646 3. Assumptions 648 The design intent is to ensure that the shim6 protocol is capable of 649 handling path failures independently of the number of IP addresses 650 (locators) available to the two communicating hosts, and 651 independently of which host detects the failure condition. 653 In the case when host A and host B have an active shim6 state, with 654 host A having only one locator and host B having multiple locators, 655 it might be that host B is trying to send a packet to host A, and has 656 detected a failure condition with the current locator pair. As host 657 B has multiple locators it presumably has multiple ISPs. In this 658 case there are probably alternate egress paths for host B to be able 659 to try to reach A, but B can not vary the destination address (host A 660 locator) to select such alternate paths, since A has only one 661 locator. 663 This leads to the assumption that a host should be able to cause 664 different egress paths from its site to be used. The most reasonable 665 approach to accomplish this is to have the host use different source 666 addresses and have the source address affect the selection of the 667 site egress. The details of how this can be accomplished is beyond 668 the scope of this document, but without this capability the ability 669 of the shim to try different "paths" by trying different locator 670 pairs will have limited utility. 672 The above assumption applies whether or not the ISPs perform ingress 673 filtering. 675 In addition, when the site's ISPs perform ingress filtering based on 676 packet source addresses, shim6 assumes that packets sent with 677 different source and destination combinations have a reasonable 678 chance of making it through the relevant ISP's ingress filters. This 679 can be accomplished in several ways (all outside the scope of this 680 document), such as having the ISPs relax there ingress filters, or 681 selecting the egress such that it matches the IP source address 682 prefix. 684 Further discussion of this issue is captured in [20]. 686 The shim6 approach assumes that there are no IPv6-to-IPv6 NATs on the 687 paths, i.e., that the two ends can exchange their own notion of their 688 IPv6 addresses and that those addresses will also make sense to their 689 peer. 691 4. Protocol Overview 693 The shim6 protocol operates in several phases over time. The 694 following sequence illustrates the concepts: 696 o An application on host A decides to contact B using some upper- 697 layer protocol. This results in the ULP on A sending packets to 698 B. We call this the initial contact. Assuming the IP addresses 699 selected by Default Address Selection [12] and its extensions [13] 700 work, then there is no action by the shim at this point in time. 701 Any shim context establishment can be deferred until later. 703 o Some heuristic on A or B (or both) determine that it is 704 appropriate to pay the shim6 overhead to make this host-to-host 705 communication robust against locator failures. For instance, this 706 heuristic might be that more than 50 packets have been sent or 707 received, or a timer expiration while active packet exchange is in 708 place. This makes the shim initiate the 4-way context 709 establishment exchange. 711 As a result of this exchange, both A and B will know a list of 712 locators for each other. 714 If the context establishment exchange fails, the initiator will 715 then know that the other end does not support shim6, and will 716 continue with standard unicast behavior for the session. 718 o Communication continues without any change for the ULP packets. 719 In particular, there are no shim extension headers added to the 720 ULP packets, since the ULID pair is the same as the locator pair. 721 In addition, there might be some messages exchanged between the 722 shim sub-layers for (un)reachability detection. 724 o At some point in time something fails. Depending on the approach 725 to reachability detection, there might be some advice from the 726 ULP, or the shim (un)reachability detection might discover that 727 there is a problem. 729 At this point in time one or both ends of the communication need 730 to probe the different alternate locator pairs until a working 731 pair is found, and switch to using that locator pair. 733 o Once a working alternative locator pair has been found, the shim 734 will rewrite the packets on transmit, and tag the packets with 735 shim6 Payload extension header, which contains the receiver's 736 context tag. The receiver will use the context tag to find the 737 context state which will indicate which addresses to place in the 738 IPv6 header before passing the packet up to the ULP. The result 739 is that from the perspective of the ULP the packet passes 740 unmodified end-to-end, even though the IP routing infrastructure 741 sends the packet to a different locator. 743 o The shim (un)reachability detection will monitor the new locator 744 pair as it monitored the original locator pair, so that subsequent 745 failures can be detected. 747 o In addition to failures detected based on end-to-end observations, 748 one endpoint might know for certain that one or more of its 749 locators is not working. For instance, the network interface 750 might have failed or gone down (at layer 2), or an IPv6 address 751 might have become deprecated or invalid. In such cases the host 752 can signal its peer that this address is no longer recommended to 753 try. Thus this triggers something similar to a failure handling 754 in that a new, working locator pair must be found. 756 The protocol also has the ability to express other forms of 757 locator preferences. A change in any preferences can be signaled 758 to the peer, which will made the peer record the new preferences. 759 A change in the preferences might optionally make the peer want to 760 use a different locator pair. If it makes this decision, it 761 follows the same locator switching procedure as after a failure 762 (by verifying that its peer is indeed present at the alternate 763 locator, etc). 765 o When the shim thinks that the context state is no longer used, it 766 can garbage collect the state; there is no coordination necessary 767 with the peer host before the state is removed. There is a 768 recovery message defined to be able to signal when there is no 769 context state, which can be used to detect and recover from both 770 premature garbage collection, as well as complete state loss 771 (crash and reboot) of a peer. 773 The exact mechanism to determine when the context state is no 774 longer used is implementation dependent. An implementation might 775 use the existence of ULP state (where known to the implementation) 776 as an indication that the state is still used, combined with a 777 timer (to handle ULP state that might not be known to the shim 778 sub-layer) to determine when the state is likely to no longer be 779 used. 781 NOTE: The ULP packets in shim6 can be carried completely unmodified 782 as long as the ULID pair is used as the locator pair. After a switch 783 to a different locator pair the packets are "tagged" with a shim6 784 extension header, so that the receiver can always determine the 785 context to which they belong. This is accomplished by including an 786 8-octet shim6 Payload Extension header before the (extension) headers 787 that are processed by the IP endpoint sublayer and ULPs. If 788 subsequently the original ULIDs are selected as the active locator 789 pair then the tagging of packets with the shim6 extension header can 790 also be stopped. 792 4.1. Context Tags 794 A context between two hosts is actually a context between two ULIDs. 795 The context is identified by a pair of context tags. Each end gets 796 to allocate a context tag, and once the context is established, most 797 shim6 control messages contain the context tag that the receiver of 798 the message allocated. Thus at a minimum the combination of have to uniquely identify one 800 context. But since the Payload extension headers are demultiplexed 801 without looking at the locators in the packet, the receiver will need 802 to allocate context tags that are unique for all its contexts. The 803 context tag is a 47-bit number (the largest which can fit in an 804 8-octet extension header). 806 The mechanism for detecting a loss of context state at the peer that 807 is currently proposed in this document assumes that the receiver can 808 tell the packets that need locator rewriting, even after it has lost 809 all state (e.g., due to a crash followed by a reboot). This is 810 achieved because after a rehoming event the packets that need 811 receive-side rewriting, carry the Payload extension header. 813 4.2. Context Forking 815 It has been asserted that it will be important for future ULPs, in 816 particular, future transport protocols, to be able to control which 817 locator pairs are used for different communication. For instance, 818 host A and host B might communicate using both VoIP traffic and ftp 819 traffic, and those communications might benefit from using different 820 locator pairs. However, the fundamental shim6 mechanism uses a 821 single current locator pair for each context, thus a single context 822 can not accomplish this. 824 For this reason, the shim6 protocol supports the notion of context 825 forking. This is a mechanism by which a ULP can specify (using some 826 API not yet defined) that a context for e.g., the ULID pair 827 should be forked into two contexts. In this case the forked-off 828 context will be assigned a non-zero Forked Instance Identifier, while 829 the default context has FII zero. 831 The Forked Instance Identifier is a 32-bit identifier which has no 832 semantics in the protocol other then being part of the tuple which 833 identifies the context. The hosts can allocate FIIs e.g., as 834 sequential numbers for any given ULID pair. 836 No other special considerations are needed in the shim6 protocol to 837 handle forked contexts. 839 Note that forking as specified does NOT allow A to be able to tell B 840 that certain traffic (a 5-tuple?) should be forked for the reverse 841 direction. The shim6 forking mechanism as specified applies only to 842 the sending of ULP packets. If some ULP wants to fork for both 843 directions, it is up to the ULP to set this up, and then instruct the 844 shim at each end to transmit using the forked context. 846 4.3. API Extensions 848 Several API extensions have been discussed for shim6, but their 849 actual specification is out of scope for this document. The simplest 850 one would be to add a socket option to be able to have traffic bypass 851 the shim (not create any state, and not use any state created by 852 other traffic). This could be an IPV6_DONTSHIM socket option. Such 853 an option would be useful for protocols, such as DNS, where the 854 application has its own failover mechanism (multiple NS records in 855 the case of DNS) and using the shim could potentially add extra 856 latency with no added benefits. 858 Some other API extensions are discussed in Appendix A 860 4.4. Securing shim6 862 The mechanisms are secured using a combination of techniques: 864 o The HBA technique [7] for verifying the locators to prevent an 865 attacker from redirecting the packet stream to somewhere else. 867 o Requiring a Reachability Probe+Reply before a new locator is used 868 as the destination, in order to prevent 3rd party flooding 869 attacks. 871 o The first message does not create any state on the responder. 872 Essentially a 3-way exchange is required before the responder 873 creates any state. This means that a state-based DoS attack 874 (trying to use up all of memory on the responder) at least 875 provides an IPv6 address that the attacker was using. 877 o The context establishment messages use nonces to prevent replay 878 attacks, and to prevent off-path attackers from interfering with 879 the establishment. 881 o Every control message of the shim6 protocol, past the context 882 establishment, carry the context tag assigned to the particular 883 context. This implies that an attacker needs to discover that 884 context tag before being able to spoof any shim6 control message. 885 Such discovery probably requires to be along the path in order to 886 be sniff the context tag value. The result is that through this 887 technique, the shim6 protocol is protected against off-path 888 attackers. 890 4.5. Overview of Shim Control Messages 892 The shim6 context establishment is accomplished using four messages; 893 I1, R1, I2, R2. Normally they are sent in that order from initiator 894 and responder, respectively. Should both ends attempt to set up 895 context state at the same time (for the same ULID pair), then their 896 I1 messages might cross in flight, and result in an immediate R2 897 message. [The names of these messages are borrowed from HIP [25].] 899 R1bis and I2bis messages are defined, which are used to recover a 900 context after it has been lost. A R1bis message is sent when a shim6 901 control or Payload extension header arrives and there is no matching 902 context state at the receiver. When such a message is received, it 903 will result in the re-creation of the shim6 context using the I2bis 904 and R2 messages. 906 The peers' lists of locators are normally exchanged as part of the 907 context establishment exchange. But the set of locators might be 908 dynamic. For this reason there is a Update Request and Update 909 Acknowledgement messages, and a Locator List option. 911 Even when the list of locators is fixed, a host might determine that 912 some preferences might have changed. For instance, it might 913 determine that there is a locally visible failure that implies that 914 some locator(s) are no longer usable. This uses a Locator 915 Preferences option in the Update Request message. 917 The mechanism for (un)reachability detection is called Forced 918 Bidirectional Communication (FBD). The FBD approach uses a Keepalive 919 message, which is sent when a host has received packets from the 920 peer, but the ULP has not given the host an opportunity to send any 921 packet to the peer. The message type is reserved in this document, 922 but the message format and processing rules are specified in [8]. 924 In addition, when the context is established and there is a failure 925 there needs to be a way to probe the set of locator pairs to 926 efficiently find a working pair. This document reserves an Probe 927 message type, with the packet format and processing rules specified 928 in [8]. 930 The above probe and keepalive messages assume we have an established 931 ULID-pair context. However, communication might fail during the 932 initial contact (that is, when the application or transport protocol 933 is trying to setup some communication). This is handled using the 934 mechanisms in the ULP to try different address pairs as specified in 935 [12] [13]. In the future versions of the protocol, and with a richer 936 API between the ULP and the shim, the shim might be help optimize 937 discovering a working locator pair during initial contact. This is 938 for further study. 940 4.6. Extension Header Order 942 Since the shim is placed between the IP endpoint sub-layer and the IP 943 routing sub-layer in the host, the shim header will be placed before 944 any endpoint extension headers (fragmentation headers, destination 945 options header, AH, ESP), but after any routing related headers (hop- 946 by-hop extensions header, routing header, a destinations options 947 header which precedes a routing header). When tunneling is used, 948 whether IP-in-IP tunneling or the special form of tunneling that 949 Mobile IPv6 uses (with Home Address Options and Routing header type 950 2), there is a choice whether the shim applies inside the tunnel or 951 outside the tunnel, which affects the location of the shim6 header. 953 In most cases IP-in-IP tunnels are used as a routing technique, thus 954 it makes sense to apply them on the locators which means that the 955 sender would insert the shim6 header after any IP-in-IP 956 encapsulation; this is what occurs naturally when routers apply IP- 957 in-IP encapsulation. Thus the packets would have: 959 o Outer IP header 961 o Inner IP header 963 o Shim6 extension header (if needed> 965 o ULP 967 But the shim can also be used to create "shimmed tunnels" i.e., where 968 an IP-in-IP tunnel uses the shim to be able to switch the tunnel 969 endpoint addresses between different locators. In such a case the 970 packets would have: 972 o Outer IP header 974 o Shim6 extension header (if needed> 976 o Inner IP header 978 o ULP 980 In any case, the receiver behavior is well-defined; a receiver 981 processes the extension headers in order. However, the precise 982 interaction between Mobile IPv6 and shim6 is for further study, but 983 it might make sense to have Mobile IPv6 operate on locators as well, 984 meaning that the shim would be layered on top of the MIPv6 mechanism. 986 5. Message Formats 988 The shim6 messages are all carried using a new IP protocol number [to 989 be assigned by IANA]. The shim6 messages have a common header, 990 defined below, with some fixed fields, followed by type specific 991 fields. 993 The shim6 messages are structured as an IPv6 extension header since 994 the Payload extension header is used to carry the ULP packets after a 995 locator switch. The shim6 control messages use the same extension 996 header formats so that a single "protocol number" needs to be allowed 997 through firewalls in order for shim6 to function across the firewall. 999 5.1. Common shim6 Message Format 1001 The first 17 bits of the shim6 header is common for the Payload 1002 extension header and the control messages and looks as follows: 1004 0 1 1005 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 1006 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1007 | Next Header | Hdr Ext Len |P| 1008 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1010 Fields: 1012 Next Header: The payload which follows this header. 1014 Hdr Ext Len: 8-bit unsigned integer. Length of the shim6 header in 1015 8-octet units, not including the first 8 octets. 1017 P: A single bit to distinguish Payload extension headers 1018 from control messages. 1020 5.2. Payload Extension Header Format 1022 The payload extension headers is used to carry ULP packets where the 1023 receiver must replace the content of the source and/or destination 1024 fields in the IPv6 header before passing the packet to the ULP. Thus 1025 this extension header is required when the locators pair that is used 1026 is not the same as the ULID pair. 1028 0 1 2 3 1029 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 1030 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1031 | Next Header | 0 |1| | 1032 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1033 | Receiver Context Tag | 1034 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1036 Fields: 1038 Next Header: The payload which follows this header. 1040 Hdr Ext Len: 0 (since the header is 8 octets). 1042 P: Set to one. A single bit to distinguish this from the 1043 shim6 control messages. 1045 Receiver Context Tag: 47-bit unsigned integer. Allocated by the 1046 receiver for use to identify the context. 1048 5.3. Common Shim6 Control header 1050 The common part of the header has a next header and header extension 1051 length field which is consistent with the other IPv6 extension 1052 headers, even if the next header value is always "NO NEXT HEADER" for 1053 the control messages; only the payload extension header use the Next 1054 Header field. 1056 The shim6 headers must be a multiple of 8 octets, hence the minimum 1057 size is 8 octets. 1059 The common shim control message header is as follows: 1061 0 1 2 3 1062 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 1063 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1064 | Next Header | Hdr Ext Len |0| Type |Type-specific|0| 1065 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1066 | Checksum | | 1067 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1068 | Type-specific format | 1069 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1071 Fields: 1073 Next Header: 8-bit selector. Normally set to NO_NXT_HDR (59). 1075 Hdr Ext Len: 8-bit unsigned integer. Length of the shim6 header in 1076 8-octet units, not including the first 8 octets. 1078 P: Set to zero. A single bit to distinguish this from 1079 the shim6 payload extension header. 1081 Type: 7-bit unsigned integer. Identifies the actual message 1082 from the table below. Type codes 0-63 will not 1083 trigger R1bis messages on a missing context, while 64- 1084 127 will trigger R1bis. 1086 0: A single bit (set to zero) which allows shim6 and HIP 1087 to have a common header format yet telling shim6 and 1088 HIP messages apart. 1090 Checksum: 16-bit unsigned integer. The checksum is the 16-bit 1091 one's complement of the one's complement sum of the 1092 entire shim6 header message starting with the shim6 1093 next header field, and ending as indicated by the Hdr 1094 Ext Len. Thus when there is a payload following the 1095 shim6 header, the payload is NOT included in the shim6 1096 checksum. Note that unlike protocol like ICMPv6, 1097 there is no pseudo-header checksum part of the 1098 checksum, in order to provide locator agility without 1099 having to change the checksum. 1101 Type-specific: Part of message that is different for different 1102 message types. 1104 +------------+-----------------------------------------------------+ 1105 | Type Value | Message | 1106 +------------+-----------------------------------------------------+ 1107 | 1 | I1 (first establishment message from the initiator) | 1108 | | | 1109 | 2 | R1 (first establishment message from the responder) | 1110 | | | 1111 | 3 | I2 (2nd establishment message from the initiator) | 1112 | | | 1113 | 4 | R2 (2nd establishment message from the responder) | 1114 | | | 1115 | 5 | R1bis (Reply to reference to non-existent context) | 1116 | | | 1117 | 6 | I2bis (Reply to a R1bis message) | 1118 | | | 1119 | 64 | Update Request | 1120 | | | 1121 | 65 | Update Acknowledgement | 1122 | | | 1123 | 66 | Keepalive | 1124 | | | 1125 | 67 | Probe Message | 1126 +------------+-----------------------------------------------------+ 1128 Table 1 1130 5.4. I1 Message Format 1132 The I1 message is the first message in the context establishment 1133 exchange. 1135 0 1 2 3 1136 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 1137 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1138 | 59 | Hdr Ext Len |0| Type = 1 | Reserved1 |0| 1139 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1140 | Checksum |R| | 1141 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1142 | Initiator Context Tag | 1143 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1144 | Initiator Nonce | 1145 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1146 | | 1147 + Options + 1148 | | 1149 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1151 Fields: 1153 Next Header: NO_NXT_HDR (59). 1155 Hdr Ext Len: At least 1, since the header is 16 octets when there 1156 are no options. 1158 Type: 1 1160 Reserved1: 7-bit field. Reserved for future use. Zero on 1161 transmit. MUST be ignored on receipt. 1163 R: 1-bit field. Reserved for future use. Zero on 1164 transmit. MUST be ignored on receipt. 1166 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1167 has allocated for the context. 1169 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1170 the initiator which the responder will return in the 1171 R1 message. 1173 The following options are defined for this message: 1175 ULID pair: When the IPv6 source and destination addresses in the 1176 IPv6 header does not match the ULID pair, this option 1177 MUST be included. An example of this is when 1178 recovering from a lost context. 1180 Forked Instance Identifier: When another instance of an existent 1181 context with the same ULID pair is being created, a 1182 Forked Instance Identifier option is included to 1183 distinguish this new instance from the existent one. 1185 Future protocol extensions might define additional options for this 1186 message. The C-bit in the option format defines how such a new 1187 option will be handled by an implementation. See Section 5.14. 1189 5.5. R1 Message Format 1191 The R1 message is the second message in the context establishment 1192 exchange. The responder sends this in response to an I1 message, 1193 without creating any state specific to the initiator. 1195 0 1 2 3 1196 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 1197 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1198 | 59 | Hdr Ext Len |0| Type = 2 | Reserved1 |0| 1199 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1200 | Checksum | Reserved2 | 1201 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1202 | Initiator Nonce | 1203 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1204 | Responder Nonce | 1205 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1206 | | 1207 + Options + 1208 | | 1209 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1211 Fields: 1213 Next Header: NO_NXT_HDR (59). 1215 Hdr Ext Len: At least 1, since the header is 16 octets when there 1216 are no options. 1218 Type: 2 1219 Reserved1: 7-bit field. Reserved for future use. Zero on 1220 transmit. MUST be ignored on receipt. 1222 Reserved2: 16-bit field. Reserved for future use. Zero on 1223 transmit. MUST be ignored on receipt. 1225 Initiator Nonce: 32-bit unsigned integer. Copied from the I1 1226 message. 1228 Responder Nonce: 32-bit unsigned integer. A number picked by the 1229 responder which the initiator will return in the I2 1230 message. 1232 The following options are defined for this message: 1234 Responder Validator: Variable length option. Typically a hash 1235 generated by the responder, which the responder uses 1236 together with the Responder Nonce value to verify that 1237 an I2 message is indeed sent in response to a R1 1238 message, and that the parameters in the I2 message are 1239 the same as those in the I1 message. 1241 Future protocol extensions might define additional options for this 1242 message. The C-bit in the option format defines how such a new 1243 option will be handled by an implementation. See Section 5.14. 1245 5.6. I2 Message Format 1247 The I2 message is the third message in the context establishment 1248 exchange. The initiator sends this in response to a R1 message, 1249 after checking the Initiator Nonce, etc. 1251 0 1 2 3 1252 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 1253 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1254 | 59 | Hdr Ext Len |0| Type = 3 | Reserved1 |0| 1255 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1256 | Checksum |R| | 1257 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1258 | Initiator Context Tag | 1259 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1260 | Initiator Nonce | 1261 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1262 | Responder Nonce | 1263 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1264 | Reserved2 | 1265 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1266 | | 1267 + Options + 1268 | | 1269 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1271 Fields: 1273 Next Header: NO_NXT_HDR (59). 1275 Hdr Ext Len: At least 2, since the header is 24 octets when there 1276 are no options. 1278 Type: 3 1280 Reserved1: 7-bit field. Reserved for future use. Zero on 1281 transmit. MUST be ignored on receipt. 1283 R: 1-bit field. Reserved for future use. Zero on 1284 transmit. MUST be ignored on receipt. 1286 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1287 has allocated for the context. 1289 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1290 the initiator which the responder will return in the 1291 R2 message. 1293 Responder Nonce: 32-bit unsigned integer. Copied from the R1 1294 message. 1296 Reserved2: 32-bit field. Reserved for future use. Zero on 1297 transmit. MUST be ignored on receipt. (Needed to 1298 make the options start on a multiple of 8 octet 1299 boundary.) 1301 The following options are defined for this message: 1303 Responder Validator: Variable length option. Just a copy of the 1304 Responder Validator option in the R1 message. 1306 ULID pair: When the IPv6 source and destination addresses in the 1307 IPv6 header does not match the ULID pair, this option 1308 MUST be included. An example of this is when 1309 recovering from a lost context. 1311 Forked Instance Identifier: When another instance of an existent 1312 context with the same ULID pair is being created, a 1313 Forked Instance Identifier option is included to 1314 distinguish this new instance from the existent one. 1316 Locator list: Optionally sent when the initiator immediately wants 1317 to tell the responder its list of locators. When it 1318 is sent, the necessary HBA/CGA information for 1319 verifying the locator list MUST also be included. 1321 Locator Preferences: Optionally sent when the locators don't all have 1322 equal preference. 1324 CGA Parameter Data Structure: Included when the locator list is 1325 included so the receiver can verify the locator list. 1327 CGA Signature: Included when the some of the locators in the list use 1328 CGA (and not HBA) for verification. 1330 Future protocol extensions might define additional options for this 1331 message. The C-bit in the option format defines how such a new 1332 option will be handled by an implementation. See Section 5.14. 1334 5.7. R2 Message Format 1336 The R2 message is the fourth message in the context establishment 1337 exchange. The responder sends this in response to an I2 message. 1338 The R2 message is also used when both hosts send I1 messages at the 1339 same time and the I1 messages cross in flight. 1341 0 1 2 3 1342 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 1343 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1344 | 59 | Hdr Ext Len |0| Type = 4 | Reserved1 |0| 1345 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1346 | Checksum |R| | 1347 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1348 | Responder Context Tag | 1349 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1350 | Initiator Nonce | 1351 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1352 | | 1353 + Options + 1354 | | 1355 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1357 Fields: 1359 Next Header: NO_NXT_HDR (59). 1361 Hdr Ext Len: At least 1, since the header is 16 octets when there 1362 are no options. 1364 Type: 4 1366 Reserved1: 7-bit field. Reserved for future use. Zero on 1367 transmit. MUST be ignored on receipt. 1369 R: 1-bit field. Reserved for future use. Zero on 1370 transmit. MUST be ignored on receipt. 1372 Responder Context Tag: 47-bit field. The Context Tag the responder 1373 has allocated for the context. 1375 Initiator Nonce: 32-bit unsigned integer. Copied from the I2 1376 message. 1378 The following options are defined for this message: 1380 Locator List: Optionally sent when the responder immediately wants 1381 to tell the initiator its list of locators. When it 1382 is sent, the necessary HBA/CGA information for 1383 verifying the locator list MUST also be included. 1385 Locator Preferences: Optionally sent when the locators don't all have 1386 equal preference. 1388 CGA Parameter Data Structure: Included when the locator list is 1389 included so the receiver can verify the locator list. 1391 CGA Signature: Included when the some of the locators in the list use 1392 CGA (and not HBA) for verification. 1394 Future protocol extensions might define additional options for this 1395 message. The C-bit in the option format defines how such a new 1396 option will be handled by an implementation. See Section 5.14. 1398 5.8. R1bis Message Format 1400 Should a host receive a packet with a shim Payload extension header 1401 or shim6 control message with type code 64-127 (such as an Update or 1402 Probe message), and the host does not have any context state for the 1403 received context tag, then it will generate a R1bis message. 1405 This message allows the sender of the packet referring to the non- 1406 existent context to re-establish the context with a reduced context 1407 establishment exchange. Upon the reception of the R1bis message, the 1408 receiver can proceed reestablishing the lost context by directly 1409 sending an I2bis message. 1411 0 1 2 3 1412 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 1413 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1414 | 59 | Hdr Ext Len |0| Type = 5 | Reserved1 |0| 1415 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1416 | Checksum |R| | 1417 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1418 | Packet Context Tag | 1419 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1420 | Responder Nonce | 1421 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1422 | | 1423 + Options + 1424 | | 1425 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1427 Fields: 1429 Next Header: NO_NXT_HDR (59). 1431 Hdr Ext Len: At least 1, since the header is 16 octets when there 1432 are no options. 1434 Type: 5 1436 Reserved1: 7-bit field. Reserved for future use. Zero on 1437 transmit. MUST be ignored on receipt. 1439 R: 1-bit field. Reserved for future use. Zero on 1440 transmit. MUST be ignored on receipt. 1442 Packet Context Tag: 47-bit unsigned integer. The context tag 1443 contained in the received packet that triggered the 1444 generation of the R1bis message. 1446 Responder Nonce: 32-bit unsigned integer. A number picked by the 1447 responder which the initiator will return in the I2bis 1448 message. 1450 The following options are defined for this message: 1452 Responder Validator: Variable length option. Typically a hash 1453 generated by the responder, which the responder uses 1454 together with the Responder Nonce value to verify that 1455 an I2bis message is indeed sent in response to a R1bis 1456 message. 1458 Future protocol extensions might define additional options for this 1459 message. The C-bit in the option format defines how such a new 1460 option will be handled by an implementation. See Section 5.14. 1462 5.9. I2bis Message Format 1464 The I2bis message is the third message in the context recovery 1465 exchange. This is sent in response to a R1bis message, after 1466 checking that the R1bis message refers to an existing context, etc. 1468 0 1 2 3 1469 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 1470 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1471 | 59 | Hdr Ext Len |0| Type = 6 | Reserved1 |0| 1472 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1473 | Checksum |R| | 1474 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1475 | Initiator Context Tag | 1476 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1477 | Initiator Nonce | 1478 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1479 | Responder Nonce | 1480 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1481 | Reserved2 | 1482 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1483 | | | 1484 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1485 | Packet Context Tag | 1486 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1487 | | 1488 + Options + 1489 | | 1490 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1492 Fields: 1494 Next Header: NO_NXT_HDR (59). 1496 Hdr Ext Len: At least 3, since the header is 32 octets when there 1497 are no options. 1499 Type: 6 1501 Reserved1: 7-bit field. Reserved for future use. Zero on 1502 transmit. MUST be ignored on receipt. 1504 R: 1-bit field. Reserved for future use. Zero on 1505 transmit. MUST be ignored on receipt. 1507 Initiator Context Tag: 47-bit field. The Context Tag the initiator 1508 has allocated for the context. 1510 Initiator Nonce: 32-bit unsigned integer. A random number picked by 1511 the initiator which the responder will return in the 1512 R2 message. 1514 Responder Nonce: 32-bit unsigned integer. Copied from the R1bis 1515 message. 1517 Reserved2: 49-bit field. Reserved for future use. Zero on 1518 transmit. MUST be ignored on receipt. (Note that 17 1519 bits are not sufficient since the options need start 1520 on a multiple of 8 octet boundary.) 1522 Packet Context Tag: 47-bit unsigned integer. Copied from the Packet 1523 Context Tag contained in the received R1bis. 1525 The following options are defined for this message: 1527 Responder Validator: Variable length option. Just a copy of the 1528 Responder Validator option in the R1bis message. 1530 ULID pair: When the IPv6 source and destination addresses in the 1531 IPv6 header does not match the ULID pair, this option 1532 MUST be included. 1534 Forked Instance Identifier: When another instance of an existent 1535 context with the same ULID pair is being created, a 1536 Forked Instance Identifier option is included to 1537 distinguish this new instance from the existent one. 1539 Locator list: Optionally sent when the initiator immediately wants 1540 to tell the responder its list of locators. When it 1541 is sent, the necessary HBA/CGA information for 1542 verifying the locator list MUST also be included. 1544 Locator Preferences: Optionally sent when the locators don't all have 1545 equal preference. 1547 CGA Parameter Data Structure: Included when the locator list is 1548 included so the receiver can verify the locator list. 1550 CGA Signature: Included when the some of the locators in the list use 1551 CGA (and not HBA) for verification. 1553 Future protocol extensions might define additional options for this 1554 message. The C-bit in the option format defines how such a new 1555 option will be handled by an implementation. See Section 5.14. 1557 5.10. Update Request Message Format 1559 The Update Request Message is used to update either the list of 1560 locators, the locator preferences, and both. When the list of 1561 locators is updated, the message also contains the option(s) 1562 necessary for HBA/CGA to secure this. The basic sanity check that 1563 prevents off-path attackers from generating bogus updates is the 1564 context tag in the message. 1566 The update message contains options (the Locator List and the Locator 1567 Preferences) that, when included, completely replace the previous 1568 locator list and locator preferences, respectively. Thus there is no 1569 mechanism to just send deltas to the locator list. 1571 0 1 2 3 1572 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 1573 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1574 | 59 | Hdr Ext Len |0| Type = 64 | Reserved1 |0| 1575 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1576 | Checksum |R| | 1577 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1578 | Receiver Context Tag | 1579 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1580 | Request Nonce | 1581 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1582 | | 1583 + Options + 1584 | | 1585 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1587 Fields: 1589 Next Header: NO_NXT_HDR (59). 1591 Hdr Ext Len: At least 1, since the header is 16 octets when there 1592 are no options. 1594 Type: 64 1596 Reserved1: 7-bit field. Reserved for future use. Zero on 1597 transmit. MUST be ignored on receipt. 1599 R: 1-bit field. Reserved for future use. Zero on 1600 transmit. MUST be ignored on receipt. 1602 Receiver Context Tag: 47-bit field. The Context Tag the receiver has 1603 allocated for the context. 1605 Request Nonce: 32-bit unsigned integer. A random number picked by 1606 the initiator which the peer will return in the 1607 acknowledgement message. 1609 The following options are defined for this message: 1611 Locator List: The list of the sender's (new) locators. The locators 1612 might be unchanged and only the preferences have 1613 changed. 1615 Locator Preferences: Optionally sent when the locators don't all have 1616 equal preference. 1618 CGA Parameter Data Structure (PDS): Included when the locator list is 1619 included and the PDS was not included in the 1620 I2/I2bis/R2 messages, so the receiver can verify the 1621 locator list. 1623 CGA Signature: Included when the some of the locators in the list use 1624 CGA (and not HBA) for verification. 1626 Future protocol extensions might define additional options for this 1627 message. The C-bit in the option format defines how such a new 1628 option will be handled by an implementation. See Section 5.14. 1630 5.11. Update Acknowledgement Message Format 1632 This message is sent in response to a Update Request message. It 1633 implies that the Update Request has been received, and that any new 1634 locators in the Update Request can now be used as the source locators 1635 of packets. But it does not imply that the (new) locators have been 1636 verified to be used as a destination, since the host might defer the 1637 verification of a locator until it sees a need to use a locator as 1638 the destination. 1640 0 1 2 3 1641 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 1642 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1643 | 59 | Hdr Ext Len |0| Type = 65 | Reserved1 |0| 1644 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1645 | Checksum |R| | 1646 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | 1647 | Receiver Context Tag | 1648 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1649 | Request Nonce | 1650 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1651 | | 1652 + Options + 1653 | | 1654 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1656 Fields: 1658 Next Header: NO_NXT_HDR (59). 1660 Hdr Ext Len: At least 1, since the header is 16 octets when there 1661 are no options. 1663 Type: 65 1665 Reserved1: 7-bit field. Reserved for future use. Zero on 1666 transmit. MUST be ignored on receipt. 1668 R: 1-bit field. Reserved for future use. Zero on 1669 transmit. MUST be ignored on receipt. 1671 Receiver Context Tag: 47-bit field. The Context Tag the receiver has 1672 allocated for the context. 1674 Request Nonce: 32-bit unsigned integer. Copied from the Update 1675 Request message. 1677 No options are currently defined for this message. 1679 Future protocol extensions might define additional options for this 1680 message. The C-bit in the option format defines how such a new 1681 option will be handled by an implementation. See Section 5.14. 1683 5.12. Keepalive Message Format 1685 This message format is defined in [8]. 1687 The message is used to ensure that when a peer is sending ULP packets 1688 on a context, it always receives some packets in the reverse 1689 direction. When the ULP is sending bidirectional traffic, no extra 1690 packets need to be inserted. But for a unidirectional ULP traffic 1691 pattern, the shim will send back some Keepalive messages when it is 1692 receiving ULP packets. 1694 5.13. Probe Message Format 1696 This message and its semantics are defined in [8]. 1698 The idea behind that mechanism is to be able to handle the case when 1699 one locator pair works in from A to B, and another locator pair works 1700 from B to A, but there is no locator pair which works in both 1701 directions. The protocol mechanism is that as A is sending probe 1702 messages to B, B will observe which locator pairs it has received 1703 from and report that back in probe messages it is sending to A. 1705 5.14. Option Formats 1707 The format of the options is a snapshot of the current HIP option 1708 format [25]. However, there is no intention to track any changes to 1709 the HIP option format, nor is there an intent to use the same name 1710 space for the option type values. But using the same format will 1711 hopefully make it easier to import HIP capabilities into shim6 as 1712 extensions to shim6, should this turn out to be useful. 1714 All of the TLV parameters have a length (including Type and Length 1715 fields) which is a multiple of 8 bytes. When needed, padding MUST be 1716 added to the end of the parameter so that the total length becomes a 1717 multiple of 8 bytes. This rule ensures proper alignment of data. If 1718 padding is added, the Length field MUST NOT include the padding. Any 1719 added padding bytes MUST be zeroed by the sender, and their values 1720 SHOULD NOT be checked by the receiver. 1722 Consequently, the Length field indicates the length of the Contents 1723 field (in bytes). The total length of the TLV parameter (including 1724 Type, Length, Contents, and Padding) is related to the Length field 1725 according to the following formula: 1727 Total Length = 11 + Length - (Length + 3) % 8; 1729 0 1 2 3 1730 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 1731 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1732 | Type |C| Length | 1733 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1734 ~ ~ 1735 ~ Contents ~ 1736 ~ +-+-+-+-+-+-+-+-+ 1737 ~ | Padding | 1738 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1740 Fields: 1742 Type: 15-bit identifier of the type of option. The options 1743 defined in this document are below. 1745 C: Critical. One if this parameter is critical, and MUST 1746 be recognized by the recipient, zero otherwise. An 1747 implementation might view the C bit as part of the 1748 Type field, by multiplying the type values in this 1749 specification by two. 1751 Length: Length of the Contents, in bytes. 1753 Contents: Parameter specific, defined by Type. 1755 Padding: Padding, 0-7 bytes, added if needed. 1757 +------+---------------------------------+ 1758 | Type | Option Name | 1759 +------+---------------------------------+ 1760 | 1 | Responder Validator | 1761 | | | 1762 | 2 | Locator List | 1763 | | | 1764 | 3 | Locator Preferences | 1765 | | | 1766 | 4 | CGA Parameter Data Structure | 1767 | | | 1768 | 5 | CGA Signature | 1769 | | | 1770 | 6 | ULID Pair | 1771 | | | 1772 | 7 | Forked Instance Identifier | 1773 | | | 1774 | 10 | Probe Option | 1775 | | | 1776 | 11 | Reachability Option | 1777 | | | 1778 | 12 | Payload Reception Report Option | 1779 +------+---------------------------------+ 1781 Table 2 1783 Future protocol extensions might define additional options for the 1784 SHIM6 messages. The C-bit in the option format defines how such a 1785 new option will be handled by an implementation. 1787 If a host receives an option that it does not understand (an option 1788 that was defined in some future extension to this protocol) or is not 1789 listed as a valid option for the different message types above, then 1790 the Critical bit in the option determines the outcome. 1792 o If C=0 then the option is silently ignored, and the rest of the 1793 message is processed. 1795 o If C=1 then the host SHOULD send back an ICMP parameter problem 1796 (type 4, code 1), with the Pointer referencing the first octet in 1797 the option Type field. When C=1 the message MUST NOT be 1798 processed. 1800 5.14.1. Responder Validator Option Format 1802 The responder can choose exactly what input is used to compute the 1803 validator, and what one-way function (MD5, SHA1) it uses, as long as 1804 the responder can check that the validator it receives back in the I2 1805 or I2bis message is indeed one that: 1807 1)- it computed, 1809 2)- it computed for the particular context, and 1811 3)- that it isn't a replayed I2/I2bis message. 1813 Some suggestions on how to generate the validators are captured in 1814 Section 7.10.1 and Section 7.17.1. 1816 0 1 2 3 1817 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 1818 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1819 | Type = 1 |0| Length | 1820 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1821 ~ Validator ~ 1822 ~ +-+-+-+-+-+-+-+-+ 1823 ~ | Padding | 1824 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1826 Fields: 1828 Validator: Variable length content whose interpretation is local 1829 to the responder. 1831 Padding: Padding, 0-7 bytes, added if needed. See 1832 Section 5.14. 1834 5.14.2. Locator List Option Format 1836 The Locator List Option is used to carry all the locators of the 1837 sender. Note that the order of the locators is important, since the 1838 Locator Preferences refers to the locators by using the index in the 1839 list. 1841 Note that we carry all the locators in this option even though some 1842 of them can be created automatically from the CGA Parameter Data 1843 Structure. 1845 0 1 2 3 1846 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 1847 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1848 | Type = 2 |0| Length | 1849 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1850 | Locator List Generation | 1851 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1852 | Num Locators | N Octets of Verification Method | 1853 +-+-+-+-+-+-+-+-+ | 1854 ~ ~ 1855 ~ +-+-+-+-+-+-+-+-+ 1856 ~ | Padding | 1857 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1858 ~ Locators 1 through N ~ 1859 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1861 Fields: 1863 Locator List Generation: 32-bit unsigned integer. Indicates a 1864 generation number which is increased by one for each 1865 new locator list. This is used to ensure that the 1866 index in the Locator Preferences refer to the right 1867 version of the locator list. 1869 Num Locators: 8-bit unsigned integer. The number of locators that 1870 are included in the option. We call this number "N" 1871 below. 1873 Verification Method: N octets. The i'th octet specifies the 1874 verification method for the i'th locator. 1876 Padding: Padding, 0-7 bytes, added if needed so that the 1877 Locators start on a multiple of 8 octet boundary. 1878 NOTE that for this option there is never a need to pad 1879 at the end, since the locators are a multiple of 8 1880 octets in length. This internal padding is included 1881 in the length field. 1883 Locators: N 128-bit locators. 1885 The defined verification methods are: 1887 +-------+----------+ 1888 | Value | Method | 1889 +-------+----------+ 1890 | 0 | Reserved | 1891 | | | 1892 | 1 | HBA | 1893 | | | 1894 | 2 | CGA | 1895 | | | 1896 | 3-255 | Reserved | 1897 +-------+----------+ 1899 Table 3 1901 5.14.3. Locator Preferences Option Format 1903 The Locator Preferences option can have some flags to indicate 1904 whether or not a locator is known to work. In addition, the sender 1905 can include a notion of preferences. It might make sense to define 1906 "preferences" as a combination of priority and weight the same way 1907 that DNS SRV records has such information. The priority would 1908 provide a way to rank the locators, and within a given priority, the 1909 weight would provide a way to do some load sharing. See [9] for how 1910 SRV defines the interaction of priority and weight. 1912 The minimum notion of preferences we need is to be able to indicate 1913 that a locator is "dead". We can handle this using a single octet 1914 flag for each locator. 1916 We can extend that by carrying a larger "element" for each locator. 1917 This document presently also defines 2-octet and 3-octet elements, 1918 and we can add more information by having even larger elements if 1919 need be. 1921 The locators are not included in the preference list. Instead, the 1922 first element refers to locator that was in the first element in the 1923 Locator List option. The generation number carried in this option 1924 and the Locator List option is used to verify that they refer to the 1925 same version of the locator list. 1927 0 1 2 3 1928 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 1929 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1930 | Type = 3 |0| Length | 1931 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1932 | Locator List Generation | 1933 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1934 | Element Len | Element[1] | Element[2] | Element[3] | 1935 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1936 ~ ... ~ 1937 ~ +-+-+-+-+-+-+-+-+ 1938 ~ | Padding | 1939 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1941 Case of Element Len = 1 is depicted. 1943 Fields: 1945 Locator List Generation: 32-bit unsigned integer. Indicates a 1946 generation number for the locator list to which the 1947 elements should apply. 1949 Element Len: 8-bit unsigned integer. The length in octets of each 1950 element. This specification defines the cases when 1951 the length is 1, 2, or 3. 1953 Element[i]: A field with a number of octets defined by the Element 1954 Len field. Provides preferences for the i'th locator 1955 in the Locator List option that is in use. 1957 Padding: Padding, 0-7 bytes, added if needed. See 1958 Section 5.14. 1960 When the Element length equals one, then the element consists of only 1961 a one octet flags field. The currently defined set of flags are: 1963 BROKEN: 0x01 1965 TEMPORARY: 0x02 1967 The intent of TEMPORARY is to allow the distinction between more 1968 stable addresses and less stable addresses when shim6 is combined 1969 with IP mobility, when we might have more stable home locators, and 1970 less stable care-of-locators. 1972 When the Element length equals two, then the element consists of a 1 1973 octet flags field followed by a 1 octet priority field. The priority 1974 has the same semantics as the priority in DNS SRV records. 1976 When the Element length equals three, then the element consists of a 1977 1 octet flags field followed by a 1 octet priority field, and a 1 1978 octet weight field. The weight has the same semantics as the weight 1979 in DNS SRV records. 1981 This document doesn't specify the format when the Element length is 1982 more than three, except that any such formats MUST be defined so that 1983 the first three octets are the same as in the above case, that is, a 1984 of a 1 octet flags field followed by a 1 octet priority field, and a 1985 1 octet weight field. 1987 5.14.4. CGA Parameter Data Structure Option Format 1989 This option contains the CGA Parameter Data Structure (PDS). When 1990 HBA is used to verify the locators, the PDS contains the HBA 1991 multiprefix extension. When CGA is used to verify the locators, in 1992 addition to the PDS option, the host also needs to include the 1993 signature in the form of a CGA Signature option. 1995 0 1 2 3 1996 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 1997 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1998 | Type = 4 |0| Length | 1999 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2000 ~ CGA Parameter Data Structure ~ 2001 ~ +-+-+-+-+-+-+-+-+ 2002 ~ | Padding | 2003 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2005 Fields: 2007 CGA Parameter Data Structure: Variable length content. Content 2008 defined in [6] and [7]. 2010 Padding: Padding, 0-7 bytes, added if needed. See 2011 Section 5.14. 2013 5.14.5. CGA Signature Option Format 2015 When CGA is used for verification of one or more of the locators in 2016 the Locator List option, then the message in question will need to 2017 contain this option. 2019 0 1 2 3 2020 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 2021 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2022 | Type = 5 |0| Length | 2023 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2024 ~ CGA Signature ~ 2025 ~ +-+-+-+-+-+-+-+-+ 2026 ~ | Padding | 2027 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2029 Fields: 2031 CGA Signature: A variable-length field containing a PKCS#1 v1.5 2032 signature, constructed by using the sender's private 2033 key over the following sequence of octets: 2035 1. The 128-bit CGA Message Type tag [CGA] value for 2036 SHIM6, 0x4A 30 5662 4858 574B 3655 416F 506A 6D48. 2037 (The tag value has been generated randomly by the 2038 editor of this specification.). 2040 2. The Locator List Generation value of the 2041 correspondent Locator List Option. 2043 3. The subset of locators included in the 2044 correspondent Locator List Option which 2045 verification method is set to CGA. The locators 2046 MUST be included in the order they are listed in 2047 the Locator List Option. 2049 Padding: Padding, 0-7 bytes, added if needed. See 2050 Section 5.14. 2052 5.14.6. ULID Pair Option Format 2054 I1, I2, and I2bis messages MUST contain the ULID pair; normally this 2055 is in the IPv6 source and destination fields. In case that the ULID 2056 for the context differ from the address pair included in the source 2057 and destination address fields of the IPv6 packet used to carry the 2058 I1/I2/I2bis message, the ULID pair option MUST be included in the I1/ 2059 I2/I2bis message. 2061 0 1 2 3 2062 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 2063 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2064 | Type = 6 |0| Length = 36 | 2065 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2066 | Reserved2 | 2067 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2068 | | 2069 + Sender ULID + 2070 | | 2071 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2072 | | 2073 + Receiver ULID + 2074 | | 2075 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2077 Fields: 2079 Reserved2: 32-bit field. Reserved for future use. Zero on 2080 transmit. MUST be ignored on receipt. (Needed to 2081 make the ULIDs start on a multiple of 8 octet 2082 boundary.) 2084 Sender ULID: A 128-bit IPv6 address. 2086 Receiver ULID: A 128-bit IPv6 address. 2088 5.14.7. Forked Instance Identifier Option Format 2090 0 1 2 3 2091 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 2092 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2093 | Type = 7 |0| Length = 4 | 2094 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2095 | Forked Instance Identifier | 2096 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2098 Fields: 2100 Forked Instance Identifier: 32-bit field containing the identifier of 2101 the particular forked instance. 2103 5.14.8. Probe Option Format 2105 This option is defined in [8]. 2107 5.14.9. Reachability Option Format 2109 This option is defined in [8]. 2111 5.14.10. Payload Reception Report Option Format 2113 This option is defined in [8]. 2115 6. Conceptual Model of a Host 2117 This section describes a conceptual model of one possible data 2118 structure organization that hosts will maintain for the purposes of 2119 shim6. The described organization is provided to facilitate the 2120 explanation of how the shim6 protocol should behave. This document 2121 does not mandate that implementations adhere to this model as long as 2122 their external behavior is consistent with that described in this 2123 document. 2125 6.1. Conceptual Data Structures 2127 The key conceptual data structure for the shim6 protocol is the ULID 2128 pair context. This is a data structure which contains the following 2129 information: 2131 o The state of the context. See Section 6.2. 2133 o The peer ULID; ULID(peer) 2135 o The local ULID; ULID(local) 2137 o The Forked Instance Identifier; FII. This is zero for the default 2138 context i.e., when there is no forking. 2140 o The list of peer locators, with their preferences; Ls(peer) 2142 o The generation number for the most recently received, verified 2143 peer locator list. 2145 o For each peer locator, the verification method to use (from the 2146 Locator List option). 2148 o For each peer locator, a bit whether it has been verified using 2149 HBA or CGA, and a bit whether the locator has been probed to 2150 verify that the ULID is present at that location. 2152 o The preferred peer locator - used as destination; Lp(peer) 2154 o The set of local locators and the preferences; Ls(local) 2156 o The generation number for the most recently sent Locator List 2157 option. 2159 o The preferred local locator - used as source; Lp(local) 2161 o The context tag used to transmit control messages and payload 2162 extension headers - allocated by the peer; CT(peer) 2164 o The context to expect in received control messages and payload 2165 extension headers - allocated by the local host; CT(local) 2167 o Timers for retransmission of the messages during context 2168 establishment and update messages. 2170 o Depending how an implementation determines whether a context is 2171 still in use, there might be a need to track the last time a 2172 packet was sent/received using the context. 2174 o Reachability state for the locator pairs as specified in [8]. 2176 o During pair exploration, information about the probe messages that 2177 have been sent and received as specified in [8]. 2179 6.2. Context States 2181 The states that are used to describe the shim6 protocol are as 2182 follows: 2184 +---------------------+---------------------------------------------+ 2185 | State | Explanation | 2186 +---------------------+---------------------------------------------+ 2187 | IDLE | State machine start | 2188 | | | 2189 | I1-SENT | Initiating context establishment exchange | 2190 | | | 2191 | I2-SENT | Waiting to complete context establishment | 2192 | | exchange | 2193 | | | 2194 | I2BIS-SENT | Potential context loss detected | 2195 | | | 2196 | | | 2197 | ESTABLISHED | SHIM context established | 2198 | | | 2199 | E-FAILED | Context establishment exchange failed | 2200 | | | 2201 | NO-SUPPORT | ICMP Unrecognized Next Header type | 2202 | | (type 4, code 1) received indicating | 2203 | | that shim6 is not supported | 2204 +---------------------+---------------------------------------------+ 2205 In addition, in each of the aforementioned states, the following 2206 state information is stored: 2208 +---------------------+---------------------------------------------+ 2209 | State | Information | 2210 +---------------------+---------------------------------------------+ 2211 | IDLE | None | 2212 | | | 2213 | I1-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2214 | | INIT nonce, Lp(local), Lp(peer), Ls(local) | 2215 | | | 2216 | I2-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2217 | | INIT nonce, RESP nonce, Lp(local), Lp(peer),| 2218 | | Ls(local) | 2219 | | | 2220 | ESTABLISHED | ULID(peer), ULID(local), [FII], CT(local), | 2221 | | CT(peer), Lp(local), Lp(peer), Ls(local) | 2222 | | Ls(peer), INIT nonce?(to receive late R2) | 2223 | | | 2224 | I2BIS-SENT | ULID(peer), ULID(local), [FII], CT(local), | 2225 | | CT(peer), Lp(local), Lp(peer), Ls(local) | 2226 | | Ls(peer), CT(R1bis) | 2227 | | | 2228 | E-FAILED | ULID(peer), ULID(local) | 2229 | | | 2230 | NO-SUPPORT | ULID(peer), ULID(local) | 2231 +---------------------+---------------------------------------------+ 2233 7. Establishing ULID-Pair Contexts 2235 ULID-pair contexts are established using a 4-way exchange, which 2236 allows the responder to avoid creating state on the first packet. As 2237 part of this exchange each end allocates a context tag, and it shares 2238 this context tag and its set of locators with the peer. 2240 In some cases the 4-way exchange is not necessary, for instance when 2241 both ends try to setup the context at the same time, or when 2242 recovering from a context that has been garbage collected or lost at 2243 one of the hosts. 2245 7.1. Uniqueness of Context Tags 2247 As part of establishing a new context, each host has to assign a 2248 unique context tag. Since the Payload Extension headers are 2249 demultiplexed based solely on the context tag value (without using 2250 the locators), the context tag MUST be unique for each context. 2252 In addition, in order to minimize the reuse of context tags, the host 2253 SHOULD randomly cycle through the 2^47 context tag values,(e.g. 2254 following the guidelines described in [17]). 2256 7.2. Locator Verification 2258 The peer's locators might need to be verified during context 2259 establishment as well as when handling locator updates in Section 10. 2261 There are two separate aspects of locator verification. One is to 2262 verify that the locator is tied to the ULID, i.e., that the host 2263 which "owns" the ULID is also the one that is claiming the locator 2264 "ownership". The shim6 protocol uses the HBA or CGA techniques for 2265 doing this verification. The other is to verify that the host is 2266 indeed reachable at the claimed locator. Such verification is needed 2267 both to make sure communication can proceed, but also to prevent 3rd 2268 party flooding attacks [19]. These different verifications happen at 2269 different times, since the first might need to be performed before 2270 packets can be received by the peer with the source locator in 2271 question, but the latter verification is only needed before packets 2272 are sent to the locator. 2274 Before a host can use a locator (different than the ULID) as the 2275 source locator, it must know that the peer will accept packets with 2276 that source locator as being part of this context. Thus the HBA/CGA 2277 verification SHOULD be performed by the host before the host 2278 acknowledges the new locator, by sending an Update Acknowledgement 2279 message, or an R2 message. 2281 Before a host can use a locator (different than the ULID) as the 2282 destination locator it MUST perform the HBA/CGA verification if this 2283 was not performed before upon the reception of the locator set. In 2284 addition, it MUST verify that the ULID is indeed present at that 2285 locator. This verification is performed by doing a return- 2286 routability test as part of the Probe sub-protocol [8]. 2288 If the verification method in the Locator List option is not 2289 supported by the host, or if the verification method is not 2290 consistent with the CGA Parameter Data Structure (e.g., the Parameter 2291 Data Structure doesn't contain the multiprefix extension, and the 2292 verification method says to use HBA), then the host MUST ignore the 2293 Locator List and the message in which it is contained, and the host 2294 SHOULD generates an ICMP parameter problem (type 4, code 0), with the 2295 Pointer referencing the octet in the Verification method that was 2296 found inconsistent. 2298 7.3. Normal context establishment 2300 The normal context establishment consists of a 4 message exchange in 2301 the order of I1, R1, I2, R2 as can be seen in Figure 24. 2303 Initiator Responder 2305 IDLE IDLE 2306 ------------- I1 --------------> 2307 I1-SENT 2308 <------------ R1 --------------- 2309 IDLE 2310 ------------- I2 --------------> 2311 I2-SENT 2312 <------------ R2 --------------- 2313 ESTABLISHED ESTABLISHED 2315 Figure 24: Normal context establishment 2317 7.4. Concurrent context establishment 2319 When both ends try to initiate a context for the same ULID pair, then 2320 we might end up with crossing I1 messages. Alternatively, since no 2321 state is created when receiving the I1, a host might send a I1 after 2322 having sent a R1 message. 2324 Since a host remembers that it has sent an I1, it can respond to an 2325 I1 from the peer (for the same ULID-pair), with a R2, resulting in 2326 the message exchange shown in Figure 25. Such behavior is needed for 2327 other reasons such as to correctly respond to retransmitted I1 2328 messages, which occur when the R2 message has been lost. 2330 Host A Host B 2332 IDLE IDLE 2333 -\ 2334 I1-SENT---\ 2335 ---\ /--- 2336 --- I1 ---\ /--- I1-SENT 2337 ---\ 2338 /--- I1 ---/ ---\ 2339 /--- --> 2340 <--- 2342 -\ 2343 I1-SENT---\ 2344 ---\ /--- 2345 --- R2 ---\ /--- I1-SENT 2346 ---\ 2347 /--- R2 ---/ ---\ 2348 /--- --> 2349 <--- ESTABLISHED 2350 ESTABLISHED 2352 Figure 25: Crossing I1 messages 2354 If a host has received an I1 and sent an R1, it has no state to 2355 remember this. Thus if the ULP on the host sends down packets, this 2356 might trigger the host to send an I1 message itself. Thus while one 2357 end is sending an I1 the other is sending an I2 as can be seen in 2358 Figure 26. 2360 Host A Host B 2362 IDLE IDLE 2363 -\ 2364 ---\ 2365 I1-SENT ---\ 2366 --- I1 ---\ 2367 ---\ 2368 ---\ 2369 --> 2371 /--- 2372 /--- IDLE 2373 --- 2374 /--- R1--/ 2375 /--- 2376 <--- 2378 -\ 2379 I2-SENT---\ 2380 ---\ /--- 2381 --- I2---\ /--- I1-SENT 2382 ---\ 2383 /--- I1 ---/ ---\ 2384 /--- --> 2385 <--- ESTABLISHED 2387 -\ 2388 I2-SENT---\ 2389 ---\ /--- 2390 --- R2 ---\ /--- 2391 ---\ 2392 /--- R2 ---/ ---\ 2393 /--- --> 2394 <--- ESTABLISHED 2395 ESTABLISHED 2397 Figure 26: Crossing I2 and I1 2399 7.5. Context recovery 2401 Due to garbage collection, we can end up with one end having and 2402 using the context state, and the other end not having any state. We 2403 need to be able to recover this state at the end that has lost it, 2404 before we can use it. 2406 This need can arise in the following cases: 2408 o The communication is working using the ULID pair as the locator 2409 pair, but a problem arises, and the end that has retained the 2410 context state decides to probe alternate locator pairs. 2412 o The communication is working using a locator pair that is not the 2413 ULID pair, hence the ULP packets sent from a peer that has 2414 retained the context state use the shim6 Payload extension header. 2416 o The host that retained the state sends a control message (e.g. an 2417 Update Request message). 2419 In all the cases the result is that the peer without state receives a 2420 shim message for which it has to context for the context tag. 2422 In all of those cases we can recover the context by having the node 2423 which doesn't have a context state, send back an R1bis message, and 2424 have then complete the recovery with a I2bis and R2 message as can be 2425 seen in Figure 27. 2427 Host A Host B 2429 Context for 2430 CT(peer)=X Discards context for 2431 CT(local)=X 2433 ESTABLISHED IDLE 2435 ---- payload, probe, etc. -----> No context state 2436 for CT(local)=X 2438 <------------ R1bis ------------ 2439 IDLE 2441 ------------- I2bis -----------> 2442 I2BIS_SENT 2443 <------------ R2 --------------- 2444 ESTABLISHED ESTABLISHED 2446 Figure 27: Context loss at receiver 2448 If one end has garbage collected or lost the context state, it might 2449 try to create a new context state (for the same ULID pair), by 2450 sending an I1 message. The peer (that still has the context state) 2451 will reply with an R1 message and the full 4-way exchange will be 2452 performed again in this case as can be seen in Figure 28. 2454 Host A Host B 2456 Context for 2457 CT(peer)=X Discards context for 2458 ULIDs A1, B1 CT(local)=X 2460 ESTABLISHED IDLE 2462 Finds <------------ I1 --------------- Tries to setup 2463 existing for ULIDs A1, B1 2464 context, 2465 but CT(peer) I1-SENT 2466 doesn't match 2467 ------------- R1 ---------------> 2468 Left old context 2469 in ESTABLISHED 2471 <------------ I2 --------------- 2472 Recreate context 2474 with new CT(peer) I2-SENT 2475 and Ls(peer). 2477 ESTABLISHED 2478 ------------- R2 --------------> 2479 ESTABLISHED ESTABLISHED 2481 Figure 28: Context loss at sender 2483 7.6. Context confusion 2485 Since each end might garbage collect the context state we can have 2486 the case when one end has retained the context state and tries to use 2487 it, while the other end has lost the state. We discussed this in the 2488 previous section on recovery. But for the same reasons, when one 2489 host retains context tag X as CT(peer) for ULID pair , the 2490 other end might end up allocating that context tag as CT(local) for 2491 another ULID pair, e.g., between the same hosts. In this 2492 case we can not use the recovery mechanisms since there needs to be 2493 separate context tags for the two ULID pairs. 2495 This type of "confusion" can be observed in two cases (assuming it is 2496 A that has retained the state and B has dropped it): 2498 o B decides to create a context for ULID pair , and 2499 allocates X as its context tag for this, and sends an I1 to A. 2501 o A decides to create a context for ULID pair , and starts 2502 the exchange by sending I1 to B. When B receives the I2 message, 2503 it allocates X as the context tag for this context. 2505 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 . 2507 Thus A can detect that B must have lost the context for . 2509 The confusion can be detected when I2/I2bis/R2 is received since we 2510 require that those messages MUST include a sufficiently large set of 2511 locators in a Locator List option that the peer can determine whether 2512 or not two contexts have the same host as the peer by comparing if 2513 there is any common locators in Ls(peer). 2515 The requirement is that the old context which used the context tag 2516 MUST be removed; it can no longer be used to send packets. Thus A 2517 would forcibly remove the context state for , so that it 2518 can accept the new context for . An implementation MAY 2519 re-create a context to replace the one that was removed; in this case 2520 for . The normal I1, R1, I2, R2 establishment exchange would 2521 then pick unique context tags for that replacement context. This re- 2522 creation is OPTIONAL, but might be useful when there is ULP 2523 communication which is using the ULID pair whose context was removed. 2525 Note that an I1 message with a duplicate context tag should not cause 2526 the removal of the old context state; this operation needs to be 2527 deferred until the reception of the I2 message. 2529 7.7. Sending I1 messages 2531 When the shim layer decides to setup a context for a ULID pair, it 2532 starts by allocating and initializing the context state for its end. 2533 As part of this it assigns a random context tag to the context that 2534 is not being used as CT(local) by any other context . In the case 2535 that a new API is used and the ULP requests a forked context, the 2536 Forked Instance Identifier value will be set to a non-zero value. 2537 Otherwise, the FII value is zero. Then the initiator can send an I1 2538 message and set the context state to I1-SENT. The I1 message MUST 2539 include the ULID pair; normally in the IPv6 source and destination 2540 fields. But if the ULID pair for the context is not used as locator 2541 pair for the I1 message, then a ULID option MUST be included in the 2542 I1 message. In addition, if a Forked Instance Identifier value is 2543 non-zero, the I1 message MUST include a Context Instance Identifier 2544 option containing the correspondent value. 2546 7.8. Retransmitting I1 messages 2548 If the host does not receive an I2 or R2 message in response to the 2549 I1 message after I1_TIMEOUT time, then it needs to retransmit the I1 2550 message. The retransmissions should use a retransmission timer with 2551 binary exponential backoff to avoid creating congestion issues for 2552 the network when lots of hosts perform I1 retransmissions. Also, the 2553 actual timeout value should be randomized between 0.5 and 1.5 of the 2554 nominal value to avoid self-synchronization. 2556 If, after I1_RETRIES_MAX retransmissions, there is no response, then 2557 most likely the peer does not implement the shim6 protocol, or there 2558 could be a firewall that blocks the protocol. In this case it makes 2559 sense for the host to remember to not try again to establish a 2560 context with that ULID. However, any such negative caching should 2561 retained for at most NO_R1_HOLDDOWN_TIME, to be able to later setup a 2562 context should the problem have been that the host was not reachable 2563 at all when the shim tried to establish the context. 2565 If the host receives an ICMP error with "Unrecognized Next Header" 2566 type (type 4, code 1) and the included packet is the I1 message it 2567 just sent, then this is a more reliable indication that the peer ULID 2568 does not implement shim6. Again, in this case, the host should 2569 remember to not try again to establish a context with that ULID. 2570 Such negative caching should retained for at most ICMP_HOLDDOWN_TIME, 2571 which should be significantly longer than the previous case. 2573 7.9. Receiving I1 messages 2575 A host MUST silently discard any received I1 messages that do not 2576 satisfy all of the following validity checks in addition to those 2577 specified in Section 12.2: 2579 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2580 16 octets. 2582 Upon the reception of an I1 message, the host extracts the ULID pair 2583 and the Forked Instance Identifier from the message. If there is no 2584 ULID-pair option, then the ULID pair is taken from the source and 2585 destination fields in the IPv6 header. If there is no FII option in 2586 the message, then the FII value is taken to be zero. 2588 Next the host looks for an existing context which matches the ULID 2589 pair and the FII. 2591 If no state is found (i.e., the state is IDLE), then the host replies 2592 with a R1 message as specified below. 2594 If such a context exists in ESTABLISHED state, the host verifies that 2595 the locator of the Initiator is included in Ls(peer) (This check is 2596 unnecessary if there is no ULID-pair option in the I1 message). 2598 If the state exists in ESTABLISHED state and the locators do not fall 2599 in the locator sets, then the host replies with a R1 message as 2600 specified below. This completes the I1 processing, with the context 2601 state being unchanged. 2603 If the state exists in ESTABLISHED state and the locators do fall in 2604 the sets, then the host compares CT(peer) for the context with the CT 2605 contained in the I1 message. 2607 o If the context tags match, then this probably means that the R2 2608 message was lost and this I1 is a retransmission. In this case, 2609 the host replies with a R2 message containing the information 2610 available for the existent context. 2612 o If the context tags do not match, then it probably means that the 2613 Initiator has lost the context information for this context and it 2614 is trying to establish a new one for the same ULID-pair. In this 2615 case, the host replies with a R1 message as specified below. This 2616 completes the I1 processing, with the context state being 2617 unchanged. 2619 If the state exists in other state (I1-SENT, I2-SENT, I2BIS-SENT), we 2620 are in the situation of Concurrent context establishment described in 2621 Section 7.4. In this case, the host leaves CT(peer) unchanged, and 2622 replies with a R2 message. This completes the I1 processing, with 2623 the context state being unchanged. 2625 7.10. Sending R1 messages 2627 When the host needs to send a R1 message in response to the I1 2628 message, it copies the Initiator Nonce from the I1 message to the R1 2629 message, generates a Responder Nonce and calculates a Responder 2630 Validator option as suggested in the following section. No state is 2631 created on the host in this case.(Note that the information used to 2632 generate the R1 reply message is either contained in the received I1 2633 message or it is global information that is not associated with the 2634 particular requested context (the S and the Responder nonce values)). 2636 When the host needs to send a R2 message in response to the I1 2637 message, it copies the Initiator Nonce from the I1 message to the R2 2638 message, and otherwise follows the normal rules for forming an R2 2639 message (see Section 7.14). 2641 7.10.1. Generating the R1 Validator 2643 One way for the responder to properly generate validators is to 2644 maintain a single secret (S) and a running counter for the Responder 2645 Nonce. 2647 In the case the validator is generated to be included in a R1 2648 message, for each I1 message. The responder can increase the 2649 counter, use the counter value as the responder nonce, and use the 2650 following information as input to the one-way function: 2652 o The the secret S 2654 o That Responder Nonce 2656 o The Initiator Context Tag from the I1 message 2658 o The ULIDs from the I1 message 2660 o The locators from the I1 message (strictly only needed if they are 2661 different from the ULIDs) 2663 o The forked instance identifier if such option was included in the 2664 I1 message 2666 and then the output of the hash function is used as the validator 2667 octet string. 2669 7.11. Receiving R1 messages and sending I2 messages 2671 A host MUST silently discard any received R1 messages that do not 2672 satisfy all of the following validity checks in addition to those 2673 specified in Section 12.2: 2675 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2676 16 octets. 2678 Upon the reception of an R1 message, the host extracts the Initiator 2679 Nonce and the Locator Pair from the message (the latter from the 2680 source and destination fields in the IPv6 header). Next the host 2681 looks for an existing context which matches the Initiator Nonce and 2682 where the locators are contained in Ls(peer) and Ls(local), 2683 respectively. If no such context is found, then the R1 message is 2684 silently discarded. 2686 If such a context is found, then the host looks at the state: 2688 o If the state is I1-SENT, then it sends an I2 message as specified 2689 below. 2691 o In any other state (I2-SENT, I2BIS-SENT, ESTABLISHED) then the 2692 host has already sent an I2 message then this is probably a reply 2693 to a retransmitted I1 message, so this R1 message MUST be silently 2694 discarded. 2696 When the host sends an I2 message, then it includes the Responder 2697 Validator option that was in the R1 message. The I2 message MUST 2698 include the ULID pair; normally in the IPv6 source and destination 2699 fields. If a ULID-pair option was included in the I1 message then it 2700 MUST be included in the I2 message as well. In addition, if the 2701 Forked Instance Identifier value for this context is non-zero, the I2 2702 message MUST contain a Forked Instance Identifier Option carrying 2703 this value. Besides, the I2 message contains an Initiator Nonce. 2704 This is not required to be the same than the one included in the 2705 previous I1 message. 2707 The I2 message also includes the Initiator's locator list and the CGA 2708 parameter data structure. If CGA (and not HBA) is used to verify the 2709 locator list, then Initiator also signs the key parts of the message 2710 and includes a CGA signature option containing the signature. 2712 When the I2 message has been sent, the state is set to I2-SENT. 2714 7.12. Retransmitting I2 messages 2716 If the initiator does not receive an R2 message after I2_TIMEOUT time 2717 after sending an I2 message it MAY retransmit the I2 message, using 2718 binary exponential backoff and randomized timers. The Responder 2719 Validator option might have a limited lifetime, that is, the peer 2720 might reject Responder Validator options that are older than 2721 VALIDATOR_MIN_LIFETIME to avoid replay attacks. Thus the initiator 2722 SHOULD fall back to retransmitting the I1 message when there is no R2 2723 received after retransmitting the I2 message I2_RETRIES_MAX times. 2725 7.13. Receiving I2 messages 2727 A host MUST silently discard any received I2 messages that do not 2728 satisfy all of the following validity checks in addition to those 2729 specified in Section 12.2: 2731 o The Hdr Ext Len field is at least 2, i.e., the length is at least 2732 24 octets. 2734 Upon the reception of an I2 message, the host extracts the ULID pair 2735 and the Forked Instance identifier from the message. If there is no 2736 ULID-pair option, then the ULID pair is taken from the source and 2737 destination fields in the IPv6 header. If there is no FII option in 2738 the message, then the FII value is taken to be zero. 2740 Next the host verifies that the Responder Nonce is a recent one 2741 (Nonces that are no older than VALIDATOR_MIN_LIFETIME SHOULD be 2742 considered recent), and that the Responder Validator option matches 2743 the validator the host would have computed for the ULID, locators, 2744 responder nonce, and FII. 2746 If a CGA Parameter Data Structure (PDS) is included in the message, 2747 then the host MUST verify if the actual PDS contained in the message 2748 corresponds to the ULID(peer). 2750 If any of the above verifications fails, then the host silently 2751 discards the message and it has completed the I2 processing. 2753 If all the above verifications are successful, then the host proceeds 2754 to look for a context state for the Initiator. The host looks for a 2755 context with the extracted ULID pair and FII. If none exist then 2756 state of the (non-existing) context is viewed as being IDLE, thus the 2757 actions depend on the state as follows: 2759 o If the state is IDLE (i.e., the context does not exist) the host 2760 allocates a context tag (CT(local)), creates the context state for 2761 the context, and sets its state to ESTABLISHED. It records 2762 CT(peer), and the peer's locator set as well as its own locator 2763 set in the context. It SHOULD perform the HBA/CGA verification of 2764 the peer's locator set at this point in time, as specified in 2765 Section 7.2. Then the host sends an R2 message back as specified 2766 below. 2768 o If the state is I1-SENT, then the host verifies if the source 2769 locator is included in Ls(peer) or, it is included in the Locator 2770 List contained in the the I2 message and the HBA/CGA verification 2771 for this specific locator is successful 2773 * If this is not the case, then the message is silently discarded 2774 and the context state remains unchanged. 2776 * If this is the case, then the host updates the context 2777 information (CT(peer), Ls(peer)) with the data contained in the 2778 I2 message and the host MUST send a R2 message back as 2779 specified below. Note that before updating Ls(peer) 2780 information, the host SHOULD perform the HBA/CGA validation of 2781 the peer's locator set at this point in time as specified in 2782 Section 7.2. The host moves to ESTABLISHED state. 2784 o If the state is ESTABLISHED, I2-SENT, or I2BIS-SENT, then the host 2785 verifies if the source locator is included in Ls(peer) or, it is 2786 included in the Locator List contained in the the I2 message and 2787 the HBA/CGA verification for this specific locator is successful 2789 * If this is not the case, then the message is silently discarded 2790 and the context state remains unchanged. 2792 * If this is the case, then the host updates the context 2793 information (CT(peer), Ls(peer)) with the data contained in the 2794 I2 message and the host MUST send a R2 message back as 2795 specified in Section 7.14. Note that before updating Ls(peer) 2796 information, the host SHOULD perform the HBA/CGA validation of 2797 the peer's locator set at this point in time as specified in 2798 Section 7.2. The context state remains unchanged. 2800 7.14. Sending R2 messages 2802 Before the host sends the R2 message it MUST look for a possible 2803 context confusion i.e. where it would end up with multiple contexts 2804 using the same CT(peer) for the same peer host. See Section 7.15. 2806 When the host needs to send an R2 message, the host forms the message 2807 using its locators and its context tag, copies the Initiator Nonce 2808 from the triggering message (I2, I2bis, or I1), and includes the 2809 necessary options so that the peer can verify the locators. In 2810 particular, the R2 message includes the Responder's locator list and 2811 the PDS option. If CGA (and not HBA) is used to verify the locator 2812 list, then the Responder also signs the key parts of the message and 2813 includes a CGA Signature option containing the signature. 2815 R2 messages are never retransmitted. If the R2 message is lost, then 2816 the initiator will retransmit either the I2/I2bis or I1 message. 2817 Either retransmission will cause the responder to find the context 2818 state and respond with an R2 message. 2820 7.15. Match for Context Confusion 2822 When the host receives an I2, I2bis, or R2 it MUST look for a 2823 possible context confusion i.e. where it would end up with multiple 2824 contexts using the same CT(peer) for the same peer host. This can 2825 happen when it has received the above messages since they create a 2826 new context with a new CT(peer). Same issue applies when CT(peer) is 2827 updated for an existing context. 2829 The host takes CT(peer) for the newly created or updated context, and 2830 looks for other contexts which: 2832 o Are in state ESTABLISHED or I2BIS-SENT. 2834 o Have the same CT(peer). 2836 o Where Ls(peer) has at least one locator in common with the newly 2837 created or updated context. 2839 If such a context is found, then the host checks if the ULID pair or 2840 the Forked Instance Identifier different than the ones in the newly 2841 created or updated context: 2843 o If either or both are different, then the peer is reusing the 2844 context tag for the creation of a context with different ULID pair 2845 or FII, which is an indication that the peer has lost the original 2846 context. In this case, we are in the Context confusion situation, 2847 and the host MUST NOT use the old context to send any packets. It 2848 MAY just discard the old context (after all, the peer has 2849 discarded it), or it MAY attempt to re-establish the old context 2850 by sending a new I1 message and moving its state to I1-SENT. In 2851 any case, once that this situation is detected, the host MUST NOT 2852 keep two contexts with overlapping Ls(peer) locator sets and the 2853 same context tag in ESTABLISHED state, since this would result in 2854 demultiplexing problems on the peer. 2856 o If both are the same, then this context is actually the context 2857 that is created or updated, hence there is no confusion. 2859 7.16. Receiving R2 messages 2861 A host MUST silently discard any received R2 messages that do not 2862 satisfy all of the following validity checks in addition to those 2863 specified in Section 12.2: 2865 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2866 16 octets. 2868 Upon the reception of an R2 message, the host extracts the Initiator 2869 Nonce and the Locator Pair from the message (the latter from the 2870 source and destination fields in the IPv6 header). Next the host 2871 looks for an existing context which matches the Initiator Nonce and 2872 where the locators are Lp(peer) and Lp(local), respectively. Based 2873 on the state: 2875 o If no such context is found, i.e., the state is IDLE, then the 2876 message is silently dropped. 2878 o If state is I1-SENT, I2-SENT, or I2BIS-SENT then the host performs 2879 the following actions: If a CGA Parameter Data Structure (PDS) is 2880 included in the message, then the host MUST verify that the actual 2881 PDS contained in the message corresponds to the ULID(peer) as 2882 specified in Section 7.2. If the verification fails, then the 2883 message is silently dropped. If the verification succeeds, then 2884 the host records the information from the R2 message in the 2885 context state; it records the peer's locator set and CT(peer). 2886 The host SHOULD perform the HBA/CGA verification of the peer's 2887 locator set at this point in time, as specified in Section 7.2. 2889 The host sets its state to ESTABLISHED. 2891 o If the state is ESTABLISHED, the R2 message is silently ignored, 2892 (since this is likely to be a reply to a retransmitted I2 2893 message). 2895 Before the host completes the R2 processing it MUST look for a 2896 possible context confusion i.e. where it would end up with multiple 2897 contexts using the same CT(peer) for the same peer host. See 2898 Section 7.15. 2900 7.17. Sending R1bis messages 2902 Upon the receipt of a shim6 payload extension header where there is 2903 no current SHIM6 context at the receiver, the receiver is to respond 2904 with an R1bis message in order to enable a fast re-establishment of 2905 the lost SHIM6 context. 2907 Also a host is to respond with a R1bis upon receipt of any control 2908 messages that has a message type in the range 64-127 (i.e., excluding 2909 the context setup messages such as I1, R1, R1bis, I2, I2bis, R2 and 2910 future extensions), where the control message refers to a non 2911 existent context. 2913 We assume that all the incoming packets that trigger the generation 2914 of an R1bis message contain a locator pair (in the address fields of 2915 the IPv6 header) and a Context Tag. 2917 Upon reception of any of the packets described above, the host will 2918 reply with an R1bis including the following information: 2920 o The Responder Nonce is a number picked by the responder which the 2921 initiator will return in the I2bis message. 2923 o Packet Context Tag is the context tag contained in the received 2924 packet that triggered the generation of the R1bis message. 2926 o The Responder Validator option is included, with a validator that 2927 is computed as suggested in the next section. 2929 7.17.1. Generating the R1bis Validator 2931 One way for the responder to properly generate validators is to 2932 maintain a single secret (S) and a running counter for the Responder 2933 Nonce. 2935 In the case the validator is generated to be included in a R1bis 2936 message, for each received payload extension header or control 2937 message, the responder can increase the counter, use the counter 2938 value as the responder nonce, and use the following information as 2939 input to the one-way function: 2941 o The the secret S 2943 o That Responder Nonce 2945 o The Receiver Context tag included in the received packet 2947 o The locators from the received packet 2949 and then the output of the hash function is used as the validator 2950 octet string. 2952 7.18. Receiving R1bis messages and sending I2bis messages 2954 A host MUST silently discard any received R1bis messages that do not 2955 satisfy all of the following validity checks in addition to those 2956 specified in Section 12.2: 2958 o The Hdr Ext Len field is at least 1, i.e., the length is at least 2959 16 octets. 2961 Upon the reception of an R1bis message, the host extracts the Packet 2962 Context Tag and the Locator Pair from the message (the latter from 2963 the source and destination fields in the IPv6 header). Next the host 2964 looks for an existing context where the Packet Context Tag matches 2965 CT(peer) and where the locators match Lp(peer) and Lp(local), 2966 respectively. 2968 o If no such context is not found, i.e., the state is IDLE, then the 2969 R1bis message is silently discarded. 2971 o If the state is I1-SENT, I2-SENT, or I2BIS-SENT, then the R1bis 2972 message is silently discarded. 2974 o If the state is ESTABLISHED, then we are in the case where the 2975 peer has lost the context and the goal is to try to re-establish 2976 it. For that, the host leaves CT(peer) unchanged in the context 2977 state, transitions to I2BIS-SENT state, and sends a I2bis message, 2978 including the computed Responder Validator option, the Packet 2979 Context Tag, and the Responder Nonce received in the R1bis 2980 message. This I2bis message is sent using the locator pair 2981 included in the R1bis message. In the case that this locator pair 2982 differs from the ULID pair defined for this context, then an ULID 2983 option MUST be included in the I2bis message. In addition, if the 2984 Forked Instance Identifier for this context is non-zero, then a 2985 Forked Instance Identifier option carrying the instance identifier 2986 value for this context MUST be included in the I2bis message. 2988 7.19. Retransmitting I2bis messages 2990 If the initiator does not receive an R2 message after I2bis_TIMEOUT 2991 time after sending an I2bis message it MAY retransmit the I2bis 2992 message, using binary exponential backoff and randomized timers. The 2993 Responder Validator option might have a limited lifetime, that is, 2994 the peer might reject Responder Validator options that are older than 2995 VALIDATOR_MIN_LIFETIME to avoid replay attacks. Thus the initiator 2996 SHOULD fall back to retransmitting the I1 message when there is no R2 2997 received after retransmitting the I2bis message I2bis_RETRIES_MAX 2998 times. 3000 7.20. Receiving I2bis messages and sending R2 messages 3002 A host MUST silently discard any received I2bis messages that do not 3003 satisfy all of the following validity checks in addition to those 3004 specified in Section 12.2: 3006 o The Hdr Ext Len field is at least 3, i.e., the length is at least 3007 32 octets. 3009 Upon the reception of an I2bis message, the host extracts the ULID 3010 pair and the Forked Instance identifier from the message. If there 3011 is no ULID-pair option, then the ULID pair is taken from the source 3012 and destination fields in the IPv6 header. If there is no FII option 3013 in the message, then the FII value is taken to be zero. 3015 Next the host verifies that the Responder Nonce is a recent one 3016 (Nonces that are no older than VALIDATOR_MIN_LIFETIME SHOULD be 3017 considered recent), and that the Responder Validator option matches 3018 the validator the host would have computed for the ULID, locators, 3019 responder nonce, and FII as part of sending an R1bis message. 3021 If a CGA Parameter Data Structure (PDS) is included in the message, 3022 then the host MUST verify if the actual PDS contained in the message 3023 corresponds to the ULID(peer). 3025 If any of the above verifications fails, then the host silently 3026 discard the message and it has completed the I2bis processing. 3028 If both verifications are successful, then the host proceeds to look 3029 for a context state for the Initiator. The host looks for a context 3030 with the extracted ULID pair and FII. If none exist then state of 3031 the (non-existing) context is viewed as being IDLE, thus the actions 3032 depend on the state as follows: 3034 o If the state is IDLE (i.e., the context does not exist) the host 3035 allocates a context tag (CT(local)), creates the context state for 3036 the context, and sets its state to ESTABLISHED. The host SHOULD 3037 NOT use the Packet Context Tag in the I2bis message for CT(local); 3038 instead it should pick a new random context tag just as when it 3039 processes an I2 message. It records CT(peer), and the peer's 3040 locator set as well as its own locator set in the context. It 3041 SHOULD perform the HBA/CGA verification of the peer's locator set 3042 at this point in time as specified in Section 7.2. Then the host 3043 sends an R2 message back as specified in Section 7.14. 3045 o If the state is I1-SENT, then the host verifies if the source 3046 locator is included in Ls(peer) or, it is included in the Locator 3047 List contained in the the I2 message and the HBA/CGA verification 3048 for this specific locator is successful 3050 * If this is not the case, then the message is silently 3051 discarded. The the context state remains unchanged. 3053 * If this is the case, then the host updates the context 3054 information (CT(peer), Ls(peer)) with the data contained in the 3055 I2 message and the host MUST send a R2 message back as 3056 specified below. Note that before updating Ls(peer) 3057 information, the host SHOULD perform the HBA/CGA validation of 3058 the peer's locator set at this point in time as specified in 3059 Section 7.2. The host moves to ESTABLISHED state. 3061 o If the state is ESTABLISHED, I2-SENT, or I2BIS-SENT, then the host 3062 verifies if the source locator is included in Ls(peer) or, it is 3063 included in the Locator List contained in the the I2 message and 3064 the HBA/CGA verification for this specific locator is successful 3066 * If this is not the case, then the message is silently 3067 discarded. The the context state remains unchanged. 3069 * If this is the case, then the host updates the context 3070 information (CT(peer), Ls(peer)) with the data contained in the 3071 I2 message and the host MUST send a R2 message back as 3072 specified in Section 7.14. Note that before updating Ls(peer) 3073 information, the host SHOULD perform the HBA/CGA validation of 3074 the peer's locator set at this point in time as specified in 3075 Section 7.2. The context state remains unchanged. 3077 8. Handling ICMP Error Messages 3079 The routers in the path as well as the destination might generate 3080 various ICMP error messages, such as host unreachable, packet too 3081 big, and Unrecognized Next Header type. It is critical that these 3082 packets make it back up to the ULPs so that they can take appropriate 3083 action. 3085 This is an implementation issue in the sense that the mechanism is 3086 completely local to the host itself. But the issue of how ICMP 3087 errors are correctly dispatched to the ULP on the host are important, 3088 hence this section specifies the issue. 3090 +--------------+ 3091 | IPv6 Header | 3092 | | 3093 +--------------+ 3094 | ICMPv6 | 3095 | Header | 3096 - - +--------------+ - - 3097 | IPv6 Header | 3098 | src, dst as | Can be dispatched 3099 IPv6 | sent by ULP | unmodified to ULP 3100 | on host | ICMP error handler 3101 Packet +--------------+ 3102 | ULP | 3103 in | Header | 3104 +--------------+ 3105 Error | | 3106 ~ Data ~ 3107 | | 3108 - - +--------------+ - - 3110 Figure 29: ICMP error handling without payload extension header 3112 When the ULP packets are sent without the payload extension header, 3113 that is, while the initial locators=ULIDs are working, this 3114 introduces no new concerns; an implementation's existing mechanism 3115 for delivering these errors to the ULP will work. See Figure 29. 3117 But when the shim on the transmitting side inserts the payload 3118 extension header and replaces the ULIDs in the IP address fields with 3119 some other locators, then an ICMP error coming back will have a 3120 "packet in error" which is not a packet that the ULP sent. Thus the 3121 implementation will have to apply the reverse mapping to the "packet 3122 in error" before passing the ICMP error up to the ULP. See 3123 Figure 30. 3125 +--------------+ 3126 | IPv6 Header | 3127 | | 3128 +--------------+ 3129 | ICMPv6 | 3130 | Header | 3131 - - +--------------+ - - 3132 | IPv6 Header | 3133 | src, dst as | Needs to be 3134 IPv6 | modified by | transformed to 3135 | shim on host | have ULIDs 3136 +--------------+ in src, dst fields, 3137 Packet | SHIM6 ext. | and SHIM6 ext. 3138 | Header | header removed 3139 in +--------------+ before it can be 3140 | Transport | dispatched to the ULP 3141 Error | Header | ICMP error handler. 3142 +--------------+ 3143 | | 3144 ~ Data ~ 3145 | | 3146 - - +--------------+ - - 3148 Figure 30: ICMP error handling with payload extension header 3150 Note that this mapping is different than when receiving packets from 3151 the peer with a payload extension headers, because in that case the 3152 packets contain CT(local). But the ICMP errors have a "packet in 3153 error" with an payload extension header containing CT(peer). This is 3154 because they were intended to be received by the peer. In any case, 3155 since the has to be 3156 unique when received by the peer, the local host should also only be 3157 able to find one context that matches this tuple. 3159 If the ICMP error is a Packet Too Big, the reported MTU must be 3160 adjusted to be 8 octets less, since the shim will add 8 octets when 3161 sending packets. 3163 After the "packet in error" has had the original ULIDs inserted, then 3164 this payload extension header can be removed. The result is a 3165 "packet in error" that is passed to the ULP which looks as if the 3166 shim did not exist. 3168 9. Teardown of the ULID-Pair Context 3170 Each host can unilaterally decide when to tear down a ULID-pair 3171 context. It is RECOMMENDED that hosts do not tear down the context 3172 when they know that there is some upper layer protocol that might use 3173 the context. For example, an implementation might know this if there 3174 is an open socket which is connected to the ULID(peer). However, 3175 there might be cases when the knowledge is not readily available to 3176 the shim layer, for instance for UDP applications which do not 3177 connect their sockets, or any application which retains some higher 3178 level state across (TCP) connections and UDP packets. 3180 Thus it is RECOMMENDED that implementations minimize premature 3181 teardown by observing the amount of traffic that is sent and received 3182 using the context, and only after it appears quiescent, tear down the 3183 state. A reasonable approach would be not to tear down a context 3184 until at least 5 minutes have passed since the last message was sent 3185 or received using the context. 3187 Since there is no explicit, coordinated removal of the context state, 3188 there are potential issues around context tag reuse. One end might 3189 remove the state, and potentially reuse that context tag for some 3190 other communication, and the peer might later try to use the old 3191 context (which it didn't remove). The protocol has mechanisms to 3192 recover from this, which work whether the state removal was total and 3193 accidental (e.g., crash and reboot of the host), or just a garbage 3194 collection of shim state that didn't seem to be used. However, the 3195 host should try to minimize the reuse of context tags by trying to 3196 randomly cycle through the 2^47 context tag values. (See Appendix C 3197 for a summary how the recovery works in the different cases.) 3199 10. Updating the Peer 3201 The Update Request and Acknowledgement are used both to update the 3202 list of locators (only possible when CGA is used to verify the 3203 locator(s)), as well as updating the preferences associated with each 3204 locator. 3206 10.1. Sending Update Request messages 3208 When a host has a change in the locator set, then it can communicate 3209 this to the peer by sending an Update Request. When a host has a 3210 change in the preferences for its locator set, it can also 3211 communicate this to the peer. The Update Request message can include 3212 just a Locator List option, to convey the new set of locators (which 3213 requires a CGA signature option as well), just a Locator Preferences 3214 option, or both a new Locator List and new Locator Preferences. 3216 Should the host send a new Locator List, the host picks a new random 3217 local generation number, records this in the context, and puts it in 3218 the Locator List option. Any Locator Preference option, whether send 3219 in the same Update Request or in some future Update Request, will use 3220 that generation number to make sure the preferences get applied to 3221 the correct version of the locator list. 3223 The host picks a random Request Nonce for each update, and keeps the 3224 same nonce for any retransmissions of the Update Request. The nonce 3225 is used to match the acknowledgement with the request. 3227 10.2. Retransmitting Update Request messages 3229 If the host does not receive an Update Acknowledgement R2 message in 3230 response to the Update Request message after UPDATE_TIMEOUT time, 3231 then it needs to retransmit the Update Request message. The 3232 retransmissions should use a retransmission timer with binary 3233 exponential backoff to avoid creating congestion issues for the 3234 network when lots of hosts perform Update Request retransmissions. 3235 Also, the actual timeout value should be randomized between 0.5 and 3236 1.5 of the nominal value to avoid self-synchronization. 3238 Should there be no response, the retransmissions continue forever. 3239 The binary exponential backoff stops at MAX_UPDATE_TIMEOUT. But the 3240 only way the retransmissions would stop when there is no 3241 acknowledgement, is when the shim, through the Probe protocol or some 3242 other mechanism, decides to discard the context state due to lack of 3243 ULP usage in combination with no responses to the Probes. 3245 10.3. Newer Information While Retransmitting 3247 There can be at most one outstanding Update Request message at any 3248 time. Thus until e.g. an update with a new Locator List has been 3249 acknowledged, any even newer Locator List or new Locator Preferences 3250 can not just be sent. However, when there is newer information and 3251 the older information has not yet been acknowledged, the host can 3252 instead of waiting for an acknowledgement, abandon the previous 3253 update and construct a new Update Request (with a new Request Nonce) 3254 which includes the new information as well as the information that 3255 hadn't yet been acknowledged. 3257 For example, if the original locator list was just (A1, A2), and if 3258 an Update Request with the Locator List (A1, A3) is outstanding, and 3259 the host determines that it should both add A4 to the locator list, 3260 and mark A1 as BROKEN, then it would need to: 3262 o Pick a new random Request Nonce for the new Update Request. 3264 o Pick a new random Generation number for the new locator list. 3266 o Form the new locator list - (A1, A3, A4) 3268 o Form a Locator Preference option which uses the new generation 3269 number and has the BROKEN flag for the first locator. 3271 o Send the Update Request and start a retransmission timer. 3273 Any Update Acknowledgement which doesn't match the current request 3274 nonce, for instance an acknowledgement for the abandoned Update 3275 Request, will be silently ignored. 3277 10.4. Receiving Update Request messages 3279 A host MUST silently discard any received Update Request messages 3280 that do not satisfy all of the following validity checks in addition 3281 to those specified in Section 12.2: 3283 o The Hdr Ext Len field is at least 1, i.e., the length is at least 3284 16 octets. 3286 Upon the reception of an Update Request message, the host extracts 3287 the Context Tag from the message. It then looks for a context which 3288 has a CT(local) that matches the context tag. If no such context is 3289 found, it sends a R1bis message as specified in Section 7.17. 3291 Since context tags can be reused, the host MUST verify that the IPv6 3292 source address field is part of Ls(peer) and that the IPv6 3293 destination address field is part of Ls(local). If this is not the 3294 case, the sender of the Update Request has a stale context which 3295 happens to match the CT(local) for this context. In this case the 3296 host MUST send a R1bis message, and otherwise ignore the Update 3297 Request message. 3299 If a CGA Parameter Data Structure (PDS) is included in the message, 3300 then the host MUST verify if the actual PDS contained in the packet 3301 corresponds to the ULID(peer). If this verification fails, the 3302 message is silently discarded. 3304 Then, depending on the state of the context: 3306 o If ESTABLISHED: Proceed to process message. 3308 o If I1-SENT, discard the message and stay in I1-SENT. 3310 o If I2-SENT, then send R2 and proceed to process the message. 3312 o If I2BIS-SENT, then send R2 and proceed to process the message. 3314 The verification issues for the locators carried in the Locator 3315 Update message are specified in Section 7.2. If the locator list can 3316 not be verified, this procedure might send an ICMP Parameter Problem 3317 error. In any case, if it can not be verified, there is no further 3318 processing of the Update Request. 3320 Once any Locator List option in the Update Request has been verified, 3321 the peer generation number in the context is updated to be the one in 3322 the Locator List option. 3324 If the Update message contains a Locator Preference option, then the 3325 Generation number in the preference option is compared with the peer 3326 generation number in the context. If they do not match, then the 3327 host generates an ICMP parameter problem (type 4, code 0) with the 3328 Pointer field referring to the first octet in the Generation number 3329 in the Locator Preference option. In addition, if the number of 3330 elements in the Locator Preference option does not match the number 3331 of locators in Ls(peer), then an ICMP parameter problem is sent with 3332 the Pointer referring to the first octet of the Length field in the 3333 Locator Preference option. In both cases of failures, no further 3334 processing is performed for the Locator Update message. 3336 If the generation number matches, the locator preferences are 3337 recorded in the context. 3339 Once the Locator List option (if present) has been verified and any 3340 new locator list or locator preferences have been recorded, the host 3341 sends an Update Acknowledgement message, copying the nonce from the 3342 request, and using the CT(peer) in as the Receiver Context Tag. 3344 Any new locators, or more likely new locator preferences, might 3345 result in the host wanting to select a different locator pair for the 3346 context. For instance, if the Locator Preferences lists the current 3347 Lp(peer) as BROKEN. The host uses the Probe message in [8] to verify 3348 that the new locator is reachable before changing Lp(peer). 3350 10.5. Receiving Update Acknowledgement messages 3352 A host MUST silently discard any received Update Acknowledgement 3353 messages that do not satisfy all of the following validity checks in 3354 addition to those specified in Section 12.2: 3356 o The Hdr Ext Len field is at least 1, i.e., the length is at least 3357 16 octets. 3359 Upon the reception of an Update Acknowledgement message, the host 3360 extracts the Context Tag and the Request Nonce from the message. It 3361 then looks for a context which has a CT(local) that matches the 3362 context tag. If no such context is found, it sends a R1bis message 3363 as specified in Section 7.17. 3365 Since context tags can be reused, the host MUST verify that the IPv6 3366 source address field is part of Ls(peer) and that the IPv6 3367 destination address field is part of Ls(local). If this is not the 3368 case, the sender of the Update Acknowledgement has a stale context 3369 which happens to match the CT(local) for this context. In this case 3370 the host MUST send a R1bis message, and otherwise ignore the Update 3371 Acknowledgement message. 3373 Then, depending on the state of the context: 3375 o If ESTABLISHED: Proceed to process message. 3377 o If I1-SENT, discard the message and stay in I1-SENT. 3379 o If I2-SENT, then send R2 and proceed to process the message. 3381 o If I2BIS-SENT, then send R2 and proceed to process the message. 3383 If the Request Nonce doesn't match the Nonce for the last sent Update 3384 Request for the context, then the Update Acknowledgement is silently 3385 ignored. If the nonce matches, then the update has been completed 3386 and the Update retransmit timer can be reset. 3388 11. Sending ULP Payloads 3390 When there is no context state for the ULID pair on the sender, there 3391 is no effect on how ULP packets are sent. If the host is using some 3392 heuristic for determining when to perform a deferred context 3393 establishment, then the host might need to do some accounting (count 3394 the number of packets sent and received) even before there is a ULID- 3395 pair context. 3397 If the context is not in ESTABLISHED or I2BIS-SENT state, then it 3398 there is also no effect on how the ULP packets are sent. Only in the 3399 ESTABLISHED and I2BIS-SENT states does the host have CT(peer) and 3400 Ls(peer) set. 3402 If there is a ULID-pair context for the ULID pair, then the sender 3403 needs to verify whether context uses the ULIDs as locators, that is, 3404 whether Lp(peer) == ULID(peer) and Lp(local) == ULID(local). 3406 If this is the case, then packets can be sent unmodified by the shim. 3407 If it is not the case, then the logic in Section 11.1 will need to be 3408 used. 3410 There will also be some maintenance activity relating to 3411 (un)reachability detection, whether packets are sent with the 3412 original locators or not. The details of this is out of scope for 3413 this document and is specified in [8]. 3415 11.1. Sending ULP Payload after a Switch 3417 When sending packets, if there is a ULID-pair context for the ULID 3418 pair, and the ULID pair is no longer used as the locator pair, then 3419 the sender needs to transform the packet. Apart from replacing the 3420 IPv6 source and destination fields with a locator pair, an 8-octet 3421 header is added so that the receiver can find the context and inverse 3422 the transformation. 3424 If there has been a failure causing a switch, and later the context 3425 switches back to sending things using the ULID pair as the locator 3426 pair, then there is no longer a need to do any packet transformation 3427 by the sender, hence there is no need to include the 8-octet 3428 extension header. 3430 First, the IP address fields are replaced. The IPv6 source address 3431 field is set to Lp(local) and the destination address field is set to 3432 Lp(peer). NOTE that this MUST NOT cause any recalculation of the ULP 3433 checksums, since the ULP checksums are carried end-to-end and the ULP 3434 pseudo-header contains the ULIDs which are preserved end-to-end. 3436 The sender skips any "routing sub-layer extension headers" that the 3437 ULP might have included, thus it skips any hop-by-hop extension 3438 header, any routing header, and any destination options header that 3439 is followed by a routing header. After any such headers the shim6 3440 extension header will be added. This might be before a Fragment 3441 header, a Destination Options header, an ESP or AH header, or a ULP 3442 header. 3444 The inserted shim6 Payload extension header includes the peer's 3445 context tag. It takes on the next header value from the preceding 3446 extension header, since that extension header will have a next header 3447 value of SHIM6. 3449 12. Receiving Packets 3451 As in normal IPv6 receive side packet processing the receiver parses 3452 the (extension) headers in order. Should it find a shim6 extension 3453 header it will look at the "P" field in that header. If this bit is 3454 zero, then the packet must be passed to the shim6 payload handling 3455 for rewriting. Otherwise, the packet is passed to the shim6 control 3456 handling. 3458 12.1. Receiving Payload Extension Headers 3460 The receiver extracts the context tag from the payload extension 3461 header, and uses this to find a ULID-pair context. If no context is 3462 found, the receiver SHOULD generate a R1bis message (see 3463 Section 7.17). 3465 Then, depending on the state of the context: 3467 o If ESTABLISHED: Proceed to process message. 3469 o If I1-SENT, discard the message and stay in I1-SENT. 3471 o If I2-SENT, then send R2 and proceed to process the message. 3473 o If I2BIS-SENT, then send R2 and proceed to process the message. 3475 With the context in hand, the receiver can now replace the IP address 3476 fields with the ULIDs kept in the context. Finally, the Payload 3477 extension header is removed from the packet (so that the ULP doesn't 3478 get confused by it), and the next header value in the preceding 3479 header is set to be the actual protocol number for the payload. Then 3480 the packet can be passed to the protocol identified by the next 3481 header value (which might be some function associated with the IP 3482 endpoint sublayer, or a ULP). 3484 If the host is using some heuristic for determining when to perform a 3485 deferred context establishment, then the host might need to do some 3486 accounting (count the number of packets sent and received) for 3487 packets that does not have a shim6 extension header and for which 3488 there is no context. But the need for this depends on what 3489 heuristics the implementation has chosen. 3491 12.2. Receiving Shim Control messages 3493 A shim control message has the checksum field verified. The Shim 3494 header length field is also verified against the length of the IPv6 3495 packet to make sure that the shim message doesn't claim to end past 3496 the end of the IPv6 packet. Finally, it checks that the neither the 3497 IPv6 destination field nor the IPv6 source field is a multicast 3498 address. If any of those checks fail, the packet is silently 3499 dropped. 3501 The message is then dispatched based on the shim message type. Each 3502 message type is then processed as described elsewhere in this 3503 document. If the packet contains a shim message type which is 3504 unknown to the receiver, then an ICMPv6 Parameter Problem error is 3505 generated and sent back. The pointer field in the Parameter Problem 3506 is set to point at the first octet of the shim message type. The 3507 error is rate limited just like other ICMP errors [5]. 3509 All the control messages can contain any options with C=0. If there 3510 is any option in the message with C=1 that isn't known to the host, 3511 then the host MUST send an ICMPv6 Parameter Problem, with the Pointer 3512 field referencing the first octet of the Option Type. 3514 12.3. Context Lookup 3516 We assume that each shim context has its own state machine. We 3517 assume that a dispatcher delivers incoming packets to the state 3518 machine that it belongs to. Here we describe the rules used for the 3519 dispatcher to deliver packets to the correct shim context state 3520 machine. 3522 There is one state machine per context identified that is 3523 conceptually identified by ULID pair and Forked Instance Identifier 3524 (which is zero by default), or identified by CT(local). However, the 3525 detailed lookup rules are more complex, especially during context 3526 establishment. 3528 Clearly, if the required context is not established, it will be in 3529 IDLE state. 3531 During context establishment, the context is identified as follows: 3533 o I1 packets: Deliver to the context associated with the ULID pair 3534 and the Forked Instance Identifier. 3536 o I2 packets: Deliver to the context associated with the ULID pair 3537 and the Forked Instance Identifier. 3539 o R1 packets: Deliver to the context with the locator pair included 3540 in the packet and the Initiator nonce included in the packet (R1 3541 does not contain ULID pair nor the CT(local)). If no context 3542 exist with this locator pair and Initiator nonce, then silently 3543 discard. 3545 o R2 packets: Deliver to the context with the locator pair included 3546 in the packet and the Initiator nonce included in the packet (R2 3547 does not contain ULID pair nor the CT(local)). If no context 3548 exists with this locator pair and INIT nonce, then silently 3549 discard. 3551 o R1bis packet: deliver to the context that has the locator pair and 3552 the CT(peer) equal to the Packet Context Tag included in the R1bis 3553 packet. 3555 o I2bis packets: Deliver to the context associated with the ULID 3556 pair and the Forked Instance Identifier. 3558 o Payload extension headers: Deliver to the context with CT(local) 3559 equal to the Receiver Context Tag included in the packet. 3561 o Other control messages (Update, Keepalive, Probe): Deliver to the 3562 context with CT(local) equal to the Receiver Context Tag included 3563 in the packet. Verify that the IPv6 source address field is part 3564 of Ls(peer) and that the IPv6 destination address field is part of 3565 Ls(local). If not, send a R1bis message. 3567 o ICMP errors which contain a shim6 payload extension header or 3568 other shim control packet in the "packet in error": Use the 3569 "packet in error" for dispatching as follows. Deliver to the 3570 context with CT(peer) equal to the Receiver Context Tag, Lp(local) 3571 being the IPv6 source address, and Lp(peer) being the IPv6 3572 destination address. 3574 In addition, the shim on the sending side needs to be able to find 3575 the context state when a ULP packet is passed down from the ULP. In 3576 that case the lookup key is the pair of ULIDs and FII=0. If we have 3577 a ULP API that allows the ULP to do context forking, then presumably 3578 the ULP would pass down the Forked Instance Identifier. 3580 13. Initial Contact 3582 The initial contact is some non-shim communication between two ULIDs, 3583 as described in Section 2. At that point in time there is no 3584 activity in the shim. 3586 Whether the shim ends up being used or not (e.g., the peer might not 3587 support shim6) it is highly desirable that the initial contact can be 3588 established even if there is a failure for one or more IP addresses. 3590 The approach taken is to rely on the applications and the transport 3591 protocols to retry with different source and destination addresses, 3592 consistent with what is already specified in Default Address 3593 Selection [12], and some fixes to that specification [13] to make it 3594 try different source addresses and not only different destination 3595 addresses. 3597 The implementation of such an approach can potentially result in long 3598 timeouts. For instance, a naive implementation at the socket API 3599 which uses getaddrinfo() to retrieve all destination addresses and 3600 then tries to bind() and connect() to try all source and destination 3601 address combinations waiting for TCP to time out for each combination 3602 before trying the next one. 3604 However, if implementations encapsulate this in some new connect-by- 3605 name() API, and use non-blocking connect calls, it is possible to 3606 cycle through the available combinations in a more rapid manner until 3607 a working source and destination pair is found. Thus the issues in 3608 this domain are issues of implementations and the current socket API, 3609 and not issues of protocol specification. In all honesty, while 3610 providing an easy to use connect-by-name() API for TCP and other 3611 connection-oriented transports is easy; providing a similar 3612 capability at the API for UDP is hard due to the protocol itself not 3613 providing any "success" feedback. But even the UDP issue is one of 3614 APIs and implementation. 3616 14. Protocol constants 3618 The protocol uses the following constants: 3620 I1_RETRIES_MAX = 4 3622 I1_TIMEOUT = 4 seconds 3624 NO_R1_HOLDDOWN_TIME = 1 min 3626 ICMP_HOLDDOWN_TIME = 10 min 3628 I2_TIMEOUT = 4 seconds 3630 I2_RETRIES_MAX = 2 3632 I2bis_TIMEOUT = 4 seconds 3634 I2bis_RETRIES_MAX = 2 3636 VALIDATOR_MIN_LIFETIME = 30 seconds 3638 UPDATE_TIMEOUT = 4 seconds 3640 The retransmit timers (I1_TIMEOUT, I2_TIMEOUT, UPDATE_TIMEOUT) are 3641 subject to binary exponential backoff, as well as randomization 3642 across a range of 0.5 and 1.5 times the nominal (backed off) value. 3643 This removes any risk of synchronization between lots of hosts 3644 performing independent shim operations at the same time. 3646 The randomization is applied after the binary exponential backoff. 3647 Thus the first retransmission would happen based on a uniformly 3648 distributed random number in the range [0.5*4, 1.5*4] seconds, the 3649 second retransmission [0.5*8, 1.5*8] seconds after the first one, 3650 etc. 3652 15. Implications Elsewhere 3654 The general shim6 approach, as well as the specifics of this proposed 3655 solution, has implications elsewhere. The key implications are: 3657 o Applications that perform referrals, or callbacks using IP 3658 addresses as the 'identifiers' can still function in limited ways, 3659 as described in [22]. But in order for such applications to be 3660 able to take advantage of the multiple locators for redundancy, 3661 the applications need to be modified to either use fully qualified 3662 domain names as the 'identifiers', or they need to pass all the 3663 locators as the 'identifiers' i.e., the 'identifier' from the 3664 applications perspective becomes a set of IP addresses instead of 3665 a single IP address. 3667 o Firewalls that today pass limited traffic, e.g., outbound TCP 3668 connections, would presumably block the shim6 protocol. This 3669 means that even when shim6 capable hosts are communicating, the I1 3670 messages would be dropped, hence the hosts would not discover that 3671 their peer is shim6 capable. This is in fact a feature, since if 3672 the hosts managed to establish a ULID-pair context, then the 3673 firewall would probably drop the "different" packets that are sent 3674 after a failure (those using the shim6 payload extension header 3675 with a TCP packet inside it). Thus stateful firewalls that are 3676 modified to pass shim6 messages should also be modified to pass 3677 the payload extension header, so that the shim can use the 3678 alternate locators to recover from failures. This presumably 3679 implies that the firewall needs to track the set of locators in 3680 use by looking at the shim6 control exchanges. Such firewalls 3681 might even want to verify the locators using the HBA/CGA 3682 verification themselves, which they can do without modifying any 3683 of the shim6 packets they pass through. 3685 o Signaling protocols for QoS or other things that involve having 3686 devices in the network path look at IP addresses and port numbers, 3687 or IP addresses and Flow Labels, need to be invoked on the hosts 3688 when the locator pair changes due to a failure. At that point in 3689 time those protocols need to inform the devices that a new pair of 3690 IP addresses will be used for the flow. Note that this is the 3691 case even though this protocol, unlike some earlier proposals, 3692 does not overload the flow label as a context tag; the in-path 3693 devices need to know about the use of the new locators even though 3694 the flow label stays the same. 3696 o MTU implications. The path MTU mechanisms we use are robust 3697 against different packets taking different paths through the 3698 Internet, by computing a minimum over the recently observed path 3699 MTUs. When shim6 fails over from using one locator pair to 3700 another pair, this means that packets might travel over a 3701 different path through the Internet, hence the path MTU might be 3702 quite different. Perhaps such a path change would be a good hint 3703 to the path MTU mechanism to try a larger MTU? 3705 The fact that the shim will add an 8 octet payload extension 3706 header to the ULP packets after a locator switch, can also affect 3707 the usable path MTU for the ULPs. In this case the MTU change is 3708 local to the sending host, thus conveying the change to the ULPs 3709 is an implementation matter. 3711 o The precise interaction between Mobile IPv6 and shim6 is for 3712 further study, but it might make sense to have Mobile IPv6 operate 3713 on locators, meaning that the shim would be layered on top of the 3714 MIPv6 mechanism. 3716 16. Security Considerations 3718 This document satisfies the concerns specified in [19] as follows: 3720 o The HBA technique [7] for verifying the locators to prevent an 3721 attacker from redirecting the packet stream to somewhere else. 3723 o Requiring a Reachability Probe+Reply before a new locator is used 3724 as the destination, in order to prevent 3rd party flooding 3725 attacks. 3727 o The first message does not create any state on the responder. 3728 Essentially a 3-way exchange is required before the responder 3729 creates any state. This means that a state-based DoS attack 3730 (trying to use up all of memory on the responder) at least 3731 provides an IPv6 address that the attacker was using. 3733 o The context establishment messages use nonces to prevent replay 3734 attacks, and to prevent off-path attackers from interfering with 3735 the establishment. 3737 o Every control message of the shim6 protocol, past the context 3738 establishment, carry the context tag assigned to the particular 3739 context. This implies that an attacker needs to discover that 3740 context tag before being able to spoof any shim6 control message. 3741 Such discovery probably requires to be along the path in order to 3742 be sniff the context tag value. The result is that through this 3743 technique, the shim6 protocol is protected against off-path 3744 attackers. 3746 Some of the residual threats in this proposal are: 3748 o An attacker which arrives late on the path (after the context has 3749 been established) can use the R1bis message to cause one peer to 3750 recreate the context, and at that point in time the attacker can 3751 observe all of the exchange. But this doesn't seem to open any 3752 new doors for the attacker since such an attacker can observe the 3753 context tags that are being used, and once known it can use those 3754 to send bogus messages. 3756 o An attacker which is present on the path so that it can find out 3757 the context tags, can generate a R1bis message after it has moved 3758 off the path. For this packet to be effective it needs to have a 3759 source locator which belongs to the context, thus there can not be 3760 "too much" ingress filtering between the attackers new location 3761 and the communicating peers. But this doesn't seem to be that 3762 severe, because once the R1bis causes the context to be re- 3763 established, a new pair of context tags will be used, which will 3764 not be known to the attacker. If this is still a concern, we 3765 could require a 2-way handshake "did you really loose the state?" 3766 in response to the error message. 3768 o It might be possible for an attacker to try random 47-bit context 3769 tags and see if they can cause disruption for communication 3770 between two hosts. In particular, in the case of payload packets, 3771 the effects of such attack would be similar of those of an 3772 attacker sending packets with spoofed source address. In the case 3773 of control packets, it is not enough to find the correct context 3774 tag, but additional information is required (e.g. nonces, proper 3775 source addresses) (see previous bullet for the case of R1bis). If 3776 a 47-bit tag, which is the largest that fits in an 8-octet 3777 extension header, isn't sufficient, one could use an even larger 3778 tag in the shim6 control messages, and use the low-order 47 bits 3779 in the payload extension header. 3781 o When the payload extension header is used, an attacker that can 3782 guess the 47-bit random context tag, can inject packets into the 3783 context with any source locator. Thus if there is ingress 3784 filtering between the attacker, this could potentially allow to 3785 bypass the ingress filtering. However, in addition to guessing 3786 the 47-bit context tag, the attacker also needs to find a context 3787 where, after the receiver's replacement of the locators with the 3788 ULIDs, the the ULP checksum is correct. But even this wouldn't be 3789 sufficient with ULPs like TCP, since the TCP port numbers and 3790 sequence numbers must match an existing connection. Thus, even 3791 though the issues for off-path attackers injecting packets are 3792 different than today with ingress filtering, it is still very hard 3793 for an off-path attacker to guess. If IPsec is applied then the 3794 issue goes away completely. 3796 o The validator included in the R1 and R1bis packets are generated 3797 as a hash of several input parameters. However, most of the 3798 inputs are actually determined by the sender, and only the secret 3799 value S is unknown to the sender. However, the resulting 3800 protection is deemed to be enough since it would be easier for the 3801 attacker to just obtain a new validator sending a I1 packet than 3802 performing all the computations required to determine the secret 3803 S. However, it is recommended that the host changes the secret S 3804 periodically. 3806 17. IANA Considerations 3808 IANA is directed to allocate a new IP Protocol Number value for the 3809 SHIM6 Protocol. 3811 IANA is directed to record a CGA message type for the SHIM6 Protocol 3812 in the [CGA] namespace registry with the value 0x4A30 5662 4858 574B 3813 3655 416F 506A 6D48. 3815 IANA is directed to establish a SHIM6 Parameter Registry with two 3816 components: SHIM6 Type registrations and SHIM6 Options registrations. 3818 The initial contents of the SHIM6 Type registry are as follows: 3820 +------------+-----------------------------------------------------+ 3821 | Type Value | Message | 3822 +------------+-----------------------------------------------------+ 3823 | 0 | RESERVED | 3824 | | | 3825 | 1 | I1 (first establishment message from the initiator) | 3826 | | | 3827 | 2 | R1 (first establishment message from the responder) | 3828 | | | 3829 | 3 | I2 (2nd establishment message from the initiator) | 3830 | | | 3831 | 4 | R2 (2nd establishment message from the responder) | 3832 | | | 3833 | 5 | R1bis (Reply to reference to non-existent context) | 3834 | | | 3835 | 6 | I2bis (Reply to a R1bis message) | 3836 | | | 3837 | 7-59 | Can be allocated using Standards Action | 3838 | | | 3839 | 60-63 | For Experimental use | 3840 | | | 3841 | 64 | Update Request | 3842 | | | 3843 | 65 | Update Acknowledgement | 3844 | | | 3845 | 66 | Keepalive | 3846 | | | 3847 | 67 | Probe Message | 3848 | | | 3849 | 68-123 | Can be allocated using Standards Action | 3850 | | | 3851 | 124-127 | For Experimental use | 3852 +------------+-----------------------------------------------------+ 3853 The initial contents of the SHIM6 Options registry are as follows: 3855 +-------------+----------------------------------+ 3856 | Type | Option Name | 3857 +-------------+----------------------------------+ 3858 | 0 | RESERVED | 3859 | | | 3860 | 1 | Responder Validator | 3861 | | | 3862 | 2 | Locator List | 3863 | | | 3864 | 3 | Locator Preferences | 3865 | | | 3866 | 4 | CGA Parameter Data Structure | 3867 | | | 3868 | 5 | CGA Signature | 3869 | | | 3870 | 6 | ULID Pair | 3871 | | | 3872 | 7 | Forked Instance Identifier | 3873 | | | 3874 | 8-9 | Allocated using Standards action | 3875 | | | 3876 | 10 | Probe Option | 3877 | | | 3878 | 11 | Reachability Option | 3879 | | | 3880 | 12 | Payload Reception Report Option | 3881 | | | 3882 | 13-16383 | Allocated using Standards action | 3883 | | | 3884 | 16384-32767 | For Experimental use | 3885 +-------------+----------------------------------+ 3887 18. Acknowledgements 3889 Over the years many people active in the multi6 and shim6 WGs have 3890 contributed ideas a suggestions that are reflected in this 3891 specification. Special thanks to the careful comments from Geoff 3892 Huston, Shinta Sugimoto and Pekka Savola on earlier versions of this 3893 draft. 3895 Appendix A. Possible Protocol Extensions 3897 During the development of this protocol, several issues have been 3898 brought up as important one to address, but are ones that do not need 3899 to be in the base protocol itself but can instead be done as 3900 extensions to the protocol. The key ones are: 3902 o As stated in the assumptions in Section 3, the in order for the 3903 shim6 protocol to be able to recover from a wide range of 3904 failures, for instance when one of the communicating hosts is 3905 singly-homed, and cope with a site's ISPs that do ingress 3906 filtering based on the source IPv6 address, there is a need for 3907 the host to be able to influence the egress selection from its 3908 site. Further discussion of this issue is captured in [20]. 3910 o Is there need for keeping the list of locators private between the 3911 two communicating endpoints? We can potentially accomplish that 3912 when using CGA but not with HBA, but it comes at the cost of doing 3913 some public key encryption and decryption operations as part of 3914 the context establishment. The suggestion is to leave this for a 3915 future extension to the protocol. 3917 o Defining some form of end-to-end "compression" mechanism that 3918 removes the need for including the Shim6 Payload extension header 3919 when the locator pair is not the ULID pair. 3921 o Supporting the dynamic setting of locator preferences on a site- 3922 wide basis, and use the Locator Preference option in the shim6 3923 protocol to convey these preferences to remote communicating 3924 hosts. This could mirror the DNS SRV record's notion of priority 3925 and weight. 3927 o Potentially recommend that more application protocols use DNS SRV 3928 records to allow a site some influence on load spreading for the 3929 initial contact (before the shim6 context establishment) as well 3930 as for traffic which does not use the shim. 3932 o Specifying APIs for the ULPs to be aware of the locators the shim 3933 is using, and be able to influence the choice of locators 3934 (controlling preferences as well as triggering a locator pair 3935 switch). This includes providing APIs the ULPs can use to fork a 3936 shim context. 3938 o Whether it is feasible to relax the suggestions for when context 3939 state is removed, so that one can end up with an asymmetric 3940 distribution of the context state and still get (most of) the shim 3941 benefits. For example, the busy server would go through the 3942 context setup but would quickly remove the context state after 3943 this (in order to save memory) but the not-so-busy client would 3944 retain the context state. The context recovery mechanism 3945 presented in Section 7.5 would then be recreate the state should 3946 the client send either a shim control message (e.g., probe message 3947 because it sees a problem), or a ULP packet in an payload 3948 extension header (because it had earlier failed over to an 3949 alternative locator pair, but had been silent for a while). This 3950 seems to provide the benefits of the shim as long as the client 3951 can detect the failure. If the client doesn't send anything, and 3952 it is the server that tries to send, then it will not be able to 3953 recover because the shim on the server has no context state, hence 3954 doesn't know any alternate locator pairs. 3956 o Study whether a host explicitly fail communication when a ULID 3957 becomes invalid (based on RFC 2462 lifetimes or DHCPv6), or should 3958 we let the communication continue using the invalidated ULID (it 3959 can certainly work since other locators will be used). 3961 o Study what it would take to make the shim6 control protocol not 3962 rely at all on a stable source locator in the packets. This can 3963 probably be accomplished by having all the shim control messages 3964 include the ULID-pair option. 3966 o If each host might have lots of locators, then the currently 3967 requirement to include essentially all of them in the I2 and R2 3968 messages might be constraining. If this is the case we can look 3969 into using the CGA Parameter Data Structure for the comparison, 3970 instead of the prefix sets, to be able to detect context 3971 confusion. This would place some constraint on a (logical) only 3972 using e.g., one CGA public key, and would require some carefully 3973 crafted rules on how two PDSs are compared for "being the same 3974 host". But if we don't expect more than a handful locators per 3975 host, then we don't need this added complexity. 3977 o ULP specified timers for the reachability detection mechanism 3978 (which can be useful particularly when there are forked contexts). 3980 o Pre-verify some "backup" locator pair, so that the failover time 3981 can be shorter. 3983 o Study how shim6 and Mobile IPv6 might interact. There existing an 3984 initial draft on this topic [21]. 3986 Appendix B. Simplified State Machine 3988 The states are defined in Section 6.2. The intent is that the 3989 stylized description below be consistent with the textual description 3990 in the specification, but should they conflict, the textual 3991 description is normative. 3993 The following table describes the possible actions in state IDLE and 3994 their respective triggers: 3996 +---------------------+---------------------------------------------+ 3997 | Trigger | Action | 3998 +---------------------+---------------------------------------------+ 3999 | Receive I1 | Send R1 and stay in IDLE | 4000 | | | 4001 | Heuristics trigger | Send I1 and move to I1-SENT | 4002 | a new context | | 4003 | establishment | | 4004 | | | 4005 | Receive I2, verify | If successful, send R2 and move to | 4006 | validator and | ESTABLISHED | 4007 | RESP nonce | | 4008 | | If fail, stay in IDLE | 4009 | | | 4010 | Receive I2bis, | If successful, send R2 and move to | 4011 | verify validator | ESTABLISHED | 4012 | and RESP nonce | | 4013 | | If fail, stay in IDLE | 4014 | | | 4015 | R1, R1bis, R2 | N/A (This context lacks the required info | 4016 | | for the dispatcher to deliver them) | 4017 | | | 4018 | Receive payload | Send R1bis and stay in IDLE | 4019 | extension header | | 4020 | or other control | | 4021 | packet | | 4022 +---------------------+---------------------------------------------+ 4023 The following table describes the possible actions in state I1-SENT 4024 and their respective triggers: 4026 +---------------------+---------------------------------------------+ 4027 | Trigger | Action | 4028 +---------------------+---------------------------------------------+ 4029 | Receive R1, verify | If successful, send I2 and move to I2-SENT | 4030 | INIT nonce | | 4031 | | If fail, discard and stay in I1-SENT | 4032 | | | 4033 | Receive I1 | Send R2 and stay in I1-SENT | 4034 | | | 4035 | Receive R2, verify | If successful, move to ESTABLISHED | 4036 | INIT nonce | | 4037 | | If fail, discard and stay in I1-SENT | 4038 | | | 4039 | Receive I2, verify | If successful, send R2 and move to | 4040 | validator and RESP | ESTABLISHED | 4041 | nonce | | 4042 | | If fail, discard and stay in I1-SENT | 4043 | | | 4044 | Receive I2bis, | If successful, send R2 and move to | 4045 | verify validator | ESTABLISHED | 4046 | and RESP nonce | | 4047 | | If fail, discard and stay in I1-SENT | 4048 | | | 4049 | Timeout, increment | If counter =< I1_RETRIES_MAX, send I1 and | 4050 | timeout counter | stay in I1-SENT | 4051 | | | 4052 | | If counter > I1_RETRIES_MAX, go to E-FAILED | 4053 | | | 4054 | Receive ICMP payload| Move to E-FAILED | 4055 | unknown error | | 4056 | | | 4057 | R1bis | N/A (Dispatcher doesn't deliver since | 4058 | | CT(peer) is not set) | 4059 | | | 4060 | Receive Payload or | Discard and stay in I1-SENT | 4061 | extension header | | 4062 | or other control | | 4063 | packet | | 4064 +---------------------+---------------------------------------------+ 4065 The following table describes the possible actions in state I2-SENT 4066 and their respective triggers: 4068 +---------------------+---------------------------------------------+ 4069 | Trigger | Action | 4070 +---------------------+---------------------------------------------+ 4071 | Receive R2, verify | If successful move to ESTABLISHED | 4072 | INIT nonce | | 4073 | | If fail, stay in I2-SENT | 4074 | | | 4075 | Receive I1 | Send R2 and stay in I2-SENT | 4076 | | | 4077 | Receive I2 | Send R2 and stay in I2-SENT | 4078 | verify validator | | 4079 | and RESP nonce | | 4080 | | | 4081 | Receive I2bis | Send R2 and stay in I2-SENT | 4082 | verify validator | | 4083 | and RESP nonce | | 4084 | | | 4085 | Receive R1 | Discard and stay in I2-SENT | 4086 | | | 4087 | Timeout, increment | If counter =< I2_RETRIES_MAX, send I2 and | 4088 | timeout counter | stay in I2-SENT | 4089 | | | 4090 | | If counter > I2_RETRIES_MAX, send I1 and go | 4091 | | to I1-SENT | 4092 | | | 4093 | R1bis | N/A (Dispatcher doesn't deliver since | 4094 | | CT(peer) is not set) | 4095 | | | 4096 | Receive payload or | Accept and send I2 (probably R2 was sent | 4097 | extension header | by peer and lost) | 4098 | other control | | 4099 | packet | | 4100 +---------------------+---------------------------------------------+ 4101 The following table describes the possible actions in state I2BIS- 4102 SENT and their respective triggers: 4104 +---------------------+---------------------------------------------+ 4105 | Trigger | Action | 4106 +---------------------+---------------------------------------------+ 4107 | Receive R2, verify | If successful move to ESTABLISHED | 4108 | INIT nonce | | 4109 | | If fail, stay in I2BIS-SENT | 4110 | | | 4111 | Receive I1 | Send R2 and stay in I2BIS-SENT | 4112 | | | 4113 | Receive I2 | Send R2 and stay in I2BIS-SENT | 4114 | verify validator | | 4115 | and RESP nonce | | 4116 | | | 4117 | Receive I2bis | Send R2 and stay in I2BIS-SENT | 4118 | verify validator | | 4119 | and RESP nonce | | 4120 | | | 4121 | Receive R1 | Discard and stay in I2BIS-SENT | 4122 | | | 4123 | Timeout, increment | If counter =< I2_RETRIES_MAX, send I2bis | 4124 | timeout counter | and stay in I2BIS-SENT | 4125 | | | 4126 | | If counter > I2_RETRIES_MAX, send I1 and | 4127 | | go to I1-SENT | 4128 | | | 4129 | R1bis | N/A (Dispatcher doesn't deliver since | 4130 | | CT(peer) is not set) | 4131 | | | 4132 | Receive payload or | Accept and send I2bis (probably R2 was | 4133 | extension header | sent by peer and lost) | 4134 | other control | | 4135 | packet | | 4136 +---------------------+---------------------------------------------+ 4137 The following table describes the possible actions in state 4138 ESTABLISHED and their respective triggers: 4140 +---------------------+---------------------------------------------+ 4141 | Trigger | Action | 4142 +---------------------+---------------------------------------------+ 4143 | Receive I1, compare | If no match, send R1 and stay in ESTABLISHED| 4144 | CT(peer) with | | 4145 | received CT | If match, send R2 and stay in ESTABLISHED | 4146 | | | 4147 | | | 4148 | Receive I2, verify | If successful, then send R2 and stay in | 4149 | validator and RESP | ESTABLISHED | 4150 | nonce | | 4151 | | Otherwise, discard and stay in ESTABLISHED | 4152 | | | 4153 | Receive I2bis, | If successful, then send R2 and stay in | 4154 | verify validator | ESTABLISHED | 4155 | and RESP nonce | | 4156 | | Otherwise, discard and stay in ESTABLISHED | 4157 | | | 4158 | Receive R2 | Discard and stay in ESTABLISHED | 4159 | | | 4160 | Receive R1 | Discard and stay in ESTABLISHED | 4161 | | | 4162 | Receive R1bis | Send I2bis and move to I2BIS-SENT | 4163 | | | 4164 | | | 4165 | Receive payload or | Process and stay in ESTABLISHED | 4166 | extension header | | 4167 | other control | | 4168 | packet | | 4169 | | | 4170 | Implementation | Discard state and go to IDLE | 4171 | specific heuristic | | 4172 | (E.g., No open ULP | | 4173 | sockets and idle | | 4174 | for some time ) | | 4175 +---------------------+---------------------------------------------+ 4176 The following table describes the possible actions in state E-FAILED 4177 and their respective triggers: 4179 +---------------------+---------------------------------------------+ 4180 | Trigger | Action | 4181 +---------------------+---------------------------------------------+ 4182 | Wait for | Go to IDLE | 4183 | NO_R1_HOLDDOWN_TIME | | 4184 | | | 4185 | Any packet | Process as in IDLE | 4186 +---------------------+---------------------------------------------+ 4188 The following table describes the possible actions in state NO- 4189 SUPPORT and their respective triggers: 4191 +---------------------+---------------------------------------------+ 4192 | Trigger | Action | 4193 +---------------------+---------------------------------------------+ 4194 | Wait for | Go to IDLE | 4195 | ICMP_HOLDDOWN_TIME | | 4196 | | | 4197 | Any packet | Process as in IDLE | 4198 +---------------------+---------------------------------------------+ 4200 Appendix B.1. Simplified State Machine diagram 4202 Timeout/Null +------------+ 4203 I1/R1 +------------------| NO SUPPORT | 4204 Payload or Control/R1bis | +------------+ 4205 +---------+ | ^ 4206 | | | ICMP Error/Null| 4207 | V V | 4208 +-----------------+ Timeout/Null +----------+ | 4209 | |<---------------| E-FAILED | | 4210 +-| IDLE | +----------+ | 4211 I2 or I2bis/R2 | | | ^ | 4212 | +-----------------+ (Tiemout#>MAX)/Null| | 4213 | ^ | | | 4214 | | +------+ | | 4215 I2 or I2bis/R2 | | Heuristic/I1| I1/R2 | | 4216 Payload/Null | | | Control/Null | | 4217 I1/R1 or R2 | +--+ | Payload/Null | | 4218 R1 or R2/Null | |Heuristic/Null | (Tiemout#| | 4223 | ESTABLISHED |<----------------------------| I1-SENT | 4224 | | | | 4225 +-------------------+ +----------------+ 4226 | ^ ^ | ^ ^ 4227 | | |R2/Null +-------------+ | | 4228 | | +----------+ |R1/I2 | | 4229 | | | V | | 4230 | | +------------------+ | | 4231 | | | |-------------+ | 4232 | | | I2-SENT | (Timeout#>Max)/I1 | 4233 | | | | | 4234 | | +------------------+ | 4235 | | | ^ | 4236 | | +--------------+ | 4237 | | I1 or I2bis or I2 or Payload/R2 | 4238 | | (Timeout#Max)/I1 | 4241 | R2/Null| +------------------------------------------+ 4242 | V | 4243 | +-------------------+ 4244 | | |<-+ (Timeout#| I2bis-SENT | | I1 or I2 or I2bis/R2 4246 R1bis/I2bis | |--+ R1 or R1bis/Null 4247 +-------------------+ Payload/R2 4249 Appendix C. Context Tag Reuse 4251 The shim6 protocol doesn't have a mechanism for coordinated state 4252 removal between the peers, because such state removal doesn't seem to 4253 help given that a host can crash and reboot at any time. A result of 4254 this is that the protocol needs to be robust against a context tag 4255 being reused for some other context. This section summarizes the 4256 different cases in which a tag can be reused, and how the recovery 4257 works. 4259 The different cases are exemplified by the following case. Assume 4260 host A and B were communicating using a context with the ULID pair 4261 , and that B had assigned context tag X to this context. We 4262 assume that B uses only the context tag to demultiplex the received 4263 payload extension headers, since this is the more general case. 4264 Further we assume that B removes this context state, while A retains 4265 it. B might then at a later time assign CT(local)=X to some other 4266 context, and we have several cases: 4268 o The context tag is reassigned to a context for the same ULID pair 4269 . We've called this "Context Recovery" in this document. 4271 o The context tag is reassigned to a context for a different ULID 4272 pair between the same to hosts, e.g., . We've called this 4273 "Context Confusion" in this document. 4275 o The context tag is reassigned to a context between B and other 4276 host C, for instance for the ULID pair . That is a form 4277 of three party context confusion. 4279 Appendix C.1. Context Recovery 4281 This case is relatively simple, and is discussed in Section 7.5. The 4282 observation is that since the ULID pair is the same, when either A or 4283 B tries to establish the new context, A can keep the old context 4284 while B re-creates the context with the same context tag CT(B) = X. 4286 Appendix C.2. Context Confusion 4288 This cases is a bit more complex, and is discussed in Section 7.6. 4289 When the new context is created, whether A or B initiates it, host A 4290 can detect when it receives B's locator set (in the I2, or R2 4291 message), that it ends up with two contexts to the same peer host 4292 (overlapping Ls(peer) locator sets) that have the same context tag 4293 CT(peer) = X. At this point in time host A can clear up any 4294 possibility of causing confusion by not using the old context to send 4295 any more packets. It either just discards the old context (it might 4296 not be used by any ULP traffic, since B had discarded it), or it 4297 recreates a different context for the old ULID pair (), for 4298 which B will assign a unique CT(B) as part of the normal context 4299 establishment mechanism. 4301 Appendix C.3. Three Party Context Confusion 4303 The third case does not have a place where the old state on A can be 4304 verified, since the new context is established between B and C. Thus 4305 when B receives payload extension headers with X as the context tag, 4306 it will find the context for , hence rewrite the packets to 4307 have C3 in the source address field and B2 in the destination address 4308 field before passing them up to the ULP. This rewriting is correct 4309 when the packets are in fact sent by host C, but if host A ever 4310 happens to send a packet using the old context, then the ULP on A 4311 sends a packet with ULIDs and the packet arrives at the ULP 4312 on B with ULIDs . 4314 This is clearly an error, and the packet will most likely be rejected 4315 by the ULP on B due to a bad pseudo-header checksum. Even if the 4316 checksum is ok (probability 2^-16), the ULP isn't likely to have a 4317 connection for those ULIDs and port numbers. And if the ULP is 4318 connection-less, processing the packet is most likely harmless; such 4319 a ULP must be able to copy with random packets being sent by random 4320 peers in any case. 4322 This broken state, where packets sent from A to B using the old 4323 context on host A might persist for some time, but it will not remain 4324 for very long. The unreachability detection on host A will kick in, 4325 because it does not see any return traffic (payload or Keepalive 4326 messages) for the context. This will result in host A sending Probe 4327 messages to host B to find a working locator pair. The effect of 4328 this is that host B will notice that it does not have a context for 4329 the ULID pair and CT(B) = X, which will make host B send an 4330 R1bis packet to re-establish that context. The re-established 4331 context, just like in the previous section, will get a unique CT(B) 4332 assigned by host B, thus there will no longer be any confusion. 4334 In summary, there are cases where a context tag might be reused while 4335 some peer retains the state, but the protocol can recover from it. 4336 The probability of these events is low given the 47 bit context tag 4337 size. However, it is important that these recovery mechanisms be 4338 tested. Thus during development and testing it is recommended that 4339 implementations not use the full 47 bit space, but instead keep e.g. 4340 the top 40 bits as zero, only leaving the host with 128 unique 4341 context tags. This will help test the recovery mechanisms. 4343 Appendix D. Design Alternatives 4345 This document has picked a certain set of design choices in order to 4346 try to work out a bunch of the details, and stimulate discussion. 4347 But as has been discussed on the mailing list, there are other 4348 choices that make sense. This appendix tries to enumerate some 4349 alternatives. 4351 Appendix D.1. Context granularity 4353 Over the years various suggestions have been made whether the shim 4354 should, even if it operates at the IP layer, be aware of ULP 4355 connections and sessions, and as a result be able to make separate 4356 shim contexts for separate ULP connections and sessions. A few 4357 different options have been discussed: 4359 o Each ULP connection maps to its own shim context. 4361 o The shim is unaware of the ULP notion of connections and just 4362 operates on a host-to-host (IP address) granularity. 4364 o Hybrids where the shim is aware of some ULPs (such as TCP) and 4365 handles other ULPs on a host-to-host basis. 4367 Having shim state for every ULP connection potentially means higher 4368 overhead since the state setup overhead might become significant; 4369 there is utility in being able to amortize this over multiple 4370 connections. 4372 But being completely unaware of the ULP connections might hamper ULPs 4373 that want different communication to use different locator pairs, for 4374 instance for quality or cost reasons. 4376 The protocol has a shim which operates with host-level granularity 4377 (strictly speaking, with ULID-pair granularity, to be able to 4378 amortize the context establishment over multiple ULP connections. 4379 This is combined with the ability for shim-aware ULPs to request 4380 context forking so that different ULP traffic can use different 4381 locator pairs. 4383 Appendix D.2. Demultiplexing of data packets in shim6 communications 4385 Once a ULID-pair context is established between two hosts, packets 4386 may carry locators that differ from the ULIDs presented to the ULPs 4387 using the established context. One of main functions of the SHIM6 4388 layer is to perform the mapping between the locators used to forward 4389 packets through the network and the ULIDs presented to the ULP. In 4390 order to perform that translation for incoming packets, the SHIM6 4391 layer needs to first identify which of the incoming packets need to 4392 be translated and then perform the mapping between locators and ULIDs 4393 using the associated context. Such operation is called 4394 demultiplexing. It should be noted that because any address can be 4395 used both as a locator and as a ULID, additional information other 4396 than the addresses carried in packets, need to be taken into account 4397 for this operation. 4399 For example, if a host has address A1 and A2 and starts communicating 4400 with a peer with addresses B1 and B2, then some communication 4401 (connections) might use the pair as ULID and others might 4402 use e.g., . Initially there are no failures so these address 4403 pairs are used as locators i.e. in the IP address fields in the 4404 packets on the wire. But when there is a failure the shim6 layer on 4405 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 4407 IP address field for some packets and not others, but the packets all 4408 have the same locator pair. 4410 In order to accomplish the demultiplexing operation successfully, 4411 data packets carry a context tag that allows the receiver of the 4412 packet to determine the shim context to be used to perform the 4413 operation. 4415 Two mechanisms for carrying the context tag information have been 4416 considered in depth during the shim protocol design. Those carrying 4417 the context tag in the flow label field of the IPv6 header and the 4418 usage of a new extension header to carry the context tag. In this 4419 appendix we will describe the pros and cons of each approach and 4420 justify the selected option. 4422 Appendix D.2.1. Flow-label 4424 A possible approach is to carry the context tag in the Flow Label 4425 field of the IPv6 header. This means that when a shim6 context is 4426 established, a Flow Label value is associated with this context (and 4427 perhaps a separate flow label for each direction). 4429 The simplest approach that does this is to have the triple identify the context at 4431 the receiver. 4433 The problem with this approach is that because the locator sets are 4434 dynamic, it is not possible at any given moment to be sure that two 4435 contexts for which the same context tag is allocated will have 4436 disjoint locator sets during the lifetime of the contexts. 4438 Suppose that Node A has addresses IPA1, IPA2, IPA3 and IPA4 and that 4439 Host B has addresses IPB1 and IPB2. 4441 Suppose that two different contexts are established between HostA and 4442 HostB. 4444 Context #1 is using IPA1 and IPB1 as ULIDs. The locator set 4445 associated to IPA1 is IPA1 and IPA2 while the locator set associated 4446 to IPB1 is just IPB1. 4448 Context #2 uses IPA3 and IPB2 as ULIDs. The locator set associated 4449 to IPA3 is IPA3 and IPA4 and the locator set associated to IPB2 is 4450 just IPB2. 4452 Because the locator sets of the Context #1 and Context #2 are 4453 disjoint, hosts could think that the same context tag value can be 4454 assigned to both of them. The problem arrives when later on IPA3 is 4455 added as a valid locator for IPA1 and IPB2 is added as a valid 4456 locator for IPB1 in Context #1. In this case, the triple would not identify a 4458 unique context anymore and correct demultiplexing is no longer 4459 possible. 4461 A possible approach to overcome this limitation is simply not to 4462 repeat the Flow Label values for any communication established in a 4463 host. This basically means that each time a new communication that 4464 is using different ULIDs is established, a new Flow Label value is 4465 assigned to it. By this mean, each communication that is using 4466 different ULIDs can be differentiated because it has a different Flow 4467 Label value. 4469 The problem with such approach is that it requires that the receiver 4470 of the communication allocates the Flow Label value used for incoming 4471 packets, in order to assign them uniquely. For this, a shim 4472 negotiation of the Flow Label value to use in the communication is 4473 needed before exchanging data packets. This poses problems with non- 4474 shim capable hosts, since they would not be able to negotiate an 4475 acceptable value for the Flow Label. This limitation can be lifted 4476 by marking the packets that belong to shim sessions from those that 4477 do not. These marking would require at least a bit in the IPv6 4478 header that is not currently available, so more creative options 4479 would be required, for instance using new Next Header values to 4480 indicate that the packet belongs to a shim6 enabled communication and 4481 that the Flow Label carries context information as proposed in the 4482 now expired NOID draft. . However, even if this is done, this 4483 approach is incompatible with the deferred establishment capability 4484 of the shim protocol, which is a preferred function, since it 4485 suppresses the delay due to the shim context establishment prior to 4486 initiation of the communication and it also allows nodes to define at 4487 which stage of the communication they decide, based on their own 4488 policies, that a given communication requires to be protected by the 4489 shim. 4491 In order to cope with the identified limitations, an alternative 4492 approach that does not constraints the flow label values used by 4493 communications that are using ULIDs equal to the locators (i.e. no 4494 shim translation) is to only require that different flow label values 4495 are assigned to different shim contexts. In such approach 4496 communications start with unmodified flow label usage (could be zero, 4497 or as suggested in [16]). The packets sent after a failure when a 4498 different locator pair is used would use a completely different flow 4499 label, and this flow label could be allocated by the receiver as part 4500 of the shim context establishment. Since it is allocated during the 4501 context establishment, the receiver of the "failed over" packets can 4502 pick a flow label of its choosing (that is unique in the sense that 4503 no other context is using it as a context tag), without any 4504 performance impact, and respecting that for each locator pair, the 4505 flow label value used for a given locator pair doesn't change due to 4506 the operation of the multihoming shim. 4508 In this approach, the constraint is that Flow Label values being used 4509 as context identifiers cannot be used by other communications that 4510 use non-disjoint locator sets. This means that once that a given 4511 Flow Label value has been assigned to a shim context that has a 4512 certain locator sets associated, the same value cannot be used for 4513 other communications that use an address pair that is contained in 4514 the locator sets of the context. This is a constraint in the 4515 potential Flow Label allocation strategies. 4517 A possible workaround to this constraint is to mark shim packets that 4518 require translation, in order to differentiate them from regular IPv6 4519 packets, using the artificial Next Header values described above. In 4520 this case, the Flow Label values constrained are only those of the 4521 packets that are being translated by the shim. This last approach 4522 would be the preferred approach if the context tag is to be carried 4523 in the Flow Label field. This is not only because it imposes the 4524 minimum constraints to the Flow Label allocation strategies, limiting 4525 the restrictions only to those packets that need to be translated by 4526 the shim, but also because Context Loss detection mechanisms greatly 4527 benefit from the fact that shim data packets are identified as such, 4528 allowing the receiving end to identify if a shim context associated 4529 to a received packet is suppose to exist, as it will be discussed in 4530 the Context Loss detection appendix below. 4532 Appendix D.2.2. Extension Header 4534 Another approach, which is the one selected for this protocol, is to 4535 carry the context tag in a new Extension Header. These context tags 4536 are allocated by the receiving end during the shim6 protocol initial 4537 negotiation, implying that each context will have two context tags, 4538 one for each direction. Data packets will be demultiplexed using the 4539 context tag carried in the Extension Header. This seems a clean 4540 approach since it does not overload existing fields. However, it 4541 introduces additional overhead in the packet due to the additional 4542 header. The additional overhead introduced is 8 octets. However, it 4543 should be noted that the context tag is only required when a locator 4544 other than the one used as ULID is contained in the packet. Packets 4545 where both the source and destination address fields contain the 4546 ULIDs do not require a context tag, since no rewriting is necessary 4547 at the receiver. This approach would reduce the overhead, because 4548 the additional header is only required after a failure. On the other 4549 hand, this approach would cause changes in the available MTU for some 4550 packets, since packets that include the Extension Header will have an 4551 MTU 8 octets shorter. However, path changes through the network can 4552 result in different MTU in any case, thus having a locator change, 4553 which implies a path change, affect the MTU doesn't introduce any new 4554 issues. 4556 Appendix D.3. Context Loss Detection 4558 In this appendix we will present different approaches considered to 4559 detect context loss and potential context recovery strategies. The 4560 scenario being considered is the following: Node A and Node B are 4561 communicating using IPA1 and IPB1. Sometime later, a shim context is 4562 established between them, with IPA1 and IPB1 as ULIDs and 4563 IPA1,...,IPAn and IPB1,...,IPBm as locator set respectively. 4565 It may happen, that later on, one of the hosts, e.g. Host A looses 4566 the shim context. The reason for this can be that Host A has a more 4567 aggressive garbage collection policy than HostB or that an error 4568 occurred in the shim layer at host A resulting in the loss of the 4569 context state. 4571 The mechanisms considered in this appendix are aimed to deal with 4572 this problem. There are essentially two tasks that need to be 4573 performed in order to cope with this problem: first, the context loss 4574 must be detected and second the context needs to be recovered/ 4575 reestablished. 4577 Mechanisms for detecting context. loss 4579 These mechanisms basically consist in that each end of the context 4580 periodically sends a packet containing context-specific information 4581 to the other end. Upon reception of such packets, the receiver 4582 verifies that the required context exists. In case that the context 4583 does not exist, it sends a packet notifying the problem to the 4584 sender. 4586 An obvious alternative for this would be to create a specific context 4587 keepalive exchange, which consists in periodically sending packets 4588 with this purpose. This option was considered and discarded because 4589 it seemed an overkill to define a new packet exchange to deal with 4590 this issue. 4592 An alternative is to piggyback the context loss detection function in 4593 other existent packet exchanges. In particular, both shim control 4594 and data packets can be used for this. 4596 Shim control packets can be trivially used for this, because they 4597 carry context specific information, so that when a node receives one 4598 of such packets, it will verify if the context exists. However, shim 4599 control frequency may not be adequate for context loss detection 4600 since control packet exchanges can be very limited for a session in 4601 certain scenarios. 4603 Data packets, on the other hand, are expected to be exchanged with a 4604 higher frequency but they do not necessarily carry context specific 4605 information. In particular, packets flowing before a locator change 4606 (i.e. packet carrying the ULIDs in the address fields) do not need 4607 context information since they do not need any shim processing. 4608 Packets that carry locators that differ from the ULIDs carry context 4609 information. 4611 However, we need to make a distinction here between the different 4612 approaches considered to carry the context tag, in particular between 4613 those approaches where packets are explicitly marked as shim packets 4614 and those approaches where packets are not marked as such. For 4615 instance, in the case where the context tag is carried in the Flow 4616 Label and packets are not marked as shim packets (i.e. no new Next 4617 Header values are defined for shim), a receiver that has lost the 4618 associated context is not able to detect that the packet is 4619 associated with a missing context. The result is that the packet 4620 will be passed unchanged to the upper layer protocol, which in turn 4621 will probably silently discard it due to a checksum error. The 4622 resulting behavior is that the context loss is undetected. This is 4623 one additional reason to discard an approach that carries the context 4624 tag in the Flow Label field and does not explicitly mark the shim 4625 packets as such. On the other hand, approaches that mark shim data 4626 packets (like the Extension Header or the Flow Label with new Next 4627 Header values approaches) allow the receiver to detect if the context 4628 associated to the received packet is missing. In this case, data 4629 packets also perform the function of a context loss detection 4630 exchange. However, it must be noted that only those packets that 4631 carry a locator that differs form the ULID are marked. This 4632 basically means that context loss will be detected after an outage 4633 has occurred i.e. alternative locators are being used. 4635 Summarizing, the proposed context loss detection mechanisms uses shim 4636 control packets and payload extension headers to detect context loss. 4637 Shim control packets detect context loss during the whole lifetime of 4638 the context, but the expected frequency in some cases is very low. 4639 On the other hand, payload extension headers have a higher expected 4640 frequency in general, but they only detect context loss after an 4641 outage. This behavior implies that it will be common that context 4642 loss is detected after a failure i.e. once that it is actually 4643 needed. Because of that, a mechanism for recovering from context 4644 loss is required if this approach is used. 4646 Overall, the mechanism for detecting lost context would work as 4647 follows: the end that still has the context available sends a message 4648 referring to the context. Upon the reception of such message, the 4649 end that has lost the context identifies the situation and notifies 4650 the context loss event to the other end by sending a packet 4651 containing the lost context information extracted from the received 4652 packet. 4654 One option is to simply send an error message containing the received 4655 packets (or at least as much of the received packet that the MTU 4656 allows to fit in). One of the goals of this notification is to allow 4657 the other end that still retains context state, to reestablish the 4658 lost context. The mechanism to reestablish the loss context consists 4659 in performing the 4-way initial handshake. This is a time consuming 4660 exchange and at this point time may be critical since we are 4661 reestablishing a context that is currently needed (because context 4662 loss detection may occur after a failure). So, another option, which 4663 is the one used in this protocol, is to replace the error message by 4664 a modified R1 message, so that the time required to perform the 4665 context establishment exchange can be reduced. Upon the reception of 4666 this modified R1 message, the end that still has the context state 4667 can finish the context establishment exchange and restore the lost 4668 context. 4670 Appendix D.4. Securing locator sets 4672 The adoption of a protocol like SHIM that allows the binding of a 4673 given ULID with a set of locators opens the doors for different types 4674 of redirection attacks as described in [19]. The goal in terms of 4675 security for the design of the shim protocol is not to introduce any 4676 new vulnerability in the Internet architecture. It is a non-goal to 4677 provide additional protection than the currently available in the 4678 single-homed IPv6 Internet. 4680 Multiple security mechanisms were considered to protect the shim 4681 protocol. In this appendix we will present some of them. 4683 The simplest option to protect the shim protocol was to use cookies 4684 i.e. a randomly generated bit string that is negotiated during the 4685 context establishment phase and then it is included in following 4686 signaling messages. By this mean, it would be possible to verify 4687 that the party that was involved in the initial handshake is the same 4688 party that is introducing new locators. Moreover, before using a new 4689 locator, an exchange is performed through the new locator, verifying 4690 that the party located at the new locator knows the cookie i.e. that 4691 it is the same party that performed the initial handshake. 4693 While this security mechanisms does indeed provide a fair amount of 4694 protection, it does leave the door open for the so-called time 4695 shifted attacks. In these attacks, an attacker that once was on the 4696 path, it discovers the cookie by sniffing any signaling message. 4697 After that, the attacker can leave the path and still perform a 4698 redirection attack, since as he is in possession of the cookie, he 4699 can introduce a new locator in the locator set and he can also 4700 successfully perform the reachability exchange if he is able to 4701 receive packets at the new locator. The difference with the current 4702 single-homed IPv6 situation is that in the current situation the 4703 attacker needs to be on-path during the whole lifetime of the attack, 4704 while in this new situation where only cookie protection if provided, 4705 an attacker that once was on the path can perform attacks after he 4706 has left the on-path location. 4708 Moreover, because the cookie is included in signaling messages, the 4709 attacker can discover the cookie by sniffing any of them, making the 4710 protocol vulnerable during the whole lifetime of the shim context. A 4711 possible approach to increase the security was to use a shared secret 4712 i.e. a bit string that is negotiated during the initial handshake but 4713 that is used as a key to protect following messages. With this 4714 technique, the attacker must be present on the path sniffing packets 4715 during the initial handshake, since it is the only moment where the 4716 shared secret is exchanged. While this improves the security, it is 4717 still vulnerable to time shifted attacks, even though it imposes that 4718 the attacker must be on path at a very specific moment (the 4719 establishment phase) to actually be able to launch the attack. While 4720 this seems to substantially improve the situation, it should be noted 4721 that, depending on protocol details, an attacker may be able to force 4722 the recreation of the initial handshake (for instance by blocking 4723 messages and making the parties think that the context has been 4724 lost), so the resulting situation may not differ that much from the 4725 cookie based approach. 4727 Another option that was discussed during the design of the protocol 4728 was the possibility of using IPsec for protecting the shim protocol. 4729 Now, the problem under consideration in this scenario is how to 4730 securely bind an address that is being used as ULID with a locator 4731 set that can be used to exchange packets. The mechanism provided by 4732 IPsec to securely bind the address used with the cryptographic keys 4733 is the usage of digital certificates. This implies that an IPsec 4734 based solution would require that the generation of digital 4735 certificates that bind the key and the ULID by a common third trusted 4736 party for both parties involved in the communication. Considering 4737 that the scope of application of the shim protocol is global, this 4738 would imply a global public key infrastructure. The major issues 4739 with this approach are the deployment difficulties associated with a 4740 global PKI. 4742 Finally two different technologies were selected to protect the shim 4743 protocol: HBA [7] and CGA [6]. These two approaches provide a 4744 similar level of protection but they provide different functionality 4745 with a different computational cost. 4747 The HBA mechanism relies on the capability of generating all the 4748 addresses of a multihomed host as an unalterable set of intrinsically 4749 bound IPv6 addresses, known as an HBA set. In this approach, 4750 addresses incorporate a cryptographic one-way hash of the prefix-set 4751 available into the interface identifier part. The result is that the 4752 binding between all the available addresses is encoded within the 4753 addresses themselves, providing hijacking protection. Any peer using 4754 the shim protocol node can efficiently verify that the alternative 4755 addresses proposed for continuing the communication are bound to the 4756 initial address through a simple hash calculation. A limitation of 4757 the HBA technique is that once generated the address set is fixed and 4758 cannot be changed without also changing all the addresses of the HBA 4759 set. In other words, the HBA technique does not support dynamic 4760 addition of address to a previously generated HBA set. An advantage 4761 of this approach is that it requires only hash operations to verify a 4762 locator set, imposing very low computational cost to the protocol. 4764 In a CGA based approach the address used as ULID is a CGA that 4765 contains a hash of a public key in its interface identifier. The 4766 result is a secure binding between the ULID and the associated key 4767 pair. This allows each peer to use the corresponding private key to 4768 sign the shim messages that convey locator set information. The 4769 trust chain in this case is the following: the ULID used for the 4770 communication is securely bound to the key pair because it contains 4771 the hash of the public key, and the locator set is bound to the 4772 public key through the signature. The CGA approach then supports 4773 dynamic addition of new locators in the locator set, since in order 4774 to do that, the node only needs to sign the new locator with the 4775 private key associated with the CGA used as ULID. A limitation of 4776 this approach is that it imposes systematic usage of public key 4777 cryptography with its associate computational cost. 4779 Any of these two mechanisms HBA and CGA provide time-shifted attack 4780 protection, since the ULID is securely bound to a locator set that 4781 can only be defined by the owner of the ULID. 4783 So, the design decision adopted was that both mechanisms HBA and CGA 4784 are supported, so that when only stable address sets are required, 4785 the nodes can benefit from the low computational cost offered by HBA 4786 while when dynamic locator sets are required, this can be achieved 4787 through CGAs with an additional cost. Moreover, because HBAs are 4788 defined as a CGA extension, the addresses available in a node can 4789 simultaneously be CGAs and HBAs, allowing the usage of the HBA and 4790 CGA functionality when needed without requiring a change in the 4791 addresses used. 4793 Appendix D.5. ULID-pair context establishment exchange 4795 Two options were considered for the ULID-pair context establishment 4796 exchange: a 2-way handshake and a 4-way handshake. 4798 A key goal for the design of this exchange was that protection 4799 against DoS attacks. The attack under consideration was basically a 4800 situation where an attacker launches a great amount of ULID-pair 4801 establishment request packets, exhausting victim's resources, similar 4802 to TCP SYN flooding attacks. 4804 A 4 way-handshake exchange protects against these attacks because the 4805 receiver does not creates any state associate to a given context 4806 until the reception of the second packet which contains a prior 4807 contact proof in the form of a token. At this point the receiver can 4808 verify that at least the address used by the initiator is at some 4809 extent valid, since the initiator is able to receive packets at this 4810 address. In the worse case, the responder can track down the 4811 attacker using this address. The drawback of this approach is that 4812 it imposes a 4 packet exchange for any context establishment. This 4813 would be a great deal if the shim context needed to be established up 4814 front, before the communication can proceed. However, thanks to 4815 deferred context establishment capability of the shim protocol, this 4816 limitation has a reduced impact in the performance of the protocol. 4817 (It may however have a greater impact in the situation of context 4818 recover as discussed earlier, but in this case, it is possible to 4819 perform optimizations to reduce the number of packets as described 4820 above) 4822 The other option considered was a 2-way handshake with the 4823 possibility to fall back to a 4-way handshake in case of attack. In 4824 this approach, the ULID-pair establishment exchange normally consists 4825 in a 2-packet exchange and it does not verify that the initiator has 4826 performed a prior contact before creating context state. In case 4827 that a DoS attack is detected, the responder falls back to a 4-way 4828 handshake similar to the one described previously in order to prevent 4829 the detected attack to proceed. The main difficulty with this attack 4830 is how to detect that a responder is currently under attack. It 4831 should be noted, that because this is 2-way exchange, it is not 4832 possible to use the number of half open sessions (as in TCP) to 4833 detect an ongoing attack and different heuristics need to be 4834 considered. 4836 The design decision taken was that considering the current impact of 4837 DoS attacks and the low impact of the 4-way exchange in the shim 4838 protocol thanks to the deferred context establishment capability, a 4839 4-way exchange would be adopted for the base protocol. 4841 Appendix D.6. Updating locator sets 4843 There are two possible approaches to the addition and removal of 4844 locators: atomic and differential approaches. The atomic approach 4845 essentially send the complete locators set each time that a variation 4846 in the locator set occurs. The differential approach send the 4847 differences between the existing locator set and the new one. The 4848 atomic approach imposes additional overhead, since all the locator 4849 set has to be exchanged each time while the differential approach 4850 requires re-synchronization of both ends through changes i.e. that 4851 both ends have the same idea about what the current locator set is. 4853 Because of the difficulties imposed by the synchronization 4854 requirement, the atomic approach was selected. 4856 Appendix D.7. State Cleanup 4858 There are essentially two approaches for discarding an existing state 4859 about locators, keys and identifiers of a correspondent node: a 4860 coordinated approach and an unilateral approach. 4862 In the unilateral approach, each node discards the information about 4863 the other node without coordination with the other node based on some 4864 local timers and heuristics. No packet exchange is required for 4865 this. In this case, it would be possible that one of the nodes has 4866 discarded the state while the other node still hasn't. In this case, 4867 a No-Context error message may be required to inform about the 4868 situation and possibly a recovery mechanism is also needed. 4870 A coordinated approach would use an explicit CLOSE mechanism, akin to 4871 the one specified in HIP [25]. If an explicit CLOSE handshake and 4872 associated timer is used, then there would no longer be a need for 4873 the No Context Error message due to a peer having garbage collected 4874 its end of the context. However, there is still potentially a need 4875 to have a No Context Error message in the case of a complete state 4876 loss of the peer (also known as a crash followed by a reboot). Only 4877 if we assume that the reboot takes at least the CLOSE timer, or that 4878 it is ok to not provide complete service until CLOSE timer minutes 4879 after the crash, can we completely do away with the No Context Error 4880 message. 4882 In addition, other aspect that is relevant for this design choice is 4883 the context confusion issue. In particular, using an unilateral 4884 approach to discard context state clearly opens the possibility of 4885 context confusion, where one of the ends unilaterally discards the 4886 context state, while the peer does not. In this case, the end that 4887 has discarded the state can re-use the context tag value used for the 4888 discarded state for a another context, creating a potential context 4889 confusion situation. In order to illustrate the cases where problems 4890 would arise consider the following scenario: 4892 o Hosts A and B establish context 1 using CTA and CTB as context 4893 tags. 4895 o Later on, A discards context 1 and the context tag value CTA 4896 becomes available for reuse. 4898 o However, B still keeps context 1. 4900 This would become a context confusion situation in the following two 4901 cases: 4903 o A new context 2 is established between A and B with a different 4904 ULID pair (or Forked Instance Identifier), and A uses CTA as 4905 context tag, If the locator sets used for both contexts are not 4906 disjoint, we are in a context confusion situation. 4908 o A new context is established between A and C and A uses CTA as 4909 context tag value for this new context. Later on, B sends Payload 4910 extension header and/or control messages containing CTA, which 4911 could be interpreted by A as belonging to context 2 (if no proper 4912 care is taken). Again we are in a context confusion situation. 4914 One could think that using a coordinated approach would eliminate 4915 these context confusion situations, making the protocol much simpler. 4916 However, this is not the case, because even in the case of a 4917 coordinated approach using a CLOSE/CLOSE ACK exchange, there is still 4918 the possibility of a host rebooting without having the time to 4919 perform the CLOSE exchange. So, it is true that the coordinated 4920 approach eliminates the possibility of a context confusion situation 4921 because premature garbage collection, but it does not prevents the 4922 same situations due to a crash and reboot of one of the involved 4923 hosts. The result is that even if we went for a coordinated 4924 approach, we would still need to deal with context confusion and 4925 provide the means to detect and recover from this situations. 4927 Appendix E. Change Log 4929 [RFC Editor: please remove this section] 4931 The following changes have been made since draft-ietf-shim6-proto-04: 4933 o Defined I1_RETRIES_MAX as 4. 4935 o Added text in section 7.9 clarifying the no per context state is 4936 stored at the receiver in order to reply an I1 message. 4938 o Added text in section 5 and in section 5.14 in particular, on 4939 defining additional options (including critical and non critical 4940 options). 4942 o Added text in the security considerations about threats related to 4943 secret S for generating the validators and recommendation to 4944 change S periodically. 4946 o Added text in the security considerations about the effects of 4947 attacks based on guessing the context tag being similar to 4948 spoofing source addresses in the case of payload packets. 4950 o Added clarification on what a recent nonce is in I2 and I2bis. 4952 o Removed (empty) open issues section. 4954 o Editorial corrections. 4956 The following changes have been made since draft-ietf-shim6-proto-03: 4958 o Editorial clarifications based on comments from Geoff, Shinta, 4959 Jari. 4961 o Added "no IPv6 NATs as an explicit assumption. 4963 o Moving some things out of the Introduction and Overview sections 4964 to remove all SHOULDs and MUSTs from there. 4966 o Added requirement that any Locator Preference options which use an 4967 element length greater than 3 octets have the already defined 4968 first 3 octets of flags, priority and weight. 4970 o Fixed security hole where a single message (I1) could cause 4971 CT(peer) to be updated. Now a three-way handshake is required 4972 before CT(peer) is updated for an existing context. 4974 The following changes have been made since draft-ietf-shim6-proto-02: 4976 o Replaced the Context Error message with the R1bis message. 4978 o Removed the Packet In Error option, since it was only used in the 4979 Context Error message. 4981 o Introduced a I2bis message which is sent in response to an I1bis 4982 message, since the responders processing is quite in this case 4983 than in the regular R1 case. 4985 o Moved the packet formats for the Keepalive and Probe message types 4986 and Event option to [8]. Only the message type values and option 4987 type value are specified for those in this document. 4989 o Removed the unused message types. 4991 o Added a state machine description as an appendix. 4993 o Filled in all the TBDs - except the IANA assignment of the 4994 protocol number. 4996 o Specified how context recovery and forked contexts work together. 4997 This required the introduction of a Forked Instance option to be 4998 able to tell which of possibly forked instances is being 4999 recovered. 5001 o Renamed the "host-pair context" to be "ULID-pair context". 5003 o Picked some initial retransmit timers for I1 and I2; 4 seconds. 5005 o Added timer values as protocol constants. The retransmit timers 5006 use binary exponential backoff and randomization (between .5 and 5007 1.5 of the nominal value). 5009 o Require that the R1/R1bis verifiers be usable for some minimum 5010 time so that the initiator knows for how long time it can safely 5011 retransmit I2 before it needs to go back to sending I1 again. 5012 Picked 30 seconds. 5014 o Split the message type codes into 0-63, which will not generate 5015 R1bis messages, and 64-127 which will generate R1bis messages. 5016 This allows extensibility of the protocol with new message types 5017 while being able to control when R1bis is generated. 5019 o Expanded the context tag from 32 to 47 bits. 5021 o Specified that enough locators need to be included in I2 and R2 5022 messages. Specified that the HBA/CGA verification must be 5023 performed when the locator set is received. 5025 o Specified that ICMP parameter problem errors are sent in certain 5026 error cases, for instance when the verification method is unknown 5027 to the receiver, or there is an unknown message type or option 5028 type. 5030 o Renamed "payload message" to be "payload extension header". 5032 o Many editorial clarifications suggested by Geoff Huston. 5034 o Modified the dispatching of payload extension header to only 5035 compare CT(local) i.e., not compare the source and destination 5036 IPv6 address fields. 5038 The following changes have been made since draft-ietf-shim6-proto-00: 5040 o Removed the use of the flow label and the overloading of the IP 5041 protocol numbers. Instead, when the locator pair is not the ULID 5042 pair, the ULP payloads will be carried with an 8 octet extension 5043 header. The belief is that it is possible to remove these extra 5044 bytes by defining future shim6 extensions that exchange more 5045 information between the hosts, without having to overload the flow 5046 label or the IP protocol numbers. 5048 o Grew the context tag from 20 bits to 32 bits, with the possibility 5049 to grow it to 47 bits. This implies changes to the message 5050 formats. 5052 o Almost by accident, the new shim6 message format is very close to 5053 the HIP message format. 5055 o Adopted the HIP format for the options, since this makes it easier 5056 to describe variable length options. The original, ND-style, 5057 option format requires internal padding in the options to make 5058 them 8 octet length in total, while the HIP format handles that 5059 using the option length field. 5061 o Removed some of the control messages, and renamed the other ones. 5063 o Added a "generation" number to the Locator List option, so that 5064 the peers can ensure that the preferences refer to the right 5065 "version" of the Locator List. 5067 o In order for FBD and exploration to work when there the use of the 5068 context is forked, that is different ULP messages are sent over 5069 different locator pairs, things are a lot easier if there is only 5070 one current locator pair used for each context. Thus the forking 5071 of the context is now causing a new context to be established for 5072 the same ULID; the new context having a new context tag. The 5073 original context is referred to as the "default" context for the 5074 ULID pair. 5076 o Added more background material and textual descriptions. 5078 19. References 5080 19.1. Normative References 5082 [1] Bradner, S., "Key words for use in RFCs to Indicate Requirement 5083 Levels", BCP 14, RFC 2119, March 1997. 5085 [2] Deering, S. and R. Hinden, "Internet Protocol, Version 6 (IPv6) 5086 Specification", RFC 2460, December 1998. 5088 [3] Narten, T., Nordmark, E., and W. Simpson, "Neighbor Discovery 5089 for IP Version 6 (IPv6)", RFC 2461, December 1998. 5091 [4] Thomson, S. and T. Narten, "IPv6 Stateless Address 5092 Autoconfiguration", RFC 2462, December 1998. 5094 [5] Conta, A. and S. Deering, "Internet Control Message Protocol 5095 (ICMPv6) for the Internet Protocol Version 6 (IPv6) 5096 Specification", RFC 2463, December 1998. 5098 [6] Aura, T., "Cryptographically Generated Addresses (CGA)", 5099 RFC 3972, March 2005. 5101 [7] Bagnulo, M., "Hash Based Addresses (HBA)", 5102 draft-ietf-shim6-hba-01 (work in progress), October 2005. 5104 [8] Arkko, J. and I. Beijnum, "Failure Detection and Locator Pair 5105 Exploration Protocol for IPv6 Multihoming", 5106 draft-ietf-shim6-failure-detection-03 (work in progress), 5107 December 2005. 5109 19.2. Informative References 5111 [9] Gulbrandsen, A., Vixie, P., and L. Esibov, "A DNS RR for 5112 specifying the location of services (DNS SRV)", RFC 2782, 5113 February 2000. 5115 [10] Ferguson, P. and D. Senie, "Network Ingress Filtering: 5116 Defeating Denial of Service Attacks which employ IP Source 5117 Address Spoofing", BCP 38, RFC 2827, May 2000. 5119 [11] Narten, T. and R. Draves, "Privacy Extensions for Stateless 5120 Address Autoconfiguration in IPv6", RFC 3041, January 2001. 5122 [12] Draves, R., "Default Address Selection for Internet Protocol 5123 version 6 (IPv6)", RFC 3484, February 2003. 5125 [13] Bagnulo, M., "Updating RFC 3484 for multihoming support", 5126 draft-bagnulo-ipv6-rfc3484-update-00 (work in progress), 5127 December 2005. 5129 [14] Schulzrinne, H., Casner, S., Frederick, R., and V. Jacobson, 5130 "RTP: A Transport Protocol for Real-Time Applications", STD 64, 5131 RFC 3550, July 2003. 5133 [15] Abley, J., Black, B., and V. Gill, "Goals for IPv6 Site- 5134 Multihoming Architectures", RFC 3582, August 2003. 5136 [16] Rajahalme, J., Conta, A., Carpenter, B., and S. Deering, "IPv6 5137 Flow Label Specification", RFC 3697, March 2004. 5139 [17] Eastlake, D., Schiller, J., and S. Crocker, "Randomness 5140 Requirements for Security", BCP 106, RFC 4086, June 2005. 5142 [18] Hinden, R. and B. Haberman, "Unique Local IPv6 Unicast 5143 Addresses", RFC 4193, October 2005. 5145 [19] Nordmark, E. and T. Li, "Threats Relating to IPv6 Multihoming 5146 Solutions", RFC 4218, October 2005. 5148 [20] Huitema, C., "Ingress filtering compatibility for IPv6 5149 multihomed sites", draft-huitema-shim6-ingress-filtering-00 5150 (work in progress), September 2005. 5152 [21] Bagnulo, M. and E. Nordmark, "SHIM - MIPv6 Interaction", 5153 draft-bagnulo-shim6-mip-00 (work in progress), July 2005. 5155 [22] Nordmark, E., "Shim6 Application Referral Issues", 5156 draft-ietf-shim6-app-refer-00 (work in progress), July 2005. 5158 [23] Abley, J., "Shim6 Applicability Statement", 5159 draft-ietf-shim6-applicability-00 (work in progress), 5160 July 2005. 5162 [24] Huston, G., "Architectural Commentary on Site Multi-homing 5163 using a Level 3 Shim", draft-ietf-shim6-arch-00 (work in 5164 progress), July 2005. 5166 [25] Moskowitz, R., "Host Identity Protocol", draft-ietf-hip-base-05 5167 (work in progress), March 2006. 5169 [26] Eronen, P., "IKEv2 Mobility and Multihoming Protocol (MOBIKE)", 5170 draft-ietf-mobike-protocol-08 (work in progress), 5171 February 2006. 5173 Authors' Addresses 5175 Erik Nordmark 5176 Sun Microsystems 5177 17 Network Circle 5178 Menlo Park, CA 94025 5179 USA 5181 Phone: +1 650 786 2921 5182 Email: erik.nordmark@sun.com 5184 Marcelo Bagnulo 5185 Universidad Carlos III de Madrid 5186 Av. Universidad 30 5187 Leganes, Madrid 28911 5188 SPAIN 5190 Phone: +34 91 6248814 5191 Email: marcelo@it.uc3m.es 5192 URI: http://www.it.uc3m.es 5194 Intellectual Property Statement 5196 The IETF takes no position regarding the validity or scope of any 5197 Intellectual Property Rights or other rights that might be claimed to 5198 pertain to the implementation or use of the technology described in 5199 this document or the extent to which any license under such rights 5200 might or might not be available; nor does it represent that it has 5201 made any independent effort to identify any such rights. Information 5202 on the procedures with respect to rights in RFC documents can be 5203 found in BCP 78 and BCP 79. 5205 Copies of IPR disclosures made to the IETF Secretariat and any 5206 assurances of licenses to be made available, or the result of an 5207 attempt made to obtain a general license or permission for the use of 5208 such proprietary rights by implementers or users of this 5209 specification can be obtained from the IETF on-line IPR repository at 5210 http://www.ietf.org/ipr. 5212 The IETF invites any interested party to bring to its attention any 5213 copyrights, patents or patent applications, or other proprietary 5214 rights that may cover technology that may be required to implement 5215 this standard. Please address the information to the IETF at 5216 ietf-ipr@ietf.org. 5218 Disclaimer of Validity 5220 This document and the information contained herein are provided on an 5221 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS 5222 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET 5223 ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, 5224 INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE 5225 INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 5226 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 5228 Copyright Statement 5230 Copyright (C) The Internet Society (2006). This document is subject 5231 to the rights, licenses and restrictions contained in BCP 78, and 5232 except as set forth therein, the authors retain all their rights. 5234 Acknowledgment 5236 Funding for the RFC Editor function is currently provided by the 5237 Internet Society.