idnits 2.17.00 (12 Aug 2021) /tmp/idnits15709/draft-ietf-ospf-sr-yang-15.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 522 has weird spacing: '...r-bound uin...' == Line 523 has weird spacing: '...r-bound uin...' == Line 535 has weird spacing: '...roup-id uin...' == Line 897 has weird spacing: '...dentity b-bit...' == The document seems to use 'NOT RECOMMENDED' as an RFC 2119 keyword, but does not include the phrase in its RFC 2119 key words list. == The document doesn't use any RFC 2119 keywords, yet seems to have RFC 2119 boilerplate text. -- The document date (July 2, 2021) is 323 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) == Unused Reference: 'RFC2328' is defined on line 1511, but no explicit reference was found in the text == Unused Reference: 'RFC4750' is defined on line 1519, but no explicit reference was found in the text == Unused Reference: 'RFC5340' is defined on line 1524, but no explicit reference was found in the text == Unused Reference: 'RFC5643' is defined on line 1528, but no explicit reference was found in the text == Unused Reference: 'RFC5838' is defined on line 1532, but no explicit reference was found in the text == Unused Reference: 'RFC7223' is defined on line 1551, but no explicit reference was found in the text == Unused Reference: 'RFC8022' is defined on line 1590, but no explicit reference was found in the text ** Obsolete normative reference: RFC 7223 (Obsoleted by RFC 8343) -- Obsolete informational reference (is this intentional?): RFC 8022 (Obsoleted by RFC 8349) Summary: 1 error (**), 0 flaws (~~), 14 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Internet D. Yeung 3 Internet-Draft Arrcus 4 Intended status: Standards Track Y. Qu 5 Expires: January 3, 2022 Futurewei 6 J. Zhang 7 Juniper Networks 8 I. Chen 9 The MITRE Corporation 10 A. Lindem 11 Cisco Systems 12 July 2, 2021 14 YANG Data Model for OSPF SR (Segment Routing) Protocol 15 draft-ietf-ospf-sr-yang-15 17 Abstract 19 This document defines a YANG data module that can be used to 20 configure and manage OSPF Extensions for Segment Routing. It also 21 defines a module for management of Signaling Maximum SID Depth (MSD) 22 Using OSPF. 24 Status of This Memo 26 This Internet-Draft is submitted in full conformance with the 27 provisions of BCP 78 and BCP 79. 29 Internet-Drafts are working documents of the Internet Engineering 30 Task Force (IETF). Note that other groups may also distribute 31 working documents as Internet-Drafts. The list of current Internet- 32 Drafts is at https://datatracker.ietf.org/drafts/current/. 34 Internet-Drafts are draft documents valid for a maximum of six months 35 and may be updated, replaced, or obsoleted by other documents at any 36 time. It is inappropriate to use Internet-Drafts as reference 37 material or to cite them other than as "work in progress." 39 This Internet-Draft will expire on January 3, 2022. 41 Copyright Notice 43 Copyright (c) 2021 IETF Trust and the persons identified as the 44 document authors. All rights reserved. 46 This document is subject to BCP 78 and the IETF Trust's Legal 47 Provisions Relating to IETF Documents 48 (https://trustee.ietf.org/license-info) in effect on the date of 49 publication of this document. Please review these documents 50 carefully, as they describe your rights and restrictions with respect 51 to this document. Code Components extracted from this document must 52 include Simplified BSD License text as described in Section 4.e of 53 the Trust Legal Provisions and are provided without warranty as 54 described in the Simplified BSD License. 56 Table of Contents 58 1. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 2 59 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 3 60 1.2. Tree Diagrams . . . . . . . . . . . . . . . . . . . . . . 3 61 2. OSPF MSD . . . . . . . . . . . . . . . . . . . . . . . . . . 3 62 2.1. OSPF MSD YANG Module . . . . . . . . . . . . . . . . . . 5 63 3. OSPF Segment Routing . . . . . . . . . . . . . . . . . . . . 11 64 3.1. OSPF Segment Routing YANG Module . . . . . . . . . . . . 16 65 4. Security Considerations . . . . . . . . . . . . . . . . . . . 30 66 5. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 31 67 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 31 68 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 32 69 7.1. Normative References . . . . . . . . . . . . . . . . . . 32 70 7.2. Informative References . . . . . . . . . . . . . . . . . 34 71 Appendix A. Contributors' Addreses . . . . . . . . . . . . . . . 35 72 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 35 74 1. Overview 76 YANG [RFC6020] [RFC7950] is a data definition language used to define 77 the contents of a conceptual data store that allows networked devices 78 to be managed using NETCONF [RFC6241]. YANG is proving relevant 79 beyond its initial confines, as bindings to other interfaces (e.g., 80 ReST) and encodings other than XML (e.g., JSON) are being defined. 81 Furthermore, YANG data models can be used as the basis for 82 implementation of other interfaces, such as CLI and programmatic 83 APIs. 85 This document defines a YANG data model that can be used to configure 86 and manage OSPFv2 extensions for Segment Routing [RFC8665] and it is 87 an augmentation to the OSPF YANG data model. 89 This document also defines a YANG data model for Signaling Maximum 90 SID Depth (MSD) Using OSPF [RFC8476], which augments the base OSPF 91 YANG data model. 93 The YANG module in this document conforms to the Network Management 94 Datastore Architecture (NMDA) [RFC8342]. 96 1.1. Requirements Language 98 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 99 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 100 document are to be interpreted as described in [RFC2119]. 102 1.2. Tree Diagrams 104 This document uses the graphical representation of data models 105 defined in [RFC8340]. 107 2. OSPF MSD 109 This document defines a model for Signaling Maximum SID Depth (MSD) 110 Using OSPF [RFC8476]. It is an augmentation of the OSPF base model. 112 module: ietf-ospf-msd 113 augment /rt:routing/rt:control-plane-protocols 114 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 115 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 116 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 117 /ospf:body/ospf:opaque/ospf:ri-opaque: 118 +--ro node-msd-tlv 119 +--ro node-msds* [msd-type] 120 +--ro msd-type identityref 121 +--ro msd-value? uint8 122 augment /rt:routing/rt:control-plane-protocols 123 /rt:control-plane-protocol/ospf:ospf/ospf:database 124 /ospf:as-scope-lsa-type/ospf:as-scope-lsas/ospf:as-scope-lsa 125 /ospf:version/ospf:ospfv2/ospf:ospfv2/ospf:body/ospf:opaque 126 /ospf:ri-opaque: 127 +--ro node-msd-tlv 128 +--ro node-msds* [msd-type] 129 +--ro msd-type identityref 130 +--ro msd-value? uint8 131 augment /rt:routing/rt:control-plane-protocols 132 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 133 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 134 /ospf:area-scope-lsa/ospf:version/ospf:ospfv3/ospf:ospfv3 135 /ospf:body/ospf:router-information: 136 +--ro node-msd-tlv 137 +--ro node-msds* [msd-type] 138 +--ro msd-type identityref 139 +--ro msd-value? uint8 140 augment /rt:routing/rt:control-plane-protocols 141 /rt:control-plane-protocol/ospf:ospf/ospf:database 142 /ospf:as-scope-lsa-type/ospf:as-scope-lsas/ospf:as-scope-lsa 143 /ospf:version/ospf:ospfv3/ospf:ospfv3/ospf:body 144 /ospf:router-information: 145 +--ro node-msd-tlv 146 +--ro node-msds* [msd-type] 147 +--ro msd-type identityref 148 +--ro msd-value? uint8 149 augment /rt:routing/rt:control-plane-protocols 150 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 151 /ospf:interfaces/ospf:interface/ospf:database 152 /ospf:link-scope-lsa-type/ospf:link-scope-lsas 153 /ospf:link-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 154 /ospf:body/ospf:opaque/ospf:extended-link-opaque 155 /ospf:extended-link-tlv: 156 +--ro link-msd-sub-tlv 157 +--ro link-msds* [msd-type] 158 +--ro msd-type identityref 159 +--ro msd-value? uint8 160 augment /rt:routing/rt:control-plane-protocols 161 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 162 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 163 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 164 /ospf:body/ospf:opaque/ospf:extended-link-opaque 165 /ospf:extended-link-tlv: 166 +--ro link-msd-sub-tlv 167 +--ro link-msds* [msd-type] 168 +--ro msd-type identityref 169 +--ro msd-value? uint8 170 augment /rt:routing/rt:control-plane-protocols 171 /rt:control-plane-protocol/ospf:ospf/ospf:database 172 /ospf:as-scope-lsa-type/ospf:as-scope-lsas/ospf:as-scope-lsa 173 /ospf:version/ospf:ospfv2/ospf:ospfv2/ospf:body/ospf:opaque 174 /ospf:extended-link-opaque/ospf:extended-link-tlv: 175 +--ro link-msd-sub-tlv 176 +--ro link-msds* [msd-type] 177 +--ro msd-type identityref 178 +--ro msd-value? uint8 179 augment /rt:routing/rt:control-plane-protocols 180 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 181 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 182 /ospf:area-scope-lsa/ospf:version/ospf:ospfv3/ospf:ospfv3 183 /ospf:body/ospfv3-e-lsa:e-router/ospfv3-e-lsa:e-router-tlvs: 184 +--ro link-msd-sub-tlv 185 +--ro link-msds* [msd-type] 186 +--ro msd-type identityref 187 +--ro msd-value? uint8 189 2.1. OSPF MSD YANG Module 191 file "ietf-ospf-msd@2021-02-21.yang" 192 module ietf-ospf-msd { 193 yang-version 1.1; 194 namespace "urn:ietf:params:xml:ns:yang:ietf-ospf-msd"; 195 prefix ospf-msd; 197 import ietf-routing { 198 prefix rt; 199 reference "RFC 8349: A YANG Data Model for Routing 200 Management (NMDA Version)"; 201 } 203 import ietf-ospf { 204 prefix ospf; 205 } 207 import ietf-ospfv3-extended-lsa { 208 prefix ospfv3-e-lsa; 209 } 211 organization 212 "IETF LSR - LSR Working Group"; 213 contact 214 "WG Web: 215 WG List: 217 Author: Yingzhen Qu 218 219 Author: Acee Lindem 220 221 Author: Stephane Litkowski 222 223 Author: Jeff Tantsura 224 226 "; 227 description 228 "The YANG module augments the base OSPF model to 229 manage different types of MSDs. 231 This YANG model conforms to the Network Management 232 Datastore Architecture (NMDA) as described in RFC 8342. 234 Copyright (c) 2021 IETF Trust and the persons identified as 235 authors of the code. All rights reserved. 237 Redistribution and use in source and binary forms, with or 238 without modification, is permitted pursuant to, and subject 239 to the license terms contained in, the Simplified BSD License 240 set forth in Section 4.c of the IETF Trust's Legal Provisions 241 Relating to IETF Documents 242 (https://trustee.ietf.org/license-info). 244 This version of this YANG module is part of RFC XXXX; 245 see the RFC itself for full legal notices. 247 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 248 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 249 'MAY', and 'OPTIONAL' in this document are to be interpreted as 250 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 251 they appear in all capitals, as shown here."; 253 reference "RFC XXXX: YANG Data Model for OSPF MSD."; 255 revision 2021-02-21 { 256 description 257 "Initial Version"; 258 reference "RFC XXXX: YANG Data Model for OSPF MSD."; 259 } 261 identity msd-base-type { 262 description 263 "Base identity for MSD Type"; 264 } 266 identity base-mpls-msd { 267 base msd-base-type; 268 description 269 "Base MPLS Imposition MSD."; 270 reference 271 "RFC 8491: Singling MSD using IS-IS."; 272 } 274 identity erld-msd { 275 base msd-base-type; 276 description 277 "ERLD-MSD is defined to advertise the ERLD."; 278 reference 279 "RFC 8662: Entropy Label for Source Packet Routing in 280 Networking (SPRING) Tunnels"; 281 } 283 grouping node-msd-tlv { 284 description 285 "Grouping for node MSD."; 286 container node-msd-tlv { 287 list node-msds { 288 key "msd-type"; 289 leaf msd-type { 290 type identityref { 291 base msd-base-type; 292 } 293 description 294 "MSD-Types"; 295 } 296 leaf msd-value { 297 type uint8; 298 description 299 "MSD value, in the range of 0-255."; 300 } 301 description 302 "Node MSD is the smallest link MSD supported by 303 the node."; 304 } 305 description 306 "Node MSD is the number of SIDs supported by a node."; 307 reference 308 "RFC 8476: Signaling Maximum SID Depth (MSD) Using OSPF"; 309 } 310 } 312 grouping link-msd-sub-tlv { 313 description 314 "Link Maximum SID Depth (MSD) grouping for an interface."; 315 container link-msd-sub-tlv { 316 list link-msds { 317 key "msd-type"; 318 leaf msd-type { 319 type identityref { 320 base msd-base-type; 321 } 322 description 323 "MSD-Types"; 324 } 325 leaf msd-value { 326 type uint8; 327 description 328 "MSD value, in the range of 0-255."; 329 } 330 description 331 "List of link MSDs"; 333 } 334 description 335 "Link MSD sub-tlvs."; 336 } 337 } 339 /* Node MSD TLV */ 340 augment "/rt:routing/" 341 + "rt:control-plane-protocols/rt:control-plane-protocol/" 342 + "ospf:ospf/ospf:areas/" 343 + "ospf:area/ospf:database/" 344 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 345 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 346 + "ospf:ospfv2/ospf:body/ospf:opaque/" 347 + "ospf:ri-opaque" { 348 when "../../../../../../../../../../../" 349 + "rt:type = 'ospf:ospfv2'" { 350 description 351 "This augmentation is only valid for OSPFv2."; 352 } 353 description 354 "Node MSD TLV is an optional TLV of OSPFv2 RI Opaque 355 LSA (RFC7770) and has a type of 12."; 357 uses node-msd-tlv; 358 } 360 augment "/rt:routing/" 361 + "rt:control-plane-protocols/rt:control-plane-protocol/" 362 + "ospf:ospf/ospf:database/" 363 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 364 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/" 365 + "ospf:ospfv2/ospf:body/ospf:opaque/" 366 + "ospf:ri-opaque" { 367 when "../../../../../../../../../" 368 + "rt:type = 'ospf:ospfv2'" { 369 description 370 "This augmentation is only valid for OSPFv2."; 371 } 372 description 373 "Node MSD TLV is an optional TLV of OSPFv2 RI Opaque 374 LSA (RFC7770) and has a type of 12."; 376 uses node-msd-tlv; 377 } 379 augment "/rt:routing/" 380 + "rt:control-plane-protocols/rt:control-plane-protocol/" 381 + "ospf:ospf/ospf:areas/" 382 + "ospf:area/ospf:database/" 383 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 384 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv3/" 385 + "ospf:ospfv3/ospf:body/ospf:router-information" { 386 when "../../../../../../../../../../" 387 + "rt:type = 'ospf:ospfv3'" { 388 description 389 "This augmentation is only valid for OSPFv3."; 390 } 391 description 392 "Node MSD TLV is an optional TLV of OSPFv3 RI Opaque 393 LSA (RFC7770) and has a type of 12."; 395 uses node-msd-tlv; 396 } 398 augment "/rt:routing/" 399 + "rt:control-plane-protocols/rt:control-plane-protocol/" 400 + "ospf:ospf/ospf:database/" 401 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 402 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv3/" 403 + "ospf:ospfv3/ospf:body/ospf:router-information" { 404 when "../../../../../../../../" 405 + "rt:type = 'ospf:ospfv3'" { 406 description 407 "This augmentation is only valid for OSPFv3."; 408 } 409 description 410 "Node MSD TLV is an optional TLV of OSPFv3 RI Opaque 411 LSA (RFC7770) and has a type of 12."; 413 uses node-msd-tlv; 414 } 416 /* link MSD sub-tlv */ 417 augment "/rt:routing/" 418 + "rt:control-plane-protocols/rt:control-plane-protocol/" 419 + "ospf:ospf/ospf:areas/ospf:area/" 420 + "ospf:interfaces/ospf:interface/ospf:database/" 421 + "ospf:link-scope-lsa-type/ospf:link-scope-lsas/" 422 + "ospf:link-scope-lsa/ospf:version/ospf:ospfv2/" 423 + "ospf:ospfv2/ospf:body/ospf:opaque/" 424 + "ospf:extended-link-opaque/ospf:extended-link-tlv" { 425 when "../../../../../../../../../../../../../../" 426 + "rt:type = 'ospf:ospfv2'" { 427 description 428 "This augmentation is only valid for OSPFv2."; 430 } 431 description 432 "Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended 433 link TLV as defined in RFC 7684 and has a type of 6."; 435 uses link-msd-sub-tlv; 436 } 438 augment "/rt:routing/" 439 + "rt:control-plane-protocols/rt:control-plane-protocol/" 440 + "ospf:ospf/ospf:areas/" 441 + "ospf:area/ospf:database/" 442 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 443 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 444 + "ospf:ospfv2/ospf:body/ospf:opaque/" 445 + "ospf:extended-link-opaque/ospf:extended-link-tlv" { 446 when "../../../../../../../../../../../../" 447 + "rt:type = 'ospf:ospfv2'" { 448 description 449 "This augmentation is only valid for OSPFv2."; 450 } 451 description 452 "Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended 453 link TLV as defined in RFC 7684 and has a type of 6."; 455 uses link-msd-sub-tlv; 456 } 458 augment "/rt:routing/" 459 + "rt:control-plane-protocols/rt:control-plane-protocol/" 460 + "ospf:ospf/ospf:database/" 461 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 462 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/" 463 + "ospf:ospfv2/ospf:body/ospf:opaque/" 464 + "ospf:extended-link-opaque/ospf:extended-link-tlv" { 465 when "../../../../../../../../../../" 466 + "rt:type = 'ospf:ospfv2'" { 467 description 468 "This augmentation is only valid for OSPFv2."; 469 } 470 description 471 "Link MSD sub-TLV is an optional sub-TLV of OSPFv2 extended 472 link TLV as defined in RFC 7684 and has a type of 6."; 474 uses link-msd-sub-tlv; 475 } 477 augment "/rt:routing/" 478 + "rt:control-plane-protocols/rt:control-plane-protocol/" 479 + "ospf:ospf/ospf:areas/ospf:area/ospf:database/" 480 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 481 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv3/" 482 + "ospf:ospfv3/ospf:body/ospfv3-e-lsa:e-router" 483 + "/ospfv3-e-lsa:e-router-tlvs" { 484 when "'ospf:../../../../../../../../" 485 + "rt:type' = 'ospf:ospfv3'" { 486 description 487 "This augmentation is only valid for OSPFv3 488 E-Router LSAs"; 489 } 490 description 491 "Augment OSPFv3 Area scope router-link TLV."; 493 uses link-msd-sub-tlv; 494 } 495 } 496 498 3. OSPF Segment Routing 500 This document defines a model for OSPF Segment Routing feature 501 [RFC8665]. It is an augmentation of the OSPF base model. 503 The OSPF SR YANG module requires support for the base segment routing 504 module [RFC9020], which defines the global segment routing 505 configuration independent of any specific routing protocol 506 configuration, and support of OSPF base model[I-D.ietf-ospf-yang] 507 which defines basic OSPF configuration and state. 509 module: ietf-ospf-sr 510 augment /rt:routing/rt:control-plane-protocols 511 /rt:control-plane-protocol/ospf:ospf: 512 +--rw segment-routing 513 | +--rw enabled? boolean 514 | +--rw bindings {mapping-server}? 515 | +--rw advertise 516 | | +--rw policies* -> /rt:routing/sr:segment-routing 517 | | /sr-mpls:sr-mpls/bindings 518 | | /mapping-server/policy/name 519 | +--rw receive? boolean 520 +--rw protocol-srgb {sr-mpls:protocol-srgb}? 521 +--rw srgb* [lower-bound upper-bound] 522 +--rw lower-bound uint32 523 +--rw upper-bound uint32 524 augment /rt:routing/rt:control-plane-protocols 525 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 526 /ospf:interfaces/ospf:interface: 527 +--rw segment-routing 528 +--rw adjacency-sid 529 +--rw adj-sids* [value] 530 | +--rw value-type? enumeration 531 | +--rw value uint32 532 | +--rw protected? boolean 533 | +--rw weight? uint8 534 +--rw advertise-adj-group-sid* [group-id] 535 | +--rw group-id uint32 536 +--rw advertise-protection? enumeration 537 augment /rt:routing/rt:control-plane-protocols 538 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 539 /ospf:interfaces/ospf:interface/ospf:fast-reroute: 540 +--rw ti-lfa {ti-lfa}? 541 +--rw enable? boolean 542 augment /rt:routing/rt:control-plane-protocols 543 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 544 /ospf:interfaces/ospf:interface/ospf:database 545 /ospf:link-scope-lsa-type/ospf:link-scope-lsas 546 /ospf:link-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 547 /ospf:body/ospf:opaque/ospf:extended-prefix-opaque: 548 +--ro extended-prefix-range-tlvs 549 +--ro extended-prefix-range-tlv* [] 550 +--ro prefix-length? uint8 551 +--ro af? uint8 552 +--ro range-size? uint16 553 +--ro extended-prefix-range-flags 554 | +--ro bits* identityref 555 +--ro prefix? inet:ip-prefix 556 +--ro perfix-sid-sub-tlvs 557 | +--ro prefix-sid-sub-tlv* [] 558 | +--ro prefix-sid-flags 559 | | +--ro bits* identityref 560 | +--ro mt-id? uint8 561 | +--ro algorithm? uint8 562 | +--ro sid? uint32 563 +--ro unknown-tlvs 564 +--ro unknown-tlv* [] 565 +--ro type? uint16 566 +--ro length? uint16 567 +--ro value? yang:hex-string 568 augment /rt:routing/rt:control-plane-protocols 569 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 570 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 571 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 572 /ospf:body/ospf:opaque/ospf:extended-prefix-opaque: 573 +--ro extended-prefix-range-tlvs 574 +--ro extended-prefix-range-tlv* [] 575 +--ro prefix-length? uint8 576 +--ro af? uint8 577 +--ro range-size? uint16 578 +--ro extended-prefix-range-flags 579 | +--ro bits* identityref 580 +--ro prefix? inet:ip-prefix 581 +--ro perfix-sid-sub-tlvs 582 | +--ro prefix-sid-sub-tlv* [] 583 | +--ro prefix-sid-flags 584 | | +--ro bits* identityref 585 | +--ro mt-id? uint8 586 | +--ro algorithm? uint8 587 | +--ro sid? uint32 588 +--ro unknown-tlvs 589 +--ro unknown-tlv* [] 590 +--ro type? uint16 591 +--ro length? uint16 592 +--ro value? yang:hex-string 593 augment /rt:routing/rt:control-plane-protocols 594 /rt:control-plane-protocol/ospf:ospf/ospf:database 595 /ospf:as-scope-lsa-type/ospf:as-scope-lsas 596 /ospf:as-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 597 /ospf:body/ospf:opaque/ospf:extended-prefix-opaque: 598 +--ro extended-prefix-range-tlvs 599 +--ro extended-prefix-range-tlv* [] 600 +--ro prefix-length? uint8 601 +--ro af? uint8 602 +--ro range-size? uint16 603 +--ro extended-prefix-range-flags 604 | +--ro bits* identityref 605 +--ro prefix? inet:ip-prefix 606 +--ro perfix-sid-sub-tlvs 607 | +--ro prefix-sid-sub-tlv* [] 608 | +--ro prefix-sid-flags 609 | | +--ro bits* identityref 610 | +--ro mt-id? uint8 611 | +--ro algorithm? uint8 612 | +--ro sid? uint32 613 +--ro unknown-tlvs 614 +--ro unknown-tlv* [] 615 +--ro type? uint16 616 +--ro length? uint16 617 +--ro value? yang:hex-string 618 augment /rt:routing/rt:control-plane-protocols 619 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 620 /ospf:interfaces/ospf:interface/ospf:database 621 /ospf:link-scope-lsa-type/ospf:link-scope-lsas 622 /ospf:link-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 623 /ospf:body/ospf:opaque/ospf:extended-prefix-opaque 624 /ospf:extended-prefix-tlv: 625 +--ro perfix-sid-sub-tlvs 626 +--ro prefix-sid-sub-tlv* [] 627 +--ro prefix-sid-flags 628 | +--ro bits* identityref 629 +--ro mt-id? uint8 630 +--ro algorithm? uint8 631 +--ro sid? uint32 632 augment /rt:routing/rt:control-plane-protocols 633 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 634 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 635 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 636 /ospf:body/ospf:opaque/ospf:extended-prefix-opaque 637 /ospf:extended-prefix-tlv: 638 +--ro perfix-sid-sub-tlvs 639 +--ro prefix-sid-sub-tlv* [] 640 +--ro prefix-sid-flags 641 | +--ro bits* identityref 642 +--ro mt-id? uint8 643 +--ro algorithm? uint8 644 +--ro sid? uint32 645 augment /rt:routing/rt:control-plane-protocols 646 /rt:control-plane-protocol/ospf:ospf/ospf:database 647 /ospf:as-scope-lsa-type/ospf:as-scope-lsas/ospf:as-scope-lsa 648 /ospf:version/ospf:ospfv2/ospf:ospfv2/ospf:body/ospf:opaque 649 /ospf:extended-prefix-opaque/ospf:extended-prefix-tlv: 650 +--ro perfix-sid-sub-tlvs 651 +--ro prefix-sid-sub-tlv* [] 652 +--ro prefix-sid-flags 653 | +--ro bits* identityref 654 +--ro mt-id? uint8 655 +--ro algorithm? uint8 656 +--ro sid? uint32 657 augment /rt:routing/rt:control-plane-protocols 658 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 659 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 660 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 661 /ospf:body/ospf:opaque/ospf:extended-link-opaque 662 /ospf:extended-link-tlv: 663 +--ro adj-sid-sub-tlvs 664 | +--ro adj-sid-sub-tlv* [] 665 | +--ro adj-sid-flags 666 | | +--ro bits* identityref 667 | +--ro mt-id? uint8 668 | +--ro weight? uint8 669 | +--ro sid? uint32 670 +--ro lan-adj-sid-sub-tlvs 671 +--ro lan-adj-sid-sub-tlv* [] 672 +--ro lan-adj-sid-flags 673 | +--ro bits* identityref 674 +--ro mt-id? uint8 675 +--ro weight? uint8 676 +--ro neighbor-router-id? yang:dotted-quad 677 +--ro sid? uint32 678 augment /rt:routing/rt:control-plane-protocols 679 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 680 /ospf:interfaces/ospf:interface/ospf:database 681 /ospf:link-scope-lsa-type/ospf:link-scope-lsas 682 /ospf:link-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 683 /ospf:body/ospf:opaque/ospf:ri-opaque: 684 +--ro sr-algorithm-tlv 685 | +--ro sr-algorithm* uint8 686 +--ro sid-range-tlvs 687 | +--ro sid-range-tlv* [] 688 | +--ro range-size? uint24 689 | +--ro sid-sub-tlv 690 | +--ro sid? uint32 691 +--ro local-block-tlvs 692 | +--ro local-block-tlv* [] 693 | +--ro range-size? uint24 694 | +--ro sid-sub-tlv 695 | +--ro sid? uint32 696 +--ro srms-preference-tlv 697 +--ro preference? uint8 698 augment /rt:routing/rt:control-plane-protocols 699 /rt:control-plane-protocol/ospf:ospf/ospf:areas/ospf:area 700 /ospf:database/ospf:area-scope-lsa-type/ospf:area-scope-lsas 701 /ospf:area-scope-lsa/ospf:version/ospf:ospfv2/ospf:ospfv2 702 /ospf:body/ospf:opaque/ospf:ri-opaque: 703 +--ro sr-algorithm-tlv 704 | +--ro sr-algorithm* uint8 705 +--ro sid-range-tlvs 706 | +--ro sid-range-tlv* [] 707 | +--ro range-size? uint24 708 | +--ro sid-sub-tlv 709 | +--ro sid? uint32 710 +--ro local-block-tlvs 711 | +--ro local-block-tlv* [] 712 | +--ro range-size? uint24 713 | +--ro sid-sub-tlv 714 | +--ro sid? uint32 715 +--ro srms-preference-tlv 716 +--ro preference? uint8 717 augment /rt:routing/rt:control-plane-protocols 718 /rt:control-plane-protocol/ospf:ospf/ospf:database 719 /ospf:as-scope-lsa-type/ospf:as-scope-lsas/ospf:as-scope-lsa 720 /ospf:version/ospf:ospfv2/ospf:ospfv2/ospf:body/ospf:opaque 721 /ospf:ri-opaque: 722 +--ro sr-algorithm-tlv 723 | +--ro sr-algorithm* uint8 724 +--ro sid-range-tlvs 725 | +--ro sid-range-tlv* [] 726 | +--ro range-size? uint24 727 | +--ro sid-sub-tlv 728 | +--ro sid? uint32 729 +--ro local-block-tlvs 730 | +--ro local-block-tlv* [] 731 | +--ro range-size? uint24 732 | +--ro sid-sub-tlv 733 | +--ro sid? uint32 734 +--ro srms-preference-tlv 735 +--ro preference? uint8 737 3.1. OSPF Segment Routing YANG Module 739 file "ietf-ospf-sr@2021-07-02.yang" 740 module ietf-ospf-sr { 741 yang-version 1.1; 742 namespace "urn:ietf:params:xml:ns:yang:ietf-ospf-sr"; 744 prefix ospf-sr; 746 import ietf-inet-types { 747 prefix "inet"; 748 reference "RFC 6991 - Common YANG Data Types"; 749 } 751 import ietf-yang-types { 752 prefix "yang"; 753 reference "RFC 6991 - Common YANG Data Types"; 754 } 756 import ietf-routing { 757 prefix "rt"; 758 reference "RFC 8349 - A YANG Data Model for Routing 759 Management (NMDA Version)"; 760 } 761 import ietf-segment-routing-common { 762 prefix "sr-cmn"; 763 reference "RFC 9020 - YANG Data Model for Segment 764 Routing"; 765 } 766 import ietf-segment-routing-mpls { 767 prefix "sr-mpls"; 768 reference "RFC 9020 - YANG Data Model for Segment 769 Routing"; 770 } 771 import ietf-ospf { 772 prefix "ospf"; 773 } 775 organization 776 "IETF LSR - Link State Routing Working Group"; 778 contact 779 "WG Web: 780 WG List: 782 Editor: Derek Yeung 783 784 Author: Derek Yeung 785 786 Author: Yingzhen Qu 787 788 Author: Acee Lindem 789 790 Author: Jeffrey Zhang 791 792 Author: Ing-Wher Chen 793 794 Author: Greg Hankins 795 "; 797 description 798 "This YANG module defines the generic configuration 799 and operational state for OSPF Segment Routing, which is 800 common across all of the vendor implementations. It is 801 intended that the module will be extended by vendors to 802 define vendor-specific OSPF Segment Routing configuration 803 and operational parameters and policies. 805 This YANG model conforms to the Network Management 806 Datastore Architecture (NMDA) as described in RFC 8342. 808 Copyright (c) 2021 IETF Trust and the persons identified as 809 authors of the code. All rights reserved. 811 Redistribution and use in source and binary forms, with or 812 without modification, is permitted pursuant to, and subject to 813 the license terms contained in, the Simplified BSD License set 814 forth in Section 4.c of the IETF Trust's Legal Provisions 815 Relating to IETF Documents 816 (https://trustee.ietf.org/license-info). 818 This version of this YANG module is part of RFC XXXX 819 (https://www.rfc-editor.org/info/rfcXXXX); see the RFC itself 820 for full legal notices. 822 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 823 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'NOT RECOMMENDED', 824 'MAY', and 'OPTIONAL' in this document are to be interpreted as 825 described in BCP 14 (RFC 2119) (RFC 8174) when, and only when, 826 they appear in all capitals, as shown here. 828 This version of this YANG module is part of RFC XXXX; 829 see the RFC itself for full legal notices."; 831 reference "RFC XXXX"; 833 revision 2021-07-02 { 834 description 835 "Initial revision."; 836 reference 837 "RFC XXXX: A YANG Data Model for OSPF Segment Routing."; 838 } 840 feature ti-lfa { 841 description 842 "Topology-Independent Loop-Free Alternate (TI-LFA) 843 computation using segment routing."; 844 } 846 identity prefix-sid-bit { 847 description 848 "Base identity for prefix sid sub-tlv bits."; 849 } 851 identity np-bit { 852 base prefix-sid-bit; 853 description 854 "No-PHP flag."; 855 } 857 identity m-bit { 858 base prefix-sid-bit; 859 description 860 "Mapping server flag."; 861 } 863 identity e-bit { 864 base prefix-sid-bit; 865 description 866 "Explicit-NULL flag."; 867 } 869 identity v-bit { 870 base prefix-sid-bit; 871 description 872 "Value/Index flag."; 873 } 875 identity l-bit { 876 base prefix-sid-bit; 877 description 878 "Local flag."; 879 } 881 identity extended-prefix-range-bit { 882 description 883 "Base identity for extended prefix range TLV bits."; 884 } 886 identity ia-bit { 887 base extended-prefix-range-bit; 888 description 889 "Inter-Area flag. If set, advertisement is of inter-area type."; 890 } 892 identity adj-sid-bit { 893 description 894 "Base identity for adj sid sub-tlv bits."; 895 } 897 identity b-bit { 898 base adj-sid-bit; 899 description 900 "Backup flag."; 901 } 903 identity vi-bit { 904 base adj-sid-bit; 905 description 906 "Value/Index flag."; 907 } 908 identity lo-bit { 909 base adj-sid-bit; 910 description 911 "Local/Global flag."; 912 } 914 identity g-bit { 915 base adj-sid-bit; 916 description 917 "Group flag."; 918 } 920 identity p-bit { 921 base adj-sid-bit; 922 description 923 "Persistent flag."; 924 } 926 typedef uint24 { 927 type uint32 { 928 range "0 .. 16777215"; 929 } 930 description 931 "24-bit unsigned integer."; 932 } 934 /* Groupings */ 935 grouping sid-sub-tlv { 936 description "SID/Label sub-TLV grouping."; 937 container sid-sub-tlv { 938 description 939 "Used to advertise the SID/Label associated with a 940 prefix or adjacency."; 941 leaf sid { 942 type uint32; 943 description 944 "Segment Identifier (SID) - A 20 bit label or 945 32 bit SID."; 946 } 947 } 948 } 950 grouping prefix-sid-sub-tlvs { 951 description "Prefix Segment ID (SID) sub-TLVs."; 952 container perfix-sid-sub-tlvs{ 953 description "Prefix SID sub-TLV."; 954 list prefix-sid-sub-tlv { 955 description "Prefix SID sub-TLV."; 956 container prefix-sid-flags { 957 leaf-list bits { 958 type identityref { 959 base prefix-sid-bit; 960 } 961 description 962 "Prefix SID Sub-TLV flag bits list."; 963 } 964 description "Segment Identifier (SID) Flags."; 965 } 966 leaf mt-id { 967 type uint8; 968 description "Multi-topology ID."; 969 } 970 leaf algorithm { 971 type uint8; 972 description 973 "The algorithm associated with the prefix-SID."; 974 } 975 leaf sid { 976 type uint32; 977 description "An index or label."; 978 } 979 } 980 } 981 } 983 grouping extended-prefix-range-tlvs { 984 description "Extended prefix range TLV grouping."; 986 container extended-prefix-range-tlvs { 987 description "The list of range of prefixes."; 988 list extended-prefix-range-tlv { 989 description "The range of prefixes."; 990 leaf prefix-length { 991 type uint8; 992 description "Length of prefix in bits."; 993 } 994 leaf af { 995 type uint8; 996 description "Address family for the prefix."; 997 } 998 leaf range-size { 999 type uint16; 1000 description "The number of prefixes covered by the 1001 advertisement."; 1002 } 1003 container extended-prefix-range-flags { 1004 leaf-list bits { 1005 type identityref { 1006 base extended-prefix-range-bit; 1007 } 1008 description "Extended prefix range TLV flags list."; 1009 } 1010 description "Extended Prefix Range TLV flags."; 1011 } 1012 leaf prefix { 1013 type inet:ip-prefix; 1014 description "Address prefix."; 1015 } 1016 uses prefix-sid-sub-tlvs; 1017 uses ospf:unknown-tlvs; 1018 } 1019 } 1020 } 1022 grouping sr-algorithm-tlv { 1023 description "SR algorithm TLV grouping."; 1024 container sr-algorithm-tlv { 1025 description "All SR algorithm TLVs."; 1026 leaf-list sr-algorithm { 1027 type uint8; 1028 description 1029 "The Segment Routing (SR) algorithms that the router is 1030 currently using."; 1031 } 1032 } 1033 } 1035 grouping sid-range-tlvs { 1036 description "SID Range TLV grouping."; 1037 container sid-range-tlvs { 1038 description "List of SID range TLVs."; 1039 list sid-range-tlv { 1040 description "SID range TLV."; 1041 leaf range-size { 1042 type uint24; 1043 description "The SID range."; 1044 } 1045 uses sid-sub-tlv; 1046 } 1047 } 1048 } 1050 grouping local-block-tlvs { 1051 description "The SR local block TLV contains the 1052 range of labels reserved for local SIDs."; 1053 container local-block-tlvs { 1054 description "List of SRLB TLVs."; 1055 list local-block-tlv { 1056 description "SRLB TLV."; 1057 leaf range-size { 1058 type uint24; 1059 description "The SID range."; 1060 } 1061 uses sid-sub-tlv; 1062 } 1063 } 1064 } 1066 grouping srms-preference-tlv { 1067 description "The SRMS preference TLV is used to advertise 1068 a preference associated with the node that acts 1069 as an SR Mapping Server."; 1070 container srms-preference-tlv { 1071 description "SRMS Preference TLV."; 1072 leaf preference { 1073 type uint8 { 1074 range "0 .. 255"; 1075 } 1076 description "SRMS preference TLV, value from 0 to 255."; 1077 } 1078 } 1079 } 1081 /* Configuration */ 1082 augment "/rt:routing/rt:control-plane-protocols" 1083 + "/rt:control-plane-protocol/ospf:ospf" { 1084 when "../rt:type = 'ospf:ospfv2' or " 1085 + "../rt:type = 'ospf:ospfv3'" { 1086 description 1087 "This augments the OSPF routing protocol when used."; 1088 } 1089 description 1090 "This augments the OSPF protocol configuration 1091 with segment routing."; 1092 uses sr-mpls:sr-control-plane; 1093 container protocol-srgb { 1094 if-feature sr-mpls:protocol-srgb; 1095 uses sr-cmn:srgb; 1096 description 1097 "Per-protocol SRGB."; 1098 } 1099 } 1100 augment "/rt:routing/rt:control-plane-protocols/" 1101 + "rt:control-plane-protocol/ospf:ospf/" 1102 + "ospf:areas/ospf:area/ospf:interfaces/ospf:interface" { 1103 when "../../../../../rt:type = 'ospf:ospfv2' or " 1104 + "../../../../../rt:type = 'ospf:ospfv3'" { 1105 description 1106 "This augments the OSPF interface configuration 1107 when used."; 1108 } 1109 description 1110 "This augments the OSPF protocol interface 1111 configuration with segment routing."; 1113 uses sr-mpls:igp-interface; 1114 } 1116 augment "/rt:routing/rt:control-plane-protocols/" 1117 + "rt:control-plane-protocol/ospf:ospf/" 1118 + "ospf:areas/ospf:area/ospf:interfaces/ospf:interface/" 1119 + "ospf:fast-reroute" { 1120 when "../../../../../../rt:type = 'ospf:ospfv2' or " 1121 + "../../../../../../rt:type = 'ospf:ospfv3'" { 1122 description 1123 "This augments the OSPF routing protocol when used."; 1124 } 1125 description 1126 "This augments the OSPF protocol IP-FRR with TI-LFA."; 1128 container ti-lfa { 1129 if-feature ti-lfa; 1130 leaf enable { 1131 type boolean; 1132 description 1133 "Enables TI-LFA computation."; 1134 } 1135 description 1136 "Topology Independent Loop Free Alternate 1137 (TI-LFA) support."; 1138 } 1139 } 1141 /* Database */ 1142 augment "/rt:routing/" 1143 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1144 + "ospf:ospf/ospf:areas/ospf:area/" 1145 + "ospf:interfaces/ospf:interface/ospf:database/" 1146 + "ospf:link-scope-lsa-type/ospf:link-scope-lsas/" 1147 + "ospf:link-scope-lsa/ospf:version/ospf:ospfv2/" 1148 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1149 + "ospf:extended-prefix-opaque" { 1150 when "../../../../../../../../../../../../../" 1151 + "rt:type = 'ospf:ospfv2'" { 1152 description 1153 "This augmentation is only valid for OSPFv2."; 1154 } 1155 description 1156 "SR specific TLVs for OSPFv2 extended prefix LSA 1157 in type 9 opaque LSA."; 1159 uses extended-prefix-range-tlvs; 1160 } 1162 augment "/rt:routing/" 1163 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1164 + "ospf:ospf/ospf:areas/" 1165 + "ospf:area/ospf:database/" 1166 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 1167 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 1168 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1169 + "ospf:extended-prefix-opaque" { 1170 when "../../../../../../../../../../../" 1171 + "rt:type = 'ospf:ospfv2'" { 1172 description 1173 "This augmentation is only valid for OSPFv2."; 1174 } 1175 description 1176 "SR specific TLVs for OSPFv2 extended prefix LSA 1177 in type 10 opaque LSA."; 1179 uses extended-prefix-range-tlvs; 1180 } 1182 augment "/rt:routing/" 1183 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1184 + "ospf:ospf/ospf:database/" 1185 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 1186 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/" 1187 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1188 + "ospf:extended-prefix-opaque" { 1189 when "../../../../../../../../../" 1190 + "rt:type = 'ospf:ospfv2'" { 1191 description 1192 "This augmentation is only valid for OSPFv2."; 1193 } 1194 description 1195 "SR specific TLVs for OSPFv2 extended prefix LSA 1196 in type 11 opaque LSA."; 1198 uses extended-prefix-range-tlvs; 1199 } 1201 augment "/rt:routing/" 1202 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1203 + "ospf:ospf/ospf:areas/ospf:area/" 1204 + "ospf:interfaces/ospf:interface/ospf:database/" 1205 + "ospf:link-scope-lsa-type/ospf:link-scope-lsas/" 1206 + "ospf:link-scope-lsa/ospf:version/ospf:ospfv2/" 1207 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1208 + "ospf:extended-prefix-opaque/ospf:extended-prefix-tlv" { 1209 when "../../../../../../../../../../../../../../" 1210 + "rt:type = 'ospf:ospfv2'" { 1211 description 1212 "This augmentation is only valid for OSPFv2."; 1213 } 1214 description 1215 "SR specific TLVs for OSPFv2 extended prefix TLV 1216 in type 9 opaque LSA."; 1217 uses prefix-sid-sub-tlvs; 1218 } 1220 augment "/rt:routing/" 1221 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1222 + "ospf:ospf/ospf:areas/" 1223 + "ospf:area/ospf:database/" 1224 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 1225 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 1226 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1227 + "ospf:extended-prefix-opaque/ospf:extended-prefix-tlv" { 1228 when "../../../../../../../../../../../../" 1229 + "rt:type = 'ospf:ospfv2'" { 1230 description 1231 "This augmentation is only valid for OSPFv2."; 1232 } 1233 description 1234 "SR specific TLVs for OSPFv2 extended prefix TLV 1235 in type 10 opaque LSA."; 1236 uses prefix-sid-sub-tlvs; 1237 } 1239 augment "/rt:routing/" 1240 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1241 + "ospf:ospf/ospf:database/" 1242 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 1243 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/" 1244 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1245 + "ospf:extended-prefix-opaque/ospf:extended-prefix-tlv" { 1246 when "../../../../../../../../../../" 1247 + "rt:type = 'ospf:ospfv2'" { 1248 description 1249 "This augmentation is only valid for OSPFv2."; 1250 } 1251 description 1252 "SR specific TLVs for OSPFv2 extended prefix TLV 1253 in type 11 opaque LSA."; 1254 uses prefix-sid-sub-tlvs; 1255 } 1257 augment "/rt:routing/" 1258 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1259 + "ospf:ospf/ospf:areas/" 1260 + "ospf:area/ospf:database/" 1261 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 1262 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 1263 + "ospf:ospfv2/ospf:body/ospf:opaque/" 1264 + "ospf:extended-link-opaque/ospf:extended-link-tlv" { 1265 when "../../../../../../../../../../../../" 1266 + "rt:type = 'ospf:ospfv2'" { 1267 description 1268 "This augmentation is only valid for OSPFv2."; 1269 } 1270 description 1271 "SR specific TLVs for OSPFv2 extended link TLV 1272 in type 10 opaque LSA."; 1274 container adj-sid-sub-tlvs { 1275 description "Adjacency SID optional sub-TLVs."; 1276 list adj-sid-sub-tlv { 1277 description "List of Adjacency SID sub-TLVs."; 1278 container adj-sid-flags { 1279 leaf-list bits { 1280 type identityref { 1281 base adj-sid-bit; 1282 } 1283 description "Adj sid sub-tlv flags list."; 1284 } 1285 description "Adj-sid sub-tlv flags."; 1286 } 1287 leaf mt-id { 1288 type uint8; 1289 description "Multi-topology ID."; 1290 } 1291 leaf weight { 1292 type uint8; 1293 description "Weight used for load-balancing."; 1294 } 1295 leaf sid { 1296 type uint32; 1297 description "Segment Identifier (SID) index/label."; 1298 } 1299 } 1300 } 1302 container lan-adj-sid-sub-tlvs { 1303 description "LAN Adjacency SID optional sub-TLVs."; 1304 list lan-adj-sid-sub-tlv { 1305 description "List of LAN adjacency SID sub-TLVs."; 1306 container lan-adj-sid-flags { 1307 leaf-list bits { 1308 type identityref { 1309 base adj-sid-bit; 1310 } 1311 description "LAN adj sid sub-tlv flags list."; 1312 } 1313 description "LAN adj-sid sub-tlv flags."; 1314 } 1315 leaf mt-id { 1316 type uint8; 1317 description "Multi-topology ID."; 1318 } 1319 leaf weight { 1320 type uint8; 1321 description "Weight used for load-balancing."; 1322 } 1323 leaf neighbor-router-id { 1324 type yang:dotted-quad; 1325 description "Neighbor router ID."; 1326 } 1327 leaf sid { 1328 type uint32; 1329 description "Segment Identifier (SID) index/label."; 1330 } 1331 } 1332 } 1333 } 1335 augment "/rt:routing/" 1336 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1337 + "ospf:ospf/ospf:areas/ospf:area/" 1338 + "ospf:interfaces/ospf:interface/ospf:database/" 1339 + "ospf:link-scope-lsa-type/ospf:link-scope-lsas/" 1340 + "ospf:link-scope-lsa/ospf:version/ospf:ospfv2/" 1341 + "ospf:ospfv2/ospf:body/ospf:opaque/ospf:ri-opaque" { 1342 when "../../../../../../../../../../../../../" 1343 + "rt:type = 'ospf:ospfv2'" { 1344 description 1345 "This augmentation is only valid for OSPFv2."; 1346 } 1348 description 1349 "SR specific TLVs for OSPFv2 type 9 opaque LSA."; 1351 uses sr-algorithm-tlv; 1352 uses sid-range-tlvs; 1353 uses local-block-tlvs; 1354 uses srms-preference-tlv; 1355 } 1357 augment "/rt:routing/" 1358 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1359 + "ospf:ospf/ospf:areas/" 1360 + "ospf:area/ospf:database/" 1361 + "ospf:area-scope-lsa-type/ospf:area-scope-lsas/" 1362 + "ospf:area-scope-lsa/ospf:version/ospf:ospfv2/" 1363 + "ospf:ospfv2/ospf:body/ospf:opaque/ospf:ri-opaque" { 1364 when "../../../../../../../../../../../" 1365 + "rt:type = 'ospf:ospfv2'" { 1366 description 1367 "This augmentation is only valid for OSPFv2."; 1368 } 1370 description 1371 "SR specific TLVs for OSPFv2 type 10 opaque LSA."; 1373 uses sr-algorithm-tlv; 1374 uses sid-range-tlvs; 1375 uses local-block-tlvs; 1376 uses srms-preference-tlv; 1377 } 1379 augment "/rt:routing/" 1380 + "rt:control-plane-protocols/rt:control-plane-protocol/" 1381 + "ospf:ospf/ospf:database/" 1382 + "ospf:as-scope-lsa-type/ospf:as-scope-lsas/" 1383 + "ospf:as-scope-lsa/ospf:version/ospf:ospfv2/" 1384 + "ospf:ospfv2/ospf:body/ospf:opaque/ospf:ri-opaque" { 1385 when "../../../../../../../../../" 1386 + "rt:type = 'ospf:ospfv2'" { 1387 description 1388 "This augmentation is only valid for OSPFv2."; 1389 } 1390 description 1391 "SR specific TLVs for OSPFv2 type 11 opaque LSA."; 1393 uses sr-algorithm-tlv; 1394 uses sid-range-tlvs; 1395 uses local-block-tlvs; 1396 uses srms-preference-tlv; 1397 } 1398 } 1399 1401 4. Security Considerations 1403 The YANG modules specified in this document define a schema for data 1404 that is designed to be accessed via network management protocols such 1405 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer 1406 is the secure transport layer, and the mandatory-to-implement secure 1407 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer 1408 is HTTPS, and the mandatory-to-implement secure transport is TLS 1409 [RFC8446]. 1411 The NETCONF Configuration Access Control model (NACM) [RFC8341] 1412 provides the means to restrict access for particular NETCONF or 1413 RESTCONF users to a pre-configured subset of all available NETCONF or 1414 RESTCONF protocol operations and content. 1416 There are a number of data nodes defined in the modules that are 1417 writable/creatable/deletable (i.e., config true, which is the 1418 default). These data nodes may be considered sensitive or vulnerable 1419 in some network environments. Write operations (e.g., edit-config) 1420 to these data nodes without proper protection can have a negative 1421 effect on network operations. These are the subtrees and data nodes 1422 and their sensitivity/vulnerability: 1424 /ospf:ospf/segment-routing/enabled - Modification to the 1425 enablement for SR could result in a Denial-of-Service (Dos) 1426 attack. If an attacker disables SR, it will cause traffic 1427 disruption. 1429 /ospf:ospf/segment-routing/bindings - Modification to the local 1430 bindings could result in a Denial-of-Service (Dos) attack. 1432 /ospf:ospf/protocol-srgb - Modification of the protocol SRGB could 1433 be used to mount a DoS attack. For example, if the protocol SRBG 1434 size is reduced to a very small value, a lot of existing segments 1435 could no longer be installed leading to a traffic disruption. 1437 /ospf:interfaces/ospf:interface/segment-routing - Modification of 1438 the Adjacency Segment Identifier (Adj-SID) could be used to mount 1439 a DoS attack. Change of an Adj-SID could be used to redirect 1440 traffic. 1442 /ospf:interfaces/ospf:interface/ospf:fast-reroute/ti-lfa - 1443 Modification of the TI-LFA enablement could lead to traffic 1444 disruption. 1446 Some of the readable data nodes in the modules may be considered 1447 sensitive or vulnerable in some network environments. It is thus 1448 important to control read access (e.g., via get, get-config, or 1449 notification) to these data nodes. 1451 Both module ietf-ospf-sr and ietf-ospf-msd augment base OSPF module 1452 data base with various TLVs. Knowledge of these data nodes ca be 1453 used to attack other routers in the OSPF domain. 1455 5. Acknowledgements 1457 The authors wish to thank Yi Yang, Alexander Clemm, Gaurav Gupta, 1458 Ladislav Lhotka, Stephane Litkowski, Greg Hankins, Manish Gupta and 1459 Alan Davey for their thorough reviews and helpful comments. 1461 This document was produced using Marshall Rose's xml2rfc tool. 1463 Author affiliation with The MITRE Corporation is provided for 1464 identification purposes only, and is not intended to convey or imply 1465 MITRE's concurrence with, or support for, the positions, opinions or 1466 viewpoints expressed. MITRE has approved this document for Public 1467 Release, Distribution Unlimited, with Public Release Case Number 1468 18-3281. 1470 6. IANA Considerations 1472 This document registers a URI in the IETF XML registry [RFC3688]. 1473 Following the format in [RFC3688], the following registration is 1474 requested to be made: 1476 URI: urn:ietf:params:xml:ns:yang:ietf-ospf-sr 1477 Registrant Contact: The IESG. 1478 XML: N/A, the requested URI is an XML namespace. 1480 URI: urn:ietf:params:xml:ns:yang:ietf-ospf-msd 1481 Registrant Contact: The IESG. 1482 XML: N/A, the requested URI is an XML namespace. 1484 This document registers a YANG module in the YANG Module Names 1485 registry [RFC6020]. 1487 name: ietf-ospf-sr 1488 namespace: urn:ietf:params:xml:ns:yang:ietf-ospf-sr 1489 prefix: ospf-sr 1490 reference: RFC XXXX 1492 name: ietf-ospf-msd 1493 namespace: urn:ietf:params:xml:ns:yang:ietf-ospf-msd 1494 prefix: ospf-msd 1495 reference: RFC XXXX 1497 7. References 1499 7.1. Normative References 1501 [I-D.ietf-ospf-yang] 1502 Yeung, D., Qu, Y., Zhang, J., Chen, I., and A. Lindem, 1503 "YANG Data Model for OSPF Protocol", draft-ietf-ospf- 1504 yang-29 (work in progress), October 2019. 1506 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1507 Requirement Levels", BCP 14, RFC 2119, 1508 DOI 10.17487/RFC2119, March 1997, 1509 . 1511 [RFC2328] Moy, J., "OSPF Version 2", STD 54, RFC 2328, 1512 DOI 10.17487/RFC2328, April 1998, 1513 . 1515 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 1516 DOI 10.17487/RFC3688, January 2004, 1517 . 1519 [RFC4750] Joyal, D., Ed., Galecki, P., Ed., Giacalone, S., Ed., 1520 Coltun, R., and F. Baker, "OSPF Version 2 Management 1521 Information Base", RFC 4750, DOI 10.17487/RFC4750, 1522 December 2006, . 1524 [RFC5340] Coltun, R., Ferguson, D., Moy, J., and A. Lindem, "OSPF 1525 for IPv6", RFC 5340, DOI 10.17487/RFC5340, July 2008, 1526 . 1528 [RFC5643] Joyal, D., Ed. and V. Manral, Ed., "Management Information 1529 Base for OSPFv3", RFC 5643, DOI 10.17487/RFC5643, August 1530 2009, . 1532 [RFC5838] Lindem, A., Ed., Mirtorabi, S., Roy, A., Barnes, M., and 1533 R. Aggarwal, "Support of Address Families in OSPFv3", 1534 RFC 5838, DOI 10.17487/RFC5838, April 2010, 1535 . 1537 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 1538 the Network Configuration Protocol (NETCONF)", RFC 6020, 1539 DOI 10.17487/RFC6020, October 2010, 1540 . 1542 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 1543 and A. Bierman, Ed., "Network Configuration Protocol 1544 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 1545 . 1547 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 1548 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 1549 . 1551 [RFC7223] Bjorklund, M., "A YANG Data Model for Interface 1552 Management", RFC 7223, DOI 10.17487/RFC7223, May 2014, 1553 . 1555 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 1556 RFC 7950, DOI 10.17487/RFC7950, August 2016, 1557 . 1559 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 1560 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 1561 . 1563 [RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration 1564 Access Control Model", STD 91, RFC 8341, 1565 DOI 10.17487/RFC8341, March 2018, 1566 . 1568 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol 1569 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018, 1570 . 1572 [RFC8476] Tantsura, J., Chunduri, U., Aldrin, S., and P. Psenak, 1573 "Signaling Maximum SID Depth (MSD) Using OSPF", RFC 8476, 1574 DOI 10.17487/RFC8476, December 2018, 1575 . 1577 [RFC8665] Psenak, P., Ed., Previdi, S., Ed., Filsfils, C., Gredler, 1578 H., Shakir, R., Henderickx, W., and J. Tantsura, "OSPF 1579 Extensions for Segment Routing", RFC 8665, 1580 DOI 10.17487/RFC8665, December 2019, 1581 . 1583 [RFC9020] Litkowski, S., Qu, Y., Lindem, A., Sarkar, P., and J. 1584 Tantsura, "YANG Data Model for Segment Routing", RFC 9020, 1585 DOI 10.17487/RFC9020, May 2021, 1586 . 1588 7.2. Informative References 1590 [RFC8022] Lhotka, L. and A. Lindem, "A YANG Data Model for Routing 1591 Management", RFC 8022, DOI 10.17487/RFC8022, November 1592 2016, . 1594 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 1595 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 1596 . 1598 [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 1599 and R. Wilton, "Network Management Datastore Architecture 1600 (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, 1601 . 1603 Appendix A. Contributors' Addreses 1605 Dean Bogdanovic 1606 Volta Networks, Inc. 1608 EMail: dean@voltanet.io 1610 Kiran Koushik Agrahara Sreenivasa 1611 Cisco Systems 1612 12515 Research Blvd, Bldg 4 1613 Austin, TX 78681 1614 USA 1616 EMail: kkoushik@cisco.com 1618 Authors' Addresses 1620 Derek Yeung 1621 Arrcus 1623 EMail: derek@arrcus.com 1625 Yingzhen Qu 1626 Futurewei 1627 2330 Central Expressway 1628 Santa Clara, CA 95050 1629 USA 1631 EMail: yingzhen.qu@futurewei.com 1633 Jeffrey Zhang 1634 Juniper Networks 1635 10 Technology Park Drive 1636 Westford, MA 01886 1637 USA 1639 EMail: zzhang@juniper.net 1641 Ing-Wher Chen 1642 The MITRE Corporation 1644 EMail: ingwherchen@mitre.org 1645 Acee Lindem 1646 Cisco Systems 1647 301 Midenhall Way 1648 Cary, NC 27513 1650 EMail: acee@cisco.com