Internet DRAFT - draft-ietf-lsr-isis-srv6-yang

draft-ietf-lsr-isis-srv6-yang







Network Working Group                                              Z. Hu
Internet-Draft                                                    Huawei
Intended status: Standards Track                                   D. Ye
Expires: 1 September 2024                                          Cisco
                                                                   Y. Qu
                                                  Futurewei Technologies
                                                                 X. Geng
                                                                   Q. Ma
                                                                  Huawei
                                                        29 February 2024


                     YANG Data Model for IS-IS SRv6
                    draft-ietf-lsr-isis-srv6-yang-05

Abstract

   This document defines a YANG data model that can be used to configure
   and manage IS-IS Segment Routing over the IPv6 Data Plane.

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 1 September 2024.

Copyright Notice

   Copyright (c) 2024 IETF Trust and the persons identified as the
   document authors.  All rights reserved.




Hu, et al.              Expires 1 September 2024                [Page 1]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents (https://trustee.ietf.org/
   license-info) in effect on the date of publication of this document.
   Please review these documents carefully, as they describe your rights
   and restrictions with respect to this document.  Code Components
   extracted from this document must include Revised BSD License text as
   described in Section 4.e of the Trust Legal Provisions and are
   provided without warranty as described in the Revised BSD License.

Table of Contents

   1.  Overview  . . . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  IS-IS SRv6  . . . . . . . . . . . . . . . . . . . . . . . . .   2
   3.  IS-IS SRv6 configuration  . . . . . . . . . . . . . . . . . .   5
     3.1.  SRv6 activation . . . . . . . . . . . . . . . . . . . . .   5
     3.2.  Locator setting . . . . . . . . . . . . . . . . . . . . .   5
     3.3.  IP Fast reroute . . . . . . . . . . . . . . . . . . . . .   5
     3.4.  Microloop avoidance . . . . . . . . . . . . . . . . . . .   5
   4.  IS-IS SRv6 YANG Module  . . . . . . . . . . . . . . . . . . .   6
   5.  Security Considerations . . . . . . . . . . . . . . . . . . .  19
   6.  Contributors  . . . . . . . . . . . . . . . . . . . . . . . .  20
   7.  Acknowledgements  . . . . . . . . . . . . . . . . . . . . . .  20
   8.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .  21
   9.  References  . . . . . . . . . . . . . . . . . . . . . . . . .  21
     9.1.  Normative References  . . . . . . . . . . . . . . . . . .  21
   Appendix A.  Configuration examples . . . . . . . . . . . . . . .  23
   Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .  24

1.  Overview

   YANG [RFC7950] is a data definition language used to define the
   contents of a conceptual data store that allows networked devices to
   be managed using NETCONF [RFC6241].  YANG is proving relevant beyond
   its initial confines, as bindings to other interfaces (e.g., REST)
   and encodings other than XML (e.g., JSON) are being defined.
   Furthermore, YANG data models can be used as the basis for
   implementation of other interfaces, such as CLI and programmatic
   APIs.

   This document defines a YANG data model that can be used to configure
   and manage IS-IS Segment Routing over the IPv6 Data Plane [RFC9352],
   and it is an augmentation to the IS-IS YANG data model [RFC9130].

2.  IS-IS SRv6

   This document defines a model for IS-IS SRv6 feature.  It is an
   augmentation of the IS-IS base model.




Hu, et al.              Expires 1 September 2024                [Page 2]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


   The IS-IS SRv6 YANG module requires support for the base srv6
   module[I-D.ietf-spring-srv6-yang], which defines the global srv6
   configuration independent of any specific routing protocol
   configuration, and support of IS-IS base model [RFC9130] which
   defines basic IS-IS configuration and state.  This module uses types
   defined in [RFC6991].  It also references [RFC8349], and [RFC9020].

   The figure below describes the overall structure of the isis-srv6
   YANG module:

