Network Working Group P. Hoffman Internet-Draft ICANN Intended status: Informational J. Hildebrand Expires: August 13, 2016 Cisco February 10, 2016 RFC v3 Prep Tool Description draft-iab-rfcv3-preptool-01 Abstract This document describes some aspects of the "prep tool" that is expected to be created when the new RFC v3 specification is deployed. 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 http://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 August 13, 2016. Copyright Notice Copyright (c) 2016 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 (http://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 and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Hoffman & Hildebrand Expires August 13, 2016 [Page 1] Internet-Draft RFC v3 Prep Tool Description February 2016 Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 2. v3 Prep Tool Usage Scenarios . . . . . . . . . . . . . . . . 2 3. Internet-Draft Submission . . . . . . . . . . . . . . . . . . 3 4. Canonical RFC Preparation . . . . . . . . . . . . . . . . . . 4 5. What the v3 Prep Tool Does . . . . . . . . . . . . . . . . . 4 6. Additional Uses for the Prep Tool . . . . . . . . . . . . . . 10 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 11 8. Security Considerations . . . . . . . . . . . . . . . . . . . 11 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 11 10. Informative References . . . . . . . . . . . . . . . . . . . 11 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 11 1. Introduction For the future of the RFC format, the RFC Editor has decided that XML (using the XML2RFCv3 vocabulary [I-D.iab-xml2rfc]) is the canonical format, in the sense that it is the data that is blessed by the process as the actual RFC. See [RFC6949] for more detail on this. Most people will read other formats, such as HTML, PDF, ASCII text, or other formats of the future, however. In order to ensure each of these formats is as similar as possible to one another as well as the canonical XML, there is a desire that the translation from XML into the other formats will be straightforward syntactic translation. To make that happen, a good amount of data will need to be in the XML format that is not there today. That data will be added by a program called the "prep tool", which will often run as a part of the xml2rfc process. This draft specifies the steps that the prep tool will have to take. As changes to [I-D.iab-xml2rfc] are made, this document will be updated. The details (particularly any vocabularies) described in this document are expected to change based on experience gained in implementing the RFC production center's toolset. Revised documents will be published capturing those changes as the toolset is completed. Other implementers must not expect those changes to remain backwards-compatible with the details described in this document. 2. v3 Prep Tool Usage Scenarios The prep tool will have several settings: o Internet-Draft preparation Hoffman & Hildebrand Expires August 13, 2016 [Page 2] Internet-Draft RFC v3 Prep Tool Description February 2016 o Canonical RFC preparation There are only a few differences between the two settings. For example, the boilerplate output will be different, as will the date output on the front page. Note that this only describes what the IETF-sponsored prep tool does. Others might create their own work-alike prep tools for their own formatting needs. However, an output format developer does not need to change the prep tool in order to create their own formatter: they only need to be able to consume prepared text. The IETF-sponsored prep tool runs in two different modes: "I-D" mode when the tool is run during Internet-Draft submission and processing, and "RFC production mode" when the tool is run by the RFC Production Center (RPC) while producing an RFC. This tool is described as if it is a separate tool so that we can reason about its architectural properties. In actual implementation, it might be a part of a larger suite of functionality. 3. Internet-Draft Submission When the IETF draft submission tool accepts v3 XML as an input format, the submission tool runs the submitted file through the prep tool. This is called "I-D mode" in this document. If the tool finds no errors, it keeps two XML files: the submitted file and the prepped file. The prepped file provides a record of what a submitter was attesting to at the time of submission. It represents a self-contained record of what any external references resolved to at the time of submission. The prepped file is used by the IETF formatters to create outputs such as HTML, PDF, and text (or the tools act in a way indistinguishable from this). The message sent out by the draft submission tool includes a link to the original XML as well as the other outputs, including the prepped XML. The prepped XML can be used by tools not yet developed to output new formats that have as similar output as possible to the current IETF formatters. For example, if the IETF creates a .mobi output renderer later, it can run that renderer on all of the prepped XML that has been saved, ensuring that the content of included external references and all of the part numbers and boilerplate will be the same as what was produced by the previous IETF formatters at the time the document was first uploaded. Hoffman & Hildebrand Expires August 13, 2016 [Page 3] Internet-Draft RFC v3 Prep Tool Description February 2016 4. Canonical RFC Preparation During AUTH48, the RPC will run the prep tool in canonical RFC preparation mode and make the results available to the authors so they can see what the final output might look like. When the document is done with AUTH48 review, the RPC runs the prep tool in canonical RFC preparation mode one last time, locks down the canonicalized XML, runs the formatters for the publication formats, and publishes all of those. It is probably a good idea for the RPC to keep a copy of the input XML file from the various steps of the RFC production process. This document assumes that the prep tool will be used in the following manner by the RFC Production Center; they may use something different, or with different configuration. Similarly to I-D's, the prepped XML can be used later to re-render the output formats, or to generate new formats. 5. What the v3 Prep Tool Does The steps listed here are in order of processing. In all cases where the prep tool would "add" an attribute or element, if that attribute or element already exists, the prep tool will check that the attribute or element is correct. If the value is incorrect, the prep tool will warn with the old and new values, then replace the incorrect value with the new value. 1. Fully process any DTDs in the input document, then remove the DTD. At a minimum, this entails processing the entityrefs and includes for external files. 2. Process all elements. Note: d XML may include more s (with relative URLs rooted at the xml:base). The tool may be configurable with a limit on the depth of recursion. 3. Run idnits. idnits will indicate if it encountered any errors, and will also provide text with all of the warnings and errors in a human-readable form. The prep tool displays all the warnings and errors, and stops if there was an error. 4. Remove processing instructions. 5. If in RFC production mode, remove comments. 6. Add the "Status of this Memo" text with current values. However, if different boilerplate text already exists in the Hoffman & Hildebrand Expires August 13, 2016 [Page 4] Internet-Draft RFC v3 Prep Tool Description February 2016 input, produce a warning that says that other tools, specifically the draft submission tool, will treat that condition as an error. The application will use the "submissionType", and "consensus" attributes of the element, and the "status" and "stream" attributes of the element, to determine which [RFC5741] boilerplate to include, as described in Appendix A of [I-D.iab-xml2rfc]. 7. Add the "Copyright Notice" text. The application will use the "ipr" and "submissionType" attributes of the element and the element to determine which portions and which version of the TLP to use, as described in A.1 of [I-D.iab-xml2rfc]. 8. Fill in the "prepTime" attribute of with the current datetime. 9. Fill in the "name" attribute of the in the with a string indicating the type of prepping that was done (RFC production or I-D mode). 10. If in I-D mode, if there is a element with a "removeInRFC" attribute that has the value "true", add a paragraph to the top of the element that says "This note is to be removed before publishing as an RFC.", if such a paragraph does not yet exist. 11. If in I-D mode, fill in "expiresDate" attribute of based on the element of the document's element, if there is one. Use the same expiry date (if needed) in the boilerplate. 12. Fill in any default values for attributes on elements, except "keepWithNext" and "keepWithPrevious" of , and "toc" of
. 13. For any element that does not already have a "target" attribute, fill that attribute in if the element has one or more child element(s). The particular URLs for RFCs and Internet-Drafts for this step will be specified later by the RFC Editor and the IESG. These URLs might also be different before and after the v3 format is adopted. 14. For each or that has an associated , replace the value of the "anchor" attribute with the value of the "to" attribute of the associated . Hoffman & Hildebrand Expires August 13, 2016 [Page 5] Internet-Draft RFC v3 Prep Tool Description February 2016 15. Add a "slugifiedName" attribute to each element that does not contain one; replace the attribute if it contains a value that begins with "n-". 16. Add "pn" attributes for all parts. Parts are: *
: pn='s-1.4.2' * : pn='s-abstract' * : pn='s-note-2' * : pn='s-boilerplate' * : pn='t-3' *
: pn='f-4' * ,