RFC 7994

Requirements for Plain-Text RFCs

๐Ÿ“… published December 2016, from ietf

Internet Architecture Board (IAB) ๐Ÿ’–

Okay bestie, let's get into this one. RFC 7994: Requirements for Plain-Text RFCs โœจ It was written by H. Flanagan from the RFC Editor ๐ŸŽ€ and it's an Informational doc, not a standards-track thing, published in December 2016 ๐Ÿฆ‹ It's an IAB product ๐Ÿ‘‘ and it doesn't obsolete or update anything, so it's standing on its own, no drama ๐Ÿ’…

ISSN: 2070-1721 ๐ŸŒธ

Abstract

In 2013 the community had a huge conversation and decided RFCs would switch to XML as the canonical format ๐Ÿซถ Before that they were plain-text, ASCII-only. The big-picture needs behind the switch live in [RFC6949], "RFC Series Format Requirements and Future Development" ๐Ÿ“š Plain text is still super important to a lot of people in the IETF, so it's still one of the formats rendered from the XML ๐Ÿ’œ This doc is all about the rendering rules for plain-text RFCs, and these rules don't apply to plain-text RFCs published before the switch ๐Ÿ•ฐ๏ธ

Status of This Memo

This one is not a standards-track spec, it's just published for info ๐Ÿ“ It's a product of the IAB and it's basically a permanent record of stuff the IAB thought was worth keeping ๐Ÿงš It reflects the IAB's consensus, and anything the IAB approves can't be a candidate for any level of Internet Standard, see Section 2 of [RFC7841] ๐Ÿ’…

For the current status, errata, and how to send feedback, check http://www.rfc-editor.org/info/rfc7994 โœจ

Copyright (c) 2016 IETF Trust and the document authors ๐ŸŒˆ All rights reserved ๐Ÿ”’ This doc is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents, which are in effect on the publication date. Go read those carefully, they spell out your rights and restrictions ๐Ÿซถ


1. Introduction ๐Ÿฆ‹

So, the big 2013 switch: the community agreed to move from plain-text ASCII to XML as the canonical format [XML-ANNOUNCE] ๐Ÿ’– The high-level reasons are in [RFC6949] ๐Ÿ“– Plain text is still a fave for many people, so it stays as a publication format, and this doc lays out how plain-text RFCs should be rendered ๐ŸŒธ These rules skip anything published before the transition, periodt โœจ

The Unicode Consortium defines "plain text" as "Computer-encoded text that consists only of a sequence of code points from a given standard, with no other formatting or structural information. Plain-text interchange is commonly used between computer systems that do not share higher-level protocols." [UNICODE-GLOSSARY] Translation: plain-text files can't carry any embedded character formatting or style info ๐Ÿ’… The actual encoding, though, isn't locked to one specific set of code points ๐ŸŽ€

A plain-text output is going to be needed for the foreseeable future ๐Ÿ”ฎ Converting xml2rfc version 2 (xml2rfc v2) into text is a well-understood process [RFC7749] ๐Ÿ’œ The plan is to lean on that experience for xml2rfc version 3 (xml2rfc v3) to text [RFC7991] ๐Ÿงš This doc calls out the stuff that changed from v2 or needs extra attention, like which character encodings are allowed, page layout changes, and how figures, artwork, and pagination get handled ๐ŸŒˆ For general style, check "RFC Style Guide" [RFC7322] ๐Ÿ“š

The assumptions behind the plain-text changes are:

  • The tools the RFC Editor and a lot of the author community use to make the text file are complicated to change and support, and the final output often needs manual tweaking ๐Ÿ˜ญ Handling page breaks and the widows and orphans that come with paginated output is especially tricky [WIDOWS] ๐Ÿ’€
  • Other publication formats, like PDF and HTML, will offer stuff like markup and pretty printing ๐Ÿฆ‹
  • There's a massive existing toolchain people use to work with plain-text docs ๐Ÿซถ Other formats might get similar features, but the workflow that uses the existing toolchain should be supported as much as is practical ๐Ÿ”ฅ

Where it's practical, the original guidance on plain-text RFC structure stays put, like line lengths and lines per page [INS2AUTH] ๐ŸŽ€ Other formats such as HTML and PDF will have extras that plain text can't do, like paragraph numbering and typographic emphasis โœจ