module: ietf-isis-srv6
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis:
    +--rw srv6-cfg
    |  +--rw enable?                 boolean
    |  +--rw default-locator?        boolean
    |  +--rw locator-name*           -> /rt:routing/sr:segment-routing
    |                                /srv6:srv6/locators/locator/name
    |  +--rw persistent-end-x-sid?   boolean
    +--rw micro-loop-avoidance
       +--rw srv6-enable?             boolean
       +--rw srv6-rib-update-delay?   uint16
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:fast-reroute:
    +--rw srv6-ti-lfa {srv6-ti-lfa}?
       +--rw enable?   boolean
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:database
          /isis:levels/isis:lsp/isis:router-capabilities:
    +--ro v6-capability
    |  +--ro flags?   identityref
    +--ro msd
       +--ro max-sl?        uint8
       +--ro max-end-pop?   uint8
       +--ro max-h_encap?   uint8
       +--ro max-end_d?     uint8
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:database
          /isis:levels/isis:lsp/isis:extended-is-neighbor/isis:neighbor:
    +--ro srv6-adjacency-sids
       +--ro end-x-sid* [sid]
          +--ro func-flags?           identityref
          +--ro algorithm?            uint8
          +--ro weight?               uint8
          +--ro endpoint-func
          |  +--ro flags?                     identityref
          |  +--ro endpoint-func?             identityref
          |  +--ro undefined-endpoint-func?   uint16



Hu, et al.              Expires 1 September 2024                [Page 3]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


          +--ro sid                   srv6-sid-value
          +--ro neighbor-id?          isis:system-id
          +--ro srv6-sid-structure
             +--ro lb-length?    uint8
             +--ro ln-length?    uint8
             +--ro fun-length?   uint8
             +--ro arg-length?   uint8
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:database
          /isis:levels/isis:lsp/isis:mt-is-neighbor/isis:neighbor:
    +--ro srv6-adjacency-sids
       +--ro end-x-sid* [sid]
          +--ro func-flags?           identityref
          +--ro algorithm?            uint8
          +--ro weight?               uint8
          +--ro endpoint-func
          |  +--ro flags?                     identityref
          |  +--ro endpoint-func?             identityref
          |  +--ro undefined-endpoint-func?   uint16
          +--ro sid                   srv6-sid-value
          +--ro neighbor-id?          isis:system-id
          +--ro srv6-sid-structure
             +--ro lb-length?    uint8
             +--ro ln-length?    uint8
             +--ro fun-length?   uint8
             +--ro arg-length?   uint8
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:database
          /isis:levels/isis:lsp:
    +--ro srv6-locators
       +--ro locator* [locator]
          +--ro mt-id?                   uint16
          +--ro flags?                   identityref
          +--ro metric?                  uint32
          +--ro algorithm?               uint8
          +--ro loc-size?                uint8
          +--ro locator                  inet:ipv6-address-no-zone
          +--ro srv6-end-sids
          |  +--ro end-sid* [sid]
          |     +--ro flags?                uint8
          |     +--ro endpoint-func
          |     |  +--ro flags?                     identityref
          |     |  +--ro endpoint-func?             identityref
          |     |  +--ro undefined-endpoint-func?   uint16
          |     +--ro sid                   srv6-sid-value
          |     +--ro srv6-sid-structure
          |        +--ro lb-length?    uint8
          |        +--ro ln-length?    uint8



Hu, et al.              Expires 1 September 2024                [Page 4]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


          |        +--ro fun-length?   uint8
          |        +--ro arg-length?   uint8
          +--ro external-prefix-flag?    boolean
          +--ro readvertisement-flag?    boolean
          +--ro node-flag?               boolean
          +--ro ipv4-source-router-id?   inet:ipv4-address
          +--ro ipv6-source-router-id?   inet:ipv6-address
  augment /rt:routing/rt:control-plane-protocols
          /rt:control-plane-protocol/isis:isis/isis:interfaces
          /isis:interface/isis:adjacencies/isis:adjacency:
    +--ro end-x-sid* [value]
       +--ro value                   srv6-sid-value
       +--ro weight?                 uint8
       +--ro protection-requested?   boolean
       +--ro persistent?             boolean
       +--ro algorithm?              uint8
       +--ro endpoint-func
          +--ro flags?                     identityref
          +--ro endpoint-func?             identityref
          +--ro undefined-endpoint-func?   uint16

3.  IS-IS SRv6 configuration

3.1.  SRv6 activation

   Activation of IS-IS SRv6 is done by setting the "enable" leaf to
   true.  This triggers advertisement of SRv6 extensions based on the
   configuration parameters that have been setup using the base SRv6
   module.

3.2.  Locator setting

   The basic SRv6 module defines the related locator leafs.  When the
   IS-IS SRv6 module is enabled, set the locator by using the following
   strategy: firstly, it is reasonable to check whether the default
   locator is used, if not, to use the specified locator.  The strategy
   is realized by adding the leaf "default-locator", "locator-name" .

3.3.  IP Fast reroute

   IS-IS SRv6 model augments the fast-reroute container.  It brings the
   ability to activate ipv6 TI-LFA (topology independent LFA).

