idnits 2.17.1 draft-ietf-softwire-yang-14.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 280 has weird spacing: '...-prefix ine...' == Line 281 has weird spacing: '...-prefix ine...' == Line 327 has weird spacing: '...-change ine...' == Line 499 has weird spacing: '...-prefix ine...' == Line 500 has weird spacing: '...-prefix ine...' -- The document date (January 7, 2019) is 1934 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) -- Possible downref: Non-RFC (?) normative reference: ref. 'TUNNELTYPE-IANA-REGISTRY' Summary: 0 errors (**), 0 flaws (~~), 6 warnings (==), 2 comments (--). 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, Ed. 5 Expires: July 11, 2019 Deutsche Telekom AG 6 M. Boucadair, Ed. 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 January 7, 2019 17 YANG Modules for IPv4-in-IPv6 Address plus Port (A+P) Softwires 18 draft-ietf-softwire-yang-14 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, Mapping of Address and 25 Port with Encapsulation (MAP-E), and Mapping of Address and Port 26 using Translation (MAP-T) softwire mechanisms. 28 Editorial Note (To be removed by RFC Editor) 30 Please update these statements within this document with the RFC 31 number to be assigned to this document: 33 o "This version of this YANG module is part of RFC XXXX;" 35 o "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 36 Softwires"; 38 o "reference: RFC XXXX" 40 Please update the "revision" date of the YANG modules. 42 Status of This Memo 44 This Internet-Draft is submitted in full conformance with the 45 provisions of BCP 78 and BCP 79. 47 Internet-Drafts are working documents of the Internet Engineering 48 Task Force (IETF). Note that other groups may also distribute 49 working documents as Internet-Drafts. The list of current Internet- 50 Drafts is at https://datatracker.ietf.org/drafts/current/. 52 Internet-Drafts are draft documents valid for a maximum of six months 53 and may be updated, replaced, or obsoleted by other documents at any 54 time. It is inappropriate to use Internet-Drafts as reference 55 material or to cite them other than as "work in progress." 57 This Internet-Draft will expire on July 11, 2019. 59 Copyright Notice 61 Copyright (c) 2019 IETF Trust and the persons identified as the 62 document authors. All rights reserved. 64 This document is subject to BCP 78 and the IETF Trust's Legal 65 Provisions Relating to IETF Documents 66 (https://trustee.ietf.org/license-info) in effect on the date of 67 publication of this document. Please review these documents 68 carefully, as they describe your rights and restrictions with respect 69 to this document. Code Components extracted from this document must 70 include Simplified BSD License text as described in Section 4.e of 71 the Trust Legal Provisions and are provided without warranty as 72 described in the Simplified BSD License. 74 Table of Contents 76 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 77 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 3 78 3. Overview of the Modules . . . . . . . . . . . . . . . . . . . 4 79 3.1. Overall Structure . . . . . . . . . . . . . . . . . . . . 4 80 3.2. Additional Components Configuration . . . . . . . . . . . 5 81 4. Softwire CE YANG Tree Diagram . . . . . . . . . . . . . . . . 6 82 4.1. CE Tree Diagram . . . . . . . . . . . . . . . . . . . . . 6 83 4.2. Softwire CE Tree Diagram Description . . . . . . . . . . 8 84 5. Softwire BR YANG Tree Diagram . . . . . . . . . . . . . . . . 9 85 5.1. BR Tree Diagram . . . . . . . . . . . . . . . . . . . . . 9 86 5.2. Softwire BR Tree Diagram Description . . . . . . . . . . 13 87 6. Softwire CE YANG Module . . . . . . . . . . . . . . . . . . . 13 88 7. BR Softwire YANG Module . . . . . . . . . . . . . . . . . . . 19 89 8. Common Softwire Element Groups YANG Module . . . . . . . . . 31 90 9. Security Considerations . . . . . . . . . . . . . . . . . . . 40 91 10. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 40 92 11. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 41 93 12. Contributors . . . . . . . . . . . . . . . . . . . . . . . . 41 94 13. References . . . . . . . . . . . . . . . . . . . . . . . . . 41 95 13.1. Normative References . . . . . . . . . . . . . . . . . . 41 96 13.2. Informative References . . . . . . . . . . . . . . . . . 43 98 Appendix A. Configuration Examples . . . . . . . . . . . . . . . 44 99 A.1. Configuration Example for a lw4o6 BR Binding-Table . . . 44 100 A.2. Configuration Example for a MAP-E BR . . . . . . . . . . 45 101 A.3. lw4o6 CE Configuration Example . . . . . . . . . . . . . 47 102 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 51 104 1. Introduction 106 The IETF Softwire working group has developed several IPv4-in-IPv6 107 softwire mechanisms to address various deployment contexts and 108 constraints. As a companion to the architectural specification 109 documents, this document focuses on the provisioning of address plus 110 port (A+P) softwire functional elements: Border Routers (BRs) and 111 Customer Premises Equipment (CEs, a.k.a., CPE). The softwire 112 mechanisms covered in this document are Lightweight 4 over 6 (lw4o6) 113 [RFC7596], Mapping of Address and Port with Encapsulation (MAP-E) 114 [RFC7597], and Mapping of Address and Port using Translation (MAP-T) 115 [RFC7599]. 117 This document focuses on A+P mechanisms [RFC6346]; the reader can 118 refer to [I-D.ietf-softwire-dslite-yang] for a YANG module for DS- 119 Lite [RFC6333]. 121 This document defines YANG modules [RFC7950] that can be used to 122 configure and manage A+P softwire elements using the NETCONF 123 [RFC6241], or RESTCONF [RFC8040] protocols for: 125 o Configuration 127 o Operational State 129 o Notifications 131 2. Terminology 133 The reader should be familiar with the concepts and terms defined in 134 [RFC7596], [RFC7597], [RFC7599], and the YANG data modelling language 135 defined in [RFC7950]. 137 The adopts the Network Management Datastore Architecture (NMDA) 138 [RFC8342]. The meaning of the symbols in tree diagrams is defined in 139 [RFC8340]. 141 The document uses the abbrieviation 'BR' as a general term for 142 softwire tunnel concentrators, including both MAP Border Routers 143 [RFC7597] and Lightweight 4over6 lWAFTRs [RFC7596]. 145 For brevity, "algorithm" is used to refer to the "mapping algorithm" 146 defined in [RFC7597]. 148 A network element may support one or multiple instances of a softwire 149 mechanism; each of these instances (i.e., binding instances, MAP-E 150 instances, or MAP-T instances) may have its own configuration and 151 parameters. The term 'algo-instance' is used to denote both MAP-E 152 and MAP-T instances. 154 3. Overview of the Modules 156 3.1. Overall Structure 158 The document defines the following two YANG modules for the 159 configuration and monitoring of softwire functional elements: 161 ietf-softwire-ce Provides configuration and monitoring for 162 softwire CE element. This module is defined as 163 augments to the interface YANG module 164 [RFC8343]. 166 ietf-softwire-br Provides configuration and monitoring for 167 softwire BR element. 169 In addition, the following module is defined: 171 ietf-softwire-common Contains groups of common functions that are 172 imported into the CE and BR modules. 174 This approach has been taken so that the various modules can be 175 easily extended to support additional softwire mechanisms, if 176 required. 178 Within the BR and CE modules, the YANG "feature" statement is used to 179 distinguish which of the different softwire mechanism(s) is relevant 180 for a specific element's configuration. For each module, a choice 181 statement 'ce-type' is included for either 'binding' or 'algorithm'. 182 'Binding' is used for configuring Lightweight 4over6, whereas 183 'algorithm' is used for configuring MAP-T or MAP-E. 185 In the 'algo-instances' container, a choice statement 'data-plane' is 186 included to specify MAP-E (encapsulation) or MAP-T (translation). 187 Table 1 shows how these choices are used to indicate the desired 188 softwire mechanism: 190 +--------------------+-----------+---------------+ 191 | S46 Mechanism | ce-type? | data-plane? | 192 +--------------------+-----------+---------------+ 193 | Lightweight 4over6 | binding | n/a | 194 | MAP-E | algorithm | encapsulation | 195 | MAP-T | algorithm | translation | 196 +--------------------+-----------+---------------+ 198 Table 1: Softwire Mechanism Choice Statement Enumeration 200 NETCONF notifications are also included. 202 Note: Earlier versions of this specification combined the softwire 203 mechanisms by their associated technologies rather than their 204 function in the architecture. As the document was revised, it 205 became apparent that dividing the modules by their role in the 206 architecture (CE or BR) was a better approach as this follows the 207 intended function and existing implementation approaches more 208 closely. 210 3.2. Additional Components Configuration 212 The softwire modules only aim to provide configuration relevant for 213 softwires. In order to fully provision a CE element, the following 214 may also be necessary: 216 o IPv6 forwarding and routing configuration, enabling the CE to 217 obtain one or more IPv6 prefixes for softwire usage. A YANG 218 module for routing management is described in [RFC8349]. 220 o IPv4 routing configuration, to add one or more IPv4 destination 221 prefix(es) reachable via the configured softwire. A YANG module 222 for routing management is described in [RFC8349]. 224 o Stateful NAT44/NAPT management, to optionally specify a port set 225 (Port Set Identifier (PSID)) along with its length. A YANG module 226 for NAT management is described in [I-D.ietf-opsawg-nat-yang]. 228 o Stateless NAT46 management, required by softwire translation based 229 mechanisms (i.e., the assignment of a Network-Specific Prefix to 230 use for IPv4/IPv6 translation). A YANG module for NAT management 231 is described in [I-D.ietf-opsawg-nat-yang]. 233 As YANG modules for the above functions are already defined in other 234 documents, their functionality is not duplicated here and they should 235 be referred to, as needed. Appendix A.3 provides XML examples of how 236 these modules can be used together. 238 The CE must already have minimal IPv6 configuration in place so it is 239 reachable by the NETCONF client to obtain softwire configuration. If 240 additional IPv6 specific configuration is necessary, the YANG modules 241 defined in [RFC8344] and [RFC8349] may be used. 243 4. Softwire CE YANG Tree Diagram 245 4.1. CE Tree Diagram 247 The CE module provides configuration and monitoring for all of the 248 softwire mechanisms covered in this document (i.e., Lightweight 249 4over6, MAP-E, and MAP-T). 251 This module augments "ietf-interfaces", defined in [RFC8343] with an 252 entry for the softwire. This entry can be referenced to configure 253 IPv4 forwarding features for the element. This entry is added only 254 if tunnel type (Section 10) is set to 'aplusp'. 256 Figure 1 shows the tree structure of the softwire CE YANG module: 258 module: ietf-softwire-ce 259 augment /if:interfaces/if:interface: 260 +--rw softwire-payload-mtu? uint16 261 +--rw softwire-path-mru? uint16 262 +--rw (ce-type)? 263 +--:(binding) {binding-mode}? 264 | +--rw binding-ipv6info? union 265 | +--rw br-ipv6-addr inet:ipv6-address 266 +--:(algo) {map-e or map-t}? 267 +--rw algo-instances 268 +--rw algo-instance* [name] 269 +--rw name string 270 +--rw enable? boolean 271 +--rw algo-versioning 272 | +--rw version? uint64 273 | +--rw date? yang:date-and-time 274 +--rw (data-plane)? 275 | +--:(encapsulation) {map-e}? 276 | | +--rw br-ipv6-addr inet:ipv6-address 277 | +--:(translation) {map-t}? 278 | +--rw dmr-ipv6-prefix? inet:ipv6-prefix 279 +--rw ea-len uint8 280 +--rw rule-ipv6-prefix inet:ipv6-prefix 281 +--rw rule-ipv4-prefix inet:ipv4-prefix 282 +--rw forwarding boolean 283 augment /if:interfaces/if:interface/if:statistics: 284 +--ro sent-ipv4-packets? 285 | yang:zero-based-counter64 286 +--ro sent-ipv4-bytes? 287 | yang:zero-based-counter64 288 +--ro sent-ipv6-packets? 289 | yang:zero-based-counter64 290 +--ro sent-ipv6-bytes? 291 | yang:zero-based-counter64 292 +--ro rcvd-ipv4-packets? 293 | yang:zero-based-counter64 294 +--ro rcvd-ipv4-bytes? 295 | yang:zero-based-counter64 296 +--ro rcvd-ipv6-packets? 297 | yang:zero-based-counter64 298 +--ro rcvd-ipv6-bytes? 299 | yang:zero-based-counter64 300 +--ro dropped-ipv4-packets? 301 | yang:zero-based-counter64 302 +--ro dropped-ipv4-bytes? 303 | yang:zero-based-counter64 304 +--ro dropped-ipv6-packets? 305 | yang:zero-based-counter64 306 +--ro dropped-ipv6-bytes? 307 | yang:zero-based-counter64 308 +--ro dropped-ipv4-fragments? 309 | yang:zero-based-counter64 310 +--ro dropped-ipv4-fragment-bytes? 311 | yang:zero-based-counter64 312 +--ro ipv6-fragments-reassembled? 313 | yang:zero-based-counter64 314 +--ro ipv6-fragments-bytes-reassembled? 315 | yang:zero-based-counter64 316 +--ro out-icmpv4-error-packets? 317 | yang:zero-based-counter64 318 +--ro out-icmpv4-error-bytes? 319 | yang:zero-based-counter64 320 +--ro out-icmpv6-error-packets? 321 | yang:zero-based-counter64 322 +--ro out-icmpv6-error-bytes? 323 yang:zero-based-counter64 325 notifications: 326 +---n softwire-ce-event {binding-mode}? 327 +--ro ce-binding-ipv6-addr-change inet:ipv6-address 329 Figure 1: Softwire CE YANG Tree Diagram 331 4.2. Softwire CE Tree Diagram Description 333 Additional information related to the operation of a CE element is 334 provided below: 336 o softwire-payload-mtu: optionally used to set the IPv4 MTU for the 337 softwire. Needed if the softwire implementation is unable to 338 correctly calculate the correct IPv4 Maximum Transit Unit (MTU) 339 size automatically. 341 o softwire-path-mru: optionally used to set the maximum IPv6 342 softwire packet size that can be received, including the 343 encapsulation/translation overhead. Needed if the softwire 344 implementation is unable to correctly calculate the correct IPv4 345 Maximum Receive Unit (MRU) size automatically [RFC4213]. 347 o ce-type: provides a choice statement allowing the binding or 348 algorithmic softwire mechanisms to be selected. 350 Further details relevant to binding softwire elements are: 352 o binding-ipv6info: used to set the IPv6 binding prefix type to 353 identify which IPv6 address to use as the tunnel source. It can 354 be 'ipv6-prefix' or 'ipv6-address'. 356 o br-ipv6-addr: sets the IPv6 address of the remote BR. 358 Additional details relevant to some of the important algorithmic 359 elements are provided below: 361 o algo-versioning: optionally used to associate a version number 362 and/or timestamp to the algorithm. This can be used for logging/ 363 data retention purposes [RFC7422]. The version number is selected 364 to uniquely identify the algorithm configuration and a new value 365 written whenever a change is made to the algorithm or a new algo- 366 instance is created. 368 o forwarding: specifies whether the rule can be used as a Forward 369 Mapping Rule (FMR). If not set, this rule is a Basic Mapping Rule 370 (BMR) only and must not be used for forwarding. Refer to 371 Section 4.1 of [RFC7598]. 373 o ea-len: used to set the length of the Embedded-Address (EA), which 374 is defined in the mapping rule for a MAP domain. 376 o data-plane: provides a choice statement for either encapsulation 377 (MAP-E) or translation (MAP-T). 379 o br-ipv6-addr: defines the IPv6 address of the BR. This 380 information is valid for MAP-E. 382 o dmr-ipv6-prefix: defines the Default Mapping Rule (DMR) IPv6 383 prefix of the BR. This information is valid for MAP-T. 385 Additional information on the notification node is listed below: 387 o ce-binding-ipv6-addr-change: if the CE's binding IPv6 address 388 changes for any reason, the NETCONF client will be notified. 390 5. Softwire BR YANG Tree Diagram 392 5.1. BR Tree Diagram 394 The BR YANG module provides configuration and monitoring for all of 395 the softwire mechanisms covered in this document (i.e., Lightweight 396 4over6, MAP-E, and MAP-T). 398 Figure 2 provides the tree structure of this module: 400 module: ietf-softwire-br 401 +--rw br-instances 402 +--rw (br-type)? 403 +--:(binding) {binding-mode}? 404 | +--rw binding 405 | +--rw bind-instance* [name] 406 | +--rw name string 407 | +--rw binding-table-versioning 408 | | +--rw version? uint64 409 | | +--rw date? yang:date-and-time 410 | +--rw softwire-num-max uint32 411 | +--rw softwire-payload-mtu uint16 412 | +--rw softwire-path-mru uint16 413 | +--rw enable-hairpinning? boolean 414 | +--rw binding-table 415 | | +--rw binding-entry* [binding-ipv6info] 416 | | +--rw binding-ipv6info union 417 | | +--rw binding-ipv4-addr? 418 | | | inet:ipv4-address 419 | | +--rw port-set 420 | | | +--rw psid-offset? uint8 421 | | | +--rw psid-len uint8 422 | | | +--rw psid uint16 423 | | +--rw br-ipv6-addr? 424 | | inet:ipv6-address 425 | +--rw icmp-policy 426 | | +--rw icmpv4-errors 427 | | | +--rw allow-incoming-icmpv4? boolean 428 | | | +--rw icmpv4-rate? uint32 429 | | | +--rw generate-icmpv4-errors? boolean 430 | | +--rw icmpv6-errors 431 | | +--rw generate-icmpv6-errors? boolean 432 | | +--rw icmpv6-rate? uint32 433 | +--ro traffic-stat 434 | +--ro discontinuity-time yang:date-and-time 435 | +--ro sent-ipv4-packets? 436 | | yang:zero-based-counter64 437 | +--ro sent-ipv4-bytes? 438 | | yang:zero-based-counter64 439 | +--ro sent-ipv6-packets? 440 | | yang:zero-based-counter64 441 | +--ro sent-ipv6-bytes? 442 | | yang:zero-based-counter64 443 | +--ro rcvd-ipv4-packets? 444 | | yang:zero-based-counter64 445 | +--ro rcvd-ipv4-bytes? 446 | | yang:zero-based-counter64 447 | +--ro rcvd-ipv6-packets? 448 | | yang:zero-based-counter64 449 | +--ro rcvd-ipv6-bytes? 450 | | yang:zero-based-counter64 451 | +--ro dropped-ipv4-packets? 452 | | yang:zero-based-counter64 453 | +--ro dropped-ipv4-bytes? 454 | | yang:zero-based-counter64 455 | +--ro dropped-ipv6-packets? 456 | | yang:zero-based-counter64 457 | +--ro dropped-ipv6-bytes? 458 | | yang:zero-based-counter64 459 | +--ro dropped-ipv4-fragments? 460 | | yang:zero-based-counter64 461 | +--ro dropped-ipv4-fragment-bytes? 462 | | yang:zero-based-counter64 463 | +--ro ipv6-fragments-reassembled? 464 | | yang:zero-based-counter64 465 | +--ro ipv6-fragments-bytes-reassembled? 466 | | yang:zero-based-counter64 467 | +--ro out-icmpv4-error-packets? 468 | | yang:zero-based-counter64 469 | +--ro out-icmpv4-error-bytes? 470 | | yang:zero-based-counter64 471 | +--ro out-icmpv6-error-packets? 472 | | yang:zero-based-counter64 473 | +--ro out-icmpv6-error-bytes? 474 | | yang:zero-based-counter64 475 | +--ro dropped-icmpv4-packets? 476 | | yang:zero-based-counter64 477 | +--ro dropped-icmpv4-bytes? 478 | | yang:zero-based-counter64 479 | +--ro hairpin-ipv4-packets? 480 | | yang:zero-based-counter64 481 | +--ro hairpin-ipv4-bytes? 482 | | yang:zero-based-counter64 483 | +--ro active-softwire-num? 484 | uint32 485 +--:(algo) {map-e or map-t}? 486 +--rw algorithm 487 +--rw algo-instance* [name] 488 +--rw name string 489 +--rw enable? boolean 490 +--rw algo-versioning 491 | +--rw version? uint64 492 | +--rw date? yang:date-and-time 493 +--rw (data-plane)? 494 | +--:(encapsulation) {map-e}? 495 | | +--rw br-ipv6-addr inet:ipv6-address 496 | +--:(translation) {map-t}? 497 | +--rw dmr-ipv6-prefix? inet:ipv6-prefix 498 +--rw ea-len uint8 499 +--rw rule-ipv6-prefix inet:ipv6-prefix 500 +--rw rule-ipv4-prefix inet:ipv4-prefix 501 +--rw forwarding boolean 502 +--rw port-set 503 | +--rw psid-offset? uint8 504 | +--rw psid-len uint8 505 | +--rw psid uint16 506 +--ro traffic-stat 507 +--ro discontinuity-time yang:date-and-time 508 +--ro sent-ipv4-packets? 509 | yang:zero-based-counter64 510 +--ro sent-ipv4-bytes? 511 | yang:zero-based-counter64 512 +--ro sent-ipv6-packets? 513 | yang:zero-based-counter64 514 +--ro sent-ipv6-bytes? 515 | yang:zero-based-counter64 516 +--ro rcvd-ipv4-packets? 517 | yang:zero-based-counter64 518 +--ro rcvd-ipv4-bytes? 519 | yang:zero-based-counter64 520 +--ro rcvd-ipv6-packets? 521 | yang:zero-based-counter64 522 +--ro rcvd-ipv6-bytes? 523 | yang:zero-based-counter64 524 +--ro dropped-ipv4-packets? 525 | yang:zero-based-counter64 526 +--ro dropped-ipv4-bytes? 527 | yang:zero-based-counter64 528 +--ro dropped-ipv6-packets? 529 | yang:zero-based-counter64 530 +--ro dropped-ipv6-bytes? 531 | yang:zero-based-counter64 532 +--ro dropped-ipv4-fragments? 533 | yang:zero-based-counter64 534 +--ro dropped-ipv4-fragment-bytes? 535 | yang:zero-based-counter64 536 +--ro ipv6-fragments-reassembled? 537 | yang:zero-based-counter64 538 +--ro ipv6-fragments-bytes-reassembled? 539 | yang:zero-based-counter64 540 +--ro out-icmpv4-error-packets? 541 | yang:zero-based-counter64 542 +--ro out-icmpv4-error-bytes? 543 | yang:zero-based-counter64 544 +--ro out-icmpv6-error-packets? 545 | yang:zero-based-counter64 546 +--ro out-icmpv6-error-bytes? 547 yang:zero-based-counter64 549 notifications: 550 +---n softwire-binding-instance-event {binding-mode}? 551 | +--ro bind-name? 552 | | -> /br-instances/binding/bind-instance/name 553 | +--ro invalid-entry* leafref 554 | +--ro added-entry* inet:ipv6-address 555 | +--ro modified-entry* leafref 556 +---n softwire-algorithm-instance-event {map-e, map-t}? 557 +--ro algo-name 558 | -> /br-instances/algorithm/algo-instance/name 559 +--ro invalid-entry-id* 560 | -> /br-instances/algorithm/algo-instance/name 561 +--ro added-entry* 562 | -> /br-instances/algorithm/algo-instance/name 563 +--ro modified-entry* 564 -> /br-instances/algorithm/algo-instance/name 566 Figure 2: Softwire BR YANG Tree 568 5.2. Softwire BR Tree Diagram Description 570 The descriptions for leaves which are common with the CE module are 571 provided in Section 4.2. Descriptions for additional elements are 572 provided below: 574 o binding-table-versioning: optionally used to associate a version 575 number and/or timestamp to the binding table. This can be used 576 for logging or data retention purposes [RFC7422]. The version 577 number is selected to uniquely identify the binding table 578 configuration and a new timestamp value written whenever a change 579 is made to the contents of the binding table or a new binding 580 table list is created. 582 o binding-entry: used to define the binding relationship between 583 3-tuples {lwB4's IPv6 address/prefix, the allocated IPv4 address, 584 restricted port-set}. For detail information, please refer to 585 [RFC7596]. 587 o softwire-num-max: used to set the maximum number of softwire 588 binding rules that can be created on the lw4o6 element 589 simultaneously. This paramter must not be set to zero because 590 this is equivalent to disabling the BR instance. 592 o active-softwire-num: holds the number of softwires currently 593 provisioned on the BR element. 595 Additional information on some of the important notification nodes is 596 listed below: 598 o invalid-entry, added-entry, modified-entry: used to notify the 599 NETCONF client that a specific binding entry or MAP rule has 600 expired, been invalidated, added, or modified. 602 6. Softwire CE YANG Module 604 This module imports the modules defined in [RFC6991], [RFC8343], and 605 [RFC7224]. It also imports the 'ietf-softwire-common' and 'iana- 606 tunnel-type' modules [I-D.ietf-softwire-iftunnel]. 608 file "ietf-softwire-ce@2018-11-30.yang" 610 module ietf-softwire-ce { 611 yang-version 1.1; 612 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-ce"; 613 prefix softwire-ce; 615 import ietf-inet-types { 616 prefix inet; 617 reference "Section 4 of RFC 6991"; 618 } 619 import ietf-interfaces { 620 prefix if; 621 reference "RFC 8343: A YANG Data Model for Interface Management"; 622 } 623 import ietf-softwire-common { 624 prefix softwire-common; 625 reference 626 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 627 Softwires"; 628 } 629 import iana-tunnel-type { 630 prefix iana-tunnel-type; 631 reference 632 "RFC YYYY: Tunnel Interface Types YANG Module"; 633 } 635 organization 636 "IETF Softwire Working Group"; 637 contact 638 "WG Web: 639 WG List: 641 Author: Qi Sun 642 644 Author: Linhui Sun 645 647 Author: Yong Cui 648 650 Editor: Ian Farrer 651 653 Author: Sladjana Zoric 654 656 Editor: Mohamed Boucadair 657 659 Author: Rajiv Asati 660 "; 661 description 662 "This document defines a YANG module for the configuration and 663 management of A+P Softwire Customer Premises Equipment (CEs). It 664 covers Lightweight 4over6, MAP-E, and MAP-T mechanisms. 666 Copyright (c) 2018 IETF Trust and the persons identified as 667 authors of the code. All rights reserved. 669 Redistribution and use in source and binary forms, with or 670 without modification, is permitted pursuant to, and subject 671 to the license terms contained in, the Simplified BSD License 672 set forth in Section 4.c of the IETF Trust's Legal Provisions 673 Relating to IETF Documents 674 (http://trustee.ietf.org/license-info). 676 This version of this YANG module is part of RFC XXXX; see 677 the RFC itself for full legal notices."; 679 revision 2018-10-23 { 680 description 681 "Initial revision."; 682 reference 683 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 684 Softwires"; 685 } 687 /* 688 * Features 689 */ 691 feature binding-mode { 692 description 693 "Binding is used for configuring the Lightweight 4over6 mechanism. 695 Binding based softwire mechanisms are IPv4-over-IPv6 tunnelling 696 transition mechanisms specifically intended for complete 697 independence between the IPv6 subnet prefix (and IPv6 address) 698 and IPv4 address, with or without IPv4 address sharing. 700 This is accomplished by maintaining state for each softwire 701 (per-subscriber state) in the central Border Relay (BR) and using 702 a hub-and-spoke forwarding architecture. In order to delegate the 703 NAPT function and achieve IPv4 address sharing, port-restricted 704 IPv4 addresses needs to be allocated to CEs. 706 This feature indicates that the network element can function as 707 one or more binding based softwire instances."; 708 reference 709 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack Lite 710 Architecture 711 RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 712 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 713 } 715 feature map-e { 716 description 717 "MAP-E is an IPv6 transition mechanism for transporting IPv4 718 packets across an IPv6 network using IP encapsulation. MAP-E 719 allows for a reduction of the amount of centralized state using 720 rules to express IPv4/IPv6 address mappings. This introduces an 721 algorithmic relationship between the IPv6 subnet and IPv4 722 address. 724 This feature indicates that the network element can function as 725 one or more MAP-E softwire instances."; 726 reference 727 "RFC7597: Mapping of Address and Port with Encapsulation (MAP-E)"; 728 } 730 feature map-t { 731 description 732 "MAP-T is an IPv6 transition mechanism for transporting IPv4 733 packets across an IPv6 network using IP translation. It leverages 734 a double stateless NAT64 based solution as well as the stateless 735 algorithmic address & transport layer port mapping algorithm 736 defined for MAP-E. 738 This feature indicates that the network element can function as 739 one or more MAP-T softwire instances."; 740 reference 741 "RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 742 } 744 // Binding Entry 746 grouping binding-entry { 747 description 748 "The binding BR (Border Relay) maintains an address binding table 749 that contains the binding between the CE's IPv6 address, 750 the allocated IPv4 address and restricted port-set."; 751 leaf binding-ipv6info { 752 type union { 753 type inet:ipv6-address; 754 type inet:ipv6-prefix; 755 } 756 description 757 "The IPv6 information for a binding entry. 759 When the IPv6 prefix type is used, 760 the IPv6 source address of the CE is constructed 761 according to the description in RFC7596. 763 If the IPv6 address type is used, the CE can use 764 any valid /128 address from a prefix assigned to 765 the CE."; 766 reference "Section 5.1 of RFC7596."; 767 } 768 leaf br-ipv6-addr { 769 type inet:ipv6-address; 770 mandatory true; 771 description 772 "The IPv6 address of the binding BR."; 773 } 774 } 776 // configuration and stateful parameters for softwire CE interface 778 augment "/if:interfaces/if:interface" { 779 when "derived-from(if:type, 'iana-tunnel-type:aplusp')"; 780 description 781 "Softwire CE interface configuration"; 782 leaf softwire-payload-mtu { 783 type uint16; 784 units "bytes"; 785 description 786 "The payload IPv4 MTU for the softwire tunnel."; 787 } 788 leaf softwire-path-mru { 789 type uint16; 790 units "bytes"; 791 description 792 "The path MRU for the softwire (payload + encapsulation 793 overhead)."; 794 reference 795 "RFC 4213: Basic Transition Mechanisms for IPv6 Hosts and 796 Routers"; 797 } 798 choice ce-type { 799 description 800 "Sets the softwire CE mechanism"; 801 case binding { 802 if-feature "binding-mode"; 803 description 804 "CE binding configuration"; 805 uses binding-entry; 806 } 807 case algo { 808 if-feature "map-e or map-t"; 809 description 810 "CE algorithm configuration"; 811 container algo-instances { 812 description 813 "Collection of MAP-E/MAP-T parameters"; 814 list algo-instance { 815 key "name"; 816 description 817 "MAP forwarding rule instance for 818 MAP-E/MAP-T"; 819 leaf name { 820 type string; 821 mandatory true; 822 description 823 "The name is used to uniquely identify an algorithm 824 instance. 826 This name can be automatically assigned 827 or explicitly configured."; 828 } 829 uses softwire-common:algorithm-instance; 830 } 831 } 832 } 833 } 834 } 835 augment "/if:interfaces/if:interface/if:statistics" { 836 when "derived-from(../if:type, 'iana-tunnel-type:aplusp')"; 837 description 838 "Softwire CE interface statistics."; 839 uses softwire-common:traffic-stat; 840 } 842 /* 843 * Notifications 844 */ 846 notification softwire-ce-event { 847 if-feature "binding-mode"; 848 description 849 "CE notification"; 850 leaf ce-binding-ipv6-addr-change { 851 type inet:ipv6-address; 852 mandatory true; 853 description 854 "This notification is generated whenever the CE's binding IPv6 855 address changes for any reason."; 857 } 858 } 859 } 860 862 7. BR Softwire YANG Module 864 This module imports typedefs from [RFC6991]. It also imports the 865 'ietf-softwire-common' module. 867 file "ietf-softwire-br@2018-10-23.yang" 869 module ietf-softwire-br { 870 yang-version 1.1; 871 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-br"; 872 prefix softwire-br; 874 import ietf-inet-types { 875 prefix inet; 876 reference "Section 4 of RFC 6991"; 877 } 878 import ietf-yang-types { 879 prefix yang; 880 reference "Section 3 of RFC 6991"; 881 } 882 import ietf-softwire-common { 883 prefix softwire-common; 884 reference 885 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 886 Softwires"; 887 } 889 organization 890 "IETF Softwire Working Group"; 891 contact 892 "WG Web: 893 WG List: 895 Author: Qi Sun 896 898 Author: Linhui Sun 899 901 Author: Yong Cui 902 904 Editor: Ian Farrer 905 907 Author: Sladjana Zoric 908 910 Editor: Mohamed Boucadair 911 913 Author: Rajiv Asati 914 "; 916 description 917 "This document defines a YANG module for the configuration and 918 management of A+P Softwire Border Routers. It covers Lightweight 919 4over6, MAP-E, and MAP-T mechanisms. 921 Copyright (c) 2018 IETF Trust and the persons identified as 922 authors of the code. All rights reserved. 924 Redistribution and use in source and binary forms, with or 925 without modification, is permitted pursuant to, and subject 926 to the license terms contained in, the Simplified BSD License 927 set forth in Section 4.c of the IETF Trust's Legal Provisions 928 Relating to IETF Documents 929 (http://trustee.ietf.org/license-info). 931 This version of this YANG module is part of RFC XXXX; see 932 the RFC itself for full legal notices."; 934 revision 2018-10-23 { 935 description 936 "Initial revision."; 937 reference 938 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 939 Softwires"; 940 } 942 /* 943 * Groupings 944 */ 946 grouping port-set { 947 description 948 "Describes a set of layer 4 port numbers. 950 This may be a simple port range, or use the Port Set 951 Identifier (PSID) algorithm to represent a range of transport 952 layer ports which will be used by a NAPT."; 954 leaf psid-offset { 955 type uint8 { 956 range "0..16"; 957 } 958 description 959 "The number of offset bits. In Lightweight 4over6, 960 the default value is 0 for assigning one contiguous 961 port range. In MAP-E/T, the default value is 6, 962 which means the system ports (0-1023) are excluded by 963 default and the assigned port ranges are distributed across 964 the entire port space, depending on either psid-len or the 965 number of contiguous ports."; 966 } 967 leaf psid-len { 968 type uint8 { 969 range "0..15"; 970 } 971 mandatory true; 972 description 973 "The length of PSID, representing the sharing 974 ratio for an IPv4 address. This, along with ea-len, can 975 be used to calculate the number of contiguous ports per 976 port range"; 977 } 978 leaf psid { 979 type uint16; 980 mandatory true; 981 description 982 "Port Set Identifier (PSID) value, which 983 identifies a set of ports algorithmically."; 984 } 985 } 987 grouping binding-entry { 988 description 989 "The binding BR maintains an address binding table that 990 contains the binding between the CE's IPv6 address, 991 the allocated IPv4 address and restricted port-set."; 992 leaf binding-ipv6info { 993 type union { 994 type inet:ipv6-address; 995 type inet:ipv6-prefix; 996 } 997 description 998 "The IPv6 information for a CE binding entry. 999 When the IPv6 prefix type is used, 1000 the IPv6 source address of the CE is constructed 1001 according to the description in RFC7596; 1002 if the IPv6 address type is used, the CE can use 1003 any valid /128 address from a prefix assigned to 1004 the CE."; 1005 reference 1006 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack 1007 Lite Architecture"; 1008 } 1009 leaf binding-ipv4-addr { 1010 type inet:ipv4-address; 1011 description 1012 "The IPv4 address assigned to the binding CE, 1013 which is used as the IPv4 external address 1014 for binding CE local NAPT44."; 1015 } 1016 container port-set { 1017 description 1018 "For Lightweight 4over6, the default value 1019 for offset should be 0, to configure one contiguous 1020 port range."; 1021 uses port-set { 1022 refine "psid-offset" { 1023 default "0"; 1024 } 1025 } 1026 } 1027 leaf br-ipv6-addr { 1028 type inet:ipv6-address; 1029 description 1030 "The IPv6 address for binding BR."; 1031 } 1032 } 1034 /* 1035 * Features 1036 */ 1038 feature binding-mode { 1039 description 1040 "Binding is used for configuring the Lightweight 4over6 mechanism. 1042 Binding based softwire mechanisms are IPv4-over-IPv6 tunnelling 1043 transition mechanisms specifically intended for complete 1044 independence between the IPv6 subnet prefix (and IPv6 address) 1045 and IPv4 address, with or without IPv4 address sharing. 1047 This is accomplished by maintaining state for each softwire 1048 (per-subscriber state) in the central Border Relay (BR) and using 1049 a hub-and-spoke forwarding architecture. In order to delegate the 1050 NAPT function and achieve IPv4 address sharing, port-restricted 1051 IPv4 addresses needs to be allocated to CEs. 1053 This feature indicates that the network element can function as 1054 one or more binding based softwire instances."; 1055 reference 1056 "RFC7596: Lightweight 4over6: An Extension to the Dual-Stack Lite 1057 Architecture 1058 RFC7597: Mapping of Address and Port with Encapsulation (MAP-E) 1059 RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 1060 } 1062 feature map-e { 1063 description 1064 "MAP-E is an IPv6 transition mechanism for transporting IPv4 1065 packets across an IPv6 network using IP encapsulation. MAP-E 1066 allows for a reduction of the amount of centralized state using 1067 rules to express IPv4/IPv6 address mappings. This introduces an 1068 algorithmic relationship between the IPv6 subnet and IPv4 1069 address. 1071 This feature indicates that the network element can function as 1072 one or more MAP-E softwire instances."; 1073 reference 1074 "RFC7597: Mapping of Address and Port with Encapsulation (MAP-E)"; 1075 } 1077 feature map-t { 1078 description 1079 "MAP-T is an IPv6 transition mechanism for transporting IPv4 1080 packets across an IPv6 network using IP translation. It leverages 1081 a double stateless NAT64 based solution as well as the stateless 1082 algorithmic address & transport layer port mapping algorithm 1083 defined for MAP-E. 1085 This feature indicates that the network element can function as 1086 one or more MAP-T softwire instances."; 1087 reference 1088 "RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 1089 } 1091 container br-instances { 1092 description 1093 "BR instances enabled in a network element."; 1094 choice br-type { 1095 description 1096 "Select binding or algorithmic BR functionality."; 1097 case binding { 1098 if-feature "binding-mode"; 1099 container binding { 1100 description 1101 "binding mechanism (binding table) configuration."; 1102 list bind-instance { 1103 key "name"; 1104 description 1105 "A set of binding instances to be configured."; 1106 leaf name { 1107 type string; 1108 mandatory true; 1109 description 1110 "The name for the binding BR. It is used to uniquely 1111 distinguish a binding instance by its name."; 1112 } 1113 container binding-table-versioning { 1114 description 1115 "binding table's version"; 1116 leaf version { 1117 type uint64; 1118 description 1119 "Timestamp when the binding table was activated. 1121 A binding instance may be provided with binding 1122 entries that may change in time (e.g., increase 1123 the size of the port set). When an abuse party 1124 presents an external IP address/port, the version 1125 of the binding table is important because, depending 1126 on the version, a distinct customer may be 1127 identified. 1129 The timestamp is used as a key to find the 1130 appropriate binding table that was put into effect 1131 when an abuse occurred. "; 1132 } 1133 leaf date { 1134 type yang:date-and-time; 1135 description 1136 "Timestamp of the binding table"; 1137 reference 1138 "RFC7422: Deterministic Address Mapping to Reduce 1139 Logging in Carrier-Grade NAT Deployments"; 1140 } 1141 } 1142 leaf softwire-num-max { 1143 type uint32 { 1144 range "1..max"; 1145 } 1146 mandatory true; 1147 description 1148 "The maximum number of softwires that can be created 1149 on the binding BR."; 1150 } 1151 leaf softwire-payload-mtu { 1152 type uint16; 1153 units "bytes"; 1154 mandatory true; 1155 description 1156 "The payload IPv4 MTU for binding softwire."; 1157 } 1158 leaf softwire-path-mru { 1159 type uint16; 1160 units "bytes"; 1161 mandatory true; 1162 description 1163 "The path MRU for binding softwire."; 1164 reference 1165 "RFC4213: Basic Transition Mechanisms for IPv6 Hosts 1166 and Routers"; 1167 } 1168 leaf enable-hairpinning { 1169 type boolean; 1170 default "true"; 1171 description 1172 "Enables/disables support for locally forwarding 1173 (hairpinning) traffic between two CEs."; 1174 reference "Section 6.2 of RFC7596"; 1175 } 1176 container binding-table { 1177 description 1178 "binding table"; 1179 list binding-entry { 1180 key "binding-ipv6info"; 1181 description 1182 "binding entry"; 1183 uses binding-entry; 1184 } 1185 } 1186 container icmp-policy { 1187 description 1188 "The binding BR can be configured to process or drop 1189 incoming ICMP messages, and to generate outgoing ICMP 1190 error messages."; 1191 container icmpv4-errors { 1192 description 1193 "ICMPv4 error processing configuration"; 1195 leaf allow-incoming-icmpv4 { 1196 type boolean; 1197 default "true"; 1198 description 1199 "Enables the processing of incoming ICMPv4 1200 packets."; 1201 reference 1202 "RFC7596: Lightweight 4over6: An Extension to 1203 the Dual-Stack Lite Architecture"; 1204 } 1205 leaf icmpv4-rate { 1206 type uint32; 1207 description 1208 "Rate limit threshold in messages per-second 1209 for processing incoming ICMPv4 errors messages"; 1210 } 1211 leaf generate-icmpv4-errors { 1212 type boolean; 1213 default "true"; 1214 description 1215 "Enables the generation of outgoing ICMPv4 error 1216 messages on receipt of an inbound IPv4 packet 1217 with no matching binding table entry."; 1218 reference "Seciton 5.2 of RFC7596."; 1219 } 1220 } 1221 container icmpv6-errors { 1222 description 1223 "ICMPv6 error processing configuration"; 1224 leaf generate-icmpv6-errors { 1225 type boolean; 1226 default "true"; 1227 description 1228 "Enables the generation of ICMPv6 error messages if 1229 no matching binding table entry is found for a 1230 received packet."; 1231 reference "Section 6.2 of RFC7596."; 1232 } 1233 leaf icmpv6-rate { 1234 type uint32; 1235 description 1236 "Rate limit threshold in messages per-second 1237 for sending ICMPv6 errors messages"; 1238 reference "Section 9 of RFC7596."; 1239 } 1240 } 1241 } 1242 container traffic-stat { 1243 config false; 1244 description 1245 "Traffic statistics information for the BR."; 1246 leaf discontinuity-time { 1247 type yang:date-and-time; 1248 mandatory true; 1249 description 1250 "The time of the most recent occasion on which the BR 1251 instance suffered a discontinuity. This must be 1252 initialized when the BR instance is configured 1253 or rebooted."; 1254 } 1255 uses softwire-common:traffic-stat; 1256 leaf dropped-icmpv4-packets { 1257 type yang:zero-based-counter64; 1258 description 1259 "ICMPv4 packets that are dropped as a result 1260 of the ICMP policy. Typically, this can be any 1261 incoming ICMPv4 packets if ICMPv4 processing is 1262 disabled or incoming ICMPv4 packets that exceed 1263 the ICMPv4 rate-limit threshold. 1265 Discontinuities in the value of this counter can 1266 occur at re-initialization of the management 1267 system, and at other times as indicated by 1268 the value of 'discontinuity-time'."; 1269 } 1270 leaf dropped-icmpv4-bytes { 1271 type yang:zero-based-counter64; 1272 description 1273 "ICMPv4 messages, in bytes, that are dropped as 1274 a result of the ICMP policy. Typically, it 1275 can be any incoming ICMPv4 packets if ICMPv4 1276 processing is disabled or incoming ICMPv4 1277 packets that exceed the ICMPv4 rate-limit 1278 threshold. 1280 Discontinuities in the value of this counter can 1281 occur at re-initialization of the management 1282 system, and at other times as indicated by 1283 the value of 'discontinuity-time'."; 1284 } 1285 leaf hairpin-ipv4-packets { 1286 type yang:zero-based-counter64; 1287 description 1288 "IPv4 packets locally routed between two CEs 1289 (hairpinned). 1291 Discontinuities in the value of this counter can 1292 occur at re-initialization of the management 1293 system, and at other times as indicated by 1294 the value of 'discontinuity-time'."; 1295 } 1296 leaf hairpin-ipv4-bytes { 1297 type yang:zero-based-counter64; 1298 description 1299 "IPv4 bytes locally routed between two CEs 1300 (hairpinned). 1302 Discontinuities in the value of this counter can 1303 occur at re-initialization of the management 1304 system, and at other times as indicated by 1305 the value of 'discontinuity-time'."; 1306 } 1307 leaf active-softwire-num { 1308 type uint32; 1309 config false; 1310 description 1311 "The number of currently active softwires on the 1312 binding instance. 1314 Discontinuities in the value of this counter can 1315 occur at re-initialization of the management 1316 system, and at other times as indicated by 1317 the value of 'discontinuity-time'."; 1318 } 1319 } 1320 } 1321 } 1322 } 1323 case algo { 1324 if-feature "map-e or map-t"; 1325 container algorithm { 1326 description 1327 " A set of parameters used for MAP-E/MAP-T."; 1328 list algo-instance { 1329 key "name"; 1330 description 1331 "Instances of algorithm"; 1332 leaf name { 1333 type string; 1334 mandatory true; 1335 description 1336 "The name is used to uniquely identify an algorithm 1337 instance. 1339 This name can be automatically assigned 1340 or explicitly configured."; 1341 } 1342 uses softwire-common:algorithm-instance; 1343 container port-set { 1344 description 1345 "Indicates a set of ports."; 1346 uses port-set; 1347 } 1348 container traffic-stat { 1349 config false; 1350 description 1351 "Traffic statistics information for the BR."; 1352 leaf discontinuity-time { 1353 type yang:date-and-time; 1354 mandatory true; 1355 description 1356 "The time of the most recent occasion on which the BR 1357 instance suffered a discontinuity. This must be 1358 reset to the current date-and-time when the BR 1359 instance is configured or rebooted."; 1360 } 1361 uses softwire-common:traffic-stat; 1362 } 1363 } 1364 } 1365 } 1366 } 1367 } 1369 /* 1370 * Notifications 1371 */ 1373 notification softwire-binding-instance-event { 1374 if-feature "binding-mode"; 1375 description 1376 "Notifications for binding instance when an entry is 1377 added, modified, or is not valid anymore."; 1378 leaf bind-name { 1379 type leafref { 1380 path "/br-instances/binding/bind-instance/name"; 1381 } 1382 description 1383 "The name of the binding-instance that 1384 generated the notification."; 1385 } 1386 leaf-list invalid-entry { 1387 type leafref { 1388 path 1389 "/br-instances/binding/" 1390 + "bind-instance[name=current()/../bind-name]/" 1391 + "binding-table/binding-entry/binding-ipv6info"; 1392 } 1393 description 1394 "Notify the client that a specific binding entry has 1395 expired or is invalid. The binding-ipv6info identifies 1396 an entry."; 1397 } 1398 leaf-list added-entry { 1399 type inet:ipv6-address; 1400 description 1401 "Notify the client that a binding entry has been added. 1402 The ipv6 address of that entry is the index. The client 1403 gets other information from the binding BR about the entry 1404 indexed by that ipv6 address."; 1405 } 1406 leaf-list modified-entry { 1407 type leafref { 1408 path 1409 "/br-instances/binding/" 1410 + "bind-instance[name=current()/../bind-name]/" 1411 + "binding-table/binding-entry/binding-ipv6info"; 1412 } 1413 description 1414 "The binding-table entry that has been modified."; 1415 } 1416 } 1417 notification softwire-algorithm-instance-event { 1418 if-feature "map-e or map-t"; 1419 description 1420 "Notifications for algorithm instance when an entry is 1421 added, modified, or is not valid anymore."; 1422 leaf algo-name { 1423 type leafref { 1424 path "/br-instances/algorithm/algo-instance/name"; 1425 } 1426 mandatory true; 1427 description 1428 "algorithmic instance event."; 1429 } 1430 leaf-list invalid-entry { 1431 type leafref { 1432 path "/br-instances/algorithm/algo-instance/name"; 1433 } 1434 description 1435 "Invalid entry event."; 1436 } 1437 leaf-list added-entry { 1438 type leafref { 1439 path "/br-instances/algorithm/algo-instance/name"; 1440 } 1441 description 1442 "Added entry."; 1443 } 1444 leaf-list modified-entry { 1445 type leafref { 1446 path "/br-instances/algorithm/algo-instance/name"; 1447 } 1448 description 1449 "Modified entry."; 1450 } 1451 } 1452 } 1453 1455 8. Common Softwire Element Groups YANG Module 1457 This module imports typedefs from [RFC6991]. 1459 The following YANG module contains definitions that are used by both 1460 the softwire CE and softwire BR YANG modules. 1462 file "ietf-softwire-common@2018-10-23.yang" 1464 module ietf-softwire-common { 1465 yang-version 1.1; 1466 namespace "urn:ietf:params:xml:ns:yang:ietf-softwire-common"; 1467 prefix softwire-common; 1469 import ietf-inet-types { 1470 prefix inet; 1471 reference "Section 4 of RFC 6991"; 1472 } 1473 import ietf-yang-types { 1474 prefix yang; 1475 reference "Section 3 of RFC 6991"; 1476 } 1478 organization 1479 "IETF Softwire Working Group"; 1480 contact 1481 "WG Web: 1482 WG List: 1483 Author: Qi Sun 1484 1486 Author: Linhui Sun 1487 1489 Author: Yong Cui 1490 1492 Editor: Ian Farrer 1493 1495 Author: Sladjana Zoric 1496 1498 Editor: Mohamed Boucadair 1499 1501 Author: Rajiv Asati 1502 "; 1503 description 1504 "This document defines a YANG module defining types 1505 common to all A+P modules. 1507 Copyright (c) 2018 IETF Trust and the persons identified as 1508 authors of the code. All rights reserved. 1510 Redistribution and use in source and binary forms, with or 1511 without modification, is permitted pursuant to, and subject 1512 to the license terms contained in, the Simplified BSD License 1513 set forth in Section 4.c of the IETF Trust's Legal Provisions 1514 Relating to IETF Documents 1515 (http://trustee.ietf.org/license-info). 1517 This version of this YANG module is part of RFC XXXX; see 1518 the RFC itself for full legal notices."; 1520 revision 2018-10-23 { 1521 description 1522 "Initial revision."; 1523 reference 1524 "RFC XXXX: YANG Modules for IPv4-in-IPv6 Address plus Port 1525 Softwires"; 1526 } 1528 feature map-e { 1529 description 1530 "MAP-E is an IPv6 transition mechanism for transporting IPv4 1531 packets across an IPv6 network using IP encapsulation. MAP-E 1532 allows for a reduction of the amount of centralized state using 1533 rules to express IPv4/IPv6 address mappings. This introduces an 1534 algorithmic relationship between the IPv6 subnet and IPv4 1535 address. 1537 This feature indicates that the network element can function as 1538 one or more MAP-E softwire instances."; 1539 reference 1540 "RFC7597: Mapping of Address and Port with Encapsulation (MAP-E)"; 1541 } 1543 feature map-t { 1544 description 1545 "MAP-T is an IPv6 transition mechanism for transporting IPv4 1546 packets across an IPv6 network using IP translation. It leverages 1547 a double stateless NAT64 based solution as well as the stateless 1548 algorithmic address & transport layer port mapping algorithm 1549 defined for MAP-E. 1551 This feature indicates that the network element can function as 1552 one or more MAP-T softwire instances."; 1553 reference 1554 "RFC7599: Mapping of Address and Port using Translation (MAP-T)"; 1555 } 1557 /* 1558 * Groupings 1559 */ 1561 grouping algorithm-instance { 1562 description 1563 "A collection of parameters that is used fro MAP-E/MAP-T."; 1564 leaf enable { 1565 type boolean; 1566 description 1567 "Enable/disable an individual MAP-E or MAP-T rule."; 1568 } 1569 container algo-versioning { 1570 description 1571 "Version number for this algorithm instance"; 1572 leaf version { 1573 type uint64; 1574 description 1575 "A version number for the mapping algorithm 1576 rules provided to the algorithm instance"; 1577 } 1578 leaf date { 1579 type yang:date-and-time; 1580 description 1581 "Timestamp when the algorithm instance was activated. 1583 An algorithm instance may be provided with mapping 1584 rules that may change in time (for example, increase 1585 the size of the port set). When an abuse party 1586 presents an external IP address/port, the version 1587 of the algorithm is important because depending on 1588 the version, a distinct customer may be identified. 1590 The timestamp is used as a key to find the appropriate 1591 algorithm that was put into effect when an abuse 1592 occurred. "; 1593 reference 1594 "RFC7422: Deterministic Address Mapping to Reduce 1595 Logging in Carrier-Grade NAT Deployments"; 1596 } 1597 } 1598 choice data-plane { 1599 description 1600 "Selects MAP-E (encapsulation) or MAP-T 1601 (translation)"; 1602 case encapsulation { 1603 if-feature "map-e"; 1604 description 1605 "encapsulation for MAP-E"; 1606 leaf br-ipv6-addr { 1607 type inet:ipv6-address; 1608 mandatory true; 1609 description 1610 "The IPv6 address of the MAP-E BR."; 1611 } 1612 } 1613 case translation { 1614 if-feature "map-t"; 1615 description 1616 "translation for MAP-T"; 1617 leaf dmr-ipv6-prefix { 1618 type inet:ipv6-prefix; 1619 description 1620 "The IPv6 prefix of the MAP-T BR."; 1621 } 1622 } 1623 } 1624 leaf ea-len { 1625 type uint8; 1626 mandatory true; 1627 description 1628 "Embedded Address (EA) bits are the IPv4 EA-bits in the IPv6 1629 address identifying an IPv4 prefix/address (or part thereof) 1630 or a shared IPv4 address (or part thereof) and a port-set 1631 identifier. The length of the EA-bits is defined as part of 1632 a MAP rule for a MAP domain."; 1633 } 1634 leaf rule-ipv6-prefix { 1635 type inet:ipv6-prefix; 1636 mandatory true; 1637 description 1638 "The Rule IPv6 prefix defined in the mapping rule."; 1639 } 1640 leaf rule-ipv4-prefix { 1641 type inet:ipv4-prefix; 1642 mandatory true; 1643 description 1644 "The Rule IPv4 prefix defined in the mapping rule."; 1645 } 1646 leaf forwarding { 1647 type boolean; 1648 mandatory true; 1649 description 1650 "This parameter specifies whether the rule may be used for 1651 forwarding (FMR). If set, this rule is used as an FMR; 1652 if not set, this rule is a Basic Mapping Rule (BMR) only 1653 and must not be used for forwarding."; 1654 } 1655 } 1657 grouping traffic-stat { 1658 description 1659 "Traffic statistics"; 1660 leaf sent-ipv4-packets { 1661 type yang:zero-based-counter64; 1662 description 1663 "Number of decapsulated and forwarded IPv4 packets. 1665 Discontinuities in the value of this counter can occur 1666 at re-initialization of the management system, and at 1667 other times as indicated by the value of 1668 'discontinuity-time'."; 1669 } 1670 leaf sent-ipv4-bytes { 1671 type yang:zero-based-counter64; 1672 description 1673 "Decapsulated/translated IPv4 traffic sent, in bytes 1674 Discontinuities in the value of this counter can occur 1675 at re-initialization of the management system, and at 1676 other times as indicated by the value of 1677 'discontinuity-time'."; 1678 } 1679 leaf sent-ipv6-packets { 1680 type yang:zero-based-counter64; 1681 description 1682 "Number of encapsulated IPv6 packets sent. 1684 Discontinuities in the value of this counter can occur 1685 at re-initialization of the management system, and at 1686 other times as indicated by the value of 1687 'discontinuity-time'."; 1688 } 1689 leaf sent-ipv6-bytes { 1690 type yang:zero-based-counter64; 1691 description 1692 "Encapsulated IPv6 traffic sent, in bytes 1694 Discontinuities in the value of this counter can occur 1695 at re-initialization of the management system, and at 1696 other times as indicated by the value of 1697 'discontinuity-time'."; 1698 } 1699 leaf rcvd-ipv4-packets { 1700 type yang:zero-based-counter64; 1701 description 1702 "Number of incoming IPv4 packets at the 1703 Internet-facing interface. 1705 Discontinuities in the value of this counter can occur 1706 at re-initialization of the management system, and at 1707 other times as indicated by the value of 1708 'discontinuity-time'."; 1709 } 1710 leaf rcvd-ipv4-bytes { 1711 type yang:zero-based-counter64; 1712 description 1713 "IPv4 traffic received for processing, in bytes. 1715 Discontinuities in the value of this counter can occur 1716 at re-initialization of the management system, and at 1717 other times as indicated by the value of 1718 'discontinuity-time'."; 1719 } 1720 leaf rcvd-ipv6-packets { 1721 type yang:zero-based-counter64; 1722 description 1723 "Number of IPv4-in-IPv6 packets received. 1725 Discontinuities in the value of this counter can occur 1726 at re-initialization of the management system, and at 1727 other times as indicated by the value of 1728 'discontinuity-time'."; 1729 } 1730 leaf rcvd-ipv6-bytes { 1731 type yang:zero-based-counter64; 1732 description 1733 "IPv4-in-IPv6 traffic received, in bytes. 1735 Discontinuities in the value of this counter can occur 1736 at re-initialization of the management system, and at 1737 other times as indicated by the value of 1738 'discontinuity-time'."; 1739 } 1740 leaf dropped-ipv4-packets { 1741 type yang:zero-based-counter64; 1742 description 1743 "Number of IPv4 packets dropped at the 1744 Internet-facing interface. 1746 Discontinuities in the value of this counter can occur 1747 at re-initialization of the management system, and at 1748 other times as indicated by the value of 1749 'discontinuity-time'."; 1750 } 1751 leaf dropped-ipv4-bytes { 1752 type yang:zero-based-counter64; 1753 description 1754 "IPv4 traffic dropped at the Internet-facing 1755 interface, in bytes. 1757 Discontinuities in the value of this counter can occur 1758 at re-initialization of the management system, and at 1759 other times as indicated by the value of 1760 'discontinuity-time'."; 1761 } 1762 leaf dropped-ipv6-packets { 1763 type yang:zero-based-counter64; 1764 description 1765 "Number of IPv4-in-IPv6 packets dropped. 1767 Discontinuities in the value of this counter can occur 1768 at re-initialization of the management system, and at 1769 other times as indicated by the value of 1770 'discontinuity-time'."; 1771 } 1772 leaf dropped-ipv6-bytes { 1773 type yang:zero-based-counter64; 1774 description 1775 "IPv4-in-IPv6 traffic dropped, in bytes. 1777 Discontinuities in the value of this counter can occur 1778 at re-initialization of the management system, and at 1779 other times as indicated by the value of 1780 'discontinuity-time'."; 1781 } 1782 leaf dropped-ipv4-fragments { 1783 type yang:zero-based-counter64; 1784 description 1785 "Number of fragmented IPv4 packets dropped. 1787 Discontinuities in the value of this counter can occur 1788 at re-initialization of the management system, and at 1789 other times as indicated by the value of 1790 'discontinuity-time'."; 1791 } 1792 leaf dropped-ipv4-fragment-bytes { 1793 type yang:zero-based-counter64; 1794 description 1795 "Fragmented IPv4 traffic dropped, in bytes. 1797 Discontinuities in the value of this counter can occur 1798 at re-initialization of the management system, and at 1799 other times as indicated by the value of 1800 'discontinuity-time'."; 1801 } 1802 leaf ipv6-fragments-reassembled { 1803 type yang:zero-based-counter64; 1804 description 1805 "Number of IPv6 fragments successfully reassembled. 1807 Discontinuities in the value of this counter can occur 1808 at re-initialization of the management system, and at 1809 other times as indicated by the value of 1810 'discontinuity-time'."; 1811 } 1812 leaf ipv6-fragments-bytes-reassembled { 1813 type yang:zero-based-counter64; 1814 description 1815 "IPv6 fragments successfully reassembled, in bytes. 1817 Discontinuities in the value of this counter can occur 1818 at re-initialization of the management system, and at 1819 other times as indicated by the value of 1820 'discontinuity-time'."; 1821 } 1822 leaf out-icmpv4-error-packets { 1823 type yang:zero-based-counter64; 1824 description 1825 "Internally generated ICMPv4 error packets. 1827 Discontinuities in the value of this counter can occur 1828 at re-initialization of the management system, and at 1829 other times as indicated by the value of 1830 'discontinuity-time'."; 1831 } 1832 leaf out-icmpv4-error-bytes { 1833 type yang:zero-based-counter64; 1834 description 1835 "Internally generated ICMPv4 error messages, in bytes. 1837 Discontinuities in the value of this counter can occur 1838 at re-initialization of the management system, and at 1839 other times as indicated by the value of 1840 'discontinuity-time'."; 1841 } 1842 leaf out-icmpv6-error-packets { 1843 type yang:zero-based-counter64; 1844 description 1845 "Internally generated ICMPv6 error packets. 1847 Discontinuities in the value of this counter can occur 1848 at re-initialization of the management system, and at 1849 other times as indicated by the value of 1850 'discontinuity-time'."; 1851 } 1852 leaf out-icmpv6-error-bytes { 1853 type yang:zero-based-counter64; 1854 description 1855 "Internally generated ICMPv6 error messages, in bytes. 1857 Discontinuities in the value of this counter can occur 1858 at re-initialization of the management system, and at 1859 other times as indicated by the value of 1860 'discontinuity-time'."; 1861 } 1862 } 1863 } 1864 1865 9. Security Considerations 1867 The YANG modules defined in this document is designed to be accessed 1868 via network management protocols such as NETCONF [RFC6241] or 1869 RESTCONF [RFC8040]. The lowest NETCONF layer is the secure transport 1870 layer, and the mandatory-to-implement secure transport is Secure 1871 Shell (SSH) [RFC6242]. The lowest RESTCONF layer is HTTPS, and the 1872 mandatory-to-implement secure transport is TLS [RFC8446]. 1874 The NETCONF access control model [RFC8341] provides the means to 1875 restrict access for particular NETCONF or RESTCONF users to a 1876 preconfigured subset of all available NETCONF or RESTCONF protocol 1877 operations and content. 1879 All data nodes defined in the YANG modules which can be created, 1880 modified, and deleted (i.e., config true, which is the default) are 1881 considered sensitive. Write operations (e.g., edit-config) applied 1882 to these data nodes without proper protection can negatively affect 1883 network operations. 1885 10. IANA Considerations 1887 This document requests IANA to assign a new tunnel type under the 1888 "tunnelType" sub-registry of the "ifType definitions" registry 1889 maintained at [TUNNELTYPE-IANA-REGISTRY] and use the following data 1890 for the new entry: 1892 Decimal: TDB1 1893 Name: aplusp 1894 Description: A+P encapsulation 1895 Reference: [RFC6346] 1897 This document requests IANA to register the following URIs in the 1898 "IETF XML Registry" [RFC3688]: 1900 URI: urn:ietf:params:xml:ns:yang:ietf-softwire-ce 1901 Registrant Contact: The IESG. 1902 XML: N/A; the requested URI is an XML namespace. 1904 URI: urn:ietf:params:xml:ns:yang:ietf-softwire-br 1905 Registrant Contact: The IESG. 1906 XML: N/A; the requested URI is an XML namespace. 1908 URI: urn:ietf:params:xml:ns:yang:ietf-softwire-common 1909 Registrant Contact: The IESG. 1910 XML: N/A; the requested URI is an XML namespace. 1912 This document requests that IANA registers the following YANG modules 1913 in the "YANG Module Names" registry [RFC6020]: 1915 name: ietf-softwire-ce 1916 namespace: urn:ietf:params:xml:ns:yang:ietf-softwire-ce 1917 prefix: softwire-ce 1918 reference: RFC XXXX 1920 name: ietf-softwire-br 1921 namespace: urn:ietf:params:xml:ns:yang:ietf-softwire-br 1922 prefix: softwire-br 1923 reference: RFC XXXX 1925 name: ietf-softwire-common 1926 namespace: urn:ietf:params:xml:ns:yang:ietf-softwire-common 1927 prefix: softwire-common 1928 reference: RFC XXXX 1930 11. Acknowledgements 1932 The authors would like to thank Lishan Li, Bert Wijnen, Giles Heron, 1933 Ole Troan, Andy Wingo and Leo Tietz for their contributions to this 1934 work. 1936 Thanks to Sheng Jiang for the review. 1938 Special thanks to Tom Petch and Martin Bjorklund for the detailed 1939 review and suggestions. 1941 12. Contributors 1943 The following individual contributed to this document: 1945 Hao Wang 1946 Tsinghua University 1947 Beijing 100084 1948 P.R.China 1949 Phone: +86-10-6278-5822 1950 Email: wangh13@mails.tsinghua.edu.cn 1952 13. References 1954 13.1. Normative References 1956 [I-D.ietf-softwire-iftunnel] 1957 Boucadair, M., Ed. and I. Farrer, "Tunnel Interface Types 1958 YANG Module", . 1961 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 1962 DOI 10.17487/RFC3688, January 2004, 1963 . 1965 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 1966 the Network Configuration Protocol (NETCONF)", RFC 6020, 1967 DOI 10.17487/RFC6020, October 2010, 1968 . 1970 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 1971 and A. Bierman, Ed., "Network Configuration Protocol 1972 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 1973 . 1975 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 1976 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 1977 . 1979 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 1980 RFC 6991, DOI 10.17487/RFC6991, July 2013, 1981 . 1983 [RFC7224] Bjorklund, M., "IANA Interface Type YANG Module", 1984 RFC 7224, DOI 10.17487/RFC7224, May 2014, 1985 . 1987 [RFC7596] Cui, Y., Sun, Q., Boucadair, M., Tsou, T., Lee, Y., and I. 1988 Farrer, "Lightweight 4over6: An Extension to the Dual- 1989 Stack Lite Architecture", RFC 7596, DOI 10.17487/RFC7596, 1990 July 2015, . 1992 [RFC7597] Troan, O., Ed., Dec, W., Li, X., Bao, C., Matsushima, S., 1993 Murakami, T., and T. Taylor, Ed., "Mapping of Address and 1994 Port with Encapsulation (MAP-E)", RFC 7597, 1995 DOI 10.17487/RFC7597, July 2015, 1996 . 1998 [RFC7598] Mrugalski, T., Troan, O., Farrer, I., Perreault, S., Dec, 1999 W., Bao, C., Yeh, L., and X. Deng, "DHCPv6 Options for 2000 Configuration of Softwire Address and Port-Mapped 2001 Clients", RFC 7598, DOI 10.17487/RFC7598, July 2015, 2002 . 2004 [RFC7599] Li, X., Bao, C., Dec, W., Ed., Troan, O., Matsushima, S., 2005 and T. Murakami, "Mapping of Address and Port using 2006 Translation (MAP-T)", RFC 7599, DOI 10.17487/RFC7599, July 2007 2015, . 2009 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 2010 RFC 7950, DOI 10.17487/RFC7950, August 2016, 2011 . 2013 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 2014 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 2015 . 2017 [RFC8341] Bierman, A. and M. Bjorklund, "Network Configuration 2018 Access Control Model", STD 91, RFC 8341, 2019 DOI 10.17487/RFC8341, March 2018, 2020 . 2022 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 2023 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 2024 . 2026 [RFC8446] Rescorla, E., "The Transport Layer Security (TLS) Protocol 2027 Version 1.3", RFC 8446, DOI 10.17487/RFC8446, August 2018, 2028 . 2030 [TUNNELTYPE-IANA-REGISTRY] 2031 Internet Assigned Numbers Authority, "tunnelType 2032 Definitions", . 2035 13.2. Informative References 2037 [I-D.ietf-opsawg-nat-yang] 2038 Boucadair, M., Sivakumar, S., Jacquenet, C., Vinapamula, 2039 S., and Q. Wu, "A YANG Module for Network Address 2040 Translation (NAT) and Network Prefix Translation (NPT)", 2041 draft-ietf-opsawg-nat-yang-17 (work in progress), 2042 September 2018. 2044 [I-D.ietf-softwire-dslite-yang] 2045 Boucadair, M., Jacquenet, C., and S. Sivakumar, "A YANG 2046 Data Model for Dual-Stack Lite (DS-Lite)", draft-ietf- 2047 softwire-dslite-yang-17 (work in progress), May 2018. 2049 [RFC4213] Nordmark, E. and R. Gilligan, "Basic Transition Mechanisms 2050 for IPv6 Hosts and Routers", RFC 4213, 2051 DOI 10.17487/RFC4213, October 2005, 2052 . 2054 [RFC6333] Durand, A., Droms, R., Woodyatt, J., and Y. Lee, "Dual- 2055 Stack Lite Broadband Deployments Following IPv4 2056 Exhaustion", RFC 6333, DOI 10.17487/RFC6333, August 2011, 2057 . 2059 [RFC6346] Bush, R., Ed., "The Address plus Port (A+P) Approach to 2060 the IPv4 Address Shortage", RFC 6346, 2061 DOI 10.17487/RFC6346, August 2011, 2062 . 2064 [RFC7422] Donley, C., Grundemann, C., Sarawat, V., Sundaresan, K., 2065 and O. Vautrin, "Deterministic Address Mapping to Reduce 2066 Logging in Carrier-Grade NAT Deployments", RFC 7422, 2067 DOI 10.17487/RFC7422, December 2014, 2068 . 2070 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 2071 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 2072 . 2074 [RFC8342] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 2075 and R. Wilton, "Network Management Datastore Architecture 2076 (NMDA)", RFC 8342, DOI 10.17487/RFC8342, March 2018, 2077 . 2079 [RFC8344] Bjorklund, M., "A YANG Data Model for IP Management", 2080 RFC 8344, DOI 10.17487/RFC8344, March 2018, 2081 . 2083 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 2084 Routing Management (NMDA Version)", RFC 8349, 2085 DOI 10.17487/RFC8349, March 2018, 2086 . 2088 Appendix A. Configuration Examples 2090 The following sections provide examples of how the softwire YANG 2091 modules can be used for configuring softwire elements. 2093 A.1. Configuration Example for a lw4o6 BR Binding-Table 2095 The lwAFTR maintains an address binding table which contains the 2096 following 3-tuples: 2098 o IPv6 Address for a single lwB4 2100 o Public IPv4 Address 2101 o Restricted port-set 2103 The entry has two functions: the IPv6 encapsulation of inbound IPv4 2104 packets destined to the lwB4 and the validation of outbound IPv4-in- 2105 IPv6 packets received from the lwB4 for de-capsulation. 2107 Consider an example for the following lw4o6 binding table entry: 2109 lwB4 Binding IPv6 Address: 2001:db8::1 2111 lwB4 Binding IPv4 Address: 192.0.2.1 2113 lwB4 PSID: 0x34 2115 lwB4 PSID Length 8 2117 BR IPv6 Address: 2001:db8:1::2 2119 2120 2121 2122 mybinding-instance 2123 2124 2125 2001:db8::1 2126 192.0.2.1 2127 2128 52 2129 8 2130 2131 2001:db8:1::2 2132 2133 2134 1024 2135 1540 2136 1500 2137 2138 2139 2141 Figure 3: lw4o6 Binding-Table Configuration XML 2143 A.2. Configuration Example for a MAP-E BR 2145 A MAP-E BR is configured with forward mapping rules for the CEs it is 2146 serving. In this example (taken from [RFC7597], Appendix A, Example 2147 2), the following parameters are required: 2149 o Rule IPv6 Prefix 2151 o Rule IPv4 Prefix 2153 o Rule EA-bit bit length 2155 o IPv6 Address of MAP-BR 2157 The mapping rule has two functions: identifying the destination CE 2158 IPv6 address for encapsulating inbound IPv4 packets and the 2159 validation of outbound IPv4-in-IPv6 packets received from the CE for 2160 de-capsulation. 2162 The transport type for the data plane also needs to be configured for 2163 encapsulation to enable MAP-E and forwarding needs to be enabled. 2165 Consider an example for the following MAP-E Forwarding Mapping Rule: 2167 Data plane: encapsulation 2169 Rule IPv6 Prefix: 2001:db8::/40 2171 Rule IPv4 Prefix: 192.0.2.0/24 2173 Rule EA-bit Length: 16 2175 BR IPv6 Address: 2001:db8:ffff::1 2177 Figure 4 provides the example MAP-E BR configuration xml. 2179 2180 2181 2182 myalgo-instance 2183 2184 2001:db8:ffff::1 2185 2186 16 2187 192.0.2.0/24 2188 2001:db8::/40 2189 true 2190 2191 6 2192 8 2193 2194 2195 2196 2198 Figure 4: MAP-E FMR Configuration XML 2200 A.3. lw4o6 CE Configuration Example 2202 This section provides XML examples for configuring a lw4o6 CE. 2203 Examples for routing and NAT44 are also provided for convienience. 2205 Consider an example for the following lw4o6 CE configuration: 2207 lwB4 Binding IPv6 Address: 2001:db8::1 2209 lwB4 Binding IPv4 Address: 192.0.2.1 2211 lwB4 PSID: 0x34 2213 lwB4 PSID Length 8 2215 BR IPv6 Address: 2001:db8:1::2 2216 2217 2218 2219 lw4o6-wan 2220 iana-tunnel-type:aplusp 2221 2223 2001:db8:1::2 2224 2225 2227 2001:db8::1 2228 2229 2230 2231 2233 Figure 5: lw4o6 CE Configuration XML 2235 In the example depicted in Figure 5, the interface name is defined 2236 for the softwire tunnel. This name is then referenced by the routing 2237 configuration for the IPv4 route. Figure 6 provides an example 2238 configuration for the CE's IPv4 routing, using the YANG module 2239 described in [RFC8349]. 2241 2242 2243 2244 2245 static 2246 v4 2247 2248 2250 2251 0.0.0.0/0 2252 2253 lw4o6-wan 2254 2255 2256 2257 2258 2259 2260 2261 2263 Figure 6: lw4o6 CE Routing Configuration XML 2265 Figure 7 provides an example configuration for the CE's NAPT44 2266 function, using the YANG module described in 2267 [I-D.ietf-opsawg-nat-yang]. 2269 2270 2271 2272 2273 1 2274 2275 1 2276 2277 1 2278 192.0.2.1 2279 2280 2281 2282 6 2283 8 2284 52 2285 2286 2287 2288 1 2289 80 2290 2291 2292 2293 2294 1 2295 8 2296 2297 2298 6 2299 32 2300 2301 2302 17 2303 16 2304 2305 2306 2307 2308 1 2309 192.0.2.1/32 2310 192.168.1.0/24 2311 6 2312 2313 2314 2 2315 192.0.2.1/32 2316 192.168.1.0/24 2317 17 2318 2319 2320 3 2321 192.0.2.1/32 2322 192.168.1.0/24 2323 1 2324 2325 2326 2327 2328 2329 2331 Figure 7: lw4o6 NAT Configuration XML 2333 Authors' Addresses 2335 Yong Cui 2336 Tsinghua University 2337 Beijing 100084 2338 P.R. China 2340 Phone: +86-10-6260-3059 2341 Email: cuiyong@tsinghua.edu.cn 2343 Ian Farrer (editor) 2344 Deutsche Telekom AG 2345 CTO-ATI,Landgrabenweg 151 2346 Bonn, NRW 53227 2347 Germany 2349 Email: ian.farrer@telekom.de 2351 Mohamed Boucadair (editor) 2352 Orange 2353 Rennes 35000 2354 France 2356 Email: mohamed.boucadair@orange.com 2358 Qi Sun 2359 Tsinghua University 2360 Beijing 100084 2361 P.R. China 2363 Phone: +86-10-6278-5822 2364 Email: sunqi.ietf@gmail.com 2366 Linhui Sun 2367 Tsinghua University 2368 Beijing 100084 2369 P.R. China 2371 Phone: +86-10-6278-5822 2372 Email: lh.sunlinh@gmail.com 2373 Sladjana Zechlin 2374 Deutsche Telekom AG 2375 Landgrabenweg 151 2376 Bonn, NRW 53227 2377 Germany 2379 Email: sladjana.zechlin@telekom.de 2381 Rajiv Asati 2382 Cisco Systems, Inc. 2383 7025 Kit Creek Rd. 2384 RTP, NC 27709 2385 USA 2387 Email: Rajiva@cisco.com