Network Working Group                                    S. Previdi, Ed.
Internet-Draft                                       Cisco Systems, Inc.
Intended status: Standards Track                           K. Talaulikar
Expires: December 31, 2018                           Cisco Systems, Inc.
                                                            J. Dong, Ed.
Expires: June 29, 2018
                                                                 M. Chen
                                                     Huawei Technologies
                                                              H. Gredler
                                                            RtBrick Inc.
                                                             J. Tantsura
                                                              Individual
                                                       December 26, 2017
                                                          Nuage Networks
                                                           June 29, 2018

Distribution of Traffic Engineering (TE) Policies and State using BGP-LS
                 draft-ietf-idr-te-lsp-distribution-08
                 draft-ietf-idr-te-lsp-distribution-09

Abstract

   This document describes a mechanism to collect the Traffic
   Engineering and Policy information that is locally available in a
   router
   node and advertise it into BGP-LS updates.  Such information can be
   used by external components for path computation, re-optimization,
   service placement, network visualization, etc.

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 RFC 2119 [RFC2119].

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 June 29, December 31, 2018.

Copyright Notice

   Copyright (c) 2017 2018 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 Simplified BSD License text as described in Section 4.e of
   the Trust Legal Provisions and are provided without warranty as
   described in the Simplified BSD License.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2   3
   2.  Carrying TE Policy Information in BGP . . . . . . . . . . . .   5
     2.1.
   3.  TE Policy Information NLRI  . . . . . . . . . . . . . . . . . .   5
     2.2. . . . . .   6
   4.  TE Policy NLRI Descriptors . . . . . . . . . . . . . . . . . . . .   7
     4.1.  Tunnel Identifier (Tunnel ID) . . . . . . . . . . . . . .   7
     4.2.  LSP Identifier (LSP ID) .   5
       2.2.1.  TE Policy Descriptors . . . . . . . . . . . . . . . .   7
     2.3.  TE
     4.3.  IPv4/IPv6 Tunnel Head-End Address . . . . . . . . . . . .   8
     4.4.  IPv4/IPv6 Tunnel Tail-End Address . . . . . . . . . . . .   8
     4.5.  SR Policy State Candidate Path Descriptor . . . . . . . . . . .   9
     4.6.  Local MPLS Cross Connect  . . . . . . . . . . . . . . . .  11
       4.6.1.  MPLS Cross Connect Interface  . . . . . . . . . . . .  12
       2.3.1.  RSVP Objects
       4.6.2.  MPLS Cross Connect FEC  . . . . . . . . . . . . . . .  13
   5.  MPLS-TE Policy State TLV  . . . . . .  14
       2.3.2.  PCE Objects . . . . . . . . . . . .  14
     5.1.  RSVP Objects  . . . . . . . . .  15
       2.3.3.  SR TE Policy Sub-TLVs . . . . . . . . . . . . .  15
     5.2.  PCEP Objects  . . .  16
   3.  Operational Considerations . . . . . . . . . . . . . . . . .  22
   4.  IANA Considerations . .  16
   6.  SR Policy State TLVs  . . . . . . . . . . . . . . . . . . .  22
     4.1.  BGP-LS NLRI-Types .  17
     6.1.  SR Binding SID  . . . . . . . . . . . . . . . . . . .  22
     4.2.  BGP-LS Protocol-IDs . .  17
     6.2.  SR Candidate Path State . . . . . . . . . . . . . . . . .  23
     4.3.  BGP-LS Descriptors TLVs  19
     6.3.  SR Candidate Path Name  . . . . . . . . . . . . . . . . .  23
     4.4.  BGP-LS LSP-State TLV  21
     6.4.  SR Candidate Path Origin Constraints . . . . . . . . . . . .  23
     4.5.  BGP-LS LSP-State TLV Dataplane . .  21
       6.4.1.  SR Affinity Constraint  . . . . . . . . . . . .  24
   5.  Security Considerations . . .  23
       6.4.2.  SR SRLG Constraint  . . . . . . . . . . . . . . . . .  24
   6.  Acknowledgements
       6.4.3.  SR Bandwidth Constraint . . . . . . . . . . . . . . .  24
       6.4.4.  SR Disjoint Group Constraint  . . . . . . .  24
   7.  Contributors . . . . .  25
     6.5.  SR Segment List . . . . . . . . . . . . . . . . . . .  24
   8.  References . .  27
     6.6.  SR Segment  . . . . . . . . . . . . . . . . . . . . . . .  25
     8.1.  Normative References  29
       6.6.1.  Segment Descriptors . . . . . . . . . . . . . . . . .  31
     6.7.  SR Segment List Metric  .  25
     8.2.  Informative References . . . . . . . . . . . . . . . .  37
   7.  Procedures  .  26
   Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . .  27

1.  Introduction

   In many network environments, traffic engineering policies .  39
   8.  Manageability Considerations  . . . . . . . . . . . . . . . .  40
   9.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .  40
     9.1.  BGP-LS NLRI-Types . . . . . . . . . . . . . . . . . . . .  40
     9.2.  BGP-LS Protocol-IDs . . . . . . . . . . . . . . . . . . .  40
     9.3.  BGP-LS TLVs . . . . . . . . . . . . . . . . . . . . . . .  41
     9.4.  BGP-LS SR Policy Protocol Origin  . . . . . . . . . . . .  41
     9.5.  BGP-LS TE State Path Origin . . . . . . . . . . . . . . .  42
     9.6.  BGP-LS TE State Dataplane . . . . . . . . . . . . . . . .  42
     9.7.  BGP-LS SR Segment Descriptors . . . . . . . . . . . . . .  43
     9.8.  BGP-LS Metric Type  . . . . . . . . . . . . . . . . . . .  43
   10. Security Considerations . . . . . . . . . . . . . . . . . . .  44
   11. Acknowledgements  . . . . . . . . . . . . . . . . . . . . . .  44
   12. Contributors  . . . . . . . . . . . . . . . . . . . . . . . .  44
   13. References  . . . . . . . . . . . . . . . . . . . . . . . . .  44
     13.1.  Normative References . . . . . . . . . . . . . . . . . .  44
     13.2.  Informative References . . . . . . . . . . . . . . . . .  46
   Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .  47

1.  Introduction

   In many network environments, traffic engineering policies are
   instantiated into various forms:

   o  MPLS Traffic Engineering Label Switched Paths (TE-LSPs).

   o  IP based tunnels (IP in IP, GRE, etc).

   o  Segment Routing Policies (SR Policy) as defined in
      [I-D.ietf-spring-segment-routing-policy]

   o  Local MPLS cross-connect configuration

   All this information can be grouped into the same term: TE Policies.
   In the rest of this document we refer to TE Policies as the set of
   information related to the various instantiation of polices: MPLS TE
   LSPs, IP tunnels (IPv4 or IPv6), SR Policies, etc.

   TE Polices are generally instantiated at the head-end and are based
   on either local configuration or controller based programming of the
   node using various APIs and protocols, e.g., PCEP or BGP.

   In many network environments, the configuration and state of each TE
   Policy that is available in the network is required by a controller
   which allows the network operator to optimize several functions and
   operations through the use of a controller aware of both topology and
   state information.

   One example of a controller is the stateful Path Computation Element
   (PCE) [RFC8231], which could provide benefits in path reoptimization.
   While some extensions are proposed in Path Computation Element
   Communication Protocol (PCEP) for the Path Computation Clients (PCCs)
   to report the LSP states to the PCE, this mechanism may not be
   applicable in a management-based PCE architecture as specified in
   section 5.5 of [RFC4655].  As illustrated in the figure below, the
   PCC is not an LSR in the routing domain, thus the head-end nodes of
   the TE-LSPs may not implement the PCEP protocol.  In this case a
   general mechanism to collect the TE-LSP states from the ingress LERs
   is needed.  This document proposes an TE Policy state collection
   mechanism complementary to the mechanism defined in [RFC8231].

                                   -----------
                                  |   -----   |
              Service             |  | TED |<-+----------->
              Request             |   -----   |  TED synchronization
                 |                |     |     |  mechanism (for example,
                 v                |     |     |  routing protocol)
           ------------- Request/ |     v     |
          |             | Response|   -----   |
          |     NMS     |<--------+> | PCE |  |
          |             |         |   -----   |
           -------------           -----------
         Service |
         Request |
                 v
            ----------  Signaling   ----------
           | Head-End | Protocol   | Adjacent |
           |  Node    |<---------->|   Node   |
            ----------              ----------

                 Figure 1.  Management-Based PCE Usage

   In networks with composite PCE nodes as specified in section 5.1 of
   [RFC4655], PCE is implemented on several routers in the network, and
   the PCCs in the network can use the mechanism described in [RFC8231]
   to report the TE Policy information to the PCE nodes.  An external
   component may also need to collect the TE Policy information from all
   the PCEs in the network to obtain a global view of the LSP state in
   the network.

   In multi-area or multi-AS scenarios, each area or AS can have a child
   PCE to collect the TE Policies in its own domain, in addition, a
   parent PCE needs to collect TE Policy information from multiple child
   PCEs to obtain a global view of LSPs inside and across the domains
   involved.

   In another network scenario, a centralized controller is used for
   service placement.  Obtaining the TE Policy state information is
   quite important for making appropriate service placement decisions
   with the purpose to both meet the application's requirements and
   utilize network resources efficiently.

   The Network Management System (NMS) may need to provide global
   visibility of the TE Policies in the network as part of the network
   visualization function.

   BGP has been extended to distribute link-state and traffic
   engineering information to external components [RFC7752].  Using the
   same protocol to collect Traffic Engineering Policy and state
   information is desirable for these external components since this
   avoids introducing multiple protocols for network information
   collection.  This document describes a mechanism to distribute
   traffic engineering policy information (MPLS, SR, IPv4 and IPv6) to
   external components using BGP-LS.

2.  Carrying TE Policy Information in BGP

   TE Policy information is advertised in BGP UPDATE messages using the
   MP_REACH_NLRI and MP_UNREACH_NLRI attributes [RFC4760].  The "Link-
   State NLRI" defined in [RFC7752] is extended to carry the TE Policy
   information.  BGP speakers that wish to exchange TE Policy
   information MUST use the BGP Multiprotocol Extensions Capability Code
   (1) to advertise the corresponding (AFI, SAFI) pair, as specified in
   [RFC4760].  New TLVs carried in the Link_State Attribute defined in
   [RFC7752] are also defined in order to carry the attributes of a TE
   Policy in the subsequent sections.

   The format of "Link-State NLRI" is defined in [RFC7752] as follows:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |            NLRI Type          |     Total NLRI Length         |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     //                  Link-State NLRI (variable)                 //
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   A new "NLRI Type" is defined for TE Policy Information as following:

   o  NLRI Type: TE Policy NLRI (value TBD see IANA Considerations
      Section 9.1).

   The format of this new NLRI type is defined in Section 3 below.

3.  TE Policy NLRI

   This document defines the new TE Policy NLRI-Type and its format as
   shown in the following figure:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+
     |  Protocol-ID  |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                        Identifier                             |
     |                        (64 bits)                              |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                Headend (Node Descriptors)                   //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                TE Policy Descriptors (variable)             //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Protocol-ID field specifies the component that owns the TE Policy
      state in the advertising node.  The following new Protocol-IDs are
      defined (values TBD see IANA Considerations Section 9.2) and apply
      to the TE Policy NLRI:

               +-------------+----------------------------------+
               | Protocol-ID | NLRI information source protocol |
               +-------------+----------------------------------+
               |    TBD      |   RSVP-TE                        |
               |    TBD      |   Segment Routing                |
               +-------------+----------------------------------+

   o  "Identifier" is an 8 octet value as defined in [RFC7752].

   o  "Headend" consists of a Node Descriptor defined in [RFC7752].

   o  "TE Policy Descriptors" consists of (values TBD see IANA
      Considerations Section 9.3):

   +-----------+----------------------------------+
   | Codepoint |       Descriptor TLVs            |
   +-----------+----------------------------------+
   |  TBD      | Tunnel ID                        |
   |  TBD      | LSP ID                           |
   |  TBD      | IPv4/6 Tunnel Head-end address   |
   |  TBD      | IPv4/6 Tunnel Tail-end address   |
   |  TBD      | SR Policy Candidate Path         |
   |  TBD      | Local MPLS Cross Connect         |
   +-----------+----------------------------------+

