idnits 2.17.1 draft-ietf-behave-v6v4-xlate-10.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** You're using the IETF Trust Provisions' Section 6.b License Notice from 12 Sep 2009 rather than the newer Notice from 28 Dec 2009. (See https://trustee.ietf.org/license-info/) Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- == There are 1 instance of lines with non-RFC6890-compliant IPv4 addresses in the document. If these are example addresses, they should be changed. -- The draft header indicates that this document obsoletes RFC2765, but the abstract doesn't seem to directly say this. It does mention RFC2765 though, so this could be OK. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == The document seems to contain a disclaimer for pre-RFC5378 work, but was first submitted on or after 10 November 2008. The disclaimer is usually necessary only for documents that revise or obsolete older RFCs, and that take significant amounts of text from those RFCs. If you can contact all authors of the source material and they are willing to grant the BCP78 rights to the IETF Trust, you can and should remove the disclaimer. Otherwise, the disclaimer is needed and you can ignore this comment. (See the Legal Provisions document at https://trustee.ietf.org/license-info for more information.) -- The document date (February 27, 2010) is 5165 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) == Unused Reference: 'RFC4213' is defined on line 1330, but no explicit reference was found in the text ** Obsolete normative reference: RFC 793 (Obsoleted by RFC 9293) ** Obsolete normative reference: RFC 879 (Obsoleted by RFC 7805, RFC 9293) ** Obsolete normative reference: RFC 2460 (Obsoleted by RFC 8200) ** Obsolete normative reference: RFC 2765 (Obsoleted by RFC 6145) ** Obsolete normative reference: RFC 2766 (Obsoleted by RFC 4966) == Outdated reference: A later version (-10) exists of draft-ietf-behave-address-format-04 == Outdated reference: A later version (-10) exists of draft-ietf-behave-v6v4-framework-06 == Outdated reference: A later version (-12) exists of draft-ietf-behave-v6v4-xlate-stateful-08 -- Obsolete informational reference (is this intentional?): RFC 3171 (Obsoleted by RFC 5771) Summary: 6 errors (**), 0 flaws (~~), 7 warnings (==), 3 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 behave X. Li 3 Internet-Draft C. Bao 4 Obsoletes: 2765 (if approved) CERNET Center/Tsinghua University 5 Intended status: Standards Track F. Baker 6 Expires: August 31, 2010 Cisco Systems 7 February 27, 2010 9 IP/ICMP Translation Algorithm 10 draft-ietf-behave-v6v4-xlate-10 12 Abstract 14 This document forms a replacement of the Stateless IP/ICMP 15 Translation Algorithm (SIIT) described in RFC 2765. The algorithm 16 translates between IPv4 and IPv6 packet headers (including ICMP 17 headers). 19 Status of this Memo 21 This Internet-Draft is submitted to IETF in full conformance with the 22 provisions of BCP 78 and BCP 79. 24 Internet-Drafts are working documents of the Internet Engineering 25 Task Force (IETF), its areas, and its working groups. Note that 26 other groups may also distribute working documents as Internet- 27 Drafts. 29 Internet-Drafts are draft documents valid for a maximum of six months 30 and may be updated, replaced, or obsoleted by other documents at any 31 time. It is inappropriate to use Internet-Drafts as reference 32 material or to cite them other than as "work in progress." 34 The list of current Internet-Drafts can be accessed at 35 http://www.ietf.org/ietf/1id-abstracts.txt. 37 The list of Internet-Draft Shadow Directories can be accessed at 38 http://www.ietf.org/shadow.html. 40 This Internet-Draft will expire on August 31, 2010. 42 Copyright Notice 44 Copyright (c) 2010 IETF Trust and the persons identified as the 45 document authors. All rights reserved. 47 This document is subject to BCP 78 and the IETF Trust's Legal 48 Provisions Relating to IETF Documents 49 (http://trustee.ietf.org/license-info) in effect on the date of 50 publication of this document. Please review these documents 51 carefully, as they describe your rights and restrictions with respect 52 to this document. Code Components extracted from this document must 53 include Simplified BSD License text as described in Section 4.e of 54 the Trust Legal Provisions and are provided without warranty as 55 described in the BSD License. 57 This document may contain material from IETF Documents or IETF 58 Contributions published or made publicly available before November 59 10, 2008. The person(s) controlling the copyright in some of this 60 material may not have granted the IETF Trust the right to allow 61 modifications of such material outside the IETF Standards Process. 62 Without obtaining an adequate license from the person(s) controlling 63 the copyright in such materials, this document may not be modified 64 outside the IETF Standards Process, and derivative works of it may 65 not be created outside the IETF Standards Process, except to format 66 it for publication as an RFC or to translate it into languages other 67 than English. 69 Table of Contents 71 1. Introduction and Motivation . . . . . . . . . . . . . . . . . 4 72 1.1. IPv4-IPv6 Translation Model . . . . . . . . . . . . . . . 4 73 1.2. Applicability and Limitations . . . . . . . . . . . . . . 5 74 1.3. Stateless vs. Stateful Mode . . . . . . . . . . . . . . . 5 75 1.4. Path MTU Discovery and Fragmentation . . . . . . . . . . . 6 76 2. Conventions . . . . . . . . . . . . . . . . . . . . . . . . . 6 77 3. Translating from IPv4 to IPv6 . . . . . . . . . . . . . . . . 6 78 3.1. Translating IPv4 Headers into IPv6 Headers . . . . . . . . 8 79 3.2. Translating ICMPv4 Headers into ICMPv6 Headers . . . . . . 10 80 3.3. Translating ICMPv4 Error Messages into ICMPv6 . . . . . . 14 81 3.4. Translator Sending ICMPv4 Error Message . . . . . . . . . 14 82 3.5. Transport-layer Header Translation . . . . . . . . . . . . 15 83 3.6. Knowing when to Translate . . . . . . . . . . . . . . . . 15 84 4. Translating from IPv6 to IPv4 . . . . . . . . . . . . . . . . 15 85 4.1. Translating IPv6 Headers into IPv4 Headers . . . . . . . . 17 86 4.2. Translating ICMPv6 Headers into ICMPv4 Headers . . . . . . 19 87 4.3. Translating ICMPv6 Error Messages into ICMPv4 . . . . . . 22 88 4.4. Translator Sending ICMPv6 Error Message . . . . . . . . . 23 89 4.5. Transport-layer Header Translation . . . . . . . . . . . . 23 90 4.6. Knowing when to Translate . . . . . . . . . . . . . . . . 24 91 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 24 92 6. Security Considerations . . . . . . . . . . . . . . . . . . . 24 93 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 25 94 8. Appendix: Stateless translation workflow example . . . . . . . 25 95 8.1. H6 establishes communication with H4 . . . . . . . . . . . 26 96 8.2. H4 establishes communication with H6 . . . . . . . . . . . 27 97 9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 28 98 9.1. Normative References . . . . . . . . . . . . . . . . . . . 28 99 9.2. Informative References . . . . . . . . . . . . . . . . . . 29 100 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 31 102 1. Introduction and Motivation 104 This document is a product of the 2008-2010 effort to define a 105 replacement for NAT-PT [RFC2766]. It is directly derivative from 106 Erik Nordmark's [RFC2765], which provides stateless translation 107 between IPv4 [RFC0791] and IPv6 [RFC2460], and between ICMPv4 108 [RFC0792] and ICMPv6 [RFC4443]. 110 The general IPv4/IPv6 translation framework is now described in 111 [I-D.ietf-behave-v6v4-framework]. This document specifies the 112 translation algorithms between IPv4 packets and IPv6 packets. The 113 mapping algorithms between IPv4 addresses and IPv6 addresses in the 114 packet headers are specified in [I-D.ietf-behave-address-format]. 116 1.1. IPv4-IPv6 Translation Model 118 The translation model is consists of two or more network domains 119 connected by one or more IP/ICMP translators (XLATEs) as shown in 120 Figure 1. 122 -------- -------- 123 // IPv4 \\ // IPv6 \\ 124 / Domain \ / Domain \ 125 / +-----+ +--+ \ 126 | |XLATE| |S2| | Sn: Servers 127 | +--+ +-----+ +--+ | Hn: Clients 128 | |S1| +-----+ | 129 | +--+ | DNS | +--+ | XLATE: IPv4/IPv6 Translator 130 \ +--+ +-----+ |H2| / DNS: DNS64/DNS46 131 \ |H1| / \ +--+ / 132 \\ +--+ // \\ // 133 -------- -------- 135 Figure 1: IPv4-IPv6 Translation Model 137 One of those networks either routes IPv4 but not IPv6, or contains 138 some hosts that only implement IPv4 or have IPv4-only applications 139 (even if the host and the network support IPv6). The other network 140 either routes IPv6 but not IPv4, or contains some hosts that only 141 implement IPv6 or has IPv6-only applications. Both networks contain 142 clients, servers, and peers. A network domain may also consist of a 143 single host. DNS servers include DNS64 and DNS46, while DNS64 144 translates A record to AAAA record and DNS46 translates AAAA record 145 to A record. 147 1.2. Applicability and Limitations 149 This document specifies the translation algorithms itself between 150 IPv4 packets and IPv6 packets. The implementation of IPv4/IPv6 151 translation SHOULD also refer to [I-D.ietf-behave-v6v4-framework], 152 [I-D.ietf-behave-address-format] and 153 [I-D.ietf-behave-v6v4-xlate-stateful], etc. 155 As with [RFC2765], the translating function specified in this 156 document does not translate any IPv4 options and it does not 157 translate IPv6 routing headers, hop-by-hop extension headers, 158 destination options headers or source routing headers. 160 The issues and algorithms in the translation of datagrams containing 161 TCP segments are described in [RFC5382]. The considerations of that 162 document are applicable in this case as well. 164 Fragmented IPv4 UDP packets that do not contain a UDP checksum (i.e., 165 the UDP checksum field is zero) are not of significant use in the 166 Internet [Miller][Dongjin] and will not be translated by the IP/ICMP 167 translator. 169 IPv4 multicast addresses [RFC3171] cannot be mapped to IPv6 multicast 170 addresses [RFC3307] based on the unicast mapping rule. However, if a 171 multicast address mapping mechanism is defined, the IP/ICMP header 172 translation aspect of this document works. 174 Translator SHOULD make sure that the packets belonging to the same 175 flow leave the translator in the same order in which they arrived. 177 1.3. Stateless vs. Stateful Mode 179 An IP/ICMP translator has two possible modes of operation: stateless 180 and stateful [I-D.ietf-behave-v6v4-framework]. In both cases, we 181 assume that a system (a node or an application) that has an IPv4 182 address but not an IPv6 address is communicating with a system that 183 has an IPv6 address but no IPv4 address, or that the two systems do 184 not have contiguous routing connectivity and hence are forced to have 185 their communications translated. 187 In the stateless mode, a specific IPv6 address range will represent 188 IPv4 systems (IPv4-converted addresses), and the IPv6 systems have 189 addresses (IPv4-translatable addresses) that can be algorithmically 190 mapped to a subset of the service provider's IPv4 addresses. In 191 general, there is no need to concern oneself with translation tables, 192 as the IPv4 and IPv6 counterparts are algorithmically related. 194 In the stateful mode, a specific IPv6 address range will represent 195 IPv4 systems (IPv4-converted addresses), but the IPv6 systems may use 196 any [RFC4291] addresses except in that range. In this case, a 197 translation table is required to bind the IPv6 systems' addresses to 198 the IPv4 addresses maintained in the translator. 200 The address translation mechanisms for the stateless and the stateful 201 translations are defined in [I-D.ietf-behave-address-format]. 203 1.4. Path MTU Discovery and Fragmentation 205 Due to the different sizes of the IPv4 and IPv6 header, which are 20+ 206 octets and 40 octets respectively, handling the maximum packet size 207 is critical for the operation of the IPv4/IPv6 translator. There are 208 three mechanisms to handle this issue: path MTU discovery (PMTUD), 209 fragmentation, and transport-layer negotiation such as the TCP MSS 210 option [RFC0879]. Note that the translator MUST behave as a router, 211 i.e. the translator MUST send a "Packet Too Big" error message or 212 fragment the packet when the packet size exceeds the MTU of the next 213 hop interface. 215 "Don't Fragment", ICMP "Packet Too Big", and packet fragmentation are 216 discussed in sections 3 and 4 of this document. The reassembling of 217 fragmented packets in the stateful translator is discussed in 218 [I-D.ietf-behave-v6v4-xlate-stateful], since it requires state 219 maintenance in the translator. 221 2. Conventions 223 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 224 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 225 document are to be interpreted as described in [RFC2119]. 227 3. Translating from IPv4 to IPv6 229 When an IP/ICMP translator receives an IPv4 datagram addressed to a 230 destination towards the IPv6 domain, it translates the IPv4 header of 231 that packet into an IPv6 header. The original IPv4 header on the 232 packet is removed and replaced by an IPv6 header. Since the ICMPv6 233 [RFC4443], TCP [RFC0793] and UDP [RFC0768] headers contain checksums 234 that cover IP header information, if the address mapping algorithm is 235 not checksum-neutral, the ICMPv6 and transport-layer headers MUST be 236 updated. The data portion of the packet is left unchanged. The IP/ 237 ICMP translator then forwards the packet based on the IPv6 238 destination address. 240 +-------------+ +-------------+ 241 | IPv4 | | IPv6 | 242 | Header | | Header | 243 +-------------+ +-------------+ 244 | Transport | | Fragment | 245 | Layer | ===> | Header | 246 | Header | | (if needed) | 247 +-------------+ +-------------+ 248 | | | Transport | 249 ~ Data ~ | Layer | 250 | | | Header | 251 +-------------+ +-------------+ 252 | | 253 ~ Data ~ 254 | | 255 +-------------+ 257 Figure 2: IPv4-to-IPv6 Translation 259 One of the differences between IPv4 and IPv6, is that in IPv6, path 260 MTU discovery is mandatory but it is optional in IPv4. This implies 261 that IPv6 routers will never fragment a packet - only the sender can 262 do fragmentation. 264 When an IPv4 node performs path MTU discovery (by setting the Don't 265 Fragment (DF) bit in the header), path MTU discovery can operate end- 266 to-end, i.e., across the translator. In this case either IPv4 or 267 IPv6 routers (including the translator) might send back ICMP "Packet 268 Too Big" messages to the sender. When the IPv6 routers send these 269 ICMPv6 errors they will pass through a translator that will translate 270 the ICMPv6 error to a form that the IPv4 sender can understand. As a 271 result, an IPv6 fragment header is only included if the IPv4 packet 272 is already fragmented. 274 However, when the IPv4 sender does not set the Don't Fragment (DF) 275 bit, the translator has to ensure that the packet does not exceed the 276 path MTU on the IPv6 side. This is done by fragmenting the IPv4 277 packet so that it fits in 1280-byte IPv6 packets, since that is the 278 minimum IPv6 MTU. Also, when the IPv4 sender does not set the DF bit 279 the translator MUST always include an IPv6 fragment header to 280 indicate that the sender allows fragmentation. 282 The rules in section 3.1 ensure that when packets are fragmented, 283 either by the sender or by IPv4 routers, the low-order 16 bits of the 284 fragment identification are carried end-to-end, ensuring that packets 285 are correctly reassembled. In addition, the rules in section 3.1 use 286 the presence of an IPv6 fragment header to indicate that the sender 287 might not be using path MTU discovery (i.e., the packet should not 288 have the DF flag set should it later be translated back to IPv4). 290 Other than the special rules for handling fragments and path MTU 291 discovery, the actual translation of the packet header consists of a 292 simple mapping as defined below. Note that ICMPv4 packets require 293 special handling in order to translate the content of ICMPv4 error 294 messages and also to add the ICMPv6 pseudo-header checksum. 296 3.1. Translating IPv4 Headers into IPv6 Headers 298 If the DF flag is not set and the IPv4 packet will result in an IPv6 299 packet larger than 1280 bytes, the packet MUST be fragmented so the 300 resulting IPv6 packet (with Fragment header added to each fragment) 301 will be less than or equal to 1280 bytes. For example, if the packet 302 is fragmented prior to the translation, the IPv4 packets must be 303 fragmented so that their length, excluding the IPv4 header, is at 304 most 1232 bytes (1280 minus 40 for the IPv6 header and 8 for the 305 Fragment header). The resulting fragments are then translated 306 independently using the logic described below. 308 If the DF bit is set and the MTU of the next-hop interface is less 309 than the total length value of the IPv4 packet plus 20, the 310 translator MUST send an ICMPv4 "Fragmentation Needed" error message 311 to the IPv4 source address. 313 If the DF bit is set and the packet is not a fragment (i.e., the MF 314 flag is not set and the Fragment Offset is equal to zero) then the 315 translator SHOULD NOT add a Fragment header to the resulting packet. 316 The IPv6 header fields are set as follows: 318 Version: 6 320 Traffic Class: By default, copied from IP Type Of Service (TOS) 321 octet. According to [RFC2474] the semantics of the bits are 322 identical in IPv4 and IPv6. However, in some IPv4 environments 323 these fields might be used with the old semantics of "Type Of 324 Service and Precedence". An implementation of a translator SHOULD 325 provide the ability to ignore the IPv4 TOS and always set the IPv6 326 traffic class (TC) to zero. In addition, if the translator is at 327 an administrative boundary, the filtering and update 328 considerations of [RFC2475] may be applicable. 330 Flow Label: 0 (all zero bits) 332 Payload Length: Total length value from IPv4 header, minus the size 333 of the IPv4 header and IPv4 options, if present. 335 Next Header: For ICMPv4 (1) changed to ICMPv6 (58), otherwise 336 protocol field copied from IPv4 header. 338 Hop Limit: The hop limit is derived from the TTL value in the IPv4 339 header. Since the translator is a router, as part of forwarding 340 the packet it needs to decrement either the IPv4 TTL (before the 341 translation) or the IPv6 Hop Limit (after the translation). As 342 part of decrementing the TTL or Hop Limit the translator (as any 343 router) needs to check for zero and send the ICMPv4 "TTL Exceeded" 344 or ICMPv6 "Hop Limit Exceeded" error. 346 Source Address: The IPv4-converted address derived from the IPv4 347 source address per [I-D.ietf-behave-address-format] section 2.1. 349 If the translator gets an illegal source address (e.g. 0.0.0.0, 350 127.0.0.1, etc.), the translator SHOULD silently drop the packet 351 (as discussed in Section 5.3.7 of [RFC1812]). 353 Destination Address: In the stateless mode, which is to say that if 354 the IPv4 destination address is within a range of configured IPv4 355 stateless translation prefix, the IPv6 destination address is the 356 IPv4-translatable address derived from the IPv4 destination 357 address per [I-D.ietf-behave-address-format] section 2.1. A 358 workflow example of stateless translation is shown in the Appendix 359 of this document. 361 In the stateful mode, which is to say that if the IPv4 destination 362 address is not within the range of any configured IPv4 stateless 363 translation prefix, the IPv6 destination address and corresponding 364 transport-layer destination port are derived from the Binding 365 Information Bases (BIBs) reflecting current session state in the 366 translator as described in [I-D.ietf-behave-v6v4-xlate-stateful]. 368 If any IPv4 options are present in the IPv4 packet, the IPv4 options 369 MUST be ignored (i.e., there is no attempt to translate the options) 370 and the packet translated normally. However, if an unexpired source 371 route option is present then the packet MUST instead be discarded, 372 and an ICMPv4 "Destination Unreachable/Source Route Failed" (Type 373 3/Code 5) error message SHOULD be returned to the sender. 375 If there is a need to add a Fragment header (the DF bit is not set or 376 the packet is a fragment) the header fields are set as above with the 377 following exceptions: 379 IPv6 fields: 381 Payload Length: Total length value from IPv4 header, plus 8 for 382 the fragment header, minus the size of the IPv4 header and IPv4 383 options, if present. 385 Next Header: Fragment header (44). 387 Fragment header fields: 389 Next Header: For ICMPv4 (1) changed to ICMPv6 (58), otherwise 390 protocol field copied from IPv4 header. 392 Fragment Offset: Fragment Offset copied from the IPv4 header. 394 M flag: More Fragments bit copied from the IPv4 header. 396 Identification: The low-order 16 bits copied from the 397 Identification field in the IPv4 header. The high-order 16 398 bits set to zero. 400 3.2. Translating ICMPv4 Headers into ICMPv6 Headers 402 All ICMPv4 messages that are to be translated require that the ICMPv6 403 checksum field be calculated as part of the translation since ICMPv6, 404 unlike ICMPv4, has a pseudo-header checksum just like UDP and TCP. 406 In addition, all ICMPv4 packets need to have the Type value 407 translated and, for ICMPv4 error messages, the included IP header 408 also needs translation. 410 The actions needed to translate various ICMPv4 messages are as 411 follows: 413 ICMPv4 query messages: 415 Echo and Echo Reply (Type 8 and Type 0): Adjust the Type values 416 to 128 and 129, respectively, and adjust the ICMP checksum both 417 to take the type change into account and to include the ICMPv6 418 pseudo-header. 420 Information Request/Reply (Type 15 and Type 16): Obsoleted in 421 ICMPv6. Silently drop. 423 Timestamp and Timestamp Reply (Type 13 and Type 14): Obsoleted in 424 ICMPv6. Silently drop. 426 Address Mask Request/Reply (Type 17 and Type 18): Obsoleted in 427 ICMPv6. Silently drop. 429 ICMP Router Advertisement (Type 9): Single hop message. Silently 430 drop. 432 ICMP Router Solicitation (Type 10): Single hop message. Silently 433 drop. 435 Unknown ICMPv4 types: Silently drop. 437 IGMP messages: While the MLD messages [RFC2710][RFC3590][RFC3810] 438 are the logical IPv6 counterparts for the IPv4 IGMP messages 439 all the "normal" IGMP messages are single-hop messages and 440 should be silently dropped by the translator. Other IGMP 441 messages might be used by multicast routing protocols and, 442 since it would be a configuration error to try to have router 443 adjacencies across IP/ICMP translators those packets should 444 also be silently dropped. 446 ICMPv4 error messages: 448 Destination Unreachable (Type 3): For all codes that are not 449 explicitly listed below, set the Type field to 1, and adjust 450 the ICMP checksum both to take the type change into account 451 and to include the ICMPv6 pseudo-header. 453 Translate the Code field as follows: 455 Code 0, 1 (Net, host unreachable): Set Code value to 0 (no 456 route to destination). 458 Code 2 (Protocol unreachable): Translate to an ICMPv6 459 Parameter Problem (Type 4, Code value 1) and make the 460 Pointer point to the IPv6 Next Header field. 462 Code 3 (Port unreachable): Set Code value to 4 (port 463 unreachable). 465 Code 4 (Fragmentation needed and DF set): Translate to an 466 ICMPv6 Packet Too Big message (Type 2) with Code value 467 set to 0. The MTU field needs to be adjusted for the 468 difference between the IPv4 and IPv6 header sizes, i.e. 469 minimum(advertised MTU+20, MTU_of_IPv6_nexthop, 470 (MTU_of_IPv4_nexthop)+20). Note that if the IPv4 router 471 set the MTU field to zero, i.e., the router does not 472 implement [RFC1191], then the translator MUST use the 473 plateau values specified in [RFC1191] to determine a 474 likely path MTU and include that path MTU in the ICMPv6 475 packet. (Use the greatest plateau value that is less 476 than the returned Total Length field.) 478 Code 5 (Source route failed): Set Code value to 0 (No route 479 to destination). Note that this error is unlikely since 480 source routes are not translated. 482 Code 6,7: Set Code value to 0 (No route to destination). 484 Code 8: Set Code value to 0 (No route to destination). 486 Code 9, 10 (Communication with destination host 487 administratively prohibited): Set Code value to 1 488 (Communication with destination administratively 489 prohibited) 491 Code 11, 12: Set Code value to 0 (no route to destination). 493 Code 13 (Communication Administratively Prohibited): Set 494 Code value to 1 (Communication with destination 495 administratively prohibited). 497 Code 14 (Host Precedence Violation): Silently drop. 499 Code 15 (Precedence cutoff in effect): Set Code value to 1 500 (Communication with destination administratively 501 prohibited). 503 Redirect (Type 5): Single hop message. Silently drop. 505 Alternative Host Address (Type 6): Silently drop. 507 Source Quench (Type 4): Obsoleted in ICMPv6. Silently drop. 509 Time Exceeded (Type 11): Set the Type field to 3, and adjust 510 the ICMP checksum both to take the type change into account 511 and to include the ICMPv6 pseudo-header. The Code field is 512 unchanged. 514 Parameter Problem (Type 12): Set the Type field to 4, and 515 adjust the ICMP checksum both to take the type change into 516 account and to include the ICMPv6 pseudo-header. Translate 517 the Code field as follows: 519 Code 0 (Pointer indicates the error): Set the Code value to 520 0 (Erroneous header field encountered) and update the 521 pointer as defined in Figure 3 (If the Original IPv4 522 Pointer Value is not listed or the Translated IPv6 523 Pointer Value is listed as "n/a", silently drop the 524 packet). 526 Code 1 (Missing a required option): Silently drop 528 Code 2 (Bad length): Set the Code value to 0 (Erroneous 529 header field encountered) and update the pointer as 530 defined in Figure 3 (If the Original IPv4 Pointer Value 531 is not listed or the Translated IPv6 Pointer Value is 532 listed as "n/a", silently drop the packet). 534 Other Code values: Silently drop 536 Unknown ICMPv4 types: Silently drop. 538 | Original IPv4 Pointer Value | Translated IPv6 Pointer Value | 539 +--------------------------------+--------------------------------+ 540 | 0 | Version/IHL | 0 | Version/Traffic Class | 541 | 1 | Type Of Service | 1 | Traffic Class/Flow Label | 542 | 2,3 | Total Length | 4 | Payload Length | 543 | 4,5 | Identification | n/a | | 544 | 6 | Flags/Fragment Offset | n/a | | 545 | 7 | Fragment Offset | n/a | | 546 | 8 | Time to Live | 7 | Hop Limit | 547 | 9 | Protocol | 6 | Next Header | 548 |10,11| Header Checksum | n/a | | 549 |12-15| Source Address | 8 | Source Address | 550 |16-19| Destination Address | 24 | Destination Address | 551 +--------------------------------+--------------------------------+ 553 Figure 3: Pointer value for translating from IPv4 to IPv6 555 ICMP Error Payload: If the received ICMPv4 packet contains an 556 ICMPv4 Extension [RFC4884], the translation of the ICMPv4 557 packet will cause the ICMPv6 packet to change length. When 558 this occurs, the ICMPv6 Extension length attribute MUST be 559 adjusted accordingly (e.g., longer due to the translation 560 from IPv4 to IPv6). If the ICMPv4 Extension exceeds the 561 maximum size of an ICMPv6 message on the outgoing interface, 562 the ICMPv4 extension should be simply truncated. For 563 extensions not defined in [RFC4884], the translator passes 564 the extensions as opaque bit strings and those containing 565 IPv4 address literals will not have those addresses 566 translated to IPv6 address literals; this may cause problems 567 with processing of those ICMP extensions. 569 3.3. Translating ICMPv4 Error Messages into ICMPv6 571 There are some differences between the ICMPv4 and the ICMPv6 error 572 message formats as detailed above. In addition, the ICMP error 573 messages contain the packet in error, which needs to be translated 574 just like a normal IP packet. The translation of this "packet in 575 error" is likely to change the length of the datagram. Thus the 576 Payload Length field in the outer IPv6 header might need to be 577 updated. 579 +-------------+ +-------------+ 580 | IPv4 | | IPv6 | 581 | Header | | Header | 582 +-------------+ +-------------+ 583 | ICMPv4 | | ICMPv6 | 584 | Header | | Header | 585 +-------------+ +-------------+ 586 | IPv4 | ===> | IPv6 | 587 | Header | | Header | 588 +-------------+ +-------------+ 589 | Partial | | Partial | 590 | Transport | | Transport | 591 | Layer | | Layer | 592 | Header | | Header | 593 +-------------+ +-------------+ 595 Figure 4: IPv4-to-IPv6 ICMP Error Translation 597 The translation of the inner IP header can be done by invoking the 598 function that translated the outer IP headers. This process SHOULD 599 stop at the first embedded header and drop the packet if it contains 600 more. 602 3.4. Translator Sending ICMPv4 Error Message 604 If the IPv4 packet is discarded, then the translator SHOULD be able 605 to send back an ICMPv4 error message to the original sender of the 606 packet, unless the discarded packet is itself an ICMPv4 message. The 607 ICMPv4 message, if sent, has a Type value of 3 (Destination 608 Unreachable) and a Code value of 13 (Communication Administratively 609 Prohibited), unless otherwise specified in this document or in 610 [I-D.ietf-behave-v6v4-xlate-stateful]. The translator SHOULD allow 611 an administrator to configure whether the ICMPv4 error messages are 612 sent, rate-limited, or not sent. 614 3.5. Transport-layer Header Translation 616 If the address translation algorithm is not checksum neutral, the 617 recalculation and updating of the transport-layer headers MUST be 618 performed. 620 When a translator receives an unfragmented UDP IPv4 packet and the 621 checksum field is zero, the translator SHOULD compute the missing UDP 622 checksum as part of translating the packet. Also, the translator 623 SHOULD maintain a counter of how many UDP checksums are generated in 624 this manner. 626 When a stateless translator receives the first fragment of a 627 fragmented UDP IPv4 packet and the checksum field is zero, the 628 translator SHOULD drop the packet and generate a system management 629 event specifying at least the IP addresses and port numbers in the 630 packet. When it receives fragments other than the first, it SHOULD 631 silently drop the packet, since there is no port information to log. 633 For stateful translator, the handling of fragmented UDP IPv4 packets 634 with a zero checksum is discussed in 635 [I-D.ietf-behave-v6v4-xlate-stateful] section 3.1. 637 3.6. Knowing when to Translate 639 If the IP/ICMP translator also provides normal forwarding function, 640 and the destination IPv4 address is reachable by a more specific 641 route without translation, the translator MUST forward it without 642 translating it. Otherwise, when an IP/ICMP translator receives an 643 IPv4 datagram addressed to an IPv4 destination representing a host in 644 the IPv6 domain, the packet MUST be translated to IPv6. 646 4. Translating from IPv6 to IPv4 648 When an IP/ICMP translator receives an IPv6 datagram addressed to a 649 destination towards the IPv4 domain, it translates the IPv6 header of 650 the received IPv6 packet into an IPv4 header. The original IPv6 651 header on the packet is removed and replaced by an IPv4 header. 652 Since the ICMPv6 [RFC4443], TCP [RFC0793], and UDP [RFC0768] headers 653 contain checksums that cover the IP header, if the address mapping 654 algorithm is not checksum-neutral, the ICMP and transport-layer 655 headers MUST be updated. The data portion of the packet is left 656 unchanged. The IP/ICMP translator then forwards the packet based on 657 the IPv4 destination address. 659 +-------------+ +-------------+ 660 | IPv6 | | IPv4 | 661 | Header | | Header | 662 +-------------+ +-------------+ 663 | Fragment | | Transport | 664 | Header | ===> | Layer | 665 |(if present) | | Header | 666 +-------------+ +-------------+ 667 | Transport | | | 668 | Layer | ~ Data ~ 669 | Header | | | 670 +-------------+ +-------------+ 671 | | 672 ~ Data ~ 673 | | 674 +-------------+ 676 Figure 5: IPv6-to-IPv4 Translation 678 There are some differences between IPv6 and IPv4 in the area of 679 fragmentation and the minimum link MTU that affect the translation. 680 An IPv6 link has to have an MTU of 1280 bytes or greater. The 681 corresponding limit for IPv4 is 68 bytes. Thus, unless there were 682 special measures, it would not be possible to do end-to-end path MTU 683 discovery when the path includes a translator, since the IPv6 node 684 might receive ICMPv6 "Packet Too Big" messages originated by an IPv4 685 router that report an MTU less than 1280. However, [RFC2460] section 686 5 requires that IPv6 nodes handle such an ICMPv6 "Packet Too Big" 687 message by reducing the path MTU to 1280 and including an IPv6 688 fragment header with each packet. In this case, the translator 689 SHOULD set DF to 0 and take the identification value from the IPv6 690 fragment header when a fragmentation header with (MF=0; Offset=0) is 691 present or set DF to 1 otherwise. This allows end-to-end path MTU 692 discovery across the translator as long as the path MTU is 1280 bytes 693 or greater. When the path MTU drops below the 1280 limit, the IPv6 694 sender will originate 1280-byte packets that will be fragmented by 695 IPv4 routers along the path after being translated to IPv4. 697 The drawback with this scheme is that it is not possible to use PMTU 698 discovery to do optimal UDP fragmentation (as opposed to completely 699 avoiding fragmentation) at the sender, since the presence of an IPv6 700 Fragment header is interpreted that it is okay to fragment the packet 701 on the IPv4 side. Thus if a UDP application wants to send large 702 packets independent of the PMTU, the sender will only be able to 703 determine the path MTU on the IPv6 side of the translator. If the 704 path MTU on the IPv4 side of the translator is smaller, then the IPv6 705 sender will not receive any ICMPv6 "Too Big" errors and cannot adjust 706 the size fragments it is sending. 708 On the other hand, a recent study indicates that only 43.46% of IPv6- 709 capable web servers include an IPv6 fragmentation header in their 710 respond packets after they were sent an ICMPv6 "Packet Too Big" 711 message specifying an MTU<1280 bytes [Stasiewicz]. A workaround to 712 this problem (ICMPv6 "Packet Too Big" message with MTU<1280) is that 713 if there is no fragmentation header in the IPv6 packet, the 714 translator SHOULD set DF to 0 for the packets equal to or smaller 715 than 1280 bytes and set DF to 1 for packets larger than 1280 bytes. 716 In addition, the translator SHOULD take the identification value from 717 the IPv6 fragmentation header if present or generate the 718 identification value otherwise. This avoids the introduction of the 719 path MTU discovery black hole. The header translation defined in the 720 next section uses this method. 722 Other than the special rules for handling fragments and path MTU 723 discovery, the actual translation of the packet header consists of a 724 simple mapping as defined below. Note that ICMPv6 packets require 725 special handling in order to translate the contents of ICMPv6 error 726 messages and also to remove the ICMPv6 pseudo-header checksum. 728 4.1. Translating IPv6 Headers into IPv4 Headers 730 If there is no IPv6 Fragment header, the IPv4 header fields are set 731 as follows: 733 Version: 4 735 Internet Header Length: 5 (no IPv4 options) 737 Type of Service (TOS) Octet: By default, copied from the IPv6 738 Traffic Class (all 8 bits). According to [RFC2474] the semantics 739 of the bits are identical in IPv4 and IPv6. However, in some IPv4 740 environments, these bits might be used with the old semantics of 741 "Type Of Service and Precedence". An implementation of a 742 translator SHOULD provide the ability to ignore the IPv6 traffic 743 class and always set the IPv4 TOS Octet to a specified value. In 744 addition, if the translator is at an administrative boundary, the 745 filtering and update considerations of [RFC2475] may be 746 applicable. 748 Total Length: Payload length value from IPv6 header, plus the size 749 of the IPv4 header. 751 Identification: If the packet size is equal to or smaller than 1280 752 bytes, generate the identification value. If the packet size is 753 greater than 1280 bytes, set Identification All zeros. 755 Flags: The More Fragments (MF) flag is set to zero. If the packet 756 size is equal to or smaller than 1280 bytes, the Don't Fragments 757 (DF) flag is set to zero. If the packet size is greater than 1280 758 bytes, the Don't Fragments (DF) flag is set to one. 760 Fragment Offset: All zeros. 762 Time to Live: Time to Live is derived from Hop Limit value in IPv6 763 header. Since the translator is a router, as part of forwarding 764 the packet it needs to decrement either the IPv6 Hop Limit (before 765 the translation) or the IPv4 TTL (after the translation). As part 766 of decrementing the TTL or Hop Limit the translator (as any 767 router) needs to check for zero and send the ICMPv4 "TTL Exceeded" 768 or ICMPv6 "Hop Limit Exceeded" error. 770 Protocol: For ICMPv6 (58) changed to ICMPv4 (1), otherwise Next 771 Header field copied from IPv6 header. 773 Header Checksum: Computed once the IPv4 header has been created. 775 Source Address: In the stateless mode, which is to say that if the 776 IPv6 source address is within the range of a configured IPv6 777 translation prefix, the IPv4 source address is derived from the 778 IPv6 source address per [I-D.ietf-behave-address-format] section 779 2.1. Note that the original IPv6 source address is an IPv4- 780 translatable address. A workflow example of stateless translation 781 is shown in Appendix of this document. If the translator only 782 supports stateless mode and if the IPv6 source address is not 783 within the range of configured IPv6 prefix(es), the translator 784 SHOULD drop the packet and respond with an ICMPv6 Type=1, Code=5 785 (Destination Unreachable, Source address failed ingress/egress 786 policy). 788 In the stateful mode, which is to say that if the IPv6 source 789 address is not within the range of any configured IPv6 stateless 790 translation prefix, the IPv4 source address and transport-layer 791 source port corresponding to the IPv4-related IPv6 source address 792 and source port are derived from the Binding Information Bases 793 (BIBs) as described in [I-D.ietf-behave-v6v4-xlate-stateful]. 795 In stateless and stateful modes, if the translator gets an illegal 796 source address (e.g. ::1, etc.), the translator SHOULD silently 797 drop the packet. 799 Destination Address: The IPv4 destination address is derived from 800 the IPv6 destination address of the datagram being translated per 801 [I-D.ietf-behave-address-format] section 2.1. Note that the 802 original IPv6 destination address is an IPv4-converted address. 804 If any of an IPv6 Hop-by-Hop Options header, Destination Options 805 header, or Routing header with the Segments Left field equal to zero 806 are present in the IPv6 packet, those IPv6 extension headers MUST be 807 ignored (i.e., there is no attempt to translate the extension 808 headers) and the packet translated normally. However, the Total 809 Length field and the Protocol field is adjusted to "skip" these 810 extension headers. 812 If a Routing header with a non-zero Segments Left field is present 813 then the packet MUST NOT be translated, and an ICMPv6 "parameter 814 problem/erroneous header field encountered" (Type 4/Code 0) error 815 message, with the Pointer field indicating the first byte of the 816 Segments Left field, SHOULD be returned to the sender. 818 If the IPv6 packet contains a Fragment header, the header fields are 819 set as above with the following exceptions: 821 Total Length: Payload length value from IPv6 header, minus 8 for the 822 Fragment header, plus the size of the IPv4 header. 824 Identification: Copied from the low-order 16-bits in the 825 Identification field in the Fragment header. 827 Flags: The More Fragments (MF) flag is copied from the M flag in the 828 Fragment header. The Don't Fragments (DF) flag is set to zero 829 allowing this packet to be fragmented if required by IPv4 routers. 831 Fragment Offset: Copied from the Fragment Offset field in the 832 Fragment header. 834 Protocol: For ICMPv6 (58) changed to ICMPv4 (1), otherwise Next 835 Header field copied from Fragment header. 837 If translated packet with DF set to 1 will be larger than the MTU of 838 the next-hop interface, then translator MUST drop packet and send 839 ICMPv6 "Packet Too Big" (Type 2/Code 0) error message to the IPv6 840 host with adjusted MTU in the ICMPv6 message. 842 4.2. Translating ICMPv6 Headers into ICMPv4 Headers 844 All ICMPv6 messages that are to be translated require that the ICMPv4 845 checksum field be updated as part of the translation since ICMPv6 846 (unlike ICMPv4) includes a pseudo-header in the checksum just like 847 UDP and TCP. 849 In addition all ICMP packets need to have the Type value translated 850 and, for ICMP error messages, the included IP header also needs 851 translation. Note that the IPv6 addresses in the IPv6 header may not 852 be IPv4-translatable addresses and there will be no corresponding 853 IPv4 addresses represented of this IPv6 address. In this case, the 854 translator can do stateful translation. A mechanism by which the 855 translator can instead do stateless translation is left for future 856 work. 858 The actions needed to translate various ICMPv6 messages are: 860 ICMPv6 informational messages: 862 Echo Request and Echo Reply (Type 128 and 129): Adjust the Type 863 values to 8 and 0, respectively, and adjust the ICMP checksum 864 both to take the type change into account and to exclude the 865 ICMPv6 pseudo-header. 867 MLD Multicast Listener Query/Report/Done (Type 130, 131, 132): 868 Single hop message. Silently drop. 870 Neighbor Discover messages (Type 133 through 137): Single hop 871 message. Silently drop. 873 Unknown informational messages: Silently drop. 875 ICMPv6 error messages: 877 Destination Unreachable (Type 1) Set the Type field to 3, and 878 adjust the ICMP checksum both to take the type change into 879 account and to exclude the ICMPv6 pseudo-header. Translate the 880 Code field as follows: 882 Code 0 (no route to destination): Set Code value to 1 (Host 883 unreachable). 885 Code 1 (Communication with destination administratively 886 prohibited): Set Code value to 10 (Communication with 887 destination host administratively prohibited). 889 Code 2 (Beyond scope of source address): Set Code value to 1 890 (Host unreachable). Note that this error is very unlikely 891 since an IPv4-translatable source address is typically 892 considered to have global scope. 894 Code 3 (Address unreachable): Set Code value to 1 (Host 895 unreachable). 897 Code 4 (Port unreachable): Set Code value to 3 (Port 898 unreachable). 900 Other Code values: Silently drop. 902 Packet Too Big (Type 2): Translate to an ICMPv4 Destination 903 Unreachable (Type 3) with Code value equal to 4, and adjust the 904 ICMPv4 checksum both to take the type change into account and 905 to exclude the ICMPv6 pseudo-header. The MTU field needs to be 906 adjusted for the difference between the IPv4 and IPv6 header 907 sizes taking into account whether or not the packet in error 908 includes a Fragment header, i.e. minimum(advertised MTU-20, 909 MTU_of_IPv4_nexthop, (MTU_of_IPv6_nexthop)-20) 911 Time Exceeded (Type 3): Set the Type value to 11, and adjust the 912 ICMPv4 checksum both to take the type change into account and 913 to exclude the ICMPv6 pseudo-header. The Code field is 914 unchanged. 916 Parameter Problem (Type 4): Translate the Type and Code field as 917 follows, and adjust the ICMPv4 checksum both to take the type 918 change into account and to exclude the ICMPv6 pseudo-header. 920 Code 0 (Erroneous header field encountered): Set Type 12, Code 921 0 and update the pointer as defined in Figure 6 (If the 922 Original IPv6 Pointer Value is not listed or the Translated 923 IPv4 Pointer Value is listed as "n/a", silently drop the 924 packet). 926 Code 1 (Unrecognized Next Header type encountered): Translate 927 this to an ICMPv4 protocol unreachable (Type 3, Code 2). 929 Code 2 (Unrecognized IPv6 option encountered): Silently drop. 931 Unknown error messages: Silently drop. 933 | Original IPv6 Pointer Value | Translated IPv4 Pointer Value | 934 +--------------------------------+--------------------------------+ 935 | 0 | Version/Traffic Class | 0 | Version/IHL, Type Of Ser | 936 | 1 | Traffic Class/Flow Label | 1 | Type Of Service | 937 | 2,3 | Flow Label | n/a | | 938 | 4,5 | Payload Length | 2 | Total Length | 939 | 6 | Next Header | 9 | Protocol | 940 | 7 | Hop Limit | 8 | Time to Live | 941 | 8-23| Source Address | 12 | Source Address | 942 |24-39| Destination Address | 16 | Destination Address | 943 +--------------------------------+--------------------------------+ 945 Figure 6: Pointer Value for translating from IPv6 to IPv4 947 ICMP Error Payload: If the received ICMPv6 packet contains an 948 ICMPv6 Extension [RFC4884], the translation of the ICMPv6 949 packet will cause the ICMPv4 packet to change length. When 950 this occurs, the ICMPv6 Extension length attribute MUST be 951 adjusted accordingly (e.g., shorter due to the translation from 952 IPv6 to IPv4). For extensions not defined in [RFC4884], the 953 translator passes the extensions as opaque bit strings and 954 those containing IPv6 address literals will not have those 955 addresses translated to IPv4 address literals; this may cause 956 problems with processing of those ICMP extensions. 958 4.3. Translating ICMPv6 Error Messages into ICMPv4 960 There are some differences between the ICMPv4 and the ICMPv6 error 961 message formats as detailed above. In addition, the ICMP error 962 messages contain the packet in error, which needs to be translated 963 just like a normal IP packet. The translation of this "packet in 964 error" is likely to change the length of the datagram thus the Total 965 Length field in the outer IPv4 header might need to be updated. 967 +-------------+ +-------------+ 968 | IPv6 | | IPv4 | 969 | Header | | Header | 970 +-------------+ +-------------+ 971 | ICMPv6 | | ICMPv4 | 972 | Header | | Header | 973 +-------------+ +-------------+ 974 | IPv6 | ===> | IPv4 | 975 | Header | | Header | 976 +-------------+ +-------------+ 977 | Partial | | Partial | 978 | Transport | | Transport | 979 | Layer | | Layer | 980 | Header | | Header | 981 +-------------+ +-------------+ 983 Figure 7: IPv6-to-IPv4 ICMP Error Translation 985 The translation of the inner IP header can be done by invoking the 986 function that translated the outer IP headers. This process SHOULD 987 stop at first embedded header and drop the packet if it contains 988 more. Note that the IPv6 addresses in the IPv6 header may not be 989 IPv4-translatable addresses and there will be no corresponding IPv4 990 addresses. In this case, the translator can do stateful translation. 991 A mechanism by which the translator can instead do stateless 992 translation is left for future work. 994 4.4. Translator Sending ICMPv6 Error Message 996 If the IPv6 packet is discarded, then the translator SHOULD be able 997 to send back an ICMPv6 error message to the original sender of the 998 packet, unless the discarded packet is itself an ICMPv6 message. 1000 If the ICMPv6 error message is being sent because the IPv6 source 1001 address is not an IPv4-translatable address and the translator is 1002 stateless, the ICMPv6 message, if sent, has a Type value 1 and Code 1003 value 5 (Source address failed ingress/egress policy). In other 1004 cases, the ICMPv6 message has a Type value of 1 (Destination 1005 Unreachable) and a Code value of 1 (Communication with destination 1006 administratively prohibited), unless otherwise specified in this 1007 document or [I-D.ietf-behave-v6v4-xlate-stateful]. The translator 1008 SHOULD allow an administrator to configure whether the ICMPv6 error 1009 messages are sent, rate-limited, or not sent. 1011 4.5. Transport-layer Header Translation 1013 If the address translation algorithm is not checksum neutral, the 1014 recalculation and updating of the transport-layer headers MUST be 1015 performed. 1017 4.6. Knowing when to Translate 1019 If the IP/ICMP translator also provides a normal forwarding function, 1020 and the destination address is reachable by a more specific route 1021 without translation, the router MUST forward it without translating 1022 it. When an IP/ICMP translator receives an IPv6 datagram addressed 1023 to an IPv6 address representing a host in IPv4 domain, the IPv6 1024 packet MUST be translated to IPv4. 1026 5. IANA Considerations 1028 This memo adds no new IANA considerations. 1030 Note to RFC Editor: This section will have served its purpose if it 1031 correctly tells IANA that no new assignments or registries are 1032 required, or if those assignments or registries are created during 1033 the RFC publication process. From the author's perspective, it may 1034 therefore be removed upon publication as an RFC at the RFC Editor's 1035 discretion. 1037 6. Security Considerations 1039 The use of stateless IP/ICMP translators does not introduce any new 1040 security issues beyond the security issues that are already present 1041 in the IPv4 and IPv6 protocols and in the routing protocols that are 1042 used to make the packets reach the translator. 1044 There are potential issues that might arise by deriving an IPv4 1045 address from an IPv6 address - particularly addresses like broadcast 1046 or loopback addresses and the non IPv4-translatable IPv6 addresses, 1047 etc. The [I-D.ietf-behave-address-format] addresses these issues. 1049 As the Authentication Header [RFC4302] is specified to include the 1050 IPv4 Identification field and the translating function is not able to 1051 always preserve the Identification field, it is not possible for an 1052 IPv6 endpoint to verify the AH on received packets that have been 1053 translated from IPv4 packets. Thus AH does not work through a 1054 translator. 1056 Packets with ESP can be translated since ESP does not depend on 1057 header fields prior to the ESP header. Note that ESP transport mode 1058 is easier to handle than ESP tunnel mode; in order to use ESP tunnel 1059 mode, the IPv6 node needs to be able to generate an inner IPv4 header 1060 when transmitting packets and remove such an IPv4 header when 1061 receiving packets. 1063 7. Acknowledgements 1065 This is under development by a large group of people. Those who have 1066 posted to the list during the discussion include Andrew Sullivan, 1067 Andrew Yourtchenko, Brian Carpenter, Dan Wing, Dave Thaler, Ed 1068 Jankiewicz, Hiroshi Miyata, Iljitsch van Beijnum, Jari Arkko, Jerry 1069 Huang, John Schnizlein, Jouni Korhonen, Kentaro Ebisawa, Kevin Yin, 1070 Magnus Westerlund, Marcelo Bagnulo Braun, Margaret Wasserman, 1071 Masahito Endo, Phil Roberts, Philip Matthews, Reinaldo Penno, Remi 1072 Denis-Courmont, Remi Despres, Senthil Sivakumar, Simon Perreault and 1073 Zen Cao. 1075 8. Appendix: Stateless translation workflow example 1077 A stateless translation workflow example is depicted in the following 1078 figure. The document address blocks 2001:DB8::/32 [RFC3849], 1079 192.0.2.0/24 and 198.51.100.0/24 [RFC5737] are used in this example. 1081 +--------------+ +--------------+ 1082 | IPv4 network | | IPv6 network | 1083 | | +-------+ | | 1084 | +----+ |-----| XLATE |---- | +----+ | 1085 | | H4 |-----| +-------+ |--| H6 | | 1086 | +----+ | | +----+ | 1087 +--------------+ +--------------+ 1089 Figure 8 1091 A translator (XLATE) connects the IPv6 network to the IPv4 network. 1092 This XLATE uses the Network Specific Prefix (NSP) 2001:DB8:100::/40 1093 defined in [I-D.ietf-behave-address-format] to represent IPv4 1094 addresses in the IPv6 address space (IPv4-converted addresses) and to 1095 represent IPv6 addresses (IPv4-translatable addresses) in the IPv4 1096 address space. In this example, 192.0.2.0/24 is the IPv4 block of 1097 the corresponding IPv4-translatable addresses. 1099 Based on the address mapping rule, the IPv6 node H6 has an IPv4- 1100 translatable IPv6 address 2001:DB8:1C0:2:21:: (address mapping from 1101 192.0.2.33). The IPv4 node H4 has IPv4 address 198.51.100.2. 1103 The IPv6 routing is configured in such a way that the IPv6 packets 1104 addressed to a destination address in 2001:DB8:100::/40 are routed to 1105 the IPv6 interface of the XLATE. 1107 The IPv4 routing is configured in such a way that the IPv4 packets 1108 addressed to a destination address in 192.0.2.0/24 are routed to the 1109 IPv4 interface of the XLATE. 1111 8.1. H6 establishes communication with H4 1113 The steps by which H6 establishes communication with H4 are: 1115 1. H6 performs the destination address mapping, so the IPv4- 1116 converted address 2001:DB8:1C6:3364:200:: is formed from 1117 198.51.100.2 based on the address mapping algorithm 1118 [I-D.ietf-behave-address-format]. 1120 2. H6 sends a packet to H4. The packet is sent from a source 1121 address 2001:DB8:1C0:2:21:: to a destination address 2001:DB8: 1122 1C6:3364:200::. 1124 3. The packet is routed to the IPv6 interface of the XLATE (since 1125 IPv6 routing is configured that way). 1127 4. The XLATE receives the packet and performs the following actions: 1129 * The XLATE translates the IPv6 header into an IPv4 header using 1130 the IP/ICMP Translation Algorithm defined in this document. 1132 * The XLATE includes 192.0.2.33 as source address in the packet 1133 and 198.51.100.2 as destination address in the packet. Note 1134 that 192.0.2.33 and 198.51.100.2 are extracted directly from 1135 the source IPv6 address 2001:DB8:1C0:2:21:: (IPv4-translatable 1136 address) and destination IPv6 address 2001:DB8:1C6:3364:200:: 1137 (IPv4-converted address) of the received IPv6 packet that is 1138 being translated. 1140 5. The XLATE sends the translated packet out its IPv4 interface and 1141 the packet arrives at H4. 1143 6. H4 node responds by sending a packet with destination address 1144 192.0.2.33 and source address 198.51.100.2. 1146 7. The packet is routed to the IPv4 interface of the XLATE (since 1147 IPv4 routing is configured that way). The XLATE performs the 1148 following operations: 1150 * The XLATE translates the IPv4 header into an IPv6 header using 1151 the IP/ICMP Translation Algorithm defined in this document. 1153 * The XLATE includes 2001:DB8:1C0:2:21:: as destination address 1154 in the packet and 2001:DB8:1C6:3364:200:: as source address in 1155 the packet. Note that 2001:DB8:1C0:2:21:: and 2001:DB8:1C6: 1156 3364:200:: are formed directly from the destination IPv4 1157 address 192.0.2.33 and source IPv4 address 198.51.100.2 of the 1158 received IPv4 packet that is being translated. 1160 8. The translated packet is sent out the IPv6 interface to H6. 1162 The packet exchange between H6 and H4 continues until the session is 1163 finished. 1165 8.2. H4 establishes communication with H6 1167 The steps by which H4 establishes communication with H6 are: 1169 1. H4 performs the destination address mapping, so 192.0.2.33 is 1170 formed from IPv4-translatable address 2001:DB8:1C0:2:21:: based 1171 on the address mapping algorithm 1172 [I-D.ietf-behave-address-format]. 1174 2. H4 sends a packet to H6. The packet is sent from a source 1175 address 198.51.100.2 to a destination address 192.0.2.33. 1177 3. The packet is routed to the IPv6 interface of the XLATE (since 1178 IPv6 routing is configured that way). 1180 4. The XLATE receives the packet and performs the following actions: 1182 * The XLATE translates the IPv4 header into an IPv6 header using 1183 the IP/ICMP Translation Algorithm defined in this document. 1185 * The XLATE includes 2001:DB8:1C6:3364:200:: as source address 1186 in the packet and 2001:DB8:1C0:2:21:: as destination address 1187 in the packet. Note that 2001:DB8:1C6:3364:200:: (IPv4- 1188 converted address) and 2001:DB8:1C0:2:21:: (IPv4-translatable 1189 address) are obtained directly from the source IPv4 address 1190 198.51.100.2 and destination IPv4 address 192.0.2.33 of the 1191 received IPv4 packet that is being translated. 1193 5. The XLATE sends the translated packet out its IPv6 interface and 1194 the packet arrives at H6. 1196 6. H6 node responds by sending a packet with destination address 1197 2001:DB8:1C6:3364:200:: and source address 2001:DB8:1C0:2:21::. 1199 7. The packet is routed to the IPv6 interface of the XLATE (since 1200 IPv6 routing is configured that way). The XLATE performs the 1201 following operations: 1203 * The XLATE translates the IPv6 header into an IPv4 header using 1204 the IP/ICMP Translation Algorithm defined in this document. 1206 * The XLATE includes 198.51.100.2 as destination address in the 1207 packet and 192.0.2.33 as source address in the packet. Note 1208 that 198.51.100.2 and 192.0.2.33 are formed directly from the 1209 destination IPv6 address 2001:DB8:1C6:3364:200:: and source 1210 IPv6 address 2001:DB8:1C0:2:21:: of the received IPv6 packet 1211 that is being translated. 1213 8. The translated packet is sent out the IPv4 interface to H4. 1215 The packet exchange between H4 and H6 continues until the session 1216 finished. 1218 9. References 1220 9.1. Normative References 1222 [RFC0768] Postel, J., "User Datagram Protocol", STD 6, RFC 768, 1223 August 1980. 1225 [RFC0791] Postel, J., "Internet Protocol", STD 5, RFC 791, 1226 September 1981. 1228 [RFC0792] Postel, J., "Internet Control Message Protocol", STD 5, 1229 RFC 792, September 1981. 1231 [RFC0793] Postel, J., "Transmission Control Protocol", STD 7, 1232 RFC 793, September 1981. 1234 [RFC0879] Postel, J., "TCP maximum segment size and related topics", 1235 RFC 879, November 1983. 1237 [RFC1812] Baker, F., "Requirements for IP Version 4 Routers", 1238 RFC 1812, June 1995. 1240 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1241 Requirement Levels", BCP 14, RFC 2119, March 1997. 1243 [RFC2460] Deering, S. and R. Hinden, "Internet Protocol, Version 6 1244 (IPv6) Specification", RFC 2460, December 1998. 1246 [RFC2765] Nordmark, E., "Stateless IP/ICMP Translation Algorithm 1247 (SIIT)", RFC 2765, February 2000. 1249 [RFC2766] Tsirtsis, G. and P. Srisuresh, "Network Address 1250 Translation - Protocol Translation (NAT-PT)", RFC 2766, 1251 February 2000. 1253 [RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing 1254 Architecture", RFC 4291, February 2006. 1256 [RFC4443] Conta, A., Deering, S., and M. Gupta, "Internet Control 1257 Message Protocol (ICMPv6) for the Internet Protocol 1258 Version 6 (IPv6) Specification", RFC 4443, March 2006. 1260 [RFC4884] Bonica, R., Gan, D., Tappan, D., and C. Pignataro, 1261 "Extended ICMP to Support Multi-Part Messages", RFC 4884, 1262 April 2007. 1264 [RFC5382] Guha, S., Biswas, K., Ford, B., Sivakumar, S., and P. 1265 Srisuresh, "NAT Behavioral Requirements for TCP", BCP 142, 1266 RFC 5382, October 2008. 1268 9.2. Informative References 1270 [Dongjin] Lee, D., "Email to the behave mailing list (http:// 1271 www.ietf.org/mail-archive/web/behave/current/ 1272 msg06856.html)", Sept 2009. 1274 [I-D.ietf-behave-address-format] 1275 Huitema, C., Bao, C., Bagnulo, M., Boucadair, M., and X. 1276 Li, "IPv6 Addressing of IPv4/IPv6 Translators", 1277 draft-ietf-behave-address-format-04 (work in progress), 1278 January 2010. 1280 [I-D.ietf-behave-v6v4-framework] 1281 Baker, F., Li, X., Bao, C., and K. Yin, "Framework for 1282 IPv4/IPv6 Translation", 1283 draft-ietf-behave-v6v4-framework-06 (work in progress), 1284 February 2010. 1286 [I-D.ietf-behave-v6v4-xlate-stateful] 1287 Bagnulo, M., Matthews, P., and I. Beijnum, "Stateful 1288 NAT64: Network Address and Protocol Translation from IPv6 1289 Clients to IPv4 Servers", 1290 draft-ietf-behave-v6v4-xlate-stateful-08 (work in 1291 progress), January 2010. 1293 [Miller] Miller, G., "Email to the ngtrans mailing list 1294 (http://www.mail-archive.com/ipv6@ietf.org/ 1295 msg10159.html)", March 1999. 1297 [RFC1191] Mogul, J. and S. Deering, "Path MTU discovery", RFC 1191, 1298 November 1990. 1300 [RFC2474] Nichols, K., Blake, S., Baker, F., and D. Black, 1301 "Definition of the Differentiated Services Field (DS 1302 Field) in the IPv4 and IPv6 Headers", RFC 2474, 1303 December 1998. 1305 [RFC2475] Blake, S., Black, D., Carlson, M., Davies, E., Wang, Z., 1306 and W. Weiss, "An Architecture for Differentiated 1307 Services", RFC 2475, December 1998. 1309 [RFC2710] Deering, S., Fenner, W., and B. Haberman, "Multicast 1310 Listener Discovery (MLD) for IPv6", RFC 2710, 1311 October 1999. 1313 [RFC3171] Albanna, Z., Almeroth, K., Meyer, D., and M. Schipper, 1314 "IANA Guidelines for IPv4 Multicast Address Assignments", 1315 BCP 51, RFC 3171, August 2001. 1317 [RFC3307] Haberman, B., "Allocation Guidelines for IPv6 Multicast 1318 Addresses", RFC 3307, August 2002. 1320 [RFC3590] Haberman, B., "Source Address Selection for the Multicast 1321 Listener Discovery (MLD) Protocol", RFC 3590, 1322 September 2003. 1324 [RFC3810] Vida, R. and L. Costa, "Multicast Listener Discovery 1325 Version 2 (MLDv2) for IPv6", RFC 3810, June 2004. 1327 [RFC3849] Huston, G., Lord, A., and P. Smith, "IPv6 Address Prefix 1328 Reserved for Documentation", RFC 3849, July 2004. 1330 [RFC4213] Nordmark, E. and R. Gilligan, "Basic Transition Mechanisms 1331 for IPv6 Hosts and Routers", RFC 4213, October 2005. 1333 [RFC4302] Kent, S., "IP Authentication Header", RFC 4302, 1334 December 2005. 1336 [RFC5737] Arkko, J., Cotton, M., and L. Vegoda, "IPv4 Address Blocks 1337 Reserved for Documentation", RFC 5737, January 2010. 1339 [Stasiewicz] 1340 Stasiewicz, B., "Email to the behave mailing list (http:// 1341 www.ietf.org/mail-archive/web/behave/current/ 1342 msg08093.html)", Feb 2010. 1344 Authors' Addresses 1346 Xing Li 1347 CERNET Center/Tsinghua University 1348 Room 225, Main Building, Tsinghua University 1349 Beijing, 100084 1350 China 1352 Phone: +86 10-62785983 1353 Email: xing@cernet.edu.cn 1355 Congxiao Bao 1356 CERNET Center/Tsinghua University 1357 Room 225, Main Building, Tsinghua University 1358 Beijing, 100084 1359 China 1361 Phone: +86 10-62785983 1362 Email: congxiao@cernet.edu.cn 1364 Fred Baker 1365 Cisco Systems 1366 Santa Barbara, California 93117 1367 USA 1369 Phone: +1-408-526-4257 1370 Email: fred@cisco.com