3.4.  Microloop avoidance

   IS-IS SRv6 model augments the micro-loop-avoidance container, this
   container including the leaf "srv6-enable" brings the ability to
   activate SRv6 avoid-microloop.



Hu, et al.              Expires 1 September 2024                [Page 5]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


4.  IS-IS SRv6 YANG Module

   <CODE BEGINS> file "ietf-isis-srv6@2024-02-28.yang"
   module ietf-isis-srv6 {
     yang-version 1.1;
     namespace "urn:ietf:params:xml:ns:"
             + "yang:ietf-isis-srv6";
     prefix isis-srv6;

     import ietf-routing {
       prefix rt;
       reference
         "RFC8349: A YANG Data Model for
                   Routing Management (NMDA Version)";
     }
     import ietf-isis {
       prefix isis;
       reference
         "RFC 9130: YANG Data Model for the IS-IS Protocol";
     }
     import ietf-inet-types {
       prefix inet;
       reference
         "RFC 6991:Common YANG Data Types";
     }
     import ietf-segment-routing {
       prefix sr;
       reference
         "RFC 9020: YANG Data Model for Segment
                    Routing";
     }
     import ietf-srv6-base {
       prefix srv6;
       reference
         "draft-ietf-spring-srv6-yang: YANG Data
          Model for SRv6 Base and Static";
     }

     organization
       "IETF LSR Working Group";
     contact
       "WG Web:   <http://datatracker.ietf.org/wg/lsr>
        WG List:  <mailto:lsr@ietf.org>

        Author:    Zhibo Hu
                   <mailto:huzhibo@huawei.com>
        Author:    Dan Ye
                   <mailto:daye@cisco.com>



Hu, et al.              Expires 1 September 2024                [Page 6]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


        Author:    Yingzhen Qu
                   <mailto:yingzhen.ietf@gmail.com>
        Author:    Qiufang Ma
                  <mailto:maqiufang1@huawei.com>
       ";
     description
       "The YANG module defines the configuration and operatioanl state
        for IS-IS extension to support Segment Routing over IPv6 data
        plane.

        This YANG model conforms to the Network Management
        Datastore Architecture (NDMA) as described in RFC 8342.

        Copyright (c) 2024 IETF Trust and the persons identified as
        authors of the code.  All rights reserved.

        Redistribution and use in source and binary forms, with or
        without modification, is permitted pursuant to, and subject
        to the license terms contained in, the Revised BSD License
        set forth in Section 4.c of the IETF Trust's Legal Provisions
        Relating to IETF Documents
        (https://trustee.ietf.org/license-info).

        This version of this YANG module is part of RFC XXXX
        (https://www.rfc-editor.org/info/rfcXXXX); see the RFC itself
        for full legal notices.

        The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL
        NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED',
        'MAY', and 'OPTIONAL' in this document are to be interpreted as
        described in BCP 14 (RFC 2119) (RFC 8174) when, and only when,
        they appear in all capitals, as shown here.";

     revision 2024-02-28 {
       description
         "Initial revision.";
       reference
         "RFC XXXX: YANG Data Model for IS-IS SRv6";
     }

     /* Identities */

     identity SRV6_END_FUNC_TYPE {
       description
         "Base identity type for srv6 endpoint function code points.";
     }

     identity SRV6_END_FUNC_PSP_USP_USD {



Hu, et al.              Expires 1 September 2024                [Page 7]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


       base SRV6_END_FUNC_TYPE;
       description
         "End (May support PSP, USP, USD).";
     }

     identity SRV6_END_X_FUNC_PSP_USP_USD {
       base SRV6_END_FUNC_TYPE;
       description
         "End.X(May support PSP, USP, USD)";
     }

     identity SRV6_END_T_FUNC_PSP_USP_USD {
       base SRV6_END_FUNC_TYPE;
       description
         "END (May support PSP, USP, USD)";
     }

     identity SRV6_END_FUNC_DX6 {
       base SRV6_END_FUNC_TYPE;
       description
         "End.DX6.";
     }

     identity SRV6_END_FUNC_DX4 {
       base SRV6_END_FUNC_TYPE;
       description
         "End.DX4.";
     }

     identity SRV6_END_FUNC_DT6 {
       base SRV6_END_FUNC_TYPE;
       description
         "End.DT6.";
     }

     identity SRV6_END_FUNC_DT4 {
       base SRV6_END_FUNC_TYPE;
       description
         "End.DT4.";
     }

     identity SRV6_END_FUNC_DT64 {
       base SRV6_END_FUNC_TYPE;
       description
         "End.DT64.";
     }

     identity SRV6_END_FUNC_OP {



Hu, et al.              Expires 1 September 2024                [Page 8]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


       base SRV6_END_FUNC_TYPE;
       description
         "END.OP .";
     }

     identity SRV6_END_FUNC_OTP {
       base SRV6_END_FUNC_TYPE;
       description
         "END.OTP .";
     }

     identity srv6-capability-bit {
       description
         "Base identity for SRv6 capability sub-TLV bits.";
       reference
         "RFC 9352: IS-IS Extensions to Support Segment Routing over
          the IPv6 Data Plane";
     }

     identity o-bit {
       base srv6-capability-bit;
       description
         "O-flag.";
       reference
         "RFC 9259: Operations, Administration, and Maintenance (OAM)
          in Segment Routing over IPv6 (SRv6)";
     }

     identity srv6-end-sid-bit {
       description
         "Base identity for SRv6 End SID sub-TLV bits.";
     }

     identity srv6-locator-bit {
       description
         "Base identity for SRv6 locator TLV bits.";
     }

     identity d-bit {
       base srv6-locator-bit;
       description
         "D-flag. up/down bit as described in RFC 5305.";
     }

     identity srv6-endx-sid-bit {
       description
         "Base identity for SRv6 End.X SID sub-TLV bits.";
     }



Hu, et al.              Expires 1 September 2024                [Page 9]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


     identity b-bit {
       base srv6-endx-sid-bit;
       description
         "B-flag. Backup flag. If set, the End.X sid is
          eligible for protection.";
     }

     identity s-bit {
       base srv6-endx-sid-bit;
       description
         "S-flag. Set flag. When set, the End.X sid refers to
          a set of adjacencies (and therefore May be assigned
          to other adjacencies as well.";
     }

     identity p-bit {
       base srv6-endx-sid-bit;
       description
         "P-flag. Persistent flag. When set, the End.X sid is
          persistently allocated, i.e., the End.x sid value
          remains consistent across router restart and/or
          interface flap.";
     }

     /* typedef */

     typedef srv6-sid-value {
       type inet:ipv6-address-no-zone;
       description
         "16 Octets encoded sid value.";
     }

     /* Features */

     feature srv6-ti-lfa {
       description
         "Enhance SRv6 FRR with ti-lfa support";
     }

     /* Groupings */

     grouping srv6-sid-structures {
       description
         "This group defines SRv6 SID Structure sub-sub-TLV.";
       container srv6-sid-structure {
         description
           "SRv6 SID Structure sub-sub-TLV is used to advertise
            the structure of the SRv6 SID as defined in RFC 8986.";



Hu, et al.              Expires 1 September 2024               [Page 10]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


         leaf lb-length {
           type uint8;
           description
             "SRv6 SID Locator Block length in bits.";
         }
         leaf ln-length {
           type uint8;
           description
             "SRv6 SID Locator Node length in bits.";
         }
         leaf fun-length {
           type uint8;
           description
             "SRv6 SID Function length in bits.";
         }
         leaf arg-length {
           type uint8;
           description
             "SRv6 SID Argument length in bits.";
         }
       }
     }

     grouping srv6-capability {
       description
         "SRV6 capability grouping.";
       container v6-capability {
         description
           "SRv6 capability.";
         leaf-list flags {
           type identityref {
             base srv6-capability-bit;
           }
           description
             "SRv6 Capability sub-TLV flag bits list.";
         }
       }
     }

     grouping srv6-endpoint-func {
       description
         "This group defines srv6 endpoint function";
       container endpoint-func {
         description
           "Srv6 Endpoint function Descriptor.";
         leaf-list flags {
           type identityref {
             base srv6-end-sid-bit;



Hu, et al.              Expires 1 September 2024               [Page 11]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           }
           description
             "SRv6 End SID sub-TLV  flag bits list. No flags
              are currently being defined.";
         }
         leaf endpoint-func {
           type identityref {
             base isis-srv6:SRV6_END_FUNC_TYPE;
           }
           description
             "The endpoint function.";
         }
         leaf undefined-endpoint-func {
           type uint16;
           description
             "Unknown endpoint func value.";
         }
       }
     }

     grouping srv6-end-sid {
       description
         "SRv6 Segment Identifier(SID) with Endpoint functions.";
       leaf-list flags {
         type identityref {
           base srv6-end-sid-bit;
         }
         description
           "SRv6 end sid flags.";
       }
       uses srv6-endpoint-func;
       leaf sid {
         type srv6-sid-value;
         description
           "SRV6 sid value.";
       }
       // sub-sub-tlvs
       uses srv6-sid-structures;
     }

     grouping srv6-locator {
       description
         "This group defines srv6 locator tlv.";
       leaf mt-id {
         type uint16 {
           range "0..4095";
         }
         description



Hu, et al.              Expires 1 September 2024               [Page 12]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           "Multitopology Identifier as defined in RFC5120.";
       }
       leaf-list flags {
         type identityref {
           base srv6-locator-bit;
         }
         description
           "Flags for SRv6 locator TLV.";
       }
       leaf metric {
         type uint32;
         description
           "Metric value.";
       }
       leaf algorithm {
         type uint8;
         description
           "Associated algorithm.";
       }
       leaf loc-size {
         type uint8;
         description
           "Number of bits in the locator field.";
       }
       leaf locator {
         type inet:ipv6-address-no-zone;
         description
           "Advertised SRV6 locator.";
       }
       container srv6-end-sids {
         description
           "This contains list of srv6 end sids.";
         list end-sid {
           key "sid";
           description
             "List of SRV6 SRv6 Segment Identifiers (SID)
              with Endpoint functions.";
           uses srv6-end-sid;
         }
       }
       uses isis:prefix-reachability-attributes;
       uses isis:prefix-ipv4-source-router-id;
       uses isis:prefix-ipv6-source-router-id;
     }

     grouping srv6-adjacency-sid {
       description
         "SRv6 sid associated with an adjacency.";



Hu, et al.              Expires 1 September 2024               [Page 13]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


       leaf-list func-flags {
         type identityref {
           base srv6-endx-sid-bit;
         }
         description
           "Flags for SRv6 end x SID.";
       }
       leaf algorithm {
         type uint8;
         description
           "Associated algorithm.";
       }
       leaf weight {
         type uint8;
         description
           "The value represents the weight of the End.X sid
            for the purpose of load balancing.";
       }
       uses srv6-endpoint-func;
       leaf sid {
         type srv6-sid-value;
         description
           "SRV6 sid value.";
       }
       leaf neighbor-id {
         type isis:system-id;
         description
           "Describes the system ID of the neighbor
            associated with the SID value. This is only
            used on LAN adjacencies.";
       }
       // sub-sub-tlvs
       uses srv6-sid-structures;
     }

     grouping srv6-adjacency-state {
       description
         "This group will extend adjacency state.";
       list end-x-sid {
         key "value";
         config false;
         leaf value {
           type srv6-sid-value;
           description
             "Value of the Adj-SID.";
         }
         leaf weight {
           type uint8;



Hu, et al.              Expires 1 September 2024               [Page 14]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           description
             "Weight associated with the End.X SID.";
         }
         leaf protection-requested {
           type boolean;
           description
             "Set to True if the End.X SID
              must be protected.";
         }
         leaf persistent {
           type boolean;
           description
             "Persistent flag. When set, the End.X sid is persistently
              allocated, i.e., the End.X sid value remains consistent
              across router restart and/or interface flap.";
         }
         leaf algorithm {
           type uint8;
           description
             "Associated algorithm.";
         }
         uses srv6-endpoint-func;
         description
           "List of End.X Segment IDs.";
       }
     }

     /* Cfg */

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis" {
       when "derived-from-or-self(../rt:type, 'isis:isis')" {
         description
           "This augment ISIS routing protocol when used";
       }
       description
         "This augments ISIS protocol configuration
          with SRv6.";
       container srv6-cfg {
         leaf enable {
           type boolean;
           default "false";
           description
             "Enables SRv6 protocol extensions.";
         }
         leaf default-locator {
           type boolean;



Hu, et al.              Expires 1 September 2024               [Page 15]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           default "false";
           description
             "Enable ISIS segment-routing IPv6 with default Locator.";
         }
         leaf-list locator-name {
           when "../default-locator = 'false'" {
             description
               "Only applies to non default locator.";
           }
           type leafref {
             path "/rt:routing/sr:segment-routing/srv6:srv6"
                + "/srv6:locators/srv6:locator/srv6:name";
           }
           description
             "Enable ISIS segment-routing IPv6 with specified Locator.";
         }
         leaf persistent-end-x-sid {
           type boolean;
           default "false";
           description
             "Enable the persistent nature of End.X sid";
         }
         description
           "Configuration about ISIS segment-routing IPv6.";
       }
       container micro-loop-avoidance {
         leaf srv6-enable {
           type boolean;
           default "false";
           description
             "Enable SRv6 avoid-microloop.Depend on SR IPv6 Enable.";
         }
         leaf srv6-rib-update-delay {
           type uint16 {
             range "1000..10000";
           }
           units "ms";
           default "5000";
           description
             "Set the route delivery delay for SRv6 avoid-microloop.
              Depend on SR IPv6 Enable.";
         }
         description
           "Enable IS-IS avoid-microloop.";
       }
     }

     augment "/rt:routing/"



Hu, et al.              Expires 1 September 2024               [Page 16]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:fast-reroute" {
       when "derived-from-or-self(../../rt:type, 'isis:isis')" {
         description
           "This augment ISIS routing protocol when used";
       }
       description
         "This augments ISIS IPFRR with IPV6 TILFA.";
       container srv6-ti-lfa {
         if-feature "srv6-ti-lfa";
         leaf enable {
           type boolean;
           description
             "Enables SRv6 TI-LFA computation.";
         }
         description
           "SRv6 TILFA configuration.";
       }
     }

     /* Operational states */

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:database/isis:levels/isis:lsp"
           + "/isis:router-capabilities" {
       when "derived-from-or-self(../../../../../rt:type, 'isis:isis')" {
         description
           "This augment ISIS routing protocol when used";
       }
       description
         "This augments ISIS protocol router capability.";
       uses srv6-capability;
       uses srv6:srv6-msd-signaled;
     }

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:database/isis:levels/isis:lsp"
           + "/isis:extended-is-neighbor/isis:neighbor" {
       when "derived-from-or-self(../../../../../../rt:type,"
          + "'isis:isis')" {
         description
           "This augment ISIS routing protocol when used.";
       }
       description
         "This augments ISIS protocol neighbor.";
       container srv6-adjacency-sids {



Hu, et al.              Expires 1 September 2024               [Page 17]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


         description
           "This defines svr6 end-x sids for the adjacency.";
         list end-x-sid {
           key "sid";
           uses srv6-adjacency-sid;
           description
             "List of end-x sids.";
         }
       }
     }

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:database/isis:levels/isis:lsp"
           + "/isis:mt-is-neighbor/isis:neighbor" {
       when "derived-from-or-self(../../../../../../rt:type,"
          + "'isis:isis')" {
         description
           "This augment ISIS routing protocol when used.";
       }
       description
         "This augments ISIS protocol neighbor.";
       container srv6-adjacency-sids {
         description
           "This defines svr6 end-x sids for the adjacency.";
         list end-x-sid {
           key "sid";
           uses srv6-adjacency-sid;
           description
             "List of end-x sids.";
         }
       }
     }

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:database/isis:levels/isis:lsp" {
       when "derived-from-or-self(../../../../rt:type, 'isis:isis')" {
         description
           "This augment ISIS routing protocol when used.";
       }
       description
         "This augments ISIS protocol LSDB.";
       container srv6-locators {
         description
           "This defines srv6 locator tlvs.";
         list locator {
           key "locator";



Hu, et al.              Expires 1 September 2024               [Page 18]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


           uses srv6-locator;
           description
             "List of srv6 locators.";
         }
       }
     }

     augment "/rt:routing/"
           + "rt:control-plane-protocols/rt:control-plane-protocol"
           + "/isis:isis/isis:interfaces/isis:interface"
           + "/isis:adjacencies/isis:adjacency" {
       when "derived-from-or-self(../../../../../rt:type,"
          + "'isis:isis')" {
         description
           "This augment ISIS routing protocol when used.";
       }
       description
         "This augments ISIS protocol operational state
          with segment routing.";
       uses srv6-adjacency-state;
     }

     /* Notifications */
   }
   <CODE ENDS>