The details here are expected to change as people gain experience building the new toolsets ๐Ÿ› ๏ธ Revised docs will be published to capture those changes as the toolsets get finished ๐Ÿ’… Other implementers must not expect those changes to stay backwards-compatible with what's described in this document ๐Ÿ™ˆ

2. Character Encoding ๐ŸŒธ

Plain-text files for RFCs will use the UTF-8 [RFC3629] encoding ๐Ÿ’– That said, non-ASCII characters are only allowed in a limited, controlled way ๐Ÿซถ

Lots of elements in the xml2rfc v3 vocabulary have an attribute holding the ASCII equivalent of a non-ASCII character string ๐Ÿฆ‹ That ASCII equivalent gets rendered in the plain text following "The Use of Non-ASCII Characters in RFCs" [RFC7997]. Go check the PDF version of that doc ๐Ÿ“„

The plain-text file will include a Byte Order Mark (BOM) so text reader software gets in-band info about which character encoding scheme is used ๐Ÿงš

3. Figures and Artwork ๐ŸŽจ

Artwork, like network diagrams or performance graphs, MUST be tagged with the XML <artwork> element (see Section 2.5 of "The 'xml2rfc' Version 3 Vocabulary" [RFC7991]. If that artwork is an ASCII art diagram, it MUST be tagged as type='ascii-art'. The plain-text format will only include ASCII art ๐Ÿ’… If the canonical format has figures or artwork that isn't ASCII art, the plain-text output MUST include a pointer to the relevant figure in the HTML version of the RFC, so readers can see the artwork ๐Ÿ‘‘

Authors who want ASCII art for the plain-text file and SVG art for the other outputs can do that ๐ŸŒˆ But they SHOULD be aware that readers could get confused by two different diagrams describing the same content ๐Ÿ˜ญ If the publication formats conflict, review the XML and PDF files to sort it out ๐Ÿ”


4. General Page Format Layout ๐Ÿ“„

One plain-text output gets made during publication, with basic pagination: a form feed instruction every 58 lines at most, blank lines included ๐ŸŽ€ Instructions or a script will be made available by and for the community so people can strip out pagination however they like ๐Ÿ’œ

4.1. Headers and Footers ๐ŸŒธ

The front page front matter (like the RFC number and category) and the last page's back matter (the authors' full names and contact info) keep the structure described in [RFC7841], "RFC Streams, Headers, and Boilerplates" ๐Ÿ’– Running headers and footers won't be added anymore ๐Ÿ™…โ€โ™€๏ธ

4.2. Table of Contents ๐Ÿ“‘

To keep content as similar as possible across the publication formats, the table of contents lists section and subsection numbers and titles, but no page numbers โœจ

4.3. Line Width ๐Ÿ“

Each line MUST be limited to 72 characters, followed by the end-of-line (EOL) character sequence ๐Ÿฆ‹ The EOL sequence the RFC Editor uses will be the two-character sequence CR LF (Carriage Return followed by Line Feed) ๐Ÿซถ This limit includes any left-side indentation ๐ŸŒˆ

Heads up that the RFC Editor's EOL may change with different transports and in different display software ๐Ÿ’€

4.4. Line Spacing ๐ŸŒท

Use single-spaced text within a paragraph, with one blank line between paragraphs ๐Ÿ’…

4.5. Hyphenation ๐Ÿ“

Hyphenated words (e.g., "Internet-Draft") SHOULD NOT be split across successive lines ๐Ÿ™ˆ


5. Elements from the xml2rfc v3 Vocabulary ๐Ÿงš

The plain-text formatter uses the relevant tags from the xml2rfc v3 source file to build a doc that follows the layout and structure in the full RFC Style Guide [RFC7322], including the updates in the web portion of the Style Guide [STYLEWEB] ๐Ÿ’œ

6. Security Considerations ๐Ÿšจ

The requirements for the plain-text format involve no significant security considerations ๐Ÿ™‚ Here's the plot twist though: as part of the larger format project, unintended changes to the text from the base XML file could corrupt a standard, practice, or critical piece of info about a protocol ๐Ÿ˜ฑ๐Ÿ’€ That's a real risk, so keep your eyes peeled ๐Ÿ‘€๐Ÿ”ฅ

7. References ๐Ÿ“š

To be continued in part 2 ๐ŸŽ€

7.1. Normative References ๐Ÿ“š

