RFC 4623

Pseudowire Emulation Edge-to-Edge (PWE3) Fragmentation and Reassembly

πŸ“… published August 2006, from ietf

RFC 4623: Pseudowire Emulation Edge-to-Edge (PWE3) Fragmentation and Reassembly πŸŽ€

Okay bestie, here's the vibe check on this one πŸ’… It's from the Network Working Group, written by A. Malis (Tellabs) and M. Townsley (Cisco Systems). It's a Standards Track doc and it's dated August 2006 πŸ—“οΈ It doesn't list any Obsoletes or Updates headers, so it isn't replacing or changing another RFC on paper.

Status of This Memo ✨

This document is a Standards Track protocol for the Internet community, and it's literally asking for discussion and suggestions for improvements πŸ’¬ For the current standardization state and status of this protocol, check the "Internet Official Protocol Standards" (STD 1) πŸ“š Distribution of this memo is unlimited 🌸

Copyright (C) The Internet Society (2006).

Abstract πŸ¦‹

This doc defines a generalized method of performing fragmentation for use by Pseudowire Emulation Edge-to-Edge (PWE3) protocols and services. It's giving "one method to rule them all" energy πŸ‘‘

Table of Contents 🧚

1. Introduction ....................................................3
2. Conventions Used in This Document ...............................4
3. Alternatives to PWE3 Fragmentation/Reassembly ...................5
4. PWE3 Fragmentation with MPLS ....................................5
   4.1. Fragment Bit Locations for MPLS ............................6
   4.2. Other Considerations .......................................6
5. PWE3 Fragmentation with L2TP ....................................6
   5.1. PW-Specific Fragmentation vs. IP fragmentation .............7
   5.2. Advertising Reassembly Support in L2TP .....................7
   5.3. L2TP Maximum Receive Unit (MRU) AVP ........................8
   5.4. L2TP Maximum Reassembled Receive Unit (MRRU) AVP ...........8
   5.5. Fragment Bit Locations for L2TPv3 Encapsulation ............9
   5.6. Fragment Bit Locations for L2TPv2 Encapsulation ............9
6. Security Considerations ........................................10
7. IANA Considerations ............................................10
   7.1. Control Message Attribute Value Pairs (AVPs) ..............11
   7.2. Default L2-Specific Sublayer Bits .........................11
   7.3. Leading Bits of the L2TPv2 Message Header .................11
8. Acknowledgements ...............................................11
9. Normative References ...........................................12
10. Informative References ........................................12
Appendix A. Relationship Between This Document and RFC 1990 .......14

1. Introduction 🌈

Okay so, the PWE3 Edge-to-Edge Architecture doc [Architecture] gives us the network reference model, and it's honestly a masterpiece πŸ–ΌοΈ

         |<-------------- Emulated Service ---------------->|
         |                                                  |
         |          |<------- Pseudowire ------->|          |
         |          |                            |          |
         |          |    |<-- PSN Tunnel -->|    |          |
         | PW End   V    V                  V    V  PW End  |
         V Service  +----+                  +----+  Service V
   +-----+    |     | PE1|==================| PE2|     |    +-----+
   |     |----------|............PW1.............|----------|     |
   | CE1 |    |     |    |                  |    |     |    | CE2 |
   |     |----------|............PW2.............|----------|     |
   +-----+  ^ |     |    |==================|    |     | ^  +-----+
         ^  |       +----+                  +----+     | |  ^
         |  |   Provider Edge 1         Provider Edge 2  |  |
         |  |                                            |  |
   Customer |                                            | Customer
   Edge 1   |                                            | Edge 2
            |                                            |
            |                                            |
      native service                               native service

                  Figure 1: PWE3 Network Reference Model

So a Pseudowire (PW) payload usually gets sent across the PW as one single IP or MPLS Packet Switched Network (PSN) Protocol Data Unit (PDU) πŸ“¦ But sometimes the payload plus its PWE3 and PSN headers can be bigger than the PSN path Maximum Transmission Unit (MTU) 😬 When a packet is bigger than the MTU of a network, fragmentation and reassembly are what let that packet get through the network and reach where it's supposed to go πŸš€