4.  TE Policy Descriptors

   This sections defines the TE Policy Descriptors TLVs which are used
   to describe the TE Policy being advertised by using the new BGP-LS TE
   Policy NLRI type defined in Section 3.

4.1.  Tunnel Identifier (Tunnel ID)

   The Tunnel Identifier TLV contains the Tunnel ID defined in [RFC3209]
   and is used for RSVP-TE protocol TE Policies.  It has the following
   format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |         Tunnel ID             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 2 octets.

   o  Tunnel ID: 2 octets as defined in [RFC3209].

4.2.  LSP Identifier (LSP ID)

   The LSP Identifier TLV contains the LSP ID defined in [RFC3209] and
   is used for RSVP-TE protocol TE Policies.  It has the following
   format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |            LSP ID             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 2 octets.

   o  LSP ID: 2 octets as defined in [RFC3209].

4.3.  IPv4/IPv6 Tunnel Head-End Address

   The IPv4/IPv6 Tunnel Head-End Address TLV contains the Tunnel Head-
   End Address defined in [RFC3209] and is used for RSVP-TE protocol TE
   Policies.  It has following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //        IPv4/IPv6 Tunnel Head-End Address (variable)         //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 4 or 16 octets.

   When the IPv4/IPv6 Tunnel Head-end Address TLV contains an IPv4
   address, its length is 4 (octets).

   When the IPv4/IPv6 Tunnel Head-end Address TLV contains an IPv6
   address, its length is 16 (octets).

4.4.  IPv4/IPv6 Tunnel Tail-End Address

   The IPv4/IPv6 Tunnel Tail-End Address TLV contains the Tunnel Tail-
   End Address defined in [RFC3209] and is used for RSVP-TE protocol TE
   Policies.  It has following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //        IPv4/IPv6 Tunnel Tail-End Address (variable)         //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 4 or 16 octets.

   When the IPv4/IPv6 Tunnel Tail-end Address TLV contains an IPv4
   address, its length is 4 (octets).

   When the IPv4/IPv6 Tunnel Tail-end Address TLV contains an IPv6
   address, its length is 16 (octets).

4.5.  SR Policy Candidate Path Descriptor

   The SR Policy Candidate Path Descriptor TLV identifies a Segment
   Routing Policy candidate path (CP) as defined in
   [I-D.ietf-spring-segment-routing-policy] and has the following
   format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |Protocol-origin|    Flags      |            RESERVED           |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Endpoint (4 or 16 octets)                //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Policy Color (4 octets)                   |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |               Originator AS Number (4 octets)                 |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |              Originator Address (4 or 16 octets)             //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                    Discriminator (4 octets)                   |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)
   o  Length: variable (valid values are 24, 36 or 48 octets)

   o  Protocol-Origin : 1 octet field which identifies the protocol or
      component which is responsible for the instantiation of this path.
      Following protocol-origin codepoints are defined in this document.

+------------+---------------------------------------------------------+
| Code Point |                   Protocol Origin                       |
+------------+---------------------------------------------------------+
|     1      | PCEP                                                    |
|     2      | BGP SR Policy                                           |
|     3      | Local (via CLI, Yang model through NETCONF, gRPC, etc.) |
+------------+---------------------------------------------------------+

   o  Flags: 1 octet field with following bit positions defined.  Other
      bits SHOULD be cleared by originator and MUST be ignored by
      receiver.

       0 1 2 3 4 5 6 7
      +-+-+-+-+-+-+-+-+
      |E|O|           |
      +-+-+-+-+-+-+-+-+

   where:

      *  E-Flag : Indicates the encoding of endpoint as IPv6 address
         when SET and IPv4 address when CLEAR

      *  O-Flag : Indicates the encoding of originator address as IPv6
         address when SET and IPv4 address when CLEAR

   o  Reserved : 2 octets which SHOULD be set to 0 by originator and
      MUST be ignored by receiver.

   o  Endpoint : 4 or 16 octets (as indicated by the flags) containing
      the address of the endpoint of the SR Policy

   o  Color : 4 octets that indicates the color of the SR Policy

   o  Originator ASN : 4 octets to carry the 4 byte encoding of the ASN
      of the originator.  Refer [I-D.ietf-spring-segment-routing-policy]
      Sec 2.4 for details.

   o  Originator Address : 4 or 16 octets (as indicated by the flags) to
      carry the address of the originator.  Refer
      [I-D.ietf-spring-segment-routing-policy] Sec 2.4 for details.

   o  Discriminator : 4 octets to carry the discrimator of the path.
      Refer [I-D.ietf-spring-segment-routing-policy] Sec 2.5 for
      details.

4.6.  Local MPLS Cross Connect

   The Local MPLS Cross Connect TLV identifies a local MPLS state in the
   form of incoming label and interface followed by an outgoing label
   and interface.  Outgoing interface may appear multiple times (for
   multicast states).  It is used with Protocol ID set to "Static
   Configuration" value 5 as defined in [RFC7752].

   The Local MPLS Cross Connect TLV has the following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Incoming label (4 octets)                 |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Outgoing label (4 octets)                 |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                          Sub-TLVs (variable)                //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable.

   o  Incoming and Outgoing labels: 4 octets each.

   o  Sub-TLVs: following Sub-TLVs are defined:

      *  Interface Sub-TLV

      *  Forwarding Equivalent Class (FEC)

   The Local MPLS Cross Connect TLV:

      MUST have an incoming label.

      MUST have an outgoing label.

      MAY contain an Interface Sub-TLV having the I-flag set.

      MUST contain at least one Interface Sub-TLV having the I-flag
      unset.

      MAY contain multiple Interface Sub-TLV having the I-flag unset.
      This is the case of a multicast MPLS cross connect.

      MAY contain a FEC Sub-TLV.

   The following sub-TLVs are defined for the Local MPLS Cross Connect
   TLV (values TBD see IANA Considerations Section 9.3):

   +-----------+----------------------------------+
   | Codepoint |       Descriptor TLV             |
   +-----------+----------------------------------+
   |  TBD      | MPLS Cross Connect Interface     |
   |  TBD      | MPLS Cross Connect FEC           |
   +-----------+----------------------------------+

   These are defined in the following sub-sections.

4.6.1.  MPLS Cross Connect Interface

   The MPLS Cross Connect Interface sub-TLV is optional and contains the
   identifier of the interface (incoming or outgoing) in the form of an
   IPv4 address or an IPv6 address.

   The MPLS Cross Connect Interface sub-TLV has the following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     +-+-+-+-+-+-+-+-+
     |     Flags     |
     +-+-+-+-+-+-+-+-+

     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |          Local Interface Identifier (4 octets)                |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //         Interface Address (4 or 16 octets)                  //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)
   o  Length: 9 or 21.

   o  Flags: 1 octet of flags defined as follows:

                              0 1 2 3 4 5 6 7
                             +-+-+-+-+-+-+-+-+
                             |I|             |
                             +-+-+-+-+-+-+-+-+

                             where:

      *  I-Flag is the Interface flag.  When set, the Interface Sub-TLV
         describes an incoming interface.  If the I-flag is not set,
         then the Interface Sub-TLV describes an outgoing interface.

   o  Local Interface Identifier: a 4 octet identifier.

   o  Interface address: a 4 octet IPv4 address or a 16 octet IPv6
      address.

4.6.2.  MPLS Cross Connect FEC

   The MPLS Cross Connect FEC sub-TLV is optional and contains the FEC
   associated to the incoming label.

   The MPLS Cross Connect FEC sub-TLV has the following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |   Flags       |  Masklength   |   Prefix (variable)          //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                     Prefix (variable)                       //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable.

   o  Flags: 1 octet of flags defined as follows:

                              0 1 2 3 4 5 6 7
                             +-+-+-+-+-+-+-+-+
                             |4|             |
                             +-+-+-+-+-+-+-+-+

                             where:

      *  4-Flag is the IPv4 flag.  When set, the FEC Sub-TLV describes
         an IPv4 FEC.  If the 4-flag is not set, then the FEC Sub-TLV
         describes an IPv6 FEC.

   o  Mask Length: 1 octet of prefix length.

   o  Prefix: an IPv4 or IPv6 prefix whose mask length is given by the "
      Mask Length" field.

5.  MPLS-TE Policy State TLV

   A new TLV called "MPLS-TE Policy State TLV", is used to describe the
   characteristics of the MPLS-TE Policy and it is carried in the
   optional non-transitive BGP Attribute "LINK_STATE Attribute" defined
   in [RFC7752].  These MPLS-TE Policy characteristics include the
   characteristics and attributes of the policy, it's dataplane,
   explicit path, Quality of Service (QoS) parameters, route
   information, the protection mechanisms, etc.

   The MPLS-TE Policy State TLV has the following format:

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |              Type             |             Length            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |  Path-origin  |   Dataplane   |            RESERVED           |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //        MPLS-TE Policy State Objects (variable)              //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

                         MPLS-TE Policy State TLV

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: the total length of the MPLS-TE Policy State TLV not
      including Type and Length fields.

   o  Path-origin: identifies the component (or protocol) from which the
      contained object originated.  This allows for objects defined in
      different components to be collected while avoiding the possible
      codepoint collisions among these components.  Following path-
      origin codepoints are defined in this document.

               +----------+------------------+
               |  Code    |     Path         |
               |  Point   |     Origin       |
               +----------+------------------+
               |    1     | RSVP-TE          |
               |    2     | PCEP             |
               |    3     | Local/Static     |
               +----------+------------------+

   o  Dataplane: describes to which dataplane the policy is applied to.
      The following dataplane values are defined in this document:

               +----------+------------------+
               |  Code    |    Dataplane     |
               |  Point   |                  |
               +----------+------------------+
               |    1     | MPLS-IPv4        |
               |    2     | MPLS-IPv6        |
               +----------+------------------+

   o  RESERVED: 16-bit field.  SHOULD be set to 0 on transmission and
      MUST be ignored on receipt.

   o  TE Policy State Objects: Rather than replicating all these objects
      in this document, the semantics and encodings of the objects as
      defined in RSVP-TE and PCEP are reused.

   The state information is carried in the "MPLS-TE Policy State
   Objects" with the following format as described in the sub-sections
   below.

5.1.  RSVP Objects

   RSVP-TE objects are encoded in the "MPLS-TE Policy State Objects"
   field of the MPLS-TE Policy State TLV and consists of MPLS TE LSP
   objects defined in RSVP-TE [RFC3209] [RFC3473].  Rather than
   replicating all MPLS TE LSP related objects in this document, the
   semantics and encodings of the MPLS TE LSP objects are re-used.
   These MPLS TE LSP objects are carried in the MPLS-TE Policy State
   TLV.

   When carrying RSVP-TE objects, the "Path-Origin" field is set to
   "RSVP-TE".

   The following RSVP-TE Objects are defined:

   o  SENDER_TSPEC and FLOW_SPEC [RFC2205]

   o  SESSION_ATTRIBUTE [RFC3209]

   o  EXPLICIT_ROUTE Object (ERO) [RFC3209]

   o  ROUTE_RECORD Object (RRO) [RFC3209]

   o  FAST_REROUTE Object [RFC4090]

   o  DETOUR Object [RFC4090]

   o  EXCLUDE_ROUTE Object (XRO) [RFC4874]

   o  SECONDARY_EXPLICIT_ROUTE Object (SERO) [RFC4873]

   o  SECONDARY_RECORD_ROUTE (SRRO) [RFC4873]

   o  LSP_ATTRIBUTES Object [RFC5420]

   o  LSP_REQUIRED_ATTRIBUTES Object [RFC5420]

   o  PROTECTION Object [RFC3473][RFC4872][RFC4873]

   o  ASSOCIATION Object [RFC4872]

   o  PRIMARY_PATH_ROUTE Object [RFC4872]

   o  ADMIN_STATUS Object [RFC3473]

   o  LABEL_REQUEST Object [RFC3209][RFC3473]

   For the MPLS TE LSP Objects listed above, the corresponding sub-
   objects are also applicable to this mechanism.  Note that this list
   is not exhaustive, other MPLS TE LSP objects which reflect specific
   characteristics of the MPLS TE LSP can also be carried in the LSP
   state TLV.

