Summary
- Telnet's Network Virtual Terminal gave mismatched machines a tiny shared vocabulary:
CR LFfor a new line,CR NULfor a carriage return on its own, and no bareCRanywhere in default NVT ASCII. - The byte after CR was evidence, not decoration. The sender picked an NVT action; the receiver translated that action into its own terminal and operating-system habits.
- RFC 1123 later cleaned up the mess around the human Enter key, binary mode switched line-ending conversion off entirely, and Net-Unicode kept CRLF while quietly discouraging CR NUL.
A printer halfway across the line
Picture the Network Virtual Terminal as the machine it was named for. Its print head sits at column forty. Octet 13 arrives — carriage return — and in the pure NVT model the head slides back to the left margin without dropping a line. Octet 10, line feed, does the opposite: down one line, horizontal position untouched. Send them together and you get the thing everyone actually wants, the left edge of the next line.
Real terminals were less obedient. Some wired Return to a line advance. Some hosts treated LF as their record separator. Others used CR, a pair, a counted record, or something a vendor invented on a Tuesday. A receiver that executed CR the instant it arrived might then execute the following LF and land somewhere the sender never intended. A receiver that paused needed a bounded way to learn whether a second motion was coming.
RFC 318 answered in 1972: hold the CR, look at the next character. CR LF closed the branch as a new line. A CR that was not part of that pair travelled as CR NUL. The null did nothing to the printer. It existed to make the sender's choice legible.
Which is the whole trick. In that grammar slot, NUL was not a blank and not a delay. It was the sender saying, out loud, “no line feed belongs to this carriage return.”
The imaginary terminal kept the common layer thin
RFC 854, written by Jon Postel and Joyce Reynolds in 1983, made the Network Virtual Terminal the default intermediate representation for Telnet. A new connection did not open with two machines exchanging exhaustive descriptions of themselves. Each host mapped its local device or process into a deliberately modest NVT and trusted the peer to do the reverse.
That division of labour is the interesting part. The shared protocol defined a handful of actions. NUL was no operation. LF moved down without changing horizontal position. CR moved to the left margin of the current line. Everything else — character conversion, terminal timing, physical width, page length, the relationship between a network action and an operating-system interface — stayed local, where it belonged.
For the combined case, RFC 854 tightened the earlier recommendation into a rule. CR LF had to be treated as one new-line character whenever the combined action was intended. CR NUL had to represent carriage return alone. CR had to be avoided elsewhere in default NVT ASCII. The rule applied in both directions, even when an implementation believed no literal printer was anywhere in the building.
On receipt, the NUL following CR was stripped before the NVT action was mapped to the local character set. It belonged to the network representation, not automatically to the application payload — a distinction that evaporates the moment a byte stream passes through three libraries and a proxy.
The Enter key was a separate argument
The wire grammar was precise. The human key was not. What should a User Telnet send when someone pressed Return or Enter? Was that a request for the NVT new-line function, or a request to transmit the local CR key faithfully?
RFC 1123, Robert Braden's 1989 host-requirements cleanup, recorded the practical split. Some clients sent CR LF; others sent CR NUL. The base specification had described printer output far more clearly than terminal input, implementations made different but defensible readings, and the result became a durable interoperability headache.
The repair worked by naming roles and contexts. A User Telnet had to be able to send CR LF, CR NUL and LF. An ASCII client should offer a user-selectable CR LF/CR NUL mode and should default the end-of-line key to CR LF. An ASCII Server Telnet had to make both CR LF and CR NUL behave like the local end-of-line key when they arrived as terminal input.
That last rule looks as though it collapses the distinction, but only at one specified interface. In a raw terminal mode the server could pass CR straight to the application; in a formatted mode it could apply the local line convention. A non-ASCII host still faced the genuine tension between preserving a bare carriage return and accepting the form that existing clients actually emitted.
For traffic that was not terminal-to-computer input — server output, or another application protocol tunnelled through Telnet — RFC 1123 required CR LF for end of line. The same octets could therefore be governed by different translation duties depending on direction and purpose.
Binary mode was a change of interpreter, not a bigger alphabet
It is tempting to treat Telnet's Binary option as NVT with an eighth data bit bolted on. That misses the control boundary. RFC 856 made binary transmission a negotiated state for each direction separately. One side requested it; the other acknowledged it. The opposite direction did not change by itself.
Inside that state, ordinary octets were eight-bit data. Telnet command syntax survived: IAC still introduced commands, and a data byte equal to IAC still had to be doubled. But end-of-line conversion stopped. RFC 1123 explicitly forbade replacing CR with CR NUL or CR LF in binary mode.
The negotiated mode decides which interpreter owns the byte. In NVT ASCII, CR opens a two-byte line/action decision. In binary mode, CR, LF and NUL are just data unless application semantics say otherwise. Dropping the NUL merely because it follows CR corrupts the binary stream. Adding one does the same.
Which is why logging only printable text is not enough. An operator chasing a line-ending defect needs the octets, the direction, and the option state at that exact point in the stream.
Linemode moved the editing, not the meaning
RFC 1184 attacked a different cost. Character-at-a-time interaction was miserable across long-delay links and expensive on networks billed per packet. Linemode let a client edit locally and send a finished command line, rather than making every keystroke wait for a remote echo.
The option did not throw the NVT distinction away. With Linemode editing active, a normal local line terminator went out as CR LF. With editing off, carriage return went out as CR NUL, LF as LF, and a special “line complete” key as CR LF.
Server output stayed the server's responsibility in every mode: CR LF for newline, CR NUL for carriage return alone, LF for line feed alone. Editing authority could drift closer to the human without letting the client invent the meaning of server output.
That separation is a useful design clue. Placement and semantics are different questions. A system may relocate buffering or editing for latency reasons while keeping the canonical representation stable at the boundary.
The old printer survived inside network text
The NVT printer can feel like an antique metaphor, but its line-ending choice escaped the remote-login session and went everywhere. Early Internet text protocols repeatedly leaned on a network form that separated local storage from wire representation.
RFC 5198 revisited that history while defining Net-Unicode. It kept CRLF as the line-ending form for network text and preserved the structural requirement that CR be followed by LF or NUL. Then it discouraged CR NUL. Modern character composition and markup made many of the printer-motion tricks unnecessary, and NUL is hazardous in software that treats it as a string terminator.
That is not evidence the 1972 choice was foolish. It is a mechanism ageing honestly. CR NUL solved a real question when carriage motion was part of the shared abstraction. Later text formats kept the installed line boundary while narrowing the exceptional form whose original use had faded.
The IANA Telnet Options registry still records Binary Transmission, Linemode, carriage-return disposition and later character-set options. The registry proves the vocabulary has stable names. It says nothing about how many current devices implement them correctly.
A small grammar carried a constitutional idea
Telnet's solution did not appoint one host to dictate how every terminal should work. It placed only the interoperable distinction in the common layer. The sender selected one of two NVT actions. The receiver could validate that selection locally by reading the next byte. Each side kept authority over its own device mapping.
The costly failures came from crossing those boundaries. A client that mapped Enter too early erased a possible bare CR. A gateway that normalised CR NUL without checking option state corrupted binary data. A receiver that acted on CR before its companion arrived guessed at something the protocol had promised to state. A library that treated NUL as end-of-string truncated the very sequence meant to remove ambiguity.
The lesson is bigger than line endings. When one symbol cannot carry enough meaning, the protocol should add a finite discriminator and say which layer consumes it. Compatibility turns fragile the moment convention substitutes for explicit state.
Sources and evidence limits
- https://www.rfc-editor.org/rfc/rfc318.html
- https://www.rfc-editor.org/rfc/rfc854.html
- https://www.rfc-editor.org/rfc/rfc856.html
- https://www.rfc-editor.org/rfc/rfc1123.html
- https://www.rfc-editor.org/rfc/rfc1184.html
- https://www.rfc-editor.org/rfc/rfc5198.html
- https://www.iana.org/assignments/telnet-options/telnet-options.xhtml
These sources establish the protocol model, the historical rule, the host-requirements clarification, the negotiated exceptions and the registered option vocabulary. They do not measure current Telnet use, certify any product's defaults, or prove that every historical implementation behaved alike. The article therefore treats CR NUL as a scoped representation rule, not as a universal property of text.
Member Briefing
Read the full trend briefing
Members read the full briefing with the source notes behind every finding.
Strategic Circle
A daily briefing in your language, built from changes we have verified.
Join for USD 20/monthCancel anytime.
Members also get the full research library, a daily briefing on the networks they follow and the private forum.