The whole point of this doc is to define a generalized method of fragmentation that works with all PWE3 protocols and services ✨ This method should only be used when MTU-management methods fail πŸ™…β€β™€οΈ Fragmenting and reassembling in core network devices costs a lot of extra processing, so it should always be something you avoid whenever you can πŸ’€

The PWE3 fragmentation and reassembly domain is shown in Figure 2 πŸ‘€

         |<-------------- Emulated Service ---------------->|
         |          |<---Fragmentation Domain--->|          |
         |          ||<------- Pseudowire ----->||          |
         |          ||                          ||          |
         |          ||   |<-- PSN Tunnel -->|   ||          |
         | PW End   VV   V                  V   VV  PW End  |
         V Service  +----+                  +----+  Service V
   +-----+    |     | PE1|==================| PE2|     |    +-----+
   |     |----------|............PW1.............|----------|     |
   | CE1 |    |     |    |                  |    |     |    | CE2 |
   |     |----------|............PW2.............|----------|     |
   +-----+  ^ |     |    |==================|    |     | ^  +-----+
         ^  |       +----+                  +----+     | |  ^
         |  |   Provider Edge 1         Provider Edge 2  |  |
         |  |                                            |  |
   Customer |                                            | Customer
   Edge 1   |                                            | Edge 2
            |                                            |
            |                                            |
      native service                               native service

              Figure 2: PWE3 Fragmentation/Reassembly Domain

Fragmentation happens in the transmitting PE right before PW encapsulation, and reassembly happens in the receiving PE right after PW decapsulation πŸ”„

Here's the thing: fragmentation and reassembly need a sequence number, so using the Sequence Number field on fragmented packets is REQUIRED πŸ”‘ (check Sections 4.1 and 5.5 for where the Sequence Number fields live for MPLS and L2TPv3 encapsulations, respectively). The order is: fragment first, then give each resulting fragment a sequential sequence number πŸ”’

Depending on which PWE3 encapsulation you're using, the value 0 might not be part of the sequence number space. If it isn't, then its use for fragmentation has to follow the same rule: as the sequence number goes up, it skips zero and wraps from 65535 to 1 πŸŒ€ On the flip side, if 0 is part of the sequence space, the same sequence space gets used for fragmentation and reassembly too πŸ’œ

2. Conventions Used in This Document πŸŽ€

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [KEYWORDS] πŸ€“

3. Alternatives to PWE3 Fragmentation/Reassembly πŸ¦‹

Fragmenting and reassembling in network equipment usually takes way more resources than sending a packet as one unit 😩 So fragmentation should be avoided whenever possible! The ideal ways to avoid it are proper configuration and management of MTU sizes between the Customer Edge (CE) router and Provider Edge (PE) router and across the PSN, plus adaptive measures that work with the originating host (e.g., [PATHMTU], [PATHMTUv6]) to shrink the packet sizes at the source πŸ™Œ

Sometimes a PE can fragment an IP version 4 (IPv4) [RFC791] packet before it enters a PW. Like, if the PE can fragment and forward IPv4 packets with the DF bit clear in a way that's identical to an IPv4 router, it can fragment packets coming in from a CE and forward the IPv4 fragments over the PW with the framing for that attachment circuit (AC) πŸ“ Architecturally, the IPv4 fragmentation happens before the PW, so the PW just sees multiple frames and forwards them the normal way for that PWType. This means the method is totally transparent to the PW encapsulation and to the remote end of the PW itself 🫢 The packet fragments get reassembled on the destination IPv4 host in the normal way. IPv6 packets are NOT to be fragmented this way 🚫

4. PWE3 Fragmentation with MPLS 🧚

When you're using the signaling procedures in [MPLS-Control], there's a Pseudowire Interface Parameter Sub-TLV type that signals fragmentation when advertising a VC label [IANA] πŸ’«

   Parameter      Length    Description
        0x09           4    Fragmentation indicator

If that parameter shows up in the VC FEC element, it means the receiver can reassemble fragments when the control word is in use for the VC label being advertised. It doesn't obligate the sender to fragment, though. It just says the sender MAY use fragmentation. The sender MUST NOT use fragmentation if this parameter is NOT present in the VC FEC element πŸ™…β€β™€οΈ