5.2.  PCEP Objects

   PCEP objects are encoded in the "MPLS-TE Policy State Objects" field
   of the MPLS-TE Policy State TLV and consists of PCEP objects defined
   in [RFC5440].  Rather than replicating all MPLS TE LSP related
   objects in this document, the semantics and encodings of the MPLS TE
   LSP objects are re-used.  These MPLS TE LSP objects are carried in
   the MPLS-TE Policy State TLV.

   When carrying PCEP objects, the "Path-Origin" field is set to "PCEP".

   The following PCEP Objects are defined:

   o  METRIC Object [RFC5440]

   o  BANDWIDTH Object [RFC5440]

   For the MPLS TE LSP Objects listed above, the corresponding sub-
   objects are also applicable to this mechanism.  Note that this list
   is not exhaustive, other MPLS TE LSP objects which reflect specific
   characteristics of the MPLS TE LSP can also be carried in the TE
   Policy State TLV.

6.  SR Policy State TLVs

   Segment Routing Policy (SR Policy) architecture is specified in
   [I-D.ietf-spring-segment-routing-policy].  A SR Policy can comprise
   of one or more candidate paths (CP) of which at a given time one and
   only one may be active (i.e. installed in forwarding and usable for
   steering of traffic).  Each CP in turn may have one or more SID-List
   of which one or more may be active; when multiple are active then
   traffic is load balanced over them.

   This section defines the various TLVs which enable the headend to
   report the state of an SR Policy, its CP(s), SID-List(s) and their
   status.  These TLVs are carried in the optional non-transitive BGP
   Attribute "LINK_STATE Attribute" defined in [RFC7752] and enable the
   same consistent form of reporting for SR Policy state irrespective of
   the Protocol-Origin used to provision the policy.  Detailed procedure
   is described in Section 7 .

6.1.  SR Binding SID

   The SR Binding SID (BSID) TLV provides the BSID and its attributes
   for the SR Policy CP.  The TLV MAY also optionally contain the
   Provisioned BSID value for reporting when explicitly provisioned.

   The TLV has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              Type             |             Length            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |           BSID Flags          |            RESERVED           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                   Binding SID (4 or 16 octets)               //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |       Provisioned Binding SID (optional, 4 or 16 octets)     //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable (valid values are 12, 16, 24 or 40 octets)

   o  BSID Flags: 2 octet field that indicates attribute and status of
      the Binding SID (BSID) associated with this CP.  The following bit
      positions are defined and the semantics are described in detail in
      [I-D.ietf-spring-segment-routing-policy].  Other bits SHOULD be
      cleared by originator and MUST be ignored by receiver.

       0                   1
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |D|B|U|S|L|F|                   |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

      *  D-Flag : Indicates the dataplane for the BSIDs and if they are
         16 octet SRv6 SID when SET and are 4 octet SR/MPLS label value
         when CLEAR.

      *  B-Flag : Indicates the allocation of the value in the BSID
         field when SET and indicates that BSID is not allocated when
         CLEAR.

      *  U-Flag : Indicates the provisioned BSID value is unavailable
         when SET.

      *  S-Flag : Indicates the BSID value in use is specified or
         provisioned value when SET and dynamically allocated value when
         CLEAR.

      *  L-Flag : Indicates the BSID value is from the Segment Routing
         Local Block (SRLB) of the headend node when SET and is from the
         local label pool when CLEAR

      *  F-Flag : Indicates the BSID value is one allocated from dynamic
         range due to fallback (e.g. when specified BSID is unavailable)
         when SET.

   o  RESERVED: 2 octets.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  Binding SID: It indicates the operational or allocated BSID value
      for the CP based on the status flags.

   o  Provisioned BSID: Optional field used to report the explicitly
      provisioned BSID value as indicated by the S-Flag being SET.

   The BSID fields above are 4 octet carrying the MPLS Label or 16
   octets carrying the SRv6 SID based on the BSID D-flag.  When carrying
   the MPLS Label, as shown in the figure below, the TC, S and TTL
   (total of 12 bits) are RESERVED and SHOULD be set to 0 by originator
   and MUST be ignored by the receiver.

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |          Label                        | TC  |S|       TTL     |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

6.2.  SR Candidate Path State

   The SR Candidate Path (CP) State TLV provides the operational status
   and attributes of the SR Policy at the CP level.  The TLV has the
   following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              Type             |             Length            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   Priority    |   RESERVED    |              Flags            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                      Preference (4 octets)                    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 12 octets

   o  Priority : 1 octet value which indicates the priority of the CP

   o  RESERVED: 1 octet.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  Flags: 2 octet field that indicates attribute and status of the
      CP.  The following bit positions are defined and the semantics are
      described in detail in [I-D.ietf-spring-segment-routing-policy].
      Other bits SHOULD be cleared by originator and MUST be ignored by
      receiver.

       0                   1
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |S|A|B|E|V|O|D|C|I|T|           |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

      *  S-Flag : Indicates the CP is in administrative shut state when
         SET

      *  A-Flag : Indicates the CP is the active path (i.e. one
         provisioned in the forwarding plane) for the SR Policy when SET

      *  B-Flag : Indicates the CP is the backup path (i.e. one
         identified for path protection of the active path) for the SR
         Policy when SET

      *  E-Flag : Indicates that the CP has been evaluated for validity
         (e.g. headend may evaluate CPs based on their preferences) when
         SET

      *  V-Flag : Indicates the CP has at least one valid SID-List when
         SET

      *  O-Flag : Indicates the CP was instantiated by the headend due
         to an on-demand-nexthop trigger based on local template when
         SET

      *  D-Flag : Indicates the CP was delegated for computation to a
         PCE/controller when SET

      *  C-Flag : Indicates the CP was provisioned by a PCE/controller
         when SET

      *  I-Flag : Indicates the CP will perform the "drop upon invalid"
         behavior when no other active path is available for this SR
         Policy and this path is the one with best preference amongst
         the available CPs.

      *  T-Flag : Indicates the CP has been marked as eligible for use
         as Transit Policy on the headend when SET

   o  Preference : 4 octet value which indicates the preference of the
      CP

6.3.  SR Candidate Path Name

   The SR Candidate Path Name TLV is an optional TLV that is used to
   carry the symbolic name associated with the candidate path.  The TLV
   has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |          Candidate Path Symbolic Name (variable)             //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable

   o  CP Name : Symbolic name for the CP.  It is a string of printable
      ASCII characters without a NULL terminator.

6.4.  SR Candidate Path Constraints

   The SR Candidate Path Constraints TLV is an optional TLV that is used
   to report the contraints associated with the candidate path.  The
   constraints are generally applied to a dynamic candidate path which
   is computed by the headend.  The constraints may also be applied to
   an explicit path where the headend is expected to validate that the
   path expresses satisfies the specified constraints and the path is to
   be invalidated by the headend when the constraints are no longer met
   (e.g. due to topology changes).

   The TLV has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              Flags            |   Algorithm   |    RESERVED   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   sub-TLVs (variable)                                        //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable

   o  Flags: 2 octet field that indicates the constraints that are being
      applied to the CP.  The following bit positions are defined and
      the other bits SHOULD be cleared by originator and MUST be ignored
      by receiver.

       0                   1
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |D|P|U|A|                       |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

      *  A-Flag : Indicates that the CP needs to use SRv6 dataplane when
         SET and SR/MPLS dataplane when CLEAR

      *  P-Flag : Indicates that the CP needs to use only protected SIDs
         when SET

      *  U-Flag : Indicates that the CP needs to use only unprotected
         SIDs when SET

      *  A-Flag : Indicates that the CP needs to use the SIDs belonging
         to the specified SR Algorithm only when SET

   o  Algorithm : Indicates the algorithm that is preferred to be used
      when the path is setup.  When the A-flag is SET then the path is
      strictly using the specified algorithm SIDs only.

   o  RESERVED: 1 octet.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  sub-TLVs: optional sub-TLVs MAY be included in this TLV to
      describe other constraints.

   The following constraint sub-TLVs are defined for the SR CP
   Constraints TLV.

6.4.1.  SR Affinity Constraint

   The SR Affinity Constraint sub-TLV is an optional sub-TLV that is
   used to carry the affinity constraints [RFC2702] associated with the
   candidate path.  The affinity is expressed in terms of Extended Admin
   Group (EAG) as defined in [RFC7308].  The TLV has the following
   format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   | Excl-Any-Size | Incl-Any-Size | Incl-All-Size |    RESERVED   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Exclude-Any EAG (optional, variable)             //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Include-Any EAG (optional, variable)             //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Include-All EAG (optional, variable)             //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable, dependent on the size of the Extended Admin
      Group.  MUST be a multiple of 4 octets.

   o  Exclude-Any-Size : one octet to indicate the size of Exclude-Any
      EAG bitmask size in multiples of 4 octets. (e.g.  value 0
      indicates the Exclude-Any EAG field is skipped, value 1 indicates
      that 4 octets of Exclude-Any EAG is included)

   o  Include-Any-Size : one octet to indicate the size of Include-Any
      EAG bitmask size in multiples of 4 octets. (e.g.  value 0
      indicates the Include-Any EAG field is skipped, value 1 indicates
      that 4 octets of Include-Any EAG is included)

   o  Include-All-Size : one octet to indicate the size of Include-All
      EAG bitmask size in multiples of 4 octets. (e.g.  value 0
      indicates the Include-All EAG field is skipped, value 1 indicates
      that 4 octets of Include-All EAG is included)

   o  RESERVED: 1 octet.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  Exclude-Any EAG : the bitmask used to represent the affinities to
      be excluded from the path.

   o  Include-Any EAG : the bitmask used to represent the affinities to
      be included in the path.

   o  Include-All EAG : the bitmask used to represent the all affinities
      to be included in the path.

6.4.2.  SR SRLG Constraint

   The SR SRLG Constraint sub-TLV is an optional sub-TLV that is used to
   carry the Shared Risk Link Group (SRLG) values [RFC4202] that are
   instantiated into various forms: to
   be excluded from the candidate path.  The TLV has the following
   format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |         SRLG Values (variable, multiples of 4 octets)        //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable, dependent on the number of SRLGs encoded.  MUST
      be a multiple of 4 octets.

   o  SRLG Values : One or more SRLG values (each of 4 octets).

6.4.3.  SR Bandwidth Constraint

   The SR Bandwidth Constraint sub-TLV is an optional sub-TLV that is
   used to indicate the desired bandwidth availability that needs to be
   ensured for the candidate path.  The TLV has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                          Bandwidth                            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  MPLS Traffic Engineering Label Switched Paths (TE-LSPs).  Type: TBD (see IANA Considerations Section 9.3)

   o  IP based tunnels (IP in IP, GRE, etc).  Length: 8 octects

   o  Segment Routing Traffic Engineering Policies (SR TE Policy) as
      defined  Bandwidth : 4 octets which specify the desired bandwidth in [I-D.previdi-idr-segment-routing-te-policy]

   o  Local cross-connect configuration

   All this information can be grouped into unit
      of bytes per second in IEEE floating point format.