5.  Security Considerations

   The YANG modules specified in this document define a schema for data
   that is designed to be accessed via network management protocols such
   as NETCONF [RFC6241] or RESTCONF [RFC8040].  The lowest NETCONF layer
   is the secure transport layer, and the mandatory-to-implement secure
   transport is Secure Shell (SSH) [RFC6242].  The lowest RESTCONF layer
   is HTTPS, and the mandatory-to-implement secure transport is TLS
   [RFC8446].

   The Network Configuration Access Control Model (NACM) [RFC8341]
   provides the means to restrict access for particular NETCONF or
   RESTCONF users to a pre-configured subset of all available NETCONF or
   RESTCONF protocol operations and content.

   There are a number of data nodes defined in this YANG module that are
   writable/creatable/deletable (i.e., config true, which is the
   default).  These data nodes may be considered sensitive or vulnerable
   in some network environments.  Write operations (e.g., edit-config)
   to these data nodes without proper protection can have a negative
   effect on network operations.  These are the subtrees and data nodes
   and their sensitivity/vulnerability:



Hu, et al.              Expires 1 September 2024               [Page 19]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


      /isis:isis/srv6-cfg

      /isis:isis/micro-loop-avoidance

      /isis:isis/srv6-ti-lfa

   Writable data nodes represent the configuration of IS-IS SRv6, micro-
   loop avoidance and ti-lfa enablement.  The ability to modify IS-IS
   SRv6 related configuration may allow the entire IS-IS domain to be
   compromised, and traffic could be hijacked.

   Some of the readable data nodes in this YANG module may be considered
   sensitive or vulnerable in some network environments.  It is thus
   important to control read access (e.g., via get, get-config, or
   notification) to these data nodes.  These are the subtrees and data
   nodes and their sensitivity/vulnerability:

      /isis:lsp/isis:router-capabilities/v6-capability

      /isis:lsp/isis:router-capabilities/srv6-msd

      /isis:lsp/isis:extended-is-neighbor/isis:neighbor/srv6-adjacency-
      sids

      /isis:lsp/isis:mt-is-neighbor/isis:neighbor/srv6-adjacency-sids

      /isis:lsp/srv6-locators

      /isis:interface/isis:adjacencies/isis:adjacency/end-x-sid

   Exposure of the LSDB will expose the detailed topology of the network
   and router capabilities, and may facilitate other attacks.