If [MPLS-Control] signaling isn't in use, then whether or not to use fragmentation MUST be configured in the sender βš™οΈ

4.1. Fragment Bit Locations for MPLS πŸ”₯

MPLS-based PWE3 uses the following control word format [Control-Word], with the B and E fragmentation bits sitting in positions 8 and 9 🎯

 0                   1                   2                   3
 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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|0 0 0 0| Flags |B|E|   Length  |     Sequence Number           |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

              Figure 3: Preferred PW MPLS Control Word

Here's how the B and E bits work 🧠

BE
--
00 indicates that the entire (un-fragmented) payload is carried
   in a single packet
01 indicates the packet carrying the first fragment
10 indicates the packet carrying the last fragment
11 indicates a packet carrying an intermediate fragment

Check Appendix A if you want the derivation behind these B and E bit values πŸ“– And see Section 1 for how the Sequence Number field gets used πŸ’…

4.2. Other Considerations 🌸

Path MTU [PATHMTU] [PATHMTUv6] can be used to dynamically figure out the maximum size for fragments 🧭 How path MTU applies to MPLS is discussed in [LABELSTACK]. You can also just configure the maximum size of the fragments yourself βš™οΈ And the signaled Interface MTU parameter in [MPLS-Control] SHOULD be used to set the maximum size of the reassembly buffer for received packets, so you make the best use of your reassembly buffer resources 🫧

5. PWE3 Fragmentation with L2TP πŸŽ€

okay bestie, this section is where we get into L2TP πŸ¦‹ It defines where the B and E bits live in the L2TPv3 [L2TPv3] and L2TPv2 [L2TPv2] headers, plus the signaling for advertising MRU (Maximum Receive Unit) values and whether fragmentation is supported on a given PW. Since IP is the most common PSN used with L2TP, IP PSN fragmentation and reassembly gets covered too πŸ’…

5.1. PW-Specific Fragmentation vs. IP fragmentation

when proper MTU management across a network fails, IP PSN fragmentation and reassembly can be used to deal with MTU mismatches between tunnel endpoints 🌸 if the overall traffic that needs fragmentation and reassembly is very light, or there are enough optimized mechanisms for IP PSN fragmentation and reassembly already available, IP PSN fragmentation and reassembly may be sufficient ✨

but when you're dealing with a large number of PW packets that need fragmentation and reassembly, a PW-specific method has properties that can lead to more resource-friendly implementations 🧚 the ability to assign buffer usage on a per-PW basis, plus PW sequencing, can be used to get an edge over a general mechanism that applies to all IP packets across all PWs. PW fragmentation can also be turned on selectively for some or all PWs, instead of enabling reassembly for every bit of IP traffic arriving at a given node πŸ’–

Deployments SHOULD avoid a situation that uses a combination of IP PSN and PW fragmentation and reassembly on the same node πŸ™ˆ that clearly defeats the purpose of the mechanism defined in this document. This is especially important for L2TPv3 pseudowires, because fragmentation can potentially happen in three different places: the IP PSN, the PW, and the encapsulated payload πŸ’€ MTU/MRU values need to be set and advertised properly at each tunnel endpoint to avoid this. When fragmentation is enabled within a given PW, the DF bit MUST be set on all L2TP over IP packets for that PW πŸ”₯

L2TPv3 nodes SHOULD participate in Path MTU ([PATHMTU], [PATHMTUv6]) for automatic adjustment of the PSN MTU πŸ‘‘ when the payload is IP, Path MTU should be used at the payload level as well 🫢

5.2. Advertising Reassembly Support in L2TP

the constructs defined in this section for advertising fragmentation support in L2TP apply to both [L2TPv3] and [L2TPv2] πŸ’œ