6.4.4.  SR Disjoint Group Constraint

   The SR Disjoint Group Constraint sub-TLV is an optional sub-TLV that
   is used to carry the disjointness constraint associated with the
   candidate path.  The disjointness between two SR Policy Candidate
   Paths is expressed by associating them with the same term: TE Policies.
   In disjoint group
   identifier and then specifying the rest type of this document we refer disjointness required
   between their paths.  The computation is expected to TE Policies as achieve the set
   highest level of
   information related disjointness requested and when that is not possible
   then fallback to a lesser level progressively based on the levels
   indicated.

   The TLV has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |               Type            |              Length           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   | Request-Flags |  Status-Flags |            RESERVED           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                 Disjoint Group Identifier                     |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: 12 octets
   o  Request Flags : one octet to indicate the various instantiation level of polices: MPLS TE
   LSPs, IP tunnels (IPv4 or IPv6), SR TE Policies, etc.

   TE Polices are generally instantiated by disjointness
      requested as specified in the head-end and are based
   on either local configuration or controller based programming form of the
   node using various protocols flags.  The following flags
      are defined and APIs, e.g., PCEP or BGP.

   In many network environments, the configuration other bits SHOULD be cleared by originator and state of each TE
   Policy
      MUST be ignored by receiver.

       0 1 2 3 4 5 6 7
      +-+-+-+-+-+-+-+-+
      |S|N|L|F|I|     |
      +-+-+-+-+-+-+-+-+

   where:

      *  S-Flag : Indicates that SRLG disjointness is available in the network requested

      *  N-Flag : Indicates that node disjointness is required by a controller
   which allows requested when

      *  L-Flag : Indicates that link disjointness is requested when

      *  F-Flag : Indicates that the network operator computation may fallback to optimize several functions and
   operations through the use of a controller aware of both topology and
   state information.

   One example lower
         level of a controller is disjointness amongst the stateful Path Computation Element
   (PCE) [I-D.ietf-pce-stateful-pce], which could provide benefits in ones requested when all
         cannot be achieved

      *  I-Flag : Indicates that the computation may fallback to the
         default best path reoptimization.  While some extensions are proposed (e.g.  IGP path) in Path
   Computation Element Communication Protocol (PCEP) for case of none of the Path
   Computation Clients (PCCs)
         desired disjointness can be achieved.

   o  Status Flags : one octet to report indicate the LSP states to level of disjointness
      that has been achieved by the PCE, this
   mechanism may not be applicable in a management-based PCE
   architecture computation as specified in section 5.5 of [RFC4655].  As
   illustrated in the figure below, form
      of flags.  The following flags are defined and the PCC other bits
      SHOULD be cleared by originator and MUST be ignored by receiver.

       0 1 2 3 4 5 6 7
      +-+-+-+-+-+-+-+-+
      |S|N|L|F|I|X|   |
      +-+-+-+-+-+-+-+-+

   where:

      *  S-Flag : Indicates that SRLG disjointness is not an LSR in the routing
   domain, thus achieved

      *  N-Flag : Indicates that node disjointness is achieved

      *  L-Flag : Indicates that link disjointness is achieved

      *  F-Flag : Indicates that the head-end nodes computation has fallen back to a
         lower level of disjointness that requested.

      *  I-Flag : Indicates that the TE-LSPs may computation has fallen back to the
         best path (e.g.  IGP path) and disjointness has not implement been
         achieved

      *  X-Flag : Indicates that the
   PCEP protocol.  In this case a general mechanism disjointness constraint could not
         be achieved and hence path has been invalidated

   o  RESERVED: 2 octets.  SHOULD be set to collect the TE-
   LSP states from 0 by originator and MUST be
      ignored by receiver.

   o  Disjointness Group Identifier : 4 octet value that is the ingress LERs group
      identifier for a set of disjoint paths

6.5.  SR Segment List

   The SR Segment List TLV is needed.  This document proposes
   an TE Policy state collection mechanism complementary used to report the
   mechanism defined in [I-D.ietf-pce-stateful-pce].

                                   -----------
                                  |   -----   |
              Service             |  | TED |<-+----------->
              Request             |   -----   |  TED synchronization
                 |                |     |     |  mechanism (for example,
                 v                |     |     |  routing protocol)
           ------------- Request/ |     v     |
          |             | Response|   -----   |
          |     NMS     |<--------+> | PCE |  |
          |             | SID-List(s) of a
   candidate path.  The TLV has following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   -----              Type             |
           -------------           -----------
         Service             Length            |
         Request
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |
                 v
            ----------  Signaling   ----------              Flags            | Head-End   Algorithm   | Protocol    RESERVED   | Adjacent
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                        Weight (4 octets)                      |  Node    |<---------->|   Node
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |
            ----------              ----------

                 Figure 1.  Management-Based PCE Usage

   In networks with composite PCE nodes as specified in section 5.1 of
   [RFC4655], PCE is implemented on several routers in the network,   sub-TLVs (variable)                                        //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable

   o  Flags: 1 octet field that indicates attribute and status of the PCCs in the network can use
      SID-List.The following bit positions are defined and the mechanism semantics
      are described in
   [I-D.ietf-pce-stateful-pce] to report the TE Policy information to
   the PCE nodes.  An external component may also need to collect the TE
   Policy information from all the PCEs detail in
      [I-D.ietf-spring-segment-routing-policy].  Other bits SHOULD be
      cleared by originator and MUST be ignored by receiver.

       0                   1
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |D|E|C|V|R|C|A|                 |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

      *  D-Flag : Indicates the network to obtain a
   global view SID-List is comprised of the LSP state in the network.

   In multi-area or multi-AS scenarios, each area or AS can have a child
   PCE to collect the TE Policies in its own domain, in addition, a
   parent PCE needs to collect TE Policy information from multiple child
   PCEs to obtain a global view SRv6 SIDs when
         SET and indicates it is comprised of LSPs inside SR/MPLS labels when CLEAR.

      *  E-Flag : Indicates that SID-List is an explicit path when SET
         and across the domains
   involved.

   In another network scenario, indicates dynamic path when CLEAR.

      *  C-Flag : Indicates that SID-List has been computed for a centralized controller
         dynamic path when SET.  It is used always reported as SET for
   service placement.  Obtaining
         explicit paths.

      *  V-Flag : Indicates the TE Policy state information is
   quite important SID-List has passed verification or its
         verification was not required when SET and failed verification
         when CLEAR.

      *  R-Flag : Indicates that the first Segment has been resolved
         when SET and failed resolution when CLEAR.

      *  C-Flag : Indicates that the computation for making appropriate service placement decisions
   with the purpose dynamic path
         failed when SET and succeeded (or not required in case of
         explicit path) when CLEAR

      *  A-Flag : Indicates that all the SIDs in the SID-List belong to both meet
         the application's requirements and
   utilize network resources efficiently.

   The Network Management System (NMS) may need specified algorithm when SET.

   o  RESERVED: 1 octet.  SHOULD be set to provide global
   visibility 0 by originator and MUST be
      ignored by receiver.

   o  Algorithm: 1 octet that indicates the algorithm of the TE Policies SIDs used
      in the network as part of the network
   visualization function.

   BGP has been extended to distribute link-state and traffic
   engineering information to external components [RFC7752].  Using SID-List when the
   same protocol to collect Traffic Engineering and Policy information A-flag is desirable for these external components since this avoids
   introducing multiple protocols SET.

   o  Weight: 4 octet field that indicates the weight associated with
      the SID-List for network information collection.
   This document describes a mechanism to distribute traffic engineering
   and policy information (MPLS, IPv4 weighted load-balancing

   o  Sub-TLVs : variable and IPv6) to external components
   using BGP-LS.

2.  Carrying TE Policy Information in BGP

2.1.  TE Policy Information

   TE Policy information is advertised in BGP UPDATE messages using contains the
   MP_REACH_NLRI ordered set of Segments and MP_UNREACH_NLRI
      any other optional attributes [RFC4760]. associated with the specific SID-
      List.

   The "Link-
   State NLRI" defined SR Segment sub-TLV (defined in [RFC7752] Section 6.6) is extended to carry the TE Policy
   information.  BGP speakers that wish to exchange TE Policy
   information MUST only currently
   defined sub-TLV for use with the BGP Multiprotocol Extensions Capability Code
   (1) to advertise the corresponding (AFI, SAFI) pair, SR Segment List TLV and it MUST be
   included as specified in
   [RFC4760].  A new an ordered set of sub-TLVs within the SR Segment List TLV carried in
   when the Link_State Attribute defined in
   [RFC7752] SID-List is also defined not empty.  A SID-List may be empty in order to carry the attributes of certain
   cases (e.g. for a TE
   Policy (Section 2.3). dynamic path) where the headend has not yet
   performed the computation and hence not derived the segments required
   for the path; in such cases, the SR Segment List TLV SHOULD NOT
   include any SR Segment sub-TLVs.

6.6.  SR Segment

   The format SR Segment sub-TLV describes a single segment in a SID-List.  One
   or more instances of "Link-State NLRI" is defined this sub-TLV in [RFC7752].  A new "NLRI
   Type" is defined an ordered manner constitute a
   SID-List for TE Policy Information as following:

   o  NLRI Type: TE a SR Policy NLRI (suggested codepoint value 5, to be
      assigned by IANA).

   [RFC7752] defines candidate path.  It is a sub-TLV of the BGP-LS NLRI as follows: SR
   Segment List TLV and has following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |            NLRI              Type             |     Total NLRI             Length            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   | Segment Type  |    RESERVED   |             Flags             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                   SID (4 or 16 octets)                       //                  Link-State NLRI
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                   SID Descriptor (variable)                 //
     |                                                               |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   This document defines a new NLRI-Type
   //   Sub-TLVs (variable)                                       //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable

   o  Segment Type : 1 octet which indicates the type of segment (refer
      Section 6.6.1 for details)

   o  RESERVED: 1 octet.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  Flags: 2 octet field that indicates attribute and status of the
      Segment and its format: SID.  The following bit positions are defined and
      the semantics are described in detail in
      [I-D.ietf-spring-segment-routing-policy].  Other bits SHOULD be
      cleared by originator and MUST be ignored by receiver.

       0                   1
       0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
      |S|E|V|R|A|                     |
      +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

      *  S-Flag : Indicates the presence of SID value in the SID field
         when SET and that no value is indicated when CLEAR.

      *  E-Flag : Indicates the SID value is explicitly provisioned
         value (locally on headend or via controller/PCE) when SET and
         is a dynamically resolved value by headend when CLEAR

      *  V-Flag : Indicates the SID has passed verification or did not
         require verification when SET and failed verification when
         CLEAR.

      *  R-Flag : Indicates the SID has been resolved or did not require
         resolution (e.g. because it is not the first SID) when SET and
         failed resolution when CLEAR.

      *  A-Flag : Indicates that the Algorithm indicated in the Segment
         descriptor is valid when SET.  When CLEAR, it indicates that
         the headend is unable to determine the algorithm of the SID.

   o  SID : 4 octet carrying the MPLS Label or 16 octets carrying the
      SRv6 SID based on the TE Policy
   NLRI defined F-flag.  When carrying the MPLS Label, as
      shown in the following section.

2.2.  TE Policy NLRI

   The TE Policy NLRI (NLRI Type 5.  Suggested value, figure below, the TC, S and TTL (total of 12 bits)
      are RESERVED and SHOULD be set to 0 by originator and MUST be assigned
      ignored by
   IANA) is shown in the following figure: receiver.

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+
     |  Protocol-ID  |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                        Identifier                             |          Label                        |                        (64 bits) TC  |S|       TTL     |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                Headend (Node Descriptors)                   //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                TE Policy Descriptors (variable)             //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Protocol-ID field specifies  SID Descriptor : variable size SID descriptor based on the component that owns type of
      segment (refer Section 6.6.1 for details)

   o  Sub-Sub-TLVs : variable and contains any other optional attributes
      associated with the TE Policy
      state specific SID-List.

   Currently no Sub-Sub-TLV of the SR Segment sub-TLV is defined.

6.6.1.  Segment Descriptors

   [I-D.ietf-spring-segment-routing-policy] section 4 defines multiple
   types of segments and their description.  This section defines the
   encoding of the Segment Descriptors for each of those Segment types
   to be used in the advertising node. Segment sub-TLV describes previously in
   Section 6.6.

   The following Protocol-IDs types are currently defined (suggested values, to be
   assigned by IANA) and apply to
      the TE Policy NLRI:

               +-------------+----------------------------------+ IANA):

+-------+--------------------------------------------------------------+
| Protocol-ID Type  | NLRI information source protocol   Segment Description                                        |
               +-------------+----------------------------------+
+-------+--------------------------------------------------------------+
|      8   0   |   RSVP-TE Invalid                                                      |
|      9   1   |   Segment Routing SR-MPLS Label                                                |
               +-------------+----------------------------------+

   o  "Identifier" is an 8 octet value
|   2   | SRv6 SID as defined in [RFC7752].

   o  "Headend" consists of a IPv6 address                                     |
|   3   | SR-MPLS Prefix SID as IPv4 Node Descriptor defined in [RFC7752].

   o  "TE Policy Descriptors" consists of:

   +-----------+----------------------------------+ Address                      | Codepoint
