idnits 2.17.1 draft-ietf-spring-sr-yang-24.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 160 has weird spacing: '...terface if:...' == Line 190 has weird spacing: '...r-bound uin...' == Line 191 has weird spacing: '...r-bound uin...' == Line 194 has weird spacing: '...r-bound uin...' == Line 195 has weird spacing: '...r-bound uin...' == (1 more instance...) -- The document date (November 24, 2020) is 1239 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 6536 (Obsoleted by RFC 8341) Summary: 2 errors (**), 0 flaws (~~), 7 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 SPRING Working Group S. Litkowski 3 Internet-Draft Cisco Systems 4 Intended status: Standards Track Y. Qu 5 Expires: May 28, 2021 Futurewei 6 A. Lindem 7 Cisco Systems 8 P. Sarkar 9 Individual 10 J. Tantsura 11 Apstra 12 November 24, 2020 14 YANG Data Model for Segment Routing 15 draft-ietf-spring-sr-yang-24 17 Abstract 19 This document defines a YANG data model for segment routing 20 configuration and operation, which is to be augmented by different 21 segment routing data planes. The document also defines a YANG model 22 that is intended to be used on network elements to configure or 23 operate segment routing MPLS data plane, as well as some generic 24 containers to be reused by IGP protocol modules to support segment 25 routing. 27 Status of This Memo 29 This Internet-Draft is submitted in full conformance with the 30 provisions of BCP 78 and BCP 79. 32 Internet-Drafts are working documents of the Internet Engineering 33 Task Force (IETF). Note that other groups may also distribute 34 working documents as Internet-Drafts. The list of current Internet- 35 Drafts is at https://datatracker.ietf.org/drafts/current/. 37 Internet-Drafts are draft documents valid for a maximum of six months 38 and may be updated, replaced, or obsoleted by other documents at any 39 time. It is inappropriate to use Internet-Drafts as reference 40 material or to cite them other than as "work in progress." 42 This Internet-Draft will expire on May 28, 2021. 44 Copyright Notice 46 Copyright (c) 2020 IETF Trust and the persons identified as the 47 document authors. All rights reserved. 49 This document is subject to BCP 78 and the IETF Trust's Legal 50 Provisions Relating to IETF Documents 51 (https://trustee.ietf.org/license-info) in effect on the date of 52 publication of this document. Please review these documents 53 carefully, as they describe your rights and restrictions with respect 54 to this document. Code Components extracted from this document must 55 include Simplified BSD License text as described in Section 4.e of 56 the Trust Legal Provisions and are provided without warranty as 57 described in the Simplified BSD License. 59 Table of Contents 61 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 62 2. Terminology and Notation . . . . . . . . . . . . . . . . . . 3 63 2.1. Tree diagram . . . . . . . . . . . . . . . . . . . . . . 3 64 2.2. Prefixes in Data Node Names . . . . . . . . . . . . . . . 3 65 3. Design of the Data Model . . . . . . . . . . . . . . . . . . 3 66 4. Configuration . . . . . . . . . . . . . . . . . . . . . . . . 6 67 5. IGP Control plane configuration . . . . . . . . . . . . . . . 6 68 5.1. IGP interface configuration . . . . . . . . . . . . . . . 7 69 5.1.1. Adjacency SID properties . . . . . . . . . . . . . . 7 70 5.1.1.1. Bundling . . . . . . . . . . . . . . . . . . . . 7 71 5.1.1.2. Protection . . . . . . . . . . . . . . . . . . . 8 72 6. State Data . . . . . . . . . . . . . . . . . . . . . . . . . 8 73 7. Notifications . . . . . . . . . . . . . . . . . . . . . . . . 8 74 8. YANG Modules . . . . . . . . . . . . . . . . . . . . . . . . 8 75 8.1. YANG Module for Segment Routing . . . . . . . . . . . . . 9 76 8.2. YANG Module for Segment Routing Common Types . . . . . . 10 77 8.3. YANG Module for Segment Routing MPLS . . . . . . . . . . 16 78 9. Security Considerations . . . . . . . . . . . . . . . . . . . 28 79 10. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 29 80 11. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 29 81 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 30 82 12.1. Normative References . . . . . . . . . . . . . . . . . . 30 83 12.2. Informative References . . . . . . . . . . . . . . . . . 32 84 Appendix A. Configuration examples . . . . . . . . . . . . . . . 32 85 A.1. SR MPLS with IPv4 . . . . . . . . . . . . . . . . . . . . 32 86 A.2. SR MPLS with IPv6 . . . . . . . . . . . . . . . . . . . . 35 87 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 38 89 1. Introduction 91 This document defines a YANG data model [RFC7950] for segment routing 92 [RFC8402] configuration and operation. The document also defines a 93 YANG model that is intended to be used on network elements to 94 configure or operate segment routing MPLS data plane [RFC8660]. This 95 document does not define the IGP extensions to support segment 96 routing but defines generic groupings that SHOULD be reused by IGP 97 extension modules. The reason of this design choice is to not 98 require implementations to support all IGP extensions. For example, 99 an implementation may support IS-IS extension but not OSPF. 101 The YANG modules in this document conform to the Network Management 102 Datastore Architecture (NMDA) [RFC8342]. 104 2. Terminology and Notation 106 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 107 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 108 "OPTIONAL" in this document are to be interpreted as described in BCP 109 14 [RFC2119] [RFC8174] when, and only when, they appear in all 110 capitals, as shown here. 112 2.1. Tree diagram 114 Tree diagrams used in this document follow the notation defined in 115 [RFC8340]. 117 2.2. Prefixes in Data Node Names 119 In this document, names of data nodes, actions, and other data model 120 objects are often used without a prefix, as long as it is clear from 121 the context in which YANG module each name is defined. Otherwise, 122 names are prefixed using the standard prefix associated with the 123 corresponding YANG module, as shown in Table 1. 125 +----------+--------------------+-----------+ 126 | Prefix | YANG module | Reference | 127 +----------+--------------------+-----------+ 128 | if | ietf-interfaces | [RFC8343] | 129 | rt | ietf-routing | [RFC8349] | 130 | rt-types | ietf-routing-types | [RFC8294] | 131 | yang | ietf-yang-types | [RFC6991] | 132 | inet | ietf-inet-types | [RFC6991] | 133 +----------+--------------------+-----------+ 135 Table 1: Prefixes and Corresponding YANG Modules 137 3. Design of the Data Model 139 Module ietf-segment-routing augments the routing container in the 140 ietf-routing model [RFC8349], and defines generic segment routing 141 configuration and operational state. This module is augmented by 142 modules supporting different data planes. 144 Module ietf-segment-routing-mpls augments ietf-segment-routing, and 145 supports SR MPLS data plane configuration and operational state. 147 module: ietf-segment-routing 148 augment /rt:routing: 149 +--rw segment-routing 151 module: ietf-segment-routing-mpls 152 augment /rt:routing/sr:segment-routing: 153 +--rw sr-mpls 154 +--ro node-capabilities 155 | +--ro entropy-readable-label-depth? uint8 156 +--rw msd {max-sid-depth}? 157 | +--rw node-msd? uint8 158 | +--rw link-msds 159 | +--rw link-msds* [interface] 160 | +--rw interface if:interface-ref 161 | +--rw msd? uint8 162 +--rw bindings 163 | +--rw mapping-server {mapping-server}? 164 | | +--rw policy* [name] 165 | | +--rw name string 166 | | +--rw entries 167 | | +--rw mapping-entry* [prefix algorithm] 168 | | +--rw prefix inet:ip-prefix 169 | | +--rw value-type? enumeration 170 | | +--rw start-sid uint32 171 | | +--rw range? uint32 172 | | +--rw algorithm identityref 173 | +--rw connected-prefix-sid-map 174 | | +--rw connected-prefix-sid* [prefix algorithm] 175 | | +--rw prefix inet:ip-prefix 176 | | +--rw value-type? enumeration 177 | | +--rw start-sid uint32 178 | | +--rw range? uint32 179 | | +--rw algorithm identityref 180 | | +--rw last-hop-behavior? enumeration 181 | +--rw local-prefix-sid 182 | +--rw local-prefix-sid* [prefix algorithm] 183 | +--rw prefix inet:ip-prefix 184 | +--rw value-type? enumeration 185 | +--rw start-sid uint32 186 | +--rw range? uint32 187 | +--rw algorithm identityref 188 +--rw global-srgb 189 | +--rw srgb* [lower-bound upper-bound] 190 | +--rw lower-bound uint32 191 | +--rw upper-bound uint32 192 +--rw srlb 193 | +--rw srlb* [lower-bound upper-bound] 194 | +--rw lower-bound uint32 195 | +--rw upper-bound uint32 196 +--ro label-blocks* [] 197 | +--ro lower-bound? uint32 198 | +--ro upper-bound? uint32 199 | +--ro size? uint32 200 | +--ro free? uint32 201 | +--ro used? uint32 202 | +--ro scope? enumeration 203 +--ro sid-db 204 +--ro sid* [target sid source source-protocol binding-type] 205 +--ro target string 206 +--ro sid uint32 207 +--ro algorithm? uint8 208 +--ro source inet:ip-address 209 +--ro used? boolean 210 +--ro source-protocol -> /rt:routing 211 /control-plane-protocols 212 /control-plane-protocol/name 213 +--ro binding-type enumeration 214 +--ro scope? enumeration 216 notifications: 217 +---n segment-routing-global-srgb-collision 218 | +--ro srgb-collisions* [] 219 | +--ro lower-bound? uint32 220 | +--ro upper-bound? uint32 221 | +--ro routing-protocol? -> /rt:routing 222 | /control-plane-protocols 223 | /control-plane-protocol/name 224 | +--ro originating-rtr-id? router-or-system-id 225 +---n segment-routing-global-sid-collision 226 | +--ro received-target? string 227 | +--ro new-sid-rtr-id? router-or-system-id 228 | +--ro original-target? string 229 | +--ro original-sid-rtr-id? router-or-system-id 230 | +--ro index? uint32 231 | +--ro routing-protocol? -> /rt:routing 232 | /control-plane-protocols 233 | /control-plane-protocol/name 234 +---n segment-routing-index-out-of-range 235 +--ro received-target? string 236 +--ro received-index? uint32 237 +--ro routing-protocol? -> /rt:routing 238 /control-plane-protocols 239 /control-plane-protocol/name 241 4. Configuration 243 The module ietf-segment-routing-mpls augments the "/rt:routing/ 244 sr:segment-routing:" with a sr-mpls container. This container 245 defines all the configuration parameters related to segment-routing 246 MPLS data plane. 248 The sr-mpls configuration is split in global configuration and 249 interface configuration. 251 The global configuration includes : 253 o bindings : Defines prefix to SID mappings. The operator can 254 control advertisement of Prefix-SID independently for IPv4 and 255 IPv6. Two types of mappings are available: 257 * Mapping-server : maps non local prefixes to a segment ID. 258 Configuration of bindings does not automatically allow 259 advertisement of those bindings. Advertisement must be 260 controlled by each routing-protocol instance (see Section 5). 261 Multiple mapping policies may be defined. 263 * Connected prefixes : maps connected prefixes to a segment ID. 264 Advertisement of the mapping will be done by IGP when enabled 265 for segment routing (see Section 5). The SID value can be 266 expressed as an index (default), or an absolute value. The 267 "last-hop-behavior" configuration dictates the PHP behavior: 268 "explicit-null", "php", or "non-php". 270 o SRGB (Segment Routing Global Block): Defines a list of label 271 blocks represented by a pair of lower-bound/upper-bound labels. 272 The SRGB is also agnostic to the control plane used. So all 273 routing-protocol instance will have to advertise the same SRGB. 275 o SRLB (Segment Routing Local Block): Defines a list of label blocks 276 represented by a pair of lower-bound/upper-bound labels, reserved 277 for local SIDs. 279 5. IGP Control plane configuration 281 Support of segment-routing extensions for a particular IGP control 282 plane is done by augmenting routing-protocol configuration with 283 segment-routing extensions. This augmentation SHOULD be part of 284 separate YANG modules in order to not create any dependency for 285 implementations to support all protocol extensions. 287 This module defines groupings that SHOULD be used by IGP segment 288 routing modules. 290 The "sr-control-plane" grouping defines the generic global 291 configuration for the IGP. 293 The "enabled" leaf enables segment-routing extensions for the 294 routing-protocol instance. 296 The "bindings" container controls the routing-protocol instance's 297 advertisement of local bindings and the processing of received 298 bindings. 300 5.1. IGP interface configuration 302 The interface configuration is part of the "igp-interface" grouping 303 and includes Adjacency SID properties. 305 5.1.1. Adjacency SID properties 307 5.1.1.1. Bundling 309 In case of parallel IP links between routers, an additional Adjacency 310 SID [RFC8402] may be advertised representing more than one adjacency 311 (i.e., a bundle of adjacencies). The "advertise-adj-group-sid" 312 configuration controls whether or not an additional adjacency SID is 313 advertised. 315 The "advertise-adj-group-sid" is a list of "group-id". The "group- 316 id" will identify interfaces that are bundled together. 318 +-------+ +------+ 319 | | ------- L1 ---- | | 320 | R1 | ------- L2 ---- | R2 | 321 | | ------- L3 ---- | | 322 | | ------- L4 ---- | | 323 +-------+ +------+ 325 In the figure above, R1 and R2 are interconnected by four links. A 326 routing protocol adjacency is established on each link. Operator 327 would like to create segment-routing Adj-SID that represent some 328 bundles of links. We can imagine two different bundles : L1/L2 and 329 L3/L4. To achieve this behavior, the service provider will configure 330 a "group-id" X for both interfaces L1 and L2 and a "group-id" Y for 331 both interfaces L3 and L4. This will result in R1 advertising an 332 additional Adj-SID for each adjacency, for example a Adj-SID with S 333 flag set and value of 400 will be added to L1 and L2. A Adj-SID with 334 S flag set and value of 500 will be added to L3 and L4. As L1/L2 and 335 L3/L4 does not share the same "group-id", a different SID value will 336 be allocated. 338 5.1.1.2. Protection 340 The "advertise-protection" defines how protection for an interface is 341 advertised. It does not control the activation or deactivation of 342 protection. If the "single" option is used, a single Adj-SID will be 343 advertised for the interface. If the interface is protected, the 344 B-Flag for the Adj-SID advertisement will be set. If the "dual" 345 option is used and if the interface is protected, two Adj-SIDs will 346 be advertised for the interface adjacencies. One Adj-SID will always 347 have the B-Flag set and the other will have the B-Flag clear. This 348 option is intended to be used in the case of traffic engineering 349 where a path must use either protected segments or non-protected 350 segments. 352 6. State Data 354 The operational states contain information reflecting the usage of 355 allocated SRGB labels. 357 It also includes a list of all global SIDs, their associated 358 bindings, and other information such as the source protocol and 359 algorithm. 361 7. Notifications 363 The model defines the following notifications for segment-routing. 365 o segment-routing-global-srgb-collision: Raised when a control plane 366 advertised SRGB blocks have conflicts. 368 o segment-routing-global-sid-collision: Raised when a control plane 369 advertised index is already associated with another target (in 370 this version, the only defined targets are IPv4 and IPv6 371 prefixes). 373 o segment-routing-index-out-of-range: Raised when a control plane 374 advertised index falls outside the range of SRGBs configured for 375 the network device. 377 8. YANG Modules 379 There are three YANG modules included in this document. 381 The following RFCs and drafts are not referenced in the document text 382 but are referenced in the ietf-segment-routing-common.yang and/or 383 ietf-segment-routing.yang module: [RFC6991], [RFC8294], [RFC8476], 384 [RFC8491], [RFC8665], and [RFC8667]. 386 8.1. YANG Module for Segment Routing 388 ietf-segment-routing.yang: This module defines a generic framework 389 for Segment Routing, and it is to be augmented by models for 390 different SR data planes. 392 file "ietf-segment-routing@2020-11-24.yang" 393 module ietf-segment-routing { 394 yang-version 1.1; 395 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing"; 396 prefix sr; 398 import ietf-routing { 399 prefix rt; 400 reference "RFC 8349: A YANG Data Model for Routing 401 Management (NMDA Version)"; 402 } 404 organization 405 "IETF SPRING - SPRING Working Group"; 406 contact 407 "WG Web: 408 WG List: 410 Author: Stephane Litkowski 411 412 Author: Yingzhen Qu 413 414 Author: Acee Lindem 415 416 Author: Pushpasis Sarkar 417 418 Author: Jeff Tantsura 419 421 "; 422 description 423 "The YANG module defines a generic framework for Segment 424 Routing. It is to be augmented by models for different 425 SR data planes. 427 This YANG model conforms to the Network Management 428 Datastore Architecture (NMDA) as described in RFC 8242. 430 Copyright (c) 2020 IETF Trust and the persons identified as 431 authors of the code. All rights reserved. 433 Redistribution and use in source and binary forms, with or 434 without modification, is permitted pursuant to, and subject 435 to the license terms contained in, the Simplified BSD License 436 set forth in Section 4.c of the IETF Trust's Legal Provisions 437 Relating to IETF Documents 438 (http://trustee.ietf.org/license-info). 440 This version of this YANG module is part of RFC XXXX; 441 see the RFC itself for full legal notices. 443 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 444 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 445 'MAY', and 'OPTIONAL' in this document are to be interpreted as 446 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 447 they appear in all capitals, as shown here."; 449 reference "RFC XXXX: YANG Data Model for Segment Routing."; 451 revision 2020-11-24 { 452 description 453 "Initial Version"; 454 reference "RFC XXXX: YANG Data Model for Segment Routing."; 455 } 457 augment "/rt:routing" { 458 description 459 "This module augments routing data model (RFC 8349) 460 with Segment Routing (SR)."; 461 container segment-routing { 462 description 463 "Segment Routing configuration. This container 464 is to be augmented by models for different SR 465 data planes."; 466 reference "RFC 8402: Segment Routing Architecture."; 467 } 468 } 469 } 470 472 8.2. YANG Module for Segment Routing Common Types 474 ietf-segment-routing-common.yang: This module defines a collection of 475 generic types and groupings for SR as defined in [RFC8402]. 477 file "ietf-segment-routing-common@2020-11-24.yang" 478 module ietf-segment-routing-common { 479 yang-version 1.1; 480 namespace 481 "urn:ietf:params:xml:ns:yang:ietf-segment-routing-common"; 482 prefix sr-cmn; 484 import ietf-inet-types { 485 prefix inet; 486 reference "RFC 6991: Common YANG Data Types"; 487 } 489 organization 490 "IETF SPRING - SPRING Working Group"; 492 contact 493 "WG Web: 494 WG List: 496 Author: Stephane Litkowski 497 498 Author: Yingzhen Qu 499 500 Author: Acee Lindem 501 502 Author: Pushpasis Sarkar 503 504 Author: Jeff Tantsura 505 507 "; 508 description 509 "The YANG module defines a collection of generic types and 510 groupings for Segment Routing (SR) as described in RFC 8402. 512 This YANG model conforms to the Network Management 513 Datastore Architecture (NMDA) as described in RFC 8242. 515 Copyright (c) 2020 IETF Trust and the persons identified as 516 authors of the code. All rights reserved. 518 Redistribution and use in source and binary forms, with or 519 without modification, is permitted pursuant to, and subject 520 to the license terms contained in, the Simplified BSD License 521 set forth in Section 4.c of the IETF Trust's Legal Provisions 522 Relating to IETF Documents 523 (http://trustee.ietf.org/license-info). 525 This version of this YANG module is part of RFC XXXX; 526 see the RFC itself for full legal notices. 528 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 529 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 530 'MAY', and 'OPTIONAL' in this document are to be interpreted as 531 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 532 they appear in all capitals, as shown here."; 534 reference "RFC XXXX: YANG Data Model for Segment Routing."; 536 revision 2020-11-24 { 537 description 538 "Initial version"; 539 reference "RFC XXXX: YANG Data Model for Segment Routing."; 540 } 542 feature sid-last-hop-behavior { 543 description 544 "Configurable last hop behavior."; 545 reference "RFC 8660: Segment Routing with the MPLS Data Plane"; 546 } 548 identity prefix-sid-algorithm { 549 description 550 "Base identity for prefix-sid algorithm."; 551 reference "RFC 8402: Segment Routing Architecture"; 552 } 554 identity prefix-sid-algorithm-shortest-path { 555 base prefix-sid-algorithm; 556 description 557 "Shortest Path First (SPF) prefix-sid algorithm. This 558 is the default algorithm."; 559 } 561 identity prefix-sid-algorithm-strict-spf { 562 base prefix-sid-algorithm; 563 description 564 "This algorithm mandates that the packet is forwarded 565 according to ECMP-aware SPF algorithm."; 566 } 568 grouping srlr { 569 description 570 "Grouping for SR Label Range configuration."; 571 leaf lower-bound { 572 type uint32; 573 description 574 "Lower value in the label range."; 575 } 576 leaf upper-bound { 577 type uint32; 578 must "../lower-bound < ../upper-bound" { 579 error-message 580 "The upper-bound must be greater than the lower-bound."; 581 description 582 "The value must be greater than 'lower-bound'."; 583 } 584 description 585 "Upper value in the label range."; 586 } 587 } 589 grouping srgb { 590 description 591 "Grouping for SR Global Label range."; 592 list srgb { 593 key "lower-bound upper-bound"; 594 ordered-by user; 595 description 596 "List of global blocks to be advertised."; 597 uses srlr; 598 } 599 } 601 grouping srlb { 602 description 603 "Grouping for SR Local Block range."; 604 list srlb { 605 key "lower-bound upper-bound"; 606 ordered-by user; 607 description 608 "List of SRLBs."; 609 uses srlr; 610 } 611 } 613 grouping sid-value-type { 614 description 615 "Defines how the SID value is expressed."; 616 leaf value-type { 617 type enumeration { 618 enum "index" { 619 description 620 "The value will be interpreted as an index."; 621 } 622 enum "absolute" { 623 description 624 "The value will become interpreted as an absolute 625 value."; 626 } 627 } 628 default "index"; 629 description 630 "This leaf defines how value must be interpreted."; 631 } 632 } 634 grouping prefix-sid { 635 description 636 "This grouping defines cfg of prefix SID."; 637 leaf prefix { 638 type inet:ip-prefix; 639 description 640 "connected prefix sid."; 641 } 642 uses prefix-sid-attributes; 643 } 645 grouping ipv4-sid { 646 description 647 "Grouping for an IPv4 prefix SID."; 648 leaf prefix { 649 type inet:ipv4-prefix; 650 description 651 "Connected IPv4 prefix sid."; 652 } 653 uses prefix-sid-attributes; 654 } 655 grouping ipv6-sid { 656 description 657 "Grouping for an IPv6 prefix SID."; 658 leaf prefix { 659 type inet:ipv6-prefix; 660 description 661 "Connected ipv6 prefix sid."; 662 } 663 uses prefix-sid-attributes; 664 } 666 grouping last-hop-behavior { 667 description 668 "Defines last hop behavior"; 669 leaf last-hop-behavior { 670 if-feature "sid-last-hop-behavior"; 671 type enumeration { 672 enum "explicit-null" { 673 description 674 "Use explicit-null for the SID."; 675 } 676 enum "no-php" { 677 description 678 "Do not use Penultimate Hop Popping (PHP) 679 for the SID."; 680 } 681 enum "php" { 682 description 683 "Use PHP for the SID."; 684 } 685 } 686 description 687 "Configure last hop behavior."; 688 } 689 } 691 grouping node-capabilities { 692 description 693 "Containing SR node capabilities."; 694 container node-capabilities { 695 config false; 696 description 697 "Shows the SR capability of the node."; 698 leaf entropy-readable-label-depth { 699 type uint8; 700 description 701 "Maximum label stack depth that a router can read."; 702 } 703 } 704 } 706 grouping prefix-sid-attributes { 707 description 708 "Grouping for Segment Routing (SR) prefix attributes."; 709 uses sid-value-type; 710 leaf start-sid { 711 type uint32; 712 mandatory true; 713 description 714 "Value associated with prefix. The value must be 715 interpreted in the context of value-type."; 716 } 717 leaf range { 718 type uint32; 719 description 720 "Indicates how many SIDs can be allocated."; 722 } 723 leaf algorithm { 724 type identityref { 725 base prefix-sid-algorithm; 726 } 727 description 728 "Prefix-sid algorithm."; 729 } 730 } 731 } 732 734 8.3. YANG Module for Segment Routing MPLS 736 ietf-segment-routing-mpls.yang: This module defines the configuration 737 and operational states for Segment Routing MPLS data plane. 739 file "ietf-segment-routing-mpls@2020-11-24.yang" 740 module ietf-segment-routing-mpls { 741 yang-version 1.1; 742 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls"; 743 prefix sr-mpls; 745 import ietf-inet-types { 746 prefix inet; 747 reference "RFC 6991: Common YANG Data Types"; 748 } 749 import ietf-routing { 750 prefix rt; 751 reference "RFC 8349: A YANG Data Model for Routing 752 Management (NMDA Version)"; 753 } 754 import ietf-interfaces { 755 prefix if; 756 reference "RFC 8343: A YANG Data Model for Interface 757 Management (NMDA Version)"; 758 } 759 import ietf-routing-types { 760 prefix rt-types; 761 reference "RFC 8294: Common YANG Data Types for the 762 Routing Area"; 763 } 764 import ietf-segment-routing { 765 prefix sr; 766 reference "RFC XXXX: YANG Data Model for Segment Routing."; 767 } 768 import ietf-segment-routing-common { 769 prefix sr-cmn; 770 reference "RFC XXXX: YANG Data Model for Segment Routing."; 771 } 773 organization 774 "IETF SPRING - SPRING Working Group"; 775 contact 776 "WG Web: 777 WG List: 779 Author: Stephane Litkowski 780 781 Author: Yingzhen Qu 782 783 Author: Acee Lindem 784 785 Author: Pushpasis Sarkar 786 787 Author: Jeff Tantsura 788 790 "; 791 description 792 "The YANG module defines a generic configuration model for 793 Segment Routing MPLS data plane. 795 This YANG model conforms to the Network Management 796 Datastore Architecture (NMDA) as described in RFC 8242. 798 Copyright (c) 2020 IETF Trust and the persons identified as 799 authors of the code. All rights reserved. 801 Redistribution and use in source and binary forms, with or 802 without modification, is permitted pursuant to, and subject 803 to the license terms contained in, the Simplified BSD License 804 set forth in Section 4.c of the IETF Trust's Legal Provisions 805 Relating to IETF Documents 806 (http://trustee.ietf.org/license-info). 808 This version of this YANG module is part of RFC XXXX; 809 see the RFC itself for full legal notices. 811 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 812 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 813 'MAY', and 'OPTIONAL' in this document are to be interpreted as 814 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 815 they appear in all capitals, as shown here."; 817 reference "RFC XXXX: YANG Data Model for Segment Routing."; 818 revision 2020-11-24 { 819 description 820 "Initial Version"; 821 reference "RFC XXXX: YANG Data Model for Segment Routing."; 822 } 824 feature mapping-server { 825 description 826 "Support for Segment Routing Mapping Server (SRMS)."; 827 reference "RFC 8661: Segment Routing MPLS Interworking 828 with LDP"; 829 } 831 feature protocol-srgb { 832 description 833 "Support for per-protocol Segment Routing Global Block 834 (SRGB) configuration."; 835 reference "RFC 8660: Segment Routing with the MPLS 836 Data Plane"; 837 } 839 feature max-sid-depth { 840 description 841 "Support for signaling MSD (Maximum SID Depth) in IGP."; 842 reference "RFC 8476: Signaling Maximum SID Depth (MSD) 843 Using OSPF 844 RFC 8491: Signaling Maximum SID Depth (MSD) 845 Using IS-IS"; 846 } 848 typedef system-id { 849 type string { 850 pattern 851 '[0-9A-Fa-f]{4}\.[0-9A-Fa-f]{4}\.[0-9A-Fa-f]{4}'; 852 } 853 description 854 "This type defines IS-IS system-id using pattern, 855 An example system-id is 0143.0438.AEF0"; 856 } 858 typedef router-or-system-id { 859 type union { 860 type rt-types:router-id; 861 type system-id; 862 } 863 description 864 "OSPF/BGP router-id or ISIS system ID."; 865 } 866 grouping sr-control-plane { 867 description 868 "Defines protocol configuration."; 869 container segment-routing { 870 description 871 "Segment Routing global configuration."; 872 leaf enabled { 873 type boolean; 874 default "false"; 875 description 876 "Enables segment-routing protocol extensions."; 877 } 878 container bindings { 879 if-feature mapping-server; 880 description 881 "Control of binding advertisement and reception."; 882 container advertise { 883 description 884 "Control advertisement of local mappings 885 in binding TLVs."; 886 leaf-list policies { 887 type leafref { 888 path "/rt:routing/sr:segment-routing/sr-mpls:sr-mpls" 889 + "/sr-mpls:bindings/sr-mpls:mapping-server" 890 + "/sr-mpls:policy/sr-mpls:name"; 891 } 892 description 893 "List of binding advertisement policies."; 894 } 895 } 896 leaf receive { 897 type boolean; 898 default "true"; 899 description 900 "Allow the reception and usage of binding TLVs."; 901 } 902 } 903 } 904 } 906 grouping igp-interface { 907 description 908 "Grouping for IGP interface configuration."; 909 container segment-routing { 910 description 911 "Container for SR interface configuration."; 912 container adjacency-sid { 913 description 914 "Adjacency SID configuration."; 915 reference "RFC 8660: Segment Routing with the MPLS 916 Data Plane"; 917 list adj-sids { 918 key "value"; 919 uses sr-cmn:sid-value-type; 920 leaf value { 921 type uint32; 922 description 923 "Value of the Adj-SID."; 924 } 925 leaf protected { 926 type boolean; 927 default false; 928 description 929 "It is used to protect the manual adj-SID, e.g. using 930 IPFRR or MPLS-FRR."; 931 } 932 leaf weight { 933 type uint8; 934 description 935 "The load-balancing factor over parallel adjacencies."; 936 reference "RFC 8402: Segment Routing Architecture 937 RFC 8665: OSPF Extensions for Segment Routing 938 RFC 8667: IS-IS Extensions for Segment 939 Routing"; 940 } 941 description 942 "List of adj-sid configuration."; 943 } 944 list advertise-adj-group-sid { 945 key "group-id"; 946 description 947 "Control advertisement of S or G flag. Enable advertisement 948 of a common Adj-SID for parallel links."; 949 reference "RFC 8665: OSPF Extensions for Segment Routing 950 Section 6.1 951 RFC 8667: IS-IS Extensions for Segment 952 Routing Section 2.2.1"; 953 leaf group-id { 954 type uint32; 955 description 956 "The value is an internal value to identify a 957 group-ID. Interfaces with the same group-ID will be 958 bundled together."; 959 } 960 } 961 leaf advertise-protection { 962 type enumeration { 963 enum "single" { 964 description 965 "A single Adj-SID is associated with the adjacency 966 and reflects the protection configuration."; 967 } 968 enum "dual" { 969 description 970 "Two Adj-SIDs will be associated with the adjacency 971 if the interface is protected. In this case, will 972 be advertised with backup flag set, the other will 973 be advertised with the backup flag clear. In case 974 protection is not configured, single Adj-SID will 975 be advertised with the backup flag clear."; 976 } 977 } 978 description 979 "If set, the Adj-SID refers to a protected adjacency."; 980 reference "RFC 8665: OSPF Extensions for Segment Routing 981 Section 6.1 982 RFC 8667: IS-IS Extensions for Segment 983 Routing Section 2.2.1"; 984 } 985 } 986 } 987 } 989 grouping max-sid-depth { 990 description 991 "Maximum SID Depth (MSD)D configuration grouping."; 992 leaf node-msd { 993 type uint8; 994 description 995 "Node MSD is the lowest MSD supported by the node."; 996 } 997 container link-msds { 998 description 999 "MSD supported by an individual interface."; 1000 list link-msds { 1001 key "interface"; 1002 description 1003 "List of link MSDs."; 1004 leaf interface { 1005 type if:interface-ref; 1006 description 1007 "Reference to device interface."; 1008 } 1009 leaf msd { 1010 type uint8; 1011 description 1012 "MSD supported by the interface."; 1013 } 1014 } 1015 } 1016 } 1018 augment "/rt:routing/sr:segment-routing" { 1019 description 1020 "This augments routing data model (RFC 8349) 1021 with Segment Routing (SR)."; 1022 container sr-mpls { 1023 description 1024 "Segment Routing global configuration."; 1025 uses sr-cmn:node-capabilities; 1026 container msd { 1027 if-feature "max-sid-depth"; 1028 description 1029 "MSD configuration."; 1030 uses max-sid-depth; 1031 } 1032 container bindings { 1033 description 1034 "List of bindings."; 1035 container mapping-server { 1036 if-feature "mapping-server"; 1037 description 1038 "Configuration of mapping-server local entries."; 1039 list policy { 1040 key "name"; 1041 description 1042 "List mapping-server policies."; 1043 leaf name { 1044 type string; 1045 description 1046 "Name of the mapping policy."; 1047 } 1048 container entries { 1049 description 1050 "IPv4/IPv6 mapping entries."; 1051 list mapping-entry { 1052 key "prefix algorithm"; 1053 description 1054 "Mapping entries."; 1055 uses sr-cmn:prefix-sid; 1056 } 1057 } 1059 } 1060 } 1061 container connected-prefix-sid-map { 1062 description 1063 "Prefix SID configuration."; 1064 list connected-prefix-sid { 1065 key "prefix algorithm"; 1066 description 1067 "List of prefix SID mapped to IPv4/IPv6 1068 local prefixes."; 1069 uses sr-cmn:prefix-sid; 1070 uses sr-cmn:last-hop-behavior; 1071 } 1072 } 1073 container local-prefix-sid { 1074 description 1075 "Local sid configuration."; 1076 list local-prefix-sid { 1077 key "prefix algorithm"; 1078 description 1079 "List of local IPv4/IPv6 prefix-sids."; 1080 uses sr-cmn:prefix-sid; 1081 } 1082 } 1083 } 1084 container global-srgb { 1085 description 1086 "Global SRGB configuration."; 1087 uses sr-cmn:srgb; 1088 } 1089 container srlb { 1090 description 1091 "Segment Routing Local Block (SRLB) configuration."; 1092 uses sr-cmn:srlb; 1093 } 1095 list label-blocks { 1096 config false; 1097 description 1098 "List of label blocks currently in use."; 1099 leaf lower-bound { 1100 type uint32; 1101 description 1102 "Lower bound of the label block."; 1103 } 1104 leaf upper-bound { 1105 type uint32; 1106 description 1107 "Upper bound of the label block."; 1108 } 1109 leaf size { 1110 type uint32; 1111 description 1112 "Number of indexes in the block."; 1113 } 1114 leaf free { 1115 type uint32; 1116 description 1117 "Number of free indexes in the block."; 1118 } 1119 leaf used { 1120 type uint32; 1121 description 1122 "Number of indexes in use in the block."; 1123 } 1124 leaf scope { 1125 type enumeration { 1126 enum "global" { 1127 description 1128 "Global SID."; 1129 } 1130 enum "local" { 1131 description 1132 "Local SID."; 1133 } 1134 } 1135 description 1136 "Scope of this label block."; 1137 } 1138 } 1139 container sid-db { 1140 config false; 1141 description 1142 "List of prefix and SID associations."; 1143 list sid { 1144 key "target sid source source-protocol binding-type"; 1145 ordered-by system; 1146 description 1147 "SID Binding."; 1148 leaf target { 1149 type string; 1150 description 1151 "Defines the target of the binding. It can be a 1152 prefix or something else."; 1153 } 1154 leaf sid { 1155 type uint32; 1156 description 1157 "Index associated with the prefix."; 1158 } 1159 leaf algorithm { 1160 type uint8; 1161 description 1162 "Algorithm to be used for the prefix SID."; 1163 reference "RFC 8665: OSPF Extensions for Segment Routing 1164 RFC 8667: IS-IS Extensions for Segment 1165 Routing"; 1166 } 1167 leaf source { 1168 type inet:ip-address; 1169 description 1170 "IP address of the router that owns the binding."; 1171 } 1172 leaf used { 1173 type boolean; 1174 description 1175 "Indicates if the binding is installed in the 1176 forwarding plane."; 1177 } 1178 leaf source-protocol { 1179 type leafref { 1180 path "/rt:routing/rt:control-plane-protocols/" 1181 + "rt:control-plane-protocol/rt:name"; 1182 } 1183 description 1184 "Routing protocol that owns the binding"; 1185 } 1186 leaf binding-type { 1187 type enumeration { 1188 enum "prefix-sid" { 1189 description 1190 "Binding is learned from a prefix SID."; 1191 } 1192 enum "binding-tlv" { 1193 description 1194 "Binding is learned from a binding TLV."; 1195 } 1196 } 1197 description 1198 "Type of binding."; 1199 } 1200 leaf scope { 1201 type enumeration { 1202 enum "global" { 1203 description 1204 "Global SID."; 1205 } 1206 enum "local" { 1207 description 1208 "Local SID."; 1209 } 1210 } 1211 description 1212 "SID scoping."; 1213 } 1214 } 1215 } 1216 } 1217 } 1219 notification segment-routing-global-srgb-collision { 1220 description 1221 "This notification is sent when SRGB blocks received from 1222 routers collide."; 1223 list srgb-collisions { 1224 description 1225 "List of SRGB blocks that collide."; 1226 leaf lower-bound { 1227 type uint32; 1228 description 1229 "Lower value in the block."; 1230 } 1231 leaf upper-bound { 1232 type uint32; 1233 description 1234 "Upper value in the block."; 1235 } 1236 leaf routing-protocol { 1237 type leafref { 1238 path "/rt:routing/rt:control-plane-protocols/" 1239 + "rt:control-plane-protocol/rt:name"; 1240 } 1241 description 1242 "Routing protocol reference for SRGB collision."; 1243 } 1244 leaf originating-rtr-id { 1245 type router-or-system-id; 1246 description 1247 "Originating Router ID of this SRGB block."; 1248 } 1249 } 1250 } 1251 notification segment-routing-global-sid-collision { 1252 description 1253 "This notification is sent when a new mapping is learned 1254 containing a mapping where the SID is already used. 1255 The notification generation must be throttled with at least 1256 a 5 second gap between notifications."; 1257 leaf received-target { 1258 type string; 1259 description 1260 "Target received in the router advertisement that caused 1261 the SID collision."; 1262 } 1263 leaf new-sid-rtr-id { 1264 type router-or-system-id; 1265 description 1266 "Router ID that advertised the colliding SID."; 1267 } 1268 leaf original-target { 1269 type string; 1270 description 1271 "Target already available in the database with the same SID 1272 as the received target."; 1273 } 1274 leaf original-sid-rtr-id { 1275 type router-or-system-id; 1276 description 1277 "Router-ID for the router that originally advertised the 1278 conlliding SID, i.e., the instance in the database."; 1279 } 1280 leaf index { 1281 type uint32; 1282 description 1283 "Value of the index used by two different prefixes."; 1284 } 1285 leaf routing-protocol { 1286 type leafref { 1287 path "/rt:routing/rt:control-plane-protocols/" 1288 + "rt:control-plane-protocol/rt:name"; 1289 } 1290 description 1291 "Routing protocol reference for colliding SID."; 1292 } 1293 } 1294 notification segment-routing-index-out-of-range { 1295 description 1296 "This notification is sent when a binding is received 1297 containing a segment index which is out of the local 1298 configured ranges. The notification generation must be 1299 throttled with at least a 5 second gap between 1300 notifications."; 1301 leaf received-target { 1302 type string; 1303 description 1304 "Target received in the router advertisement with 1305 the out-of-range index."; 1306 } 1307 leaf received-index { 1308 type uint32; 1309 description 1310 "Value of the index received."; 1311 } 1312 leaf routing-protocol { 1313 type leafref { 1314 path "/rt:routing/rt:control-plane-protocols/" 1315 + "rt:control-plane-protocol/rt:name"; 1316 } 1317 description 1318 "Routing protocol reference for out-of-range indexd."; 1319 } 1320 } 1321 } 1322 1324 9. Security Considerations 1326 The YANG modules specified in this document define a schema for data 1327 that is designed to be accessed via network management protocols such 1328 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer 1329 is the secure transport layer, and the mandatory-to-implement secure 1330 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer 1331 is HTTPS, and the mandatory-to-implement secure transport is TLS 1332 [RFC5246]. 1334 The NETCONF access control model [RFC6536] provides the means to 1335 restrict access for particular NETCONF or RESTCONF users to a pre- 1336 configured subset of all available NETCONF or RESTCONF protocol 1337 operations and content. 1339 There are a number of data nodes defined in the modules that are 1340 writable/creatable/deletable (i.e., config true, which is the 1341 default). These data nodes may be considered sensitive or vulnerable 1342 in some network environments. Write operations (e.g., edit-config) 1343 to these data nodes without proper protection can have a negative 1344 effect on network operations. 1346 Some of the readable data nodes in the modules may be considered 1347 sensitive or vulnerable in some network environments. It is thus 1348 important to control read access (e.g., via get, get-config, or 1349 notification) to these data nodes. 1351 10. Acknowledgements 1353 The authors would like to thank Derek Yeung, Greg Hankins, Hannes 1354 Gredler, Uma Chunduri, Jeffrey Zhang, Shradda Hedge, Les Ginsberg for 1355 their contributions. 1357 Thanks to Ladislav Lhotka and Tom Petch for their thorough reviews 1358 and helpful comments. 1360 11. IANA Considerations 1362 This document registers a URI in the IETF XML registry [RFC3688]. 1363 Following the format in [RFC3688], the following registration is 1364 requested to be made: 1366 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing-commmon 1367 Registrant Contact: The IESG. 1368 XML: N/A, the requested URI is an XML namespace. 1370 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing 1371 Registrant Contact: The IESG. 1372 XML: N/A, the requested URI is an XML namespace. 1374 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls 1375 Registrant Contact: The IESG. 1376 XML: N/A, the requested URI is an XML namespace. 1378 This document registers a YANG module in the YANG Module Names 1379 registry [RFC6020]. 1381 name: ietf-segment-routing-common 1382 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing-common 1383 prefix: sr-cmn 1384 reference: RFC XXXX 1386 name: ietf-segment-routing-mpls 1387 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing 1388 prefix: sr 1389 reference: RFC XXXX 1390 name: ietf-segment-routing 1391 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls 1392 prefix: sr-mpls 1393 reference: RFC XXXX 1395 12. References 1397 12.1. Normative References 1399 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1400 Requirement Levels", BCP 14, RFC 2119, 1401 DOI 10.17487/RFC2119, March 1997, 1402 . 1404 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 1405 DOI 10.17487/RFC3688, January 2004, 1406 . 1408 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 1409 (TLS) Protocol Version 1.2", RFC 5246, 1410 DOI 10.17487/RFC5246, August 2008, 1411 . 1413 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 1414 the Network Configuration Protocol (NETCONF)", RFC 6020, 1415 DOI 10.17487/RFC6020, October 2010, 1416 . 1418 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 1419 and A. Bierman, Ed., "Network Configuration Protocol 1420 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 1421 . 1423 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 1424 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 1425 . 1427 [RFC6536] Bierman, A. and M. Bjorklund, "Network Configuration 1428 Protocol (NETCONF) Access Control Model", RFC 6536, 1429 DOI 10.17487/RFC6536, March 2012, 1430 . 1432 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 1433 RFC 6991, DOI 10.17487/RFC6991, July 2013, 1434 . 1436 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 1437 RFC 7950, DOI 10.17487/RFC7950, August 2016, 1438 . 1440 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 1441 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 1442 . 1444 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 1445 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 1446 May 2017, . 1448 [RFC8294] Liu, X., Qu, Y., Lindem, A., Hopps, C., and L. Berger, 1449 "Common YANG Data Types for the Routing Area", RFC 8294, 1450 DOI 10.17487/RFC8294, December 2017, 1451 . 1453 [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 1454 and R. Wilton, "Network Management Datastore Architecture 1455 (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, 1456 . 1458 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 1459 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 1460 . 1462 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 1463 Routing Management (NMDA Version)", RFC 8349, 1464 DOI 10.17487/RFC8349, March 2018, 1465 . 1467 [RFC8402] Filsfils, C., Ed., Previdi, S., Ed., Ginsberg, L., 1468 Decraene, B., Litkowski, S., and R. Shakir, "Segment 1469 Routing Architecture", RFC 8402, DOI 10.17487/RFC8402, 1470 July 2018, . 1472 [RFC8476] Tantsura, J., Chunduri, U., Aldrin, S., and P. Psenak, 1473 "Signaling Maximum SID Depth (MSD) Using OSPF", RFC 8476, 1474 DOI 10.17487/RFC8476, December 2018, 1475 . 1477 [RFC8491] Tantsura, J., Chunduri, U., Aldrin, S., and L. Ginsberg, 1478 "Signaling Maximum SID Depth (MSD) Using IS-IS", RFC 8491, 1479 DOI 10.17487/RFC8491, November 2018, 1480 . 1482 [RFC8660] Bashandy, A., Ed., Filsfils, C., Ed., Previdi, S., 1483 Decraene, B., Litkowski, S., and R. Shakir, "Segment 1484 Routing with the MPLS Data Plane", RFC 8660, 1485 DOI 10.17487/RFC8660, December 2019, 1486 . 1488 [RFC8665] Psenak, P., Ed., Previdi, S., Ed., Filsfils, C., Gredler, 1489 H., Shakir, R., Henderickx, W., and J. Tantsura, "OSPF 1490 Extensions for Segment Routing", RFC 8665, 1491 DOI 10.17487/RFC8665, December 2019, 1492 . 1494 [RFC8667] Previdi, S., Ed., Ginsberg, L., Ed., Filsfils, C., 1495 Bashandy, A., Gredler, H., and B. Decraene, "IS-IS 1496 Extensions for Segment Routing", RFC 8667, 1497 DOI 10.17487/RFC8667, December 2019, 1498 . 1500 12.2. Informative References 1502 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 1503 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 1504 . 1506 [RFC8792] Watsen, K., Auerswald, E., Farrel, A., and Q. Wu, 1507 "Handling Long Lines in Content of Internet-Drafts and 1508 RFCs", RFC 8792, DOI 10.17487/RFC8792, June 2020, 1509 . 1511 Appendix A. Configuration examples 1513 Note: '\' line wrapping per [RFC8792]. 1515 A.1. SR MPLS with IPv4 1517 The following is an XML example using the SR MPLS YANG modules with 1518 IPv4 addresses. 1520 1521 1523 1525 1526 5 1527 1528 1529 1530 1531 mapping 1 1532 1533 1534 198.51.100.0/24 1535 \ 1537 sr-cmn:prefix-sid-algorithm-shortest-path\ 1538 1539 200 1540 100 1541 1542 1543 1544 1545 1546 1547 192.0.2.0/24 1548 \ 1550 sr-cmn:prefix-sid-algorithm-strict-spf 1551 100 1552 1 1553 php 1554 1555 1556 1557 1558 1559 45000 1560 55000 1561 1562 1563 1564 1565 1566 The following is the same example using JSON format. 1568 { 1569 "ietf-routing:routing": { 1570 "ietf-segment-routing:segment-routing": { 1571 "ietf-segment-routing-mpls:sr-mpls": { 1572 "msd": { 1573 "node-msd": 5 1574 }, 1575 "bindings": { 1576 "mapping-server": { 1577 "policy": [ 1578 { 1579 "name": "mapping 1", 1580 "entries": { 1581 "mapping-entry": [ 1582 { 1583 "prefix": "198.51.100.0/24", 1584 "algorithm": "ietf-segment-routing-common:\ 1585 prefix-sid-algorithm-shortest-path", 1586 "start-sid": 200, 1587 "range": 100 1588 } 1589 ] 1590 } 1591 } 1592 ] 1593 }, 1594 "connected-prefix-sid-map": { 1595 "connected-prefix-sid": [ 1596 { 1597 "prefix": "192.0.2.0/24", 1598 "algorithm": "ietf-segment-routing-common:\ 1599 prefix-sid-algorithm-strict-spf", 1600 "start-sid": 100, 1601 "range": 1, 1602 "last-hop-behavior": "php" 1603 } 1604 ] 1605 } 1606 }, 1607 "global-srgb": { 1608 "srgb": [ 1609 { 1610 "lower-bound": 45000, 1611 "upper-bound": 55000 1612 } 1613 ] 1615 } 1616 } 1617 } 1618 } 1619 } 1621 A.2. SR MPLS with IPv6 1623 The following is an XML example using the SR MPLS YANG modules with 1624 IPv6 addresses. 1626 1627 1629 1631 1632 5 1633 1634 1635 1636 1637 mapping 1 1638 1639 1640 2001:db8:aaaa:bbbb::/64 1641 \ 1643 sr-cmn:prefix-sid-algorithm-shortest-path\ 1644 1645 200 1646 100 1647 1648 1649 1650 1651 1652 1653 2001:db8:aaaa:cccc::/64 1654 \ 1656 sr-cmn:prefix-sid-algorithm-strict-spf 1657 100 1658 1 1659 php 1660 1661 1662 1663 1664 1665 45000 1666 55000 1667 1668 1669 1670 1671 1672 The following is the same example using JSON format. 1674 { 1675 "ietf-routing:routing": { 1676 "ietf-segment-routing:segment-routing": { 1677 "ietf-segment-routing-mpls:sr-mpls": { 1678 "msd": { 1679 "node-msd": 5 1680 }, 1681 "bindings": { 1682 "mapping-server": { 1683 "policy": [ 1684 { 1685 "name": "mapping 1", 1686 "entries": { 1687 "mapping-entry": [ 1688 { 1689 "prefix": "2001:db8:aaaa:bbbb::/64", 1690 "algorithm": "ietf-segment-routing-common:\ 1691 prefix-sid-algorithm-shortest-path", 1692 "start-sid": 200, 1693 "range": 100 1694 } 1695 ] 1696 } 1697 } 1698 ] 1699 }, 1700 "connected-prefix-sid-map": { 1701 "connected-prefix-sid": [ 1702 { 1703 "prefix": "2001:db8:aaaa:cccc::/64", 1704 "algorithm": "ietf-segment-routing-common:\ 1705 prefix-sid-algorithm-strict-spf", 1706 "start-sid": 100, 1707 "range": 1, 1708 "last-hop-behavior": "php" 1709 } 1710 ] 1711 } 1712 }, 1713 "global-srgb": { 1714 "srgb": [ 1715 { 1716 "lower-bound": 45000, 1717 "upper-bound": 55000 1718 } 1719 ] 1721 } 1722 } 1723 } 1724 } 1725 } 1727 Authors' Addresses 1729 Stephane Litkowski 1730 Cisco Systems 1732 Email: slitkows.ietf@gmail.com 1734 Yingzhen Qu 1735 Futurewei 1737 Email: yingzhen.qu@futurewei.com 1739 Acee Lindem 1740 Cisco Systems 1741 301 Mindenhall Way 1742 Cary, NC 27513 1743 US 1745 Email: acee@cisco.com 1747 Pushpasis Sarkar 1748 Individual 1750 Email: pushpasis.ietf@gmail.com 1752 Jeff Tantsura 1753 Apstra 1755 Email: jefftant.ietf@gmail.com