okay so these are the docs you have to read first, bestie, no skipping ๐Ÿ’… Here's the full list, copied exactly:

[RFC3629]  Yergeau, F., "UTF-8, a transformation format of
           ISO 10646", STD 63, RFC 3629, DOI 10.17487/RFC3629,
           November 2003, <http://www.rfc-editor.org/info/rfc3629>.

[RFC6949]  Flanagan, H. and N. Brownlee, "RFC Series Format
           Requirements and Future Development", RFC 6949,
           DOI 10.17487/RFC6949, May 2013,
           <http://www.rfc-editor.org/info/rfc6949>.

[RFC7322]  Flanagan, H. and S. Ginoza, "RFC Style Guide", RFC 7322,
           DOI 10.17487/RFC7322, September 2014,
           <http://www.rfc-editor.org/info/rfc7322>.

[RFC7749]  Reschke, J., "The "xml2rfc" Version 2 Vocabulary",
           RFC 7749, DOI 10.17487/RFC7749, February 2016,
           <http://www.rfc-editor.org/info/rfc7749>.

[RFC7841]  Halpern, J., Ed., Daigle, L., Ed., and O. Kolkman, Ed.,
           "RFC Streams, Headers, and Boilerplates", RFC 7841,
           DOI 10.17487/RFC7841, May 2016,
           <http://www.rfc-editor.org/info/rfc7841>.

[RFC7991]  Hoffman, P., "The "xml2rfc" Version 3 Vocabulary",
           RFC 7991, DOI 10.17487/RFC7991, December 2016,
           <http://www.rfc-editor.org/info/rfc7991>.

[RFC7997]  Flanagan, H., Ed., "The Use of Non-ASCII Characters in
           RFCs", RFC 7997, DOI 10.17487/RFC7997, December 2016,
           <http://www.rfc-editor.org/info/rfc7997>.

The big one is [RFC3629], which is all about UTF-8 ๐ŸŒธ It's giving foundations, literally the thing everything else is built on ๐Ÿงš

7.2. Informative References ๐Ÿฆ‹

these ones are the extra reading, not required, but ngl they're such good background ๐Ÿค“ Here's the list, exactly as written:

[INS2AUTH] RFC Editor, "Instructions to Request for Comments (RFC)
           Authors", August 2004, <https://www.rfc-editor.org/
           materials/instructions2authors.txt>.

[STYLEWEB] RFC Editor, "Web Portion of the Style Guide",
           February 2016,
           <http://www.rfc-editor.org/styleguide/part2/>.

[UNICODE-GLOSSARY]
           The Unicode Consortium, "Glossary of Unicode Terms",
           September 2016, <http://www.unicode.org/glossary/>.

[WIDOWS]   Wikipedia, "Widows and orphans", September 2016,
           <https://en.wikipedia.org/w/
           index.php?title=Widows_and_orphans&oldid=738356204>.

[XML-ANNOUNCE]
           Flanagan, H., "Subject: Direction of the RFC Format
           Development effort", May 2013,
           <http://www.rfc-editor.org/pipermail/
           rfc-interest/2013-May/005584.html>.

The [WIDOWS] entry is a Wikipedia page, so it's the most relaxed read of the bunch ๐Ÿ“

IAB Members at the Time of Approval ๐Ÿ‘‘

so these are the IAB members who were in the room when this memo got the green light โœจ Here's the squad, in alphabetical order:

Jari Arkko
Ralph Droms
Ted Hardie
Joe Hildebrand
Russ Housley
Lee Howard
Erik Nordmark
Robert Sparks
Andrew Sullivan
Dave Thaler
Martin Thomson
Brian Trammell
Suzanne Woolf

Acknowledgements ๐Ÿซถ

this doc owes a HUGE thank-you to the RFC Format Design Team ๐Ÿ’– The people who put in the work are Nevil Brownlee, Tony Hansen, Joe Hildebrand, Paul Hoffman, Ted Lemon, Julian Reschke, Adam Roach, Alice Russo, Robert Sparks, and David Thaler. Iconic behaviour, honestly ๐ŸŒˆ

Author's Address ๐Ÿ’…

the author behind it all is Heather Flanagan, from the RFC Editor ๐ŸŽ€

Heather Flanagan
RFC Editor

Email: rse@rfc-editor.org
URI:   http://orcid.org/0000-0002-2647-2220
๐Ÿ“ฆ where this page comes from