|       Descriptor TLV   4   | SR-MPLS Prefix SID as IPv6 Node Global Address               |
|   5   | SR-MPLS Adjacency SID as IPv4 Node Address & Local           |
|       | Interface ID                                                 |
|   6   | SR-MPLS Adjacency SID as IPv4 Local & Remote Interface       |
|       | Addresses                                                    |
|   7   | SR-MPLS Adjacency SID as pair of IPv6 Global Address &       |
   +-----------+----------------------------------+
|  267       | Tunnel Interface ID for Local & Remote nodes                        |
|  268   8   | LSP ID SR-MPLS Adjacency SID as pair of IPv6 Global Addresses for   |
|  269       | IPv4/6 Tunnel Head-end address the Local & Remote Interface                                 |
|  270   9   | IPv4/6 Tunnel Tail-end address SRv6 END SID as IPv6 Node Global Address                     |
|  271  10   | SR TE Policy SRv6 END.X SID as pair of IPv6 Global Address & Interface ID |
|  272       | for Local Cross Connect & Remote nodes                                     |
   +-----------+----------------------------------+

2.2.1.  TE Policy Descriptors

   This sections defines
|  11   | SRv6 END.X SID as pair of IPv6 Global Addresses for the TE Policy Descriptors TLVs.

2.2.1.1.  Tunnel Identifier (Tunnel ID)      |
|       | Local & Remote Interface                                     |
+-------+--------------------------------------------------------------+

6.6.1.1.  Type 1: SR-MPLS Label

   The Tunnel Identifier TLV contains the Tunnel ID defined in [RFC3209] Segment is SR-MPLS type and has is specified simply as the following format: label.
   The format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   +-+-+-+-+-+-+-+-+
   |         Tunnel ID   Algorithm   |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 267)

   o  Length: 2 octets.
   +-+-+-+-+-+-+-+-+

   Where:

   o  Tunnel ID: 2 octets as defined in [RFC3209].

2.2.1.2.  LSP Identifier (LSP ID)

   The LSP Identifier TLV contains  Algorithm: 1 octet value that indicates the LSP ID defined algorithm used for
      picking the SID.  This is valid only when the A-flag has been SET
      in [RFC3209] the Segment TLV.

6.6.1.2.  Type 2: SRv6 SID

   The Segment is SRv6 type and
   has is specified simply as the following format: SRv6 SID
   address.  The format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   +-+-+-+-+-+-+-+-+
   |            LSP ID   Algorithm   |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 268)

   o  Length: 2 octets.
   +-+-+-+-+-+-+-+-+

   Where:

   o  LSP ID: 2 octets as defined in [RFC3209].

2.2.1.3.  IPv4/IPv6 Tunnel Head-End Address

   The IPv4/IPv6 Tunnel Head-End Address TLV contains  Algorithm: 1 octet value that indicates the algorithm used for
      picking the SID.  This is valid only when the Tunnel Head-
   End Address defined A-flag has been SET
      in [RFC3209] the Segment TLV.

6.6.1.3.  Type 3: SR-MPLS Prefix SID for IPv4

   The Segment is SR-MPLS Prefix SID type and has following format: is specified as an IPv4
   node address.  The format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type
   +-+-+-+-+-+-+-+-+
   |          Length   Algorithm   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //        IPv4/IPv6 Tunnel Head-End
   |                 IPv4 Node Address (variable)         // (4 octets)                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   Where:

   o  Type: To be assigned by IANA (suggested value: 269)  Algorithm: 1 octet value that indicates the algorithm used for
      picking the SID

   o  Length:  IPv4 Node Address: 4 or 16 octets.

   When octet value which carries the IPv4/IPv6 Tunnel Head-end Address TLV contains an IPv4
   address, its length is 4 (octets).

   When address
      associated with the IPv4/IPv6 Tunnel Head-end Address TLV contains node

6.6.1.4.  Type 4: SR-MPLS Prefix SID for IPv6

   The Segment is SR-MPLS Prefix SID type and is specified as an IPv6
   address,
   global address.  The format of its length Segment Descriptor is 16 (octets).

2.2.1.4.  IPv4/IPv6 Tunnel Tail-End Address

   The IPv4/IPv6 Tunnel Tail-End Address TLV contains the Tunnel Tail-
   End Address defined in [RFC3209] and has following format: as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |             Type
   +-+-+-+-+-+-+-+-+
   |          Length   Algorithm   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //        IPv4/IPv6 Tunnel Tail-End
   |          IPv6 Node Global Address (variable)         // (16 octets)                 |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   Where:

   o  Type: To be assigned by IANA (suggested value: 270)  Algorithm: 1 octet value that indicates the algorithm used for
      picking the SID

   o  Length: 4 or  IPv6 Node Global Address: 16 octets.

   When octet value which carries the IPv4/IPv6 Tunnel Tail-end Address TLV contains an IPv6
      global address associated with the node

6.6.1.5.  Type 5: SR-MPLS Adjacency SID for IPv4
   address, its length with Interface ID

   The Segment is 4 (octets).

   When the IPv4/IPv6 Tunnel Tail-end Address TLV contains SR-MPLS Adjacency SID type and is specified as an IPv6
   address, IPv4
   node address along with the local interface ID on that node.  The
   format of its length Segment Descriptor is 16 (octets).

2.2.1.5.  SR TE Policy TLV

   The SR TE Policy TLV identifies a SR TE Policy as defined in
   [I-D.previdi-idr-segment-routing-te-policy] and has the following
   format: follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Distinguisher (4 octets)                  |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Policy Color                 IPv4 Node Address (4 octets)                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                     Endpoint                Local Interface ID (4 or 16 octets)                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 271)

   Where:

   o  Length: 12 octets.  IPv4 Node Address: 4 octet value which carries the IPv4 address
      associated with the node

   o  Distinguisher, Policy Color and Endpoint are defined in
      [I-D.previdi-idr-segment-routing-te-policy].

2.2.1.6.  MPLS Cross Connect

   The MPLS Cross Connect TLV identifies a local MPLS state in  Local Interface ID : 4 octet value which carries the form
   of incoming label and local
      interface followed ID of the node identified by an outgoing label the Node Address

6.6.1.6.  Type 6: SR-MPLS Adjacency SID for IPv4 with Interface Address

   The Segment is SR-MPLS Adjacency SID type and
   interface.  Outgoing interface may appear multiple times (for
   multicast states). is specified as a pair
   of IPv4 local and remote addresses.  The Local Cross Connect TLV has the following format: format of its Segment
   Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                     Incoming label                IPv4 Local Address (4 octets)                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                     Outgoing label               IPv4 Remote Address (4 octets)                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                          Sub-TLVs (variable)                //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 271)

   o  Length: variable.

   Where:

   o  Incoming and Outgoing labels:  IPv4 Local Address: 4 octets each.

   o  Sub-TLVs: following Sub-TLVs are defined:

      *  Interface Sub-TLV

      *  Forwarding Equivalent Class (FEC)

   The MPLS Cross Connect TLV:

      MUST have an incoming label.

      MUST have an outgoing label.

      MAY contain an Interface Sub-TLV having octet value which carries the I-flag set.

      MUST contain at least one Interface Sub-TLV having local IPv4
      address associated with the I-flag
      unset.

      MAY contain multiple Interface Sub-TLV having node

   o  IPv4 Remote Address: 4 octet value which carries the I-flag unset. remote IPv4
      address associated with the node's neighbor.  This is the case of a multicast MPLS cross connect. optional and
      MAY contain a FEC Sub-TLV.

2.2.1.6.1.  MPLS Cross Connect Sub-TLVs
2.2.1.6.1.1.  Interface Sub-TLV be set to 0 when not used (e.g. when identifying point-to-
      point links).

6.6.1.7.  Type 7: SR-MPLS Adjacency SID for IPv6 with interface ID

   The Interface sub-TLV Segment is optional SR-MPLS Adjacency SID type and contains the identifier of the
   interface (incoming or outgoing) in the form is specified as a pair
   of an IPv4 address or an IPv6 address. global address and interface ID for local and remote nodes.
   The Interface sub-TLV has the following format: format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     +-+-+-+-+-+-+-+-+
     |     Flags          IPv6 Local Node Global Address (16 octets)           |
     +-+-+-+-+-+-+-+-+
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |          Local Node Interface Identifier ID (4 octets)                   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //         Interface
   |          IPv6 Remote Node Global Address (16 octets)          |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |          Remote Node Interface ID (4 or 16 octets)                  //                  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 1)

   Where:

   o  Length: 9 or 21.  IPv6 Local Node Global Address: 16 octet value which carries the
      IPv6 global address associated with the local node

   o  Flags: 1  Local Node Interface ID : 4 octet value which carries the
      interface ID of flags defined as follows:

                              0 1 2 3 4 5 6 7
                             +-+-+-+-+-+-+-+-+
                             |I|             |
                             +-+-+-+-+-+-+-+-+

                             where:

      *  I-Flag is the Interface flag.  When set, local node identified by the Interface Sub-TLV
         describes an incoming interface.  If Local Node
      Address

   o  IPv6 Remote Node Global Address: 16 octet value which carries the
      IPv6 global address associated with the I-flag remote node.  This is
      optional and MAY be set to 0 when not set,
         then the Interface Sub-TLV describes an outgoing interface.

   o  Local Interface Identifier: a 4 octet identifier. used (e.g.  when identifying
      point-to-point links).

   o  Remote Node Interface address: a ID : 4 octet IPv4 address or a 16 octet IPv6
      address.

2.2.1.6.1.2.  Forwarding Equivalent Class (FEC) Sub-TLV

   The FEC sub-TLV value which carries the
      interface ID of the remote node identified by the Remote Node
      Address.  This is optional and contains the FEC associated MAY be set to the
   incoming label. 0 when not used (e.g.
      when identifying point-to-point links).

6.6.1.8.  Type 8: SR-MPLS Adjacency SID for IPv6 with interface address

   The FEC sub-TLV has the following format: Segment is SR-MPLS Adjacency SID type and is specified as a pair
   of IPv6 Global addresses for local and remote interface addresses.
   The format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |             Type              |          Length               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |   Flags       |  Masklength        Global IPv6 Local Interface Address (16 octets)        |   Prefix (variable)          //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //                     Prefix (variable)                       //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

   o  Type: To be assigned by IANA (suggested value: 2)

   o  Length: variable.

   o  Flags: 1 octet of flags defined as follows:

                              0 1 2 3 4 5 6 7
                             +-+-+-+-+-+-+-+-+
                             |4|
   |
                             +-+-+-+-+-+-+-+-+

                             where:

      *  4-Flag is the IPv4 flag.  When set, the FEC Sub-TLV describes
         an IPv4 FEC.  If the 4-flag is not set, then the FEC Sub-TLV
         describes an IPv6 FEC.

   o  Mask Length: 1 octet of prefix length.

   o  Prefix: an IPv4 or        Global IPv6 prefix whose mask length is given by the "
      Mask Length" field.

2.3.  TE Policy State

   A new TLV called "TE Policy State TLV" (codepoint to be assigned by
   IANA), is used to describe Remote Interface Address (16 octets)       |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Where:

   o  IPv6 Local Address: 16 octet value which carries the characteristics of local IPv6
      address associated with the TE Policy, node

   o  IPv6 Remote Address: 16 octet value which is carried in carries the optional non-transitive BGP Attribute
   "LINK_STATE Attribute" defined in [RFC7752].  These TE Policy
   characteristics include remote IPv6
      address associated with the characteristics node's neighbor

6.6.1.9.  Type 9: SRv6 END SID as IPv6 Node Address

   The Segment is SRv6 END SID type and attributes of the
   policy, it's dataplane, explicit path, Quality is specified as an IPv6 global
   address.  The format of Service (QoS)
   parameters, route information, the protection mechanisms, etc. its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |              Type
   +-+-+-+-+-+-+-+-+
   |             Length   Algorithm   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |  Path-origin  |   Dataplane   |            RESERVED          IPv6 Node Global Address (16 octets)                 |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     //            TE Policy State Sub-TLVs (variable)              //
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     where:

                            TE Policy State TLV

   Where:

   o  Type: Suggested  Algorithm: 1 octet value 1158 (to be assigned by IANA)

   o  Length: that indicates the total length of algorithm used for
      picking the TE Policy State TLV not including
      Type and Length fields. SID

   o  Path-origin: identifies the component (or protocol) from  IPv6 Node Global Address: 16 octet value which carries the
      contained object originated.  This allows for objects defined in
      different components to be collected while avoiding IPv6
      global address associated with the possible
      code collisions among these components.  Following path-origin
      codepoints are defined in this document (suggested values, to be
      assigned by IANA).

               +----------+------------------+
               |  Code    |     Path         |
               |  Point   |     Origin       |
               +----------+------------------+
               | node

