MPLS Working Group J. Rajamanickam, Ed. Internet-Draft R. Gandhi, Ed. Intended status: Standards Track Cisco Systems, Inc. Expires: 9 May 2023 R. Zigler, Ed. Broadcom H. Song, Ed. Futurewei Technologies K. Kompella, Ed. Juniper Networks 5 November 2022 MPLS Network Action (MNA) Header Encodings draft-jags-mpls-mna-hdr-03 Abstract This document defines the MPLS Network Action (MNA) Header encoding formats to carry Network Actions and optionally Ancillary Data in the label stack and post label stack. The MPLS Network Action can be used for example, to influence the forwarding decisions or to carry additional OAM information in the MPLS packet. This document addresses the MNA requirements specified in draft-ietf-mpls-mna- requirements. This document follows the MNA framework specified in draft-ietf-mpls-mna-fwk. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on 9 May 2023. Copyright Notice Copyright (c) 2022 IETF Trust and the persons identified as the document authors. All rights reserved. Rajamanickam, et al. Expires 9 May 2023 [Page 1] Internet-Draft MPLS Network Action Encodings November 2022 This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/ license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License. Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 2. Conventions Used in This Document . . . . . . . . . . . . . . 3 2.1. Requirements Language . . . . . . . . . . . . . . . . . . 3 2.2. Abbreviations . . . . . . . . . . . . . . . . . . . . . . 3 3. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 5 4. Network Action Sub-Stack Header . . . . . . . . . . . . . . . 5 5. In-Stack MPLS Network Action Encoding . . . . . . . . . . . . 7 5.1. In-Stack MPLS Network Opcodes Allocation Procedure . . . 10 5.2. Reserved In-Stack MPLS Network Action Opcodes . . . . . . 11 5.2.1. NAI Opcode Value 1 (PSD Offset) . . . . . . . . . . . 11 5.2.2. NAI Opcode Value 2 (Flag-Based NAIs without AD) . . . 12 5.2.3. NAI Opcode Value 3 (Combination of multiple NAIs) . . 13 5.2.4. NAI-Opcode Value 4 (PSD-ISD Ordering) . . . . . . . . 14 5.2.5. NAI-Opcode Value 126 (No Operation) . . . . . . . . . 14 5.2.6. NAI-Opcode Value 127 (Extended Opcode) . . . . . . . 15 6. Post-Stack MPLS Network Action Encoding . . . . . . . . . . . 16 6.1. MNA carrying Only Post-Stack NAs . . . . . . . . . . . . 16 6.2. MNA carrying both In-Stack and Post-Stack NAs . . . . . . 16 6.3. MNA carrying In-Stack and Post-Stack NA with different scope . . . . . . . . . . . . . . . . . . . . . . . . . . 17 6.4. Post-Stack MPLS Network Opcodes Allocation Procedure . . 18 7. Network Action Processing Order . . . . . . . . . . . . . . . 18 7.1. In-Stack NA Processing Order . . . . . . . . . . . . . . 18 7.2. Post-Stack NA Processing Order . . . . . . . . . . . . . 19 7.3. Mix of In-Stack and Post-Stack NA Processing Order . . . 20 8. Multiple MNA Copies in Label Stack . . . . . . . . . . . . . 20 9. Node Capability Signaling . . . . . . . . . . . . . . . . . . 21 10. Security Considerations . . . . . . . . . . . . . . . . . . . 21 11. Backward Compatibility . . . . . . . . . . . . . . . . . . . 21 12. Processing In-Stack MPLS Network Actions . . . . . . . . . . 22 13. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 23 13.1. IANA Considerations for MNA NASS Encoding Parameters . . 23 13.2. IANA Considerations Flag-Based Network Actions . . . . . 24 13.3. IANA Considerations for IS-NAI-Opcode . . . . . . . . . 25 13.4. IANA Considerations for MNA bSPL Label . . . . . . . . . 26 14. Appendix . . . . . . . . . . . . . . . . . . . . . . . . . . 26 14.1. Network Action Encoding Examples . . . . . . . . . . . . 26 Rajamanickam, et al. Expires 9 May 2023 [Page 2] Internet-Draft MPLS Network Action Encodings November 2022 14.1.1. Example-1 - Flag-Based In-Stack NA without AD . . . 26 14.1.2. Example-2 - In-Stack NA with 13-bit AD . . . . . . . 27 14.1.3. Example-3 - In-Stack NA with more than 20-bit AD . . 28 15. References . . . . . . . . . . . . . . . . . . . . . . . . . 28 15.1. Normative References . . . . . . . . . . . . . . . . . . 29 15.2. Informative References . . . . . . . . . . . . . . . . . 29 Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . . 30 Contributors . . . . . . . . . . . . . . . . . . . . . . . . . . 30 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 32 1. Introduction [RFC3032] defines MPLS Header for carrying a stack of MPLS labels which are used to forward packets in an MPLS network. Today's new applications require the MPLS packets to carry network action indicators and optional Ancillary Data (AD) that can be used for example, in MPLS packet forwarding decision or for OAM purpose. Ancillary Data can be used to carry additional information, for example, a network slice identifier, In-Situ OAM (IOAM) data, etc. Several MNA applications are described in [I-D.ietf-mpls-mna-usecases]. This document defines a solution to encode MPLS Network Actions (MNA) in an MPLS Label Stack those are efficient to process in hardware. The MPLS Network Actions are encoded in the form of flags and opcodes. These MPLS Network Actions can be encoded without Ancillary Data (AD) or with In-Stack Ancillary Data (ISD) or with Post-Stack Ancillary Data (PSD) (i.e., after the Bottom of the Stack (BOS)). A new base Special Purpose Label (bSPL) (value TBA) is to be assigned to indicate the presence of MPLS Network Action Sub-Stack (MNAS) in the MPLS packet. This document addresses the MNA requirements specified in [I-D.ietf-mpls-mna-requirements]. This document follows the MNA framework specified in [I-D.ietf-mpls-mna-fwk]. 2. Conventions Used in This Document 2.1. Requirements Language 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 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here. 2.2. Abbreviations The MNA terminology defined in [I-D.ietf-mpls-mna-fwk] and [I-D.ietf-mpls-mna-requirements] are used in this document. Rajamanickam, et al. Expires 9 May 2023 [Page 3] Internet-Draft MPLS Network Action Encodings November 2022 * AD: Ancillary Data. * BOS: Bottom Of Stack. * IHS: I2E, HBH, Select Scope. * I2E: Ingress-To-Egress. * HBH: Hop-By-Hop Scope. * ISD: In-Stack Data. * IS-NA: In-Stack Network Action. * IS-NAI-Opcode: In-Stack Network Action Opcode. * LSE: 32-bit Label Stack Entry. * MMSID: Maximum MPLS Stack Inspection Depth. * MPLS: Multiprotocol Label Switching. * MNA: MPLS Network Action. * NAI: Network Action Indicator. * NAI-OP: Network Action Indicator Opcode. * NAL: Length of Network Action in number of LSEs, excluding the LSE for Opcode. * NASL: Length of Network Action sub-stack in number of LSEs (after the MNA Label and the second LSE). * NASI: Network Action Sub-Stack Indicator. * NASS: Network Action Sub-Stack. * UOH: Unknown Opcode Handling. * PS-NA: Post-Stack Network Action. * P: Post-Stack Network Action Presence Indicator. * PSD: Post-Stack Data. * bSPL: Base Special Purpose Label in the range of 0-15. Rajamanickam, et al. Expires 9 May 2023 [Page 4] Internet-Draft MPLS Network Action Encodings November 2022 * TC: Traffic Class. * TTL: Time To Live. 3. Overview 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Flag-Based NAIs or AD |P|IHS|S| NASL |R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |S|4bit AD|UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 1: Network Action Sub-Stack Header MPLS Network Action (MNA) Header Encoding contains two main parts: 1. Network Action Sub-Stack Header: a. MNA Label to indicate the presence of Network Action Sub-Stack (NASS). b. NASS Encoding parameters indicating the NASS scope, length, ordering, etc. parameters of the NASS. 2. In-Stack Network Action Encoding: In-Stack Network Action is encoded in the TLV format as following: a. Type - Network Action Indicator Opcode b. Length - Network Action Length (NAL) c. Value - Ancillary Data (Optional) The detailed description of the MNA encoding solution is described below sections. 4. Network Action Sub-Stack Header Network Action Sub-Stack Header contains MNA Label and NASS encoding parameters as described below. MNA Label: Rajamanickam, et al. Expires 9 May 2023 [Page 5] Internet-Draft MPLS Network Action Encodings November 2022 A new bSPL value (value TBA) is assigned to indicate the presence of the MPLS Network Action Sub-Stack (NASS). Note: The TC and TTL fields of the new bSPL are not re-purposed for NASS encoding parameters, as the penultimate node on the MPLS packet path may propagate TTL and TC fields from the transport (or forwarding) LSE to the next LSE on the label stack, overwriting the TTL and TC fields of the next LSE, as specified in Section 3.5 of [RFC3443]. When the penultimate node is not aware of the MNA bSPL (value TBA) e.g., in case of non-MNA capable network, this can cause NASS parameters in the TTL of the MNA label to be corrupted. NASS Encoding Parameters: The TTL and TC field of the second LSE is used to encode NASS encoding parameters. The NASS encoding parameters contain the following. * P-Bit (Post-Stack Network Action Presence Bit) - This bit indicates the presence of Post-Stack Network Actions. * IHS (I2E, HBH and Select Scope): This 2-bit value indicates the scope of the In-Stack and Post-Stack NAIs encoded in that specific NASS. +======+==========+ | Bits | Scope | +======+==========+ | 00 | I2E | +------+----------+ | 01 | HBH | +------+----------+ | 10 | Select | +------+----------+ | 11 | Reserved | +------+----------+ Table 1: In-Stack and Post-Stack NAI Scope Table This indicates the scope (HBH / Select / I2E) of NASS for different nodes (e.g., midpoint nodes and egress node) where it needs to be processed. HBH (Hop-By-Hop) - This scope indicates that the NASS should be processed by the midpoint nodes as well. Rajamanickam, et al. Expires 9 May 2023 [Page 6] Internet-Draft MPLS Network Action Encodings November 2022 Select - This scope indicates that the NASS should be processed only on selected set of nodes. I2E (Ingress To Egress) - This scope indicates that the NASS Should be processed by the Egress node. Separate NASS Per Scope: Single NASS carries only one of the three scopes (HBH/SEL/I2E). MNA packet could carry more than one NASS scope, in those cases each scope is encoded as part of a single NASS. While encoding multiple NASS with the different scope, the I2E scope MUST be encoded after the HBH/SEL scope. This will make sure that the I2E scoped NASS is added closer to the BOS whereas HBH/SEL scoped NASS are added closer to the top of the label stack. This makes it easier for the midpoint nodes to process only the NASS with HBH scope in hardware. * NASL (Network Action Sub-Stack Length): This is a 4-bit value in the TTL field. This indicates the total length number of additional LSEs (not including the MNA Label and the second LSE) used to encoding the In-Stack NAIs for that specific NASS. This value is used by the node to pop the NASS or skip the processing NASS from the label stack. * R-Bits: R bits in the TTL field is Reserved for future use. * O-Bit (Ordering Bit): When O-Bit is set then it indicates that the NAIs MUST be processed in the order that is encoded in the NASS. If the Node is not capable of Processing the NAIs in the order then that specific packet MUST be dropped. Processing the NAIs in order is a complex process, some of the ASICs May not be capable of processing the NAIs in order, so this option gives the flexibility for the nodes to drop these packet, just by inspecting the O-Bit. The second LSEs First 20-Bit field could be used to encode In-Stack NA that requires maximum of 13 bits of Ancillary data. 5. In-Stack MPLS Network Action Encoding Rajamanickam, et al. Expires 9 May 2023 [Page 7] Internet-Draft MPLS Network Action Encodings November 2022 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Label | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ ~ ~ ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL |R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |S|4bit AD|UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 2: MPLS Label Stack Entry (LSE) Format The In-Stack MPLS Network Action are encoded in the TLV format. a. Type - Network Action Indicator Opcode: This is the 7-Bit value used for indicating the Network Actions. This is also called as NAI-Opcode. b. Length - Network Action Length (NAL): This is the 2-Bit valued used of indicating additional number of LSEs used to encode additional Ancillary Data. c. Value - Ancillary Data (Optional): This is the optional Data that will be used while processing the NAIs. The encoding format defined is flexible (e.g., stackable opcodes in desired order), extensible (by defining new NAI-Opcodes) and ASIC friendly (by using Sub-Stack Length, Opcode and Data in the same LSE). This encoding format also allows to carry the Flag-Based NAIs that do not require AD and the Flag-Based NAIs that require AD in the same packet. The opcode method of identifying a specific Network Actions are common in today's hardware ASICs (Similar to any IPv4/IPv6/VxLAN header processing), so this method is easy to be adopted by the existing hardware. This will allow the hardware ASICs to serially or in-parallel process the Network Actions. The Base In-Stack Network Action Encoding formats are described in detail below: NAI-Opcode: Rajamanickam, et al. Expires 9 May 2023 [Page 8] Internet-Draft MPLS Network Action Encodings November 2022 This is the first 7-Bit value in the Label Field. This indicates the Network Action that needs to be executed. The Opcode value ranges from 1 to 127. Ancillary Data: This is the additional Ancillary Data carried to process the Network Action specified by the NAI-Opcode. * The 16 bits of the Label field is used to carry the Ancillary Data * Apart from the Label field, part of AD is also carried in the 4-Bit TTL field. * Some applications need to change the Ancillary Data for the same flow, in those cases the data is encoded in the the TTL field of the LSE. UOH (Unknown Opcode Handling): * This is a 2-Bit value that defines the action that needs to be taken by a node that does not understands this corresponding opcode value. In a brown field there are possibilities that some of the midpoint nodes may not understand a specific NA opcode, this 2-Bit value will indicate the actions that needs to taken. This action could be different for different NA opcodes. When the Network Action is defined by the application, the application MUST specify the "Unknown Opcode Handling". The different type of Unknown Opcode Handling Actions are defined below. +======+============================================+ | Bits | Actions | +======+============================================+ | 00 | Skip and Process Next NA | +------+--------------------------------------------+ | 01 | Drop the packet | +------+--------------------------------------------+ | 10 | Stop processing MNA and forward the packet | +------+--------------------------------------------+ | 11 | Reserved | +------+--------------------------------------------+ Table 2: Unknown Opcode Handling Table NOTE: ECMP Hash Using Label Stack: Rajamanickam, et al. Expires 9 May 2023 [Page 9] Internet-Draft MPLS Network Action Encodings November 2022 If the intermediate node changes any label field value for the same flow then it may affect the ECMP Flow. So the intermediate node MUST node change the Label field value for the same flow. 5.1. In-Stack MPLS Network Opcodes Allocation Procedure This section discusses about the procedures and requirement for an applications allocating a new In-Stack MPLS Network Opcode. The application May request for a new Network Action Indicator with AD or without AD. More information about the NAI without AD is described in the next section. The Network Action Opcode ranges from 0 till 127. There us an IANA registry maintained for allocating the In-Stack MPLS Network Action Opcodes. Opcode "0" is considered as an invalid opcode and a Packet received with the Opcode "0" MUST be dropped. Some of the opcodes are reserved for building the basic framework for MNA. Those reserved Network Action Opcodes are defined in the next section (This is described as part of the Reserved opcode). When an application requires a new MPLS Network Action Opcode, then it MUST provide the following information: NA Opcode Value: The application MUST request for an Opcode value. Based on the request, IANA will allocate a new Opcode value for the application. If the application requested for an opcode without Ancillary data then an offset Bit-Flag position will be allocated by IANA (This is described as part of the Reserved opcode). NA Scope: The application MUST specify at-least one scope (I2E, HBH, Select) for the Network Action. Depending on the applications requirement, they MAY specify more than one scopes for the same Network Action. Unknown Opcode Handling: Rajamanickam, et al. Expires 9 May 2023 [Page 10] Internet-Draft MPLS Network Action Encodings November 2022 This is the behaviour, that a node should follow when it does not understand this specific NA opcode (Check the "Unknown Opcode Handling Table" for different options). This is an optional information that May be provided by the application. By default "Skip and process Next NA". Presence of Ancillary Data: The application MUST specify whether it requires Ancillary Data to process the Network Action. Incase the application does not need any AD, then it would use "Opcode-2" and the Flag-Based NAI offset will be assign by the IANA (This is described as part of the Reserved opcode). Ancillary Data Length: If the applications Network Action requires AD, then it MUST specify the maximum length of the AD. The Maximum length MUST NOT exceed 110 bits. If it is exceeding 110 bits, then those Network Actions MUST be encoded as part of Post-Stack Network Actions. Ancillary Data Format: The application MUST specify the format in which they encode their Ancillary data in detail. All the possible options should be provided. Network Action Processing Procedure: The application MUST specify the detailed procedure for processing their respective Network Action. The known dependencies MUST be clearly listed out in their processing procedures. 5.2. Reserved In-Stack MPLS Network Action Opcodes Some of the opcodes are reserved as described below for the basic functionality and the rest of the opcodes are assigned by IANA. 5.2.1. NAI Opcode Value 1 (PSD Offset) Some of the opcodes are reserved as described below for the basic functionality and the rest of the opcodes are assigned by IANA. Rajamanickam, et al. Expires 9 May 2023 [Page 11] Internet-Draft MPLS Network Action Encodings November 2022 * IS-NAI-Opcode Value:1 (PSD Offset) - Opcode reserved to indicate the start offset of the Post-Stack Network Actions header after the MPLS BOS in octets. This allows to carry Generic Control Word (0000b) [RFC4385] and G-ACh (0001b) [RFC5586] fields immediately after the BOS. In the absence of this opcode, the node should understand that the PSD is encoded right after the MPLS BOS. "PSD Offset" value is encoded in next 13 bits. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=1| PSD Offset |1|IHS|S| NASL |R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 3: In-Stack PSD offset Encoding Format NA Opcode Value: 1 NA Scope: Depending on the NASS scope. This could be any one of the three scopes (I2E, HBH and SEL) Unknown Opcode Handling: MUST drop (Value = 1) Ancillary Data Length: 13 bits Ancillary Data Format: The 13-bit value provides the offset to the start of the Post-Stack from the MPLS BOS in octets. 5.2.2. NAI Opcode Value 2 (Flag-Based NAIs without AD) This opcode is reserved to carry the Flag-Based NAIs those do not require Ancillary Data. These NAI flag bits are carried in the Ancillary Data field of the Opcode. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL |R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAIs |UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 4: In-Stack Flags-Based NA Encoding Format NA Opcode Value: 2 Rajamanickam, et al. Expires 9 May 2023 [Page 12] Internet-Draft MPLS Network Action Encodings November 2022 NA Scope: Scope depends on the scope of the Flag-Based NAI. This could be any one of the three scopes (I2E, HBH and SEL) Unknown Opcode Handling: Depends on the Flag-Bases NAIs that are encoded. If one of the encoded NAIs handling is Drop (Value: 1), then this packet MUST be Dropped. Ancillary Data Length: Max 110 bits. To extend this range, a new opcode could be allocated from IANA registry in the future. Ancillary Data Format: Each bit position represents a single Flag- Based NAI, that does not require AD. The bit positions are read from left to right. These bit positions will be allocated and maintained by IANA. 5.2.3. NAI Opcode Value 3 (Combination of multiple NAIs) This Opcode reserved to support a combination of multiple IS-Stack NAI with the Ancillary data. The combination of NAIs in this case, are represented as the offset bits in the first 20 bits, the Flag bit position for a specific application will be allocated and maintained by IANA. The next 3 LSE's are used to encode the AD for the specific Flag bits in the first 20 bits. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=2|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=3| Flag-Based NAIs |S| NAIs |UOH| 1 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |1| Ancillary Data |S|Ancillary Data | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 5: In-Stack Flag-Based NAs with Ancillary Data NA Opcode Value: 3 NA Scope: Scope depends on the Flag-Based NAI's scope. This could be any one of the three scopes (I2E, HBH and SEL) Unknown Opcode Handling: Depends on the Flag-Bases NAIs that are encoded. If one of the encoded NAIs handling is Drop (Value: 1), then this MUST to Drop. Ancillary Data Length: Max 110 bits Rajamanickam, et al. Expires 9 May 2023 [Page 13] Internet-Draft MPLS Network Action Encodings November 2022 Ancillary Data Format: Each bit position represents a single Flag- Based NAI, that does not require AD. The bit positions are read from left to right. These bit positions will be allocated and maintained by IANA. 5.2.4. NAI-Opcode Value 4 (PSD-ISD Ordering) This Opcode is reserved to indicate the specific order of execution between Post-Stack and In-Stack NAIs. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |1|IHS|S| NASL=2|R|R|R|1| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=4| Post-Stack-NAI |S|PS-NAI |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S|4bit AD|UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 6: In-Stack PSD Opcode Indicator Encoding Format NA Opcode Value: 4 NA Scope: Scope depends on the Scope of NASS that requires ordering. This could be any one of the three scopes (I2E, HBH and SEL) Unknown Opcode Handling: MUST drop (Value = 1) Ancillary Data Length: Max 20 bits Ancillary Data Format: When this opcode is present in the NASS then the "O-Bit" in the NASS parameters MUST be set. If not the packet MUST be dropped. Ancillary Data is encoded with the Post-Stack NAIs (8-Bit value) that is required to be processed before processing the next In-Stack NAs encoded. This opcode could hold maximum of two Post-Stack NAIs that could be executed serially. 5.2.5. NAI-Opcode Value 126 (No Operation) This opcode is reserved to fill-in unused 20 bits of 2nd LSE. Rajamanickam, et al. Expires 9 May 2023 [Page 14] Internet-Draft MPLS Network Action Encodings November 2022 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-OP=126 | 0x0 |P|IHS|S| NASL=0|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 7: In-Stack No-Operation Opcode Encoding Format NA Opcode Value: 126 NA Scope: Follows the scope of NASS Unknown Opcode Handling: MUST Skip and Proceed (Value = 0) Ancillary Data Length: Max 13 bits Ancillary Data Format: This could be any value as this opcode is a No-Operation Opcode. This value will be ignored. 5.2.6. NAI-Opcode Value 127 (Extended Opcode) This opcode is reserved to extend the current opcode range beyond 127. The Extended 7-bit opcode value will be encoded next to the base opcode value 127. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=1|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Op=127 |Ext-NAI-Op=9 |Ancillary Data |S|4bit AD|UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 8: In-Stack Extended Opcode Encoding Format NA Opcode Value: 127 NA Scope: Scope depends on the Extended NAI opcode. This could be any one of the three scopes (I2E, HBH and SEL) Unknown Opcode Handling: Depends on the Extended NAI opcode handling Ancillary Data Length: Depends on the Length supported by the extended opcode. The Maximum length of this opcode is 103 bits Rajamanickam, et al. Expires 9 May 2023 [Page 15] Internet-Draft MPLS Network Action Encodings November 2022 Ancillary Data Format: In the above example, the extended Opcode "9" is encoded in the packet. In this case only 13 bits of AD could be encoded in the same LSE, if the application requires to encode more than 13 bits then it had to use next LSE to encode the rest of the AD 6. Post-Stack MPLS Network Action Encoding The details of the Post-Stack Network Action Extension Header encodings are specified in [I-D.song-mpls-extension-header]. 6.1. MNA carrying Only Post-Stack NAs 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Label | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-OP=126 | 0 |1|IHS|1| NASL=0|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ Post-Stack Network Actions Encoding ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ ~ ~ Data ~ ~ ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 9: MNA Encoding only Post-Stack NAs In some cases the MNA header may encode only the Post-Stack NAs. In this case, the P-Bit is set to indicate the presence of Post-Stack NAs. The IHS field indicates the scope of the Post-Stack NAs (I2E, HBH, SEL). 6.2. MNA carrying both In-Stack and Post-Stack NAs Rajamanickam, et al. Expires 9 May 2023 [Page 16] Internet-Draft MPLS Network Action Encodings November 2022 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Label | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-OP=126 | 0 |1|IHS|S| NASL=1|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |1| NAIs |UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ Post-Stack Network Actions Encoding ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ ~ ~ Data ~ ~ ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 10: MNA Encoding In-Stack and Post-Stack NAs In some cases the MNA header may encode both In-Stack and Post-Stack NAs. In this case, P-Bit is set to indicate the presence of Post- Stack NAs. The NASL is set to "1", indicates the presence of an In- Stack NA LSE. The IHS field indicates the scope of both the In-Stack Post-Stack NAs (I2E, HBH, SEL). 6.3. MNA carrying In-Stack and Post-Stack NA with different scope Rajamanickam, et al. Expires 9 May 2023 [Page 17] Internet-Draft MPLS Network Action Encodings November 2022 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Label | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-OP=126 | 0 |0| 1 |S| NASL=1|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAIs |UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-OP=126 | 0 |1| 0 |1| NASL=0|R|R|R|O| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ Post-Stack Network Actions Encoding ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ ~ ~ ~ Data ~ ~ ~ +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 11: MNA Encoding In-Stack and Post-Stack NAs with diff scope In some cases the MNA may carry In-Stack NAs with Hop-By-Hop scope and Post-Stack NAs with I2E scope. In this case, there will be two NASS will be encoded. In this case, the First NASS will encode the In-Stack NA with the Hop-By-Hop scope and the second NASS will encode the presence of I2E scoped Post-Stack NAs. 6.4. Post-Stack MPLS Network Opcodes Allocation Procedure The Post-Stack MPLS Network Action opcode specific informations are provided in the draft [I-D.song-mpls-extension-header]. 7. Network Action Processing Order Depending on the application, each NA will be processed at different stages of the ASICs pipeline. But in some cases, there may be contention between processing two NAs at the same stage of ASICs, in those cases the processing order should be maintained, so that the result of the packet forwarding and OAM data collection will be predictable. 7.1. In-Stack NA Processing Order This section talks about maintaining the ordering between the In- Stack NA processing. Rajamanickam, et al. Expires 9 May 2023 [Page 18] Internet-Draft MPLS Network Action Encodings November 2022 The order of processing the NA should follow the order of NAs encoded in the NASS. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=2|R|R|R|1| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=7| Ancillary Data7 |S| AD7 |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAI |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 12: Example In-Stack NA Processing Order In the above example, a node will process the Flags-Based-NAIs first and then the NAI-Opcode "7". In some cases, some Flag-Based NAIs may need to be processed before the NAI-Opcode "7" and some Flag-Based NAIs may need to be process after the NAI-Opcode "7". 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=3|R|R|R|1| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| 0x01 |S| NAI |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=7| Ancillary Data7 |S| AD7 |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| 0x02 |S| NAI |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 13: Example In-Stack NA Processing Order In the above example, the Flag-Based NAI "0x1" is processed before the NAI-Opcode "7" and the Flags-Based NAI "0x2" is processed after the NAI-Opcode "7". 7.2. Post-Stack NA Processing Order Post-Stack NAs follow ordering specified in [I-D.song-mpls-extension-header]. Rajamanickam, et al. Expires 9 May 2023 [Page 19] Internet-Draft MPLS Network Action Encodings November 2022 7.3. Mix of In-Stack and Post-Stack NA Processing Order In some cases, Post-Stack NA needs to be processed before In-Stack NA. This section describes how to prioritize the Post-Stack NAs over the In-Stack NAs. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=3|R|R|R|1| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAIs |UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=4| Post-Stack-NAI6 |S|PS-NAI |UOH|NAL| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=7| Ancillary Data7 |S| AD7 |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 14: Example Post-Stack and In-Stack NA Processing Order In the above example, the Flag-Based NAIs required to be processed first, followed by the Post-Stack NA "6" and then In-Stack NAI-Opcode "7". The NAI-Opcode "4" is a reserved opcode which can be used for ordering between the In-Stack and Post-Stack. In this example, the AD field of the NAI-Opcode "4" carries the Post-Stack NA that is processed before processing the NAI-Opcode "7". 8. Multiple MNA Copies in Label Stack When adding a large size MPLS label stack, a copy of NASS with HBH and Select scope may be placed at regular stack depth throughout the MPLS label stack, with the understanding that the current copy of the NASS will eventually rise to the top of the label stack. For HBH scope, every node processes the current copy of the NASS and the node that pops the forwarding label that exposes the NASS will also remove the NASS after processing the NASS assuming it supports the MNA label, and it will not forward the NASS at the top to the next node. For HBH scope, the node that receives the NASS at the top of the label stack MUST remove the NASS, assuming that it supports the MNA label. For I2E scope, only one copy of NASS needs to be added and it is added just before the bottom of the stack. Rajamanickam, et al. Expires 9 May 2023 [Page 20] Internet-Draft MPLS Network Action Encodings November 2022 9. Node Capability Signaling The headend Node which is encapsulating the MNA header MUST make sure that the egress Nodes removes the MNA header. The headend Node May make sure that the MNA encoded in the packet could be able to process my midpoint and egress nodes. The following are the Node capabilities that are required for the headend Node to decide the encoding patten: * Each participating Node MUST signal their capabilities of NASS processing like ordering, maximum NASL, etc. * Each Participating Node MUST signal their capabilities of supporting each In-Stack and Post-Stack NAs and its parameters. * Each Participating Node MUST signal their Maximum MPLS Stack Inspection Depth (MMSID). This will indicate the headend node to encode the MNA at a specific stack depth. The above capability signaling will be added in LDP, RSVP-TE, BGP, IS-IS, OSPF, BGP-LS, etc. This is outside the scope of this document. 10. Security Considerations The security considerations in [RFC3032] also apply to the procedures defined in this document. The following are the security considerations that May inherit from this MNA architecture * If the untrusted source encode the MNA's NASL/NAL with incorrect length, then this may affect the MNA processing and the packet could be router in an illegitimate manner. 11. Backward Compatibility * For the non-MNA capable node that does not advertise the MPLS Network Action capability, the Encapsulating node MUST make sure that the MPLS Network Action Sub-Stack indicator is not at the top of the MPLS Label Stack to avoid dropping the packets. Based on the signalling, if the MPLS egress node is not capable of the processing MPLS Network Actions then it should not add MNA in the packet. In the worst case, if the non-MNA capable nodes that does not understand the new bSPL allocated then those routers will drop the packets. Rajamanickam, et al. Expires 9 May 2023 [Page 21] Internet-Draft MPLS Network Action Encodings November 2022 * The MPLS Network Action Encoding format is designed to make sure that it does not alias with any Special Purpose Label. * The MPLS Network Actions can co-exist with the existing GAL / G-ACh based encoding of data. * The TC and TTL fields of the MNA bSPL are not re-purposed for encoding, as the penultimate node on the MPLS packet path may propagate TTL from the transport (or forwarding) label to the next label on the label stack, overwriting the TTL on the next label. When the penultimate node is not aware of the MNA bSPL (value TBA), this can cause encoding format flags in the TTL of the NASI (label TBA) label to be corrupted. 12. Processing In-Stack MPLS Network Actions Encapsulating Node: * MUST NOT add In-Stack MPLS Network Action Sub-Stack if the decapsulation node is not capable of In-Stack MPLS Network Action. * SHOULD NOT change the IS-NAI-Opcode and the first 12 bits of the In-Stack Ancillary Data for the same packet flow to avoid ECMP path change. * MAY change In-Stack Ancillary Data part present only in the TTL field for the same packet flow. * MUST ensure that the penultimate node does not remove the NASS. Transit Node: * MUST ignore the IS-NAI-Opcode that are not supported. * MUST NOT add In-Stack NASS if the decapsulation node is not capable of In-Stack MPLS Network Actions. * SHOULD NOT change the IS-NAI-Opcode and the first 12 bits of the In-Stack Ancillary Data for the same packet flow. * MAY change In-Stack Ancillary Data part present only in the TTL field for the same packet flow. * MAY remove the IS-NAI-Opcode and its Ancillary Data for all matching packet flow. Penultimate Node: Rajamanickam, et al. Expires 9 May 2023 [Page 22] Internet-Draft MPLS Network Action Encodings November 2022 * MUST remove the NASS when it is exposed after removing the forwarding (transport) label. Decapsulating Node: * MUST remove the MPLS Network Action Sub-Stack. 13. IANA Considerations Below are the IANA actions which this document is requesting. The registries created by this document will be collected in a new registry grouping called "MPLS Network Action," which will be located at https://www.iana.org/assignments/mpls-network-action. 13.1. IANA Considerations for MNA NASS Encoding Parameters IANA is requested to create a new registry with name "MNA NASS Encoding Parameters" to assign the bit position and the meaning to the Parameters that re-purpose TTL and TC fields in the Label Stack Entry (LSE). +==============+=============+===============+ | Bit Position | Description | Reference | +==============+=============+===============+ | 20-31 | IETF Review | This document | +--------------+-------------+---------------+ Table 3: MNA NASS Encoding Parameters Registry Following NASS Encoding Parameter values are assigned from this registry. Rajamanickam, et al. Expires 9 May 2023 [Page 23] Internet-Draft MPLS Network Action Encodings November 2022 +=======+==============================================+===========+ | Value | Description | Reference | +=======+==============================================+===========+ | 20 | Post-Stack Network Action Presence Indicator | This | | | | document | +-------+----------------------------------------------+-----------+ | 21-22 | In-Stack Scope value E2H/HBH/SEL(IHS) | This | | | | document | +-------+----------------------------------------------+-----------+ | 23 | End of Stack (S) | RFC 3032 | +-------+----------------------------------------------+-----------+ | 24-27 | In-Stack Network Action Sub-Stack Length | This | | | (NASL) | document | +-------+----------------------------------------------+-----------+ | 28-30 | Reserved Bit - May be used in future | This | | | | document | +-------+----------------------------------------------+-----------+ | 31 | O-Bit - MUST process NAs in the Order of | This | | | encoding, Else drop the packet | document | +-------+----------------------------------------------+-----------+ Table 4: MNA NASS Encoding Parameter Values 13.2. IANA Considerations Flag-Based Network Actions IANA is requested to create a new registry with name "In-Stack MPLS Network Action Indicator Flags" to assign a bit position and the meaning to the Flag-Based Network Action upon the application request. Based on the need this registry can be extended beyond 20 bit positions (MAX: 110 bits) using additional LSEs. The bit positions are read and processed from Left to Right. All code-points in the range 0 through 109 in this registry shall be allocated according to the "IETF Review" procedure as specified in [RFC8126]. +==============+=============+===============+ | Bit Position | Description | Reference | +==============+=============+===============+ | 0-109 | Unassigned | This document | +--------------+-------------+---------------+ Table 5: In-Stack MPLS Network Action Indicator Flags Registry Rajamanickam, et al. Expires 9 May 2023 [Page 24] Internet-Draft MPLS Network Action Encodings November 2022 13.3. IANA Considerations for IS-NAI-Opcode IANA is requested to create a new registry with name "In-Stack MPLS Network Action Indicator Opcodes" to assign IS-NAI-Opcode values and the meaning to the Network Action upon the application request. All code-points in the range 1 through 110 in this registry shall be allocated according to the "IETF Review" procedure as specified in [RFC8126]. Code points in the range 111 through 125 in this registry shall be allocated according to the "First Come First Served" procedure as specified in [RFC8126]. Remaining code-points are allocated according to Table 6: +===========+==================+===============+ | Value | Description | Reference | +===========+==================+===============+ | 0 - 110 | IETF Review | This document | +-----------+------------------+---------------+ | 111 - 125 | Experimental Use | This document | +-----------+------------------+---------------+ Table 6: In-Stack MPLS Network Action Indicator Opcodes Registry Following IS-NAI-Opcode Indicator values are assigned from this registry. +=======+========================================+===============+ | Value | Description | Reference | +=======+========================================+===============+ | 0 | Invalid opcode, Packet MUST be dropped | This document | +-------+----------------------------------------+---------------+ | 1 | Offset of start of Post-Stack Network | This document | | | Action Header | | +-------+----------------------------------------+---------------+ | 2 | Flag-Based Network Action Indicators | This document | | | with No AD | | +-------+----------------------------------------+---------------+ | 3 | Flag-Based Network Action Indicators | This document | | | with AD | | +-------+----------------------------------------+---------------+ | 4 | Post-Stack Network Action Indicator | This document | +-------+----------------------------------------+---------------+ | 126 | No Operation | This document | +-------+----------------------------------------+---------------+ | 127 | Opcode Range Extension Beyond 255 | This document | +-------+----------------------------------------+---------------+ Table 7: In-Stack Network Action Indicator Opcode Values Rajamanickam, et al. Expires 9 May 2023 [Page 25] Internet-Draft MPLS Network Action Encodings November 2022 13.4. IANA Considerations for MNA bSPL Label IANA is requested to allocate a value TBA for the MNA bSPL label from the "Base Special-Purpose MPLS Label Values" registry to indicate the presence of MNA Sub-Stack in MPLS header. 14. Appendix 14.1. Network Action Encoding Examples 14.1.1. Example-1 - Flag-Based In-Stack NA without AD 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=1|R|R|R|0| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAIs |UOH| 0 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 15: Example NASS with In-Stack Network Action Encoding Carrying Flag- Based NA This is the example of MNA carrying Flag-Based NAIs that does not require Ancillary Data. Third LSE: NAI-Opcode=2: This is 7 bits reserved opcode to carry Flag-Based NAIs with out any AD. Flag-Based NAIs: This is the Flag-Based NAIs. S: This is the LSEs stack-bit. NAIs: Continuation of Flags-Based NAIs. UOH: Action that is required to take by a node if one of the NAIs are not recognized by the processing node. NAL: The last two bits NAL field is set to "0", as there are no additional LSE is used to encode. Rajamanickam, et al. Expires 9 May 2023 [Page 26] Internet-Draft MPLS Network Action Encodings November 2022 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode | Ancillary Data |P|IHS|S| NASL=2|R|R|R|0| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=2| Flag-Based NAIs |S| NAIs |UOH| 1 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |1| Additional Flag-Based NAIs |S|Flag-Based-NAIs| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 16: Example NASS carrying Flag-Based NA with more than 20 Flags In this example, let us assume that an application-C has been allocated a Flag position of "21" by IANA, If the application-C needs to execute its Network Action on the MPLS packet then the MSB 2nd bit in the fourth LSE field will be set to indicate the Flags position "21". NAL is set to "1" and indicates the Flag-Based NAIs are also encoded in the next LSE. NASL is set to "2" and indicates the additional 2 In-Stack LSE are encoded. While encoding the Additional Ancillary Data in the 4th LSEs Most Significant bit MUST be set to "1" to prevent from aliasing with the reserved bSPLs. 14.1.2. Example-2 - In-Stack NA with 13-bit AD 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=8| Ancillary Data |P|IHS|S| NASL=0|R|R|R|0| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 17: Example NASS carrying In-Stack Network Action that requires Ancillary Data In this example, the NASS is carrying only the In-Stack Network Action that requires 13-bit Ancillary Data. The Opcode that are encoded MUST be optional and the processing node could skip this opcode if it does not understand. Second LSE: Rajamanickam, et al. Expires 9 May 2023 [Page 27] Internet-Draft MPLS Network Action Encodings November 2022 NAI-Opcode=8: In-Stack Network Action opcode "8". Ancillary Data: 13 bit ancillary data that is required to process the opcode 8. 14.1.3. Example-3 - In-Stack NA with more than 20-bit AD An In-Stack Network Action may require more than 20 bits of Ancillary Data. In this example, the following Ancillary Data encoding is used. 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | MNA-Label=bSPL (TBA) | TC |S| TTL | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=1| 0 |P|IHS|S| NASL=2|R|R|R|0| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | NAI-Opcode=9| Ancillary Data9 |S| AD9 |UOH| 1 | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ |1| Ancillary Data9 |S|Ancillary Data9| +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Figure 18: Example In-Stack Network Action With Additional Ancillary Data Encoding Format In this example, the In-Stack NAI-Opcode "9" requires more than 20 bits of Ancillary Data to be encoded. The NA and AD are encoded in the 3rd and 4th LSEs. Third LSE: NAI-Opcode=9: In-Stack Network Action opcode "9". Ancillary Data9: 16 bits of Ancillary Data encoded to process opcode "9" AD9: 4 bits of additional Ancillary Data. Fourth LSE: 0th Bit: This bit is set to "1" to prevent aliasing with the bSPLs. Ancillary Data9: 22 bits of additional Ancillary data. Ancillary Data9: 8 bits of additional Ancillary Data. 15. References Rajamanickam, et al. Expires 9 May 2023 [Page 28] Internet-Draft MPLS Network Action Encodings November 2022 15.1. Normative References [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, . [RFC3032] Rosen, E., Tappan, D., Fedorkow, G., Rekhter, Y., Farinacci, D., Li, T., and A. Conta, "MPLS Label Stack Encoding", RFC 3032, DOI 10.17487/RFC3032, January 2001, . [RFC8126] Cotton, M., Leiba, B., and T. Narten, "Guidelines for Writing an IANA Considerations Section in RFCs", BCP 26, RFC 8126, DOI 10.17487/RFC8126, June 2017, . [RFC3443] Agarwal, P. and B. Akyol, "Time To Live (TTL) Processing in Multi-Protocol Label Switching (MPLS) Networks", BCP 26, RFC 8126, DOI 10.17487/RFC8126, January 2003, . [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, May 2017, . 15.2. Informative References [I-D.song-mpls-extension-header] Song, H., Li, Z., Zhou, T., Andersson, L., Zhang, Z., and R. Gandhi, "MPLS Network Actions using Post-Stack Extension Headers", Work in Progress, Internet-Draft, draft-song-mpls-extension-header-11, 15 October 2022, . [I-D.ietf-mpls-mna-fwk] Andersson, L., Bryant, S., Bocci, M., and T. Li, "MPLS Network Actions Framework", Work in Progress, Internet- Draft, draft-ietf-mpls-mna-fwk-02.txt, 21 October 2022, . Rajamanickam, et al. Expires 9 May 2023 [Page 29] Internet-Draft MPLS Network Action Encodings November 2022 [I-D.ietf-mpls-mna-requirements] Bocci, M., Bryant, S., and J. Drake, "Requirements for MPLS Network Action Indicators and MPLS Ancillary Data", Work in Progress, Internet-Draft, draft-ietf-mpls-mna- requirements-04.txt, 13 October 2022, . [I-D.ietf-mpls-mna-usecases] Saad, T., Makhijani, K., and H. Song, "Usecases for MPLS Indicators and Ancillary Data", Work in Progress, Internet-Draft, draft-ietf-mpls-mna-usecases-01, 24 October 2022, . [RFC5586] Bocci, M., Ed., Vigoureux, M., Ed., and S. Bryant, Ed., "MPLS Generic Associated Channel", RFC 5586, DOI 10.17487/RFC5586, June 2009, . [RFC4385] 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, DOI 10.17487/RFC4385, February 2006, . Acknowledgments The authors of this document would like to thank the MPLS Working Group Open Design Team for the discussions and comments on this document. The authors would also like to thank Amanda Baber for reviewing the IANA Considerations and providing many useful suggestions. The authors would like to thank Darren Dukes, Loa Andersson, Stewart Bryant and Greg Mirsky for reviewing our draft and providing many useful suggestions. Contributors The following people have substantially contributed to this document: Jisu Bhattacharya Cisco Systems, Inc. Email: jisu@cisco.com Bruno Decraene Orange Email: bruno.decraene@orange.com Rajamanickam, et al. Expires 9 May 2023 [Page 30] Internet-Draft MPLS Network Action Encodings November 2022 Weiqiang Cheng China Mobile Email: chengweiqiang@chinamobile.com Xiao Min ZTE Corp. Email: xiao.min2@zte.com.cn Luay Jalil Verizon Email: luay.jalil@verizon.com Jie Dong Huawei Technologies Huawei Campus, No. 156 Beiqing Rd. Beijing 100095 China Email: jie.dong@huawei.com Tianran Zhou Huawei Technologies China Email: zhoutianran@huawei.com Bin Wen Comcast Email: Bin_Wen@cable.comcast.com Sami Boutros Ciena Email: sboutros@ciena.com Tony Li Juniper Networks United States Email: tony.li@tony.li John Drake Juniper Networks United States Rajamanickam, et al. Expires 9 May 2023 [Page 31] Internet-Draft MPLS Network Action Encodings November 2022 Email: jdrake@juniper.net Figure 19 Authors' Addresses Jaganbabu Rajamanickam (editor) Cisco Systems, Inc. Canada Email: jrajaman@cisco.com Rakesh Gandhi (editor) Cisco Systems, Inc. Canada Email: rgandhi@cisco.com Royi Zigler (editor) Broadcom Email: royi.zigler@broadcom.com Haoyu Song (editor) Futurewei Technologies Email: haoyu.song@futurewei.com Kireeti Kompella (editor) Juniper Networks United States Email: kireeti.ietf@gmail.com Rajamanickam, et al. Expires 9 May 2023 [Page 32]