idnits 2.17.00 (12 Aug 2021) /tmp/idnits37376/draft-ietf-spring-sr-yang-28.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 28, 2020) is 539 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: June 1, 2021 Futurewei 6 A. Lindem 7 Cisco Systems 8 P. Sarkar 9 Arrcus Networks 10 J. Tantsura 11 Apstra 12 November 28, 2020 14 YANG Data Model for Segment Routing 15 draft-ietf-spring-sr-yang-28 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 June 1, 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 . . . . . . . . . . . . . . . . . . . . . . 30 80 11. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 30 81 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 31 82 12.1. Normative References . . . . . . . . . . . . . . . . . . 31 83 12.2. Informative References . . . . . . . . . . . . . . . . . 33 84 Appendix A. Configuration examples . . . . . . . . . . . . . . . 33 85 A.1. SR MPLS with IPv4 . . . . . . . . . . . . . . . . . . . . 34 86 A.2. SR MPLS with IPv6 . . . . . . . . . . . . . . . . . . . . 37 87 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 40 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 +--ro msd {max-sid-depth}? 157 | +--ro node-msd? uint8 158 | +--ro link-msds 159 | +--ro link-msds* [interface] 160 | +--ro interface if:interface-ref 161 | +--ro 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.yang, ietf-segment- 383 routing-common.yang, and/or ietf-segment-routing-mpls.yang modules: 384 [RFC6991], [RFC8294], [RFC8476], [RFC8491], [RFC8665], [RFC8667], 385 [RFC8669], and [RFC8814]. 387 8.1. YANG Module for Segment Routing 389 ietf-segment-routing.yang: This module defines a generic framework 390 for Segment Routing, and it is to be augmented by models for 391 different SR data planes. 393 file "ietf-segment-routing@2020-11-27.yang" 394 module ietf-segment-routing { 395 yang-version 1.1; 396 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing"; 397 prefix sr; 399 import ietf-routing { 400 prefix rt; 401 reference "RFC 8349: A YANG Data Model for Routing 402 Management (NMDA Version)"; 403 } 405 organization 406 "IETF SPRING - SPRING Working Group"; 407 contact 408 "WG Web: 409 WG List: 411 Author: Stephane Litkowski 412 413 Author: Yingzhen Qu 414 415 Author: Acee Lindem 416 417 Author: Pushpasis Sarkar 418 419 Author: Jeff Tantsura 420 422 "; 423 description 424 "The YANG module defines a generic framework for Segment 425 Routing. It is to be augmented by models for different 426 SR data planes. 428 This YANG model conforms to the Network Management 429 Datastore Architecture (NMDA) as described in RFC 8242. 431 Copyright (c) 2020 IETF Trust and the persons identified as 432 authors of the code. All rights reserved. 434 Redistribution and use in source and binary forms, with or 435 without modification, is permitted pursuant to, and subject 436 to the license terms contained in, the Simplified BSD License 437 set forth in Section 4.c of the IETF Trust's Legal Provisions 438 Relating to IETF Documents 439 (https://trustee.ietf.org/license-info). 441 This version of this YANG module is part of RFC XXXX; 442 see the RFC itself for full legal notices. 444 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 445 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 446 'MAY', and 'OPTIONAL' in this document are to be interpreted as 447 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 448 they appear in all capitals, as shown here."; 450 reference "RFC XXXX: YANG Data Model for Segment Routing."; 452 revision 2020-11-27 { 453 description 454 "Initial Version"; 455 reference "RFC XXXX: YANG Data Model for Segment Routing."; 456 } 458 augment "/rt:routing" { 459 description 460 "This module augments routing data model (RFC 8349) 461 with Segment Routing (SR)."; 462 container segment-routing { 463 description 464 "Segment Routing configuration. This container 465 is to be augmented by models for different SR 466 data planes."; 467 reference "RFC 8402: Segment Routing Architecture."; 468 } 469 } 470 } 471 473 8.2. YANG Module for Segment Routing Common Types 475 ietf-segment-routing-common.yang: This module defines a collection of 476 generic types and groupings for SR as defined in [RFC8402]. 478 file "ietf-segment-routing-common@2020-11-27.yang" 479 module ietf-segment-routing-common { 480 yang-version 1.1; 481 namespace 482 "urn:ietf:params:xml:ns:yang:ietf-segment-routing-common"; 483 prefix sr-cmn; 485 import ietf-inet-types { 486 prefix inet; 487 reference "RFC 6991: Common YANG Data Types"; 488 } 490 organization 491 "IETF SPRING - SPRING Working Group"; 493 contact 494 "WG Web: 495 WG List: 497 Author: Stephane Litkowski 498 499 Author: Yingzhen Qu 500 501 Author: Acee Lindem 502 503 Author: Pushpasis Sarkar 504 505 Author: Jeff Tantsura 506 508 "; 509 description 510 "The YANG module defines a collection of generic types and 511 groupings for Segment Routing (SR) as described in RFC 8402. 513 This YANG model conforms to the Network Management 514 Datastore Architecture (NMDA) as described in RFC 8242. 516 Copyright (c) 2020 IETF Trust and the persons identified as 517 authors of the code. All rights reserved. 519 Redistribution and use in source and binary forms, with or 520 without modification, is permitted pursuant to, and subject 521 to the license terms contained in, the Simplified BSD License 522 set forth in Section 4.c of the IETF Trust's Legal Provisions 523 Relating to IETF Documents 524 (https://trustee.ietf.org/license-info). 526 This version of this YANG module is part of RFC XXXX; 527 see the RFC itself for full legal notices. 529 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 530 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 531 'MAY', and 'OPTIONAL' in this document are to be interpreted as 532 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 533 they appear in all capitals, as shown here."; 535 reference "RFC XXXX: YANG Data Model for Segment Routing."; 537 revision 2020-11-27 { 538 description 539 "Initial version"; 540 reference "RFC XXXX: YANG Data Model for Segment Routing."; 541 } 543 feature sid-last-hop-behavior { 544 description 545 "Configurable last hop behavior."; 546 reference "RFC 8660: Segment Routing with the MPLS Data Plane"; 547 } 549 identity prefix-sid-algorithm { 550 description 551 "Base identity for prefix-sid algorithm."; 552 reference "RFC 8402: Segment Routing Architecture"; 553 } 555 identity prefix-sid-algorithm-shortest-path { 556 base prefix-sid-algorithm; 557 description 558 "Shortest Path First (SPF) prefix-sid algorithm. This 559 is the default algorithm."; 560 } 562 identity prefix-sid-algorithm-strict-spf { 563 base prefix-sid-algorithm; 564 description 565 "This algorithm mandates that the packet is forwarded 566 according to ECMP-aware SPF algorithm."; 567 } 569 grouping srlr { 570 description 571 "Grouping for SR Label Range configuration."; 572 leaf lower-bound { 573 type uint32; 574 description 575 "Lower value in the label range."; 576 } 577 leaf upper-bound { 578 type uint32; 579 must "../lower-bound < ../upper-bound" { 580 error-message 581 "The upper-bound must be greater than the lower-bound."; 582 description 583 "The value must be greater than 'lower-bound'."; 584 } 585 description 586 "Upper value in the label range."; 587 } 588 } 590 grouping srgb { 591 description 592 "Grouping for SR Global Label range."; 593 list srgb { 594 key "lower-bound upper-bound"; 595 ordered-by user; 596 description 597 "List of global blocks to be advertised."; 598 uses srlr; 599 } 600 } 602 grouping srlb { 603 description 604 "Grouping for SR Local Block range."; 605 list srlb { 606 key "lower-bound upper-bound"; 607 ordered-by user; 608 description 609 "List of SRLBs."; 610 uses srlr; 611 } 612 } 614 grouping sid-value-type { 615 description 616 "Defines how the SID value is expressed."; 617 leaf value-type { 618 type enumeration { 619 enum "index" { 620 description 621 "The value will be interpreted as an index."; 622 } 623 enum "absolute" { 624 description 625 "The value will become interpreted as an absolute 626 value."; 627 } 628 } 629 default "index"; 630 description 631 "This leaf defines how value must be interpreted."; 632 } 633 } 635 grouping prefix-sid { 636 description 637 "This grouping defines cfg of prefix SID."; 638 leaf prefix { 639 type inet:ip-prefix; 640 description 641 "connected prefix sid."; 642 } 643 uses prefix-sid-attributes; 644 } 646 grouping ipv4-sid { 647 description 648 "Grouping for an IPv4 prefix SID."; 649 leaf prefix { 650 type inet:ipv4-prefix; 651 description 652 "Connected IPv4 prefix sid."; 653 } 654 uses prefix-sid-attributes; 655 } 656 grouping ipv6-sid { 657 description 658 "Grouping for an IPv6 prefix SID."; 659 leaf prefix { 660 type inet:ipv6-prefix; 661 description 662 "Connected ipv6 prefix sid."; 663 } 664 uses prefix-sid-attributes; 665 } 667 grouping last-hop-behavior { 668 description 669 "Defines last hop behavior"; 670 leaf last-hop-behavior { 671 if-feature "sid-last-hop-behavior"; 672 type enumeration { 673 enum "explicit-null" { 674 description 675 "Use explicit-null for the SID."; 676 } 677 enum "no-php" { 678 description 679 "Do not use Penultimate Hop Popping (PHP) 680 for the SID."; 681 } 682 enum "php" { 683 description 684 "Use PHP for the SID."; 685 } 686 } 687 description 688 "Configure last hop behavior."; 689 } 690 } 692 grouping node-capabilities { 693 description 694 "Containing SR node capabilities."; 695 container node-capabilities { 696 config false; 697 description 698 "Shows the SR capability of the node."; 699 leaf entropy-readable-label-depth { 700 type uint8; 701 description 702 "Maximum label stack depth that a router can read."; 703 } 704 } 705 } 707 grouping prefix-sid-attributes { 708 description 709 "Grouping for Segment Routing (SR) prefix attributes."; 710 uses sid-value-type; 711 leaf start-sid { 712 type uint32; 713 mandatory true; 714 description 715 "Value associated with prefix. The value must be 716 interpreted in the context of value-type."; 717 } 718 leaf range { 719 type uint32; 720 description 721 "Indicates how many SIDs can be allocated."; 723 } 724 leaf algorithm { 725 type identityref { 726 base prefix-sid-algorithm; 727 } 728 description 729 "Prefix-sid algorithm."; 730 } 731 } 732 } 733 735 8.3. YANG Module for Segment Routing MPLS 737 ietf-segment-routing-mpls.yang: This module defines the configuration 738 and operational states for Segment Routing MPLS data plane. 740 file "ietf-segment-routing-mpls@2020-11-28 741 module ietf-segment-routing-mpls { 742 yang-version 1.1; 743 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls"; 744 prefix sr-mpls; 746 import ietf-inet-types { 747 prefix inet; 748 reference "RFC 6991: Common YANG Data Types"; 749 } 750 import ietf-routing { 751 prefix rt; 752 reference "RFC 8349: A YANG Data Model for Routing 753 Management (NMDA Version)"; 754 } 755 import ietf-interfaces { 756 prefix if; 757 reference "RFC 8343: A YANG Data Model for Interface 758 Management (NMDA Version)"; 759 } 760 import ietf-routing-types { 761 prefix rt-types; 762 reference "RFC 8294: Common YANG Data Types for the 763 Routing Area"; 764 } 765 import ietf-segment-routing { 766 prefix sr; 767 reference "RFC XXXX: YANG Data Model for Segment Routing."; 768 } 769 import ietf-segment-routing-common { 770 prefix sr-cmn; 771 reference "RFC XXXX: YANG Data Model for Segment Routing."; 772 } 774 organization 775 "IETF SPRING - SPRING Working Group"; 776 contact 777 "WG Web: 778 WG List: 780 Author: Stephane Litkowski 781 782 Author: Yingzhen Qu 783 784 Author: Acee Lindem 785 786 Author: Pushpasis Sarkar 787 788 Author: Jeff Tantsura 789 791 "; 792 description 793 "The YANG module defines a generic configuration model for 794 Segment Routing MPLS data plane. 796 This YANG model conforms to the Network Management 797 Datastore Architecture (NMDA) as described in RFC 8242. 799 Copyright (c) 2020 IETF Trust and the persons identified as 800 authors of the code. All rights reserved. 802 Redistribution and use in source and binary forms, with or 803 without modification, is permitted pursuant to, and subject 804 to the license terms contained in, the Simplified BSD License 805 set forth in Section 4.c of the IETF Trust's Legal Provisions 806 Relating to IETF Documents 807 (https://trustee.ietf.org/license-info). 809 This version of this YANG module is part of RFC XXXX; 810 see the RFC itself for full legal notices. 812 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 813 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 814 'MAY', and 'OPTIONAL' in this document are to be interpreted as 815 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 816 they appear in all capitals, as shown here."; 818 reference "RFC XXXX: YANG Data Model for Segment Routing."; 819 revision 2020-11-28 { 820 description 821 "Initial Version"; 822 reference "RFC XXXX: YANG Data Model for Segment Routing."; 823 } 825 feature mapping-server { 826 description 827 "Support for Segment Routing Mapping Server (SRMS)."; 828 reference "RFC 8661: Segment Routing MPLS Interworking 829 with LDP"; 830 } 832 feature protocol-srgb { 833 description 834 "Support for per-protocol Segment Routing Global Block 835 (SRGB) configuration."; 836 reference "RFC 8660: Segment Routing with the MPLS 837 Data Plane"; 838 } 840 feature max-sid-depth { 841 description 842 "Support for signaling MSD (Maximum SID Depth) in IGP."; 843 reference "RFC 8476: Signaling Maximum SID Depth (MSD) 844 Using OSPF 845 RFC 8491: Signaling Maximum SID Depth (MSD) 846 Using IS-IS 847 RFC 8814: Singaling Maximum SID Deppt (MSD) 848 Using the Border Gateway Protocol 849 (BGP) - Link State"; 850 } 852 typedef system-id { 853 type string { 854 pattern 855 '[0-9A-Fa-f]{4}\.[0-9A-Fa-f]{4}\.[0-9A-Fa-f]{4}'; 856 } 857 description 858 "This type defines IS-IS system-id using pattern, 859 An example system-id is 0143.0438.AEF0"; 860 } 862 typedef router-or-system-id { 863 type union { 864 type rt-types:router-id; 865 type system-id; 866 } 867 description 868 "OSPF/BGP router-id or ISIS system ID."; 869 } 871 grouping sr-control-plane { 872 description 873 "Defines protocol configuration."; 874 container segment-routing { 875 description 876 "Segment Routing global configuration."; 877 leaf enabled { 878 type boolean; 879 default "false"; 880 description 881 "Enables segment-routing control-plane protocol 882 extensions."; 883 } 884 container bindings { 885 if-feature mapping-server; 886 description 887 "Control of binding advertisement and reception."; 888 container advertise { 889 description 890 "Control advertisement of local mappings 891 in binding TLVs."; 892 leaf-list policies { 893 type leafref { 894 path "/rt:routing/sr:segment-routing/sr-mpls:sr-mpls" 895 + "/sr-mpls:bindings/sr-mpls:mapping-server" 896 + "/sr-mpls:policy/sr-mpls:name"; 897 } 898 description 899 "List of binding advertisement policies."; 900 } 901 } 902 leaf receive { 903 type boolean; 904 default "true"; 905 description 906 "Allow the reception and usage of binding TLVs."; 907 } 908 } 909 } 910 } 912 grouping igp-interface { 913 description 914 "Grouping for IGP interface configuration."; 916 container segment-routing { 917 description 918 "Container for SR interface configuration."; 919 container adjacency-sid { 920 description 921 "Adjacency SID configuration."; 922 reference "RFC 8660: Segment Routing with the MPLS 923 Data Plane"; 924 list adj-sids { 925 key "value"; 926 uses sr-cmn:sid-value-type; 927 leaf value { 928 type uint32; 929 description 930 "Value of the Adj-SID."; 931 } 932 leaf protected { 933 type boolean; 934 default false; 935 description 936 "It is used to protect the manual adj-SID, e.g. using 937 IPFRR or MPLS-FRR."; 938 } 939 leaf weight { 940 type uint8; 941 description 942 "The load-balancing factor over parallel adjacencies."; 943 reference "RFC 8402: Segment Routing Architecture 944 RFC 8665: OSPF Extensions for Segment Routing 945 RFC 8667: IS-IS Extensions for Segment 946 Routing"; 947 } 948 description 949 "List of adj-sid configuration."; 950 } 951 list advertise-adj-group-sid { 952 key "group-id"; 953 description 954 "Control advertisement of S or G flag. Enable 955 advertisement of a common Adj-SID for parallel 956 links."; 957 reference "RFC 8665: OSPF Extensions for Segment Routing 958 Section 6.1 959 RFC 8667: IS-IS Extensions for Segment 960 Routing Section 2.2.1"; 961 leaf group-id { 962 type uint32; 963 description 964 "The value is an internal value to identify a 965 group-ID. Interfaces with the same group-ID 966 will be bundled together."; 967 } 968 } 969 leaf advertise-protection { 970 type enumeration { 971 enum "single" { 972 description 973 "A single Adj-SID is associated with the adjacency 974 and reflects the protection configuration."; 975 } 976 enum "dual" { 977 description 978 "Two Adj-SIDs will be associated with the adjacency 979 if the interface is protected. In this case, will 980 be advertised with backup flag set, the other will 981 be advertised with the backup flag clear. In case 982 protection is not configured, single Adj-SID will 983 be advertised with the backup flag clear."; 984 } 985 } 986 description 987 "If set, the Adj-SID refers to a protected adjacency."; 988 reference "RFC 8665: OSPF Extensions for Segment Routing 989 Section 6.1 990 RFC 8667: IS-IS Extensions for Segment 991 Routing Section 2.2.1"; 992 } 993 } 994 } 995 } 997 grouping max-sid-depth { 998 description 999 "Maximum SID Depth (MSD) operational state grouping."; 1000 leaf node-msd { 1001 type uint8; 1002 description 1003 "Node MSD is the lowest MSD supported by the node."; 1004 } 1005 container link-msds { 1006 description 1007 "MSD supported by an individual interface."; 1008 list link-msds { 1009 key "interface"; 1010 description 1011 "List of link MSDs."; 1013 leaf interface { 1014 type if:interface-ref; 1015 description 1016 "Reference to device interface."; 1017 } 1018 leaf msd { 1019 type uint8; 1020 description 1021 "MSD supported by the interface."; 1022 } 1023 } 1024 } 1025 } 1027 augment "/rt:routing/sr:segment-routing" { 1028 description 1029 "This augments routing data model (RFC 8349) 1030 with Segment Routing (SR)."; 1031 container sr-mpls { 1032 description 1033 "Segment Routing global configuration and 1034 operational state."; 1035 uses sr-cmn:node-capabilities; 1036 container msd { 1037 if-feature "max-sid-depth"; 1038 config false; 1039 description 1040 "Maximum Segment Depth (MSD) Operational State."; 1041 uses max-sid-depth; 1042 } 1043 container bindings { 1044 description 1045 "List of bindings."; 1046 container mapping-server { 1047 if-feature "mapping-server"; 1048 description 1049 "Configuration of mapping-server local entries."; 1050 list policy { 1051 key "name"; 1052 description 1053 "List mapping-server policies."; 1054 leaf name { 1055 type string; 1056 description 1057 "Name of the mapping policy."; 1058 } 1059 container entries { 1060 description 1061 "IPv4/IPv6 mapping entries."; 1062 list mapping-entry { 1063 key "prefix algorithm"; 1064 description 1065 "Mapping entries."; 1066 uses sr-cmn:prefix-sid; 1067 } 1068 } 1069 } 1070 } 1071 container connected-prefix-sid-map { 1072 description 1073 "Prefix SID configuration."; 1074 list connected-prefix-sid { 1075 key "prefix algorithm"; 1076 description 1077 "List of prefix SID mapped to IPv4/IPv6 1078 local prefixes."; 1079 uses sr-cmn:prefix-sid; 1080 uses sr-cmn:last-hop-behavior; 1081 } 1082 } 1083 container local-prefix-sid { 1084 description 1085 "Local sid configuration."; 1086 list local-prefix-sid { 1087 key "prefix algorithm"; 1088 description 1089 "List of local IPv4/IPv6 prefix-sids."; 1090 uses sr-cmn:prefix-sid; 1091 } 1092 } 1093 } 1094 container global-srgb { 1095 description 1096 "Global SRGB configuration."; 1097 uses sr-cmn:srgb; 1098 } 1099 container srlb { 1100 description 1101 "Segment Routing Local Block (SRLB) configuration."; 1102 uses sr-cmn:srlb; 1103 } 1105 list label-blocks { 1106 config false; 1107 description 1108 "List of label blocks currently in use."; 1110 leaf lower-bound { 1111 type uint32; 1112 description 1113 "Lower bound of the label block."; 1114 } 1115 leaf upper-bound { 1116 type uint32; 1117 description 1118 "Upper bound of the label block."; 1119 } 1120 leaf size { 1121 type uint32; 1122 description 1123 "Number of indexes in the block."; 1124 } 1125 leaf free { 1126 type uint32; 1127 description 1128 "Number of free indexes in the block."; 1129 } 1130 leaf used { 1131 type uint32; 1132 description 1133 "Number of indexes in use in the block."; 1134 } 1135 leaf scope { 1136 type enumeration { 1137 enum "global" { 1138 description 1139 "Global SID."; 1140 } 1141 enum "local" { 1142 description 1143 "Local SID."; 1144 } 1145 } 1146 description 1147 "Scope of this label block."; 1148 } 1149 } 1150 container sid-db { 1151 config false; 1152 description 1153 "List of prefix and SID associations."; 1154 list sid { 1155 key "target sid source source-protocol binding-type"; 1156 ordered-by system; 1157 description 1158 "SID Binding."; 1159 leaf target { 1160 type string; 1161 description 1162 "Defines the target of the binding. It can be a 1163 prefix or something else."; 1164 } 1165 leaf sid { 1166 type uint32; 1167 description 1168 "Index associated with the prefix."; 1169 } 1170 leaf algorithm { 1171 type uint8; 1172 description 1173 "Algorithm to be used for the prefix SID."; 1174 reference "RFC 8665: OSPF Extensions for Segment Routing 1175 RFC 8667: IS-IS Extensions for Segment 1176 Routing 1177 RFC 8669: Segment Routing Prefix Segment 1178 Identifier Extensions to BGP"; 1179 } 1180 leaf source { 1181 type inet:ip-address; 1182 description 1183 "IP address of the router that owns the binding."; 1184 } 1185 leaf used { 1186 type boolean; 1187 description 1188 "Indicates if the binding is installed in the 1189 forwarding plane."; 1190 } 1191 leaf source-protocol { 1192 type leafref { 1193 path "/rt:routing/rt:control-plane-protocols/" 1194 + "rt:control-plane-protocol/rt:name"; 1195 } 1196 description 1197 "Routing protocol that owns the binding"; 1198 } 1199 leaf binding-type { 1200 type enumeration { 1201 enum "prefix-sid" { 1202 description 1203 "Binding is learned from a prefix SID."; 1204 } 1205 enum "binding-tlv" { 1206 description 1207 "Binding is learned from a binding TLV."; 1208 } 1209 } 1210 description 1211 "Type of binding."; 1212 } 1213 leaf scope { 1214 type enumeration { 1215 enum "global" { 1216 description 1217 "Global SID."; 1218 } 1219 enum "local" { 1220 description 1221 "Local SID."; 1222 } 1223 } 1224 description 1225 "SID scoping."; 1226 } 1227 } 1228 } 1229 } 1230 } 1232 notification segment-routing-global-srgb-collision { 1233 description 1234 "This notification is sent when SRGB blocks received from 1235 routers collide."; 1236 list srgb-collisions { 1237 description 1238 "List of SRGB blocks that collide."; 1239 leaf lower-bound { 1240 type uint32; 1241 description 1242 "Lower value in the block."; 1243 } 1244 leaf upper-bound { 1245 type uint32; 1246 description 1247 "Upper value in the block."; 1248 } 1249 leaf routing-protocol { 1250 type leafref { 1251 path "/rt:routing/rt:control-plane-protocols/" 1252 + "rt:control-plane-protocol/rt:name"; 1253 } 1254 description 1255 "Routing protocol reference for SRGB collision."; 1256 } 1257 leaf originating-rtr-id { 1258 type router-or-system-id; 1259 description 1260 "Originating Router ID of this SRGB block."; 1261 } 1262 } 1263 } 1264 notification segment-routing-global-sid-collision { 1265 description 1266 "This notification is sent when a new mapping is learned 1267 containing a mapping where the SID is already used. 1268 The notification generation must be throttled with at least 1269 a 5 second gap between notifications."; 1270 leaf received-target { 1271 type string; 1272 description 1273 "Target received in the router advertisement that caused 1274 the SID collision."; 1275 } 1276 leaf new-sid-rtr-id { 1277 type router-or-system-id; 1278 description 1279 "Router ID that advertised the colliding SID."; 1280 } 1281 leaf original-target { 1282 type string; 1283 description 1284 "Target already available in the database with the same SID 1285 as the received target."; 1286 } 1287 leaf original-sid-rtr-id { 1288 type router-or-system-id; 1289 description 1290 "Router-ID for the router that originally advertised the 1291 conlliding SID, i.e., the instance in the database."; 1292 } 1293 leaf index { 1294 type uint32; 1295 description 1296 "Value of the index used by two different prefixes."; 1297 } 1298 leaf routing-protocol { 1299 type leafref { 1300 path "/rt:routing/rt:control-plane-protocols/" 1301 + "rt:control-plane-protocol/rt:name"; 1303 } 1304 description 1305 "Routing protocol reference for colliding SID."; 1306 } 1307 } 1308 notification segment-routing-index-out-of-range { 1309 description 1310 "This notification is sent when a binding is received 1311 containing a segment index which is out of the local 1312 configured ranges. The notification generation must be 1313 throttled with at least a 5 second gap between 1314 notifications."; 1315 leaf received-target { 1316 type string; 1317 description 1318 "Target received in the router advertisement with 1319 the out-of-range index."; 1320 } 1321 leaf received-index { 1322 type uint32; 1323 description 1324 "Value of the index received."; 1325 } 1326 leaf routing-protocol { 1327 type leafref { 1328 path "/rt:routing/rt:control-plane-protocols/" 1329 + "rt:control-plane-protocol/rt:name"; 1330 } 1331 description 1332 "Routing protocol reference for out-of-range indexd."; 1333 } 1334 } 1335 } 1336 1338 9. Security Considerations 1340 The YANG modules specified in this document define a schema for data 1341 that is designed to be accessed via network management protocols such 1342 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer 1343 is the secure transport layer, and the mandatory-to-implement secure 1344 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer 1345 is HTTPS, and the mandatory-to-implement secure transport is TLS 1346 [RFC5246]. 1348 The NETCONF access control model [RFC6536] provides the means to 1349 restrict access for particular NETCONF or RESTCONF users to a pre- 1350 configured subset of all available NETCONF or RESTCONF protocol 1351 operations and content. 1353 There are a number of data nodes defined in the modules that are 1354 writable/creatable/deletable (i.e., config true, which is the 1355 default). These data nodes may be considered sensitive or vulnerable 1356 in some network environments. Write operations (e.g., edit-config) 1357 to these data nodes without proper protection can have a negative 1358 effect on network operations. Writable data nodes represent 1359 configuration of the router's bindings and the global and local label 1360 blocks. These correspond to the following schema nodes: 1362 /segment-routing 1364 /segment-routing/mpls 1366 /segment-routing/mpls/bindings - Modification to the local 1367 bindings could result in a Denial of Service (DoS) attack. 1368 Additionally, the addition of bindings could result in traffic 1369 being redirected to the router. 1371 /segment-routing/mpls/global-srgb - Modification of the Segment 1372 Routing Global Block (SRGB) could be used to mount a DoS attack. 1374 /segment-routing/mpls/srlb - Modification of the Segment Routing 1375 Local Block (SRLB) could be used to mount a DoS attack. 1377 /segment-routing/mpls/label-blocks - Modification of the Segment 1378 Routing label blocks could be used to mount a DoS attack. 1380 Some of the readable data nodes in the modules may be considered 1381 sensitive or vulnerable in some network environments. It is thus 1382 important to control read access (e.g., via get, get-config, or 1383 notification) to these data nodes. The exposure of both local 1384 bindings and SID database will exposure segment routing paths that 1385 may be attacked. These correspond to the following schema nodes: 1387 /segment-routing/mpls/bindings - Knowledge of these data nodes can 1388 be used to attack the local router with either a a Denial of 1389 Service (DoS) attack or rediection of traffic destined to the 1390 local router. 1392 /segment-routing/mpls/sid-db - Knowledge of these data nodes can 1393 be used to attack the other routers in the segment routing domain 1394 with either a a Denial of Service (DoS) attack or rediection 1395 traffic destined for those routers. 1397 Furthermore exposure the node's capabilities and maximum segment 1398 depth may be useful in mounting a Denial-of-Service (DOS) attack by 1399 sending the node SR packets that the router can't process. These 1400 correspond to the following schema nodes: 1402 /segment-routing/mpls/node-capabilities 1404 /segment-routing/mpls/msd 1406 10. Acknowledgements 1408 The authors would like to thank Derek Yeung, Greg Hankins, Hannes 1409 Gredler, Uma Chunduri, Jeffrey Zhang, Shradda Hedge, Les Ginsberg for 1410 their contributions. 1412 Thanks to Ladislav Lhotka and Tom Petch for their thorough reviews 1413 and helpful comments. 1415 11. IANA Considerations 1417 This document registers a URI in the IETF XML registry [RFC3688]. 1418 Following the format in [RFC3688], the following registration is 1419 requested to be made: 1421 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing-commmon 1422 Registrant Contact: The IESG. 1423 XML: N/A, the requested URI is an XML namespace. 1425 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing 1426 Registrant Contact: The IESG. 1427 XML: N/A, the requested URI is an XML namespace. 1429 URI: urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls 1430 Registrant Contact: The IESG. 1431 XML: N/A, the requested URI is an XML namespace. 1433 This document registers a YANG module in the YANG Module Names 1434 registry [RFC6020]. 1436 name: ietf-segment-routing-common 1437 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing-common 1438 prefix: sr-cmn 1439 reference: RFC XXXX 1441 name: ietf-segment-routing 1442 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing 1443 prefix: sr 1444 reference: RFC XXXX 1445 name: ietf-segment-routing-mpls 1446 namespace: urn:ietf:params:xml:ns:yang:ietf-segment-routing-mpls 1447 prefix: sr-mpls 1448 reference: RFC XXXX 1450 12. References 1452 12.1. Normative References 1454 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1455 Requirement Levels", BCP 14, RFC 2119, 1456 DOI 10.17487/RFC2119, March 1997, 1457 . 1459 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 1460 DOI 10.17487/RFC3688, January 2004, 1461 . 1463 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 1464 (TLS) Protocol Version 1.2", RFC 5246, 1465 DOI 10.17487/RFC5246, August 2008, 1466 . 1468 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 1469 the Network Configuration Protocol (NETCONF)", RFC 6020, 1470 DOI 10.17487/RFC6020, October 2010, 1471 . 1473 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 1474 and A. Bierman, Ed., "Network Configuration Protocol 1475 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 1476 . 1478 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 1479 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 1480 . 1482 [RFC6536] Bierman, A. and M. Bjorklund, "Network Configuration 1483 Protocol (NETCONF) Access Control Model", RFC 6536, 1484 DOI 10.17487/RFC6536, March 2012, 1485 . 1487 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 1488 RFC 6991, DOI 10.17487/RFC6991, July 2013, 1489 . 1491 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 1492 RFC 7950, DOI 10.17487/RFC7950, August 2016, 1493 . 1495 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 1496 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 1497 . 1499 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 1500 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 1501 May 2017, . 1503 [RFC8294] Liu, X., Qu, Y., Lindem, A., Hopps, C., and L. Berger, 1504 "Common YANG Data Types for the Routing Area", RFC 8294, 1505 DOI 10.17487/RFC8294, December 2017, 1506 . 1508 [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 1509 and R. Wilton, "Network Management Datastore Architecture 1510 (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, 1511 . 1513 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 1514 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 1515 . 1517 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 1518 Routing Management (NMDA Version)", RFC 8349, 1519 DOI 10.17487/RFC8349, March 2018, 1520 . 1522 [RFC8402] Filsfils, C., Ed., Previdi, S., Ed., Ginsberg, L., 1523 Decraene, B., Litkowski, S., and R. Shakir, "Segment 1524 Routing Architecture", RFC 8402, DOI 10.17487/RFC8402, 1525 July 2018, . 1527 [RFC8476] Tantsura, J., Chunduri, U., Aldrin, S., and P. Psenak, 1528 "Signaling Maximum SID Depth (MSD) Using OSPF", RFC 8476, 1529 DOI 10.17487/RFC8476, December 2018, 1530 . 1532 [RFC8491] Tantsura, J., Chunduri, U., Aldrin, S., and L. Ginsberg, 1533 "Signaling Maximum SID Depth (MSD) Using IS-IS", RFC 8491, 1534 DOI 10.17487/RFC8491, November 2018, 1535 . 1537 [RFC8660] Bashandy, A., Ed., Filsfils, C., Ed., Previdi, S., 1538 Decraene, B., Litkowski, S., and R. Shakir, "Segment 1539 Routing with the MPLS Data Plane", RFC 8660, 1540 DOI 10.17487/RFC8660, December 2019, 1541 . 1543 [RFC8665] Psenak, P., Ed., Previdi, S., Ed., Filsfils, C., Gredler, 1544 H., Shakir, R., Henderickx, W., and J. Tantsura, "OSPF 1545 Extensions for Segment Routing", RFC 8665, 1546 DOI 10.17487/RFC8665, December 2019, 1547 . 1549 [RFC8667] Previdi, S., Ed., Ginsberg, L., Ed., Filsfils, C., 1550 Bashandy, A., Gredler, H., and B. Decraene, "IS-IS 1551 Extensions for Segment Routing", RFC 8667, 1552 DOI 10.17487/RFC8667, December 2019, 1553 . 1555 [RFC8669] Previdi, S., Filsfils, C., Lindem, A., Ed., Sreekantiah, 1556 A., and H. Gredler, "Segment Routing Prefix Segment 1557 Identifier Extensions for BGP", RFC 8669, 1558 DOI 10.17487/RFC8669, December 2019, 1559 . 1561 [RFC8814] Tantsura, J., Chunduri, U., Talaulikar, K., Mirsky, G., 1562 and N. Triantafillis, "Signaling Maximum SID Depth (MSD) 1563 Using the Border Gateway Protocol - Link State", RFC 8814, 1564 DOI 10.17487/RFC8814, August 2020, 1565 . 1567 12.2. Informative References 1569 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 1570 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 1571 . 1573 [RFC8792] Watsen, K., Auerswald, E., Farrel, A., and Q. Wu, 1574 "Handling Long Lines in Content of Internet-Drafts and 1575 RFCs", RFC 8792, DOI 10.17487/RFC8792, June 2020, 1576 . 1578 Appendix A. Configuration examples 1580 Note: '\' line wrapping per [RFC8792]. 1582 A.1. SR MPLS with IPv4 1584 The following is an XML example using the SR MPLS YANG modules with 1585 IPv4 addresses. 1587 1588 1590 1592 1593 1594 1595 mapping 1 1596 1597 1598 198.51.100.0/24 1599 \ 1601 sr-cmn:prefix-sid-algorithm-shortest-path\ 1602 1603 200 1604 100 1605 1606 1607 1608 1609 1610 1611 192.0.2.0/24 1612 \ 1614 sr-cmn:prefix-sid-algorithm-strict-spf 1615 100 1616 1 1617 php 1618 1619 1620 1621 1622 1623 45000 1624 55000 1625 1626 1627 1628 1629 1631 The following is the same example using JSON format. 1633 { 1634 "ietf-routing:routing": { 1635 "ietf-segment-routing:segment-routing": { 1636 "ietf-segment-routing-mpls:sr-mpls": { 1637 "bindings": { 1638 "mapping-server": { 1639 "policy": [ 1640 { 1641 "name": "mapping 1", 1642 "entries": { 1643 "mapping-entry": [ 1644 { 1645 "prefix": "198.51.100.0/24", 1646 "algorithm": "ietf-segment-routing-common:\ 1647 prefix-sid-algorithm-shortest-path", 1648 "start-sid": 200, 1649 "range": 100 1650 } 1651 ] 1652 } 1653 } 1654 ] 1655 }, 1656 "connected-prefix-sid-map": { 1657 "connected-prefix-sid": [ 1658 { 1659 "prefix": "192.0.2.0/24", 1660 "algorithm": "ietf-segment-routing-common:\ 1661 prefix-sid-algorithm-strict-spf", 1662 "start-sid": 100, 1663 "range": 1, 1664 "last-hop-behavior": "php" 1665 } 1666 ] 1667 } 1668 }, 1669 "global-srgb": { 1670 "srgb": [ 1671 { 1672 "lower-bound": 45000, 1673 "upper-bound": 55000 1674 } 1675 ] 1676 } 1677 } 1678 } 1679 } 1680 } 1682 A.2. SR MPLS with IPv6 1684 The following is an XML example using the SR MPLS YANG modules with 1685 IPv6 addresses. 1687 1688 1690 1692 1693 1694 1695 mapping 1 1696 1697 1698 2001:db8:aaaa:bbbb::/64 1699 \ 1701 sr-cmn:prefix-sid-algorithm-shortest-path\ 1702 1703 200 1704 100 1705 1706 1707 1708 1709 1710 1711 2001:db8:aaaa:cccc::/64 1712 \ 1714 sr-cmn:prefix-sid-algorithm-strict-spf 1715 100 1716 1 1717 php 1718 1719 1720 1721 1722 1723 45000 1724 55000 1725 1726 1727 1728 1729 1731 The following is the same example using JSON format. 1733 { 1734 "ietf-routing:routing": { 1735 "ietf-segment-routing:segment-routing": { 1736 "ietf-segment-routing-mpls:sr-mpls": { 1737 "bindings": { 1738 "mapping-server": { 1739 "policy": [ 1740 { 1741 "name": "mapping 1", 1742 "entries": { 1743 "mapping-entry": [ 1744 { 1745 "prefix": "2001:db8:aaaa:bbbb::/64", 1746 "algorithm": "ietf-segment-routing-common:\ 1747 prefix-sid-algorithm-shortest-path", 1748 "start-sid": 200, 1749 "range": 100 1750 } 1751 ] 1752 } 1753 } 1754 ] 1755 }, 1756 "connected-prefix-sid-map": { 1757 "connected-prefix-sid": [ 1758 { 1759 "prefix": "2001:db8:aaaa:cccc::/64", 1760 "algorithm": "ietf-segment-routing-common:\ 1761 prefix-sid-algorithm-strict-spf", 1762 "start-sid": 100, 1763 "range": 1, 1764 "last-hop-behavior": "php" 1765 } 1766 ] 1767 } 1768 }, 1769 "global-srgb": { 1770 "srgb": [ 1771 { 1772 "lower-bound": 45000, 1773 "upper-bound": 55000 1774 } 1775 ] 1776 } 1777 } 1778 } 1779 } 1780 } 1782 Authors' Addresses 1784 Stephane Litkowski 1785 Cisco Systems 1787 Email: slitkows.ietf@gmail.com 1789 Yingzhen Qu 1790 Futurewei 1792 Email: yingzhen.qu@futurewei.com 1794 Acee Lindem 1795 Cisco Systems 1796 301 Mindenhall Way 1797 Cary, NC 27513 1798 US 1800 Email: acee@cisco.com 1802 Pushpasis Sarkar 1803 Arrcus Networks 1805 Email: pushpasis.ietf@gmail.com 1807 Jeff Tantsura 1808 Apstra 1810 Email: jefftant.ietf@gmail.com