idnits 2.17.1 draft-ietf-behave-address-format-09.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- == There are 4 instances of lines with non-RFC3849-compliant IPv6 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 mention this, which it should. -- The draft header indicates that this document updates RFC4291, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year (Using the creation date from RFC4291, updated by this document, for RFC5378 checks: 2003-10-10) -- 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 (July 10, 2010) is 5031 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: '1' on line 672 -- Looks like a reference, but probably isn't: '5' on line 672 == Missing Reference: 'TBD' is mentioned on line 674, but not defined == Missing Reference: 'RFC-ietf-behave-address-format' is mentioned on line 676, but not defined == Outdated reference: A later version (-11) exists of draft-ietf-behave-dns64-04 == Outdated reference: A later version (-10) exists of draft-ietf-behave-v6v4-framework-03 -- Obsolete informational reference (is this intentional?): RFC 3484 (Obsoleted by RFC 6724) -- Obsolete informational reference (is this intentional?): RFC 5389 (Obsoleted by RFC 8489) -- Obsolete informational reference (is this intentional?): RFC 5735 (Obsoleted by RFC 6890) Summary: 0 errors (**), 0 flaws (~~), 6 warnings (==), 9 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group C. Bao 3 Internet-Draft CERNET Center/Tsinghua University 4 Obsoletes: 2765 (if approved) C. Huitema 5 Updates: 4291 (if approved) Microsoft Corporation 6 Intended status: Standards Track M. Bagnulo 7 Expires: January 11, 2011 UC3M 8 M. Boucadair 9 France Telecom 10 X. Li 11 CERNET Center/Tsinghua University 12 July 10, 2010 14 IPv6 Addressing of IPv4/IPv6 Translators 15 draft-ietf-behave-address-format-09.txt 17 Abstract 19 This document discusses the algorithmic translation of an IPv6 20 address to a corresponding IPv4 address, and vice versa, using only 21 statically configured information. It defines a well-known prefix 22 for use in algorithmic translations, while allowing organizations to 23 also use network-specific prefixes when appropriate. Algorithmic 24 translation is used in IPv4/IPv6 translators, as well as other types 25 of proxies and gateways (e.g., for DNS) used in IPv4/IPv6 scenarios. 27 Status of this Memo 29 This Internet-Draft is submitted in full conformance with the 30 provisions of BCP 78 and BCP 79. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF). Note that other groups may also distribute 34 working documents as Internet-Drafts. The list of current Internet- 35 Drafts is at http://datatracker.ietf.org/drafts/current/. 37 Internet-Drafts are draft documents valid for a maximum of six months 38 and may be updated, replaced, or obsoleted by other documents at any 39 time. It is inappropriate to use Internet-Drafts as reference 40 material or to cite them other than as "work in progress." 42 This Internet-Draft will expire on January 11, 2011. 44 Copyright Notice 46 Copyright (c) 2010 IETF Trust and the persons identified as the 47 document authors. All rights reserved. 49 This document is subject to BCP 78 and the IETF Trust's Legal 50 Provisions Relating to IETF Documents 51 (http://trustee.ietf.org/license-info) in effect on the date of 52 publication of this document. Please review these documents 53 carefully, as they describe your rights and restrictions with respect 54 to this document. Code Components extracted from this document must 55 include Simplified BSD License text as described in Section 4.e of 56 the Trust Legal Provisions and are provided without warranty as 57 described in the Simplified BSD License. 59 Table of Contents 61 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 62 1.1. Applicability Scope . . . . . . . . . . . . . . . . . . . 3 63 1.2. Conventions . . . . . . . . . . . . . . . . . . . . . . . 4 64 1.3. Terminology . . . . . . . . . . . . . . . . . . . . . . . 4 65 2. IPv4-Embedded IPv6 Address Prefix and Format . . . . . . . . . 4 66 2.1. Well Known Prefix . . . . . . . . . . . . . . . . . . . . 4 67 2.2. IPv4-Embedded IPv6 Address Format . . . . . . . . . . . . 5 68 2.3. Address Translation Algorithms . . . . . . . . . . . . . . 6 69 2.4. Text Representation . . . . . . . . . . . . . . . . . . . 7 70 3. Deployment Guidelines . . . . . . . . . . . . . . . . . . . . 7 71 3.1. Restrictions on the use of the Well-Known Prefix . . . . . 7 72 3.2. Impact on Inter-Domain Routing . . . . . . . . . . . . . . 8 73 3.3. Choice of Prefix for Stateless Translation Deployments . . 8 74 3.4. Choice of Prefix for Stateful Translation Deployments . . 11 75 4. Design choices . . . . . . . . . . . . . . . . . . . . . . . . 12 76 4.1. Choice of Suffix . . . . . . . . . . . . . . . . . . . . . 12 77 4.2. Choice of the Well-Known Prefix . . . . . . . . . . . . . 12 78 5. Security Considerations . . . . . . . . . . . . . . . . . . . 14 79 5.1. Protection Against Spoofing . . . . . . . . . . . . . . . 14 80 5.2. Secure Configuration . . . . . . . . . . . . . . . . . . . 14 81 5.3. Firewall Configuration . . . . . . . . . . . . . . . . . . 14 82 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 15 83 7. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 15 84 8. Contributors . . . . . . . . . . . . . . . . . . . . . . . . . 15 85 9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 17 86 9.1. Normative References . . . . . . . . . . . . . . . . . . . 17 87 9.2. Informative References . . . . . . . . . . . . . . . . . . 17 88 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 17 90 1. Introduction 92 This document is part of a series of IPv4/IPv6 translation documents. 93 A framework for IPv4/IPv6 translation is discussed in 94 [I-D.ietf-behave-v6v4-framework], including a taxonomy of scenarios 95 that will be used in this document. Other documents specify the 96 behavior of various types of translators and gateways, including 97 mechanisms for translating between IP headers and other types of 98 messages that include IP addresses. This document specifies how an 99 individual IPv6 address is translated to a corresponding IPv4 100 address, and vice versa, in cases where an algorithmic mapping is 101 used. While specific types of devices are used herein as examples, 102 it is the responsibility of the specification of such devices to 103 reference this document for algorithmic mapping of the addresses 104 themselves. 106 Section 2 describes the prefixes and the format of "IPv4-Embedded 107 IPv6 addresses", i.e., IPv6 addresses in which 32 bits contain an 108 IPv4 address. This format is common to both "IPv4-converted" and 109 "IPv4-Translatable" IPv6 addresses. This section also defines the 110 algorithms for translating addresses, and the text representation of 111 IPv4-Embedded IPv6 addresses. 113 Section 3 discusses the choice of prefixes, the conditions in which 114 they can be used, and the use of IPv4-Embedded IPv6 addresses with 115 stateless and stateful translation. 117 Section 4 provides a summary of the discussions behind two specific 118 design decisions, the choice of a null suffix and the specific value 119 of the selected prefix. 121 Section 5 discusses security concerns. 123 In some scenarios, a dual-stack host will unnecessarily send its 124 traffic through an IPv6/IPv4 translator. This can be caused by 125 host's default address selection algorithm [RFC3484], referrals, or 126 other reasons. Optimizing these scenarios for dual-stack hosts is 127 for future study. 129 1.1. Applicability Scope 131 This document is part of a series defining address translation 132 services. We understand that the address format could also be used 133 by other interconnection methods between IPv6 and IPv4, e.g., methods 134 based on encapsulation. If encapsulation methods are developed by 135 the IETF, we expect that their descriptions will document their 136 specific use of IPv4-Embedded IPv6 addresses. 138 1.2. Conventions 140 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 141 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 142 document are to be interpreted as described in RFC 2119 [RFC2119]. 144 1.3. Terminology 146 This document makes use of the following terms: 148 Address translator: any entity that has to derive an IPv4 address 149 from an IPv6 address or vice versa. This applies not only to 150 devices that do IPv4/IPv6 packet translation, but also to other 151 entities that manipulate addresses, such as name resolution 152 proxies (e.g. DNS64 [I-D.ietf-behave-dns64]) and possibly other 153 types of Application Layer Gateways (ALGs). 154 IPv4-converted IPv6 addresses: IPv6 addresses used to represent IPv4 155 nodes in an IPv6 network. They are a variant of IPv4-Embedded 156 IPv6 addresses, and follow the format described in Section 2.2. 157 IPv4-Embedded IPv6 addresses: IPv6 addresses in which 32 bits 158 contain an IPv4 address. Their format is described in 159 Section 2.2. 160 IPv4/IPv6 translator: an entity that translates IPv4 packets to IPv6 161 packets, and vice versa. It may do "stateless" translation, 162 meaning that there is no per-flow state required, or "stateful" 163 translation where per-flow state is created when the first packet 164 in a flow is received. 165 IPv4-Translatable IPv6 addresses: IPv6 addresses assigned to IPv6 166 nodes for use with stateless translation. They are a variant of 167 IPv4-Embedded IPv6 addresses, and follow the format described in 168 Section 2.2. 169 Network-Specific Prefix: an IPv6 prefix assigned by an organization 170 for use in algorithmic mapping. Options for the Network Specific 171 Prefix are discussed in Section 3.3 and Section 3.4. 172 Well-Known Prefix: the IPv6 prefix defined in this document for use 173 in an algorithmic mapping. 175 2. IPv4-Embedded IPv6 Address Prefix and Format 177 2.1. Well Known Prefix 179 This document reserves a "Well-Known Prefix" for use in an 180 algorithmic mapping. The value of this IPv6 prefix is: 182 64:FF9B::/96 184 2.2. IPv4-Embedded IPv6 Address Format 186 IPv4-converted IPv6 addresses and IPv4-Translatable IPv6 addresses 187 follow the same format, described here as the IPv4-Embedded IPv6 188 address Format. IPv4-Embedded IPv6 addresses are composed of a 189 variable length prefix, the embedded IPv4 address, and a variable 190 length suffix, as presented in the following diagram, in which PL 191 designates the prefix length: 193 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 194 |PL| 0-------------32--40--48--56--64--72--80--88--96--104-112-120-| 195 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 196 |32| prefix |v4(32) | u | suffix | 197 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 198 |40| prefix |v4(24) | u |(8)| suffix | 199 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 200 |48| prefix |v4(16) | u | (16) | suffix | 201 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 202 |56| prefix |(8)| u | v4(24) | suffix | 203 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 204 |64| prefix | u | v4(32) | suffix | 205 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 206 |96| prefix | v4(32) | 207 +--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 209 Figure 1 211 In these addresses, the prefix shall be either the "Well-Known 212 Prefix", or a "Network-Specific Prefix" unique to the organization 213 deploying the address translators. The prefixes can only have one of 214 the following lengths: 32, 40, 48, 56, 64 or 96. (The Well-Known 215 prefic is 96 bits long, and can only be used in the last form of the 216 table.) 218 Various deployments justify different prefix lengths with Network- 219 Specific prefixes. The tradeoff between different prefix lengths are 220 discussed in Section 3.3 and Section 3.4. 222 Bits 64 to 71 of the address are reserved for compatibility with the 223 host identifier format defined in the IPv6 addressing architecture 224 [RFC4291]. These bits MUST be set to zero. When using a /96 225 Network-Specific Prefix, the administrators MUST ensure that the bits 226 64 to 71 are set to zero. A simple way to achieve that is to 227 construct the /96 Network-Specific Prefix by picking a /64 prefix, 228 and then adding four octets set to zero. 230 The IPv4 address is encoded following the prefix, most significant 231 bits first. Depending of the prefix length, the 4 octets of the 232 address may be separated by the reserved octet "u", whose 8 bits MUST 233 be set to zero. In particular: 234 o When the prefix is 32 bits long, the IPv4 address is encoded in 235 positions 32 to 63. 236 o When the prefix is 40 bits long, 24 bits of the IPv4 address are 237 encoded in positions 40 to 63, with the remaining 8 bits in 238 position 72 to 79. 239 o When the prefix is 48 bits long, 16 bits of the IPv4 address are 240 encoded in positions 48 to 63, with the remaining 16 bits in 241 position 72 to 87. 242 o When the prefix is 56 bits long, 8 bits of the IPv4 address are 243 encoded in positions 56 to 63, with the remaining 24 bits in 244 position 72 to 95. 245 o When the prefix is 64 bits long, the IPv4 address is encoded in 246 positions 72 to 103. 247 o When the prefix is 96 bits long, the IPv4 address is encoded in 248 positions 96 to 127. 250 There are no remaining bits, and thus no suffix, if the prefix is 96 251 bits long. In the other cases, the remaining bits of the address 252 constitute the suffix. These bits are reserved for future 253 extensions, and SHOULD be set to zero. Address translators who 254 receive IPv4 embedded IPv6 addresses where these bits are not zero 255 SHOULD ignore the bits' value and proceed as if the bits' value was 256 zero. (Future extensions may specify a different behavior.) 258 2.3. Address Translation Algorithms 260 IPv4-Embedded IPv6 addresses are composed according to the following 261 algorithm: 262 o Concatenate the prefix, the 32 bits of the IPv4 address and the 263 suffix if needed to obtain a 128 bit address. 264 o If the prefix length is less than 96 bits, insert the null octet 265 "u" at the appropriate position (bits 64 to 71), thus causing the 266 least significant octet to be excluded, as documented in Figure 1. 268 The IPv4 addresses are extracted from the IPv4-Embedded IPv6 269 addresses according to the following algorithm: 270 o If the prefix is 96 bit long, extract the last 32 bits of the IPv6 271 address; 272 o for the other prefix lengths, remove the "u" octet to obtain a 120 273 bit sequence (effectively shifting bits 72-127 to positions 64- 274 119), then extract the 32 bits following the prefix. 276 2.4. Text Representation 278 IPv4-Embedded IPv6 addresses will be represented in text in 279 conformity with section 2.2 of [RFC4291]. IPv4-Embedded IPv6 280 addresses constructed using the Well-Known Prefix or a /96 Network- 281 Specific Prefix may be represented using the alternative form 282 presented in section 2.2 of [RFC4291], with the embedded IPv4 address 283 represented in dotted decimal notation. Examples of such 284 representations are presented in Table 1 and Table 2. 286 +-----------------------+------------+------------------------------+ 287 | Network-Specific | IPv4 | IPv4-Embedded IPv6 address | 288 | Prefix | address | | 289 +-----------------------+------------+------------------------------+ 290 | 2001:DB8::/32 | 192.0.2.33 | 2001:DB8:C000:221:: | 291 | 2001:DB8:100::/40 | 192.0.2.33 | 2001:DB8:1C0:2:21:: | 292 | 2001:DB8:122::/48 | 192.0.2.33 | 2001:DB8:122:C000:2:2100:: | 293 | 2001:DB8:122:300::/56 | 192.0.2.33 | 2001:DB8:122:3C0:0:221:: | 294 | 2001:DB8:122:344::/64 | 192.0.2.33 | 2001:DB8:122:344:C0:2:2100:: | 295 | 2001:DB8:122:344::/96 | 192.0.2.33 | 2001:DB8:122:344::192.0.2.33 | 296 +-----------------------+------------+------------------------------+ 298 Table 1: Text representation of IPv4-Embedded IPv6 addresses using 299 Network-Specific Prefixes 301 +-------------------+--------------+----------------------------+ 302 | Well Known Prefix | IPv4 address | IPv4-Embedded IPv6 address | 303 +-------------------+--------------+----------------------------+ 304 | 64:FF9B::/96 | 192.0.2.33 | 64:FF9B::192.0.2.33 | 305 +-------------------+--------------+----------------------------+ 307 Table 2: Text representation of IPv4-Embedded IPv6 addresses using 308 the Well-Known Prefix 310 The Network-Specific Prefix examples in Table 1 are derived from the 311 IPv6 prefix reserved for documentation in [RFC3849]. The IPv4 312 address 192.0.2.33 is part of the subnet 192.0.2.0/24 reserved for 313 documentation in [RFC5735]. 315 3. Deployment Guidelines 317 3.1. Restrictions on the use of the Well-Known Prefix 319 The Well-Known Prefix MUST NOT be used to represent non global IPv4 320 addresses, such as those defined in [RFC1918] or listed in section 3 321 of [RFC5735]. Address translators MUST NOT translate packets in 322 which an address is composed of the Well-Known Prefix and a non 323 global IPv4 address, they MUST drop these packets. 325 The Well-Known Prefix SHOULD NOT be used to construct IPv4- 326 Translatable IPv6 addresses. The nodes served by IPv4-Translatable 327 IPv6 addresses should be able to receive global IPv6 traffic bound to 328 their IPv4-Translatable IPv6 address without incurring intermediate 329 protocol translation. This is only possible if the specific prefix 330 used to build the IPv4-Translatable IPv6 addresses is advertized in 331 inter-domain routing, but the advertisement of more specific prefixes 332 derived from the Well-Known Prefix is not supported, as explained in 333 Section 3.2. Network-Specific Prefixes SHOULD be used in these 334 scenarios, as explained in Section 3.3. 336 The Well-Known Prefix MAY be used by organizations deploying 337 translation services, as explained in Section 3.4. 339 3.2. Impact on Inter-Domain Routing 341 The Well-Known Prefix MAY appear in inter-domain routing tables, if 342 service providers decide to provide IPv6-IPv4 interconnection 343 services to peers. Advertisement of the Well-Known Prefix SHOULD be 344 controlled either by upstream and/or downstream service providers 345 according to inter-domain routing policies, e.g., through 346 configuration of BGP [RFC4271]. Organizations that advertize the 347 Well-Known Prefix in inter-domain routing MUST be able to provide 348 IPv4/IPv6 translation service. 350 When the IPv4/IPv6 translation relies on the Well-Known Prefix, IPv4 351 Embedded IPv6 prefixes longer than the Well-Known Prefix MUST NOT be 352 advertised in BGP (especially e-BGP) [RFC4271] because this leads to 353 importing the IPv4 routing table into the IPv6 one and therefore 354 introduces scalability issues to the global IPv6 routing table. 355 Administrators of BGP nodes SHOULD configure filters that discard 356 advertisements of embedded IPv6 prefixes longer than the Well-Known 357 Prefix. 359 When the IPv4/IPv6 translation service relies on Network-Specific 360 Prefixes, the IPv4-Translatable IPv6 prefixes used in stateless 361 translation MUST be advertised with proper aggregation to the IPv6 362 Internet. Similarly, if translators are configured with multiple 363 Network-Specific Prefixes, these prefixes MUST be advertised to the 364 IPv6 Internet with proper aggregation. 366 3.3. Choice of Prefix for Stateless Translation Deployments 368 Organizations may deploy translation services using stateless 369 translation. In these deployments, internal IPv6 nodes are addressed 370 using IPv4-Translatable IPv6 addresses, which enable them to be 371 accessed by IPv4 nodes. The addresses of these external IPv4 nodes 372 are then represented in IPv4-converted IPv6 addresses. 374 Organizations deploying stateless IPv4/IPv6 translation SHOULD assign 375 a Network-Specific Prefix to their IPv4/IPv6 translation service. 376 IPv4-Translatable and IPv4-converted IPv6 addresses MUST be 377 constructed as specified in Section 2.2. IPv4-Translatable IPv6 378 addresses MUST use the selected Network-Specific Prefix. Both IPv4- 379 Translatable IPv6 addresses and IPv4-converted IPv6 addresses SHOULD 380 use the same prefix. 382 Using the same prefix ensures that IPv6 nodes internal to the 383 organization will use the most efficient paths to reach the nodes 384 served by IPv4-Translatable IPv6 addresses. Specifically, if a node 385 learns the IPv4 address of a target internal node without knowing 386 that this target is in fact located behind the same translator that 387 the node also uses, translation rules will ensure that the IPv6 388 address constructed with the Network-Specific prefix is the same as 389 the IPv4-Translatable IPv6 address assigned to the target. Standard 390 routing preference (more specific wins) will then ensure that the 391 IPv6 packets are delivered directly, without requiring that 392 translators receive the packets and then return them in the direction 393 they came from. 395 The intra-domain routing protocol must be able to deliver packets to 396 the nodes served by IPv4-Translatable IPv6 addresses. This may 397 require routing on some or all of the embedded IPv4 address bits. 398 Security considerations detailed in Section 5 require that routers 399 check the validity of the IPv4-Translatable IPv6 source addresses, 400 using some form of reverse path check. 402 The management of stateless address translation can be illustrated 403 with a small example: 405 We will consider an IPv6 network with the prefix 2001:DB8: 406 122::/48. The network administrator has selected the Network- 407 Specific prefix 2001:DB8:122:344::/64 for managing stateless IPv4/ 408 IPv6 translation. The IPv4-Translatable address block for IPv4 409 subnet 192.0.2.0/24 is 2001:DB8:122:344:C0:2::/96. In this 410 network, the host A is assigned the IPv4-Translatable IPv6 address 411 2001:DB8:122:344:C0:2:2100::, which corresponds to the IPv4 412 address 192.0.2.33. Host A's address is configured either 413 manually or through DHCPv6. 415 In this example, host A is not directly connected to the 416 translator, but instead to a link managed by a router R. The 417 router R is configured to forward to A the packets bound to 2001: 418 DB8:122:344:C0:2:2100::. To receive these packets, R will 419 advertise reachability of the prefix 2001:DB8:122:344:C0:2:2100::/ 420 104 in the intra-domain routing protocol -- or perhaps a shorter 421 prefix if many hosts on link have IPv4-Translatable IPv6 addresses 422 derived from the same IPv4 subnet. If a packet bound to 423 192.0.2.33 reaches the translator, the destination address will be 424 translated to 2001:DB8:122:344:C0:2:2100::, and the packet will be 425 routed towards R and then to A. 427 Let's suppose now that a host B of the same domain learns the IPv4 428 address of A, maybe through an application-specific referral. If 429 B has translation-aware software, B can compose a destination 430 address by combining the Network-Specific Prefix 2001:DB8:122: 431 344::/64 and the IPv4 address 192.0.2.33, resulting in the address 432 2001:DB8:122:344:C0:2:2100::. The packet sent by B will be 433 forwarded towards R, and then to A, avoiding protocol translation. 435 Forwarding, and reverse path checks, are more efficient when 436 performed on the combination of the prefix and the IPv4 address. In 437 theory, routers are able to route on prefixes of any length, but in 438 practice there may be routers for which routing on prefixes larger 439 than 64 bits is slower. But routing efficiency is not the only 440 consideration in the choice of a prefix length. Organizations also 441 need to consider the availability of prefixes, and the potential 442 impact of all-zeroes identifiers. 444 If a /32 prefix is used, all the routing bits are contained in the 445 top 64 bits of the IPv6 address, leading to excellent routing 446 properties. These prefixes may however be hard to obtain, and 447 allocation of a /32 to a small set of IPv4-Translatable IPv6 448 addresses may be seen as wasteful. In addition, the /32 prefix and a 449 zero suffix leads to an all-zeroes interface identifier, an issue 450 that we discuss in Section 4.1. 452 Intermediate prefix lengths such as /40, /48 or /56 appear as 453 compromises. Only some of the IPv4 bits are part of the /64 454 prefixes. Reverse path checks, in particular, may have a limited 455 efficiency. Reverse path checks limited to the most significant bits 456 of the IPv4 address will reduce the possibility of spoofing external 457 IPv4 addresses, but would allow IPv6 nodes to spoof internal IPv4- 458 Translatable IPv6 addresses. 460 We propose here a compromise, based on using no more than 1/256th of 461 an organization's allocation of IPv6 addresses for the IPv4/IPv6 462 translation service. For example, if the organization is an Internet 463 Service Provider with an allocated IPv6 prefix /32 or shorter, the 464 ISP could dedicate a /40 prefix to the translation service. An end 465 site with a /48 allocation could dedicate a /56 prefix to the 466 translation service, or possibly a /96 prefix if all IPv4- 467 Translatable IPv6 addresses are located on the same link. 469 The recommended prefix length is also a function of the deployment 470 scenario. The stateless translation can be used for Scenario 1, 471 Scenario 2, Scenario 5, and Scenario 6 defined in 472 [I-D.ietf-behave-v6v4-framework]. For different scenarios, the 473 prefix length recommendations are: 474 o For scenario 1 (an IPv6 network to the IPv4 Internet) and scenario 475 2 (the IPv4 Internet to an IPv6 network), an ISP holding a /32 476 allocation SHOULD use a /40 prefix , and a site holding a /48 477 allocation SHOULD use a /56 prefix. 478 o For scenario 5 (an IPv6 network to an IPv4 network) and scenario 6 479 (an IPv4 network to an IPv6 network), the deployment SHOULD use a 480 /64 or a /96 prefix. 482 3.4. Choice of Prefix for Stateful Translation Deployments 484 Organizations may deploy translation services based on stateful 485 translation technology. An organization may decide to use either a 486 Network-Specific Prefix or the Well-Known Prefix for its stateful 487 IPv4/IPv6 translation service. 489 When these services are used, IPv6 nodes are addressed through 490 standard IPv6 addresses, while IPv4 nodes are represented by IPv4- 491 converted IPv6 addresses, as specified in Section 2.2. 493 The stateful nature of the translation creates a potential stability 494 issue when the organization deploys multiple translators. If several 495 translators use the same prefix, there is a risk that packets 496 belonging to the same connection may be routed to different 497 translators as the internal routing state changes. This issue can be 498 avoided either by assigning different prefixes to different 499 translators, or by ensuring that all translators using same prefix 500 coordinate their state. 502 Stateful translation can be used in scenarios defined in 503 [I-D.ietf-behave-v6v4-framework]. The Well Known Prefix SHOULD be 504 used in these scenarios, with two exceptions: 505 o In all scenarios, the translation MAY use a Network-Specific 506 Prefix, if deemed appropriate for management reasons. 507 o The Well-Known Prefix MUST NOT be used for scenario 3 (the IPv6 508 Internet to an IPv4 network), as this would lead to using the 509 Well-Known Prefix with non-global IPv4 addresses. That means a 510 Network-Specific Prefix MUST be used in that scenario, for example 511 a /96 prefix. 513 4. Design choices 515 The prefix that we have chosen reflects two design choices, the null 516 suffix and the specific value of the Well Known Prefix. We provide 517 here a summary of the discussions leading to those two choices. 519 4.1. Choice of Suffix 521 The address format described in Section 2.2 recommends a zero suffix. 522 Before making this recommendation, we considered different options: 523 checksum neutrality; the encoding of a port range; and a value 524 different than 0. 526 In the case of stateless translation, there would be no need for the 527 translator to recompute a one's complement checksum if both the IPv4- 528 Translatable and the IPv4-converted IPv6 addresses were constructed 529 in a "checksum-neutral" manner, that is if the IPv6 addresses would 530 have the same one's complement checksum as the embedded IPv4 address. 531 In the case of stateful translation, checksum neutrality does not 532 eliminate checksum computation during translation, as only one of the 533 two addresses would be checksum neutral. We considered reserving 16 534 bits in the suffix to guarantee checksum neutrality, but declined 535 because it would not help with stateful translation, and because 536 checksum neutrality can also be achieved by an appropriate choice of 537 the Network-Specific Prefix, i.e. selecting a prefix whose one's 538 complement checksum equals either 0 or 0xFFFF. 540 There have been proposals to complement stateless translation with a 541 port-range feature. Instead of mapping an IPv4 address to exactly 542 one IPv6 prefix, the options would allow several IPv6 nodes to share 543 an IPv4 address, with each node managing a different range of ports. 544 If a port range extension is needed, it could be defined later, using 545 bits currently reserved as null in the suffix. 547 When a /32 prefix is used, an all-zero suffix results in an all-zero 548 interface identifier. We understand the conflict with Section 2.6.1 549 of RFC4291, which specifies that all zeroes are used for the subnet- 550 router anycast address. However, in our specification, there would 551 be only one node with an IPv4-Translatable IPv6 address in the /64 552 subnet, and the anycast semantic would not create confusion. We thus 553 decided to keep the null suffix for now. This issue does not exist 554 for prefixes larger than 32 bits, such as the /40, /56, /64 and /96 555 prefixes that we recommend in Section 3.3. 557 4.2. Choice of the Well-Known Prefix 559 Before making our recommendation of the Well-Known Prefix, we were 560 faced with three choices: 562 o reuse the IPv4-mapped prefix, ::FFFF:0:0/96, as specified in RFC 563 2765 Section 2.1; 564 o request IANA to allocate a /32 prefix, 565 o or request allocation of a new /96 prefix. 567 We weighted the pros and cons of these choices before settling on the 568 recommended /96 Well-Known Prefix. 570 The main advantage of the existing IPv4-mapped prefix is that it is 571 already defined. Reusing that prefix would require minimal 572 standardization efforts. However, being already defined is not just 573 an advantage, as there may be side effects of current 574 implementations. When presented with the IPv4-mapped prefix, current 575 versions of Windows and MacOS generate IPv4 packets, but will not 576 send IPv6 packets. If we used the IPv4-mapped prefix, these nodes 577 would not be able to support translation without modification. This 578 will defeat the main purpose of the translation techniques. We thus 579 eliminated the first choice, and decided to not reuse the IPv4-mapped 580 prefix, ::FFFF:0:0/96. 582 A /32 prefix would have allowed the embedded IPv4 address to fit 583 within the top 64 bits of the IPv6 address. This would have 584 facilitated routing and load balancing when an organization deploys 585 several translators. However, such destination-address based load 586 balancing may not be desirable. It is not compatible with STUN 587 [RFC5389] in the deployments involving multiple stateful translators, 588 each one having a different pool of IPv4 addresses. STUN 589 compatibility would only be achieved if the translators managed the 590 same pool of IPv4 addresses and were able to coordinate their 591 translation state, in which case there is no big advantage to using a 592 /32 prefix rather than a /96 prefix. 594 According to Section 2.2 of [RFC4291], in the legal textual 595 representations of IPv6 addresses, dotted decimal can only appear at 596 the end. The /96 prefix is compatible with that requirement. It 597 enables the dotted decimal notation without requiring an update to 598 [RFC4291]. This representation makes the address format easier to 599 use, and log files easier to read. 601 The prefix that we recommend has the particularity of being "checksum 602 neutral". The sum of the hexadecimal numbers "0064" and "FF9B" is 603 "FFFF", i.e. a value equal to zero in one's complement arithmetic. 604 An IPv4-Embedded IPv6 address constructed with this prefix will have 605 the same one's complement checksum as the embedded IPv4 address. 607 5. Security Considerations 609 5.1. Protection Against Spoofing 611 IPv4/IPv6 translators can be modeled as special routers, are subject 612 to the same risks, and can implement the same mitigations. (The 613 discussion of generic threats to routers and their mitigations is 614 beyond the scope of this document.) There is however a particular 615 risk that directly derives from the practice of embedding IPv4 616 addresses in IPv6: address spoofing. 618 An attacker could use an IPv4-Embedded IPv6 address as the source 619 address of malicious packets. After translation, the packets will 620 appear as IPv4 packets from the specified source, and the attacker 621 may be hard to track. If left without mitigation, the attack would 622 allow malicious IPv6 nodes to spoof arbitrary IPv4 addresses. 624 The mitigation is to implement reverse path checks, and to verify 625 throughout the network that packets are coming from an authorized 626 location. 628 5.2. Secure Configuration 630 The prefixes used for address translation are used by IPv6 nodes to 631 send packets to IPv6/IPv4 translators. Attackers could attempt to 632 fool nodes, DNS gateways, and IPv4/IPv6 translators into using wrong 633 values for these parameters, resulting in network disruption, denial 634 of service, and possible information disclosure. To mitigate such 635 attacks, network administrators need to ensure that prefixes are 636 configured in a secure way. 638 The mechanisms for achieving secure configuration of prefixes are 639 beyond the scope of this document. 641 5.3. Firewall Configuration 643 Many firewalls and other security devices filter traffic based on 644 IPv4 addresses. Attackers could attempt to fool these firewalls by 645 sending IPv6 packets to or from IPv6 addresses that translate to the 646 filtered IPv4 addresses. If the attack is successful, traffic that 647 was previously blocked might be able to pass through the firewalls 648 disguised as IPv6 packets. In all such scenarios, administrators 649 should assure that packets that send to or from IPv4 embedded IPv6 650 addresses are subject to the same filtering as those directly sent to 651 or from the embedded IPv4 addresses. 653 The mechanisms for configuring firewalls and security devices to 654 achieve this filtering are beyond the scope of this document. 656 6. IANA Considerations 658 Upon approval of this document, IANA will make the following changes 659 in the "Internet Protocol Version 6 Address Space" registry located 660 at http://www.iana.org/assignments/ipv6-address-space: 662 OLD: 664 IPv6 Prefix Allocation Reference Note 665 ----------- ---------------- ------------ ---------------- 666 0000::/8 Reserved by IETF [RFC4291] [1][5] 668 NEW: 670 IPv6 Prefix Allocation Reference Note 671 ----------- ---------------- ------------ ---------------- 672 0000::/8 Reserved by IETF [RFC4291] [1][5][TBD] 674 [TBD] The "Well Known Prefix" 64:FF9B::/96 used in an algorithmic 675 mapping between IPv4 to IPv6 addresses is defined out of the 676 0000::/8 address block, per [RFC-ietf-behave-address-format]. 678 7. Acknowledgements 680 Many people in the Behave WG have contributed to the discussion that 681 led to this document, including Andrew Sullivan, Andrew Yourtchenko, 682 Ari Keranen, Brian Carpenter, Charlie Kaufman, Dan Wing, Dave Thaler, 683 David Harrington, Ed Jankiewicz, Fred Baker, Hiroshi Miyata, Iljitsch 684 van Beijnum, John Schnizlein, Keith Moore, Kevin Yin, Magnus 685 Westerlund, Margaret Wasserman, Masahito Endo, Phil Roberts, Philip 686 Matthews, Remi Denis-Courmont, Remi Despres and William Waites. 688 Marcelo Bagnulo is partly funded by Trilogy, a research project 689 supported by the European Commission under its Seventh Framework 690 Program. 692 8. Contributors 694 The following individuals co-authored drafts from which text has been 695 incorporated, and are listed in alphabetical order. 697 Congxiao Bao 698 CERNET Center/Tsinghua University 699 Room 225, Main Building, Tsinghua University 700 Beijing, 100084 701 China 702 Phone: +86 62785983 703 Email: congxiao@cernet.edu.cn 705 Dave Thaler 706 Microsoft Corporation 707 One Microsoft Way 708 Redmond, WA 98052 709 USA 710 Phone: +1 425 703 8835 711 Email: dthaler@microsoft.com 713 Fred Baker 714 Cisco Systems 715 Santa Barbara, California 93117 716 USA 717 Phone: +1-408-526-4257 718 Fax: +1-413-473-2403 719 Email: fred@cisco.com 721 Hiroshi Miyata 722 Yokogawa Electric Corporation 723 2-9-32 Nakacho 724 Musashino-shi, Tokyo 180-8750 725 JAPAN 726 Email: h.miyata@jp.yokogawa.com 728 Marcelo Bagnulo 729 Universidad Carlos III de Madrid 730 Av. Universidad 30 731 Leganes, Madrid 28911 732 ESPANA 733 Email: marcelo@it.uc3m.es 735 Xing Li 736 CERNET Center/Tsinghua University 737 Room 225, Main Building, Tsinghua University 738 Beijing, 100084 739 China 740 Phone: +86 62785983 741 Email: xing@cernet.edu.cn 743 9. References 745 9.1. Normative References 747 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 748 Requirement Levels", BCP 14, RFC 2119, March 1997. 750 [RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing 751 Architecture", RFC 4291, February 2006. 753 9.2. Informative References 755 [I-D.ietf-behave-dns64] 756 Bagnulo, M., Sullivan, A., Matthews, P., and I. Beijnum, 757 "DNS64: DNS extensions for Network Address Translation 758 from IPv6 Clients to IPv4 Servers", 759 draft-ietf-behave-dns64-04 (work in progress), 760 December 2009. 762 [I-D.ietf-behave-v6v4-framework] 763 Baker, F., Li, X., Bao, C., and K. Yin, "Framework for 764 IPv4/IPv6 Translation", 765 draft-ietf-behave-v6v4-framework-03 (work in progress), 766 October 2009. 768 [RFC1918] Rekhter, Y., Moskowitz, R., Karrenberg, D., Groot, G., and 769 E. Lear, "Address Allocation for Private Internets", 770 BCP 5, RFC 1918, February 1996. 772 [RFC3484] Draves, R., "Default Address Selection for Internet 773 Protocol version 6 (IPv6)", RFC 3484, February 2003. 775 [RFC3849] Huston, G., Lord, A., and P. Smith, "IPv6 Address Prefix 776 Reserved for Documentation", RFC 3849, July 2004. 778 [RFC4271] Rekhter, Y., Li, T., and S. Hares, "A Border Gateway 779 Protocol 4 (BGP-4)", RFC 4271, January 2006. 781 [RFC5389] Rosenberg, J., Mahy, R., Matthews, P., and D. Wing, 782 "Session Traversal Utilities for NAT (STUN)", RFC 5389, 783 October 2008. 785 [RFC5735] Cotton, M. and L. Vegoda, "Special Use IPv4 Addresses", 786 BCP 153, RFC 5735, January 2010. 788 Authors' Addresses 790 Congxiao Bao 791 CERNET Center/Tsinghua University 792 Room 225, Main Building, Tsinghua University 793 Beijing, 100084 794 China 796 Phone: +86 10-62785983 797 Email: congxiao@cernet.edu.cn 799 Christian Huitema 800 Microsoft Corporation 801 One Microsoft Way 802 Redmond, WA 98052-6399 803 U.S.A. 805 Email: huitema@microsoft.com 807 Marcelo Bagnulo 808 UC3M 809 Av. Universidad 30 810 Leganes, Madrid 28911 811 Spain 813 Phone: +34-91-6249500 814 Fax: 815 Email: marcelo@it.uc3m.es 816 URI: http://www.it.uc3m.es/marcelo 818 Mohamed Boucadair 819 France Telecom 820 3, Av Francois Chateaux 821 Rennes 350000 822 France 824 Email: mohamed.boucadair@orange-ftgroup.com 825 Xing Li 826 CERNET Center/Tsinghua University 827 Room 225, Main Building, Tsinghua University 828 Beijing, 100084 829 China 831 Phone: +86 10-62785983 832 Email: xing@cernet.edu.cn