idnits 2.17.1 draft-ietf-softwire-yang-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 262 has weird spacing: '...-prefix ine...' == Line 263 has weird spacing: '...-prefix ine...' == Line 309 has weird spacing: '...-change ine...' == Line 482 has weird spacing: '...-prefix ine...' == Line 483 has weird spacing: '...-prefix ine...' -- The document date (June 29, 2018) is 2128 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) == Outdated reference: A later version (-17) exists of draft-ietf-opsawg-nat-yang-15 Summary: 1 error (**), 0 flaws (~~), 7 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Softwire Working Group Y. Cui 3 Internet-Draft Tsinghua University 4 Intended status: Standards Track I. Farrer 5 Expires: December 31, 2018 Deutsche Telekom AG 6 M. Boucadair 7 Orange 8 Q. Sun 9 L. Sun 10 Tsinghua University 11 S. Zechlin 12 Deutsche Telekom AG 13 R. Asati 14 Cisco Systems, Inc. 15 June 29, 2018 17 YANG Modules for IPv4-in-IPv6 Address plus Port Softwires 18 draft-ietf-softwire-yang-06 20 Abstract 22 This document defines YANG modules for the configuration and 23 operation of IPv4-in-IPv6 softwire Border Relays and Customer 24 Premises Equipment for the Lightweight 4over6, MAP-E, and MAP-T 25 softwire mechanisms. 27 Editorial Note (To be removed by RFC Editor) 29 Please update these statements within this document with the RFC 30 number to be assigned to this document: 32 o "This version of this YANG module is part of RFC XXXX;" 34 o "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 35 Softwires"; 37 o "reference: RFC XXXX" 39 Please update the "revision" date of the YANG module. 41 Status of This Memo 43 This Internet-Draft is submitted in full conformance with the 44 provisions of BCP 78 and BCP 79. 46 Internet-Drafts are working documents of the Internet Engineering 47 Task Force (IETF). Note that other groups may also distribute 48 working documents as Internet-Drafts. The list of current Internet- 49 Drafts is at https://datatracker.ietf.org/drafts/current/. 51 Internet-Drafts are draft documents valid for a maximum of six months 52 and may be updated, replaced, or obsoleted by other documents at any 53 time. It is inappropriate to use Internet-Drafts as reference 54 material or to cite them other than as "work in progress." 56 This Internet-Draft will expire on December 31, 2018. 58 Copyright Notice 60 Copyright (c) 2018 IETF Trust and the persons identified as the 61 document authors. All rights reserved. 63 This document is subject to BCP 78 and the IETF Trust's Legal 64 Provisions Relating to IETF Documents 65 (https://trustee.ietf.org/license-info) in effect on the date of 66 publication of this document. Please review these documents 67 carefully, as they describe your rights and restrictions with respect 68 to this document. Code Components extracted from this document must 69 include Simplified BSD License text as described in Section 4.e of 70 the Trust Legal Provisions and are provided without warranty as 71 described in the Simplified BSD License. 73 Table of Contents 75 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 76 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 3 77 2. Overview of the Modules . . . . . . . . . . . . . . . . . . . 3 78 2.1. Overall Structure . . . . . . . . . . . . . . . . . . . . 3 79 2.2. Additional Components Configuration . . . . . . . . . . . 5 80 3. Softwire CE YANG Tree Diagram . . . . . . . . . . . . . . . . 5 81 3.1. CE Tree Diagram . . . . . . . . . . . . . . . . . . . . . 5 82 3.2. Softwire CE Tree Diagram Description . . . . . . . . . . 7 83 4. Softwire BR YANG Tree Diagram . . . . . . . . . . . . . . . . 8 84 4.1. BR Tree Diagram . . . . . . . . . . . . . . . . . . . . . 8 85 4.2. Softwire BR Tree Diagram Description . . . . . . . . . . 12 86 5. Softwire CE YANG Module . . . . . . . . . . . . . . . . . . . 13 87 6. BR Softwire YANG Module . . . . . . . . . . . . . . . . . . . 17 88 7. Common Softwire Element Groups YANG Module . . . . . . . . . 29 89 8. Security Considerations . . . . . . . . . . . . . . . . . . . 35 90 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 36 91 10. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 36 92 11. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 37 93 12. References . . . . . . . . . . . . . . . . . . . . . . . . . 37 94 12.1. Normative References . . . . . . . . . . . . . . . . . . 37 95 12.2. Informative References . . . . . . . . . . . . . . . . . 38 96 Appendix A. Configutation Examples . . . . . . . . . . . . . . . 39 97 A.1. Configuration Example for a lw4o6 BR Binding-Table . . . 39 98 A.2. Configuration Example for a MAP-E BR . . . . . . . . . . 40 99 A.3. lw4o6 CE Configuration Example . . . . . . . . . . . . . 42 100 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 45 102 1. Introduction 104 The IETF softwire working group has developed several IPv4-in-IPv6 105 softwire mechanisms to address various deployment contexts and 106 constraints. As a companion to the architectural specification 107 documents, this document focuses on the provisioning of address plus 108 port (A+P) softwire functional elements: Border Routers (BRs) and 109 Customer Premises Equipment (CEs). The softwire mechanisms covered 110 in this document are Lightweight 4 over 6 [RFC7596], MAP-E [RFC7597], 111 and MAP-T [RFC7599]. 113 This document focuses on A+P mechanisms; the reader can refer to 114 [I-D.ietf-softwire-dslite-yang] for a YANG module for DS-Lite 115 [RFC6333]. 117 This document defines YANG data modules [RFC7950] that can be used to 118 configure and manage A+P softwire elements using the NETCONF protocol 119 [RFC6241] for: 121 o Configuration 123 o Operational State 125 o Notifications 127 1.1. Terminology 129 The reader should be familiar with the concepts and terms defined in 130 [RFC7596], [RFC7597], [RFC7599], and the YANG data modelling language 131 defined in [RFC7950]. 133 The meaning of the symbols in tree diagrams is defined in [RFC8340]. 135 2. Overview of the Modules 137 2.1. Overall Structure 139 The document defines the following two YANG data modules for the 140 configuration and monitoring of softwire functional elements: 142 ietf-softwire-ce Provides configuration and monitoring for 143 softwire CE element. This module is defined as 144 augments to the interface YANG module 146 [RFC8343]. 148 ietf-softwire-br Provides configuration and monitoring for 149 softwire BR element. 151 In addition, the following module is defined: 153 ietf-softwire-common Contains groups of common functions that are 154 imported into the CE and BR modules. 156 This approach has been taken so that the various modules can be 157 easily extended to support additional softwire mechanisms, if 158 required. 160 Within the BR and CE modules, the YANG "feature" statement is used to 161 distinguish which of the different softwire mechanism(s) is relevant 162 for a specific element's configuration. For each module, a choice 163 statement 'ce-type' is included for either 'binding' or 'algorithm'. 164 'Binding' is used for configuring Lightweight 4over6, whereas 165 'algorithm' is used for configuring MAP-T or MAP-E. 167 In the 'algo-instances' container, a choice statement 'data-plane' is 168 included to specify MAP-E (encapsulation) or MAP-T (translation). 169 Table 1 shows how these choices are used to indicate the desired 170 softwire mechanism: 172 +--------------------+-----------+---------------+ 173 | S46 Mechanism | ce-type? | data-plane? | 174 +--------------------+-----------+---------------+ 175 | Lightweight 4over6 | binding | n/a | 176 | MAP-E | algorithm | encapsulation | 177 | MAP-T | algorithm | translation | 178 +--------------------+-----------+---------------+ 180 Table 1: Softwire Mechanism Choice Statement Enumeration 182 NETCONF notifications are also included. 184 Note: Earlier versions of this specification combined the softwire 185 mechanisms by their associated technologies rather than their 186 function in the architecture. As the document was revised, it 187 became apparent that dividing the modules by their role in the 188 architecture (CE or BR) was a better approach as this follows the 189 intended function and existing implementation approaches more 190 closely. 192 2.2. Additional Components Configuration 194 The softwire modules only aim to provide configuration relevant for 195 softwires. In order to fully provision a CE element, the following 196 may also be necessary: 198 o IPv6 forwarding and routing configuration, to enable CE to obtain 199 one or more IPv6 prefixes for softwire usage. A YANG module for 200 routing management is described in [RFC8349] 202 o IPv4 routing configuration, to add one or more IPv4 destination 203 prefix(es) reachable via the configured softwire. A YANG module 204 for routing management is described in [RFC8349] 206 o Stateful NAT44/NAPT management, to optionally specify a port set 207 (PSID) along with its length. A YANG module for NAT management is 208 described in [I-D.ietf-opsawg-nat-yang] 210 o Stateless NAT46 management, required by softwire translation based 211 mechanisms (i.e. the assignment of a Network-Specific Prefix to 212 use for IPv4/IPv6 translation). A YANG module for NAT management 213 is described in [I-D.ietf-opsawg-nat-yang] 215 As YANG modules for the above functions are already defined in other 216 documents, their functionality is not duplicated here and they should 217 be imported here, as needed. Appendix A.3 provides XML examples of 218 how these modules can be used together. 220 The CE must already have minimal IPv6 configuration in place so it is 221 reachable by the NETCONF client to obtain softwire configuration. If 222 additional IPv6 specific configuration is necessary, the YANG modules 223 defined in [RFC8344] and [RFC8349] may be used. 225 3. Softwire CE YANG Tree Diagram 227 3.1. CE Tree Diagram 229 The CE module provides configuration and monitoring for all of the 230 softwire mechanisms covered in this document (i.e., Lightweight 231 4over6, MAP-E, and MAP-T). 233 This module augments "ietf-interfaces", defined in [RFC8343] with an 234 entry for the softwire. This entry can be referenced to configure 235 IPv4 forwarding features for the element. 237 Figure 1 describes the tree structure of the softwire CE YANG module. 239 module: ietf-softwire-ce 240 augment /if:interfaces/if:interface: 241 +--rw softwire-payload-mtu? uint16 242 +--rw softwire-path-mru? uint16 243 +--rw (ce-type)? 244 +--:(binding) {binding}? 245 | +--rw binding-ipv6info? union 246 | +--rw br-ipv6-addr inet:ipv6-address 247 +--:(algorithm) {algorithm}? 248 +--rw algo-instances 249 +--rw algo-instance* [id] 250 +--rw id uint32 251 +--rw enable? boolean 252 +--rw algo-versioning 253 | +--rw version? uint64 254 | +--rw date? yang:date-and-time 255 +--rw name? string 256 +--rw (data-plane)? 257 | +--:(encapsulation) 258 | | +--rw br-ipv6-addr inet:ipv6-address 259 | +--:(translation) 260 | +--rw dmr-ipv6-prefix? inet:ipv6-prefix 261 +--rw ea-len uint8 262 +--rw rule-ipv6-prefix inet:ipv6-prefix 263 +--rw rule-ipv4-prefix inet:ipv4-prefix 264 +--rw forwarding boolean 265 augment /if:interfaces/if:interface/if:statistics: 266 +--ro sent-ipv4-packets? 267 | yang:zero-based-counter64 268 +--ro sent-ipv4-bytes? 269 | yang:zero-based-counter64 270 +--ro sent-ipv6-packets? 271 | yang:zero-based-counter64 272 +--ro sent-ipv6-bytes? 273 | yang:zero-based-counter64 274 +--ro rcvd-ipv4-packets? 275 | yang:zero-based-counter64 276 +--ro rcvd-ipv4-bytes? 277 | yang:zero-based-counter64 278 +--ro rcvd-ipv6-packets? 279 | yang:zero-based-counter64 280 +--ro rcvd-ipv6-bytes? 281 | yang:zero-based-counter64 282 +--ro dropped-ipv4-packets? 283 | yang:zero-based-counter64 284 +--ro dropped-ipv4-bytes? 285 | yang:zero-based-counter64 286 +--ro dropped-ipv6-packets? 287 | yang:zero-based-counter64 288 +--ro dropped-ipv6-bytes? 289 | yang:zero-based-counter64 290 +--ro dropped-ipv4-fragments? 291 | yang:zero-based-counter64 292 +--ro dropped-ipv4-fragment-bytes? 293 | yang:zero-based-counter64 294 +--ro ipv6-fragments-reassembled? 295 | yang:zero-based-counter64 296 +--ro ipv6-fragments-bytes-reassembled? 297 | yang:zero-based-counter64 298 +--ro out-icmpv4-error-packets? 299 | yang:zero-based-counter64 300 +--ro out-icmpv4-error-bytes? 301 | yang:zero-based-counter64 302 +--ro out-icmpv6-error-packets? 303 | yang:zero-based-counter64 304 +--ro out-icmpv6-error-bytes? 305 yang:zero-based-counter64 307 notifications: 308 +---n softwire-ce-event {binding}? 309 +--ro ce-binding-ipv6-addr-change inet:ipv6-address 311 Figure 1: Softwire CE YANG Tree Diagram 313 3.2. Softwire CE Tree Diagram Description 315 Additional information related to the operation of a CE element is 316 provided below: 318 o softwire-payload-mtu: optionally used to set the IPv4 MTU for the 319 softwire. Needed if the softwire implementation is unable to 320 correctly calculate the correct IPv4 Maximum Transit Unit (MTU) 321 size automatically. 323 o softwire-path-mru: optionally used to set the maximum IPv6 324 softwire packet size that can be received, including the 325 encapsulation/translation overhead. Needed if the softwire 326 implementation is unable to correctly calculate the correct IPv4 327 Maximum Receive Unit (MRU) size automatically. 329 o ce-type: provides a choice statement allowing the binding or 330 algorithmic softwire mechanisms to be selected. 332 Further details relevant to binding softwire elements are: 334 o binding-ipv6info: used to set the IPv6 binding prefix type to 335 identify which IPv6 address to use as the tunnel source. It can 336 be 'IPv6 prefix type' or ''IPv6 address type'. 338 o br-ipv6-addr: defines the IPv6 address of the remote BR. 340 Additional details relevant to some of the important algorithmic 341 elements are provided below: 343 o algo-versioning: optionally used to add an incremental version 344 number and/or timestamp to the algorithm. This can be used for 345 logging/data retention purposes. The version number is 346 incremented and a new timestamp value written whenever a change is 347 made to the algorithm or a new instance is created. 349 o forwarding: specifies whether the rule can be used as a Forward 350 Mapping Rule (FMR). If not set, this rule is a Basic Mapping Rule 351 (BMR) only and must not be used for forwarding. Refer to 352 Section 4.1 of [RFC7598]. 354 o ea-len: used to set the length of the Embedded-Address (EA), which 355 is defined in the mapping rule for a MAP domain. 357 o data-plane: provides a choice statement for either encapsulation 358 (MAP-E) or translation (MAP-T). 360 o br-ipv6-addr: defines the IPv6 address of the BR. This 361 information is valid for MAP-E. 363 o dmr-ipv6-prefix: defines the Default Mapping Rule (DMR) IPv6 364 prefix of the BR. This information is valid for MAP-T. 366 Additional information on the notification node is listed below: 368 o ce-binding-ipv6-addr-change: if the CE's binding IPv6 address 369 changes for any reason, the NETCONF client will be notified. 371 4. Softwire BR YANG Tree Diagram 373 4.1. BR Tree Diagram 375 The BR YANG module provides configuration and monitoring for all of 376 the softwire mechanisms covered in this document (i.e., Lightweight 377 4over6, MAP-E, and MAP-T). 379 Figure 2 provides the tree structure of this module. 381 module: ietf-softwire-br 382 +--rw br-instances 383 +--rw (br-type)? 384 +--:(binding) {binding}? 385 | +--rw binding {binding}? 386 | +--rw bind-instance* [id] 387 | +--rw binding-table-versioning 388 | | +--rw version? uint64 389 | | +--rw date? yang:date-and-time 390 | +--rw id uint32 391 | +--rw name? string 392 | +--rw softwire-num-max uint32 393 | +--rw softwires-payload-mtu uint16 394 | +--rw softwire-path-mru uint16 395 | +--rw enable-hairpinning? boolean 396 | +--rw binding-table 397 | | +--rw binding-entry* [binding-ipv6info] 398 | | +--rw binding-ipv6info union 399 | | +--rw binding-ipv4-addr? 400 | | | inet:ipv4-address 401 | | +--rw port-set 402 | | | +--rw psid-offset? uint8 403 | | | +--rw psid-len uint8 404 | | | +--rw psid uint16 405 | | +--rw br-ipv6-addr? 406 | | inet:ipv6-address 407 | +--rw icmp-policy 408 | | +--rw icmpv4-errors 409 | | | +--rw allow-incoming-icmpv4? boolean 410 | | | +--rw icmpv4-rate? uint32 411 | | | +--rw generate-icmpv4-errors? boolean 412 | | +--rw icmpv6-errors 413 | | +--rw generate-icmpv6-errors? boolean 414 | | +--rw icmpv6-rate? uint32 415 | +--ro traffic-stat 416 | +--ro discontinuity-time yang:date-and-time 417 | +--ro sent-ipv4-packets? 418 | | yang:zero-based-counter64 419 | +--ro sent-ipv4-bytes? 420 | | yang:zero-based-counter64 421 | +--ro sent-ipv6-packets? 422 | | yang:zero-based-counter64 423 | +--ro sent-ipv6-bytes? 424 | | yang:zero-based-counter64 425 | +--ro rcvd-ipv4-packets? 426 | | yang:zero-based-counter64 427 | +--ro rcvd-ipv4-bytes? 428 | | yang:zero-based-counter64 429 | +--ro rcvd-ipv6-packets? 430 | | yang:zero-based-counter64 431 | +--ro rcvd-ipv6-bytes? 432 | | yang:zero-based-counter64 433 | +--ro dropped-ipv4-packets? 434 | | yang:zero-based-counter64 435 | +--ro dropped-ipv4-bytes? 436 | | yang:zero-based-counter64 437 | +--ro dropped-ipv6-packets? 438 | | yang:zero-based-counter64 439 | +--ro dropped-ipv6-bytes? 440 | | yang:zero-based-counter64 441 | +--ro dropped-ipv4-fragments? 442 | | yang:zero-based-counter64 443 | +--ro dropped-ipv4-fragment-bytes? 444 | | yang:zero-based-counter64 445 | +--ro ipv6-fragments-reassembled? 446 | | yang:zero-based-counter64 447 | +--ro ipv6-fragments-bytes-reassembled? 448 | | yang:zero-based-counter64 449 | +--ro out-icmpv4-error-packets? 450 | | yang:zero-based-counter64 451 | +--ro out-icmpv4-error-bytes? 452 | | yang:zero-based-counter64 453 | +--ro out-icmpv6-error-packets? 454 | | yang:zero-based-counter64 455 | +--ro out-icmpv6-error-bytes? 456 | | yang:zero-based-counter64 457 | +--ro dropped-icmpv4-packets? 458 | | yang:zero-based-counter64 459 | +--ro dropped-icmpv4-bytes? 460 | | yang:zero-based-counter64 461 | +--ro hairpin-ipv4-packets? 462 | | yang:zero-based-counter64 463 | +--ro hairpin-ipv4-bytes? 464 | | yang:zero-based-counter64 465 | +--ro active-softwire-num? 466 | uint32 467 +--:(algorithm) {algorithm}? 468 +--rw algorithm {algorithm}? 469 +--rw algo-instance* [id] 470 +--rw id uint32 471 +--rw enable? boolean 472 +--rw algo-versioning 473 | +--rw version? uint64 474 | +--rw date? yang:date-and-time 475 +--rw name? string 476 +--rw (data-plane)? 477 | +--:(encapsulation) 478 | | +--rw br-ipv6-addr inet:ipv6-address 479 | +--:(translation) 480 | +--rw dmr-ipv6-prefix? inet:ipv6-prefix 481 +--rw ea-len uint8 482 +--rw rule-ipv6-prefix inet:ipv6-prefix 483 +--rw rule-ipv4-prefix inet:ipv4-prefix 484 +--rw forwarding boolean 485 +--rw port-set 486 | +--rw psid-offset? uint8 487 | +--rw psid-len uint8 488 | +--rw psid uint16 489 +--ro traffic-stat 490 +--ro discontinuity-time yang:date-and-time 491 +--ro sent-ipv4-packets? 492 | yang:zero-based-counter64 493 +--ro sent-ipv4-bytes? 494 | yang:zero-based-counter64 495 +--ro sent-ipv6-packets? 496 | yang:zero-based-counter64 497 +--ro sent-ipv6-bytes? 498 | yang:zero-based-counter64 499 +--ro rcvd-ipv4-packets? 500 | yang:zero-based-counter64 501 +--ro rcvd-ipv4-bytes? 502 | yang:zero-based-counter64 503 +--ro rcvd-ipv6-packets? 504 | yang:zero-based-counter64 505 +--ro rcvd-ipv6-bytes? 506 | yang:zero-based-counter64 507 +--ro dropped-ipv4-packets? 508 | yang:zero-based-counter64 509 +--ro dropped-ipv4-bytes? 510 | yang:zero-based-counter64 511 +--ro dropped-ipv6-packets? 512 | yang:zero-based-counter64 513 +--ro dropped-ipv6-bytes? 514 | yang:zero-based-counter64 515 +--ro dropped-ipv4-fragments? 516 | yang:zero-based-counter64 517 +--ro dropped-ipv4-fragment-bytes? 518 | yang:zero-based-counter64 519 +--ro ipv6-fragments-reassembled? 520 | yang:zero-based-counter64 521 +--ro ipv6-fragments-bytes-reassembled? 522 | yang:zero-based-counter64 523 +--ro out-icmpv4-error-packets? 524 | yang:zero-based-counter64 525 +--ro out-icmpv4-error-bytes? 526 | yang:zero-based-counter64 527 +--ro out-icmpv6-error-packets? 528 | yang:zero-based-counter64 529 +--ro out-icmpv6-error-bytes? 530 yang:zero-based-counter64 532 notifications: 533 +---n softwire-binding-instance-event {binding}? 534 | +--ro bind-id? 535 | | -> /br-instances/binding/bind-instance/id 536 | +--ro invalid-entry* leafref 537 | +--ro added-entry* inet:ipv6-address 538 | +--ro modified-entry* leafref 539 +---n softwire-algorithm-instance-event {algorithm}? 540 +--ro algo-id 541 | -> /br-instances/algorithm/algo-instance/id 542 +--ro invalid-entry-id* 543 | -> /br-instances/algorithm/algo-instance/id 544 +--ro added-entry* 545 | -> /br-instances/algorithm/algo-instance/id 546 +--ro modified-entry* 547 -> /br-instances/algorithm/algo-instance/id 549 Figure 2: Softwire BR YANG Tree 551 4.2. Softwire BR Tree Diagram Description 553 The descriptions for leaves which are common with the CE module are 554 provided in Section 3.2. Descriptions for additional elements are 555 provided below: 557 o binding-table-versioning: optionally used to add an incremental 558 version number and/or timestamp to the binding table. This can be 559 used for logging or data retention purposes. The version number 560 is incremented and a new timestamp value written whenever a change 561 is made to the contents of the binding table or a new binding 562 table list is created. 564 o binding-entry: used to define the binding relationship between 565 3-tuples {lwB4's IPv6 address/prefix, the allocated IPv4 address, 566 restricted port-set}. For detail information, please refer to 567 [RFC7596]. 569 o softwire-num-max: used to set the maximum number of softwire 570 binding rules that can be created on the lw4o6 element 571 simultaneously. 573 o active-softwire-num: holds the number of softwires currently 574 provisioned on the element. 576 Additional information on some of the important notification nodes is 577 listed below: 579 o invalid-entry, added-entry, modified-entry: used to notify the 580 NETCONF client that a specific binding entry or MAP rule has 581 expired, been invalidated, added, or modified. 583 5. Softwire CE YANG Module 585 This module imports typedefs from [RFC6991]. 587 file "ietf-softwire-ce@2018-03-16.yang" 589 module ietf-softwire-ce { 590 yang-version 1.1; 591 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-ce"; 592 prefix "softwire-ce"; 594 import ietf-inet-types {prefix inet; } 595 import ietf-interfaces {prefix if; } 596 import iana-if-type {prefix ianaift; } 597 import ietf-softwire-common {prefix softwire-common; } 599 organization 600 "IETF Softwire Working Group"; 602 contact 603 "WG Web: 604 WG List: 606 Qi Sun 607 Linhui Sun 608 Yong Cui 609 Ian Farrer 610 Sladjana Zoric 611 Mohamed Boucadair 612 Rajiv 613 "; 615 description 616 "This document defines a YANG data module for the configuration and 617 management of A+P Softwire Customer Premises Equipment (CEs). It 618 covers Lightweight 4over6, MAP-E, and MAP-T mechanisms. 619 Copyright (c) 2018 IETF Trust and the persons identified 620 as authors of the code. All rights reserved. 621 This version of this YANG module is part of RFC XXX; see the RFC 622 itself for full legal notices."; 624 revision 2018-03-16 { 625 description 626 "Initial revision."; 627 reference 628 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 629 Softwires"; 630 } 632 /* 633 * Features 634 */ 636 feature binding { 637 description 638 "Binding is used for configuring the Lightweight 4over6 mechanism. 640 Binding based softwire mechanisms are IPv4-over-IPv6 tunnelling 641 transition mechanisms specifically intended for complete 642 independence between the IPv6 subnet prefix (and IPv6 address) 643 and IPv4 address, with or without IPv4 address sharing. 645 This is accomplished by maintaining state for each softwire 646 (per-subscriber state) in the central Border Relay (BR) and using 647 a hub-and-spoke forwarding architecture. In order to delegate the 648 NAPT function and achieve IPv4 address sharing, port-restricted 649 IPv4 addresses needs to be allocated to CEs. 651 This feature indicates that the instance functions as a binding 652 based softwire instance."; 654 reference 655 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack Lite 656 Architecture 657 RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 658 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 659 } 661 feature algorithm { 662 description 663 "MAP-E is an IPv6 transition mechanism for transporting IPv4 664 packets across an IPv6 network using IP encapsulation. MAP-E 665 allows for a reduction of the amount of centralized state using 666 rules to express IPv4/IPv6 address mappings. This introduces an 667 algorithmic relationship between the IPv6 subnet and IPv4 address. 669 MAP-T is an IPv6 transition mechanism for transporting IPv4 670 packets across an IPv6 network using IP translation. It leverages 671 a double stateless NAT64 based solution as well as the stateless 672 algorithmic address & transport layer port mapping algorithm 673 defined for MAP-E. 675 This feature indicates that the instance functions as a MAP-E or 676 MAP-T instance."; 678 reference 679 "RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 680 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 681 } 683 // Binding Entry 684 grouping binding-entry { 685 description 686 "The binding BR maintains an address binding table that 687 contains the binding between the CE's IPv6 address, 688 the allocated IPv4 address and restricted port-set."; 690 leaf binding-ipv6info { 692 type union { 693 type inet:ipv6-address; 694 type inet:ipv6-prefix; 695 } 697 description 698 "The IPv6 information for a binding entry. 700 When the IPv6 prefix type is used, 701 the IPv6 source address of the CE is constructed 702 according to the description in RFC7596. 704 If the IPv6 address type is used, the CE can use 705 any valid /128 address from a prefix assigned to 706 the CE."; 707 reference 708 "Section 5.1 of RFC7596."; 709 } 711 leaf br-ipv6-addr { 712 type inet:ipv6-address; 713 mandatory true; 714 description 715 "The IPv6 address for of the binding BR."; 716 } 717 } 719 // configuration and stateful parameters for softwire CE interface 720 augment "/if:interfaces/if:interface" { 721 when "if:type = 'ianaift:tunnel'"; 722 description "Softwire CE interface configuration"; 724 leaf softwire-payload-mtu { 725 type uint16; 726 units bytes; 727 description 728 "The payload IPv4 MTU for the Softwire tunnel."; 729 } 731 leaf softwire-path-mru { 732 type uint16; 733 units bytes; 734 description 735 "The path MRU for the softwire (payload + encapsulation 736 overhead)."; 737 } 739 choice ce-type { 740 description "Sets the softwire CE mechanism"; 742 case binding { 743 if-feature binding; 744 description "CE binding configuration"; 745 uses binding-entry; 746 } 748 case algorithm { 749 if-feature algorithm; 750 description "CE algorithm configuration"; 752 container algo-instances { 753 description 754 "Indicates that the instances supports the MAP-E and MAP-T 755 function. The instances advertise the MAP-E/MAP-T 756 feature through the capability exchange mechanism 757 when a NETCONF session is established."; 758 list algo-instance { 759 key "id"; 760 description 761 "MAP forwarding rule instance for 762 MAP-E/MAP-T"; 763 leaf id { 764 type uint32; 765 mandatory true; 766 description "Algorithm Instance ID"; 767 } 768 uses softwire-common:algorithm-instance; 769 } 770 } 771 } 772 } 773 } 775 augment "/if:interfaces/if:interface/if:statistics" { 776 when "../if:type = 'ianaift:tunnel'"; 777 description "Softwire CE interface statistics."; 778 uses softwire-common:traffic-stat; 779 } 781 /* 782 * Notifications 783 */ 785 notification softwire-ce-event { 786 if-feature binding; 787 description "CE notification"; 788 leaf ce-binding-ipv6-addr-change { 789 type inet:ipv6-address; 790 mandatory true; 791 description 792 "If the CE's binding IPv6 address changes for any reason, 793 it should notify the NETCONF client."; 794 } 795 } 796 } 797 799 6. BR Softwire YANG Module 801 This module imports typedefs from [RFC6991]. 803 file "ietf-softwire-br@2018-03-16.yang" 805 module ietf-softwire-br { 806 yang-version 1.1; 807 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-br"; 808 prefix "softwire-br"; 810 import ietf-inet-types {prefix inet; } 811 import ietf-yang-types {prefix yang; } 812 import ietf-softwire-common {prefix softwire-common; } 814 organization 815 "IETF Softwire Working Group"; 817 contact 818 "WG Web: 819 WG List: 821 Qi Sun 822 Linhui Sun 823 Yong Cui 824 Ian Farrer 825 Sladjana Zoric 826 Mohamed Boucadair 827 Rajiv 828 "; 830 description 831 "This document defines a YANG data module for the configuration and 832 management of A+P Softwire Border Routers. It covers Lightweight 833 4over6, MAP-E, and MAP-T mechanisms. 835 Copyright (c) 2018 IETF Trust and the persons identified 836 as authors of the code. All rights reserved. 837 This version of this YANG module is part of RFC XXX; see the RFC 838 itself for full legal notices."; 840 revision 2018-03-16 { 841 description 842 "Initial revision."; 843 reference 844 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 845 Softwires"; 846 } 848 /* 849 * Groupings 850 */ 852 grouping port-set { 853 description 854 "Describes a set of layer 4 port numbers. 856 This may be a simple port range, or use the PSID algorithm 857 to represent a range of transport layer ports which will 858 be used by a NAPT."; 860 leaf psid-offset { 861 type uint8 { 862 range 0..16; 863 } 864 description 865 "The number of offset bits. In Lightweight 4over6, 866 the default value is 0 for assigning one contiguous 867 port range. In MAP-E/T, the default value is 6, 868 which means the system ports (0-1023) are excluded by 869 default and the assigned port ranges are distributed across the 870 entire port space, depending on either psid-len or the 871 number of contiguous ports."; 872 } 874 leaf psid-len { 875 type uint8 { 876 range 0..15; 877 } 878 mandatory true; 879 description 880 "The length of PSID, representing the sharing 881 ratio for an IPv4 address. This, along with ea-len, can 882 be used to calculate the number of contiguous ports per 883 port range"; 884 } 886 leaf psid { 887 type uint16; 888 mandatory true; 889 description 890 "Port Set Identifier (PSID) value, which 891 identifies a set of ports algorithmically."; 892 } 893 } 895 grouping binding-entry { 896 description 897 "The binding BR maintains an address binding table that 898 contains the binding between the CE's IPv6 address, 899 the allocated IPv4 address and restricted port-set."; 900 leaf binding-ipv6info { 901 type union { 902 type inet:ipv6-address; 903 type inet:ipv6-prefix; 904 } 905 description 906 "The IPv6 information for a CE binding entry. 907 When the IPv6 prefix type is used, 908 the IPv6 source address of the CE is constructed 909 according to the description in RFC7596; 910 if the IPv6 address type is used, the CE can use 911 any valid /128 address from a prefix assigned to 912 the CE."; 914 reference 915 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack 916 Lite Architecture"; 917 } 918 leaf binding-ipv4-addr { 919 type inet:ipv4-address; 920 description 921 "The IPv4 address assigned to the binding CE, 922 which is used as the IPv4 external address 923 for binding CE local NAPT44."; 924 } 925 container port-set { 926 description 927 "For Lightweight 4over6, the default value 928 for offset should be 0, to configure one contiguous 929 port range."; 930 uses port-set { 931 refine "psid-offset" { 932 default "0"; 933 } 934 } 935 } 936 leaf br-ipv6-addr { 937 type inet:ipv6-address; 938 description 939 "The IPv6 address for binding BR."; 940 } 941 } 943 /* 944 * Features 945 */ 947 feature binding { 948 description 949 "Binding is used for configuring the Lightweight 4over6 mechanism. 951 Binding based softwire mechanisms are IPv4-over-IPv6 tunnelling 952 transition mechanisms specifically intended for complete 953 independence between the IPv6 subnet prefix (and IPv6 address) and 954 IPv4 address, with or without IPv4 address sharing. 956 This is accomplished by maintaining state for each softwire 957 (per-subscriber state) in the central Border Relay (BR) and using 958 a hub-and-spoke forwarding architecture. In order to delegate the 959 NAPT function and achieve IPv4 address sharing, port-restricted 960 IPv4 addresses needs to be allocated to CEs. 962 This feature indicates that the instance functions as a binding 963 based softwire instance."; 965 reference 966 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack Lite 967 Architecture 968 RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 969 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 970 } 972 feature algorithm { 973 description 974 "MAP-E is an IPv6 transition mechanism for transporting IPv4 975 packets across an IPv6 network using IP encapsulation. MAP-E 976 allows for a reduction of the amount of centralized state using 977 rules to express IPv4/IPv6 address mappings. This introduces an 978 algorithmic relationship between the IPv6 subnet and IPv4 address. 980 MAP-T is an IPv6 transition mechanism for transporting IPv4 981 packets across an IPv6 network using IP translation. It leverages 982 double stateless NAT64 based solution as well as the stateless 983 algorithmic address & transport layer port mapping algorithm 984 defined for MAP-E. 986 This feature indicates that the instance functions as a MAP-E or 987 MAP-T instance."; 989 reference 990 "RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 991 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 992 } 994 container br-instances { 995 description 996 "BR Instances"; 998 choice br-type { 999 description 1000 "Select binding or algorithmic BR functionality."; 1001 case binding { 1002 if-feature binding; 1003 container binding { 1004 if-feature binding; 1005 description 1006 "binding mechanism (binding table) configuration."; 1007 list bind-instance { 1008 key "id"; 1009 description 1010 "A set of binding BRs to be configured."; 1011 container binding-table-versioning { 1012 description "binding table's version"; 1013 leaf version{ 1014 type uint64; 1015 description "Incremental version number of the binding 1016 table"; 1017 } 1018 leaf date { 1019 type yang:date-and-time; 1020 description "Timestamp of the binding 1021 table"; 1022 } 1023 } 1024 leaf id { 1025 type uint32; 1026 mandatory true; 1027 description "An instance identifier."; 1028 } 1029 leaf name { 1030 type string; 1031 description "The name for the binding BR."; 1032 } 1033 leaf softwire-num-max { 1034 type uint32; 1035 mandatory true; 1036 description 1037 "The maximum number of softwires that can be created on 1038 the binding BR."; 1039 } 1040 leaf softwires-payload-mtu { 1041 type uint16; 1042 units bytes; 1043 mandatory true; 1044 description 1045 "The payload IPv4 MTU for binding softwire."; 1046 } 1047 leaf softwire-path-mru { 1048 type uint16; 1049 units bytes; 1050 mandatory true; 1051 description 1052 "The path MRU for binding softwire."; 1053 } 1054 leaf enable-hairpinning { 1055 type boolean; 1056 default true; 1057 description 1058 "Enables/disables support for locally forwarding 1059 (hairpinning) traffic between two CEs."; 1060 reference 1061 "RFC7596 Section 6.2"; 1062 } 1063 container binding-table { 1064 description "binding table"; 1065 list binding-entry { 1066 key "binding-ipv6info"; 1067 description "binding entry"; 1068 uses binding-entry; 1069 } 1070 } 1071 container icmp-policy { 1072 description 1073 "The binding BR can be configured to process or drop 1074 incoming ICMP messages, and to generate outgoing ICMP 1075 error messages."; 1077 container icmpv4-errors { 1078 description 1079 "ICMPv4 error processing configuration"; 1080 leaf allow-incoming-icmpv4 { 1081 type boolean; 1082 default true; 1083 description 1084 "Enables the processing of incoming ICMPv4 1085 packets."; 1086 reference 1087 "RFC7596: Lightweight 4over6: An Extension to the 1088 Dual-Stack Lite Architecture"; 1089 } 1090 leaf icmpv4-rate { 1091 type uint32; 1092 description 1093 "Rate limit threshold in messages per-second 1094 for processing incoming ICMPv4 errors messages"; 1095 } 1096 leaf generate-icmpv4-errors { 1097 type boolean; 1098 default true; 1099 description 1100 "Enables the generation of outgoing ICMPv4 error 1101 messages on receipt of an inbound IPv4 packet with 1102 no matching binding table entry."; 1103 reference 1104 "Seciton 5.2 of RFC7596."; 1105 } 1107 } 1109 container icmpv6-errors { 1110 description 1111 "ICMPv6 error processing configuration"; 1112 leaf generate-icmpv6-errors { 1113 type boolean; 1114 default true; 1115 description 1116 "Enables the generation of ICMPv6 errors messages if 1117 no matching binding table entry is found for a 1118 received packet."; 1119 reference 1120 "Section 6.2 of RFC7596."; 1121 } 1122 leaf icmpv6-rate { 1123 type uint32; 1124 description 1125 "Rate limit threshold in messages per-second 1126 for sending ICMPv6 errors messages"; 1127 reference 1128 "Section 9 of RFC7596."; 1129 } 1130 } 1131 } 1133 container traffic-stat { 1134 config false; 1135 description 1136 "Traffic statistics information for the BR."; 1138 leaf discontinuity-time { 1139 type yang:date-and-time; 1140 mandatory true; 1141 description 1142 "The time of the most recent occasion on which the BR 1143 instance suffered a discontinuity. This must be 1144 initialized when the BR instance is configured 1145 or rebooted."; 1146 } 1148 uses softwire-common:traffic-stat; 1150 leaf dropped-icmpv4-packets { 1151 type yang:zero-based-counter64; 1152 description 1153 "ICMPv4 packets that are dropped as a result 1154 of the ICMP policy. Typically, this can be any 1155 incoming ICMPv4 packets if ICMPv4 processing is 1156 disabled or incoming ICMPv4 packets that exceed 1157 the ICMPv4 rate-limit threshold. 1159 Discontinuities in the value of this counter can 1160 occur at re-initialization of the management 1161 system, and at other times as indicated by 1162 the value of 'discontinuity-time'."; 1163 } 1164 leaf dropped-icmpv4-bytes { 1165 type yang:zero-based-counter64; 1166 description 1167 "ICMPv4 messages, in bytes, that are dropped as 1168 a result of the ICMP policy. Typically, it 1169 can be any incoming ICMPv4 packets if ICMPv4 1170 processing is disabled or incoming ICMPv4 1171 packets that exceed the ICMPv4 rate-limit 1172 threshold. 1174 Discontinuities in the value of this counter can 1175 occur at re-initialization of the management 1176 system, and at other times as indicated by 1177 the value of 'discontinuity-time'."; 1178 } 1179 leaf hairpin-ipv4-packets { 1180 type yang:zero-based-counter64; 1181 description 1182 "IPv4 packets locally routed between two CEs 1183 (hairpinned). 1185 Discontinuities in the value of this counter can 1186 occur at re-initialization of the management 1187 system, and at other times as indicated by 1188 the value of 'discontinuity-time'."; 1189 } 1190 leaf hairpin-ipv4-bytes { 1191 type yang:zero-based-counter64; 1192 description 1193 "IPv4 bytes locally routed between two CEs 1194 (hairpinned). 1196 Discontinuities in the value of this counter can 1197 occur at re-initialization of the management 1198 system, and at other times as indicated by 1199 the value of 'discontinuity-time'."; 1200 } 1201 leaf active-softwire-num { 1202 type uint32; 1203 config false; 1204 description 1205 "The number of currently active softwires on the 1206 binding instance. 1208 Discontinuities in the value of this counter can 1209 occur at re-initialization of the management 1210 system, and at other times as indicated by 1211 the value of 'discontinuity-time'."; 1212 } 1213 } 1214 } 1215 } 1216 } 1217 case algorithm { 1218 if-feature algorithm; 1219 container algorithm { 1220 if-feature algorithm; 1221 description 1222 "Indicate that the instance supports the MAP-E and MAP-T 1223 function. The instances advertise the MAP-E/MAP-T feature 1224 through the capability exchange mechanism when a NETCONF 1225 session is established."; 1226 list algo-instance { 1227 key "id"; 1228 description "Instances of algorithm"; 1229 leaf id { 1230 type uint32; 1231 mandatory true; 1232 description "id"; 1233 } 1234 uses softwire-common:algorithm-instance; 1235 container port-set { 1236 description "Indicates a set of ports."; 1237 uses port-set; 1238 } 1239 container traffic-stat { 1240 config false; 1241 description 1242 "Traffic statistics information for the BR."; 1243 leaf discontinuity-time { 1244 type yang:date-and-time; 1245 mandatory true; 1246 description 1247 "The time of the most recent occasion on which the BR 1248 instance suffered a discontinuity. This must be 1249 initialized when the BR instance is configured 1250 or rebooted."; 1252 } 1253 uses softwire-common:traffic-stat; 1254 } 1255 } 1256 } 1257 } 1258 } 1259 } 1261 /* 1262 * Notifications 1263 */ 1264 notification softwire-binding-instance-event { 1265 if-feature binding; 1266 description "Notifications for binding instance."; 1267 leaf bind-id { 1268 type leafref { 1269 path 1270 "/br-instances/binding/" 1271 + "bind-instance/id"; 1272 } 1273 description "The ID of the binding-instance that 1274 generated the notification."; 1275 } 1276 leaf-list invalid-entry { 1277 type leafref { 1278 path 1279 "/br-instances/binding/" 1280 + "bind-instance[id=current()/../bind-id]/" 1281 + "binding-table/binding-entry/binding-ipv6info"; 1282 } 1283 description 1284 "Notify the client that a specific binding entry has been 1285 expired/invalid. The binding-ipv6info identifies an entry."; 1286 } 1287 leaf-list added-entry { 1288 type inet:ipv6-address; 1289 description 1290 "Notify the client that a binding entry has been added. 1291 The ipv6 address of that entry is the index. The client 1292 gets other information from the binding BR about the entry 1293 indexed by that ipv6 address. 1294 "; 1295 } 1296 leaf-list modified-entry { 1297 type leafref { 1298 path 1299 "/br-instances/binding/" 1300 + "bind-instance[id=current()/../bind-id]/" 1301 + "binding-table/binding-entry/binding-ipv6info"; 1302 } 1303 description "The ID of the the binding-table entry that 1304 has been modified."; 1305 } 1306 } 1308 notification softwire-algorithm-instance-event { 1309 if-feature algorithm; 1310 description "Notifications for algorithmic instance."; 1311 leaf algo-id { 1312 type leafref { 1313 path 1314 "/br-instances/algorithm/algo-instance/id"; 1315 } 1316 mandatory true; 1317 description "algorithmic instance event."; 1318 } 1319 leaf-list invalid-entry-id { 1320 type leafref { 1321 path 1322 "/br-instances/algorithm/algo-instance/id"; 1323 } 1324 description "Invalid entry event."; 1325 } 1326 leaf-list added-entry { 1327 type leafref { 1328 path 1329 "/br-instances/algorithm/algo-instance/id"; 1330 } 1331 description "Added entry."; 1332 } 1333 leaf-list modified-entry { 1334 type leafref { 1335 path 1336 "/br-instances/algorithm/algo-instance/id"; 1337 } 1338 description "Modified entry."; 1339 } 1340 } 1341 } 1342 1343 7. Common Softwire Element Groups YANG Module 1345 The following YANG module contains definitions that are used by both 1346 the softwire CE and softwire BR YANG modules. 1348 file "ietf-softwire-common@2018-03-16.yang" 1350 module ietf-softwire-common { 1351 yang-version 1.1; 1352 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-common"; 1353 prefix "softwire-common"; 1355 import ietf-inet-types { prefix inet; } 1356 import ietf-yang-types { prefix yang; } 1358 organization 1359 "IETF Softwire Working Group"; 1361 contact 1362 "WG Web: 1363 WG List: 1365 Qi Sun 1366 Linhui Sun 1367 Yong Cui 1368 Ian Farrer 1369 Sladjana Zoric 1370 Mohamed Boucadair 1371 Rajiv 1372 "; 1374 description 1375 "This document defines a YANG data module for the configuration and 1376 management of A+P Softwire Customer Premises Equipment (CEs). It 1377 covers Lightweight 4over6, MAP-E and MAP-T mechanisms. 1379 Copyright (c) 2018 IETF Trust and the persons identified 1380 as authors of the code. All rights reserved. 1381 This version of this YANG module is part of RFC XXX; see the RFC 1382 itself for full legal notices."; 1384 revision 2018-03-16 { 1385 description 1386 "Initial revision."; 1387 reference 1388 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 1389 Softwires"; 1390 } 1391 /* 1392 * Groupings 1393 */ 1395 grouping algorithm-instance { 1396 description 1397 "Indicates that the instance supports the MAP-E and MAP-T 1398 function. The instance advertises the MAP-E/MAP-T feature 1399 through the capability exchange mechanism when a NETCONF 1400 session is established."; 1402 leaf enable { 1403 type boolean; 1404 description 1405 "Enable/disable an individual MAP-E or MAP-T rule."; 1406 } 1407 container algo-versioning { 1408 description "algorithm's version"; 1409 leaf version { 1410 type uint64; 1411 description "Incremental version number for the algorithm"; 1412 } 1413 leaf date { 1414 type yang:date-and-time; 1415 description "Timestamp to the algorithm"; 1416 } 1417 } 1418 leaf name { 1419 type string; 1420 description "The name for the instance."; 1421 } 1422 choice data-plane { 1423 description "Selects MAP-E (encapsulation) or MAP-T 1424 (translation)"; 1425 case encapsulation { 1426 description "encapsulation for MAP-E"; 1427 leaf br-ipv6-addr { 1428 type inet:ipv6-address; 1429 mandatory true; 1430 description 1431 "The IPv6 address of the MAP-E BR."; 1432 } 1433 } 1434 case translation { 1435 description "translation for MAP-T"; 1436 leaf dmr-ipv6-prefix { 1437 type inet:ipv6-prefix; 1438 description 1439 "The IPv6 prefix of the MAP-T BR."; 1440 } 1441 } 1442 } 1443 leaf ea-len { 1444 type uint8; 1445 mandatory true; 1446 description 1447 "Embedded Address (EA) bits are the IPv4 EA-bits in the IPv6 1448 address identify an IPv4 prefix/address (or part thereof) or 1449 a shared IPv4 address (or part thereof) and a port-set 1450 identifier. The length of the EA-bits is defined as part of 1451 a MAP rule for a MAP domain."; 1452 } 1453 leaf rule-ipv6-prefix { 1454 type inet:ipv6-prefix; 1455 mandatory true; 1456 description 1457 "The Rule IPv6 prefix defined in the mapping rule."; 1458 } 1459 leaf rule-ipv4-prefix { 1460 type inet:ipv4-prefix; 1461 mandatory true; 1462 description 1463 "The Rule IPv4 prefix defined in the mapping rule."; 1464 } 1465 leaf forwarding { 1466 type boolean; 1467 mandatory true; 1468 description 1469 "This parameter specifies whether the rule may be used for 1470 forwarding (FMR). If set, this rule is used as an FMR; 1471 if not set, this rule is a Basic Mapping Rule (BMR) only 1472 and must not be used for forwarding."; 1473 } 1474 } 1476 grouping traffic-stat { 1477 description "Traffic statistics"; 1478 leaf sent-ipv4-packets { 1479 type yang:zero-based-counter64; 1480 description "Number of decapsulated and forwarded IPv4 packets. 1482 Discontinuities in the value of this counter can occur 1483 at re-initialization of the management system, and at 1484 other times as indicated by the value of 1485 'discontinuity-time'."; 1486 } 1487 leaf sent-ipv4-bytes { 1488 type yang:zero-based-counter64; 1489 description "Decapsulated/translated IPv4 traffic sent, in bytes 1491 Discontinuities in the value of this counter can occur 1492 at re-initialization of the management system, and at 1493 other times as indicated by the value of 1494 'discontinuity-time'."; 1495 } 1496 leaf sent-ipv6-packets { 1497 type yang:zero-based-counter64; 1498 description "Number of encapsulated IPv6 packets sent. 1500 Discontinuities in the value of this counter can occur 1501 at re-initialization of the management system, and at 1502 other times as indicated by the value of 1503 'discontinuity-time'."; 1504 } 1505 leaf sent-ipv6-bytes { 1506 type yang:zero-based-counter64; 1507 description "Encapsulated IPv6 traffic sent, in bytes 1509 Discontinuities in the value of this counter can occur 1510 at re-initialization of the management system, and at 1511 other times as indicated by the value of 1512 'discontinuity-time'."; 1513 } 1514 leaf rcvd-ipv4-packets { 1515 type yang:zero-based-counter64; 1516 description "Number of incoming IPv4 packets at the 1517 Internet-facing interface. 1519 Discontinuities in the value of this counter can occur 1520 at re-initialization of the management system, and at 1521 other times as indicated by the value of 1522 'discontinuity-time'."; 1523 } 1524 leaf rcvd-ipv4-bytes { 1525 type yang:zero-based-counter64; 1526 description "IPv4 traffic received for processing, in bytes 1528 Discontinuities in the value of this counter can occur 1529 at re-initialization of the management system, and at 1530 other times as indicated by the value of 1531 'discontinuity-time'."; 1532 } 1533 leaf rcvd-ipv6-packets { 1534 type yang:zero-based-counter64; 1535 description "Number of IPv4-in-IPv6 packets received 1537 Discontinuities in the value of this counter can occur 1538 at re-initialization of the management system, and at 1539 other times as indicated by the value of 1540 'discontinuity-time'."; 1541 } 1542 leaf rcvd-ipv6-bytes { 1543 type yang:zero-based-counter64; 1544 description "IPv4-in-IPv6 traffic received, in bytes 1546 Discontinuities in the value of this counter can occur 1547 at re-initialization of the management system, and at 1548 other times as indicated by the value of 1549 'discontinuity-time'."; 1550 } 1551 leaf dropped-ipv4-packets { 1552 type yang:zero-based-counter64; 1553 description "Number of IPv4 packets dropped at the 1554 Internet-facing interface. 1556 Discontinuities in the value of this counter can occur 1557 at re-initialization of the management system, and at 1558 other times as indicated by the value of 1559 'discontinuity-time'."; 1560 } 1561 leaf dropped-ipv4-bytes { 1562 type yang:zero-based-counter64; 1563 description "IPv4 traffic dropped at the Internet-facing 1564 interface, in bytes. 1566 Discontinuities in the value of this counter can occur 1567 at re-initialization of the management system, and at 1568 other times as indicated by the value of 1569 'discontinuity-time'."; 1570 } 1571 leaf dropped-ipv6-packets { 1572 type yang:zero-based-counter64; 1573 description "Number of IPv4-in-IPv6 packets dropped. 1575 Discontinuities in the value of this counter can occur 1576 at re-initialization of the management system, and at 1577 other times as indicated by the value of 1578 'discontinuity-time'."; 1579 } 1580 leaf dropped-ipv6-bytes { 1581 type yang:zero-based-counter64; 1582 description "IPv4-in-IPv6 traffic dropped, in bytes 1583 Discontinuities in the value of this counter can occur 1584 at re-initialization of the management system, and at 1585 other times as indicated by the value of 1586 'discontinuity-time'."; 1587 } 1588 leaf dropped-ipv4-fragments { 1589 type yang:zero-based-counter64; 1590 description "Number of fragmented IPv4 packets dropped 1592 Discontinuities in the value of this counter can occur 1593 at re-initialization of the management system, and at 1594 other times as indicated by the value of 1595 'discontinuity-time'."; 1596 } 1597 leaf dropped-ipv4-fragment-bytes { 1598 type yang:zero-based-counter64; 1599 description "Fragmented IPv4 traffic dropped, in bytes 1601 Discontinuities in the value of this counter can occur 1602 at re-initialization of the management system, and at 1603 other times as indicated by the value of 1604 'discontinuity-time'."; 1605 } 1606 leaf ipv6-fragments-reassembled { 1607 type yang:zero-based-counter64; 1608 description "Number of IPv6 fragments successfully reassembled 1610 Discontinuities in the value of this counter can occur 1611 at re-initialization of the management system, and at 1612 other times as indicated by the value of 1613 'discontinuity-time'."; 1614 } 1615 leaf ipv6-fragments-bytes-reassembled { 1616 type yang:zero-based-counter64; 1617 description "IPv6 fragments successfully reassembled, in bytes 1619 Discontinuities in the value of this counter can occur 1620 at re-initialization of the management system, and at 1621 other times as indicated by the value of 1622 'discontinuity-time'."; 1623 } 1624 leaf out-icmpv4-error-packets { 1625 type yang:zero-based-counter64; 1626 description "Internally generated ICMPv4 error packets. 1628 Discontinuities in the value of this counter can occur 1629 at re-initialization of the management system, and at 1630 other times as indicated by the value of 1631 'discontinuity-time'."; 1632 } 1633 leaf out-icmpv4-error-bytes { 1634 type yang:zero-based-counter64; 1635 description "Internally generated ICMPv4 error messages, in bytes. 1637 Discontinuities in the value of this counter can occur 1638 at re-initialization of the management system, and at 1639 other times as indicated by the value of 1640 'discontinuity-time'."; 1641 } 1642 leaf out-icmpv6-error-packets { 1643 type yang:zero-based-counter64; 1644 description "Internally generated ICMPv6 error packets. 1646 Discontinuities in the value of this counter can occur 1647 at re-initialization of the management system, and at 1648 other times as indicated by the value of 1649 'discontinuity-time'."; 1650 } 1651 leaf out-icmpv6-error-bytes { 1652 type yang:zero-based-counter64; 1653 description "Internally generated ICMPv6 error messages, in bytes. 1655 Discontinuities in the value of this counter can occur 1656 at re-initialization of the management system, and at 1657 other times as indicated by the value of 1658 'discontinuity-time'."; 1659 } 1660 } 1661 } 1662 1664 8. Security Considerations 1666 The YANG module defined in this document is designed to be accessed 1667 via network management protocols such as NETCONF [RFC6241] or 1668 RESTCONF [RFC8040]. The lowest NETCONF layer is the secure transport 1669 layer, and the mandatory-to-implement secure transport is Secure 1670 Shell (SSH) [RFC6242]. The lowest RESTCONF layer is HTTPS, and the 1671 mandatory-to-implement secure transport is TLS [RFC5246]. 1673 The NETCONF access control model [RFC8341] provides the means to 1674 restrict access for particular NETCONF or RESTCONF users to a 1675 preconfigured subset of all available NETCONF or RESTCONF protocol 1676 operations and content. 1678 All data nodes defined in the YANG modules which can be created, 1679 modified, and deleted (i.e., config true, which is the default) are 1680 considered sensitive. Write operations (e.g., edit-config) applied 1681 to these data nodes without proper protection can negatively affect 1682 network operations. 1684 9. IANA Considerations 1686 This document requests IANA to register the following URIs in the 1687 "IETF XML Registry" [RFC3688]. 1689 URI: urn:ietf:params:xml:ns:yang:softwire-ce 1690 Registrant Contact: The IESG. 1691 XML: N/A; the requested URI is an XML namespace. 1693 URI: urn:ietf:params:xml:ns:yang:softwire-br 1694 Registrant Contact: The IESG. 1695 XML: N/A; the requested URI is an XML namespace. 1697 URI: urn:ietf:params:xml:ns:yang:softwire-common 1698 Registrant Contact: The IESG. 1699 XML: N/A; the requested URI is an XML namespace. 1701 This document requests that IANA registers the following YANG modules 1702 in the "YANG Module Names" registry [RFC7950]. 1704 name: ietf-softwire-ce 1705 namespace: urn:ietf:params:xml:ns:yang:softwire-ce 1706 prefix: softwire-ce 1707 reference: RFC XXXX 1709 name: ietf-softwire-br 1710 namespace: urn:ietf:params:xml:ns:yang:softwire-br 1711 prefix: softwire-br 1712 reference: RFC XXXX 1714 name: ietf-softwire-common 1715 namespace: urn:ietf:params:xml:ns:yang:softwire-common 1716 prefix: softwire-br 1717 reference: RFC XXXX 1719 10. Acknowledgements 1721 The authors would like to thank Lishan Li, Bert Wijnen, Giles Heron, 1722 Ole Troan, Andy Wingo and Leo Tietz for their contributions to this 1723 work. 1725 Thanks to Sheng Jiang for the review. 1727 11. Contributors 1729 The following individuals contributed to this document: 1731 Hao Wang 1732 Tsinghua University 1733 Beijing 100084 1734 P.R.China 1735 Phone: +86-10-6278-5822 1736 Email: wangh13@mails.tsinghua.edu.cn 1738 12. References 1740 12.1. Normative References 1742 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 1743 DOI 10.17487/RFC3688, January 2004, 1744 . 1746 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 1747 (TLS) Protocol Version 1.2", RFC 5246, 1748 DOI 10.17487/RFC5246, August 2008, 1749 . 1751 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 1752 and A. Bierman, Ed., "Network Configuration Protocol 1753 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 1754 . 1756 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 1757 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 1758 . 1760 [RFC7596] Cui, Y., Sun, Q., Boucadair, M., Tsou, T., Lee, Y., and I. 1761 Farrer, "Lightweight 4over6: An Extension to the Dual- 1762 Stack Lite Architecture", RFC 7596, DOI 10.17487/RFC7596, 1763 July 2015, . 1765 [RFC7597] Troan, O., Ed., Dec, W., Li, X., Bao, C., Matsushima, S., 1766 Murakami, T., and T. Taylor, Ed., "Mapping of Address and 1767 Port with Encapsulation (MAP-E)", RFC 7597, 1768 DOI 10.17487/RFC7597, July 2015, 1769 . 1771 [RFC7598] Mrugalski, T., Troan, O., Farrer, I., Perreault, S., Dec, 1772 W., Bao, C., Yeh, L., and X. Deng, "DHCPv6 Options for 1773 Configuration of Softwire Address and Port-Mapped 1774 Clients", RFC 7598, DOI 10.17487/RFC7598, July 2015, 1775 . 1777 [RFC7599] Li, X., Bao, C., Dec, W., Ed., Troan, O., Matsushima, S., 1778 and T. Murakami, "Mapping of Address and Port using 1779 Translation (MAP-T)", RFC 7599, DOI 10.17487/RFC7599, July 1780 2015, . 1782 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 1783 RFC 7950, DOI 10.17487/RFC7950, August 2016, 1784 . 1786 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 1787 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 1788 . 1790 [RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration 1791 Access Control Model", STD 91, RFC 8341, 1792 DOI 10.17487/RFC8341, March 2018, 1793 . 1795 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 1796 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 1797 . 1799 12.2. Informative References 1801 [I-D.ietf-opsawg-nat-yang] 1802 Boucadair, M., Sivakumar, S., Jacquenet, C., Vinapamula, 1803 S., and Q. Wu, "A YANG Module for Network Address 1804 Translation (NAT) and Network Prefix Translation (NPT)", 1805 draft-ietf-opsawg-nat-yang-15 (work in progress), June 1806 2018. 1808 [I-D.ietf-softwire-dslite-yang] 1809 Boucadair, M., Jacquenet, C., and S. Sivakumar, "A YANG 1810 Data Model for Dual-Stack Lite (DS-Lite)", draft-ietf- 1811 softwire-dslite-yang-17 (work in progress), May 2018. 1813 [RFC6333] Durand, A., Droms, R., Woodyatt, J., and Y. Lee, "Dual- 1814 Stack Lite Broadband Deployments Following IPv4 1815 Exhaustion", RFC 6333, DOI 10.17487/RFC6333, August 2011, 1816 . 1818 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 1819 RFC 6991, DOI 10.17487/RFC6991, July 2013, 1820 . 1822 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 1823 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 1824 . 1826 [RFC8344] Bjorklund, M., "A YANG Data Model for IP Management", 1827 RFC 8344, DOI 10.17487/RFC8344, March 2018, 1828 . 1830 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 1831 Routing Management (NMDA Version)", RFC 8349, 1832 DOI 10.17487/RFC8349, March 2018, 1833 . 1835 Appendix A. Configutation Examples 1837 The following sections provide examples of how the softwire YANG 1838 modules can be used for configuring softwire elements. 1840 A.1. Configuration Example for a lw4o6 BR Binding-Table 1842 The lwAFTR maintains an address binding table which contains the 1843 following 3-tuples: 1845 o IPv6 Address for a single lwB4 1847 o Public IPv4 Address 1849 o Restricted port-set 1851 The entry has two functions: the IPv6 encapsulation of inbound IPv4 1852 packets destined to the lwB4 and the validation of outbound IPv4-in- 1853 IPv6 packets received from the lwB4 for de-capsulation. 1855 Consider an example for the following lw4o6 binding table entry: 1857 lwB4 Binding IPv6 Address: 2001:db8::1 1859 lwB4 Binding IPv4 Address: 192.0.2.1 1861 lwB4 PSID: 0x34 1863 lwB4 PSID Length 8 1865 BR IPv6 Address: 2001:db8:1::2 1867 1868 1869 1870 1871 1872 1 1873 1874 1875 2001:db8::1 1876 192.0.2.1 1877 1878 52 1879 8 1880 1881 2001:db8:1::2 1882 1883 1884 1024 1885 1540 1886 1500 1887 1888 1889 1890 1891 1893 Figure 3: lw4o6 Binding-Table Configuration XML 1895 A.2. Configuration Example for a MAP-E BR 1897 A MAP-E BR is configured with forward mapping rules for the CEs it is 1898 serving. In this example (taken from [RFC7597], Appendix A, Example 1899 2), the following parameters are required: 1901 o Rule IPv6 Prefix 1903 o Rule IPv4 Prefix 1905 o Rule EA-bit bit length 1907 o IPv6 Address of MAP-BR 1909 The mapping rule has two functions: identifying the destination CE 1910 IPv6 address for encapsulating inbound IPv4 packets and the 1911 validation of outbound IPv4-in-IPv6 packets received from the CE for 1912 de-capsulation. 1914 The transport type for the data plane also needs to be configured for 1915 encapsulation to enable MAP-E and forwarding needs to be enabled. 1917 Consider an example for the following MAP-E Forwarding Mapping Rule: 1919 Data plane: encapsulation 1921 Rule IPv6 Prefix: 2001:db8::/40 1923 Rule IPv4 Prefix: 192.0.2.0/24 1925 Rule EA-bit Length: 16 1927 BR IPv6 Address: 2001:db8:ffff::1 1929 Figure 4 provides the example MAP-E BR configuration xml. 1931 1932 1933 1934 1935 1936 42 1937 1938 1939 1234 1940 encapsulation 1941 16 1942 192.0.2.0/24 1943 2001:db8::/40 1944 true 1945 2001:db8:ffff::1 1946 6 1947 8 1948 1949 1950 1951 1952 1953 1954 1956 Figure 4: MAP-E FMR Configuration XML 1958 A.3. lw4o6 CE Configuration Example 1960 This section provides XML examples for configuring a lw4o6 CE. 1961 Examples for routing and NAT44 are also provided for convienience. 1963 Consider an example for the following lw4o6 CE configuration: 1965 lwB4 Binding IPv6 Address: 2001:db8::1 1967 lwB4 Binding IPv4 Address: 192.0.2.1 1969 lwB4 PSID: 0x34 1971 lwB4 PSID Length 8 1973 BR IPv6 Address: 2001:db8:1::2 1975 1976 1977 1978 lw4o6-wan 1979 1981 iana:tunnel 1982 1983 1985 2001:db8:1::2 1986 2001:db8::1 1987 1988 1989 1990 1992 Figure 5: lw4o6 CE Configuration XML 1994 In the example depicted in Figure 5, the interface name is defined 1995 for the softwire tunnel. This name is then referenced by the routing 1996 configuration for the IPv4 route. Figure 6 provides an example 1997 configuration for the CE's IPv4 routing, using the YANG module 1998 described in [RFC8349]. 2000 2001 2002 2003 2004 static 2005 v4 2006 2007 2009 2010 0.0.0.0/0 2011 2012 lw4o6-wan 2013 2014 2015 2016 2017 2018 2019 2020 2022 Figure 6: lw4o6 CE Routing Configuration XML 2024 Figure 7 provides an example configuration for the CE's NAPT44 2025 function, using the YANG module described in 2026 [I-D.ietf-opsawg-nat-yang]. 2028 2029 2030 2031 2032 1 2033 2034 1 2035 2036 1 2037 192.0.2.1 2038 2039 2040 2041 6 2042 8 2043 52 2044 2045 2046 2047 1 2048 80 2049 2050 2051 2052 2053 1 2054 8 2055 2056 2057 6 2058 32 2059 2060 2061 17 2062 16 2063 2064 2065 2066 2067 1 2068 192.0.2.1/32 2069 192.168.1.0/24 2070 6 2071 2072 2073 2 2074 192.0.2.1/32 2075 192.168.1.0/24 2076 17 2077 2078 2079 3 2080 192.0.2.1/32 2081 192.168.1.0/24 2082 1 2083 2084 2085 2086 2087 2088 2090 Figure 7: lw4o6 NAT Configuration XML 2092 Authors' Addresses 2094 Yong Cui 2095 Tsinghua University 2096 Beijing 100084 2097 P.R. China 2099 Phone: +86-10-6260-3059 2100 Email: yong@csnet1.cs.tsinghua.edu.cn 2102 Ian Farrer 2103 Deutsche Telekom AG 2104 CTO-ATI,Landgrabenweg 151 2105 Bonn, NRW 53227 2106 Germany 2108 Email: ian.farrer@telekom.de 2110 Mohamed Boucadair 2111 Orange 2112 Rennes 35000 2113 France 2115 Email: mohamed.boucadair@orange.com 2117 Qi Sun 2118 Tsinghua University 2119 Beijing 100084 2120 P.R. China 2122 Phone: +86-10-6278-5822 2123 Email: sunqi.ietf@gmail.com 2125 Linhui Sun 2126 Tsinghua University 2127 Beijing 100084 2128 P.R. China 2130 Phone: +86-10-6278-5822 2131 Email: lh.sunlinh@gmail.com 2132 Sladjana Zechlin 2133 Deutsche Telekom AG 2134 Landgrabenweg 151 2135 Bonn, NRW 53227 2136 Germany 2138 Email: sladjana.zechlin@telekom.de 2140 Rajiv Asati 2141 Cisco Systems, Inc. 2142 7025 Kit Creek Rd. 2143 RTP, NC 27709 2144 USA 2146 Email: Rajiva@cisco.com