idnits 2.17.1 draft-ietf-netmod-module-tags-03.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 : ---------------------------------------------------------------------------- ** The document seems to lack a Security Considerations section. ** There is 1 instance of too long lines in the document, the longest one being 14 characters in excess of 72. ** The abstract seems to contain references ([I-D.ietf-netmod-RFC6087bis]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. == The 'Updates: ' line in the draft header should list only the _numbers_ of the RFCs which will be updated by this document (if approved); it should not include the word 'RFC' in the list. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 350 has weird spacing: '... prefix des...' -- The document date (October 17, 2018) is 2016 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 5226 (Obsoleted by RFC 8126) ** Downref: Normative reference to an Informational RFC: RFC 8199 Summary: 5 errors (**), 0 flaws (~~), 3 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group C. Hopps 3 Internet-Draft Deutsche Telekom 4 Updates: rfc6087bis (if approved) L. Berger 5 Intended status: Standards Track LabN Consulting, L.L.C. 6 Expires: April 20, 2019 D. Bogdanovic 7 October 17, 2018 9 YANG Module Tags 10 draft-ietf-netmod-module-tags-03 12 Abstract 14 This document provides for the association of tags with YANG modules. 15 The expectation is for such tags to be used to help classify and 16 organize modules. A method for defining, reading and writing a 17 modules tags is provided. Tags may be standardized and assigned 18 during module definition; assigned by implementations; or dynamically 19 defined and set by users. This document provides guidance to future 20 model writers and, as such, this document updates 21 [I-D.ietf-netmod-rfc6087bis]. 23 Status of This Memo 25 This Internet-Draft is submitted in full conformance with the 26 provisions of BCP 78 and BCP 79. 28 Internet-Drafts are working documents of the Internet Engineering 29 Task Force (IETF). Note that other groups may also distribute 30 working documents as Internet-Drafts. The list of current Internet- 31 Drafts is at https://datatracker.ietf.org/drafts/current/. 33 Internet-Drafts are draft documents valid for a maximum of six months 34 and may be updated, replaced, or obsoleted by other documents at any 35 time. It is inappropriate to use Internet-Drafts as reference 36 material or to cite them other than as "work in progress." 38 This Internet-Draft will expire on April 20, 2019. 40 Copyright Notice 42 Copyright (c) 2018 IETF Trust and the persons identified as the 43 document authors. All rights reserved. 45 This document is subject to BCP 78 and the IETF Trust's Legal 46 Provisions Relating to IETF Documents 47 (https://trustee.ietf.org/license-info) in effect on the date of 48 publication of this document. Please review these documents 49 carefully, as they describe your rights and restrictions with respect 50 to this document. Code Components extracted from this document must 51 include Simplified BSD License text as described in Section 4.e of 52 the Trust Legal Provisions and are provided without warranty as 53 described in the Simplified BSD License. 55 Table of Contents 57 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 58 2. Conventions Used in This Document . . . . . . . . . . . . . . 3 59 3. Tag Values . . . . . . . . . . . . . . . . . . . . . . . . . 3 60 3.1. IETF Standard Tags . . . . . . . . . . . . . . . . . . . 3 61 3.2. Vendor Tags . . . . . . . . . . . . . . . . . . . . . . . 3 62 3.3. User Tags . . . . . . . . . . . . . . . . . . . . . . . . 3 63 3.4. Reserved Tags . . . . . . . . . . . . . . . . . . . . . . 4 64 4. Tag Management . . . . . . . . . . . . . . . . . . . . . . . 4 65 4.1. Module Definition Association . . . . . . . . . . . . . . 4 66 4.2. Implementation Association . . . . . . . . . . . . . . . 4 67 4.3. Administrative Tagging . . . . . . . . . . . . . . . . . 4 68 5. Tags Module Structure . . . . . . . . . . . . . . . . . . . . 4 69 5.1. Tags Module Tree . . . . . . . . . . . . . . . . . . . . 4 70 5.2. Tags Module . . . . . . . . . . . . . . . . . . . . . . . 5 71 6. Other Classifications . . . . . . . . . . . . . . . . . . . . 7 72 7. Guidelines to Model Writers . . . . . . . . . . . . . . . . . 7 73 7.1. Define Standard Tags . . . . . . . . . . . . . . . . . . 7 74 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 75 8.1. YANG Module Tag Prefix Registry . . . . . . . . . . . . . 8 76 8.2. YANG Module IETF Tag Registry . . . . . . . . . . . . . . 8 77 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 10 78 9.1. Normative References . . . . . . . . . . . . . . . . . . 10 79 9.2. Informative References . . . . . . . . . . . . . . . . . 10 80 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 82 1. Introduction 84 The use of tags for classification and organization is fairly 85 ubiquitous not only within IETF protocols, but in the internet itself 86 (e.g., #hashtags). Tags can be usefully standardized, but they can 87 also serve as a non-standardized mechanism available for users to 88 define themselves. Our solution provides for both cases allowing for 89 the most flexibility. In particular, tags may be standardized as 90 well as assigned during module definition; assigned by 91 implementations; or dynamically defined and set by users. 93 This document defines a YANG module [RFC6020] which provides a list 94 of module entries to allow for adding or removing of tags as well as 95 viewing the set of tags associated with a module. 97 This document defines an extension statement to be used to indicate 98 tags that SHOULD be added by the module implementation automatically 99 (i.e., outside of configuration). 101 This document also defines an IANA registry for tag prefixes as well 102 as a set of globally assigned tags. 104 Section 7 provides guidelines for authors of YANG data models. This 105 section updates [I-D.ietf-netmod-rfc6087bis]. 107 2. Conventions Used in This Document 109 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 110 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 111 "OPTIONAL" in this document are to be interpreted as described in 112 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, 113 as shown here. 115 3. Tag Values 117 All tags begin with a prefix indicating who owns their definition. 118 An IANA registry is used to support standardizing tag prefixes. 119 Currently 3 prefixes are defined with all others reserved. No 120 further structure is imposed by this document on the value following 121 the standard prefix, and the value can contain any yang type 'string' 122 characters except carriage-returns, newlines and tabs. 124 3.1. IETF Standard Tags 126 An IETF standard tag is a tag that has the prefix "ietf:". All IETF 127 standard tags are registered with IANA in a registry defined later in 128 this document. 130 3.2. Vendor Tags 132 A vendor tag is a tag that has the prefix "vendor:". These tags are 133 defined by the vendor that implements the module, and are not 134 standardized; however, it is RECOMMENDED that the vendor include 135 extra identification in the tag to avoid collisions such as using the 136 enterpise or organization name follwing the "vendor:" prefix (e.g., 137 vendor:example.com:vendor-defined-classifier). 139 3.3. User Tags 141 A user tag is any tag that has the prefix "user:". These tags are 142 defined by the user/administrator and will never be standardized. 144 3.4. Reserved Tags 146 Any tag not starting with the prefix "ietf:", "vendor:" or "user:" is 147 reserved for future standardization. 149 4. Tag Management 151 Tags can become associated with a module in a number of ways. Tags 152 may be defined and associated at module design time, at 153 implementation time, or via user administrative control. As the main 154 consumer of tags are users, users may also remove any tag, no matter 155 how the tag became associated with a module. 157 4.1. Module Definition Association 159 A module definition can indicate a set of tags to be added by the 160 module implementer. These design time tags are indicated using the 161 module-tag extension statement. If the module definition will be 162 IETF standards track, the tags MUST also be IETF standard tags 163 (Section 3.1). Thus, new modules can drive the addition of new 164 standard tags to the IANA registry, and the IANA registry can serve 165 as a check against duplication. 167 4.2. Implementation Association 169 An implementation MAY include additional tags associated with a 170 module. These tags may be standard or vendor specific tags. 172 4.3. Administrative Tagging 174 Tags of any kind can be assigned and removed with using normal 175 configuration mechanisms. 177 5. Tags Module Structure 179 5.1. Tags Module Tree 181 The tree associated with the "ietf-module-tags" module follows. The 182 meaning of the symbols can be found in [RFC8340]. 184 module: ietf-module-tags 185 +--rw module-tags 186 +--rw module* [name] 187 +--rw name yang:yang-identifier 188 +--rw tag* tag 189 +--rw masked-tag* tag 191 5.2. Tags Module 193 file "ietf-module-tags@2018-10-17.yang" 194 module ietf-module-tags { 195 yang-version 1.1; 196 namespace "urn:ietf:params:xml:ns:yang:ietf-module-tags"; 197 prefix tags; 199 import ietf-yang-types { 200 prefix yang; 201 } 203 organization 204 "IETF NetMod Working Group (NetMod)"; 205 contact 206 "NetMod Working Group - "; 208 // RFC Ed.: replace XXXX with actual RFC number and 209 // remove this note. 211 description 212 "This module describes a mechanism associating tags with YANG 213 modules. Tags may be IANA assigned or privately defined. 215 Copyright (c) 2018 IETF Trust and the persons identified as 216 authors of the code. All rights reserved. 218 Redistribution and use in source and binary forms, with or 219 without modification, is permitted pursuant to, and subject to 220 the license terms contained in, the Simplified BSD License set 221 forth in Section 4.c of the IETF Trust's Legal Provisions 222 Relating to IETF Documents 223 (https://trustee.ietf.org/license-info). 225 The key words 'MUST', 'MUST NOT', 'REQUIRED', 'SHALL', 'SHALL 226 NOT', 'SHOULD', 'SHOULD NOT', 'RECOMMENDED', 'MAY', and 227 'OPTIONAL' in the module text are to be interpreted as described 228 in RFC 2119 (https://tools.ietf.org/html/rfc2119). 230 This version of this YANG module is part of RFC XXXX 231 (https://tools.ietf.org/html/rfcXXXX); see the RFC itself for 232 full legal notices."; 234 // RFC Ed.: update the date below with the date of RFC publication 235 // and RFC number and remove this note. 237 revision 2018-10-17 { 238 description 239 "Initial revision."; 240 reference "RFC XXXX: YANG Module Tags"; 241 } 243 typedef tag { 244 type string { 245 length "1..max"; 246 pattern '[a-zA-Z_][a-zA-Z0-9\-_]*:[\S ]+'; 247 } 248 description 249 "A tag value is composed of a standard prefix followed by any type 250 'string' value that does not include carriage return, newline or 251 tab characters."; 252 } 254 extension module-tag { 255 argument tag; 256 description 257 "The argument 'tag' is of type 'tag'. This extension statement is 258 used by module authors to indicate the tags that SHOULD be added 259 automatically by the system. As such the origin of the value 260 for the pre-defined tags should be set to 'system'."; 261 } 263 container module-tags { 264 description 265 "Contains the list of modules and their associated tags"; 266 list module { 267 key "name"; 268 description 269 "A list of modules and their associated tags"; 270 leaf name { 271 type yang:yang-identifier; 272 mandatory true; 273 description 274 "The YANG module name."; 275 } 276 leaf-list tag { 277 type tag; 278 description 279 "Tags associated with the module. See the IANA 'YANG Module 280 Tag Prefix' registry for reserved prefixes and the IANA 'YANG 281 Module IETF Tag' registry for IETF standard tags. 283 The operational view of this list is constructed using the following steps: 285 1) System added tags are added. 286 2) User configured tags are added. 288 3) Any tag that is equal to a masked-tag is removed."; 289 } 290 leaf-list masked-tag { 291 type tag; 292 description 293 "The list of tags that should not be associated with this 294 module. This user can remove (mask) tags by adding 295 them to this list. It is not an error to add tags to this 296 list that are not associated with the module."; 297 } 298 } 299 } 300 } 301 303 6. Other Classifications 305 It's worth noting that a different YANG module classification 306 document exists [RFC8199]. That document is classifying modules in 307 only a logical manner and does not define tagging or any other 308 mechanisms. It divides YANG modules into 2 categories (service or 309 element) and then into one of 3 origins: standard, vendor or user. 310 It does provide a good way to discuss and identify modules in 311 general. This document defines standard tags to support [RFC8199] 312 style classification. 314 7. Guidelines to Model Writers 316 This section updates [I-D.ietf-netmod-rfc6087bis]. 318 7.1. Define Standard Tags 320 A module can indicate using module-tag extension statements a set of 321 tags that are to be automatically associated with it (i.e., not added 322 through configuration). 324 module example-module { 325 ... 326 import module-tags { prefix tags; } 328 tags:module-tag "ietf:some-new-tag"; 329 tags:module-tag "ietf:some-other-tag"; 330 ... 331 } 333 The module writer can use existing standard tags, or use new tags 334 defined in the model definition, as appropriate. For standardized 335 modules new tags MUST be assigned in the IANA registry defined below, 336 see Section 8.2 below. 338 8. IANA Considerations 340 8.1. YANG Module Tag Prefix Registry 342 This registry allocates tag prefixes. All YANG module tags SHOULD 343 begin with one of the prefixes in this registry. 345 The allocation policy for this registry is Specification Required 346 [RFC5226]. 348 The initial values for this registry are as follows. 350 prefix description 351 -------- --------------------------------------------------- 352 ietf: IETF Standard Tag allocated in the IANA YANG Module 353 IETF Tag Registry. 354 vendor: Non-standardized tags allocated by the module implementer. 355 user: Non-standardized tags allocated by and for the user. 357 Other SDOs (standard organizations) wishing to standardize their own 358 set of tags could allocate a top level prefix from this registry. 360 8.2. YANG Module IETF Tag Registry 362 This registry allocates prefixes that have the standard prefix 363 "ietf:". New values should be well considered and not achievable 364 through a combination of already existing standard tags. 366 The allocation policy for this registry is IETF Review [RFC5226]. 368 The initial values for this registry are as follows. 370 +------------------------+------------------------------+-----------+ 371 | Tag | Description | Reference | 372 +------------------------+------------------------------+-----------+ 373 | ietf:rfc8199-element | A module for a network | [RFC8199] | 374 | | element. | | 375 | | | | 376 | ietf:rfc8199-service | A module for a network | [RFC8199] | 377 | | service. | | 378 | | | | 379 | ietf:rfc8199-standard | A module defined by a | [RFC8199] | 380 | | standards organization. | | 381 | | | | 382 | ietf:rfc8199-vendor | A module defined by a | [RFC8199] | 383 | | vendor. | | 384 | | | | 385 | ietf:rfc8199-user | A module defined by the | [RFC8199] | 386 | | user. | | 387 | | | | 388 | ietf:hardware | A module relating to | [This | 389 | | hardware (e.g., inventory). | document] | 390 | | | | 391 | ietf:software | A module relating to | [This | 392 | | software (e.g., installed | document] | 393 | | OS). | | 394 | | | | 395 | ietf:qos | A module for managing | [This | 396 | | quality of service. | document] | 397 | | | | 398 | ietf:protocol | A module representing a | [This | 399 | | protocol. | document] | 400 | | | | 401 | ietf:system-management | A module relating to system | [This | 402 | | management (e.g., a system | document] | 403 | | management protocol such as | | 404 | | syslog, TACAC+, SNMP, | | 405 | | netconf, ...). | | 406 | | | | 407 | ietf:network-service | A module relating to network | [This | 408 | | service (e.g., a network | document] | 409 | | service protocol such as an | | 410 | | NTP server, DNS server, DHCP | | 411 | | server, etc). | | 412 | | | | 413 | ietf:oam | A module representing | [This | 414 | | Operations, Administration, | document] | 415 | | and Maintenance (e.g., BFD). | | 416 | | | | 417 | ietf:routing | A module related to routing. | [This | 418 | | | document] | 419 | | | | 420 | ietf:signaling | A module representing | [This | 421 | | control plane signaling. | document] | 422 | | | | 423 | ietf:lmp | A module representing a link | [This | 424 | | management protocol. | document] | 425 +------------------------+------------------------------+-----------+ 427 Table 1: IETF Module Tag Registry 429 9. References 431 9.1. Normative References 433 [I-D.ietf-netmod-rfc6087bis] 434 Bierman, A., "Guidelines for Authors and Reviewers of YANG 435 Data Model Documents", draft-ietf-netmod-rfc6087bis-20 436 (work in progress), March 2018. 438 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 439 Requirement Levels", BCP 14, RFC 2119, 440 DOI 10.17487/RFC2119, March 1997, 441 . 443 [RFC5226] Narten, T. and H. Alvestrand, "Guidelines for Writing an 444 IANA Considerations Section in RFCs", RFC 5226, 445 DOI 10.17487/RFC5226, May 2008, 446 . 448 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 449 the Network Configuration Protocol (NETCONF)", RFC 6020, 450 DOI 10.17487/RFC6020, October 2010, 451 . 453 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 454 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 455 May 2017, . 457 [RFC8199] Bogdanovic, D., Claise, B., and C. Moberg, "YANG Module 458 Classification", RFC 8199, DOI 10.17487/RFC8199, July 459 2017, . 461 9.2. Informative References 463 [RFC8340] Bjorklund, M. and L. Berger, Ed., "YANG Tree Diagrams", 464 BCP 215, RFC 8340, DOI 10.17487/RFC8340, March 2018, 465 . 467 Authors' Addresses 469 Christan Hopps 470 Deutsche Telekom 472 Email: chopps@chopps.org 473 Lou Berger 474 LabN Consulting, L.L.C. 476 Email: lberger@labn.net 478 Dean Bogdanovic 480 Email: ivandean@gmail.com