idnits 2.17.1 draft-ietf-mpls-ldp-yang-09.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 : ---------------------------------------------------------------------------- ** There are 10 instances of too long lines in the document, the longest one being 11 characters in excess of 72. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 496 has weird spacing: '...address ine...' == Line 514 has weird spacing: '...address ine...' == Line 575 has weird spacing: '...address ine...' == Line 1189 has weird spacing: '... lsr-id yan...' -- The document date (March 20, 2020) is 1497 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: 'RFC7277' is defined on line 4034, but no explicit reference was found in the text == Outdated reference: A later version (-31) exists of draft-ietf-rtgwg-policy-model-09 ** Downref: Normative reference to an Informational RFC: RFC 5443 ** Downref: Normative reference to an Informational RFC: RFC 5920 ** Obsolete normative reference: RFC 7277 (Obsoleted by RFC 8344) == Outdated reference: A later version (-11) exists of draft-ietf-mpls-mldp-yang-06 Summary: 4 errors (**), 0 flaws (~~), 8 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 1 MPLS Working Group K. Raza, Ed. 2 Internet-Draft R. Asati 3 Intended status: Standards Track Cisco Systems 4 Expires: September 21, 2020 5 X. Liu 6 Volta Networks 8 S. Esale 9 Juniper Networks 11 X. Chen 12 Huawei Technologies 14 H. Shah 15 Ciena Corporation 17 March 20, 2020 19 YANG Data Model for MPLS LDP 20 draft-ietf-mpls-ldp-yang-09 22 Abstract 24 This document describes a YANG data model for Multi-Protocol Label 25 Switching (MPLS) Label Distribution Protocol (LDP). The model also 26 serves as the base model to define Multipoint LDP (mLDP) model. 28 The YANG modules in this document conform to the Network Management 29 Datastore Architecture (NMDA). 31 Status of This Memo 33 This Internet-Draft is submitted in full conformance with the 34 provisions of BCP 78 and BCP 79. 36 Internet-Drafts are working documents of the Internet Engineering 37 Task Force (IETF). Note that other groups may also distribute 38 working documents as Internet-Drafts. The list of current Internet- 39 Drafts is at https://datatracker.ietf.org/drafts/current/. 41 Internet-Drafts are draft documents valid for a maximum of six months 42 and may be updated, replaced, or obsoleted by other documents at any 43 time. It is inappropriate to use Internet-Drafts as reference 44 material or to cite them other than as "work in progress." 46 This Internet-Draft will expire on September 21, 2020. 48 Copyright Notice 50 Copyright (c) 2020 IETF Trust and the persons identified as the 51 document authors. All rights reserved. 53 This document is subject to BCP 78 and the IETF Trust's Legal 54 Provisions Relating to IETF Documents (https://trustee.ietf.org/ 55 license-info) in effect on the date of publication of this document. 56 Please review these documents carefully, as they describe your rights 57 and restrictions with respect to this document. Code Components 58 extracted from this document must include Simplified BSD License text 59 as described in Section 4.e of the Trust Legal Provisions and are 60 provided without warranty as described in the Simplified BSD License. 62 Table of Contents 64 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 65 1.1. Base and Extended . . . . . . . . . . . . . . . . . . . . 3 66 2. Specification of Requirements . . . . . . . . . . . . . . . . 4 67 3. Overview . . . . . . . . . . . . . . . . . . . . . . . . . . 4 68 4. The Complete Tree . . . . . . . . . . . . . . . . . . . . . . 7 69 5. Configuration . . . . . . . . . . . . . . . . . . . . . . . . 16 70 5.1. Configuration Hierarchy . . . . . . . . . . . . . . . . . 19 71 5.1.1. Global parameters . . . . . . . . . . . . . . . . . . 20 72 5.1.2. Capabilities parameters . . . . . . . . . . . . . . . 20 73 5.1.3. Per-Address-Family parameters . . . . . . . . . . . . 20 74 5.1.4. Hello Discovery parameters . . . . . . . . . . . . . 20 75 5.1.5. Peer parameters . . . . . . . . . . . . . . . . . . . 21 76 5.1.6. Forwarding parameters . . . . . . . . . . . . . . . . 21 77 6. Operational State . . . . . . . . . . . . . . . . . . . . . . 22 78 6.1. Adjacency state . . . . . . . . . . . . . . . . . . . . . 22 79 6.2. Peer state . . . . . . . . . . . . . . . . . . . . . . . 23 80 6.3. Bindings state . . . . . . . . . . . . . . . . . . . . . 24 81 6.4. Capabilities state . . . . . . . . . . . . . . . . . . . 26 82 7. Notifications . . . . . . . . . . . . . . . . . . . . . . . . 27 83 8. Action . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 84 9. YANG Specification . . . . . . . . . . . . . . . . . . . . . 27 85 9.1. Base . . . . . . . . . . . . . . . . . . . . . . . . . . 27 86 9.2. Extended . . . . . . . . . . . . . . . . . . . . . . . . 59 87 10. Security Considerations . . . . . . . . . . . . . . . . . . . 80 88 10.1. YANG model . . . . . . . . . . . . . . . . . . . . . . . 80 89 10.1.1. Writable nodes . . . . . . . . . . . . . . . . . . . 81 90 10.1.2. Readable nodes . . . . . . . . . . . . . . . . . . . 81 91 10.1.3. RPC operations . . . . . . . . . . . . . . . . . . . 82 92 10.1.4. Notifications . . . . . . . . . . . . . . . . . . . 83 93 11. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 83 94 12. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 83 95 13. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 84 96 14. Normative References . . . . . . . . . . . . . . . . . . . . 84 97 15. Informative References . . . . . . . . . . . . . . . . . . . 87 98 Appendix A. Data Tree Example . . . . . . . . . . . . . . . . . 88 99 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 92 101 1. Introduction 103 The Network Configuration Protocol (NETCONF) [RFC6241] is one of the 104 network management protocols that defines mechanisms to manage 105 network devices. YANG [RFC6020] [RFC7950] is a modular language that 106 represents data structures in an XML tree format, and is used as a 107 data modelling language for the NETCONF. 109 This document introduces a YANG data model for MPLS Label 110 Distribution Protocol (LDP) [RFC5036]. This model also covers LDP 111 IPv6 [RFC7552] and LDP capabilities [RFC5561] specifications. 113 The data model is defined for the following constructs that are used 114 for managing the protocol: 116 * Configuration 118 * Operational State 120 * Executables (Actions) 122 * Notifications 124 This document is organized to define the data model for each of the 125 above constructs in the sequence as listed above. 127 1.1. Base and Extended 129 The configuration and state items are divided into the following two 130 broad categories: 132 * Base 134 * Extended 136 The "base" category contains the basic and fundamental features that 137 are covered in LDP base specification [RFC5036] and constitute the 138 minimum requirements for a typical base LDP deployment. Whereas, the 139 "extended" category contains other non-base features. All the items 140 in a base category are mandatory and hence no "if-feature" is allowed 141 under the "base" category. The base and extended categories are 142 defined in their own modules as described later. 144 The example of base feature includes the configuration of LDP lsr-id, 145 enabling LDP interfaces, setting password for LDP session etc., 146 whereas the examples of extended feature include inbound/outbound 147 label policies, igp sync [RFC5443], downstream-on-demand etc. It is 148 worth highlighting that LDP IPv6 [RFC7552] is also categorized as an 149 extended feature. 151 While "base" model support will suffice for small deployments, it is 152 expected that large deployments will require both the "base" and 153 "extended" models support from the vendors. 155 2. Specification of Requirements 157 In this document, the word "IP" is used to refer to both IPv4 and 158 IPv6, unless otherwise explicitly stated. For example, "IP address 159 family" should be read as "IPv4 and/or IPv6 address family". 161 3. Overview 163 This document defines two new modules for LDP YANG support: 165 * "ietf-mpls-ldp" module that specifies the base LDP features and 166 augments /rt:routing/rt:control-plane-protocols/rt:control-plane- 167 protocol defined in [RFC8349]. We define new identity 'mpls-ldp' 168 for LDP and the model allows only a single instance of 'mpls-ldp'. 170 * "ietf-mpls-ldp-extended" module that specifies the extended LDP 171 features and augments the base LDP module. 173 It is to be noted that mLDP YANG model [I-D.ietf-mpls-mldp-yang] 174 augments LDP base and extended modules to specify the mLDP specific 175 base and extended features. 177 There are four types of containers in our module(s): 179 * Read-Write parameters for configuration (Section 5) 181 * Read-only parameters for operational state (Section 6) 183 * Notifications for events (Section 7) 185 * RPCs for executing commands to perform some action (Section 8) 187 The modules in this document conforms to the Network Management 188 Datastore Architecture (NMDA) defined in [RFC8342]. The operational 189 state data is combined with the associated configuration data in the 190 same hierarchy [RFC8407]. When protocol states are retrieved from 191 the NMDA operational state datastore, the returned states cover all 192 "config true" (rw) and "config false" (ro) nodes defined in the 193 schema. 195 Following diagram depicts high level LDP YANG tree organization and 196 hierarchy: 198 +-- rw routing 199 +-- rw control-plane-protocols 200 +-- rw control-plane-protocol 201 +-- rw mpls-ldp 202 +-- rw ... 203 +-- rw ... // base 204 | +-- rw ... 205 | +-- ro ... 206 | +-- 207 +-- ro ... 208 | +-- ro ... 209 | +-- ro ... 210 | +-- 211 +-- rw ldp-ext: .... // extended 212 | +-- rw ... 213 | +-- ro ... 214 | +-- 215 +-- ro ... 216 +-- ro ... 217 +-- ro ... 219 rpcs: 220 +-- x mpls-ldp-some_action 221 +-- x . . . . . 223 notifications: 224 +--- n mpls-ldp-some_event 225 +--- n ... 227 Figure 1: LDP YANG tree organization 229 Before going into data model details, it is important to take note of 230 the following points: 232 * This model aims to address only the core LDP parameters as per RFC 233 specification, as well as well-known and widely deployed 234 manageability controls (such as label filtering policies to apply 235 filtering rules on the assignment, advertisement, and acceptance 236 for label bindings). Any vendor specific feature should be 237 defined in a vendor-specific augmentation of this model. 239 * Multi-topology LDP [RFC7307] is beyond the scope of this document. 241 * This model does not cover any applications running on top of LDP, 242 nor does it cover any OAM procedures for LDP. 244 * This model is a VPN Routing and Forwarding (VRF)-centric model. 245 It is important to note that [RFC4364] defines VRF tables and 246 default forwarding tables as different, however from a YANG 247 modelling perspective this introduces unnecessary complications, 248 hence we are treating the default forwarding table as just another 249 VRF. 251 * A "network-instance", as defined in [RFC8529], refers to a VRF 252 instance (both default and non-default) within the scope of this 253 model. 255 * This model supports two address-families, namely "ipv4" and 256 "ipv6". 258 * This model assumes platform-wide label space (i.e. label space Id 259 of zero). However, when Upstream Label assignment [RFC6389] is in 260 use, an upstream assigned label is looked up in a Context-Specific 261 label space as defined in [RFC5331]. 263 * The label and peer policies (including filters) are defined using 264 prefix-set and neighbor-set respectively as defined in routing- 265 policy model [I-D.ietf-rtgwg-policy-model]. 267 * This model uses the terms LDP "neighbor"/"adjacency", "session", 268 and "peer" with the following semantics: 270 - Neighbor/Adjacency: An LDP enabled LSR that is discovered 271 through LDP discovery mechanisms. 273 - Session: An LDP neighbor with whom a TCP connection has been 274 established. 276 - Peer: An LDP session which has successfully progressed beyond 277 its initialization phase and is either already exchanging the 278 bindings or is ready to do so. 280 It is to be noted that LDP Graceful Restart (GR) mechanisms 281 defined in [RFC3478] allow keeping the exchanged bindings for some 282 time after a session goes down with a peer. We call such a state 283 belonging to a "stale" peer -- i.e. keeping peer bindings from a 284 peer with whom currently there is either no connection established 285 or connection is established but GR session is in recovery state. 286 When used in this document, the above terms will refer strictly to 287 the semantics and definitions defined for them. 289 A simplified graphical tree representation of base and extended LDP 290 YANG data model is presented in Figure 2. The meaning of the symbols 291 in these tree diagrams is defined in [RFC8340]. 293 The actual YANG specification for base and extended modules is 294 captured in Section 9. 296 While presenting the YANG tree view and actual specification, this 297 document assumes readers' familiarity with the concepts of YANG 298 modeling, its presentation and its compilation. 300 4. The Complete Tree 302 Following is a complete tree representation of configuration, state, 303 notification, and RPC items under LDP base and extended modules. 305 module: ietf-mpls-ldp 306 augment /rt:routing/rt:control-plane-protocols 307 /rt:control-plane-protocol: 308 +--rw mpls-ldp 309 +--rw global 310 | +--rw capability 311 | | +--rw ldp-ext:end-of-lib {capability-end-of-lib}? 312 | | | +--rw ldp-ext:enabled? boolean 313 | | +--rw ldp-ext:typed-wildcard-fec 314 | | | {capability-typed-wildcard-fec}? 315 | | | +--rw ldp-ext:enabled? boolean 316 | | +--rw ldp-ext:upstream-label-assignment 317 | | {capability-upstream-label-assignment}? 318 | | +--rw ldp-ext:enabled? boolean 319 | +--rw graceful-restart 320 | | +--rw enabled? boolean 321 | | +--rw reconnect-time? uint16 322 | | +--rw recovery-time? uint16 323 | | +--rw forwarding-holdtime? uint16 324 | | +--rw ldp-ext:helper-enabled? boolean 325 | | {graceful-restart-helper-mode}? 326 | +--rw lsr-id? 327 | | rt-types:router-id 328 | +--rw address-families 329 | | +--rw ipv4! 330 | | | +--rw enabled? boolean 331 | | | +--ro label-distribution-control-mode? enumeration 332 | | | +--ro bindings 333 | | | | +--ro address* [address] 334 | | | | | +--ro address inet:ipv4-address 335 | | | | | +--ro advertisement-type? advertised-received 336 | | | | | +--ro peer 337 | | | | | +--ro lsr-id? leafref 338 | | | | | +--ro label-space-id? leafref 339 | | | | +--ro fec-label* [fec] 340 | | | | +--ro fec inet:ipv4-prefix 341 | | | | +--ro peer* 342 | | | | [lsr-id label-space-id advertisement-type] 343 | | | | +--ro lsr-id leafref 344 | | | | +--ro label-space-id leafref 345 | | | | +--ro advertisement-type 346 | | | | | advertised-received 347 | | | | +--ro label? 348 | | | | | rt-types:mpls-label 349 | | | | +--ro used-in-forwarding? boolean 350 | | | +--rw ldp-ext:label-policy 351 | | | | +--rw ldp-ext:advertise 352 | | | | | +--rw ldp-ext:egress-explicit-null 353 | | | | | | +--rw ldp-ext:enabled? boolean 354 | | | | | +--rw ldp-ext:prefix-list? 355 | | | | | prefix-list-ref 356 | | | | +--rw ldp-ext:accept 357 | | | | | +--rw ldp-ext:prefix-list? prefix-list-ref 358 | | | | +--rw ldp-ext:assign 359 | | | | {policy-label-assignment-config}? 360 | | | | +--rw ldp-ext:independent-mode 361 | | | | | +--rw ldp-ext:prefix-list? prefix-list-ref 362 | | | | +--rw ldp-ext:ordered-mode 363 | | | | {policy-ordered-label-config}? 364 | | | | +--rw ldp-ext:egress-prefix-list? 365 | | | | prefix-list-ref 366 | | | +--rw ldp-ext:transport-address? 367 | | | inet:ipv4-address 368 | | +--rw ldp-ext:ipv6! 369 | | +--rw ldp-ext:enabled? 370 | | | boolean 371 | | +--rw ldp-ext:label-policy 372 | | | +--rw ldp-ext:advertise 373 | | | | +--rw ldp-ext:egress-explicit-null 374 | | | | | +--rw ldp-ext:enabled? boolean 375 | | | | +--rw ldp-ext:prefix-list? 376 | | | | prefix-list-ref 377 | | | +--rw ldp-ext:accept 378 | | | | +--rw ldp-ext:prefix-list? prefix-list-ref 379 | | | +--rw ldp-ext:assign 380 | | | {policy-label-assignment-config}? 381 | | | +--rw ldp-ext:independent-mode 382 | | | | +--rw ldp-ext:prefix-list? prefix-list-ref 383 | | | +--rw ldp-ext:ordered-mode 384 | | | {policy-ordered-label-config}? 385 | | | +--rw ldp-ext:egress-prefix-list? 386 | | | prefix-list-ref 387 | | +--rw ldp-ext:transport-address 388 | | | inet:ipv6-address 389 | | +--ro ldp-ext:label-distribution-control-mode? 390 | | | enumeration 391 | | +--ro ldp-ext:bindings 392 | | +--ro ldp-ext:address* [address] 393 | | | +--ro ldp-ext:address 394 | | | | inet:ipv6-address 395 | | | +--ro ldp-ext:advertisement-type? 396 | | | | advertised-received 397 | | | +--ro ldp-ext:peer 398 | | | +--ro ldp-ext:lsr-id? leafref 399 | | | +--ro ldp-ext:label-space-id? leafref 400 | | +--ro ldp-ext:fec-label* [fec] 401 | | +--ro ldp-ext:fec inet:ipv6-prefix 402 | | +--ro ldp-ext:peer* 403 | | [lsr-id label-space-id advertisement-type] 404 | | +--ro ldp-ext:lsr-id leafref 405 | | +--ro ldp-ext:label-space-id leafref 406 | | +--ro ldp-ext:advertisement-type 407 | | | advertised-received 408 | | +--ro ldp-ext:label? 409 | | | rt-types:mpls-label 410 | | +--ro ldp-ext:used-in-forwarding? boolean 411 | +--rw ldp-ext:forwarding-nexthop 412 | | {forwarding-nexthop-config}? 413 | | +--rw ldp-ext:interfaces 414 | | +--rw ldp-ext:interface* [name] 415 | | +--rw ldp-ext:name if:interface-ref 416 | | +--rw ldp-ext:address-family* [afi] 417 | | +--rw ldp-ext:afi identityref 418 | | +--rw ldp-ext:ldp-disable? boolean 419 | +--rw ldp-ext:igp-synchronization-delay? uint16 420 +--rw discovery 421 | +--rw interfaces 422 | | +--rw hello-holdtime? uint16 423 | | +--rw hello-interval? uint16 424 | | +--rw interface* [name] 425 | | +--rw name 426 | | | if:interface-ref 427 | | +--ro next-hello? uint16 428 | | +--rw address-families 429 | | | +--rw ipv4! 430 | | | | +--rw enabled? boolean 431 | | | | +--ro hello-adjacencies 432 | | | | | +--ro hello-adjacency* [adjacent-address] 433 | | | | | +--ro adjacent-address 434 | | | | | | inet:ipv4-address 435 | | | | | +--ro flag* identityref 436 | | | | | +--ro hello-holdtime 437 | | | | | | +--ro adjacent? uint16 438 | | | | | | +--ro negotiated? uint16 439 | | | | | | +--ro remaining? uint16 440 | | | | | +--ro next-hello? uint16 441 | | | | | +--ro statistics 442 | | | | | | +--ro discontinuity-time 443 | | | | | | | yang:date-and-time 444 | | | | | | +--ro hello-received? 445 | | | | | | | yang:counter64 446 | | | | | | +--ro hello-dropped? 447 | | | | | | yang:counter64 448 | | | | | +--ro peer 449 | | | | | +--ro lsr-id? leafref 450 | | | | | +--ro label-space-id? leafref 451 | | | | +--rw ldp-ext:transport-address? union 452 | | | +--rw ldp-ext:ipv6! 453 | | | +--rw ldp-ext:enabled? boolean 454 | | | +--ro ldp-ext:hello-adjacencies 455 | | | | +--ro ldp-ext:hello-adjacency* 456 | | | | [adjacent-address] 457 | | | | +--ro ldp-ext:adjacent-address 458 | | | | | inet:ipv6-address 459 | | | | +--ro ldp-ext:flag* 460 | | | | | identityref 461 | | | | +--ro ldp-ext:hello-holdtime 462 | | | | | +--ro ldp-ext:adjacent? uint16 463 | | | | | +--ro ldp-ext:negotiated? uint16 464 | | | | | +--ro ldp-ext:remaining? uint16 465 | | | | +--ro ldp-ext:next-hello? uint16 466 | | | | +--ro ldp-ext:statistics 467 | | | | | +--ro ldp-ext:discontinuity-time 468 | | | | | | yang:date-and-time 469 | | | | | +--ro ldp-ext:hello-received? 470 | | | | | | yang:counter64 471 | | | | | +--ro ldp-ext:hello-dropped? 472 | | | | | yang:counter64 473 | | | | +--ro ldp-ext:peer 474 | | | | +--ro ldp-ext:lsr-id? leafref 475 | | | | +--ro ldp-ext:label-space-id? leafref 476 | | | +--rw ldp-ext:transport-address? union 477 | | +--rw ldp-ext:hello-holdtime? uint16 478 | | | {per-interface-timer-config}? 479 | | +--rw ldp-ext:hello-interval? uint16 480 | | | {per-interface-timer-config}? 481 | | +--rw ldp-ext:igp-synchronization-delay? uint16 482 | | {per-interface-timer-config}? 483 | +--rw targeted 484 | +--rw hello-holdtime? uint16 485 | +--rw hello-interval? uint16 486 | +--rw hello-accept 487 | | +--rw enabled? boolean 488 | | +--rw ldp-ext:neighbor-list? neighbor-list-ref 489 | | {policy-targeted-discovery-config}? 490 | +--rw address-families 491 | +--rw ipv4! 492 | | +--ro hello-adjacencies 493 | | | +--ro hello-adjacency* 494 | | | [local-address adjacent-address] 495 | | | +--ro local-address inet:ipv4-address 496 | | | +--ro adjacent-address inet:ipv4-address 497 | | | +--ro flag* identityref 498 | | | +--ro hello-holdtime 499 | | | | +--ro adjacent? uint16 500 | | | | +--ro negotiated? uint16 501 | | | | +--ro remaining? uint16 502 | | | +--ro next-hello? uint16 503 | | | +--ro statistics 504 | | | | +--ro discontinuity-time 505 | | | | | yang:date-and-time 506 | | | | +--ro hello-received? 507 | | | | | yang:counter64 508 | | | | +--ro hello-dropped? 509 | | | | yang:counter64 510 | | | +--ro peer 511 | | | +--ro lsr-id? leafref 512 | | | +--ro label-space-id? leafref 513 | | +--rw target* [adjacent-address] 514 | | +--rw adjacent-address inet:ipv4-address 515 | | +--rw enabled? boolean 516 | | +--rw local-address? inet:ipv4-address 517 | +--rw ldp-ext:ipv6! 518 | +--ro ldp-ext:hello-adjacencies 519 | | +--ro ldp-ext:hello-adjacency* 520 | | [local-address adjacent-address] 521 | | +--ro ldp-ext:local-address 522 | | | inet:ipv6-address 523 | | +--ro ldp-ext:adjacent-address 524 | | | inet:ipv6-address 525 | | +--ro ldp-ext:flag* 526 | | | identityref 527 | | +--ro ldp-ext:hello-holdtime 528 | | | +--ro ldp-ext:adjacent? uint16 529 | | | +--ro ldp-ext:negotiated? uint16 530 | | | +--ro ldp-ext:remaining? uint16 531 | | +--ro ldp-ext:next-hello? uint16 532 | | +--ro ldp-ext:statistics 533 | | | +--ro ldp-ext:discontinuity-time 534 | | | | yang:date-and-time 535 | | | +--ro ldp-ext:hello-received? 536 | | | | yang:counter64 537 | | | +--ro ldp-ext:hello-dropped? 538 | | | yang:counter64 539 | | +--ro ldp-ext:peer 540 | | +--ro ldp-ext:lsr-id? leafref 541 | | +--ro ldp-ext:label-space-id? leafref 542 | +--rw ldp-ext:target* [adjacent-address] 543 | +--rw ldp-ext:adjacent-address 544 | | inet:ipv6-address 545 | +--rw ldp-ext:enabled? boolean 546 | +--rw ldp-ext:local-address? 547 | inet:ipv6-address 548 +--rw peers 549 +--rw authentication 550 | +--rw (authentication-type)? 551 | +--:(password) 552 | | +--rw key? string 553 | | +--rw crypto-algorithm? identityref 554 | +--:(ldp-ext:key-chain) {key-chain}? 555 | +--rw ldp-ext:key-chain? key-chain:key-chain-ref 556 +--rw session-ka-holdtime? uint16 557 +--rw session-ka-interval? uint16 558 +--rw peer* [lsr-id label-space-id] 559 | +--rw lsr-id rt-types:router-id 560 | +--rw label-space-id uint16 561 | +--rw authentication 562 | | +--rw (authentication-type)? 563 | | +--:(password) 564 | | | +--rw key? string 565 | | | +--rw crypto-algorithm? identityref 566 | | +--:(ldp-ext:key-chain) {key-chain}? 567 | | +--rw ldp-ext:key-chain? 568 | | key-chain:key-chain-ref 569 | +--rw address-families 570 | | +--rw ipv4! 571 | | | +--ro hello-adjacencies 572 | | | | +--ro hello-adjacency* 573 | | | | [local-address adjacent-address] 574 | | | | +--ro local-address inet:ipv4-address 575 | | | | +--ro adjacent-address inet:ipv4-address 576 | | | | +--ro flag* identityref 577 | | | | +--ro hello-holdtime 578 | | | | | +--ro adjacent? uint16 579 | | | | | +--ro negotiated? uint16 580 | | | | | +--ro remaining? uint16 581 | | | | +--ro next-hello? uint16 582 | | | | +--ro statistics 583 | | | | | +--ro discontinuity-time 584 | | | | | | yang:date-and-time 585 | | | | | +--ro hello-received? 586 | | | | | | yang:counter64 587 | | | | | +--ro hello-dropped? 588 | | | | | yang:counter64 589 | | | | +--ro interface? if:interface-ref 590 | | | +--rw ldp-ext:label-policy 591 | | | +--rw ldp-ext:advertise 592 | | | | +--rw ldp-ext:prefix-list? prefix-list-ref 593 | | | +--rw ldp-ext:accept 594 | | | +--rw ldp-ext:prefix-list? prefix-list-ref 595 | | +--rw ldp-ext:ipv6! 596 | | +--ro ldp-ext:hello-adjacencies 597 | | | +--ro ldp-ext:hello-adjacency* 598 | | | [local-address adjacent-address] 599 | | | +--ro ldp-ext:local-address 600 | | | | inet:ipv6-address 601 | | | +--ro ldp-ext:adjacent-address 602 | | | | inet:ipv6-address 603 | | | +--ro ldp-ext:flag* 604 | | | | identityref 605 | | | +--ro ldp-ext:hello-holdtime 606 | | | | +--ro ldp-ext:adjacent? uint16 607 | | | | +--ro ldp-ext:negotiated? uint16 608 | | | | +--ro ldp-ext:remaining? uint16 609 | | | +--ro ldp-ext:next-hello? uint16 610 | | | +--ro ldp-ext:statistics 611 | | | | +--ro ldp-ext:discontinuity-time 612 | | | | | yang:date-and-time 613 | | | | +--ro ldp-ext:hello-received? 614 | | | | | yang:counter64 615 | | | | +--ro ldp-ext:hello-dropped? 616 | | | | yang:counter64 617 | | | +--ro ldp-ext:interface? 618 | | | if:interface-ref 619 | | +--rw ldp-ext:label-policy 620 | | +--rw ldp-ext:advertise 621 | | | +--rw ldp-ext:prefix-list? prefix-list-ref 622 | | +--rw ldp-ext:accept 623 | | +--rw ldp-ext:prefix-list? prefix-list-ref 624 | +--ro label-advertisement-mode 625 | | +--ro local? label-adv-mode 626 | | +--ro peer? label-adv-mode 627 | | +--ro negotiated? label-adv-mode 628 | +--ro next-keep-alive? uint16 629 | +--ro received-peer-state 630 | | +--ro graceful-restart 631 | | | +--ro enabled? boolean 632 | | | +--ro reconnect-time? uint16 633 | | | +--ro recovery-time? uint16 634 | | +--ro capability 635 | | +--ro end-of-lib 636 | | | +--ro enabled? boolean 637 | | +--ro typed-wildcard-fec 638 | | | +--ro enabled? boolean 639 | | +--ro upstream-label-assignment 640 | | +--ro enabled? boolean 641 | +--ro session-holdtime 642 | | +--ro peer? uint16 643 | | +--ro negotiated? uint16 644 | | +--ro remaining? uint16 645 | +--ro session-state? enumeration 646 | +--ro tcp-connection 647 | | +--ro local-address? inet:ip-address 648 | | +--ro local-port? inet:port-number 649 | | +--ro remote-address? inet:ip-address 650 | | +--ro remote-port? inet:port-number 651 | +--ro up-time? 652 | | rt-types:timeticks64 653 | +--ro statistics 654 | | +--ro discontinuity-time yang:date-and-time 655 | | +--ro received 656 | | | +--ro total-octets? yang:counter64 657 | | | +--ro total-messages? yang:counter64 658 | | | +--ro address? yang:counter64 659 | | | +--ro address-withdraw? yang:counter64 660 | | | +--ro initialization? yang:counter64 661 | | | +--ro keepalive? yang:counter64 662 | | | +--ro label-abort-request? yang:counter64 663 | | | +--ro label-mapping? yang:counter64 664 | | | +--ro label-release? yang:counter64 665 | | | +--ro label-request? yang:counter64 666 | | | +--ro label-withdraw? yang:counter64 667 | | | +--ro notification? yang:counter64 668 | | +--ro sent 669 | | | +--ro total-octets? yang:counter64 670 | | | +--ro total-messages? yang:counter64 671 | | | +--ro address? yang:counter64 672 | | | +--ro address-withdraw? yang:counter64 673 | | | +--ro initialization? yang:counter64 674 | | | +--ro keepalive? yang:counter64 675 | | | +--ro label-abort-request? yang:counter64 676 | | | +--ro label-mapping? yang:counter64 677 | | | +--ro label-release? yang:counter64 678 | | | +--ro label-request? yang:counter64 679 | | | +--ro label-withdraw? yang:counter64 680 | | | +--ro notification? yang:counter64 681 | | +--ro total-addresses? uint32 682 | | +--ro total-labels? uint32 683 | | +--ro total-fec-label-bindings? uint32 684 | +--rw ldp-ext:admin-down? boolean 685 | | {per-peer-admin-down}? 686 | +--rw ldp-ext:graceful-restart 687 | | {per-peer-graceful-restart-config}? 688 | | +--rw ldp-ext:enabled? boolean 689 | | +--rw ldp-ext:reconnect-time? uint16 690 | | +--rw ldp-ext:recovery-time? uint16 691 | +--rw ldp-ext:session-ka-holdtime? uint16 692 | | {per-peer-session-attributes-config}? 693 | +--rw ldp-ext:session-ka-interval? uint16 694 | {per-peer-session-attributes-config}? 695 +--rw ldp-ext:session-downstream-on-demand 696 | {session-downstream-on-demand-config}? 697 | +--rw ldp-ext:enabled? boolean 698 | +--rw ldp-ext:peer-list? peer-list-ref 699 +--rw ldp-ext:dual-stack-transport-preference 700 {peers-dual-stack-transport-preference}? 701 +--rw ldp-ext:max-wait? uint16 702 +--rw ldp-ext:prefer-ipv4! 703 +--rw ldp-ext:peer-list? peer-list-ref 705 rpcs: 706 +---x mpls-ldp-clear-peer 707 | +---w input 708 | +---w protocol-name? leafref 709 | +---w lsr-id? leafref 710 | +---w label-space-id? leafref 711 +---x mpls-ldp-clear-hello-adjacency 712 | +---w input 713 | +---w hello-adjacency 714 | +---w protocol-name? leafref 715 | +---w (hello-adjacency-type)? 716 | +--:(targeted) 717 | | +---w targeted! 718 | | +---w target-address? inet:ip-address 719 | +--:(link) 720 | +---w link! 721 | +---w next-hop-interface? leafref 722 | +---w next-hop-address? inet:ip-address 723 +---x mpls-ldp-clear-peer-statistics 724 +---w input 725 +---w protocol-name? leafref 726 +---w lsr-id? leafref 727 +---w label-space-id? leafref 729 notifications: 730 +---n mpls-ldp-peer-event 731 | +--ro event-type? oper-status-event-type 732 | +--ro peer 733 | +--ro protocol-name? leafref 734 | +--ro lsr-id? leafref 735 | +--ro label-space-id? leafref 736 +---n mpls-ldp-hello-adjacency-event 737 | +--ro event-type? oper-status-event-type 738 | +--ro protocol-name? leafref 739 | +--ro (hello-adjacency-type)? 740 | +--:(targeted) 741 | | +--ro targeted 742 | | +--ro target-address? inet:ip-address 743 | +--:(link) 744 | +--ro link 745 | +--ro next-hop-interface? if:interface-ref 746 | +--ro next-hop-address? inet:ip-address 747 +---n mpls-ldp-fec-event 748 +--ro event-type? oper-status-event-type 749 +--ro protocol-name? leafref 750 +--ro fec? inet:ip-prefix 752 Figure 2: Complete Tree 754 5. Configuration 756 This specification defines the configuration parameters for base LDP 757 as specified in [RFC5036] and LDP IPv6 [RFC7552]. Moreover, it 758 incorporates provisions to enable LDP Capabilities [RFC5561], and 759 defines some of the most significant and commonly used capabilities 760 such as Typed Wildcard FEC [RFC5918], End-of-LIB [RFC5919], and LDP 761 Upstream Label Assignment [RFC6389]. 763 This model augments /rt:routing/rt:control-plane-protocols/ 764 rt:control-plane-protocol that is defined in [RFC8349] and follows 765 NMDA as mentioned earlier. 767 Following is the high-level configuration organization for base LDP 768 module: 770 augment /rt:routing/rt:control-plane-protocols: 771 /rt:control-plane-protocol: 772 +-- mpls-ldp 773 +-- global 774 | +-- ... 775 | +-- ... 776 | +-- address-families 777 | | +-- ipv4 778 | | +-- . . . 779 | | +-- . . . 780 | +-- capability 781 | +-- ... 782 | +-- ... 783 +-- discovery 784 | +-- interfaces 785 | | +-- ... 786 | | +-- ... 787 | | +-- interface* [interface] 788 | | +-- ... 789 | | +-- address-families 790 | | +-- ipv4 791 | | +-- ... 792 | | +-- ... 793 | +-- targeted 794 | +-- ... 795 | +-- address-families 796 | +-- ipv4 797 | +- target* [adjacent-address] 798 | +- ... 799 | +- ... 800 +-- peers 801 +-- ... 802 +-- ... 803 +-- peer* [lsr-id label-space-id] 804 +-- ... 805 +-- ... 807 Figure 3: Base Configuration organization 809 Following is the high-level configuration organization for extended 810 LDP: 812 augment /rt:routing/rt:control-plane-protocols/rt:control-plane-protocol 813 +-- mpls-ldp 814 +-- global 815 | +-- ... 816 | +-- ... 817 | +-- address-families 818 | | +-- ipv4 819 | | | +-- . . . 820 | | | +-- . . . 821 | | | +-- label-policy 822 | | | +-- ... 823 | | | +-- ... 824 | | +-- ipv6 825 | | +-- . . . 826 | | +-- . . . 827 | | +-- label-policy 828 | | +-- ... 829 | | +-- ... 830 | +-- capability 831 | | +-- ... 832 | | +-- ... 833 | +-- discovery 834 | +-- interfaces 835 | | +-- ... 836 | | +-- ... 837 | | +-- interface* [interface] 838 | | +-- ... 839 | | +-- address-families 840 | | +-- ipv4 841 | | | +-- ... 842 | | | +-- ... 843 | | +-- ipv6 844 | | +-- ... 845 | | +-- ... 846 | +-- targeteted 847 | +-- ... 848 | +-- address-families 849 | +-- ipv6 850 | +- target* [adjacent-address] 851 | +- ... 852 | +- ... 853 +-- forwarding-nexthop 854 | +-- ... 855 | +-- ... 856 +-- peers 857 +-- ... 858 +-- ... 859 +-- peer* 860 +-- ... 861 +-- ... 862 +-- label-policy 863 | +-- .. 864 +-- address-families 865 +-- ipv4 866 | +-- ... 867 +-- ipv6 868 +-- ... 870 Figure 4: Extended Configuration organization 872 Given the configuration hierarchy, the model allows inheritance such 873 that an item in a child tree is able to derive value from a similar 874 or related item in one of the parents. For instance, hello holdtime 875 can be configured per-VRF or per-VRF-interface, thus allowing 876 inheritance as well flexibility to override with a different value at 877 any child level. 879 5.1. Configuration Hierarchy 881 LDP module resides under a network-instance and the scope of any LDP 882 configuration defined under this tree is per network-instance (per- 883 VRF). This configuration is further divided into sub categories as 884 follows. 886 * Global parameters 888 * Per-address-family parameters 890 * LDP Capabilities parameters 892 * Hello Discovery parameters 894 - interfaces 896 o Global 898 o Per-interface: Global 900 o Per-interface: Per-address-family 902 - targeted 904 o Global 905 o Per-address-family: Per-target 907 * Peer parameters 909 - Global 911 - Per-peer: Global 913 - Per-peer: Per-address-family 915 * Forwarding parameters 917 Following subsections briefly explain these configuration areas. 919 5.1.1. Global parameters 921 There are configuration items that are available directly under a VRF 922 instance and do not fall under any other sub tree. Example of such a 923 parameter is LDP LSR Id that is typically configured per VRF. To 924 keep legacy LDP features and applications working in an LDP IPv4 925 networks with this model, this document recommends an operator to 926 pick a routable IPv4 unicast address (within a routing domain) as an 927 LSR Id. 929 5.1.2. Capabilities parameters 931 This container falls under the global tree and holds the LDP 932 capabilities that are to be enabled for certain features. By 933 default, an LDP capability is disabled unless explicitly enabled. 934 These capabilities are typically used to negotiate with LDP peer(s) 935 the support/non-support related to a feature and its parameters. The 936 scope of a capability enabled under this container applies to all LDP 937 peers in the given VRF instance. There is also a peer level 938 capability container that is provided to override a capability that 939 is enabled/specified at VRF level. 941 5.1.3. Per-Address-Family parameters 943 Any LDP configuration parameter related to IP address family (AF) 944 whose scope is VRF wide is configured under this tree. The examples 945 of per-AF parameters include enabling LDP for an address family, 946 prefix-list based label policies, and LDP transport address. 948 5.1.4. Hello Discovery parameters 950 This container is used to hold LDP configuration related to Hello and 951 discovery process for both basic (link) and extended (targeted) 952 discovery. 954 The "interfaces" is a container to configure parameters related to 955 VRF interfaces. There are parameters that apply to all interfaces 956 (such as hello timers), as well as parameters that can be configured 957 per-interface. Hence, an interface list is defined under 958 "interfaces" container. The model defines parameters to configure 959 per-interface non AF related items, as well as per-interface per-AF 960 items. The example of the former is interface hello timers, and 961 example of the latter is enabling hellos for a given AF under an 962 interface. 964 The "targeted" container under a VRF instance allows to configure LDP 965 targeted discovery related parameters. Within this container, the 966 "target" list provides a means to configure multiple target addresses 967 to perform extended discovery to a specific destination target, as 968 well as to fine-tune the per-target parameters. 970 5.1.5. Peer parameters 972 This container is used to hold LDP configuration related to LDP 973 sessions and peers under a VRF instance. This container allows to 974 configure parameters that either apply on VRF's all peers or a subset 975 (peer-list) of VRF peers. The example of such parameters include 976 authentication password, session KA timers etc. Moreover, the model 977 also allows per-peer parameter tuning by specifying a "peer" list 978 under the "peers" container. A peer is uniquely identified by its 979 LSR Id. 981 Like per-interface parameters, some per-peer parameters are AF- 982 agnostic (i.e. either non AF related or apply to both IP address 983 families), and some that belong to an AF. The example of the former 984 is per-peer session password configuration, whereas the example of 985 the latter is prefix-list based label policies (inbound and outbound) 986 that apply to a given peer. 988 5.1.6. Forwarding parameters 990 This container is used to hold configuration used to control LDP 991 forwarding behavior under a VRF instance. One example of a 992 configuration under this container is when a user wishes to enable 993 neighbor discovery on an interface but wishes to disable use of the 994 same interface as forwarding nexthop. This example configuration 995 makes sense only when there are more than one LDP enabled interfaces 996 towards the neighbor. 998 6. Operational State 1000 Operational state of LDP can be queried and obtained from read-only 1001 state containers that fall under the same tree (/rt:routing/ 1002 rt:control-plane-protocols/rt:control-plane-protocol) as the 1003 configuration. 1005 Following are main areas for which LDP operational state is defined: 1007 * Neighbor Adjacencies 1009 * Peer 1011 * Bindings (FEC-label and address) 1013 * Capabilities 1015 6.1. Adjacency state 1017 Neighbor adjacencies are per address-family hello adjacencies that 1018 are formed with neighbors as result of LDP basic or extended 1019 discovery. In terms of organization, there is a source of discovery 1020 (e.g. interface or target address) along with its associated 1021 parameters and one or more discovered neighbors along with neighbor 1022 discovery related parameters. For the basic discovery, there could 1023 be more than one discovered neighbor for a given source (interface), 1024 whereas there is at most one discovered neighbor for an extended 1025 discovery source (local-address and target-address). It is also to 1026 be noted that the reason for a targeted neighbor adjacency could be 1027 either an active source (locally configured targeted) or passive 1028 source (to allow any incoming extended/targeted hellos). A neighbor/ 1029 adjacency record also contains session-state that helps highlight 1030 whether a given adjacency has progressed to subsequent session level 1031 or to eventual peer level. 1033 Following captures high level tree hierarchy for neighbor adjacency 1034 state. The tree is shown for ipv4 address-family only; a similar 1035 tree exists for ipv6 address-family as well. 1037 +--rw mpls-ldp! 1038 +--rw discovery 1039 +--rw interfaces 1040 | +--rw interface* [interface] 1041 | +--rw address-families 1042 | +--rw ipv4 1043 | +--ro hello-adjacencies 1044 | +--ro hello-adjacencies* [adjacent-address] 1045 | +--ro adjacent-address 1046 | . . . . 1047 | . . . . 1048 +--rw targeted 1049 +--rw address-families 1050 +--rw ipv4 1051 +--ro hello-adjacencies 1052 +--ro hello-adjacencies* 1053 | [local-address adjacent-address] 1054 +--ro local-address 1055 +--ro adjacent-address 1056 . . . . 1057 . . . . 1059 Figure 5: Adjacency state 1061 6.2. Peer state 1063 Peer related state is presented under peers tree. This is one of the 1064 core state that provides info on the session related parameters 1065 (mode, authentication, KA timeout etc.), TCP connection info, hello 1066 adjacencies for the peer, statistics related to messages and 1067 bindings, and capabilities exchange info. 1069 Following captures high level tree hierarchy for peer state. The 1070 peer's hello adjacencies tree is shown for ipv4 address-family only; 1071 a similar tree exists for ipv6 address-family as well. 1073 +--rw mpls-ldp! 1074 +--rw peers 1075 +--rw peer* [lsr-id label-space-id] 1076 +--rw lsr-id 1077 +--rw label-space-id 1078 +--ro label-advertisement-mode 1079 +--ro session-state 1080 +--ro tcp-connection 1081 +--ro session-holdtime? 1082 +--ro up-time 1083 +-- . . . . 1084 +--ro address-families 1085 | +--ro ipv4 1086 | +--ro hello-adjacencies 1087 | +--ro hello-adjacencies* 1088 | [local-address adjacent-address] 1089 | . . . . 1090 | . . . . 1091 +--ro received-peer-state 1092 | +--ro . . . . 1093 | +--ro capability 1094 | +--ro . . . . 1095 +--ro statistics 1096 +-- . . . . 1097 +-- received 1098 | +-- ... 1099 +-- sent 1100 +-- ... 1102 Figure 6: Peer state 1104 6.3. Bindings state 1106 Binding state provides information on LDP FEC-label bindings as well 1107 as address binding for both inbound (received) as well as outbound 1108 (advertised) direction. FEC-label bindings are presented as a FEC- 1109 centric view, and address bindings are presented as an address- 1110 centric view: 1112 FEC-Label bindings: 1113 FEC 203.0.113.1/32: 1114 advertised: local-label 16000 1115 peer 192.0.2.1:0 1116 peer 192.0.2.2:0 1117 peer 192.0.2.3:0 1118 received: 1119 peer 192.0.2.1:0, label 16002, used-in-forwarding=Yes 1120 peer 192.0.2.2:0, label 17002, used-in-forwarding=No 1121 FEC 203.0.113.2/32: 1122 . . . . 1123 FEC 198.51.100.0/24: 1124 . . . . 1125 FEC 2001:db8:0:2:: 1126 . . . . 1127 FEC 2001:db8:0:3:: 1128 . . . . 1130 Address bindings: 1131 Addr 192.0.2.10: 1132 advertised 1133 Addr 2001:db8:0:10:: 1134 advertised 1136 Addr 192.0.2.1: 1137 received, peer 192.0.2.1:0 1138 Addr 192.0.2.2: 1139 received, peer 192.0.2.2:0 1140 Addr 192.0.2.3: 1141 received, peer 192.0.2.3:0 1142 Addr 2001:db8:0:2:: 1143 received, peer 192.0.2.2:0 1144 Addr 2001:db8:0:3:: 1145 received, peer 192.0.2.3:0 1147 Figure 7: Example Bindings 1149 Note that all local addresses are advertised to all peers and hence 1150 no need to provide per-peer information for local address 1151 advertisement. Furthermore, note that it is easy to derive a peer- 1152 centric view for the bindings from the information already provided 1153 in this model. 1155 Following captures high level tree hierarchy for bindings state. The 1156 tree shown below is for ipv4 address-family only; a similar tree 1157 exists for ipv6 address-family as well. 1159 +--rw mpls-ldp! 1160 +--rw global 1161 +--rw address-families 1162 +--rw ipv4 1163 +--ro bindings 1164 +--ro address* [address] 1165 | +--ro address (ipv4-address or ipv6-address) 1166 | +--ro advertisement-type? advertised-received 1167 | +--ro peer? leafref 1168 +--ro fec-label* [fec] 1169 +--ro fec (ipv4-prefix or ipv6-prefix) 1170 +--ro peer* [peer advertisement-type] 1171 +--ro peer leafref 1172 +--ro advertisement-type? advertised-received 1173 +--ro label? mpls:mpls-label 1174 +--ro used-in-forwarding? boolean 1176 Figure 8: Bindings state 1178 6.4. Capabilities state 1180 LDP capabilities state comprise two types of information - global 1181 information (such as timer etc.), and per-peer information. 1183 Following captures high level tree hierarchy for LDP capabilities 1184 state. 1186 +--rw mpls-ldp! 1187 +--rw peers 1188 +--rw peer* [lsr-id label-space-id] 1189 +--rw lsr-id yang:dotted-quad 1190 +--rw label-space-id 1191 +--ro received-peer-state 1192 +--ro capability 1193 +--ro . . . . 1194 +--ro . . . . 1196 Figure 9: Capabilities state 1198 7. Notifications 1200 This model defines a list of notifications to inform client of 1201 important events detected during the protocol operation. These 1202 events include events related to changes in the operational state of 1203 an LDP peer, hello adjacency, and FEC etc. It is to be noted that an 1204 LDP FEC is treated as operational (up) as long as it has at least 1 1205 NHLFE (Next Hop Label Forwarding Entry) with outgoing label. 1207 A simplified graphical representation of the data model for LDP 1208 notifications is shown in Figure 2. 1210 8. Action 1212 This model defines a list of rpcs that allow performing an action or 1213 executing a command on the protocol. For example, it allows to clear 1214 (reset) LDP peers, hello-adjacencies, and statistics. The model 1215 makes an effort to provide different level of control so that a user 1216 is able to either clear all, or clear all for a given type, or clear 1217 a specific entity. 1219 A simplified graphical representation of the data model for LDP 1220 actions is shown in Figure 2. 1222 9. YANG Specification 1224 Following sections specify the actual YANG (module) specification for 1225 LDP constructs defined earlier in the document. 1227 9.1. Base 1229 This YANG module imports types defined in [RFC6991], [RFC8349], 1230 [RFC8294], [RFC8343], and [RFC8344]. 1232 file "ietf-mpls-ldp@2020-02-25.yang" 1234 // RFC Editor: replace the above date 2020-02-25 with the date of 1235 // publication and remove this note. 1237 module ietf-mpls-ldp { 1238 yang-version 1.1; 1240 namespace "urn:ietf:params:xml:ns:yang:ietf-mpls-ldp"; 1241 prefix "ldp"; 1243 import ietf-inet-types { 1244 prefix "inet"; 1245 reference "RFC 6991: Common YANG Data Types"; 1246 } 1248 import ietf-yang-types { 1249 prefix "yang"; 1250 reference "RFC 6991: Common YANG Data Types"; 1251 } 1253 import ietf-routing { 1254 prefix "rt"; 1255 reference 1256 "RFC 8349: A YANG Data Model for Routing Management (NMDA 1257 version)"; 1258 } 1260 import ietf-routing-types { 1261 prefix "rt-types"; 1262 reference 1263 "RFC 8294: Common YANG Data Types for the Routing Area"; 1264 } 1266 import ietf-interfaces { 1267 prefix "if"; 1268 reference "RFC 8343: A YANG Data Model for Interface Management"; 1269 } 1271 import ietf-ip { 1272 prefix "ip"; 1273 reference "RFC 7277: A YANG Data Model for IP Management"; 1274 } 1276 import ietf-key-chain { 1277 prefix "key-chain"; 1278 reference "RFC 8177: YANG Data Model for Key Chains"; 1279 } 1281 organization 1282 "IETF MPLS Working Group"; 1283 contact 1284 "WG Web: 1285 WG List: 1287 Editor: Kamran Raza 1288 1290 Editor: Rajiv Asati 1291 1293 Editor: Xufeng Liu 1294 1296 Editor: Santosh Esale 1297 1299 Editor: Xia Chen 1300 1302 Editor: Himanshu Shah 1303 "; 1305 description 1306 "This YANG module defines the essential components for the 1307 management of Multi-Protocol Label Switching (MPLS) Label 1308 Distribution Protocol (LDP). It is also the base model to 1309 be augmented for Multipoint LDP (mLDP). 1311 Copyright (c) 2020 IETF Trust and the persons identified as 1312 authors of the code. All rights reserved. 1314 Redistribution and use in source and binary forms, with or 1315 without modification, is permitted pursuant to, and subject to 1316 the license terms contained in, the Simplified BSD License set 1317 forth in Section 4.c of the IETF Trust's Legal Provisions 1318 Relating to IETF Documents 1319 (http://trustee.ietf.org/license-info). 1321 This version of this YANG module is part of RFC XXXX; see the 1322 RFC itself for full legal notices."; 1324 // RFC Editor: replace XXXX with actual RFC number and remove 1325 // this note 1327 revision 2020-02-25 { 1328 description 1329 "Initial revision."; 1330 reference 1331 "RFC XXXX: YANG Data Model for MPLS LDP."; 1332 // RFC Editor: replace XXXX with actual RFC number and remove 1333 // this note 1334 } 1336 /* 1337 * Typedefs 1338 */ 1339 typedef advertised-received { 1340 type enumeration { 1341 enum advertised { 1342 description "Advertised information."; 1343 } 1344 enum received { 1345 description "Received information."; 1346 } 1347 } 1348 description 1349 "Received or advertised."; 1350 } 1352 typedef downstream-upstream { 1353 type enumeration { 1354 enum downstream { 1355 description "Downstream information."; 1356 } 1357 enum upstream { 1358 description "Upstream information."; 1359 } 1360 } 1361 description 1362 "Downstream or upstream."; 1363 } 1365 typedef label-adv-mode { 1366 type enumeration { 1367 enum downstream-unsolicited { 1368 description "Downstream Unsolicited."; 1369 } 1370 enum downstream-on-demand { 1371 description "Downstream on Demand."; 1372 } 1373 } 1374 description 1375 "Label Advertisement Mode."; 1376 } 1378 typedef oper-status-event-type { 1379 type enumeration { 1380 enum up { 1381 value 1; 1382 description 1383 "Operational status changed to up."; 1384 } 1385 enum down { 1386 value 2; 1387 description 1388 "Operational status changed to down."; 1390 } 1391 } 1392 description "Operational status event type for notifications."; 1393 } 1395 /* 1396 * Identities 1397 */ 1398 identity mpls-ldp { 1399 base rt:control-plane-protocol; 1400 description 1401 "LDP protocol."; 1402 reference 1403 "RFC 5036: LDP Specification"; 1404 } 1406 identity adjacency-flag-base { 1407 description "Base type for adjacency flags."; 1408 } 1410 identity adjacency-flag-active { 1411 base adjacency-flag-base; 1412 description 1413 "This adjacency is configured and actively created."; 1414 } 1416 identity adjacency-flag-passive { 1417 base adjacency-flag-base; 1418 description 1419 "This adjacency is not configured and passively accepted."; 1420 } 1422 /* 1423 * Groupings 1424 */ 1426 grouping adjacency-state-attributes { 1427 description 1428 "The operational state attributes of an LDP Hello adjacency, 1429 which can used for basic and extended discoveris, in IPv4 and 1430 IPv6 address families."; 1432 leaf-list flag { 1433 type identityref { 1434 base adjacency-flag-base; 1435 } 1436 description 1437 "On or more flags to indicate whether the adjacency is 1438 actively created, passively accepted, or both."; 1439 } 1440 container hello-holdtime { 1441 description 1442 "Containing Hello holdtime state information."; 1443 leaf adjacent { 1444 type uint16; 1445 units seconds; 1446 description 1447 "The holdtime value learned from the adjacent LSR."; 1448 } 1449 leaf negotiated { 1450 type uint16; 1451 units seconds; 1452 description 1453 "The holdtime negotiated between this LSR and the adjacent 1454 LSR."; 1455 } 1456 leaf remaining { 1457 type uint16; 1458 units seconds; 1459 description 1460 "The time remaining until the holdtime timer expires."; 1461 } 1462 } 1464 leaf next-hello { 1465 type uint16; 1466 units seconds; 1467 description 1468 "The time when the next Hello message will be sent."; 1469 } 1471 container statistics { 1472 description 1473 "Statistics objects."; 1475 leaf discontinuity-time { 1476 type yang:date-and-time; 1477 mandatory true; 1478 description 1479 "The time on the most recent occasion at which any one or 1480 more of this interface's counters suffered a 1481 discontinuity. If no such discontinuities have occurred 1482 since the last re-initialization of the local management 1483 subsystem, then this node contains the time the local 1484 management subsystem re-initialized itself."; 1485 } 1486 leaf hello-received { 1487 type yang:counter64; 1488 description 1489 "The number of Hello messages received."; 1490 } 1491 leaf hello-dropped { 1492 type yang:counter64; 1493 description 1494 "The number of Hello messages dropped."; 1495 } 1496 } // statistics 1497 } // adjacency-state-attributes 1499 grouping basic-discovery-timers { 1500 description 1501 "The timer attributes for basic discovery, used in the 1502 per-interface setting and in the all-interface setting."; 1504 leaf hello-holdtime { 1505 type uint16 { 1506 range 15..3600; 1507 } 1508 units seconds; 1509 description 1510 "The time interval for which a LDP link Hello adjacency 1511 is maintained in the absence of link Hello messages from 1512 the LDP neighbor. 1513 This leaf may be configured at the per-interface level or 1514 the global level, with precedence given to the value at the 1515 per-interface level. If the leaf is not configured at 1516 either level, the default value at the global level is 1517 used."; 1518 } 1519 leaf hello-interval { 1520 type uint16 { 1521 range 5..1200; 1522 } 1523 units seconds; 1524 description 1525 "The interval between consecutive LDP link Hello messages 1526 used in basic LDP discovery. 1527 This leaf may be configured at the per-interface level or 1528 the global level, with precedence given to the value at the 1529 per-interface level. If the leaf is not configured at 1530 either level, the default value at the global level is 1531 used."; 1532 } 1533 } // basic-discovery-timers 1534 grouping binding-address-state-attributes { 1535 description 1536 "Operational state attributes of an address binding, used in 1537 IPv4 and IPv6 address families."; 1539 leaf advertisement-type { 1540 type advertised-received; 1541 description 1542 "Received or advertised."; 1543 } 1544 container peer { 1545 when "../advertisement-type = 'received'" { 1546 description 1547 "Applicable for received address."; 1548 } 1549 description 1550 "LDP peer from which this address is received."; 1551 uses ldp-peer-ref-from-binding; 1552 } 1553 } // binding-address-state-attributes 1555 grouping binding-label-state-attributes { 1556 description 1557 "Operational state attributes for a FEC-label binding, used in 1558 IPv4 and IPv6 address families."; 1560 list peer { 1561 key "lsr-id label-space-id advertisement-type"; 1562 description 1563 "List of advertised and received peers."; 1564 uses ldp-peer-ref-from-binding { 1565 description 1566 "The LDP peer from which this binding is received, or to 1567 which this binding is advertised. 1568 The peer is identified by its LDP ID, which consists of 1569 the LSR ID and the Label Space ID."; 1570 } 1571 leaf advertisement-type { 1572 type advertised-received; 1573 description 1574 "Received or advertised."; 1575 } 1576 leaf label { 1577 type rt-types:mpls-label; 1578 description 1579 "Advertised (outbound) or received (inbound) 1580 label."; 1581 } 1582 leaf used-in-forwarding { 1583 type boolean; 1584 description 1585 "'true' if the label is used in forwarding."; 1586 } 1587 } // peer 1588 } // binding-label-state-attributes 1590 grouping graceful-restart-attributes-per-peer { 1591 description 1592 "Per peer graceful restart attributes. 1593 On the local side, these attributes are configuration and 1594 operational state data. One the peer side, these attributes 1595 are operational state data received from the peer."; 1597 container graceful-restart { 1598 description 1599 "Attributes for graceful restart."; 1600 leaf enabled { 1601 type boolean; 1602 description 1603 "Enable or disable graceful restart. 1604 This leaf may be configured at the per-peer level or the 1605 global level, with precedence given to the value at the 1606 per-peer level. If the leaf is not configured at either 1607 level, the default value at the global level is used."; 1608 } 1609 leaf reconnect-time { 1610 type uint16 { 1611 range 10..1800; 1612 } 1613 units seconds; 1614 description 1615 "Specifies the time interval that the remote LDP peer 1616 must wait for the local LDP peer to reconnect after the 1617 remote peer detects the LDP communication failure. 1618 This leaf may be configured at the per-peer level or the 1619 global level, with precedence given to the value at the 1620 per-peer level. If the leaf is not configured at either 1621 level, the default value at the global level is used."; 1622 } 1623 leaf recovery-time { 1624 type uint16 { 1625 range 30..3600; 1626 } 1627 units seconds; 1628 description 1629 "Specifies the time interval, in seconds, that the remote 1630 LDP peer preserves its MPLS forwarding state after 1631 receiving the Initialization message from the restarted 1632 local LDP peer. 1633 This leaf may be configured at the per-peer level or the 1634 global level, with precedence given to the value at the 1635 per-peer level. If the leaf is not configured at either 1636 level, the default value at the global level is used."; 1637 } 1638 } // graceful-restart 1639 } // graceful-restart-attributes-per-peer 1641 grouping ldp-interface-ref { 1642 description 1643 "Defining a reference to LDP interface."; 1645 leaf name { 1646 type if:interface-ref; 1647 must "(/if:interfaces/if:interface[if:name=current()]/ip:ipv4)" 1648 + " or " 1649 + "(/if:interfaces/if:interface[if:name=current()]/ip:ipv6)" 1650 { 1651 description "Interface is IPv4 or IPv6."; 1652 } 1653 description 1654 "The name of an LDP interface."; 1655 } 1656 } 1658 grouping ldp-peer-ref-absolute { 1659 description 1660 "An absolute reference to an LDP peer, by the LDP ID, which 1661 consists of the LSR ID and the Label Space ID."; 1663 leaf protocol-name { 1664 type leafref { 1665 path "/rt:routing/rt:control-plane-protocols/" 1666 + "rt:control-plane-protocol/rt:name"; 1667 } 1668 description 1669 "The name of the LDP protocol instance."; 1670 } 1671 leaf lsr-id { 1672 type leafref { 1673 path "/rt:routing/rt:control-plane-protocols/" 1674 + "rt:control-plane-protocol" 1675 + "[rt:name=current()/../protocol-name]/" 1676 + "ldp:mpls-ldp/ldp:peers/ldp:peer/ldp:lsr-id"; 1677 } 1678 description 1679 "The LSR ID of the peer, as a portion of the peer LDP ID."; 1680 } 1681 leaf label-space-id { 1682 type leafref { 1683 path "/rt:routing/rt:control-plane-protocols/" 1684 + "rt:control-plane-protocol" 1685 + "[rt:name=current()/../protocol-name]/" 1686 + "ldp:mpls-ldp/ldp:peers/" 1687 + "ldp:peer[ldp:lsr-id=current()/../lsr-id]/" 1688 + "ldp:label-space-id"; 1689 } 1690 description 1691 "The Label Space ID of the peer, as a portion of the peer 1692 LDP ID."; 1693 } 1694 } // ldp-peer-ref-absolute 1696 grouping ldp-peer-ref-from-binding { 1697 description 1698 "A relative reference to an LDP peer, by the LDP ID, which 1699 consists of the LSR ID and the Label Space ID."; 1701 leaf lsr-id { 1702 type leafref { 1703 path "../../../../../../../ldp:peers/ldp:peer/ldp:lsr-id"; 1704 } 1705 description 1706 "The LSR ID of the peer, as a portion of the peer LDP ID."; 1707 } 1708 leaf label-space-id { 1709 type leafref { 1710 path "../../../../../../../ldp:peers/" 1711 + "ldp:peer[ldp:lsr-id=current()/../lsr-id]/" 1712 + "ldp:label-space-id"; 1713 } 1714 description 1715 "The Label Space ID of the peer, as a portion of the peer 1716 LDP ID."; 1717 } 1718 } // ldp-peer-ref-from-binding 1720 grouping ldp-peer-ref-from-interface { 1721 description 1722 "A relative reference to an LDP peer, by the LDP ID, which 1723 consists of the LSR ID and the Label Space ID."; 1725 container peer { 1726 description 1727 "Reference to an LDP peer, by the LDP ID, which consists of 1728 the LSR ID and the Label Space ID."; 1729 leaf lsr-id { 1730 type leafref { 1731 path "../../../../../../../../../ldp:peers/ldp:peer/" 1732 + "ldp:lsr-id"; 1733 } 1734 description 1735 "The LSR ID of the peer, as a portion of the peer LDP ID."; 1736 } 1737 leaf label-space-id { 1738 type leafref { 1739 path "../../../../../../../../../ldp:peers/" 1740 + "ldp:peer[ldp:lsr-id=current()/../lsr-id]/" 1741 + "ldp:label-space-id"; 1742 } 1743 description 1744 "The Label Space ID of the peer, as a portion of the peer 1745 LDP ID."; 1746 } 1747 } // peer 1748 } // ldp-peer-ref-from-interface 1750 grouping ldp-peer-ref-from-target { 1751 description 1752 "A relative reference to an LDP peer, by the LDP ID, which 1753 consists of the LSR ID and the Label Space ID."; 1755 container peer { 1756 description 1757 "Reference to an LDP peer, by the LDP ID, which consists of 1758 the LSR ID and the Label Space ID."; 1759 leaf lsr-id { 1760 type leafref { 1761 path "../../../../../../../../ldp:peers/ldp:peer/" 1762 + "ldp:lsr-id"; 1763 } 1764 description 1765 "The LSR ID of the peer, as a portion of the peer LDP ID."; 1766 } 1767 leaf label-space-id { 1768 type leafref { 1769 path "../../../../../../../../ldp:peers/" 1770 + "ldp:peer[ldp:lsr-id=current()/../lsr-id]/" 1771 + "ldp:label-space-id"; 1772 } 1773 description 1774 "The Label Space ID of the peer, as a portion of the peer 1775 LDP ID."; 1776 } 1777 } // peer 1778 } // ldp-peer-ref-from-target 1780 grouping peer-attributes { 1781 description 1782 "Peer configuration attributes, used in the per-peer setting 1783 can in the all-peer setting."; 1785 leaf session-ka-holdtime { 1786 type uint16 { 1787 range 45..3600; 1788 } 1789 units seconds; 1790 description 1791 "The time interval after which an inactive LDP session 1792 terminates and the corresponding TCP session closes. 1793 Inactivity is defined as not receiving LDP packets from the 1794 peer. 1795 This leaf may be configured at the per-peer level or the 1796 global level, with precedence given to the value at the 1797 per-peer level. If the leaf is not configured at either 1798 level, the default value at the global level is used."; 1799 } 1800 leaf session-ka-interval { 1801 type uint16 { 1802 range 15..1200; 1803 } 1804 units seconds; 1805 description 1806 "The interval between successive transmissions of keepalive 1807 packets. Keepalive packets are only sent in the absence of 1808 other LDP packets transmitted over the LDP session. 1809 This leaf may be configured at the per-peer level or the 1810 global level, with precedence given to the value at the 1811 per-peer level. If the leaf is not configured at either 1812 level, the default value at the global level is used."; 1813 } 1814 } // peer-attributes 1816 grouping peer-authentication { 1817 description 1818 "Peer authentication container, used in the per-peer setting 1819 can in the all-peer setting."; 1821 container authentication { 1822 description 1823 "Containing authentication information."; 1824 choice authentication-type { 1825 description 1826 "Choice of authentication."; 1827 case password { 1828 leaf key { 1829 type string; 1830 description 1831 "This leaf specifies the authentication key. The length 1832 of the key may be dependent on the cryptographic 1833 algorithm."; 1834 } 1835 leaf crypto-algorithm { 1836 type identityref { 1837 base key-chain:crypto-algorithm; 1838 } 1839 description 1840 "Cryptographic algorithm associated with key."; 1841 } 1842 } 1843 } 1844 } 1845 } // peer-authentication 1847 grouping peer-state-derived { 1848 description 1849 "The peer state information derived from the LDP protocol 1850 operations."; 1852 container label-advertisement-mode { 1853 config false; 1854 description "Label advertisement mode state."; 1855 leaf local { 1856 type label-adv-mode; 1857 description 1858 "Local Label Advertisement Mode."; 1859 } 1860 leaf peer { 1861 type label-adv-mode; 1862 description 1863 "Peer Label Advertisement Mode."; 1864 } 1865 leaf negotiated { 1866 type label-adv-mode; 1867 description 1868 "Negotiated Label Advertisement Mode."; 1869 } 1871 } 1872 leaf next-keep-alive { 1873 type uint16; 1874 units seconds; 1875 config false; 1876 description 1877 "Time duration from now until sending the next KeepAlive 1878 message."; 1879 } 1881 container received-peer-state { 1882 config false; 1883 description 1884 "Operational state information learned from the peer."; 1886 uses graceful-restart-attributes-per-peer; 1888 container capability { 1889 description "Peer capability information."; 1890 container end-of-lib { 1891 description 1892 "Peer's end-of-lib capability."; 1893 leaf enabled { 1894 type boolean; 1895 description 1896 "'true' if peer's end-of-lib capability is enabled."; 1897 } 1898 } 1899 container typed-wildcard-fec { 1900 description 1901 "Peer's typed-wildcard-fec capability."; 1902 leaf enabled { 1903 type boolean; 1904 description 1905 "'true' if peer's typed-wildcard-fec capability is 1906 enabled."; 1907 } 1908 } 1909 container upstream-label-assignment { 1910 description 1911 "Peer's upstream label assignment capability."; 1912 leaf enabled { 1913 type boolean; 1914 description 1915 "'true' if peer's upstream label assignment is 1916 enabled."; 1917 } 1918 } 1920 } // capability 1921 } // received-peer-state 1923 container session-holdtime { 1924 config false; 1925 description "Session holdtime state."; 1926 leaf peer { 1927 type uint16; 1928 units seconds; 1929 description "Peer holdtime."; 1930 } 1931 leaf negotiated { 1932 type uint16; 1933 units seconds; 1934 description "Negotiated holdtime."; 1935 } 1936 leaf remaining { 1937 type uint16; 1938 units seconds; 1939 description "Remaining holdtime."; 1940 } 1941 } // session-holdtime 1943 leaf session-state { 1944 type enumeration { 1945 enum non-existent { 1946 description "NON EXISTENT state. Transport disconnected."; 1947 } 1948 enum initialized { 1949 description "INITIALIZED state."; 1950 } 1951 enum openrec { 1952 description "OPENREC state."; 1953 } 1954 enum opensent { 1955 description "OPENSENT state."; 1956 } 1957 enum operational { 1958 description "OPERATIONAL state."; 1959 } 1960 } 1961 config false; 1962 description 1963 "Representing the operational status of the LDP session."; 1964 reference 1965 "RFC5036, Sec. 2.5.4."; 1966 } 1967 container tcp-connection { 1968 config false; 1969 description "TCP connection state."; 1970 leaf local-address { 1971 type inet:ip-address; 1972 description "Local address."; 1973 } 1974 leaf local-port { 1975 type inet:port-number; 1976 description "Local port number."; 1977 } 1978 leaf remote-address { 1979 type inet:ip-address; 1980 description "Remote address."; 1981 } 1982 leaf remote-port { 1983 type inet:port-number; 1984 description "Remote port number."; 1985 } 1986 } // tcp-connection 1988 leaf up-time { 1989 type rt-types:timeticks64; 1990 config false; 1991 description 1992 "The number of time ticks (hundredths of a second) since the 1993 the state of the session with the peer changed to 1994 OPERATIONAL."; 1995 } 1997 container statistics { 1998 config false; 1999 description 2000 "Statistics objects."; 2002 leaf discontinuity-time { 2003 type yang:date-and-time; 2004 mandatory true; 2005 description 2006 "The time on the most recent occasion at which any one or 2007 more of this interface's counters suffered a 2008 discontinuity. If no such discontinuities have occurred 2009 since the last re-initialization of the local management 2010 subsystem, then this node contains the time the local 2011 management subsystem re-initialized itself."; 2012 } 2014 container received { 2015 description "Inbound statistics."; 2016 uses statistics-peer-received-sent; 2017 } 2018 container sent { 2019 description "Outbound statistics."; 2020 uses statistics-peer-received-sent; 2021 } 2023 leaf total-addresses { 2024 type uint32; 2025 description 2026 "The number of learned addresses."; 2027 } 2028 leaf total-labels { 2029 type uint32; 2030 description 2031 "The number of learned labels."; 2032 } 2033 leaf total-fec-label-bindings { 2034 type uint32; 2035 description 2036 "The number of learned label-address bindings."; 2037 } 2038 } // statistics 2039 } // peer-state-derived 2041 grouping statistics-peer-received-sent { 2042 description 2043 "Inbound and outbound statistic counters."; 2044 leaf total-octets { 2045 type yang:counter64; 2046 description 2047 "The total number of octets sent or received."; 2048 } 2049 leaf total-messages { 2050 type yang:counter64; 2051 description 2052 "The number of messages sent or received."; 2053 } 2054 leaf address { 2055 type yang:counter64; 2056 description 2057 "The number of address messages sent or received."; 2058 } 2059 leaf address-withdraw { 2060 type yang:counter64; 2061 description 2062 "The number of address-withdraw messages sent or received."; 2064 } 2065 leaf initialization { 2066 type yang:counter64; 2067 description 2068 "The number of initialization messages sent or received."; 2069 } 2070 leaf keepalive { 2071 type yang:counter64; 2072 description 2073 "The number of keepalive messages sent or received."; 2074 } 2075 leaf label-abort-request { 2076 type yang:counter64; 2077 description 2078 "The number of label-abort-request messages sent or 2079 received."; 2080 } 2081 leaf label-mapping { 2082 type yang:counter64; 2083 description 2084 "The number of label-mapping messages sent or received."; 2085 } 2086 leaf label-release { 2087 type yang:counter64; 2088 description 2089 "The number of label-release messages sent or received."; 2090 } 2091 leaf label-request { 2092 type yang:counter64; 2093 description 2094 "The number of label-request messages sent or received."; 2095 } 2096 leaf label-withdraw { 2097 type yang:counter64; 2098 description 2099 "The number of label-withdraw messages sent or received."; 2100 } 2101 leaf notification { 2102 type yang:counter64; 2103 description 2104 "The number of notification messages sent or received."; 2105 } 2106 } // statistics-peer-received-sent 2108 /* 2109 * Configuration data and operational state data nodes 2110 */ 2112 augment "/rt:routing/rt:control-plane-protocols/" 2113 + "rt:control-plane-protocol" { 2114 when "derived-from-or-self(rt:type, 'ldp:mpls-ldp')" { 2115 description 2116 "This augmentation is only valid for a control-plane 2117 protocol instance of LDP (type 'mpls-ldp')."; 2118 } 2119 description 2120 "LDP augmentation to routing control-plane protocol 2121 configuration and state."; 2123 container mpls-ldp { 2124 must "not (../../rt:control-plane-protocol" 2125 + "[derived-from-or-self(rt:type, 'ldp:mpls-ldp')]" 2126 + "[rt:name!=current()/../rt:name])" 2127 { 2128 description "Only one LDP instance is allowed."; 2129 } 2131 description 2132 "Containing configuration and operational data for the LDP 2133 protocol."; 2135 container global { 2136 description 2137 "Global attributes for LDP."; 2139 container capability { 2140 description 2141 "Containing the LDP capability data. The container is 2142 used for augmentations."; 2143 reference 2144 "RFC5036: Sec. 1.5."; 2145 } 2147 container graceful-restart { 2148 description 2149 "Attributes for graceful restart."; 2150 leaf enabled { 2151 type boolean; 2152 default false; 2153 description 2154 "Enable or disable graceful restart."; 2155 } 2156 leaf reconnect-time { 2157 type uint16 { 2158 range 10..1800; 2159 } 2160 units seconds; 2161 default 120; 2162 description 2163 "Specifies the time interval that the remote LDP peer 2164 must wait for the local LDP peer to reconnect after 2165 the remote peer detects the LDP communication 2166 failure."; 2167 } 2168 leaf recovery-time { 2169 type uint16 { 2170 range 30..3600; 2171 } 2172 units seconds; 2173 default 120; 2174 description 2175 "Specifies the time interval, in seconds, that the 2176 remote LDP peer preserves its MPLS forwarding state 2177 after receiving the Initialization message from the 2178 restarted local LDP peer."; 2179 } 2180 leaf forwarding-holdtime { 2181 type uint16 { 2182 range 30..3600; 2183 } 2184 units seconds; 2185 default 180; 2186 description 2187 "Specifies the time interval, in seconds, before the 2188 termination of the recovery phase."; 2189 } 2190 } // graceful-restart 2192 leaf lsr-id { 2193 type rt-types:router-id; 2194 description 2195 "Specify the value to act as the LDP LSR ID. 2196 If this attribute is not specified, LDP uses the router 2197 ID as determined by the system."; 2198 } 2200 container address-families { 2201 description 2202 "Per address family confgiration and operational state. 2203 The address family can be either IPv4 or IPv6."; 2204 container ipv4 { 2205 presence 2206 "Present if IPv4 is enabled, unless the 'enabled' 2207 leaf is set to 'false'"; 2209 description 2210 "Containing data related to the IPv4 address family."; 2212 leaf enabled { 2213 type boolean; 2214 default true; 2215 description 2216 "'false' to disable the address family."; 2217 } 2219 leaf label-distribution-control-mode { 2220 type enumeration { 2221 enum independent { 2222 description 2223 "Independent label distribution control."; 2224 } 2225 enum ordered { 2226 description 2227 "Ordered label distribution control."; 2228 } 2229 } 2230 config false; 2231 description 2232 "Label distribution control mode."; 2233 reference 2234 "RFC5036: LDP Specification. Sec 2.6."; 2235 } 2237 // ipv4 bindings 2238 container bindings { 2239 config false; 2240 description 2241 "LDP address and label binding information."; 2242 list address { 2243 key "address"; 2244 description 2245 "List of address bindings learned by LDP."; 2246 leaf address { 2247 type inet:ipv4-address; 2248 description 2249 "The IPv4 address learned from an Address 2250 message received from or advertised to a peer."; 2251 } 2252 uses binding-address-state-attributes; 2253 } 2255 list fec-label { 2256 key "fec"; 2257 description 2258 "List of FEC-label bindings learned by LDP."; 2259 leaf fec { 2260 type inet:ipv4-prefix; 2261 description 2262 "The prefix FEC value in the FEC-label binding, 2263 learned in a Label Mapping message received from 2264 or advertised to a peer."; 2265 } 2266 uses binding-label-state-attributes; 2267 } 2268 } // bindings 2269 } // ipv4 2270 } // address-families 2271 } // global 2273 container discovery { 2274 description 2275 "Neighbor discovery configuration and operational state."; 2277 container interfaces { 2278 description 2279 "A list of interfaces for LDP Basic Discovery."; 2280 reference 2281 "RFC5036: LDP Specification. Sec 2.4.1."; 2283 uses basic-discovery-timers { 2284 refine "hello-holdtime" { 2285 default 15; 2286 } 2287 refine "hello-interval" { 2288 default 5; 2289 } 2290 } 2292 list interface { 2293 key "name"; 2294 description 2295 "List of LDP interfaces used for LDP Basic Discovery."; 2296 uses ldp-interface-ref; 2297 leaf next-hello { 2298 type uint16; 2299 units seconds; 2300 config false; 2301 description "Time to send the next Hello message."; 2302 } 2304 container address-families { 2305 description 2306 "Container for address families."; 2307 container ipv4 { 2308 presence 2309 "Present if IPv4 is enabled, unless the 'enabled' 2310 leaf is set to 'false'"; 2311 description 2312 "IPv4 address family."; 2314 leaf enabled { 2315 type boolean; 2316 default true; 2317 description 2318 "Set to false to disable the address family on 2319 the interface."; 2320 } 2322 container hello-adjacencies { 2323 config false; 2324 description 2325 "Containing a list of Hello adjacencies."; 2327 list hello-adjacency { 2328 key "adjacent-address"; 2329 config false; 2330 description "List of Hello adjacencies."; 2332 leaf adjacent-address { 2333 type inet:ipv4-address; 2334 description 2335 "Neighbor address of the Hello adjacency."; 2336 } 2338 uses adjacency-state-attributes; 2339 uses ldp-peer-ref-from-interface; 2340 } 2341 } 2342 } // ipv4 2343 } // address-families 2344 } // interface 2345 } // interfaces 2347 container targeted 2348 { 2349 description 2350 "A list of targeted neighbors for extended discovery."; 2352 leaf hello-holdtime { 2353 type uint16 { 2354 range 15..3600; 2355 } 2356 units seconds; 2357 default 45; 2358 description 2359 "The time interval for which LDP targeted Hello 2360 adjacency is maintained in the absence of targeted 2361 Hello messages from an LDP neighbor."; 2362 } 2363 leaf hello-interval { 2364 type uint16 { 2365 range 5..3600; 2366 } 2367 units seconds; 2368 default 15; 2369 description 2370 "The interval between consecutive LDP targeted Hello 2371 messages used in extended LDP discovery."; 2372 } 2374 container hello-accept { 2375 description 2376 "LDP policy to control the acceptance of extended 2377 neighbor discovery Hello messages."; 2379 leaf enabled { 2380 type boolean; 2381 default false; 2382 description 2383 "'true' to accept; 'false' to deny."; 2384 } 2385 } 2387 container address-families { 2388 description 2389 "Container for address families."; 2390 container ipv4 { 2391 presence 2392 "Present if IPv4 is enabled."; 2393 description 2394 "IPv4 address family."; 2396 container hello-adjacencies { 2397 config false; 2398 description 2399 "Containing a list of Hello adjacencies."; 2401 list hello-adjacency { 2402 key "local-address adjacent-address"; 2403 description "List of Hello adjacencies."; 2405 leaf local-address { 2406 type inet:ipv4-address; 2407 description 2408 "Local address of the Hello adjacency."; 2409 } 2410 leaf adjacent-address { 2411 type inet:ipv4-address; 2412 description 2413 "Neighbor address of the Hello adjacency."; 2414 } 2416 uses adjacency-state-attributes; 2417 uses ldp-peer-ref-from-target; 2418 } 2419 } 2421 list target { 2422 key "adjacent-address"; 2423 description 2424 "Targeted discovery params."; 2426 leaf adjacent-address { 2427 type inet:ipv4-address; 2428 description 2429 "Configures a remote LDP neighbor for the 2430 extended LDP discovery."; 2431 } 2433 leaf enabled { 2434 type boolean; 2435 default true; 2436 description 2437 "'true' to enable the target."; 2438 } 2439 leaf local-address { 2440 type inet:ipv4-address; 2441 description 2442 "The local address used as the source address to 2443 send targeted Hello messages. 2444 If the value is not specified, the 2445 transport-address is used as the source 2446 address."; 2447 } 2448 } // target 2450 } // ipv4 2451 } // address-families 2452 } // targeted 2453 } // discovery 2455 container peers { 2456 description 2457 "Peers configuration attributes."; 2459 uses peer-authentication; 2460 uses peer-attributes { 2461 refine session-ka-holdtime { 2462 default 180; 2463 } 2464 refine session-ka-interval { 2465 default 60; 2466 } 2467 } 2469 list peer { 2470 key "lsr-id label-space-id"; 2471 description 2472 "List of peers."; 2474 leaf lsr-id { 2475 type rt-types:router-id; 2476 description 2477 "The LSR ID of the peer, to identify the globally 2478 unique LSR. This is the first four octets of the LDP 2479 ID. This leaf is used together with the leaf 2480 'label-space-id' to form the LDP ID."; 2481 reference 2482 "RFC5036. Sec 2.2.2."; 2483 } 2484 leaf label-space-id { 2485 type uint16; 2486 description 2487 "The Label Space ID of the peer, to identify a specific 2488 label space within the LSR. This is the last two 2489 octets of the LDP ID. This leaf is used together with 2490 the leaf 'lsr-id' to form the LDP ID."; 2491 reference 2492 "RFC5036. Sec 2.2.2."; 2493 } 2495 uses peer-authentication; 2497 container address-families { 2498 description 2499 "Per-vrf per-af params."; 2500 container ipv4 { 2501 presence 2502 "Present if IPv4 is enabled."; 2503 description 2504 "IPv4 address family."; 2506 container hello-adjacencies { 2507 config false; 2508 description 2509 "Containing a list of Hello adjacencies."; 2511 list hello-adjacency { 2512 key "local-address adjacent-address"; 2513 description "List of Hello adjacencies."; 2515 leaf local-address { 2516 type inet:ipv4-address; 2517 description 2518 "Local address of the Hello adjacency."; 2519 } 2520 leaf adjacent-address { 2521 type inet:ipv4-address; 2522 description 2523 "Neighbor address of the Hello adjacency."; 2524 } 2526 uses adjacency-state-attributes; 2528 leaf interface { 2529 type if:interface-ref; 2530 description "Interface for this adjacency."; 2531 } 2532 } 2533 } 2534 } // ipv4 2535 } // address-families 2537 uses peer-state-derived; 2538 } // list peer 2539 } // peers 2540 } // container mpls-ldp 2541 } 2543 /* 2544 * RPCs 2545 */ 2547 rpc mpls-ldp-clear-peer { 2548 description 2549 "Clears the session to the peer."; 2550 input { 2551 uses ldp-peer-ref-absolute { 2552 description 2553 "The LDP peer to be cleared. If this is not provided 2554 then all peers are cleared. 2555 The peer is identified by its LDP ID, which consists of 2556 the LSR ID and the Label Space ID."; 2557 } 2558 } 2559 } 2561 rpc mpls-ldp-clear-hello-adjacency { 2562 description 2563 "Clears the hello adjacency"; 2564 input { 2565 container hello-adjacency { 2566 description 2567 "Link adjacency or targettted adjacency. If this is not 2568 provided then all Hello adjacencies are cleared"; 2569 leaf protocol-name { 2570 type leafref { 2571 path "/rt:routing/rt:control-plane-protocols/" 2572 + "rt:control-plane-protocol/rt:name"; 2573 } 2574 description 2575 "The name of the LDP protocol instance."; 2576 } 2577 choice hello-adjacency-type { 2578 description "Adjacency type."; 2579 case targeted { 2580 container targeted { 2581 presence "Present to clear targeted adjacencies."; 2582 description 2583 "Clear targeted adjacencies."; 2584 leaf target-address { 2585 type inet:ip-address; 2586 description 2587 "The target address. If this is not provided then 2588 all targeted adjacencies are cleared"; 2589 } 2590 } 2591 } 2592 case link { 2593 container link { 2594 presence "Present to clear link adjacencies."; 2595 description 2596 "Clear link adjacencies."; 2597 leaf next-hop-interface { 2598 type leafref { 2599 path "/rt:routing/rt:control-plane-protocols/" 2600 + "rt:control-plane-protocol/mpls-ldp/discovery/" 2601 + "interfaces/interface/name"; 2602 } 2603 description 2604 "Interface connecting to next-hop. If this is not 2605 provided then all link adjacencies are cleared."; 2606 } 2607 leaf next-hop-address { 2608 type inet:ip-address; 2609 must "../next-hop-interface" { 2610 description 2611 "Applicable when interface is specified."; 2612 } 2613 description 2614 "IP address of next-hop. If this is not provided 2615 then adjacencies to all next-hops on the given 2616 interface are cleared."; 2617 } 2618 } 2619 } 2620 } // hello-adjacency-type 2621 } // hello-adjacency 2622 } // input 2623 } // mpls-ldp-clear-hello-adjacency 2625 rpc mpls-ldp-clear-peer-statistics { 2626 description 2627 "Clears protocol statistics (e.g. sent and received 2628 counters)."; 2629 input { 2630 uses ldp-peer-ref-absolute { 2631 description 2632 "The LDP peer whose statistics are to be cleared. 2633 If this is not provided then all peers' statistics are 2634 cleared. 2635 The peer is identified by its LDP ID, which consists of 2636 the LSR ID and the Label Space ID."; 2637 } 2638 } 2639 } 2641 /* 2642 * Notifications 2643 */ 2644 notification mpls-ldp-peer-event { 2646 description 2647 "Notification event for a change of LDP peer operational 2648 status."; 2649 leaf event-type { 2650 type oper-status-event-type; 2651 description "Event type."; 2652 } 2653 container peer { 2654 description 2655 "Reference to an LDP peer, by the LDP ID, which consists of 2656 the LSR ID and the Label Space ID."; 2657 uses ldp-peer-ref-absolute; 2658 } 2659 } 2661 notification mpls-ldp-hello-adjacency-event { 2662 description 2663 "Notification event for a change of LDP adjacency operational 2664 status."; 2665 leaf event-type { 2666 type oper-status-event-type; 2667 description "Event type."; 2668 } 2669 leaf protocol-name { 2670 type leafref { 2671 path "/rt:routing/rt:control-plane-protocols/" 2672 + "rt:control-plane-protocol/rt:name"; 2673 } 2674 description 2675 "The name of the LDP protocol instance."; 2676 } 2677 choice hello-adjacency-type { 2678 description 2679 "Interface or targeted adjacency."; 2680 case targeted { 2681 container targeted { 2682 description 2683 "Targeted adjacency through LDP extended discovery."; 2684 leaf target-address { 2685 type inet:ip-address; 2686 description 2687 "The target adjacent address learned."; 2688 } 2689 } 2690 } 2691 case link { 2692 container link { 2693 description 2694 "Link adjacency through LDP basic discovery."; 2695 leaf next-hop-interface { 2696 type if:interface-ref; 2697 description 2698 "The interface connecting to the adjacent next hop."; 2699 } 2700 leaf next-hop-address { 2701 type inet:ip-address; 2702 must "../next-hop-interface" { 2703 description 2704 "Applicable when interface is specified."; 2706 } 2707 description 2708 "IP address of the next hop. This can be IPv4 or IPv6 2709 address."; 2710 } 2711 } 2712 } 2713 } // hello-adjacency-type 2714 } // mpls-ldp-hello-adjacency-event 2716 notification mpls-ldp-fec-event { 2717 description 2718 "Notification event for a change of FEC status."; 2719 leaf event-type { 2720 type oper-status-event-type; 2721 description "Event type."; 2722 } 2723 leaf protocol-name { 2724 type leafref { 2725 path "/rt:routing/rt:control-plane-protocols/" 2726 + "rt:control-plane-protocol/rt:name"; 2727 } 2728 description 2729 "The name of the LDP protocol instance."; 2730 } 2731 leaf fec { 2732 type inet:ip-prefix; 2733 description 2734 "The address prefix element of the FEC whose status 2735 has changed."; 2736 } 2737 } 2738 } 2739 2741 Figure 10: LDP base module 2743 9.2. Extended 2745 This YANG module imports types defined in [RFC6991], [RFC8349], 2746 [RFC8177], and [RFC8343]. 2748 file "ietf-mpls-ldp-extended@2020-02-25.yang" 2750 // RFC Editor: replace the above date 2020-02-25 with the date of 2751 // publication and remove this note. 2753 module ietf-mpls-ldp-extended { 2754 yang-version 1.1; 2756 namespace "urn:ietf:params:xml:ns:yang:ietf-mpls-ldp-extended"; 2757 prefix "ldp-ext"; 2759 import ietf-inet-types { 2760 prefix "inet"; 2761 reference "RFC 6991: Common YANG Data Types"; 2762 } 2764 import ietf-routing { 2765 prefix "rt"; 2766 reference 2767 "RFC 8349: A YANG Data Model for Routing Management (NMDA 2768 version)"; 2769 } 2771 import ietf-key-chain { 2772 prefix "key-chain"; 2773 reference "RFC 8177: YANG Data Model for Key Chains"; 2774 } 2776 import ietf-mpls-ldp { 2777 prefix "ldp"; 2778 reference "RFC XXXX: YANG Data Model for MPLS LDP"; 2779 // RFC Editor: replace XXXX with actual RFC number and remove 2780 // this note 2781 } 2782 import ietf-interfaces { 2783 prefix "if"; 2784 reference "RFC 8343: A YANG Data Model for Interface Management"; 2785 } 2787 import ietf-routing-policy { 2788 prefix rt-pol; 2789 reference 2790 "I-D.ietf-rtgwg-policy-model: A YANG Data Model for Routing 2791 Policy Management"; 2792 } 2794 organization 2795 "IETF MPLS Working Group"; 2796 contact 2797 "WG Web: 2798 WG List: 2800 Editor: Kamran Raza 2801 2803 Editor: Rajiv Asati 2804 2806 Editor: Xufeng Liu 2807 2809 Editor: Santosh Esale 2810 2812 Editor: Xia Chen 2813 2815 Editor: Himanshu Shah 2816 "; 2818 description 2819 "This YANG module defines the extended components for the 2820 management of Multi-Protocol Label Switching (MPLS) Label 2821 Distribution Protocol (LDP). It is also the model to 2822 be augmented for extended Multipoint LDP (mLDP). 2824 Copyright (c) 2020 IETF Trust and the persons identified as 2825 authors of the code. All rights reserved. 2827 Redistribution and use in source and binary forms, with or 2828 without modification, is permitted pursuant to, and subject to 2829 the license terms contained in, the Simplified BSD License set 2830 forth in Section 4.c of the IETF Trust's Legal Provisions 2831 Relating to IETF Documents 2832 (http://trustee.ietf.org/license-info). 2834 This version of this YANG module is part of RFC XXXX; see the 2835 RFC itself for full legal notices."; 2837 // RFC Editor: replace XXXX with actual RFC number and remove 2838 // this note 2840 revision 2020-02-25 { 2841 description 2842 "Initial revision."; 2843 reference 2844 "RFC XXXX: YANG Data Model for MPLS LDP."; 2846 // RFC Editor: replace XXXX with actual RFC number and remove 2847 // this note 2848 } 2850 /* 2851 * Features 2852 */ 2853 feature capability-end-of-lib { 2854 description 2855 "This feature indicates that the system allows to configure 2856 LDP end-of-lib capability."; 2857 } 2859 feature capability-typed-wildcard-fec { 2860 description 2861 "This feature indicates that the system allows to configure 2862 LDP typed-wildcard-fec capability."; 2863 } 2865 feature capability-upstream-label-assignment { 2866 description 2867 "This feature indicates that the system allows to configure 2868 LDP upstream label assignment capability."; 2869 } 2871 feature forwarding-nexthop-config { 2872 description 2873 "This feature indicates that the system allows to configure 2874 forwarding nexthop on interfaces."; 2875 } 2877 feature graceful-restart-helper-mode { 2878 description 2879 "This feature indicates that the system supports graceful 2880 restart helper mode. We call an LSR to be operating in GR 2881 helper mode when it advertises 0 as its FT Reconnect Timeout 2882 in the FT Session TLV. 2883 Please refer RFC3478 section 2 for details."; 2884 } 2886 feature key-chain { 2887 description 2888 "This feature indicates that the system supports keychain for 2889 authentication."; 2890 } 2892 feature peers-dual-stack-transport-preference { 2893 description 2894 "This feature indicates that the system allows to configure 2895 the transport connection preference in a dual-stack setup 2896 for peers."; 2897 } 2899 feature per-interface-timer-config { 2900 description 2901 "This feature indicates that the system allows to configure 2902 interface Hello timers at the per-interface level."; 2903 } 2905 feature per-peer-admin-down { 2906 description 2907 "This feature indicates that the system allows to 2908 administratively disable a peer."; 2909 } 2911 feature per-peer-graceful-restart-config { 2912 description 2913 "This feature indicates that the system allows to configure 2914 graceful restart at the per-peer level."; 2915 } 2917 feature per-peer-session-attributes-config { 2918 description 2919 "This feature indicates that the system allows to configure 2920 session attributes at the per-peer level."; 2921 } 2923 feature policy-label-assignment-config { 2924 description 2925 "This feature indicates that the system allows to configure 2926 policies to assign labels according to certain prefixes."; 2927 } 2929 feature policy-ordered-label-config { 2930 description 2931 "This feature indicates that the system allows to configure 2932 ordered label policies."; 2933 } 2935 feature policy-targeted-discovery-config { 2936 description 2937 "This feature indicates that the system allows to configure 2938 policies to control the acceptance of targeted neighbor 2939 discovery Hello messages."; 2940 } 2942 feature session-downstream-on-demand-config { 2943 description 2944 "This feature indicates that the system allows to configure 2945 session downstream-on-demand"; 2946 } 2948 /* 2949 * Typedefs 2950 */ 2951 typedef neighbor-list-ref { 2952 type leafref { 2953 path "/rt-pol:routing-policy/rt-pol:defined-sets/" 2954 + "rt-pol:neighbor-sets/rt-pol:neighbor-set/rt-pol:name"; 2955 } 2956 description 2957 "A type for a reference to a neighbor address list. 2958 The string value is the name identifier for uniquely 2959 identifying the referenced address list, which contains a list 2960 of addresses that a routing policy can applied."; 2961 reference 2962 "I-D.ietf-rtgwg-policy-model: A YANG Data Model for Routing 2963 Policy Management"; 2964 } 2966 typedef prefix-list-ref { 2967 type leafref { 2968 path "/rt-pol:routing-policy/rt-pol:defined-sets/" 2969 + "rt-pol:prefix-sets/rt-pol:prefix-set/rt-pol:name"; 2970 } 2971 description 2972 "A type for a reference to a prefix list. 2973 The string value is the name identifier for uniquely 2974 identifying the referenced prefix set, which contains a list 2975 of prefixes that a routing policy can applied."; 2976 reference 2977 "I-D.ietf-rtgwg-policy-model: A YANG Data Model for Routing 2978 Policy Management"; 2979 } 2981 typedef peer-list-ref { 2982 type leafref { 2983 path "/rt-pol:routing-policy/rt-pol:defined-sets/" 2984 + "rt-pol:neighbor-sets/rt-pol:neighbor-set/rt-pol:name"; 2985 } 2986 description 2987 "A type for a reference to a peer address list. 2988 The string value is the name identifier for uniquely 2989 identifying the referenced address list, which contains a list 2990 of addresses that a routing policy can applied."; 2991 reference 2992 "I-D.ietf-rtgwg-policy-model: A YANG Data Model for Routing 2993 Policy Management"; 2994 } 2996 /* 2997 * Identities 2998 */ 3000 /* 3001 * Groupings 3002 */ 3003 grouping address-family-ipv4-augment { 3004 description "Augmentation to address family IPv4."; 3006 uses policy-container; 3008 leaf transport-address { 3009 type inet:ipv4-address; 3010 description 3011 "The transport address advertised in LDP Hello messages. 3012 If this value is not specified, the LDP LSR ID is used as 3013 the transport address."; 3014 reference 3015 "RFC5036. Sec. 3.5.2."; 3016 } 3017 } 3019 grouping authentication-keychain-augment { 3020 description "Augmentation to authentication to add keychain."; 3021 leaf key-chain { 3022 type key-chain:key-chain-ref; 3023 description 3024 "key-chain name. 3025 If not specified, no key chain is used."; 3026 } 3027 } 3029 grouping capability-augment { 3030 description "Augmentation to capability."; 3032 container end-of-lib { 3033 if-feature capability-end-of-lib; 3034 description 3035 "Configure end-of-lib capability."; 3036 leaf enabled { 3037 type boolean; 3038 default false; 3039 description 3040 "'true' to enable end-of-lib capability."; 3041 } 3042 } 3043 container typed-wildcard-fec { 3044 if-feature capability-typed-wildcard-fec; 3045 description 3046 "Configure typed-wildcard-fec capability."; 3047 leaf enabled { 3048 type boolean; 3049 default false; 3050 description 3051 "'true' to enable typed-wildcard-fec capability."; 3052 } 3053 } 3054 container upstream-label-assignment { 3055 if-feature capability-upstream-label-assignment; 3056 description 3057 "Configure upstream label assignment capability."; 3058 leaf enabled { 3059 type boolean; 3060 default false; 3061 description 3062 "'true' to enable upstream label assignment."; 3063 } 3064 } 3065 } // capability-augment 3067 grouping global-augment { 3068 description "Augmentation to global attributes."; 3069 leaf igp-synchronization-delay { 3070 type uint16 { 3071 range "0 | 3..300"; 3072 } 3073 units seconds; 3074 default 0; 3075 description 3076 "Sets the interval that the LDP waits before notifying the 3077 Interior Gateway Protocol (IGP) that label exchange is 3078 completed so that IGP can start advertising the normal 3079 metric for the link. 3080 If the value is not specified, there is no delay."; 3081 } 3082 } 3084 grouping global-forwarding-nexthop-augment { 3085 description 3086 "Augmentation to global forwarding nexthop interfaces."; 3088 container forwarding-nexthop { 3089 if-feature forwarding-nexthop-config; 3090 description 3091 "Configuration for forwarding nexthop."; 3093 container interfaces { 3094 description 3095 "Containing a list of interfaces on which forwarding can be 3096 disabled."; 3098 list interface { 3099 key "name"; 3100 description 3101 "List of LDP interfaces on which forwarding can be 3102 disabled."; 3103 uses ldp:ldp-interface-ref; 3104 list address-family { 3105 key "afi"; 3106 description 3107 "Per-vrf per-af params."; 3108 leaf afi { 3109 type identityref { 3110 base rt:address-family; 3111 } 3112 description 3113 "Address family type value."; 3114 } 3115 leaf ldp-disable { 3116 type boolean; 3117 default false; 3118 description 3119 "'true' to disable LDP forwarding on the interface."; 3120 } 3121 } 3122 } // interface 3123 } // interfaces 3124 } // forwarding-nexthop 3125 } // global-forwarding-nexthop-augment 3127 grouping graceful-restart-augment { 3128 description "Augmentation to graceful restart."; 3130 leaf helper-enabled { 3131 if-feature graceful-restart-helper-mode; 3132 type boolean; 3133 default false; 3134 description 3135 "Enable or disable graceful restart helper mode."; 3136 } 3137 } 3139 grouping interface-address-family-ipv4-augment { 3140 description "Augmentation to interface address family IPv4."; 3142 leaf transport-address { 3143 type union { 3144 type enumeration { 3145 enum "use-global-transport-address" { 3146 description 3147 "Use the transport address set at the global level 3148 common for all interfaces for this address family."; 3149 } 3150 enum "use-interface-address" { 3151 description 3152 "Use interface address as the transport address."; 3153 } 3154 } 3155 type inet:ipv4-address; 3156 } 3157 default "use-global-transport-address"; 3158 description 3159 "IP address to be advertised as the LDP transport address."; 3160 } 3161 } 3163 grouping interface-address-family-ipv6-augment { 3164 description "Augmentation to interface address family IPv6."; 3165 leaf transport-address { 3166 type union { 3167 type enumeration { 3168 enum "use-global-transport-address" { 3169 description 3170 "Use the transport address set at the global level 3171 common for all interfaces for this address family."; 3172 } 3173 enum "use-interface-address" { 3174 description 3175 "Use interface address as the transport address."; 3176 } 3177 } 3178 type inet:ipv6-address; 3179 } 3180 default "use-global-transport-address"; 3181 description 3182 "IP address to be advertised as the LDP transport address."; 3183 } 3184 } 3186 grouping interface-augment { 3187 description "Augmentation to interface."; 3189 uses ldp:basic-discovery-timers { 3190 if-feature per-interface-timer-config; 3191 } 3192 leaf igp-synchronization-delay { 3193 if-feature per-interface-timer-config; 3194 type uint16 { 3195 range "0 | 3..300"; 3196 } 3197 units seconds; 3198 description 3199 "Sets the interval that the LDP waits before notifying the 3200 Interior Gateway Protocol (IGP) that label exchange is 3201 completed so that IGP can start advertising the normal 3202 metric for the link. 3203 This leaf may be configured at the per-interface level or 3204 the global level, with precedence given to the value at the 3205 per-interface level. If the leaf is not configured at 3206 either level, the default value at the global level is 3207 used."; 3208 } 3209 } 3211 grouping peer-af-policy-container { 3212 description 3213 "LDP policy attribute container under peer address-family."; 3214 container label-policy { 3215 description 3216 "Label policy attributes."; 3217 container advertise { 3218 description 3219 "Label advertising policies."; 3220 leaf prefix-list { 3221 type prefix-list-ref; 3222 description 3223 "Applies the prefix list to filter outgoing label 3224 advertisements. 3225 If the value is not specified, no prefix filter 3226 is applied."; 3227 } 3228 } 3229 container accept { 3230 description 3231 "Label advertisement acceptance policies."; 3232 leaf prefix-list { 3233 type prefix-list-ref; 3234 description 3235 "Applies the prefix list to filer incoming label 3236 advertisements. 3237 If the value is not specified, no prefix filter 3238 is applied."; 3239 } 3240 } 3241 } 3242 } // peer-af-policy-container 3244 grouping peer-augment { 3245 description "Augmentation to each peer list entry."; 3247 leaf admin-down { 3248 if-feature per-peer-admin-down; 3249 type boolean; 3250 default false; 3251 description 3252 "'true' to disable the peer."; 3253 } 3255 uses ldp:graceful-restart-attributes-per-peer { 3256 if-feature per-peer-graceful-restart-config; 3257 } 3259 uses ldp:peer-attributes { 3260 if-feature per-peer-session-attributes-config; 3262 } 3263 } 3265 grouping peers-augment { 3266 description "Augmentation to peers container."; 3268 container session-downstream-on-demand { 3269 if-feature session-downstream-on-demand-config; 3270 description 3271 "Session downstream-on-demand attributes."; 3272 leaf enabled { 3273 type boolean; 3274 default false; 3275 description 3276 "'true' if session downstream-on-demand is enabled."; 3277 } 3278 leaf peer-list { 3279 type peer-list-ref; 3280 description 3281 "The name of a peer ACL, to be applied to the 3282 downstream-on-demand sessions. 3283 If this value is not specified, no filter is applied to 3284 any downstream-on-demand sessions."; 3285 } 3286 } 3287 container dual-stack-transport-preference { 3288 if-feature peers-dual-stack-transport-preference; 3289 description 3290 "The settings of peers to establish TCP connection in a 3291 dual-stack setup."; 3292 leaf max-wait { 3293 type uint16 { 3294 range "0..60"; 3295 } 3296 default 30; 3297 description 3298 "The maximum wait time in seconds for preferred transport 3299 connection establishment. 0 indicates no preference."; 3300 } 3301 container prefer-ipv4 { 3302 presence 3303 "Present if IPv4 is prefered for transport connection 3304 establishment, subject to the 'peer-list' in this 3305 container."; 3306 description 3307 "Uses IPv4 as the prefered address family for transport 3308 connection establishment, subject to the 'peer-list' in 3309 this container. 3311 If this container is not present, as a default, IPv6 is 3312 the prefered address family for transport connection 3313 establishment."; 3314 leaf peer-list { 3315 type peer-list-ref; 3316 description 3317 "The name of a peer ACL, to be applied to the IPv4 3318 transport connections. 3319 If this value is not specified, no filter is applied, 3320 and the IPv4 is prefered for all peers."; 3321 } 3322 } 3323 } 3324 } // peers-augment 3326 grouping policy-container { 3327 description 3328 "LDP policy attributes."; 3329 container label-policy { 3330 description 3331 "Label policy attributes."; 3332 container advertise { 3333 description 3334 "Label advertising policies."; 3335 container egress-explicit-null { 3336 description 3337 "Enables an egress router to advertise an 3338 explicit null label (value 0) in place of an 3339 implicit null label (value 3) to the 3340 penultimate hop router."; 3341 leaf enabled { 3342 type boolean; 3343 default false; 3344 description 3345 "'true' to enable explicit null."; 3346 } 3347 } 3348 leaf prefix-list { 3349 type prefix-list-ref; 3350 description 3351 "Applies the prefix list to filter outgoing label 3352 advertisements. 3353 If the value is not specified, no prefix filter 3354 is applied."; 3355 } 3356 } 3357 container accept { 3358 description 3359 "Label advertisement acceptance policies."; 3360 leaf prefix-list { 3361 type prefix-list-ref; 3362 description 3363 "Applies the prefix list to filter incoming label 3364 advertisements. 3365 If the value is not specified, no prefix filter 3366 is applied."; 3367 } 3368 } 3369 container assign { 3370 if-feature policy-label-assignment-config; 3371 description 3372 "Label assignment policies"; 3373 container independent-mode { 3374 description 3375 "Independent label policy attributes."; 3376 leaf prefix-list { 3377 type prefix-list-ref; 3378 description 3379 "Assign labels according to certain prefixes. 3380 If the value is not specified, no prefix filter 3381 is applied (labels are assigned to all learned 3382 routes)."; 3384 } 3385 } 3386 container ordered-mode { 3387 if-feature policy-ordered-label-config; 3388 description 3389 "Ordered label policy attributes."; 3390 leaf egress-prefix-list { 3391 type prefix-list-ref; 3392 description 3393 "Assign labels according to certain prefixes for 3394 egress LSR."; 3395 } 3396 } 3397 } // assign 3398 } // label-policy 3399 } // policy-container 3401 /* 3402 * Configuration and state data nodes 3403 */ 3404 // Forwarding nexthop augmentation to the global tree 3405 augment "/rt:routing/rt:control-plane-protocols/" 3406 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global" { 3407 description "Forwarding nexthop augmentation."; 3408 uses global-forwarding-nexthop-augment; 3409 } 3411 // global/address-families/ipv6 3412 augment "/rt:routing/rt:control-plane-protocols/" 3413 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global/" 3414 + "ldp:address-families" { 3415 description "Global IPv6 augmentation."; 3417 container ipv6 { 3418 presence 3419 "Present if IPv6 is enabled, unless the 'enabled' 3420 leaf is set to 'false'"; 3421 description 3422 "Containing data related to the IPv6 address family."; 3424 leaf enabled { 3425 type boolean; 3426 default true; 3427 description 3428 "'false' to disable the address family."; 3429 } 3431 uses policy-container; 3433 leaf transport-address { 3434 type inet:ipv6-address; 3435 mandatory true; 3436 description 3437 "The transport address advertised in LDP Hello messages."; 3438 } 3440 leaf label-distribution-control-mode { 3441 type enumeration { 3442 enum independent { 3443 description 3444 "Independent label distribution control."; 3445 } 3446 enum ordered { 3447 description 3448 "Ordered label distribution control."; 3449 } 3450 } 3451 config false; 3452 description 3453 "Label distribution control mode."; 3454 reference 3455 "RFC5036: LDP Specification. Sec 2.6."; 3456 } 3458 // ipv6 bindings 3459 container bindings { 3460 config false; 3461 description 3462 "LDP address and label binding information."; 3463 list address { 3464 key "address"; 3465 description 3466 "List of address bindings learned by LDP."; 3467 leaf address { 3468 type inet:ipv6-address; 3469 description 3470 "The IPv6 address learned from an Address 3471 message received from or advertised to a peer."; 3472 } 3473 uses ldp:binding-address-state-attributes; 3474 } 3476 list fec-label { 3477 key "fec"; 3478 description 3479 "List of FEC-label bindings learned by LDP."; 3480 leaf fec { 3481 type inet:ipv6-prefix; 3482 description 3483 "The prefix FEC value in the FEC-label binding, 3484 learned in a Label Mapping message received from 3485 or advertised to a peer."; 3486 } 3487 uses ldp:binding-label-state-attributes; 3488 } 3489 } // bindings 3490 } // ipv6 3491 } 3493 // discovery/interfaces/interface/address-families/ipv6 3494 augment "/rt:routing/rt:control-plane-protocols/" 3495 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3496 + "ldp:interfaces/ldp:interface/" 3497 + "ldp:address-families" { 3498 description "Interface IPv6 augmentation."; 3500 container ipv6 { 3501 presence 3502 "Present if IPv6 is enabled, unless the 'enabled' 3503 leaf is set to 'false'"; 3504 description 3505 "IPv6 address family."; 3507 leaf enabled { 3508 type boolean; 3509 default true; 3510 description 3511 "'false' to disable the address family on the interface."; 3512 } 3514 container hello-adjacencies { 3515 config false; 3516 description 3517 "Containing a list of Hello adjacencies."; 3519 list hello-adjacency { 3520 key "adjacent-address"; 3521 config false; 3522 description "List of Hello adjacencies."; 3524 leaf adjacent-address { 3525 type inet:ipv6-address; 3526 description 3527 "Neighbor address of the Hello adjacency."; 3528 } 3530 uses ldp:adjacency-state-attributes; 3531 uses ldp:ldp-peer-ref-from-interface; 3532 } 3533 } 3534 } // ipv6 3535 } 3537 // discovery/targeted/address-families/ipv6 3538 augment "/rt:routing/rt:control-plane-protocols/" 3539 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3540 + "ldp:targeted/ldp:address-families" { 3541 description "Targeted discovery IPv6 augmentation."; 3543 container ipv6 { 3544 presence 3545 "Present if IPv6 is enabled."; 3546 description 3547 "IPv6 address family."; 3549 container hello-adjacencies { 3550 config false; 3551 description 3552 "Containing a list of Hello adjacencies."; 3554 list hello-adjacency { 3555 key "local-address adjacent-address"; 3556 config false; 3557 description "List of Hello adjacencies."; 3559 leaf local-address { 3560 type inet:ipv6-address; 3561 description 3562 "Local address of the Hello adjacency."; 3563 } 3564 leaf adjacent-address { 3565 type inet:ipv6-address; 3566 description 3567 "Neighbor address of the Hello adjacency."; 3568 } 3570 uses ldp:adjacency-state-attributes; 3571 uses ldp:ldp-peer-ref-from-target; 3572 } 3573 } 3575 list target { 3576 key "adjacent-address"; 3577 description 3578 "Targeted discovery params."; 3580 leaf adjacent-address { 3581 type inet:ipv6-address; 3582 description 3583 "Configures a remote LDP neighbor for the 3584 extended LDP discovery."; 3585 } 3586 leaf enabled { 3587 type boolean; 3588 default true; 3589 description 3590 "'true' to enable the target."; 3591 } 3592 leaf local-address { 3593 type inet:ipv6-address; 3594 description 3595 "The local address used as the source address to send 3596 targeted Hello messages. 3597 If the value is not specified, the transport-address 3598 is used as the source address."; 3600 } 3601 } // target 3602 } // ipv6 3603 } 3605 // /peers/peer/state/address-families/ipv6 3606 augment "/rt:routing/rt:control-plane-protocols/" 3607 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/" 3608 + "ldp:peer/ldp:address-families" { 3609 description "Peer state IPv6 augmentation."; 3611 container ipv6 { 3612 presence 3613 "Present if IPv6 is enabled."; 3614 description 3615 "IPv6 address family."; 3617 container hello-adjacencies { 3618 config false; 3619 description 3620 "Containing a list of Hello adjacencies."; 3622 list hello-adjacency { 3623 key "local-address adjacent-address"; 3624 description "List of Hello adjacencies."; 3626 leaf local-address { 3627 type inet:ipv6-address; 3628 description 3629 "Local address of the Hello adjacency."; 3630 } 3631 leaf adjacent-address { 3632 type inet:ipv6-address; 3633 description 3634 "Neighbor address of the Hello adjacency."; 3635 } 3637 uses ldp:adjacency-state-attributes; 3639 leaf interface { 3640 type if:interface-ref; 3641 description "Interface for this adjacency."; 3642 } 3643 } 3644 } 3645 } // ipv6 3646 } 3647 /* 3648 * Configuration data and operational state data nodes 3649 */ 3650 augment "/rt:routing/rt:control-plane-protocols/" 3651 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global" { 3652 description "Graceful restart augmentation."; 3653 uses global-augment; 3654 } 3656 augment "/rt:routing/rt:control-plane-protocols/" 3657 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global/" 3658 + "ldp:capability" { 3659 description "Capability augmentation."; 3660 uses capability-augment; 3661 } 3663 augment "/rt:routing/rt:control-plane-protocols/" 3664 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global/" 3665 + "ldp:graceful-restart" { 3666 description "Graceful restart augmentation."; 3667 uses graceful-restart-augment; 3668 } 3670 augment "/rt:routing/rt:control-plane-protocols/" 3671 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:global/" 3672 + "ldp:address-families/ldp:ipv4" { 3673 description "Address family IPv4 augmentation."; 3674 uses address-family-ipv4-augment; 3675 } 3677 augment "/rt:routing/rt:control-plane-protocols/" 3678 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3679 + "ldp:interfaces/ldp:interface" { 3680 description "Interface augmentation."; 3681 uses interface-augment; 3682 } 3684 augment "/rt:routing/rt:control-plane-protocols/" 3685 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3686 + "ldp:interfaces/ldp:interface/ldp:address-families/" 3687 + "ldp:ipv4" { 3688 description "Interface address family IPv4 augmentation."; 3689 uses interface-address-family-ipv4-augment; 3690 } 3692 augment "/rt:routing/rt:control-plane-protocols/" 3693 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3694 + "ldp:interfaces/ldp:interface/ldp:address-families/" 3695 + "ldp-ext:ipv6" { 3696 description "Interface address family IPv6 augmentation."; 3697 uses interface-address-family-ipv6-augment; 3698 } 3700 augment "/rt:routing/rt:control-plane-protocols/" 3701 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:discovery/" 3702 + "ldp:targeted/ldp:hello-accept" { 3703 description "Targeted discovery augmentation."; 3704 leaf neighbor-list { 3705 if-feature policy-targeted-discovery-config; 3706 type neighbor-list-ref; 3707 description 3708 "The name of a neighbor ACL, to accept Hello messages from 3709 LDP peers as permitted by the neighbor-list policy. 3710 If this value is not specified, targeted Hello messages from 3711 any source are accepted."; 3712 } 3713 } 3715 augment "/rt:routing/rt:control-plane-protocols/" 3716 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers" { 3717 description "Peers augmentation."; 3718 uses peers-augment; 3719 } 3721 augment "/rt:routing/rt:control-plane-protocols/" 3722 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/" 3723 + "ldp:authentication/ldp:authentication-type" { 3724 if-feature key-chain; 3725 description "Peers authentication augmentation."; 3726 case key-chain { 3727 uses authentication-keychain-augment; 3728 } 3729 } 3731 augment "/rt:routing/rt:control-plane-protocols/" 3732 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/ldp:peer" { 3733 description "Peer list entry augmentation."; 3734 uses peer-augment; 3735 } 3737 augment "/rt:routing/rt:control-plane-protocols/" 3738 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/ldp:peer/" 3739 + "ldp:authentication/ldp:authentication-type" { 3740 if-feature key-chain; 3741 description "Peer list entry authentication augmentation."; 3742 case key-chain { 3743 uses authentication-keychain-augment; 3744 } 3745 } 3747 augment "/rt:routing/rt:control-plane-protocols/" 3748 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/ldp:peer/" 3749 + "ldp:address-families/ldp:ipv4" { 3750 description 3751 "Peer list entry IPv4 augmentation."; 3752 uses peer-af-policy-container; 3753 } 3755 augment "/rt:routing/rt:control-plane-protocols/" 3756 + "rt:control-plane-protocol/ldp:mpls-ldp/ldp:peers/ldp:peer/" 3757 + "ldp:address-families/ldp-ext:ipv6" { 3758 description 3759 "Peer list entry IPv6 augmentation."; 3760 uses peer-af-policy-container; 3761 } 3762 } 3764 3766 Figure 11: LDP extended module 3768 10. Security Considerations 3770 This specification inherits the security considerations captured in 3771 [RFC5920] and the LDP protocol specification documents, namely base 3772 LDP [RFC5036], LDP IPv6 [RFC7552], LDP Capabilities [RFC5561], Typed 3773 Wildcard FEC [RFC5918], LDP End-of-LIB [RFC5919], and LDP Upstream 3774 Label Assignment [RFC6389]. 3776 10.1. YANG model 3778 The YANG modules specified in this document defines a schema for data 3779 that is designed to be accessed via network management protocols such 3780 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer 3781 is the secure transport layer, and the mandatory-to-implement secure 3782 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer 3783 is HTTPS, and the mandatory-to-implement secure transport is TLS 3784 [RFC8446]. 3786 The Network Configuration Access Control Model (NACM) [RFC8341] 3787 provides the means to restrict access for particular NETCONF or 3788 RESTCONF users to a preconfigured subset of all available NETCONF or 3789 RESTCONF protocol operations and content. 3791 10.1.1. Writable nodes 3793 There are a number of data nodes defined in this YANG module that are 3794 writable/creatable/deletable (i.e., config true, which is the 3795 default). These data nodes may be considered sensitive or vulnerable 3796 in some network environments. Write operations (e.g., edit-config) 3797 to these data nodes without proper protection can have a negative 3798 effect on network operations. 3800 For LDP, the ability to modify MPLS LDP configuration may allow the 3801 entire MPLS LDP domain to be compromised including forming LDP 3802 adjacencies and/or peer sessions with unauthorized routers to mount a 3803 massive Denial-of-Service (DoS) attack. In particular, folling are 3804 the subtrees and data nodes that are sensitivite and vulnerable: 3806 * /mpls-ldp/discovery/interfaces/interface: Adding LDP on any 3807 unprotected interface could allow an LDP hello adjacency to be 3808 formed with an unauthorized and malicious neighbor. Once an hello 3809 adjacency is formed, a peer session could progress with this 3810 neighbor. 3812 * /mpls-ldp/discovery/targeted/hello-accept: Allowing acceptance of 3813 targeted-hellos could open LDP to DoS attacks related to incoming 3814 targeted hellos from malicious sources. 3816 * /mpls-ldp/peers/authentication: Allowing a peer session 3817 establishement is typically controlled via LDP authentication 3818 where a proper and secure authentication password/key management 3819 is warranted. 3821 * /mpls-ldp/peers/peer/authentication: Same as above. 3823 10.1.2. Readable nodes 3825 Some of the readable data nodes in this YANG module may be considered 3826 sensitive or vulnerable in some network environments. It is thus 3827 important to control read access (e.g., via get, get-config, or 3828 notification) to these data nodes. These are the subtrees and data 3829 nodes and their sensitivity/vulnerability: 3831 The exposure of LDP databases (such as hello adjacencies, peers, 3832 address bindings, and fec-label bindings) beyond the scope of the LDP 3833 admin domain may be undesirable. The relevant subtrees and data 3834 nodes are as follows: 3836 * /mpls-ldp/global/address-families/ipv4/bindings/address 3838 * /mpls-ldp/global/address-families/ipv6/bindings/address 3840 * /mpls-ldp/global/address-families/ipv4/bindings/fec-label 3842 * /mpls-ldp/global/address-families/ipv6/bindings/fec-label 3844 * /mpls-ldp/discovery/interfaces/interface/address-families/ipv4/ 3845 hello-adjacencies 3847 * /mpls-ldp/discovery/interfaces/interface/address-families/ipv6/ 3848 hello-adjacencies 3850 * /mpls-ldp/discovery/targeted/address-families/ipv4/hello- 3851 adjacencies 3853 * /mpls-ldp/discovery/targeted/address-families/ipv6/hello- 3854 adjacencies 3856 * /mpls-ldp/peers 3858 The configuration for LDP peer authentication is supported via the 3859 specification of key-chain [RFC8040], or via direct specification of 3860 a key associated with a crypto algorithm (such as MD5). The relevant 3861 subtrees and data nodes are as follows: 3863 * /mpls-ldp/peers/authentication 3865 * /mpls-ldp/peers/peer/authentication 3867 The actual authentication key data (whether locally specified or part 3868 of a key-chain) is sensitive and needs to be kept secret from 3869 unauthorized parties. For key-chain based authentication, this model 3870 inherits the security considerations of [RFC8040] (that includes the 3871 considerations with respect to the local storage and handling of 3872 authentication keys). A similar procedure for storage and access to 3873 direct key is warranted. 3875 10.1.3. RPC operations 3877 Some of the RPC operations in this YANG module may be considered 3878 sensitive or vulnerable in some network environments. It is thus 3879 important to control access to these operations otherwise control 3880 plane flaps, network outages, and DoS attacks are possible. The RPC 3881 operations are: 3883 * mpls-ldp-clear-peer 3884 * mpls-ldp-clear-hello-adjacency 3886 10.1.4. Notifications 3888 The model describes several notifications. The implementations must 3889 rate-limit the generation of these notifications to avoid creating 3890 significant notification load and possible side effects on the system 3891 stability. 3893 11. IANA Considerations 3895 This document requests the registration of the following URIs in the 3896 IETF "XML registry" [RFC3688]: 3898 +----------------------------------------------------+----------+---+ 3899 | URI |Registrant|XML| 3900 +====================================================+==========+===+ 3901 | urn:ietf:params:xml:ns:yang:ietf-mpls-ldp | The IESG |N/A| 3902 +----------------------------------------------------+----------+---+ 3903 | urn:ietf:params:xml:ns:yang:ietf-mpls-ldp-extended | The IESG |N/A| 3904 +----------------------------------------------------+----------+---+ 3906 Table 1: URIs 3908 This document requests the registration of the following YANG modules 3909 in the "YANG Module Names" registry [RFC6020]: 3911 +----------------------+---------------------------+------+---------+ 3912 | Name | Namespace |Prefix|Reference| 3913 +======================+===========================+======+=========+ 3914 |ietf-mpls-ldp |urn:ietf:params:xml:ns:yang| ldp | This | 3915 | |:ietf-mpls-ldp | | document| 3916 +----------------------+---------------------------+------+---------+ 3917 |ietf-mpls-ldp-extended|urn:ietf:params:xml:ns:yang| ldp- | This | 3918 | |:ietf-mpls-ldp-extended | ext | document| 3919 +----------------------+---------------------------+------+---------+ 3921 Table 2: YANG Modules 3923 -- RFC Editor: Replace "this document" with the document RFC number 3924 at time of publication, and remove this note. 3926 12. Acknowledgments 3928 The authors would like to acknowledge Eddie Chami, Nagendra Kumar, 3929 Mannan Venkatesan, and Pavan Beeram for their contribution to this 3930 document. 3932 We also acknowledge Ladislav Lhotka, Jan Lindblad, Tom Petch, 3933 Yingzhen Qu, and Benjamin Kaduk for their detailed review of the 3934 model during WG and IESG. 3936 13. Contributors 3938 Danial Johari 3939 Cisco Systems 3940 Email: dajohari@cisco.com 3942 Loa Andersson 3943 Huawei Technologies 3944 Email: loa@pi.nu 3946 Jeff Tantsura 3947 Apstra 3948 Email: jefftant.ietf@gmail.com 3950 Matthew Bocci 3951 Nokia 3952 Email: matthew.bocci@nokia.com 3954 Reshad Rahman 3955 Cisco Systems 3956 Email: rrahman@cisco.com 3958 Stephane Litkowski 3959 Cisco Systems 3960 Email: slitkows@cisco.com 3962 14. Normative References 3964 [I-D.ietf-rtgwg-policy-model] 3965 Qu, Y., Tantsura, J., Lindem, A., and X. Liu, "A YANG Data 3966 Model for Routing Policy Management", Work in Progress, 3967 Internet-Draft, draft-ietf-rtgwg-policy-model-09, 4 March 3968 2020, . 3971 [RFC3478] Leelanivas, M., Rekhter, Y., and R. Aggarwal, "Graceful 3972 Restart Mechanism for Label Distribution Protocol", 3973 RFC 3478, DOI 10.17487/RFC3478, February 2003, 3974 . 3976 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 3977 DOI 10.17487/RFC3688, January 2004, 3978 . 3980 [RFC5036] Andersson, L., Ed., Minei, I., Ed., and B. Thomas, Ed., 3981 "LDP Specification", RFC 5036, DOI 10.17487/RFC5036, 3982 October 2007, . 3984 [RFC5331] Aggarwal, R., Rekhter, Y., and E. Rosen, "MPLS Upstream 3985 Label Assignment and Context-Specific Label Space", 3986 RFC 5331, DOI 10.17487/RFC5331, August 2008, 3987 . 3989 [RFC5443] Jork, M., Atlas, A., and L. Fang, "LDP IGP 3990 Synchronization", RFC 5443, DOI 10.17487/RFC5443, March 3991 2009, . 3993 [RFC5561] Thomas, B., Raza, K., Aggarwal, S., Aggarwal, R., and JL. 3994 Le Roux, "LDP Capabilities", RFC 5561, 3995 DOI 10.17487/RFC5561, July 2009, 3996 . 3998 [RFC5918] Asati, R., Minei, I., and B. Thomas, "Label Distribution 3999 Protocol (LDP) 'Typed Wildcard' Forward Equivalence Class 4000 (FEC)", RFC 5918, DOI 10.17487/RFC5918, August 2010, 4001 . 4003 [RFC5919] Asati, R., Mohapatra, P., Chen, E., and B. Thomas, 4004 "Signaling LDP Label Advertisement Completion", RFC 5919, 4005 DOI 10.17487/RFC5919, August 2010, 4006 . 4008 [RFC5920] Fang, L., Ed., "Security Framework for MPLS and GMPLS 4009 Networks", RFC 5920, DOI 10.17487/RFC5920, July 2010, 4010 . 4012 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 4013 the Network Configuration Protocol (NETCONF)", RFC 6020, 4014 DOI 10.17487/RFC6020, October 2010, 4015 . 4017 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 4018 and A. Bierman, Ed., "Network Configuration Protocol 4019 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 4020 . 4022 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 4023 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 4024 . 4026 [RFC6389] Aggarwal, R. and JL. Le Roux, "MPLS Upstream Label 4027 Assignment for LDP", RFC 6389, DOI 10.17487/RFC6389, 4028 November 2011, . 4030 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 4031 RFC 6991, DOI 10.17487/RFC6991, July 2013, 4032 . 4034 [RFC7277] Bjorklund, M., "A YANG Data Model for IP Management", 4035 RFC 7277, DOI 10.17487/RFC7277, June 2014, 4036 . 4038 [RFC7552] Asati, R., Pignataro, C., Raza, K., Manral, V., and R. 4039 Papneja, "Updates to LDP for IPv6", RFC 7552, 4040 DOI 10.17487/RFC7552, June 2015, 4041 . 4043 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 4044 RFC 7950, DOI 10.17487/RFC7950, August 2016, 4045 . 4047 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 4048 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 4049 . 4051 [RFC8177] Lindem, A., Ed., Qu, Y., Yeung, D., Chen, I., and J. 4052 Zhang, "YANG Data Model for Key Chains", RFC 8177, 4053 DOI 10.17487/RFC8177, June 2017, 4054 . 4056 [RFC8294] Liu, X., Qu, Y., Lindem, A., Hopps, C., and L. Berger, 4057 "Common YANG Data Types for the Routing Area", RFC 8294, 4058 DOI 10.17487/RFC8294, December 2017, 4059 . 4061 [RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration 4062 Access Control Model", STD 91, RFC 8341, 4063 DOI 10.17487/RFC8341, March 2018, 4064 . 4066 [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 4067 and R. Wilton, "Network Management Datastore Architecture 4068 (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, 4069 . 4071 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 4072 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 4073 . 4075 [RFC8344] Bjorklund, M., "A YANG Data Model for IP Management", 4076 RFC 8344, DOI 10.17487/RFC8344, March 2018, 4077 . 4079 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 4080 Routing Management (NMDA Version)", RFC 8349, 4081 DOI 10.17487/RFC8349, March 2018, 4082 . 4084 [RFC8407] Bierman, A., "Guidelines for Authors and Reviewers of 4085 Documents Containing YANG Data Models", BCP 216, RFC 8407, 4086 DOI 10.17487/RFC8407, October 2018, 4087 . 4089 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol 4090 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018, 4091 . 4093 [RFC8529] Berger, L., Hopps, C., Lindem, A., Bogdanovic, D., and X. 4094 Liu, "YANG Data Model for Network Instances", RFC 8529, 4095 DOI 10.17487/RFC8529, March 2019, 4096 . 4098 15. Informative References 4100 [I-D.ietf-mpls-mldp-yang] 4101 Raza, K., Liu, X., Esale, S., Andersson, L., Tantsura, J., 4102 and S. Krishnaswamy, "YANG Data Model for MPLS mLDP", Work 4103 in Progress, Internet-Draft, draft-ietf-mpls-mldp-yang-06, 4104 31 May 2019, . 4107 [RFC4364] Rosen, E. and Y. Rekhter, "BGP/MPLS IP Virtual Private 4108 Networks (VPNs)", RFC 4364, DOI 10.17487/RFC4364, February 4109 2006, . 4111 [RFC7307] Zhao, Q., Raza, K., Zhou, C., Fang, L., Li, L., and D. 4112 King, "LDP Extensions for Multi-Topology", RFC 7307, 4113 DOI 10.17487/RFC7307, July 2014, 4114 . 4116 [RFC7951] Lhotka, L., "JSON Encoding of Data Modeled with YANG", 4117 RFC 7951, DOI 10.17487/RFC7951, August 2016, 4118 . 4120 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 4121 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 4122 . 4124 Appendix A. Data Tree Example 4126 This section contains an example of an instance data tree in the JSON 4127 encoding [RFC7951], containing both configuration and state data. 4129 +---------------------+ 4130 | | 4131 | Router 203.0.113.1 | 4132 | | 4133 +----------+----------+ 4134 |eth1 4135 |2001:db8:0:1::1/64 4136 | 4137 | 4138 |2001:db8:0:1::2/64 4139 +----------+----------+ 4140 | | | 4141 | Another Router +---------| 2001:db8:0:2::/64 4142 | | | 4143 +---------------------+ 4145 Figure 12: Example topology 4147 The configuration instance data tree for Router 203.0.113.1 in the 4148 above figure could be as follows: 4150 { 4151 "ietf-interfaces:interfaces": { 4152 "interface": [ 4153 { 4154 "name": "eth1", 4155 "description": "An interface with LDP enabled.", 4156 "type": "iana-if-type:ethernetCsmacd", 4157 "ietf-ip:ipv6": { 4158 "address": [ 4159 { 4160 "ip": "2001:db8:0:1::1", 4161 "prefix-length": 64 4162 } 4163 ], 4164 "forwarding": true 4165 } 4166 } 4167 ] 4168 }, 4169 "ietf-routing:routing": { 4170 "router-id": "203.0.113.1", 4171 "control-plane-protocols": { 4172 "control-plane-protocol": [ 4173 { 4174 "type": "ietf-mpls-ldp:mpls-ldp", 4175 "name": "ldp-1", 4176 "ietf-mpls-ldp:mpls-ldp": { 4177 "global": { 4178 "address-families": { 4179 "ietf-mpls-ldp-extended:ipv6": { 4180 "enabled": true, 4181 "transport-address": "2001:db8:0:1::1" 4182 } 4183 } 4184 }, 4185 "discovery": { 4186 "interfaces": { 4187 "interface": [ 4188 { 4189 "name": "eth1", 4190 "address-families": { 4191 "ietf-mpls-ldp-extended:ipv6": { 4192 "enabled": true 4193 } 4194 } 4195 } 4196 ] 4197 } 4198 } 4199 } 4200 } 4201 ] 4202 } 4203 } 4204 } 4206 Figure 13: Example Configuration data in JSON 4208 The corresponding operational state data for Router 203.0.113.1 could 4209 be as follows: 4211 { 4212 "ietf-interfaces:interfaces": { 4213 "interface": [ 4214 { 4215 "name": "eth1", 4216 "description": "An interface with LDP enabled.", 4217 "type": "iana-if-type:ethernetCsmacd", 4218 "phys-address": "00:00:5e:00:53:01", 4219 "oper-status": "up", 4220 "statistics": { 4221 "discontinuity-time": "2018-09-10T15:16:27-05:00" 4222 }, 4223 "ietf-ip:ipv6": { 4224 "forwarding": true, 4225 "mtu": 1500, 4226 "address": [ 4227 { 4228 "ip": "2001:db8:0:1::1", 4229 "prefix-length": 64, 4230 "origin": "static", 4231 "status": "preferred" 4232 }, 4233 { 4234 "ip": "fe80::200:5eff:fe00:5301", 4235 "prefix-length": 64, 4236 "origin": "link-layer", 4237 "status": "preferred" 4238 } 4239 ], 4240 "neighbor": [ 4241 { 4242 "ip": "2001:db8:0:1::2", 4243 "link-layer-address": "00:00:5e:00:53:02", 4244 "origin": "dynamic", 4245 "is-router": [null], 4246 "state": "reachable" 4247 }, 4248 { 4249 "ip": "fe80::200:5eff:fe00:5302", 4250 "link-layer-address": "00:00:5e:00:53:02", 4251 "origin": "dynamic", 4252 "is-router": [null], 4253 "state": "reachable" 4254 } 4255 ] 4256 } 4257 } 4258 ] 4259 }, 4260 "ietf-routing:routing": { 4261 "router-id": "203.0.113.1", 4262 "interfaces": { 4263 "interface": [ 4264 "eth1" 4265 ] 4266 }, 4267 "control-plane-protocols": { 4268 "control-plane-protocol": [ 4269 { 4270 "type": "ietf-mpls-ldp:mpls-ldp", 4271 "name": "ldp-1", 4272 "ietf-mpls-ldp:mpls-ldp": { 4273 "global": { 4274 "address-families": { 4275 "ietf-mpls-ldp-extended:ipv6": { 4276 "enabled": true, 4277 "transport-address": "2001:db8:0:1::1" 4278 } 4279 } 4280 }, 4281 "discovery": { 4282 "interfaces": { 4283 "interface": [ 4284 { 4285 "name": "eth1", 4286 "address-families": { 4287 "ietf-mpls-ldp-extended:ipv6": { 4288 "enabled": true, 4289 "hello-adjacencies": { 4290 "hello-adjacency": [ 4291 { 4292 "adjacent-address": 4293 "fe80::200:5eff:fe00:5302", 4294 "flag": ["adjacency-flag-active"], 4295 "hello-holdtime": { 4296 "adjacent": 15, 4297 "negotiated": 15, 4298 "remaining": 9 4299 }, 4300 "next-hello": 3, 4301 "statistics": { 4302 "discontinuity-time": 4303 "2018-09-10T15:16:27-05:00" 4304 }, 4305 "peer": { 4306 "lsr-id": "203.0.113.2", 4307 "label-space-id": 0 4308 } 4309 } 4310 ] 4311 } 4312 } 4313 } 4314 } 4316 ] 4317 } 4318 }, 4319 "peers": { 4320 "peer": [ 4321 { 4322 "lsr-id": "203.0.113.2", 4323 "label-space-id": 0, 4324 "label-advertisement-mode": { 4325 "local": "downstream-unsolicited", 4326 "peer": "downstream-unsolicited", 4327 "negotiated": "downstream-unsolicited" 4328 }, 4329 "next-keep-alive": 5, 4330 "session-holdtime": { 4331 "peer": 180, 4332 "negotiated": 180, 4333 "remaining": 78 4334 }, 4335 "session-state": "operational", 4336 "tcp-connection": { 4337 "local-address": "fe80::200:5eff:fe00:5301", 4338 "local-port": 646, 4339 "remote-address": "fe80::200:5eff:fe00:5302", 4340 "remote-port": 646 4341 }, 4342 "up-time": 3438100, 4343 "statistics": { 4344 "discontinuity-time": "2018-09-10T15:16:27-05:00" 4345 } 4346 } 4347 ] 4348 } 4349 } 4350 } 4351 ] 4352 } 4353 } 4354 } 4356 Figure 14: Example Operational data in JSON 4358 Authors' Addresses 4360 Kamran Raza (editor) 4361 Cisco Systems 4362 Canada 4363 Email: skraza@cisco.com 4365 Rajiv Asati 4366 Cisco Systems 4367 United States of America 4368 Email: rajiva@cisco.com 4370 Xufeng Liu 4371 Volta Networks 4372 United States of America 4373 Email: xufeng.liu.ietf@gmail.com 4375 Santosh Esale 4376 Juniper Networks 4377 United States of America 4378 Email: sesale@juniper.net 4380 Xia Chen 4381 Huawei Technologies 4382 China 4383 Email: jescia.chenxia@huawei.com 4385 Himanshu Shah 4386 Ciena Corporation 4387 United States of America 4388 Email: hshah@ciena.com