6.  Contributors

   Jiajia Dong
   Huawei
   China

   Email:dongjiajia@huawei.com

7.  Acknowledgements

   TBD.







Hu, et al.              Expires 1 September 2024               [Page 20]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


8.  IANA Considerations

   The IANA is requested to assign two new URIs from the IETF XML
   registry ([RFC3688]).  Authors are suggesting the following URI:

               URI: urn:ietf:params:xml:ns:yang:ietf-isis-srv6
               Registrant Contact: IS-IS WG
               XML: N/A, the requested URI is an XML namespace

   This document also requests one new YANG module name in the YANG
   Module Names registry ([RFC6020]) with the following suggestion :

  name: ietf-isis-srv6
  namespace: urn:ietf:params:xml:ns:yang:ietf-isis-srv6 prefix: isis-srv6
  reference: RFC XXXX

9.  References

9.1.  Normative References

   [I-D.ietf-spring-srv6-yang]
              Raza, S., Agarwal, S., Liu, X., Hu, Z., Hussain, I., Shah,
              H. C., Voyer, D., Matsushima, S., Horiba, K.,
              Rajamanickam, J., and A. Abdelsalam, "YANG Data Model for
              SRv6 Base and Static", Work in Progress, Internet-Draft,
              draft-ietf-spring-srv6-yang-02, 23 September 2022,
              <https://www.ietf.org/archive/id/draft-ietf-spring-srv6-
              yang-02.txt>.

   [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>.

   [RFC3688]  Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688,
              DOI 10.17487/RFC3688, January 2004,
              <https://www.rfc-editor.org/info/rfc3688>.

   [RFC6020]  Bjorklund, M., Ed., "YANG - A Data Modeling Language for
              the Network Configuration Protocol (NETCONF)", RFC 6020,
              DOI 10.17487/RFC6020, October 2010,
              <https://www.rfc-editor.org/info/rfc6020>.

   [RFC6241]  Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed.,
              and A. Bierman, Ed., "Network Configuration Protocol
              (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011,
              <https://www.rfc-editor.org/info/rfc6241>.




Hu, et al.              Expires 1 September 2024               [Page 21]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


   [RFC6242]  Wasserman, M., "Using the NETCONF Protocol over Secure
              Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011,
              <https://www.rfc-editor.org/info/rfc6242>.

   [RFC6991]  Schoenwaelder, J., Ed., "Common YANG Data Types",
              RFC 6991, DOI 10.17487/RFC6991, July 2013,
              <https://www.rfc-editor.org/info/rfc6991>.

   [RFC7950]  Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language",
              RFC 7950, DOI 10.17487/RFC7950, August 2016,
              <https://www.rfc-editor.org/info/rfc7950>.

   [RFC8040]  Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF
              Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017,
              <https://www.rfc-editor.org/info/rfc8040>.

   [RFC8341]  Bierman, A. and M. Bjorklund, "Network Configuration
              Access Control Model", STD 91, RFC 8341,
              DOI 10.17487/RFC8341, March 2018,
              <https://www.rfc-editor.org/info/rfc8341>.

   [RFC8349]  Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for
              Routing Management (NMDA Version)", RFC 8349,
              DOI 10.17487/RFC8349, March 2018,
              <https://www.rfc-editor.org/info/rfc8349>.

   [RFC8446]  Rescorla, E., "The Transport Layer Security (TLS) Protocol
              Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018,
              <https://www.rfc-editor.org/info/rfc8446>.

   [RFC9020]  Litkowski, S., Qu, Y., Lindem, A., Sarkar, P., and J.
              Tantsura, "YANG Data Model for Segment Routing", RFC 9020,
              DOI 10.17487/RFC9020, 25 January 2021,
              <https://www.rfc-editor.org/info/rfc9020>.

   [RFC9130]  Litkowski, S., Yeung, D., Lindem, A., Zhang, J., and L.
              Lhotka, "YANG Data Model for IS-IS Protocol", RFC 9130,
              DOI 10.17487/RFC9130, 15 October 2019,
              <https://www.rfc-editor.org/info/rfc9130>.

   [RFC9352]  Psenak, P., Filsfils, C., Bashandy, A., Decraene, B., and
              Z. Hu, "IS-IS Extensions to Support Segment Routing over
              the IPv6 Dataplane", RFC 9352, DOI 10.17487/RFC9352, 20
              October 2021, <https://www.rfc-editor.org/info/rfc9352>.







Hu, et al.              Expires 1 September 2024               [Page 22]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


Appendix A.  Configuration examples

   The following is an XML example using IS-IS SRv6 YANG module.

      <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
        <control-plane-protocols>
       <control-plane-protocol>
         <isis xmlns="urn:ietf:params:xml:ns:yang:ietf-isis">
        <srv6-cfg>
         <enable>true</enable>
      <default-locator>false</default-locator>
      <locator-name>DOM0_ALG0</locator-name>
      <persistent-end-x-sid>true</persistent-end-x-sid>
        </srv6-cfg>
        <micro-loop-avoidance>
         <srv6-enable>true</srv6-enable>
      <srv6-rib-update-delay>2000</srv6-rib-update-delay>
        </micro-loop-avoidance>
      </isis>
       </control-plane-protocol>
     </control-plane-protocols>
      </routing>

      <routing xmlns="urn:ietf:params:xml:ns:yang:ietf-routing">
        <control-plane-protocols>
       <control-plane-protocol>
         <isis xmlns="urn:ietf:params:xml:ns:yang:ietf-isis">
              <fast-reroute>
         <srv6-ti-lfa>
        <enable>true</enable>
      </srv6-ti-lfa>
        </fast-reroute>
      </isis>
       </control-plane-protocol>
     </control-plane-protocols>
      </routing>

   The following is the corresponding example using JSON format.













Hu, et al.              Expires 1 September 2024               [Page 23]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


   {
      "control-plane-protocols": {
         "control-plane-protocol": {
            "isis": {
               "srv6-cfg": {
                  "enable": "true",
                  "default-locator": "false",
                  "locator-name": "DOM0_ALG0",
                  "persistent-end-x-sid": "true"
               },
               "micro-loop-avoidance": {
                  "srv6-enable": "true",
                  "srv6-rib-update-delay": "2000"
               }
            }
         }
      }
   }

   {
      "control-plane-protocols": {
         "control-plane-protocol": {
            "isis": {
               "fast-reroute": {
                  "srv6-ti-lfa": {
                     "enable": "true"
                  }
               }
            }
         }
      }
   }

Authors' Addresses

   Zhibo Hu
   Huawei
   Huawei Bld., No.156 Beiqing Rd.
   Beijing
   100095
   China
   Email: huzhibo@huawei.com









Hu, et al.              Expires 1 September 2024               [Page 24]

Internet-Draft       YANG Data Model for IS-IS SRv6        February 2024


   Dan Ye
   Cisco
   170 W. Tasman Dr. San Jose,
   California,  95134
   United States of America
   Email: daye@cisco.com


   Yingzhen Qu
   Futurewei Technologies
   2330 Central Express Way
   Santa Clara,  950950
   United States of America
   Email: yingzhen.ietf@gmail.com


   Xuesong Geng
   Huawei
   Huawei Bld., No.156 Beiqing Rd.
   Beijing
   100095
   China
   Email: gengxuesong@huawei.com


   Qiufang Ma
   Huawei
   101 Software Avenue, Yuhua District
   Nanjing
   Jiangsu, 210012
   China
   Email: maqiufang1@huawei.com



















Hu, et al.              Expires 1 September 2024               [Page 25]