idnits 2.17.1 draft-ietf-6lowpan-hc-02.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** It looks like you're using RFC 3978 boilerplate. You should update this to the boilerplate described in the IETF Trust License Policy document (see https://trustee.ietf.org/license-info), which is required now. -- Found old boilerplate from RFC 3978, Section 5.1 on line 16. -- Found old boilerplate from RFC 3978, Section 5.5, updated by RFC 4748 on line 610. -- Found old boilerplate from RFC 3979, Section 5, paragraph 1 on line 621. -- Found old boilerplate from RFC 3979, Section 5, paragraph 2 on line 628. -- Found old boilerplate from RFC 3979, Section 5, paragraph 3 on line 634. 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 : ---------------------------------------------------------------------------- -- The draft header indicates that this document updates RFC4944, but the abstract doesn't seem to mention this, which it should. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust Copyright Line does not match the current year (Using the creation date from RFC4944, updated by this document, for RFC5378 checks: 2005-07-13) -- 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 (November 1, 2008) is 5654 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: 'RFC4007' is defined on line 550, but no explicit reference was found in the text == Unused Reference: 'RFC4291' is defined on line 554, but no explicit reference was found in the text ** Obsolete normative reference: RFC 2460 (Obsoleted by RFC 8200) -- Obsolete informational reference (is this intentional?): RFC 3315 (Obsoleted by RFC 8415) Summary: 2 errors (**), 0 flaws (~~), 3 warnings (==), 9 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group J. Hui, Ed. 3 Internet-Draft Arch Rock Corporation 4 Updates: 4944 (if approved) P. Thubert 5 Intended status: Standards Track Cisco 6 Expires: May 5, 2009 November 1, 2008 8 Compression Format for IPv6 Datagrams in 6LoWPAN Networks 9 draft-ietf-6lowpan-hc-02 11 Status of this Memo 13 By submitting this Internet-Draft, each author represents that any 14 applicable patent or other IPR claims of which he or she is aware 15 have been or will be disclosed, and any of which he or she becomes 16 aware will be disclosed, in accordance with Section 6 of BCP 79. 18 Internet-Drafts are working documents of the Internet Engineering 19 Task Force (IETF), its areas, and its working groups. Note that 20 other groups may also distribute working documents as Internet- 21 Drafts. 23 Internet-Drafts are draft documents valid for a maximum of six months 24 and may be updated, replaced, or obsoleted by other documents at any 25 time. It is inappropriate to use Internet-Drafts as reference 26 material or to cite them other than as "work in progress." 28 The list of current Internet-Drafts can be accessed at 29 http://www.ietf.org/ietf/1id-abstracts.txt. 31 The list of Internet-Draft Shadow Directories can be accessed at 32 http://www.ietf.org/shadow.html. 34 This Internet-Draft will expire on May 5, 2009. 36 Abstract 38 This document specifies an IPv6 header compression format for IPv6 39 packet delivery in 6LoWPAN networks. The compression format relies 40 on shared context to allow compression of arbitrary prefixes. This 41 document specifies compression of multicast addresses and a framework 42 for compressing next headers. This framework specifies UDP 43 compression and is prepared for additional transports. 45 Table of Contents 47 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 48 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 4 49 2. IPv6 Header Compression . . . . . . . . . . . . . . . . . . . 4 50 2.1. LOWPAN_IPHC Encoding Format . . . . . . . . . . . . . . . 5 51 2.1.1. Base Format . . . . . . . . . . . . . . . . . . . . . 5 52 2.1.2. Context Identifier Extension . . . . . . . . . . . . . 7 53 2.2. IPv6 Header Encoding . . . . . . . . . . . . . . . . . . . 8 54 2.2.1. Traffic Class and Flow Label Encoding . . . . . . . . 8 55 2.2.2. IPv6 Address Encoding for Unicast Destinations . . . . 9 56 2.2.3. IPv6 Address Encoding for Multicast Destinations . . . 9 57 3. IPv6 Next Header Compression . . . . . . . . . . . . . . . . . 11 58 3.1. LOWPAN_NHC Format . . . . . . . . . . . . . . . . . . . . 11 59 3.2. UDP Header Compression . . . . . . . . . . . . . . . . . . 12 60 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 13 61 5. Security Considerations . . . . . . . . . . . . . . . . . . . 13 62 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 13 63 7. Changes . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 64 8. References . . . . . . . . . . . . . . . . . . . . . . . . . . 13 65 8.1. Normative References . . . . . . . . . . . . . . . . . . . 13 66 8.2. Informative References . . . . . . . . . . . . . . . . . . 14 67 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 14 68 Intellectual Property and Copyright Statements . . . . . . . . . . 16 70 1. Introduction 72 The [IEEE 802.15.4] standard specifies an MTU of 128 bytes, yielding 73 about 80 octets of actual MAC payload once security is turned on, on 74 a wireless link with a link throughput of 250 kbps or less. The 75 6LoWPAN adaptation format [RFC4944] was specified to carry IPv6 76 datagrams over such constrained links, taking into account limited 77 bandwidth, memory, or energy resources that are expected in 78 applications such as wireless Sensor Networks. [RFC4944] defines a 79 Mesh Addressing header to support sub-IP forwarding, a Fragmentation 80 header to support the IPv6 minimum MTU requirement [RFC2460], and 81 stateless header compression for IPv6 datagrams (LOWPAN_HC1 and 82 LOWPAN_HC2) to reduce the relatively large IPv6 and UDP headers down 83 to (in the best case) several bytes. 85 LOWPAN_HC1 and LOWPAN_HC2 are insufficient for most practical uses of 86 6LoWPAN networks. LOWPAN_HC1 is most effective for link-local 87 unicast communication, where IPv6 addresses carry the link-local 88 prefix and an Interface Identifier (IID) directly derived from IEEE 89 802.15.4 addresses. In this case, both addresses may be completely 90 elided. However, though link local addresses are commonly used for 91 local protocol interactions such as IPv6 ND [RFC4861], DHCPv6 92 [RFC3315] or routing protocols, they are usually not used for 93 application layer data traffic, so the actual value of this 94 compression mechanism is limited. 96 Routable addresses must be used when communicating with devices 97 external to the LoWPAN or in a route-over configuration where IP 98 forwarding occurs within the LoWPAN. For routable addresses, 99 LOWPAN_HC1 requires both IPv6 source and destination addresses to 100 carry the prefix in-line. In cases where the Mesh Addressing header 101 is not used, the IID of a routable address must be carried in-line. 102 However, LOWPAN_HC1 requires 64-bits for the IID when carried in-line 103 and cannot be shortened even when it is derived from the IEEE 104 802.15.4 16-bit short address. 106 When the destination is an IPv6 multicast address, LOWPAN_HC1 107 requires the full 128-bit address to be carried in-line. This 108 specification provides an additional mechanism to compress Unique 109 Local, Global and multicast IPv6 Addresses based on shared states 110 within contexts. It also introduces a number of additional 111 improvements over [RFC4944]. 113 LOWPAN_HC1 cannot elide the IPv6 Hop Limit in the IPv6 header, even 114 though a limited set of values are useful in many practical cases. 115 For instance, if the LoWPAN is a mesh-under stub, a Hop Limit of 1 116 for inbound and a default value such as 64 for outbound are usually 117 enough for application layer data traffic. Compressing that field 118 enables saving one octet per packet. 120 LOWPAN_HC1 can be extended to include a LOWPAN_HC2 octet to support 121 compression of UDP, TCP, or ICMPv6; that LOWPAN_HC2 octet is placed 122 right after the LOWPAN_HC1 octet and before the uncompressed IP 123 fields. This specification moves the transport control octet after 124 the uncompressed IP fields for a more properly layered structure. 126 [RFC4944] defines a compression mechanism for UDP, but that mechanism 127 does not enable checksum compression when rendered possible by 128 additional upper layer mechanisms such as upper layer Message 129 Integrity Check (MIC). This specification adds the capability to 130 compress the UDP checksum over the LoWPAN, which enables to save an 131 additional pair of octets. 133 Finally, LOWPAN_HC1 lacks the flexibility to support the compression 134 of additional transport mechanisms that could be introduced in the 135 future. 137 This document specifies a header compression format for IPv6 138 datagrams. This format improves on the header compression format 139 defined in [RFC4944] by generalizing it to support a broader range of 140 communication paradigms, including both mesh-under and route-over 141 configurations; communication to nodes internal and external to the 142 6LoWPAN network; and multicast communication. This document also 143 defines a flexible framework for compressing arbitrary next headers 144 and defines UDP header compression within this framework. This 145 compression format carries forward the design concepts in RFC 4944 146 [RFC4944], minimizing any state and relying on shared context among 147 all nodes in a 6LoWPAN network. 149 1.1. Requirements Language 151 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 152 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 153 document are to be interpreted as described in RFC 2119 [RFC2119]. 155 2. IPv6 Header Compression 157 In this section, we define the LOWPAN_IPHC encoding format for 158 compressing the IPv6 header. To enable effective compression 159 LOWPAN_IPHC relies on information pertaining to the entire 6LoWPAN 160 network. LOWPAN_IPHC assumes the following will be the common case 161 for 6LoWPAN communication: Version is 6; Traffic Class and Flow Label 162 are both zero; Payload Length can be inferred from lower layers from 163 either the 6LoWPAN Fragmentation header or the IEEE 802.15.4 header; 164 Hop Limit will be set to a well-known value by the source; addresses 165 assigned to 6LoWPAN interfaces will be formed using the link-local 166 prefix or a single routable prefix assigned to the entire 6LoWPAN 167 network; addresses assigned to 6LoWPAN interfaces are formed with an 168 IID derived directly from either the 64-bit extended or 16-bit short 169 IEEE 802.15.4 addresses. 171 +-------------------------------------+------------------------ 172 | Dispatch + LOWPAN_IPHC (2-3 octets) | Compressed IPv6 Header 173 +-------------------------------------+------------------------ 175 Figure 1: LOWPAN_IPHC Header 177 The LOWPAN_IPHC encoding utilizes 11 bits, 3 of which are taken from 178 the rightmost bit of the dispatch type. The encoding may be extended 179 by another octet to support additional contexts. Uncompressed IPv6 180 header fields follow the LOWPAN_IPHC encoding, as shown in Figure 1. 181 With the above scenario, the LOWPAN_IPHC can compress the IPv6 header 182 down to two octets (the dispatch octet and the LOWPAN_IPHC encoding) 183 with link-local communication. When routing over multiple IP hops, 184 LOWPAN_IPHC can compress the IPv6 header down to 7 octets (1-octet 185 dispatch, 1-octet LOWPAN_IPHC, 1-octet Hop Limit, 2-octet Source 186 Address, and 2-octet Destination Address). 188 2.1. LOWPAN_IPHC Encoding Format 190 2.1.1. Base Format 192 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 193 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 194 | 0 | 1 | 0 | 0 | 1 | TF |NH | HLIM | CM | SAM | DAM | 195 +---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+ 197 Figure 2: LOWPAN_IPHC Encoding 199 TF: Traffic Class, Flow Label: 200 00: 4-bit Pad + Traffic Class + Flow Label (4 bytes) 201 01: ECN + 2-bit Pad + Flow Label (3 bytes) 202 10: Traffic Class (1 byte) 203 11: Version, Traffic Class, and Flow Label are compressed. 204 NH: Next Header: 206 0: Full 8 bits for Next Header are carried in-line. 207 1: The Next Header field is compressed and the next header is 208 compressed using LOWPAN_NHC, which is discussed in Section 3. 209 HLIM: Hop Limit: 210 00: The Hop Limit field is carried in-line. 211 01: The Hop Limit field is compressed and the the hop limit is 1. 212 10: The Hop Limit field is compressed and the the hop limit is 213 64. 214 11: The Hop Limit field is compressed and the hop limit is 255. 215 CM: Compression Mode: 216 00: Stateful compression using a default context. In this case 217 the context for SAM and DAM is the default context. 218 01: Stateful compression using an indexed context; In this case 219 the context for SAM and DAM is indicated in additional context 220 octets that extends the LOWPAN_IPHC field to disambiguate an 221 elided prefix or address described by the SAM or DAM fields. 222 10: Stateless compression using a well-know (Link-Local) prefix; 223 In this case, the context is the Link Local context and the 224 prefix is FE80::/64. This compression mode is used for link 225 local to link local communication. 226 11: Stateless compression using a well-know pattern; In this 227 case, the context for the source address is the Link Local 228 context and the prefix is FE80::/64. The compression for the 229 destination address does not use a context but a well-known 230 pattern used in multicast addresses. This compression mode is 231 used for link local to link scoped multicast group 232 communication. 233 SAM & DAM: Source and Destination Address Mode: The values for the 234 SAM field are generally are generically as follows: 235 00: 128 bits: The whole Address is carried in-line. 236 01: 64 bits: the first 64 bits of the Address are elided. The 237 value of those bits are taken from the context and padded with 238 zeroes. The remaining 64 bits are carried inline. 239 10: 16 bits: the first 112 bits of the Address are elided. The 240 value of those bits is taken from the context and padded with 241 zeroes. The remaining 16 bits are carried inline. 242 11: 0 bit. The Address is fully elided. The first 64 bits of 243 the Address are elided taken from the context. The remaining 244 64 bits are computed from the link layer address as defined in 245 [RFC4944]. 246 This generic rule applies depending on the CM field and with 247 exceptions as follows: 248 CM field of 10 (well-known prefix): The value of 00 is reserved 249 for SAM and DAM. 251 CM field of 11 (well-known pattern): The SAM value of 00 252 indicates that the Source Address is the unspecified address. 253 The compression of the Destination Address relies on well-known 254 patterns for multicast addresses as follows: 255 00: 8 bits. Used to compress the most used permanently- 256 assigned multicast addresses. A prefix of FF02::/120 is 257 elided. The remaining 8 bits are carried inline. 258 01: 24 bits. Used to compress Solicited-Node multicast 259 addresses. A prefix of FF02::1:FF00:0/104 is elided. The 260 remaining 24 bits are carried inline. 261 10: 16 bits: The Compressed Multicast address fsmg where f is 262 4-bit flags, s is 4-bit scope, and mg is the least 263 significant 8 bits of the multicast group identifier FFfs:: 264 00mg. The 16 bits of fsmg are carried inline. 265 11: 24 bits: The Compressed Multicast address fsmgmg where f 266 is 4-bit flags, s is 4-bit scope, and mgmg is the least 267 significant 16 bits of the multicast group identifier FFfs:: 268 mgmg. The 24 bits of fsmgmg are carried inline. 270 2.1.2. Context Identifier Extension 272 This specification expects that a concept of context is shared 273 between the node that compresses a packet and the node(s) that need 274 to expand it. The specification enables a node to use of up to 16 275 contexts. How the contexts are shared and maintained is out of 276 scope. Actions in response to unknown and/or invalid contexts are 277 out of scope. 279 If the CM field is set to '01' in the LOWPAN_HC encoding, then an 280 additional octet extends the LOWPAN_HC encoding following the DAM 281 bits but before the IPv6 header fields that are carried in-line. The 282 additional octet identifies the prefix when the IPv6 source and/or 283 destination address is compressed. The context identifier is 4 bits 284 for each address, supporting up to 16 contexts. The encoding is 285 shown in Figure 3. 287 0 1 2 3 4 5 6 7 288 +---+---+---+---+---+---+---+---+ 289 | SAC | DAC | 290 +---+---+---+---+---+---+---+---+ 292 Figure 3: LOWPAN_IPHC Encoding 294 SAC: Source Address Context Identifies the prefix that is used when 295 the IPv6 source address is compressed. 296 DAC: Destination Address Context Identifies the prefix that is used 297 when the IPv6 destination address is compressed. 299 2.2. IPv6 Header Encoding 301 Fields carried in-line (in part or in whole) appear in the same order 302 as they do in the IPv6 header format [RFC2460]. The Version field is 303 always elided. Unicast IPv6 addresses may be compressed to 64 or 16 304 bits or completely elided. Multicast IPv6 addresses may be 305 compressed to 8, 16, or 24 bits. The IPv6 Payload Length field MUST 306 always be elided and inferred from lower layers using the 6LoWPAN 307 Fragmentation header or the IEEE 802.15.4 header. 309 2.2.1. Traffic Class and Flow Label Encoding 311 The TF field in the LOWPAN_HC encoding indicate whether the Traffic 312 Class and Flow Label are carried in-line in the compressed IPv6 313 header. When Flow Label is included while the Traffic Class is 314 compressed, an additional 4 bits are included to maintain byte- 315 alignment. Two of the 4 bits contain the ECN bits from the Traffic 316 Class field. 318 To ensure that the ECN bits appear in the same location for all 319 encodings that include them, the Traffic Class field is rotated right 320 by 2 bits in the compressed IPv6 header. The encodings are shown 321 below: 323 1 2 3 324 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 325 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 326 |ECN| DSCP | rsv | Flow Label | 327 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 329 TF = 00 331 1 2 332 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 333 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 334 |ECN|rsv| Flow Label | 335 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 336 TF = 01 338 0 1 2 3 4 5 6 7 339 +-+-+-+-+-+-+-+-+ 340 |ECN| DSCP | 341 +-+-+-+-+-+-+-+-+ 343 TF = 10 345 2.2.2. IPv6 Address Encoding for Unicast Destinations 347 IPv6 unicast addresses may be carried in-line in full or or 348 compressed to 64, 16, or 0 bits. When compressed, the bits carried 349 in-line represent the least significant bits of the suffix. The 350 value of the prefix depends on the value of the DDF field and 351 possibly the SAC field in the Context Identifier Extension. 353 Destination is Global with No Context ID (DDF = 00): When the 354 source and/or destination addresses are compressed, the prefix is 355 identified by context 0. 356 Destination is Global with Context ID (DDF = 01): When the source 357 and/or destination addresses are compressed, the prefix is 358 identified by the SAC and DAC fields in the Context Identifier 359 Extension, respectively. 360 Destination is Link-Local Unicast (DDF = 10): When the source 361 and/or destination addresses are compressed, the prefix is the 362 link-local unicast prefix (FE80::/10). 364 When an address is completely elided, the lower bits are inferred 365 from lower layers (either from the 6LoWPAN Mesh Addressing header or 366 from the IEEE 802.15.4 header). Specifically, if the lower-layer 367 header contains an extended 802.15.4 address, then a 64-bit suffix is 368 derived from the lower-layer header. If the lower-layer header 369 contains short 802.15.4 address, then a 16-bit suffix is derived from 370 the lower-layer header. 372 2.2.3. IPv6 Address Encoding for Multicast Destinations 374 IPv6 source addresses with link-local scope may be compressed when 375 the destination address is a multicast address. The IPv6 source 376 address may be compressed to 64, 16, or 0 bits. The encoding also 377 supports the compression of the unspecified address (::). 379 SAM = 00: Source Address is the unspecified address and all 128 bits 380 are elided. 381 SAM = 01: 64-bit prefix is elided and is the link-local (FE80::/10). 382 64-bit Suffix is carried in-line. 383 SAM = 10: 112-bit prefix is elided and is the link-local 384 (FE80::/10). 16-bit Suffix is carried in-line. 385 SAM = 11: All 128 bits of Source Address are elided. The prefix is 386 the link-local prefix (FE80::/10). The suffix is derived from 387 lower-layer headers. 389 IPv6 multicast addresses may be comrpessed down to 24, 16, or 8 bits. 390 The format supports compression of the Solicited-Node Multicast 391 Address (FF02::1:FFXX:XXXX) as well as any IPv6 multicast address 392 where the upper 104 bits of the multicast group identifier are zero 393 (FFXX::XXXX). The encoding format also compressed link-local 394 multicast addresses of the form (FF02::00XX) down to a single byte. 395 The compressed form only carries least-significant bits of the 396 multicast group identifier. 398 0 1 2 3 4 5 6 7 399 +-+-+-+-+-+-+-+-+ 400 | Group ID | 401 +-+-+-+-+-+-+-+-+ 403 DAM = 00. 8-bit Compressed Multicast Address (FF02::00mg) 405 1 2 406 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 407 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 408 | Last 24 bits of Group ID | 409 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 411 DAM = 01. Compressed Solicited-Node Address (FF02::1:FFXX:XXXX). 413 1 414 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 415 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 416 | Flags | Scope | Group ID | 417 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 419 DAM = 10. 16-bit Compressed Multicast Address (FFfs::00mg). 421 1 2 422 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 423 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 424 | Flags | Scope | Last 16 bits of Group ID | 425 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 427 DAM = 11. 24-bit Compressed Multicast Address (FFfs::mgmg). 429 3. IPv6 Next Header Compression 431 LOWPAN_IPHC elides the IPv6 Next Header field when the NH bit is set 432 to 1. It also indicates the use of 6LoWPAN next header compression, 433 LOWPAN_NHC. The value of IPv6 Next Header is recovered from the 434 first bits in the LOWPAN_NHC encoding. The following bits are 435 specific to the IPv6 Next Header value. Figure 4 shows the structure 436 of an IPv6 datagram compressed using LOWPAN_IPHC and LOWPAN_NHC. 438 +-------------+-------------+-------------+-----------------+-------- 439 | LOWPAN_IPHC | In-line | LOWPAN_NHC | In-line Next | Payload 440 | Encoding | IP Fields | Encoding | Header Fields | 441 +-------------+-------------+-------------+-----------------+-------- 443 Figure 4: Typical LOWPAN_IPHC/LOWPAN_NHC Header Configuration 445 3.1. LOWPAN_NHC Format 447 Compression formats for different next headers are identified by a 448 variable length bit-pattern immediately following the LOWPAN_IPHC 449 compressed header. When defining a next header compression format, 450 the number of bits used SHOULD be determined by the perceived 451 frequency of using that format. However, the number of bits and any 452 remaining encoding bits SHOULD respect octet alignment. The 453 following bits are specific to the next header compression format. 454 In this document, we define a compression format for UDP headers. 456 +----------------+--------------------------- 457 | var-len NHC ID | compressed next header... 458 +----------------+--------------------------- 459 Figure 5: LOWPAN_NHC Encoding 461 3.2. UDP Header Compression 463 This document defines a compression format for UDP headers using 464 LOWPAN_NHC. The UDP compression format is shown in Figure 6. Bits 0 465 through 4 represent the NHC ID and '11110' indicates the specific UDP 466 header compression encoding defined in this section. 468 0 1 2 3 4 5 6 7 469 +---+---+---+---+---+---+---+---+ 470 | 1 | 1 | 1 | 1 | 0 | C | P | 471 +---+---+---+---+---+---+---+---+ 473 Figure 6: UDP Header Encoding 475 C: Checksum: 476 0: All 16 bits of Checksum are carried in-line. The Checksum MUST 477 be included if there are no other end-to-end integrity checks 478 that are stronger than what is provided by the UDP checksum. 479 Such an integrity check MUST be end-to-end and cover the IPv6 480 pseudo-header, UDP header, and UDP payload. 481 1: All 16 bits of Checksum are elided. The Checksum is recovered 482 by recomputing it. 483 P: Ports: 484 00: All 16 bits for both Source Port and Destination Port are 485 carried in-line. 486 01: All 16 bits for Source Port are carried in-line. First 8 487 bits of Destination Port is 0xF0 and elided. The remaining 8 488 bits of Destination Port are carried in-line. 489 10: First 8 bits of Source Port are 0xF0 and elided. The 490 remaining 8 bits of Source Port are carried in-line. All 16 491 bits for Destination Port are carried in-line. 492 11: First 12 bits of both Source Port and Destination Port are 493 0xF0B and elided. The remaining 4 bits for each are carried 494 in-line. 496 Fields carried in-line (in part or in whole) appear in the same order 497 as they do in the IPv6 header format [RFC2460]. IPv6 addresses may 498 be compressed to 64 or 16 bits or completely elided. The UDP Length 499 field MUST always be elided and is inferred from lower layers using 500 the 6LoWPAN Fragmentation header or the IEEE 802.15.4 header. 502 4. IANA Considerations 504 This document defines a new IPv6 header compression format for 505 6LoWPAN networks. The document allocates Dispatch type values of 506 0x08-0x0F (TBD) for LOWPAN_IPHC. 508 5. Security Considerations 510 The definition of LOWPAN_IPHC permits the compression of header 511 information on communication that could take place in its absence, 512 albeit in a less efficient form. It recognizes that a IEEE 802.15.4 513 PAN may have associated with it a number of prefixes through shared 514 context. How the shared context is assigned and managed is beyond 515 the scope of this document. 517 6. Acknowledgements 519 Thanks to Julien Abeille, Carsten Bormann, Christos Polyzois, and Jay 520 Werb for useful feedback and discussion. 522 7. Changes 524 Draft 02: 525 - Updated wording with compression mode to clarify that a 526 compression mode does not enforce what kind of destination address 527 is being used. Specifically changed Destination Dependent Field 528 to Compression Mode. 529 - Specify that the configuration and management of contexts is out 530 of scope of this document. 532 Draft 01: 533 - HC back to 1 byte by default by stealing a few bits from the 534 dispatch field. 535 - Added better support for multicast address compression. 536 - Fixed alignment for UDP port compression. 537 - Better support for Traffic Class and Flow Label compression. 538 - Pascal joined as an author. 540 8. References 542 8.1. Normative References 544 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 545 Requirement Levels", BCP 14, RFC 2119, March 1997. 547 [RFC2460] Deering, S. and R. Hinden, "Internet Protocol, Version 6 548 (IPv6) Specification", RFC 2460, December 1998. 550 [RFC4007] Deering, S., Haberman, B., Jinmei, T., Nordmark, E., and 551 B. Zill, "IPv6 Scoped Address Architecture", RFC 4007, 552 March 2005. 554 [RFC4291] Hinden, R. and S. Deering, "IP Version 6 Addressing 555 Architecture", RFC 4291, February 2006. 557 [RFC4944] Montenegro, G., Kushalnagar, N., Hui, J., and D. Culler, 558 "Transmission of IPv6 Packets over IEEE 802.15.4 559 Networks", RFC 4944, September 2007. 561 8.2. Informative References 563 [IEEE 802.15.4] 564 IEEE Computer Society, "IEEE Std. 802.15.4-2006", 565 October 2006. 567 [RFC3315] Droms, R., Bound, J., Volz, B., Lemon, T., Perkins, C., 568 and M. Carney, "Dynamic Host Configuration Protocol for 569 IPv6 (DHCPv6)", RFC 3315, July 2003. 571 [RFC4861] Narten, T., Nordmark, E., Simpson, W., and H. Soliman, 572 "Neighbor Discovery for IP version 6 (IPv6)", RFC 4861, 573 September 2007. 575 Authors' Addresses 577 Jonathan W. Hui (editor) 578 Arch Rock Corporation 579 501 2nd St. Ste. 410 580 San Francisco, California 94107 581 USA 583 Phone: +415 692 0828 584 Email: jhui@archrock.com 585 Pascal Thubert 586 Cisco Systems 587 Village d'Entreprises Green Side 588 400, Avenue de Roumanille 589 Batiment T3 590 Biot - Sophia Antipolis 06410 591 FRANCE 593 Phone: +33 4 97 23 26 34 594 Email: pthubert@cisco.com 596 Full Copyright Statement 598 Copyright (C) The IETF Trust (2008). 600 This document is subject to the rights, licenses and restrictions 601 contained in BCP 78, and except as set forth therein, the authors 602 retain all their rights. 604 This document and the information contained herein are provided on an 605 "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS 606 OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND 607 THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS 608 OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF 609 THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED 610 WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. 612 Intellectual Property 614 The IETF takes no position regarding the validity or scope of any 615 Intellectual Property Rights or other rights that might be claimed to 616 pertain to the implementation or use of the technology described in 617 this document or the extent to which any license under such rights 618 might or might not be available; nor does it represent that it has 619 made any independent effort to identify any such rights. Information 620 on the procedures with respect to rights in RFC documents can be 621 found in BCP 78 and BCP 79. 623 Copies of IPR disclosures made to the IETF Secretariat and any 624 assurances of licenses to be made available, or the result of an 625 attempt made to obtain a general license or permission for the use of 626 such proprietary rights by implementers or users of this 627 specification can be obtained from the IETF on-line IPR repository at 628 http://www.ietf.org/ipr. 630 The IETF invites any interested party to bring to its attention any 631 copyrights, patents or patent applications, or other proprietary 632 rights that may cover technology that may be required to implement 633 this standard. Please address the information to the IETF at 634 ietf-ipr@ietf.org.