6.6.1.10.  Type 10: SRv6 END.X SID as interface ID

   The Segment is SRv6 END.X SID type and is specified as a pair of IPv6
   global address and interface ID for local and remote nodes.  The
   format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1     | RSVP-TE          |
               | 2     | PCE              |
               | 3     | BGP SR TE Policy |
               | 4     | NETCONF          |
               | 5     | Static           |
               +----------+------------------+

   o  Dataplane: describes to which dataplane the policy is applied to.
      The following dataplane values are defined:

               +----------+------------------+
               |  Code    |    Dataplane     |
               |  Point   |                  |
               +----------+------------------+
               | 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   | MPLS-IPv4          IPv6 Local Node Global Address (16 octets)           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |    2          Local Node Interface ID (4 octets)                   | MPLS-IPv6
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |          IPv6 Remote Node Global Address (16 octets)          |    3
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   | IPv6          Remote Node Interface ID (4 octets)                  |
               +----------+------------------+
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Where:

   o  RESERVED: 16-bit field field.  SHOULD be set to 0 on transmission
      and MUST be ignored on receipt.

   TE Policy State sub-TLVs: objects as defined in [RFC3209],[RFC3473],
   [RFC5440] and [I-D.previdi-idr-segment-routing-te-policy].  Rather
   than replicating all these objects in this document, the semantics
   and encodings of the objects are reused.  These objects are carried
   in  IPv6 Local Node Global Address: 16 octet value which carries the "TE Policy State Information"
      IPv6 global address associated with the following format.

2.3.1.  RSVP Objects

   RSVP-TE objects are encoded in local node

   o  Local Node Interface ID : 4 octet value which carries the "Value" field
      interface ID of the LSP State TLV
   and consists of MPLS TE LSP objects defined in RSVP-TE [RFC3209]
   [RFC3473].  Rather than replicating all MPLS TE LSP related objects
   in this document, local node identified by the semantics Local Node
      Address

   o  IPv6 Remote Node Global Address: 16 octet value which carries the
      IPv6 global address associated with the remote node.  This is
      optional and encodings of MAY be set to 0 when not used (e.g.  when identifying
      point-to-point links).

   o  Remote Node Interface ID : 4 octet value which carries the MPLS TE LSP
   objects are re-used.  These MPLS TE LSP objects are carried in
      interface ID of the
   LSP State TLV.

   When carrying RSVP-TE objects, remote node identified by the "Path-Origin" field Remote Node
      Address.  This is optional and MAY be set to
   "RSVP-TE". 0 when not used (e.g.
      when identifying point-to-point links).

6.6.1.11.  Type 11: SRv6 END.X SID as interface address

   The following RSVP-TE Objects are defined:

   o  SENDER_TSPEC Segment is SRv6 END.X SID type and FLOW_SPEC [RFC2205]

   o  SESSION_ATTRIBUTE [RFC3209]

   o  EXPLICIT_ROUTE Object (ERO) [RFC3209]

   o  ROUTE_RECORD Object (RRO) [RFC3209]

   o  FAST_REROUTE Object [RFC4090]

   o  DETOUR Object [RFC4090]

   o  EXCLUDE_ROUTE Object (XRO) [RFC4874]

   o  SECONDARY_EXPLICIT_ROUTE Object (SERO) [RFC4873]
   o  SECONDARY_RECORD_ROUTE (SRRO) [RFC4873]

   o  LSP_ATTRIBUTES Object [RFC5420]

   o  LSP_REQUIRED_ATTRIBUTES Object [RFC5420]

   o  PROTECTION Object [RFC3473][RFC4872][RFC4873]

   o  ASSOCIATION Object [RFC4872]

   o  PRIMARY_PATH_ROUTE Object [RFC4872]

   o  ADMIN_STATUS Object [RFC3473] is specified as a pair of IPv6
   Global addresses for local and remote interface addresses.  The
   format of its Segment Descriptor is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |        Global IPv6 Local Interface Address (16 octets)        |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |        Global IPv6 Remote Interface Address (16 octets)       |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Where:

   o  LABEL_REQUEST Object [RFC3209][RFC3473]

   For the MPLS TE LSP Objects listed above,  IPv6 Local Address: 16 octet value which carries the corresponding sub-
   objects are also applicable to this mechanism.  Note that this list
   is not exhaustive, other MPLS TE LSP objects local IPv6
      address associated with the node

   o  IPv6 Remote Address: 16 octet value which reflect specific
   characteristics of carries the MPLS TE LSP can also be carried in remote IPv6
      address associated with the LSP
   state TLV.

2.3.2.  PCE Objects

   PCE objects are encoded in node's neighbor

6.7.  SR Segment List Metric

   The SR Segment List Metric sub-TLV describes the "Value" field metric used for
   computation of the MPLS TE LSP State
   TLV and consists SID-List.  It is used to report the type of PCE objects defined in [RFC5440].  Rather than
   replicating all MPLS TE LSP related objects metric
   used in this document, the
   semantics and encodings computation of a dynamic path either on the MPLS TE LSP objects are re-used.
   These MPLS TE LSP objects are carried in the LSP State TLV.

   When carrying PCE objects, headend or
   when the "Path-Origin" field path computation is set delegated to "PCE".

   The following PCE Objects are defined:

   o  METRIC Object [RFC5440]

   o  BANDWIDTH Object [RFC5440]

   For a PCE/controller.  When the MPLS TE LSP Objects listed above,
   path computation is done on the corresponding sub-
   objects are headend, it is also applicable used to this mechanism.  Note that this list
   is not exhaustive, other MPLS TE LSP objects which reflect specific
   characteristics of report
   the MPLS TE LSP can also be carried in calculated metric for the LSP
   state TLV.

2.3.3.  SR TE Policy Sub-TLVs

   Segment Routing Traffic Engineering Policy (SR TE Policy) as
   described in [I-D.previdi-idr-segment-routing-te-policy]makes use path.

   It is a sub-TLV of the Tunnel Encapsulation Attribute defined in
   [I-D.ietf-idr-tunnel-encaps] and defines following sub-TLVs:

   o  Preference

   o  Binding SID

   o  Weight

   o SR Segment List

   o  Segment

   The equivalent sub-TLVs are defined hereafter and carried in the TE
   Policy State TLV.  When carrying SR TE Policy objects, the "Path-
   Origin" field is set to "BGP SR TE Policy".

2.3.3.1.  Preference Object

   The Preference sub-TLV TLV and has the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              Type             |             Length            |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |  Metric Type  |      Flags    |          RESERVED             |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                      Preference (4 octets)                         Metric Margin                         |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   All fields, including
   |                         Metric Bound                          |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                         Metric Value                          |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   where:

   o  Type: TBD (see IANA Considerations Section 9.3)

   o  Length: variable
   o  Metric Type : 1 octet field which identifies the type and length, of metric
      used for path computation.  Following metric type codepoints are
      defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.2.  SR TE Binding SID Sub-TLV

   The Binding SID sub-TLV has the following format:

    0                   1                   2                   3 this document.

   +------------+-----------------------------------------+
   | Code Point |         Metric Type                     |
   +------------+-----------------------------------------+
   |     0      | IGP Metric                              |
   |     1      | Min Unidirectional Link Delay [RFC7471] |
   |     2 3 4 5 6 7 8 9 0      | TE Metric [RFC3630]                     |
   +------------+-----------------------------------------+

   o  Flags: 1 2 3 4 5 6 7 8 9 octet field that indicates the validity of the metric
      fields and their semantics.  The following bit positions are
      defined and the other bits SHOULD be cleared by originator and
      MUST be ignored by receiver.

       0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Type      |   Length      |     Flags     |   RESERVED    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |              Binding SID (variable, optional)
      +-+-+-+-+-+-+-+-+
      |M|A|B|V|       |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   All fields, including type and length, are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

   [I-D.previdi-idr-segment-routing-te-policy] specifies
      +-+-+-+-+-+-+-+-+

   where:

      *  M-Flag : Indicates that the Binding SID
   sub-TLV which carries metric margin allowed for path
         computation is specified when SET

      *  A-Flag : Indicates that the metric margin is specified as an indication of which
         absolute value to allocate when SET and is expressed as
   Binding SID to a percentage of the SR TE Policy.  In
         minimum metric when CLEAR.

      *  B-Flag : Indicates that the context of metric bound allowed for the BGP-LS
   extensions defined in this document, path
         is specified when SET.

      *  V-Flag : Indicates that the Binding SID sub-TLV metric value computed is being
         reported when SET.

   o  RESERVED: 2 octets.  SHOULD be set to 0 by originator and MUST be
      ignored by receiver.

   o  Metric Margin : 4 octets which indicate the
   reciever metric margin value
      when M-flag is SET.  The metric margin is specified as either an
      absolute value or as a percentage of the , the Binding SID TLThe Binding SID sub-TLV contains minimum computed path
      metric based on the Binding SID A-flag.  The metric margin loosens the originator of
      criteria for minimum metric path calculation up to the BGP-LS update has allocated specified
      metric to accomodate for other factors such as bandwidth
      availability, minimal SID stack depth and maximizing of ECMP for
      the corresponding SR TE Policy.

   In path computed.

   o  Metric Bound : 4 octects which indicate the context of BGP-LS, maximum metric value
      that is allowed when B-flag is SET.  If the Binding SID sub-TLV defined in this
   document, contains computed path metric
      crosses the effective specified bound value of then the Binding SID that path is considered as
      invalid.

   o  Metric Value : 4 octets which indicate the
   router allocated to metric value of the SR TE Policy.  The router
      computed path when V-flag is SET.  This value is available and
      reported when the SR TE Policy
   receiver (as described in
   [I-D.previdi-idr-segment-routing-te-policy]) computation is successful and it a valid path is also the
   originator of the corresponding
      available.

7.  Procedures

   The BGP-LS update with advertisements for the extensions
   defined in this document.

2.3.3.3.  Weight Sub-TLV

   The Weight sub-TLV has TE Policy NLRI are originated by
   the following format:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Type      |   Length      |     Flags     |   RESERVED    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                              Weight                           |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   All fields, including type and length, headend node for the TE Policies that are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.4.  Segment List Sub-TLV

   The Segment List object contains sub-TLVs (which instantiated on its
   local node.

   For MPLS TE LSPs signaled via RSVP-TE, the NLRI descriptor TLVs as
   specified in fact are sub-sub-
   TLVs) and has following format:

   0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Type      |             Length            |   RESERVED    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                           sub-TLVs                          //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   o  All fields, including type Section 4.1, Section 4.2, Section 4.3 and length, Section 4.4
   are used.  Then the TE LSP state is encoded in the BGP-LS Attribute
   field as MPLS-TE Policy State TLV as described in Section 5.  The
   RSVP-TE objects that reflect the state of the LSP are included as
   defined in
      [I-D.previdi-idr-segment-routing-te-policy].

   o  Length is Section 5.1.  When the total length (not including TE LSP is setup with the Type and Length
      fields) help of
   PCEP signaling then another MPLS-TE Policy State TLV SHOULD be used
   to to encode the sub-TLVs encoded within related PCEP objects corresponding to the Segment List sub-TLV.

   o  sub-objects:

      * LSP as
   defined in Section 5.2.

   For SR Policies, the NLRI descriptor TLV as specified in Section 4.5
   is used.  An optional single Weight sub-TLV.

      *  One SR Policy candidate path (CP) may be instantiated on the
   headend node via a local configuration, PCEP or more Segment sub-TLVs.

   The Segment List sub-TLV BGP SR Policy
   signaling and this is mandatory.

   Multiple occurrences of indicated via the Segment List sub-TLV MAY appear in SR Protocol Origin.  Then the
   SR
   TE Policy.

