Skip to main content

4. SR Endpoint Behaviors

4. SR Endpoint Behaviors

The following is a set of well-known behaviors that can be associated with a SID.

BehaviorDescription
EndEndpoint

The SRv6 instantiation of a Prefix-SID [RFC8402]
End.XEndpoint with L3 cross-connect

The SRv6 instantiation of an Adj-SID [RFC8402]
End.TEndpoint with specific IPv6 table lookup
End.DX6Endpoint with decapsulation and IPv6 cross-connect

e.g., IPv6-L3VPN (equivalent to per-CE VPN label)
End.DX4Endpoint with decapsulation and IPv4 cross-connect

e.g., IPv4-L3VPN (equivalent to per-CE VPN label)
End.DT6Endpoint with decapsulation and specific IPv6 table lookup

e.g., IPv6-L3VPN (equivalent to per-VRF VPN label)
End.DT4Endpoint with decapsulation and specific IPv4 table lookup

e.g., IPv4-L3VPN (equivalent to per-VRF VPN label)
End.DT46Endpoint with decapsulation and specific IP table lookup

e.g., IP-L3VPN (equivalent to per-VRF VPN label)
End.DX2Endpoint with decapsulation and L2 cross-connect

e.g., L2VPN use case
End.DX2VEndpoint with decapsulation and VLAN L2 table lookup

e.g., EVPN Flexible Cross-connect use case
End.DT2UEndpoint with decapsulation and unicast MAC L2 table lookup

e.g., EVPN Bridging Unicast use case
End.DT2MEndpoint with decapsulation and L2 table flooding

e.g., EVPN Bridging Broadcast, Unknown Unicast, and Multicast (BUM) use case with Ethernet Segment Identifier (ESI) filtering
End.B6.EncapsEndpoint bound to an SRv6 Policy with encapsulation

SRv6 instantiation of a Binding SID
End.B6.Encaps.RedEnd.B6.Encaps with reduced SRH

SRv6 instantiation of a Binding SID
End.BMEndpoint bound to an SR-MPLS Policy

SRv6 instantiation of an SR-MPLS Binding SID

Table 1: Endpoint Behaviors

The list is not exhaustive. In practice, any behavior can be attached to a local SID; for example, a node N can bind a SID to a local Virtual Machine (VM) or container that can apply any complex processing on the packet, provided there is an SRv6 Endpoint Behavior codepoint allocated for the processing.

When an SRv6-capable node (N) receives an IPv6 packet whose destination address matches a FIB entry that represents a locally instantiated SRv6 SID (S), the IPv6 header chain is processed as defined in Section 4 of [RFC8200]. For SRv6 SIDs associated with an Endpoint behavior defined in this document, the SRH and Upper-Layer header are processed as defined in the following subsections.

The pseudocode describing these behaviors details local processing at a node. An implementation of the pseudocode is compliant as long as the externally observable wire protocol is as described by the pseudocode.

Section 4.16 defines flavors of some of these behaviors.

Section 10.2 of this document defines the IANA registry used to maintain all these behaviors as well as future ones defined in other documents.

4.1. End: Endpoint

The Endpoint behavior ("End" for short) is the most basic behavior. It is the instantiation of a Prefix-SID [RFC8402].

When N receives a packet whose IPv6 DA is S and S is a local End SID, N does the following:

S01. When an SRH is processed {
S02. If (Segments Left == 0) {
S03. Stop processing the SRH, and proceed to process the next
header in the packet, whose type is identified by
the Next Header field in the routing header.
S04. }
S05. If (IPv6 Hop Limit <= 1) {
S06. Send an ICMP Time Exceeded message to the Source Address
with Code 0 (Hop limit exceeded in transit),
interrupt packet processing, and discard the packet.
S07. }
S08. max_LE = (Hdr Ext Len / 2) - 1
S09. If ((Last Entry > max_LE) or (Segments Left > Last Entry+1)) {
S10. Send an ICMP Parameter Problem to the Source Address
with Code 0 (Erroneous header field encountered)
and Pointer set to the Segments Left field,
interrupt packet processing, and discard the packet.
S11. }
S12. Decrement IPv6 Hop Limit by 1
S13. Decrement Segments Left by 1
S14. Update IPv6 DA with Segment List[Segments Left]
S15. Submit the packet to the egress IPv6 FIB lookup for
transmission to the new destination
S16. }

Note:

The End behavior operates on the same FIB table (i.e., identified by VRF or L3 relay ID) associated to the packet. Hence, the FIB lookup on line S15 is done in the same FIB table as the ingress interface.

4.1.1. Upper-Layer Header

When processing the Upper-Layer header of a packet matching a FIB entry locally instantiated as an End SID, N does the following:

S01. If (Upper-Layer header type is allowed by local configuration) {
S02. Proceed to process the Upper-Layer header
S03. } Else {
S04. Send an ICMP Parameter Problem to the Source Address
with Code 4 (SR Upper-layer Header Error)
and Pointer set to the offset of the Upper-Layer header,
interrupt packet processing, and discard the packet.
S05 }

Allowing the processing of specific Upper-Layer header types is useful for Operations, Administration, and Maintenance (OAM). As an example, an operator might permit pinging of SIDs. To do this, they may enable local configuration to allow Upper-Layer header type 58 (ICMPv6).

It is RECOMMENDED that an implementation of local configuration only allows Upper-Layer header processing of types that do not result in the packet being forwarded (e.g., ICMPv6).

[继续其他子章节...]