this document defines two new AVPs to advertise maximum receive unit values and reassembly support ✨ these AVPs MAY be present in the ICRQ, ICRP, ICCN, OCRQ, OCRP, OCCN, or SLI messages (that's Incoming-Call-Request (ICRQ), Incoming-Call-Reply (ICRP), Incoming-Call-Connected (ICCN), Outgoing-Call-Request (OCRQ), Outgoing-Call-Reply (OCRP), Outgoing-Call-Connected (OCCN), and Set-Link-Info (SLI), fr fr πŸ¦‹). the most recent value received always takes precedence over a previous value, and it MUST be dynamic over the life of the session if it's received via the SLI message 🌈 one of the two new AVPs (MRRU) is used to advertise that PWE3 reassembly is supported by the sender of the AVP. Reassembly support MAY be unidirectional πŸ“

5.3. L2TP Maximum Receive Unit (MRU) AVP

    0                   1                   2                   3
    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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |M|H|0|0|0|0|    Length         |              0                |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              MRU              |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

              Figure 4: L2TP Maximum Receive Unit (MRU) AVP

MRU (Maximum Receive Unit), attribute number 94, is the maximum size, in octets, of a fragmented or complete PW frame (including L2TP encapsulation) that the side of the PW advertising this value can receive πŸŽ€ the advertised MRU does NOT include the PSN header (aka the IP and/or UDP header). This AVP does not imply that PWE3 fragmentation or reassembly is supported πŸ™ƒ if reassembly is not enabled or unavailable, this AVP may be used alone to advertise the MRU for a complete frame.

this AVP MAY be hidden (the H bit MAY be 0 or 1). The mandatory (M) bit for this AVP SHOULD be set to 0. The Length (before hiding) is 8, and the Vendor ID is the IETF Vendor ID of 0 🧚

5.4. L2TP Maximum Reassembled Receive Unit (MRRU) AVP

    0                   1                   2                   3
    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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |M|H|0|0|0|0|    Length         |              0                |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              MRRU             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

       Figure 5: L2TP Maximum Reassembled Receive Unit (MRRU) AVP

MRRU (Maximum Reassembled Receive Unit AVP), attribute number 95, is the maximum size, in octets, of a reassembled frame. That includes any PW framing, but not the L2TP encapsulation or the L2-specific sublayer 🌷 having this AVP present means you can receive PW fragments and reassemble them πŸ’… packet fragments MUST NOT be sent by a peer that hasn't received this AVP in a control message. And if the MRRU is present in a message, the MRU AVP MUST be present as well 🚫

the MRRU SHOULD be used to set the maximum size of the reassembly buffer for received packets, so you make the best use of reassembly buffer resources πŸ¦‹

this AVP MAY be hidden (the H bit MAY be 0 or 1). The mandatory (M) bit for this AVP SHOULD be set to 0. The Length (before hiding) is 8, and the Vendor ID is the IETF Vendor ID of 0 ✨

5.5. Fragment Bit Locations for L2TPv3 Encapsulation

the usage of the B and E bits is described in Section 4.1. For L2TPv3 encapsulation, the B and E bits are defined as bits 2 and 3 in the leading bits of the Default L2-Specific Sublayer (see Section 7) 🧩

    0                   1                   2                   3
    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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |M|H|0|0|0|0|    Length         |              0                |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |x|S|B|E|x|x|x|x|              Sequence Number                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Figure 6: B and E Bits Location in the Default L2-Specific Sublayer

The S (Sequence) bit is as defined in [L2TPv3]. Where the B and E bits sit for PW-Types that use a variant L2 specific sublayer is outside the scope of this document πŸ™ˆ

when fragmentation is used, an L2-Specific Sublayer with B and E bits defined MUST be present in all data packets for a given session πŸ”₯ the presence and format of the L2-Specific Sublayer is advertised via the L2-Specific Sublayer AVP, Attribute Type 69, defined in Section 5.4.4 of [L2TPv3] πŸ“£

See Section 1 for the description of how the Sequence Number field is used 🌸

5.6. Fragment Bit Locations for L2TPv2 Encapsulation

the usage of the B and E bits is described in Section 4.1. For L2TPv2 encapsulation, the B and E bits are defined as bits 8 and 9 in the leading bits of the L2TPv2 header, as shown below (see Section 7) 🌈

    0                   1                   2                   3
    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
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |M|H|0|0|0|0|    Length         |              0                |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |T|L|x|x|S|x|O|P|B|E|x|x|  Ver  |          Length (opt)         |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

       Figure 7: B and E bits location in the L2TPv2 Message Header

6. Security Considerations πŸ”

as with any additional protocol construct, each level of complexity adds the potential to exploit protocol and implementation errors 😭 implementers should be especially careful not to tie up an abundance of resources, even for the most pathological combination of packet fragments that could be received. Beyond these general implementation quality issues, there are no known notable security issues with using the mechanism defined in this document. It's worth pointing out that RFC 1990, which this document is based on, and its derivatives have been widely implemented and extensively used across the Internet and elsewhere πŸ‘‘

[IPFRAG-SEC] and [TINYFRAG] describe potential network attacks associated with IP fragmentation and reassembly 🚨 these issues try to bypass IP access controls by sending carefully formed "tiny fragments", or by abusing the IP offset field so fragments overlap and rewrite interesting portions of an IP packet after access checks have already happened. The latter is not an issue for the PW-specific fragmentation method described in this document, because there is no offset field πŸ¦‹ however, implementations MUST be sure not to allow more than one whole fragment to overwrite another in a reconstructed frame. The former may be a concern if packet filtering and access controls are placed on tunneled frames within the PW encapsulation. To get around any possible attacks in either case, all filtering and access controls should be applied to the resulting reconstructed frame rather than to any PW fragments πŸ›‘οΈ


7. IANA Considerations πŸ“‹

this document does not define any new registries for IANA to maintain 🌸

note that [IANA] has already allocated the Fragmentation Indicator interface parameter, so no further IANA action is required βœ…

this document requires IANA to assign new values for registries IANA already manages (see Sections 7.1 and 7.2) and two reserved bits in an existing header (see Section 7.3) πŸ’–

7.1. Control Message Attribute Value Pairs (AVPs)

two additional AVP Attributes are specified in Sections 5.3 and 5.4. They are required to be defined by IANA as described in Section 2.2 of [BCP0068] πŸŽ€

Control Message Attribute Value Pairs
-------------------------------------

94 - Maximum Receive Unit (MRU) AVP
95 - Maximum Reassembled Receive Unit (MRRU) AVP

7.2. Default L2-Specific Sublayer Bits

this registry was created as part of the publication of [L2TPv3]. This document defines two reserved bits in the Default L2-Specific Sublayer in Section 5.5, which may be assigned by IETF Consensus [RFC2434]. They are required to be assigned by IANA 🧚

Default L2-Specific Sublayer bits - per [L2TPv3]
---------------------------------

Bit 2 - B (Fragmentation) bit
Bit 3 - E (Fragmentation) bit

7.3. Leading Bits of the L2TPv2 Message Header

this document requires definition of two reserved bits in the L2TPv2 [L2TPv2] header. Their locations are noted by the "B" and "E" bits in Section 5.6 🌈

Leading Bits of the L2TPv2 Message Header - per [L2TPv2, L2TPv3]
-----------------------------------------

Bit 8 - B (Fragmentation) bit
Bit 9 - E (Fragmentation) bit

8. Acknowledgements 🫢

the authors wish to thank Eric Rosen and Carlos Pignataro, both of Cisco Systems, for their review of this document πŸ’œ

9. Normative References ✨

Okay, these are the docs the spec needs you to have read, so no skipping! πŸ“š

  • [Control-Word] Bryant, S., Swallow, G., Martini, L., and D. McPherson, "Pseudowire Emulation Edge-to-Edge (PWE3) Control Word for Use over an MPLS PSN", RFC 4385, February 2006.
  • [IANA] Martini, L., "IANA Allocations for Pseudowire Edge to Edge Emulation (PWE3)", BCP 116, RFC 4446, April 2006.
  • [KEYWORDS] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997.
  • [LABELSTACK] Rosen, E., Tappan, D., Fedorkow, G., Rekhter, Y., Farinacci, D., Li, T., and A. Conta, "MPLS Label Stack Encoding", RFC 3032, January 2001.
  • [L2TPv2] Townsley, W., Valencia, A., Rubens, A., Pall, G., Zorn, G., and B. Palter, "Layer Two Tunneling Protocol "L2TP"", RFC 2661, August 1999.
  • [L2TPv3] Lau, J., Townsley, M., and I. Goyret, "Layer Two Tunneling Protocol - Version 3 (L2TPv3)", RFC 3931, March 2005.
  • [MLPPP] Sklower, K., Lloyd, B., McGregor, G., Carr, D., and T. Coradetti, "The PPP Multilink Protocol (MP)", RFC 1990, August 1996.
  • [MPLS-Control] Martini, L., Rosen, E., El-Aawar, N., Smith, T., and G. Heron, "Pseudowire Setup and Maintenance Using the Label Distribution Protocol (LDP)", RFC 4447, April 2006.
  • [PATHMTU] Mogul, J. and S. Deering, "Path MTU discovery", RFC 1191, November 1990.
  • [PATHMTUv6] McCann, J., Deering, S., and J. Mogul, "Path MTU Discovery for IP version 6", RFC 1981, August 1996.

10. Informative References πŸ’‘

These ones are the bonus reading, the "ooh, tell me more" list. 🧚

  • [Architecture] Bryant, S. and P. Pate, "Pseudo Wire Emulation Edge-to-Edge (PWE3) Architecture", RFC 3985, March 2005.
  • [BCP0068] Townsley, W., "Layer Two Tunneling Protocol (L2TP) Internet Assigned Numbers Authority (IANA) Considerations Update", BCP 68, RFC 3438, December 2002.
  • [FAST] ATM Forum, "Frame Based ATM over SONET/SDH Transport (FAST)", af-fbatm-0151.000, July 2000.
  • [FRF.12] Frame Relay Forum, "Frame Relay Fragmentation Implementation Agreement", FRF.12, December 1997.
  • [IPFRAG-SEC] Ziemba, G., Reed, D., and P. Traina, "Security Considerations for IP Fragment Filtering", RFC 1858, October 1995.
  • [RFC2434] Narten, T. and H. Alvestrand, "Guidelines for Writing an IANA Considerations Section in RFCs", BCP 26, RFC 2434, October 1998.
  • [RFC791] Postel, J., "Internet Protocol", STD 5, RFC 791, September 1981.
  • [TINYFRAG] Miller, I., "Protection Against a Variant of the Tiny Fragment Attack (RFC 1858)", RFC 3128, June 2001.

Appendix A. Relationship between This Document and RFC 1990 πŸŽ€

Okay, so fragmenting big packets into smaller chunks for sending is not a new idea, bestie. 🧩 RFC 1990, Multi-Link PPP [MLPPP], defined one method for it, and Frame Relay [FRF.12] and ATM [FAST] both borrowed that same method. This document also adopts the RFC 1990 fragmentation and reassembly procedures, with a few distinct tweaks that we go over in this appendix. Familiarity with RFC 1990 is assumed, so go read it if you haven't! πŸ’…

RFC 1990 was built for environments where fragments can show up out of order, because they got sent over several parallel links. It says buffering is used to put the fragments back in the right order. For PWE3, being able to reorder fragments before reassembly is OPTIONAL πŸ™ˆ, and receivers MAY choose to drop frames when a lost fragment is detected. So when the sequence number on received fragments shows that a fragment got skipped, the partially reassembled packet MAY be dropped, or the receiver MAY wish to wait for the missing fragment to arrive out of order. If it waits, a reassembly timer MUST be used, so it doesn't lock up buffer resources for too long. ⏱️

Dropping out-of-order fragments on a given PW can be a huge scalability win for network equipment doing reassembly. If out-of-order fragments are pretty rare on a PW, throughput shouldn't really take a hit from it. ✨ BUT, and this is a big but, if fragments of a given frame keep arriving out of order in the same way (say, a short fragment always zooms ahead of a bigger one), then dropping out-of-order fragments means that fragmented frame never gets received at all. That can turn into an effective denial of service for a higher-level application. 😭 So implementations fragmenting a PW frame MUST at the very least make sure all fragments are sent in order from their own egress point.

An implementation may also choose to allow reassembly of a limited number of fragmented frames on a given PW, or across a set of PWs that have reassembly enabled. This spreads the reassembly resources out more evenly, so one PW or a small set of them can't eat up every reassembly resource on a node. 🫢 Same as with dropping out-of-order fragments, there are cases where this can also end up being an effective denial of service. For example, if fragments from multiple frames keep arriving before any one frame can be rebuilt in a limited set of PW reassembly buffers, then none of those fragmented frames will ever get delivered. πŸ’€

RFC 1990 headers use two bits to mark the first and last fragments in a frame, plus a sequence number. The sequence number can be either 12 or 24 bits long (from [MLPPP]):

            0             7 8            15
           +-+-+-+-+-------+---------------+
           |B|E|0|0|    sequence number    |
           +-+-+-+-+-------+---------------+

           +-+-+-+-+-+-+-+-+---------------+
           |B|E|0|0|0|0|0|0|sequence number|
           +-+-+-+-+-+-+-+-+---------------+
           |      sequence number (L)      |
           +---------------+---------------+

           Figure 6: RFC 1990 Header Formats

PWE3 fragmentation takes advantage of the PW sequence numbers and control bit fields that already exist wherever it can, instead of defining a separate header just for fragmentation. 🌸 So it uses neither of the RFC 1990 sequence number formats above, and relies on the sequence number that's already in the PWE3 header instead.

RFC 1990 defines two one-bit fields: a (B)eginning fragment bit and an (E)nding fragment bit. The B bit is set to 1 on the first fragment derived from a PPP packet and set to 0 on all other fragments from that same PPP packet. The E bit is set to 1 on the last fragment and set to 0 on all the others. A complete, unfragmented frame has both the B and E bits set to 1. πŸ¦‹

PWE3 fragmentation flips the values of the B and E bits, but keeps the same idea of marking where a fragmented frame begins and ends. So for PW, the B bit is set to 0 on the first fragment derived from a PW frame and set to 1 on all other fragments from that same frame. The E bit is set to 0 on the last fragment and set to 1 on all the others. A complete, unfragmented frame has both the B and E bits set to 0. The reason for flipping them is so complete frames (especially implementations that only support complete frames) can just leave the B and E bits in the header set to 0. Clever, right? πŸ‘‘

To support fragmentation, the B and E bits MUST be defined or identified for all PWE3 tunneling protocols. Sections 4 and 5 define these locations for the PWE3 MPLS [Control-Word], L2TPv2 [L2TPv2], and L2TPv3 [L2TPv3] tunneling protocols. 🌈


Authors' Addresses πŸ–ŠοΈ

Andrew G. Malis Tellabs 1415 West Diehl Road Naperville, IL 60563

EMail: Andy.Malis@tellabs.com

W. Mark Townsley Cisco Systems 7025 Kit Creek Road PO Box 14987 Research Triangle Park, NC 27709

EMail: mark@townsley.net


Copyright (C) The Internet Society (2006).

This document is subject to the rights, licenses and restrictions contained in BCP 78, and except as set forth therein, the authors retain all their rights.

This document and the information contained herein are provided on an "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.


Intellectual Property πŸ”₯

The IETF takes no position on the validity or scope of any Intellectual Property Rights or other rights that might be claimed to apply to implementing or using the technology described in this document, or on whether any license under those rights might or might not be available. It also doesn't say it has made any independent effort to identify any such rights. Info on the procedures for rights in RFC documents can be found in BCP 78 and BCP 79.

Copies of IPR disclosures made to the IETF Secretariat, any assurances of licenses to be made available, or the results of an attempt to get a general license or permission for implementers or users of this specification to use those proprietary rights can be obtained from the IETF's online IPR repository at http://www.ietf.org/ipr.

The IETF invites any interested party to bring to its attention any copyrights, patents or patent applications, or other proprietary rights that may cover technology that may be required to implement this standard. Please send that info to the IETF at ietf-ipr@ietf.org. 🫢


Acknowledgement 🌷

Funding for the RFC Editor function is provided by the IETF Administrative Support Activity (IASA). πŸ’–

πŸ“¦ where this page comes from