diff --git a/release/models/aft/openconfig-aft-common.yang b/release/models/aft/openconfig-aft-common.yang index c69587e0f..50eac8d8f 100644 --- a/release/models/aft/openconfig-aft-common.yang +++ b/release/models/aft/openconfig-aft-common.yang @@ -23,7 +23,13 @@ submodule openconfig-aft-common { "Submodule containing definitions of groupings that are re-used across multiple contexts within the AFT model."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-09-05" { + description + "Add encap-headers to AFT model."; + reference "2.7.0"; + } revision "2024-04-25" { description @@ -217,38 +223,212 @@ submodule openconfig-aft-common { container ip-in-ip { description - "When specified, the packet has an IP-in-IP header applied to it before - forwarding to the specified next-hop."; + "When specified, the packet has an IP-in-IP header applied to it + before forwarding to the specified next-hop. + + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; container state { config false; description "State parameters relating to IP-in-IP encapsulation."; - uses aft-common-entry-nexthop-ipip-state; + + uses aft-common-entry-nexthop-ip-state; } } container gre { description "When specified, the packet has an GRE - (Generic Routing Encapsulation)header applied to + (Generic Routing Encapsulation) header applied to it before forwarding to the specified next-hop. encapsulate-header leaf should be set to GRE for this - to apply"; + to apply. + + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; container state { config false; description "State parameters relating to GRE encapsulation."; + uses aft-common-entry-nexthop-gre-state; } } + container encap-headers { + description + "Container for packet encapsulation headers. When leaves in this + container are populated, it indicates encapsulation of the packet + matching the next-hop is performed using a stack of one or more + headers defined in the list encap-header. + + Each entry in the list must indicate an encapsulation type and + populate a container with the parameters for that encapsulation + header."; + + list encap-header { + description + "A list of headers added on top of a packet ordered by the + index value. The inner-most header is the 0th value and is + adjacent to the original packet. Additional headers may be + added in index order. + + For example, in an encapsulation stack for MPLS in UDPv4, the + first index in the list is the MPLS header and the second + index is a UDPv4 header."; + + key "index"; + + leaf index { + type leafref { + path "../state/index"; + } + description + "A unique index identifying an encapsulation header in a stack + of encapsulation headers."; + } + + container state { + description + "State parameters relating to encapsulation headers."; + + uses aft-common-nexthop-encap-headers-state; + } + + container gre { + when "../state/type = 'oc-aftt:GRE'"; + description + "Container of nodes for GRE encapsulation."; + + container state { + description + "State parameters relating to GRE encapsulation headers."; + + uses aft-common-entry-nexthop-gre-state; + } + } + + container ipv4 { + when "../state/type = 'oc-aftt:IPV4'"; + description + "Container of nodes for UDP in IPv4 encapsulation. When this + container is used, an IPv4 packet with no transport header + is added to the encapsulation list."; + + container state { + description + "State parameters relating to IP encapsulation headers."; + + uses aft-common-entry-nexthop-ip-state; + } + } + + container ipv6 { + when "../state/type = 'oc-aftt:IPV6'"; + description + "Container of nodes for UDP in IPv6 encapsulation. When this + container is used, an IPv6 packet with no transport header + is added to the encapsulation list."; + + container state { + description + "State parameters relating to IP encapsulation headers."; + + uses aft-common-entry-nexthop-ip-state; + } + } + + container mpls { + when "../state/type = 'oc-aftt:MPLS'"; + description + "Container of nodes for MPLS encapsulation."; + + container state { + description + "State parameters relating to MPLS encapsulation headers."; + + uses aft-common-entry-nexthop-mpls-state; + } + } + + container udp-v4 { + when "../state/type = 'oc-aftt:UDPV4'"; + description + "Container of nodes for UDP in IPv4 encapsulation. When this + container is used, an IPv4 header with a UDP header is added + to the encapsulation list."; + + container state { + description + "State parameters relating to UDP in IPv4 encapsulation + headers."; + + uses aft-common-entry-nexthop-encap-udp-state; + } + } + + container udp-v6 { + when "../state/type = 'oc-aftt:UDPV6'"; + description + "Container of nodes for UDP in IPv6 encapsulation. When this + container is used, an IPv6 header with a UDP header is added + to the encapsulation list."; + + container state { + description + "State parameters relating to UDP in IPv6 encapsulation + headers."; + + uses aft-common-entry-nexthop-encap-udp-state; + } + } + + container vxlan { + when "../state/type = 'oc-aftt:VXLAN'"; + description + "Container of nodes for VXLAN encapsulation."; + + container state { + description + "State parameters relating to VXLAN encapsulation headers."; + + uses aft-common-entry-nexthop-vxlan-state; + } + } + + } + } + uses oc-if:interface-ref-state; } } } + grouping aft-common-nexthop-encap-headers-state { + description + "Operational state parameters relating to encapsulation headers."; + + leaf index { + type uint8; + description + "A pointer to an entry in an ordered list of encapsulation headers."; + } + + leaf type { + type oc-aftt:encapsulation-header-type; + description + "Defines which type of packet header should be used."; + } + + } + grouping aft-common-entry-state { description "Operational state parameters relating to a forwarding entry"; @@ -294,14 +474,24 @@ submodule openconfig-aft-common { "Where applicable, the next hop label representing the virtual network identifier (VNI) for the forwarding entry. This leaf is applicable only to next-hops which include VXLAN encapsulation - header information"; + header information. + + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; } leaf tunnel-src-ip-address { type oc-inet:ip-address; description "Where applicable this represents the vxlan tunnel source ip address. - For VXLAN this represents the source VTEP ip address"; + For VXLAN this represents the source VTEP IP address. + + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; } } @@ -348,7 +538,7 @@ submodule openconfig-aft-common { default false; description "Flag that controls pop action, i.e., the top-most MPLS label - should be popped from the packet when switched by the system. + should be popped from the packet when switched by the system. The top-most MPLS label associated with pop action is equal to the label key used in 'mpls' AFT 'label-entry' list."; @@ -372,8 +562,12 @@ submodule openconfig-aft-common { system re-ordering of leaves is permitted by the system. A swap operation is reflected by entries in the - popped-mpls-label-stack and pushed-mpls-label-stack nodes."; + popped-mpls-label-stack and pushed-mpls-label-stack nodes. + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; } leaf encapsulate-header { @@ -381,7 +575,12 @@ submodule openconfig-aft-common { description "When forwarding a packet to the specified next-hop the local system performs an encapsulation of the packet - adding the - specified header type."; + specified header type. + + This node must be supported in addition to the + encap-headers/encap-header tree. A future release of OpenConfig + will deprecate this node in favor of the + encap-headers/encap-header subtree."; } leaf decapsulate-header { @@ -399,9 +598,9 @@ submodule openconfig-aft-common { uses aft-common-install-protocol; } - grouping aft-common-entry-nexthop-ipip-state { + grouping aft-common-entry-nexthop-ip-state { description - "IP-in-IP encapsulation applied on a next-hop"; + "IP encapsulation applied on a next-hop"; leaf src-ip { type oc-inet:ip-address; @@ -444,6 +643,115 @@ submodule openconfig-aft-common { } } + grouping aft-common-entry-nexthop-mpls-state { + description + "MPLS encapsulation of a packet."; + + leaf traffic-class { + type oc-mplst:mpls-tc; + description + "The value of the MPLS traffic class (TC) bits, formerly known as the + EXP bits."; + } + + leaf-list mpls-label-stack { + type oc-mplst:mpls-label; + ordered-by user; + description + "A stack of MPLS label values. The first entry in the list is the + label at the bottom of the stack. The bottom of the stack is adjacent + to the MPLS payload. + + For example, a packet with a label stack of two labels, the bottom + label being 42 and the top label being 8072 will be represented with + a leaf-list of [42, 8072]. The resulting packet, starting with the + beginning of the packet will be '[8072][42][Payload]'. + + Note: a swap operation is reflected by entries in the + popped-mpls-label-stack and the pushed-mpls-label-stack"; + } + } + + + grouping aft-common-entry-nexthop-encap-udp-state { + description + "UDP encapsulation applied on top of a packet."; + + leaf src-ip { + type oc-inet:ip-address; + description + "The source IP address for IP/UDP encapsulation."; + } + + leaf dst-ip { + type oc-inet:ip-address; + description + "Destination IP address for IP/UDP encapsulation."; + } + + leaf dscp { + type oc-inet:dscp; + description + "DSCP value to use for the UDP header of the encapsulated + packet."; + } + + leaf src-udp-port { + type oc-inet:port-number; + description + "Source UDP port number to use for the UDP header of the encapsulated + packet. The source UDP port should be derived from the payload + packet entropy. The exact methodology is implementation dependent, + but for example, the port could be derived from an entropy hash of + the payload or the source port (if present) of the payload."; + } + + leaf dst-udp-port { + type oc-inet:port-number; + description + "Source UDP port number to use for the UDP header of the encapsulated + packet. + + When the payload packet is MPLS, then RFC 7510 - Encapsulating MPLS + in UDP should be followed."; + reference + "RFC 7510 - Encapsulating MPLS in UDP specifies that 6635 must be + used for MPLS-in-UDP and 6636 must be used for MPLS-in-UDP with DTLS. + Because of this condition, no default is defined in OpenConfig. The + system is expected to utilize the appropriate port."; + } + + leaf ip-ttl { + type uint8; + description + "This leaf reflects the configured/default IP TTL value that is used + in the outer header during packet encapsulation. When this leaf is + not set, the TTL value of the inner packet is copied over as the + outer packet's IP TTL value during encapsulation."; + } + } + + grouping aft-common-entry-nexthop-vxlan-state { + description + "VXLAN encapsulation applied on top of a packet."; + + leaf vni-label { + type oc-evpn-types:evi-id; + description + "Where applicable, the next hop label representing the virtual + network identifier (VNI) for the forwarding entry. This leaf is + applicable only to next-hops which include VXLAN encapsulation + header information"; + } + + leaf tunnel-src-ip-address { + type oc-inet:ip-address; + description + "Where applicable this represents the vxlan tunnel source ip address. + For VXLAN this represents the source VTEP ip address"; + } + } + grouping aft-common-install-protocol { description "Grouping for a common reference to the protocol which diff --git a/release/models/aft/openconfig-aft-ethernet.yang b/release/models/aft/openconfig-aft-ethernet.yang index b2c0758df..3fbe6edab 100644 --- a/release/models/aft/openconfig-aft-ethernet.yang +++ b/release/models/aft/openconfig-aft-ethernet.yang @@ -20,7 +20,13 @@ submodule openconfig-aft-ethernet { "Submodule containing definitions of groupings for the abstract forwarding tables for Ethernet."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-07-18" { + description + "Add container for mpls-in-udp under next-hops aft entry state."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-ipv4.yang b/release/models/aft/openconfig-aft-ipv4.yang index d582b2ad7..87fb7e6fa 100644 --- a/release/models/aft/openconfig-aft-ipv4.yang +++ b/release/models/aft/openconfig-aft-ipv4.yang @@ -20,7 +20,13 @@ submodule openconfig-aft-ipv4 { "Submodule containing definitions of groupings for the abstract forwarding tables for IPv4."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-09-05" { + description + "Add encapsulate-stack under aft next-hops."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-ipv6.yang b/release/models/aft/openconfig-aft-ipv6.yang index c8aede635..765830cd5 100644 --- a/release/models/aft/openconfig-aft-ipv6.yang +++ b/release/models/aft/openconfig-aft-ipv6.yang @@ -20,7 +20,13 @@ submodule openconfig-aft-ipv6 { "Submodule containing definitions of groupings for the abstract forwarding tables for IPv6."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-07-18" { + description + "Add container for mpls-in-udp under next-hops aft entry state."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-mpls.yang b/release/models/aft/openconfig-aft-mpls.yang index 2418a5a9e..c99e1c58f 100644 --- a/release/models/aft/openconfig-aft-mpls.yang +++ b/release/models/aft/openconfig-aft-mpls.yang @@ -21,7 +21,13 @@ submodule openconfig-aft-mpls { "Submodule containing definitions of groupings for the abstract forwarding table for MPLS label forwarding."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-09-05" { + description + "Add encapsulate-stack under aft next-hops."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-pf.yang b/release/models/aft/openconfig-aft-pf.yang index 8f0d5a243..9980ad5f0 100644 --- a/release/models/aft/openconfig-aft-pf.yang +++ b/release/models/aft/openconfig-aft-pf.yang @@ -28,7 +28,13 @@ submodule openconfig-aft-pf { fields other than the destination address that is used in other forwarding tables."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-07-18" { + description + "Add container for mpls-in-udp under next-hops aft entry state."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-state-synced.yang b/release/models/aft/openconfig-aft-state-synced.yang index 3e0950826..fbe6eb5ca 100644 --- a/release/models/aft/openconfig-aft-state-synced.yang +++ b/release/models/aft/openconfig-aft-state-synced.yang @@ -16,7 +16,13 @@ submodule openconfig-aft-state-synced { "Submodule containing definitions of groupings for the state synced signals corresponding to various abstract forwarding tables."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-07-18" { + description + "Add container for mpls-in-udp under next-hops aft entry state."; + reference "2.7.0"; + } revision "2024-04-25" { description diff --git a/release/models/aft/openconfig-aft-types.yang b/release/models/aft/openconfig-aft-types.yang index 4b7fc8f64..56d920b5f 100644 --- a/release/models/aft/openconfig-aft-types.yang +++ b/release/models/aft/openconfig-aft-types.yang @@ -16,7 +16,13 @@ module openconfig-aft-types { "Types related to the OpenConfig Abstract Forwarding Table (AFT) model"; - oc-ext:openconfig-version "1.1.0"; + oc-ext:openconfig-version "1.2.0"; + + revision "2024-07-18" { + description + "Add MPLS in UDP enums for encapsulate-header."; + reference "1.2.0"; + } revision "2022-05-05" { description @@ -89,6 +95,10 @@ module openconfig-aft-types { description "The encapsulation header is a VXLAN packet header"; } + enum UDP { + description + "The encapsulation header is UDP packet header."; + } } description "Types of tunnel encapsulation that are supported by systems as either diff --git a/release/models/aft/openconfig-aft.yang b/release/models/aft/openconfig-aft.yang index d1af3e977..de3ce202e 100644 --- a/release/models/aft/openconfig-aft.yang +++ b/release/models/aft/openconfig-aft.yang @@ -42,7 +42,13 @@ module openconfig-aft { is referred to as an Abstract Forwarding Table (AFT), rather than the FIB."; - oc-ext:openconfig-version "2.6.0"; + oc-ext:openconfig-version "2.7.0"; + + revision "2024-09-05" { + description + "Add encapsulate-stack under aft next-hops."; + reference "2.7.0"; + } revision "2024-04-25" { description