NETMOD Working Group P. Andersson Internet-Draft Ionio Systems Updates: 6020, 7950, I-D.ietf-netmod-rfc8407bis 2 April 2026 (if approved) Intended status: Standards Track Expires: 4 October 2026 YANG module file name convention draft-ietf-netmod-yang-module-filename-07 Abstract This document presents YANG module file name convention. The convention extends the current YANG module file name using revision-date, with the YANG semantic version extension. The YANG semantic version extension allows for an informative version to be associated with a particular YANG module revision. This documents updates RFCs 6020, 7950, and draft-ietf-netmod-rfc8407bis. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." This Internet-Draft will expire on 4 October 2026. Copyright Notice Copyright (c) 2026 IETF Trust and the persons identified as the document authors. All rights reserved. This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/ license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights Andersson Expires 4 October 2026 [Page 1] Internet-Draft YANG module file name convention April 2026 and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License. Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 2 1.2. Motivation . . . . . . . . . . . . . . . . . . . . . . . 2 2. YANG Module File Names . . . . . . . . . . . . . . . . . . . 3 2.1. Coexistence with YANG Semver . . . . . . . . . . . . . . 3 2.2. Known Incompatibilities . . . . . . . . . . . . . . . . . 4 3. Operational Considerations . . . . . . . . . . . . . . . . . 4 4. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 4 5. Security Considerations . . . . . . . . . . . . . . . . . . . 5 6. References . . . . . . . . . . . . . . . . . . . . . . . . . 5 6.1. Normative References . . . . . . . . . . . . . . . . . . 5 6.2. Informative References . . . . . . . . . . . . . . . . . 6 Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . . 6 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 6 1. Introduction This document defines the YANG module file name convention. It extends the current convention defined in [RFC6020], [RFC7950], and [I-D.ietf-netmod-rfc8407bis], which uses revision-date, with the YANG semantic version extension defined in [I-D.ietf-netmod-yang-semver]. 1.1. Terminology The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 [RFC2119] [RFC8174] when, and only when, they appear in all capitals, as shown here. 1.2. Motivation The motivation for using YANG semantic version instead of revision date is that it conveys additional information to the user. A revision date only tells the user that it has been updated, while, for instance, a YANG Semver version can tell the user about the module's compatibility level at a glance. Having this information available as early as possible, i.e. in the module file name, makes it possible to quickly identify the module revision; compared to searching in the file contents and checking the revisions. Having the YANG semantic version visible in the file name will make it Andersson Expires 4 October 2026 [Page 2] Internet-Draft YANG module file name convention April 2026 easier to handle large sets of YANG modules. 2. YANG Module File Names This section updates Section 5.2 of [RFC7950], Section 5.2 of [RFC6020], and Section 3.2 of [I-D.ietf-netmod-rfc8407bis]. If a revision has an associated YANG semantic version (ysv:version) then a YANG file MUST be created that use the YANG semantic version in the file name. Additionally, a YANG file with the revision-date MAY be created. The name of the files SHOULD be of the form: module-or-submodule-name [('#' ysv:version) / ('@' revision-date)] ( '.yang' / '.yin' ) E.g., acme-router-module#2.0.3.yang or acme-router-module@2024-05-15.yang. In short, the YANG semantic version file name scheme is recommended, as its use will convey compatibility status at a glance withouth the need to read the module. If the YANG module (or submodule) has an associated YANG semantic version (ysv:version), then a file name that use the YANG semantic version MUST be created. In addition, a file with the revision date in the file name MAY be created as well. 2.1. Coexistence with YANG Semver As can be seen above, all valid identifiers for YANG semantic version are valid in the file name as well. Section 4.3 of [I-D.ietf-netmod-yang-semver] The following example is a valid YANG module file name example-module#2.3.1_non_compatible+build2237refM443ss.yang One consequence of this is that there might exist two child modules of version 2.0.0 with the same X.Y.Z digits (2.0.1) but different version labels: 2.0.1-draft-superman-super-stuff-03 2.0.1-draft-batman-cool-addition-07 (a competing draft) Andersson Expires 4 October 2026 [Page 3] Internet-Draft YANG module file name convention April 2026 2.2. Known Incompatibilities There are currently no known publicly available tools that support the YANG semantic version file name schema. There are known proprietary tooling that already uses the file name schema presented in this document. At the IETF 119 Hackathon, there was a project that investigated the feasibility to modify popular YANG tooling to support the proposed schema. There was a successful attempt to modify pyang to support the file name schema and also "recommended-min" previously included in [I-D.ietf-netmod-yang-module-versioning]. Furthermore, there were efforts in researching yanger and libyang to support the schema, but the hackathon ended before these projects could be concluded. 3. Operational Considerations The delimiter symbol for YANG Semver is "#", the number sign. Since this symbol may have special, reserved, or semantic meaning in some contexts, it is important to escape or encode it according to the context. In URI and URL contexts, the delimiter symbol needs to be percent encoded where it would be interpreted semantically (e.g. as the fragment identifier) by the software reading it. The percent encoding for "#" is "%23". In online registries, such as IANA registries and code repositories, it is expected that the full YANG module file name is retained. This means that a server publishing a YANG module with a YANG Semver delimited by "#" needs to ensure that the client doesn't misinterpret the delimiter as e.g. a URL fragment identifier in links. A client needs to percent encode direct requests for YANG modules where the file name includes a YANG Semver delimiter symbol. 4. IANA Considerations For complete guidance on how to handle YANG modules in RFCs and IANA registries, with regards to [I-D.ietf-netmod-yang-module-versioning], [I-D.ietf-netmod-yang-semver], and YANG module file names, see [I-D.ietf-netmod-iana-yang-guidance]. The "YANG Module Names" Registry need to support YANG modules with both the existing file name convention and the file name convention defined in this document. Andersson Expires 4 October 2026 [Page 4] Internet-Draft YANG module file name convention April 2026 The registry MUST create a file with a YANG semantic version if the YANG module (or submodule) has an associated YANG semantic version (ysv:version). The registry MUST also create a file with the YANG module using a file name with the revision date. It MUST be ensured that the files' contents are identical. 5. Security Considerations There are no security considerations for this draft. 6. References 6.1. Normative References [I-D.ietf-netmod-iana-yang-guidance] Wilton, R., "Guidance for Managing YANG Modules in RFCs and IANA Registries", Work in Progress, Internet-Draft, draft-ietf-netmod-iana-yang-guidance-01, 17 March 2026, . [I-D.ietf-netmod-rfc8407bis] Bierman, A., Boucadair, M., and Q. Wu, "Guidelines for Authors and Reviewers of Documents Containing YANG Data Models", Work in Progress, Internet-Draft, draft-ietf- netmod-rfc8407bis-28, 5 June 2025, . [I-D.ietf-netmod-yang-module-versioning] Wilton, R., Rahman, R., Lengyel, B., Clarke, J., and J. Sterne, "Updated YANG Module Revision Handling", Work in Progress, Internet-Draft, draft-ietf-netmod-yang-module- versioning-15, 18 October 2025, . [I-D.ietf-netmod-yang-semver] Clarke, J., Wilton, R., Rahman, R., Lengyel, B., Sterne, J., and B. Claise, "YANG Semantic Versioning", Work in Progress, Internet-Draft, draft-ietf-netmod-yang-semver- 24, 29 September 2025, . Andersson Expires 4 October 2026 [Page 5] Internet-Draft YANG module file name convention April 2026 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, . [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for the Network Configuration Protocol (NETCONF)", RFC 6020, DOI 10.17487/RFC6020, October 2010, . [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", RFC 7950, DOI 10.17487/RFC7950, August 2016, . [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, May 2017, . 6.2. Informative References Acknowledgements The author would like to thank Joe Clarke, Reshad Rahman, Mahesh Jethanandani, David Dong, Aihua Guo, Barry Leiba, Joel M. Halpern, and Meir Goldman for their excellent technical reviews, support, and guidance. Author's Address Per Andersson Ionio Systems Email: per.ietf@ionio.se Andersson Expires 4 October 2026 [Page 6]