RFC 9263 | NSH MD2 Context Headers | August 2022 |
Wei, et al. | Standards Track | [Page] |
Service Function Chaining (SFC) uses the Network Service Header (NSH) (RFC 8300) to steer and provide context metadata (MD) with each packet. Such metadata can be of various types, including MD Type 2, consisting of Variable-Length Context Headers. This document specifies several such Context Headers that can be used within a Service Function Path (SFP).¶
This is an Internet Standards Track document.¶
This document is a product of the Internet Engineering Task Force (IETF). It represents the consensus of the IETF community. It has received public review and has been approved for publication by the Internet Engineering Steering Group (IESG). Further information on Internet Standards is available in Section 2 of RFC 7841.¶
Information about the current status of this document, any errata, and how to provide feedback on it may be obtained at https://www.rfc-editor.org/info/rfc9263.¶
Copyright (c) 2022 IETF Trust and the persons identified as the document authors. All rights reserved.¶
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.¶
The Network Service Header (NSH) [RFC8300] is the Service Function Chaining (SFC) encapsulation that supports the SFC architecture [RFC7665]. As such, the NSH provides the following key elements:¶
[RFC8300] further defines two metadata formats (MD Types): 1 and 2. MD Type 1 defines the fixed-length, 16-octet metadata, whereas MD Type 2 defines a variable-length context format for metadata. This document defines several common metadata Context Headers for use within NSH MD Type 2. These supplement the Subscriber Identifier and Performance Policy MD Type 2 metadata Context Headers specified in [RFC8979].¶
This document does not address metadata usage, updating/chaining of metadata, or other SFP functions. Those topics are described in [RFC8300].¶
This document uses the terminology defined in the SFC architecture [RFC7665] and the NSH [RFC8300].¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here.¶
An NSH is composed of a 4-octet Base Header, a 4-octet Service Path Header, and optional Context Headers. The Base Header identifies the MD Type in use:¶
Please refer to the NSH [RFC8300] for a detailed header description.¶
When the Base Header specifies MD Type = 0x2, zero or more Variable-Length Context Headers MAY be added, immediately following the Service Path Header. Figure 2 below depicts the format of the Context Header as defined in Section 2.5.1 of [RFC8300].¶
[RFC8300] specifies Metadata Class 0x0000 as IETF Base NSH MD Class. In this document, metadata types are defined for the IETF Base NSH MD Class. The Context Headers specified in the subsections below are as follows:¶
This metadata context carries a network forwarding context, used for segregation and forwarding scope. Forwarding context can take several forms depending on the network environment, for example, Virtual eXtensible Local Area Network (VXLAN) / Generic Protocol Extension for VXLAN (VXLAN-GPE) Virtual Network Identifier (VNID), VPN Routing and Forwarding (VRF) identification, or VLAN.¶
The fields are described as follows:¶
This 4-bit field that defines the interpretation of the Forwarding Context field. Please see the IANA considerations in Section 6.2. This document defines these CT values:¶
Tenant identification is often used for segregation within a multi-tenant environment. Orchestration system-generated Tenant IDs are an example of such data. This Context Header carries the value of the Tenant ID. Virtual Tenant Network (VTN) [OpenDaylight-VTN] is an application that provides multi-tenant virtual networks on a Software-Defined Networking (SDN) controller.¶
The fields are described as follows:¶
This Context Header carries a Node ID of the network node at which the packet entered the SFC-enabled domain. This node will necessarily be a classifier [RFC7665]. In cases where the Service Path Identifier (SPI) identifies the ingress node, this Context Header is superfluous.¶
The fields are described as follows:¶
This context identifies the ingress interface of the ingress network node. The l2vlan (135), l3ipvlan (136), ipForward (142), and mpls (166) in [IANAifType] are examples of source interfaces.¶
The fields are described as follows:¶
Flow ID provides a field in NSH MD Type 2 to label packets belonging to the same flow. For example, [RFC8200] defines IPv6 Flow Label as Flow ID. Another example of Flow ID is how [RFC6790] defines an entropy label that is generated based on flow information in the MPLS network. Absence of this field or a value of zero denotes that packets have not been labeled with a Flow ID.¶
The fields are described as follows:¶
This 4-bit field that defines the interpretation of the Flow ID field. Please see the IANA considerations in Section 6.3. This document defines these CT values:¶
Intent-based systems can use this data to express the logical grouping of source and/or destination objects. [OpenStack] and [OpenDaylight] provide examples of such a system. Each is expressed as a 32-bit opaque object.¶
If there is no group information specified for the Source Group or Destination Group field, the field MUST be sent as zero and ignored on receipt.¶
Traffic handling policies are often referred to by a system-generated identifier, which is then used by the devices to look up the policy's content locally. For example, this identifier could be an index to an array, a lookup key, or a database ID. The identifier allows enforcement agents or services to look up the content of their part of the policy.¶
The fields are described as follows:¶
This Policy ID is a general Policy ID, essentially a key to allow Service Functions (SFs) to know which policies to apply to packets. Those policies generally will not have much to do with performance but rather with what specific treatment to apply. It may, for example, select a URL filter data set for a URL filter or select a video transcoding policy in a transcoding SF. The Performance Policy ID in [RFC8979] is described there as having very specific use and, for example, says that fully controlled SFPs would not use it. The Policy ID in this document is for cases not covered by [RFC8979].¶
A misbehaving node from within the SFC-enabled domain may alter the content of the Context Headers, which may lead to service disruption. Such an attack is not unique to the Context Headers defined in this document. Measures discussed in Section 8 of [RFC8300] describes the general security considerations for protecting the NSH. [RFC9145] specifies methods of protecting the integrity of the NSH metadata. If the NSH includes the Message Authentication Code (MAC) and Encrypted Metadata Context Header [RFC9145], the authentication of the packet MUST be verified before using any data. If the verification fails, the receiver MUST stop processing the Variable-Length Context Headers and notify an operator.¶
The security and privacy considerations for the 7 types of Context Headers specified above are discussed below. Since NSH-ignorant SFs will never see the NSH, then even if they are malign, they cannot compromise security or privacy based on the NSH or any of these Context Headers; however, they could cause compromise based on the rest of the packet. To the extent that any of these headers are included when they would be unneeded or have no effect, they provide a covert channel for the entity adding the Context Header to communicate a limited amount of arbitrary information to downstream entities within the SFC-enabled domain.¶
All of the Forwarding Context variants specified in this document (those with CT values between 0 and 4) merely repeat a field that is available in the packet encapsulated by the NSH. These variants repeat that field in the NSH for convenience. Thus, there are no special security or privacy considerations in these cases. Any future new values of CT for the Forwarding Context must specify the security and privacy considerations for those extensions.¶
The Tenant ID indicates the tenant to which traffic belongs and might be used to tie together and correlate packets for a tenant that some monitoring function could not otherwise group, especially if other possible identifiers were being randomized. As such, it may reduce security by facilitating traffic analysis but only within the SFC-enabled domain where this Context Header is present in packets.¶
The SFC-enabled domain manager normally operates the initial ingress/classifier node and is thus potentially aware of the information provided by this Context Header. Furthermore, in many cases, the SPI that will be present in the NSH identifies or closely constrains the ingress node. Also, in most cases, it is anticipated that many entities will be sending packets into an SFC-enabled domain through the same ingress node. Thus, under most circumstances, this Context Header is expected to weaken security and privacy to only a minor extent and only within the SFC-enabled domain.¶
This Context Header is likely to be meaningless unless the Ingress Network Node Information Context Header is also present. When that node information header is present, this source interface header provides a more fine-grained view of the source by identifying not just the initial ingress/classifier node but also the port of that node on which the data arrived. Thus, it is more likely to identify a specific source entity or at least to more tightly constrain the set of possible source entities than just the node information header. As a result, inclusion of this Context Header with the node information Context Header is potentially a greater threat to security and privacy than the node information header alone, but this threat is still constrained to the SFC-enabled domain.¶
The variations of this Context Header specified in this document simply repeat fields already available in the packet and thus have no special security or privacy considerations. Any future new values of CT for the Flow ID must specify the security and privacy considerations for those extensions.¶
This Context Header provides additional information that might help identify the source and/or destination of packets. Depending on the granularity of the groups, it could either (1) distinguish packets as part of flows from and/or to objects where those flows could not otherwise be easily distinguished but appear to be part of one or fewer flows or (2) group packet flows that are from and/or to an object where those flows could not otherwise be easily grouped for analysis or another purpose. Thus, the presence of this Context Header with non-zero source and/or destination groups can, within the SFC-enabled domain, erode security and privacy to an extent that depends on the details of the grouping.¶
This Context Header carries an identifier that nodes in the SFC-enabled domain can use to look up policy to potentially influence their actions with regard to the packet carrying this header. If there are no such decisions regarding their actions, then the header should not be included. If there are such decisions, the information on which they are to be based needs to be included somewhere in the packet. There is no reason for inclusion in this Context Header to have any security or privacy considerations that would not apply to any other plaintext way of including such information. It may provide additional information to help identify a flow of data for analysis.¶
IANA has assigned the following types (Table 1) from the "NSH IETF-Assigned Optional Variable-Length Metadata Types" registry available at [IANA-NSH-MD2].¶
Value | Description | Reference |
---|---|---|
0x04 | Forwarding Context | RFC 9263 |
0x05 | Tenant ID | RFC 9263 |
0x06 | Ingress Network Node ID | RFC 9263 |
0x07 | Ingress Network Interface | RFC 9263 |
0x08 | Flow ID | RFC 9263 |
0x09 | Source and/or Destination Groups | RFC 9263 |
0x0A | Policy ID | RFC 9263 |
IANA has created a new subregistry for "Forwarding Context Types" at [IANA-NSH-MD2] as follows.¶
The registration policy is IETF Review.¶
Value | Description | Reference |
---|---|---|
0x0 | 12-bit VLAN identifier | RFC 9263 |
0x1 | 24-bit double tagging identifiers | RFC 9263 |
0x2 | 20-bit MPLS VPN label | RFC 9263 |
0x3 | 24-bit virtual network identifier (VNI) | RFC 9263 |
0x4 | 32-bit Session ID | RFC 9263 |
0x5-0xE | Unassigned | |
0xF | Reserved | RFC 9263 |
IANA has created a new subregistry for "Flow ID Context Types" at [IANA-NSH-MD2] as follows.¶
The registration policy is IETF Review.¶
Value | Description | Reference |
---|---|---|
0x0 | 20-bit IPv6 Flow Label | RFC 9263 |
0x1 | 20-bit entropy label in the MPLS network | RFC 9263 |
0x2-0xE | Unassigned | |
0xF | Reserved | RFC 9263 |
The authors would like to thank Paul Quinn, Behcet Sarikaya, Dirk von Hugo, Mohamed Boucadair, Gregory Mirsky, and Joel Halpern for providing invaluable concepts and content for this document.¶