2.3.3.5.  Segment Sub-TLV

   The Segment sub-TLV describes a single segment Policy Candidate Path's attribute and state is encoded in a segment list
   (i.e.: a single element of the explicit path).  Multiple Segment sub- BGP-
   LS Attribute field as SR Policy State TLVs constitute an explicit path of the and sub-TLVs as described
   in Section 6.  The SR TE Policy.

   [I-D.previdi-idr-segment-routing-te-policy] defines 8 different types
   of Segment Sub-TLVs:

   Type 1: SID only, Candidate Path State TLV as defined in
   Section 6.2 is included to report the form state of MPLS Label
   Type 2: SID only, in the form of IPv6 address
   Type 3: IPv4 Node Address with optional SID
   Type 4: IPv6 Node Address with optional SID
   Type 5: IPv4 Address + index with optional SID
   Type 6: IPv4 Local and Remote addresses with optional SID
   Type 7: IPv6 Address + index with optional SID
   Type 8: IPv6 Local and Remote addresses with optional SID

2.3.3.5.1.  Type 1: SID only, CP.  The SR BSID
   TLV as defined in Section 6.1 is included to report the form BSID of MPLS Label the
   CP when one is either provisioned or allocated by the headend.  The Type-1
   constraints for the SR Policy Candidate Path are reported using the
   SR Candidate Path Constraints TLV as described in Section 6.4.The SR
   Segment Sub-TLV encodes a single SID List TLV is included for each of the SID-List(s) associated
   with the CP.  Each SR Segment List TLV in turn includes SR Segment
   sub-TLV(s) to report the form of an
   MPLS label. segment(s) and their status.  The format SR Segment
   List Metric sub-TLV is used to report the metric values and
   constraints for the specific SID List.

   When the SR Policy CP is setup with the help of PCEP signaling then
   another MPLS-TE Policy State TLV MAY be used to to encode the related
   PCEP objects corresponding to the LSP as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 defined in Section 5.2
   specifically to report information and status that is not covered by
   the defined TLVs under Section 6.  In the event of a conflict of
   information, the receiver MUST prefer the information originated via
   TLVs defined in Section 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Type      |   Length      |     Flags     |   RESERVED    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |          Label                        | TC  |S|       TTL     |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   Type, Length over the PCEP objects reported via the TE
   Policy State TLV.

8.  Manageability Considerations

   The Existing BGP operational and values management procedures apply to this
   document.  No new procedures are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.2.  Type 2: SID only, this document.  The
   considerations as specified in [RFC7752] apply to this document.

   In general, it is assumed that the TE Policy head-end nodes are
   responsible for the distribution of TE Policy state information,
   while other nodes, e.g. the nodes in the form path of IPv6 address

   The Type-2 Segment Sub-TLV encodes a single SID policy, MAY report
   the TE Policy information (if available) when needed.  For example,
   the border routers in the form of an
   IPv6 address. inter-domain case will also distribute LSP
   state information since the ingress node may not have the complete
   information for the end-to-end path.

9.  IANA Considerations

   This document requires new IANA assigned codepoints.

9.1.  BGP-LS NLRI-Types

   IANA maintains a registry called "Border Gateway Protocol - Link
   State (BGP-LS) Parameters" with a sub-registry called "BGP-LS NLRI-
   Types".

   The format following codepoints is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ suggested (to be assigned by IANA):

    +------+----------------------------+---------------+
    | Type |   Length NLRI Type                  |     Flags   Reference   |   RESERVED
    +------+----------------------------+---------------+
    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                       IPv6 SID (16 octets)                  //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.3.  Type 3: IPv4 Node Address with optional SID

   The Type-3 Segment Sub-TLV encodes an IPv4 node address and an
   optional SID in the form of either an MPLS label or an IPv6 address.
   The format is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4  5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+   |     Type TE Policy NLRI type        | this document |
    +------+----------------------------+---------------+

9.2.  BGP-LS Protocol-IDs

   IANA maintains a registry called "Border Gateway Protocol - Link
   State (BGP-LS) Parameters" with a sub-registry called "BGP-LS
   Protocol-IDs".

   The following Protocol-ID codepoints are suggested (to be assigned by
   IANA):

    +-------------+----------------------------------+---------------+
    | Protocol-ID |   Length NLRI information source protocol |     Flags   Reference   |   RESERVED
    +-------------+----------------------------------+---------------+
    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+     8       |                 IPv4 Node Address (4 octets)          RSVP-TE                 |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                SID (optional, 4 or 16 octets)               //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.4.  Type 4: IPv6 Node Address with optional SID

   The Type-4 Segment Sub-TLV encodes an IPv6 node address and an
   optional SID in the form of either an MPLS label or an IPv6 address.
   The format is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ this document |     Type
    |   Length     9       |     Flags       Segment Routing            |   RESERVED this document |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                IPv6 Node Address (16 octets)                //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                SID (optional, 4 or 16 octets)               //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.5.  Type 5: IPv4 Address + index
    +-------------+----------------------------------+---------------+

9.3.  BGP-LS TLVs

   IANA maintains a registry called "Border Gateway Protocol - Link
   State (BGP-LS) Parameters" with optional SID

   The Type-5 Segment Sub-TLV encodes an IPv4 node address, an interface
   index a sub-registry called "Node Anchor,
   Link Descriptor and an optional SID in the form of either an MPLS label or an
   IPv6 address. Link Attribute TLVs".

   The format is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ following TLV codepoints are suggested (to be assigned by IANA):

   +----------+----------------------------------------+---------------+
   |     Type TLV Code |   Length             Description                |     Flags Value defined |   RESERVED
   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+  Point   |                 IfIndex (4 octets)                                        |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+       in      |                 IPv4 Node Address (4 octets)
   +----------+----------------------------------------+---------------+
   |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                SID (optional, 4 or 16 octets)               //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.6.  Type 6: IPv4 Local and Remote addresses with optional SID

   The Type-6 Segment Sub-TLV encodes an IPv4 node address, an adjacency
   local address, an adjacency remote address and an optional SID in the
   form of either an MPLS label or an IPv6 address.  The format is as
   follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+   TBD    |     Type   Tunnel ID TLV                        |   Length this document |     Flags
   |   RESERVED   TBD    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+   LSP ID TLV                           |                Local IPv4 Address (4 octets) this document |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                Remote IPv4 Address  (4 octets)   TBD    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                     SID (4 or 16 octets)                    //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.7.  Type 7: IPv6 Address + index with optional SID

   The Type-7 Segment Sub-TLV encodes an IPv6 node address, an interface
   index and an optional SID in the form of either an MPLS label or an
   IPv6 address.  The format is as follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+   IPv4/6 Tunnel Head-end address TLV   | this document |
   |   TBD    |   IPv4/6 Tunnel Tail-end address TLV   | this document |     Type
   |   Length   TBD    |     Flags   SR Policy CP Descriptor TLV          |   RESERVED this document |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                 IfIndex (4 octets)   TBD    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                IPv6 Node Address (16 octets)                //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                SID (optional, 4 or 16 octets)               //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

2.3.3.5.8.  Type 8: IPv6   MPLS Local and Remote addresses with optional SID

   The Type-8 Segment Sub-TLV encodes an IPv6 node address, an adjacency
   local address, an adjacency remote address and an optional SID in the
   form of either an Cross Connect TLV         | this document |
   |   TBD    |   MPLS label or an IPv6 address.  The format is as
   follows:

    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ Cross Connect Interface TLV     |     Type this document |   Length
   |     Flags   TBD    |   RESERVED   MPLS Cross Connect FEC TLV           | this document |
   |   TBD    |   MPLS-TE Policy State TLV             | this document |
   |   TBD    |   SR BSID TLV                          | this document |
   |   TBD    |   SR CP State TLV                      | this document |
   |   TBD    |   SR CP Name TLV                       | this document |
   |   TBD    |   SR CP Constraints TLV                | this document |
   |   TBD    |   SR Segment List TLV                  | this document |
   |   TBD    |   SR Segment sub-TLV                   | this document |
   |   TBD    |   SR Segment List Metric sub-TLV       | this document |
   |   TBD    |   SR Affinity Constraint sub-TLV       |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //               Local IPv6 Address (16 octets)                //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //               Remote IPv6 Address  (16 octets)              //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   //                     SID (4 or 16 octets)                    //
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

   Type, Length and values are defined in
   [I-D.previdi-idr-segment-routing-te-policy].

3.  Operational Considerations

   The Existing BGP operational procedures apply to this document.  No
   new operation procedures are defined in document |
   |   TBD    |   SR SRLG Constraint sub-TLV           | this document.  The
   operational considerations as specified in [RFC7752] apply to document |
   |   TBD    |   SR Bandwidth Constraint sub-TLV      | this
   document.

   In general, it is assumed that the TE Policy head-end nodes are
   responsible for the distribution of TE Policy state information,
   while other nodes, e.g. the nodes in the path of a policy, MAY report
   the TE document |
   |   TBD    |   SR Disjoint Group Constraint sub-TLV | this document |
   +----------+----------------------------------------+---------------+

9.4.  BGP-LS SR Policy information (if available) when needed.  For example,
   the border routers in the inter-domain case will also distribute LSP
   state information since the ingress node may not have the complete
   information for the end-to-end path.

4.  IANA Considerations Protocol Origin

   This document requires new IANA assigned codepoints.

4.1.  BGP-LS NLRI-Types requests IANA maintains to maintain a registry called new sub-registry under
   "Border Gateway Protocol - Link State (BGP-LS) Parameters" with a sub-registry Parameters".  The new
   registry is called "BGP-LS NLRI-
   Types". "SR Policy Protocol Origin" and contains the
   codepoints allocated to the "Protocol Origin" field defined in
   Section 4.5.  The registry contains the following codepoints is suggested (to
   (suggested values, to be assigned by IANA):

    +------+----------------------------+---------------+

+------------+---------------------------------------------------------+
| Type Code Point | NLRI Type                   Protocol Origin                       |   Reference
+------------+---------------------------------------------------------+
|
    +------+----------------------------+---------------+     1      |  5 PCEP                                                    | TE
|     2      | BGP SR Policy NLRI type                                           | this document
|
    +------+----------------------------+---------------+

4.2.     3      | Local (via CLI, Yang model through NETCONF, gRPC, etc.) |
+------------+---------------------------------------------------------+

9.5.  BGP-LS Protocol-IDs TE State Path Origin

   This document requests IANA maintains to maintain a registry called new sub-registry under
   "Border Gateway Protocol - Link State (BGP-LS) Parameters" with a sub-registry Parameters".  The new
   registry is called "BGP-LS
   Protocol-IDs". "TE State Path Origin" and contains the codepoints
   allocated to the "Path Origin" field defined in Section 5.  The
   registry contains the following Protocol-ID codepoints are suggested (to (suggested values, to be
   assigned by IANA):

    +-------------+----------------------------------+---------------+

               +----------+------------------+
               | Protocol-ID  Code    | NLRI information source protocol     Path         |   Reference
               |
    +-------------+----------------------------------+---------------+  Point   |     8     Origin       |
               +----------+------------------+
               |    1     | RSVP-TE          | this document
               |    2     |     9 PCEP             |       Segment Routing
               | this document    3     |
    +-------------+----------------------------------+---------------+

4.3. Local/Static     |
               +----------+------------------+

9.6.  BGP-LS Descriptors TLVs TE State Dataplane

   This document requests IANA maintains to maintain a registry called new sub-registry under
   "Border Gateway Protocol - Link State (BGP-LS) Parameters" with a sub-registry Parameters".  The new
   registry is called "Node Anchor,
   Link Descriptor "TE State Dataplane" and Link Attribute TLVs". contains the codepoints
   allocated to the "dataplane" field defined in Section 5.  The
   registry contains the following TLV codepoints are suggested (to (suggested values, to be
   assigned by IANA):

   +----------+--------------------------------------+---------------+

               +----------+------------------+
               | TLV  Code    |             Description              | Value defined   Dataplane      |
               |  Point   |                  |       in      |
   +----------+--------------------------------------+---------------+
   |   1158   |   TE Policy State TLV                | this document |
   |    267   |   Tunnel ID TLV                      | this document |
   |    268   |   LSP ID TLV                         | this document |
   |    269   |   IPv4/6 Tunnel Head-end address TLV | this document |
   |    270   |   IPv4/6 Tunnel Tail-end address TLV
               +----------+------------------+
               | this document    1     | MPLS-IPv4        |    271
               |   SR TE Policy Identifier TLV    2     | this document MPLS-IPv6        |
   +----------+--------------------------------------+---------------+

4.4.
               +----------+------------------+

9.7.  BGP-LS LSP-State TLV Path Origin SR Segment Descriptors

   This document requests IANA to maintain a new sub-registry under
   "Border Gateway Protocol - Link State (BGP-LS) Parameters".  The new
   registry is called "Path Origin" "SR Segment Descriptor Types" and contains the
   codepoints allocated to the "Path Origin" "Segment Type" field defined in
   Section 2.3. 6.6 and described in Section 6.6.1.  The registry contains
   the following codepoints (suggested values, to be assigned by IANA):

               +----------+------------------+

+-------+--------------------------------------------------------------+
| Code  |   Segment Description                                        |
| Point |                                                              |
+-------+--------------------------------------------------------------+
|   0   | Invalid                                                      |
|   1   | SR-MPLS Label                                                |
|   2   | SRv6 SID as IPv6 address                                     |
|   3   | SR-MPLS Prefix SID as IPv4 Node Address                      |
|   4   | SR-MPLS Prefix SID as IPv6 Node Global Address               |
|   5   | SR-MPLS Adjacency SID as IPv4 Node Address & Local           |
|       | Interface ID                                                 |
|   6   | SR-MPLS Adjacency SID as IPv4 Local & Remote Interface       |  Code
|     Path       | Addresses                                                    |  Point
|     Origin   7   |
               +----------+------------------+ SR-MPLS Adjacency SID as pair of IPv6 Global Address &       |    1
| RSVP-TE       | Interface ID for Local & Remote nodes                        |    2
| PCE   8   | SR-MPLS Adjacency SID as pair of IPv6 Global Addresses for   |    3
| BGP SR TE Policy       | the Local & Remote Interface                                 |    4
| NETCONF   9   | SRv6 END SID as IPv6 Node Global Address                     |    5
| Static  10   |
               +----------+------------------+

4.5. SRv6 END.X SID as pair of IPv6 Global Address & Interface ID |
|       | for Local & Remote nodes                                     |
|  11   | SRv6 END.X SID as pair of IPv6 Global Addresses for the      |
|       | Local & Remote Interface                                     |
+-------+--------------------------------------------------------------+

9.8.  BGP-LS LSP-State TLV Dataplane Metric Type

   This document requests IANA to maintain a new sub-registry under
   "Border Gateway Protocol - Link State (BGP-LS) Parameters".  The new
   registry is called "Dataplane" "Metric Type" and contains the codepoints
   allocated to the "dataplane" "metric type" field defined in Section 2.3. 6.7.  The
   registry contains the following codepoints (suggested values, to be
   assigned by IANA):

               +----------+------------------+

   +------------+-----------------------------------------+
   | Code Point |   Dataplane         Metric Type                     |
   +------------+-----------------------------------------+
   |  Point     0      | IGP Metric                              |
               +----------+------------------+
   |     1      | MPLS-IPv4 Min Unidirectional Link Delay [RFC7471] |
   |     2      | MPLS-IPv6        |
               |    3     | IPv6 TE Metric [RFC3630]                     |
               +----------+------------------+

5.
   +------------+-----------------------------------------+

10.  Security Considerations

   Procedures and protocol extensions defined in this document do not
   affect the BGP security model.  See [RFC6952] for details.

6.

11.  Acknowledgements

   The authors would like to thank Dhruv Dhody, Mohammed Abdul Aziz
   Khalid, Lou Berger, Acee Lindem, Siva Sivabalan, Arjun Sreekantiah,
   and Dhanendra Jain for their review and valuable comments.

7.

12.  Contributors

   The following people have substantially contributed to the editing of
   this document:

   Ketan Talaulikar
   Cisco Systems
   Email: ketant@cisco.com

   Clarence Filsfils
   Cisco Systems
   Email: cfilsfil@cisco.com

8.

13.  References

8.1.

13.1.  Normative References

   [I-D.ietf-spring-segment-routing-policy]
              Filsfils, C., Sivabalan, S., daniel.voyer@bell.ca, d.,
              bogdanov@google.com, b., and P. Mattes, "Segment Routing
              Policy Architecture", draft-ietf-spring-segment-routing-
              policy-01 (work in progress), June 2018.

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119,
              DOI 10.17487/RFC2119, March 1997,
              <https://www.rfc-editor.org/info/rfc2119>.

   [RFC2205]  Braden, R., Ed., Zhang, L., Berson, S., Herzog, S., and S.
              Jamin, "Resource ReSerVation Protocol (RSVP) -- Version 1
              Functional Specification", RFC 2205, DOI 10.17487/RFC2205,
              September 1997, <https://www.rfc-editor.org/info/rfc2205>.

   [RFC3209]  Awduche, D., Berger, L., Gan, D., Li, T., Srinivasan, V.,
              and G. Swallow, "RSVP-TE: Extensions to RSVP for LSP
              Tunnels", RFC 3209, DOI 10.17487/RFC3209, December 2001,
              <https://www.rfc-editor.org/info/rfc3209>.

   [RFC3473]  Berger, L., Ed., "Generalized Multi-Protocol Label
              Switching (GMPLS) Signaling Resource ReserVation Protocol-
              Traffic Engineering (RSVP-TE) Extensions", RFC 3473,
              DOI 10.17487/RFC3473, January 2003,
              <https://www.rfc-editor.org/info/rfc3473>.

   [RFC4090]  Pan, P., Ed., Swallow, G., Ed., and A. Atlas, Ed., "Fast
              Reroute Extensions to RSVP-TE for LSP Tunnels", RFC 4090,
              DOI 10.17487/RFC4090, May 2005,
              <https://www.rfc-editor.org/info/rfc4090>.

   [RFC4760]  Bates, T., Chandra, R., Katz, D., and Y. Rekhter,
              "Multiprotocol Extensions for BGP-4", RFC 4760,
              DOI 10.17487/RFC4760, January 2007,
              <https://www.rfc-editor.org/info/rfc4760>.

   [RFC4872]  Lang, J., Ed., Rekhter, Y., Ed., and D. Papadimitriou,
              Ed., "RSVP-TE Extensions in Support of End-to-End
              Generalized Multi-Protocol Label Switching (GMPLS)
              Recovery", RFC 4872, DOI 10.17487/RFC4872, May 2007,
              <https://www.rfc-editor.org/info/rfc4872>.

   [RFC4873]  Berger, L., Bryskin, I., Papadimitriou, D., and A. Farrel,
              "GMPLS Segment Recovery", RFC 4873, DOI 10.17487/RFC4873,
              May 2007, <https://www.rfc-editor.org/info/rfc4873>.

   [RFC4874]  Lee, CY., Farrel, A., and S. De Cnodder, "Exclude Routes -
              Extension to Resource ReserVation Protocol-Traffic
              Engineering (RSVP-TE)", RFC 4874, DOI 10.17487/RFC4874,
              April 2007, <https://www.rfc-editor.org/info/rfc4874>.

   [RFC5420]  Farrel, A., Ed., Papadimitriou, D., Vasseur, JP., and A.
              Ayyangarps, "Encoding of Attributes for MPLS LSP
              Establishment Using Resource Reservation Protocol Traffic
              Engineering (RSVP-TE)", RFC 5420, DOI 10.17487/RFC5420,
              February 2009, <https://www.rfc-editor.org/info/rfc5420>.

   [RFC5440]  Vasseur, JP., Ed. and JL. Le Roux, Ed., "Path Computation
              Element (PCE) Communication Protocol (PCEP)", RFC 5440,
              DOI 10.17487/RFC5440, March 2009,
              <https://www.rfc-editor.org/info/rfc5440>.

   [RFC7752]  Gredler, H., Ed., Medved, J., Previdi, S., Farrel, A., and
              S. Ray, "North-Bound Distribution of Link-State and
              Traffic Engineering (TE) Information Using BGP", RFC 7752,
              DOI 10.17487/RFC7752, March 2016,
              <https://www.rfc-editor.org/info/rfc7752>.

8.2.

13.2.  Informative References

   [I-D.ietf-idr-tunnel-encaps]
              Rosen, E., Patel, K., and G. Velde, "The BGP Tunnel
              Encapsulation Attribute", draft-ietf-idr-tunnel-encaps-07
              (work in progress), July 2017.

   [I-D.ietf-pce-stateful-pce]
              Crabbe, E., Minei, I., Medved,

   [RFC2702]  Awduche, D., Malcolm, J., Agogbua, J., O'Dell, M., and R. Varga, "PCEP
              Extensions J.
              McManus, "Requirements for Stateful PCE", draft-ietf-pce-stateful-
              pce-21 (work in progress), June 2017.

   [I-D.previdi-idr-segment-routing-te-policy]
              Previdi, S., Filsfils, C., Mattes, P., Rosen, E., Traffic Engineering Over MPLS",
              RFC 2702, DOI 10.17487/RFC2702, September 1999,
              <https://www.rfc-editor.org/info/rfc2702>.

   [RFC3630]  Katz, D., Kompella, K., and S.
              Lin, "Advertising Segment Routing Policies in BGP", draft-
              previdi-idr-segment-routing-te-policy-07 (work D. Yeung, "Traffic Engineering
              (TE) Extensions to OSPF Version 2", RFC 3630,
              DOI 10.17487/RFC3630, September 2003,
              <https://www.rfc-editor.org/info/rfc3630>.

   [RFC4202]  Kompella, K., Ed. and Y. Rekhter, Ed., "Routing Extensions
              in
              progress), June 2017. Support of Generalized Multi-Protocol Label Switching
              (GMPLS)", RFC 4202, DOI 10.17487/RFC4202, October 2005,
              <https://www.rfc-editor.org/info/rfc4202>.

   [RFC4655]  Farrel, A., Vasseur, J., and J. Ash, "A Path Computation
              Element (PCE)-Based Architecture", RFC 4655,
              DOI 10.17487/RFC4655, August 2006,
              <https://www.rfc-editor.org/info/rfc4655>.

   [RFC6952]  Jethanandani, M., Patel, K., and L. Zheng, "Analysis of
              BGP, LDP, PCEP, and MSDP Issues According to the Keying
              and Authentication for Routing Protocols (KARP) Design
              Guide", RFC 6952, DOI 10.17487/RFC6952, May 2013,
              <https://www.rfc-editor.org/info/rfc6952>.

   [RFC7308]  Osborne, E., "Extended Administrative Groups in MPLS
              Traffic Engineering (MPLS-TE)", RFC 7308,
              DOI 10.17487/RFC7308, July 2014,
              <https://www.rfc-editor.org/info/rfc7308>.

   [RFC7471]  Giacalone, S., Ward, D., Drake, J., Atlas, A., and S.
              Previdi, "OSPF Traffic Engineering (TE) Metric
              Extensions", RFC 7471, DOI 10.17487/RFC7471, March 2015,
              <https://www.rfc-editor.org/info/rfc7471>.

   [RFC8231]  Crabbe, E., Minei, I., Medved, J., and R. Varga, "Path
              Computation Element Communication Protocol (PCEP)
              Extensions for Stateful PCE", RFC 8231,
              DOI 10.17487/RFC8231, September 2017,
              <https://www.rfc-editor.org/info/rfc8231>.

Authors' Addresses

   Stefano Previdi (editor)

   Email: stefano@previdi.net

   Ketan Talaulikar
   Cisco Systems, Inc.

   Email: stefano@previdi.net ketant@cisco.com

   Jie Dong (editor)
   Huawei Technologies
   Huawei Campus, No. 156 Beiqing Rd.
   Beijing  100095
   China

   Email: jie.dong@huawei.com

   Mach(Guoyi) Chen
   Huawei Technologies
   Huawei Campus, No. 156 Beiqing Rd.
   Beijing  100095
   China

   Email: mach.chen@huawei.com

   Hannes Gredler
   RtBrick Inc.

   Email: hannes@rtbrick.com

   Jeff Tantsura
   Individual
   Nuage Networks

   Email: jefftant@gmail.com jefftant.ietf@gmail.com