Re: [ietf-smtp] Stray <LF> in the middle of messages

John Levine <johnl@taugh.com> Wed, 10 June 2020 18:12 UTC

Return-Path: <johnl@iecc.com>
X-Original-To: ietf-smtp@ietfa.amsl.com
Delivered-To: ietf-smtp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 73EAB3A0A9A for <ietf-smtp@ietfa.amsl.com>; Wed, 10 Jun 2020 11:12:50 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.851
X-Spam-Level:
X-Spam-Status: No, score=-1.851 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, HEADER_FROM_DIFFERENT_DOMAINS=0.249, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (1536-bit key) header.d=iecc.com header.b=hf4u4R3t; dkim=pass (1536-bit key) header.d=taugh.com header.b=Zjpuu2PT
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Jb501TBcDu5U for <ietf-smtp@ietfa.amsl.com>; Wed, 10 Jun 2020 11:12:49 -0700 (PDT)
Received: from gal.iecc.com (gal.iecc.com [IPv6:2001:470:1f07:1126:0:43:6f73:7461]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id CD8D23A0A78 for <ietf-smtp@ietf.org>; Wed, 10 Jun 2020 11:12:48 -0700 (PDT)
Received: (qmail 27095 invoked from network); 10 Jun 2020 18:12:47 -0000
DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=iecc.com; h=date:message-id:from:to:cc:subject:in-reply-to:mime-version:content-type:content-transfer-encoding; s=69d5.5ee1229f.k2006; bh=YbgKNgo1iEwqKU2TBiF0K9qHYumSdQsnz4nnS0e++84=; b=hf4u4R3tvmmPzm97ulKk48Mu4aaTn7atTuosEqr2jAEoIJeFzE6uHgeY4qdUuWhOY+LsbNeITMrYumiccQrefgr0eoUS1L3cctuZjL7SBfiwrLdRz9UqF8JwANQUAe3eKC1ioJOTBuzB0k0Xa0KDANem5RTz/2Be88/NwTdPnaxTQ6NZvCMMr6780+OLDZepxTzyISVSxqqvxZs6fO9JaoZCirM7gaDlNU+i2X+inhqO1IHWcFud8hfWDS9P5Q5P
DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=taugh.com; h=date:message-id:from:to:cc:subject:in-reply-to:mime-version:content-type:content-transfer-encoding; s=69d5.5ee1229f.k2006; bh=YbgKNgo1iEwqKU2TBiF0K9qHYumSdQsnz4nnS0e++84=; b=Zjpuu2PTSSlMOcb3fi16tJv1J5fWk4JsVpFbnJyB4/170425bBw74VxRt5CX05HFHDKsE9g9T0n9MzmoMnU3wuYial4kw6aR/tCuoKmGu7/riIMQwvYXVMM894t5pizWLNomiWEg46jCJQ70y8WrhTp4FdpUibcnzBz9gYS30fehOu7kILv2Xti2rZ4YKcatNQuMnPF7C/EB3hmf3a4A4xVowdZvIfVUNG+jrD3rzCnmXOc/swJ9w0QpnaQKBeWR
Received: from ary.qy ([IPv6:2001:470:1f07:1126::78:696d:6170]) by imap.iecc.com ([IPv6:2001:470:1f07:1126::78:696d:6170]) with ESMTP via TCP6; 10 Jun 2020 18:12:47 -0000
Received: by ary.qy (Postfix, from userid 501) id 676111A5C823; Wed, 10 Jun 2020 14:12:47 -0400 (EDT)
Date: 10 Jun 2020 14:12:47 -0400
Message-Id: <20200610181247.676111A5C823@ary.qy>
From: "John Levine" <johnl@taugh.com>
To: ietf-smtp@ietf.org
Cc: paul@pscs.co.uk
In-Reply-To: <d73baf1d-ef7f-7c0e-1e5e-10d8ba748af7@pscs.co.uk>
Organization: Taughannock Networks
X-Headerized: yes
Mime-Version: 1.0
Content-type: text/plain; charset=utf-8
Content-transfer-encoding: 8bit
Archived-At: <https://mailarchive.ietf.org/arch/msg/ietf-smtp/WGDyjdL8mitzuwFx0AZGHw5FcO4>
Subject: Re: [ietf-smtp] Stray <LF> in the middle of messages
X-BeenThere: ietf-smtp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: "Discussion of issues related to Simple Mail Transfer Protocol \(SMTP\) \[RFC 821, RFC 2821, RFC 5321\]" <ietf-smtp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ietf-smtp>, <mailto:ietf-smtp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ietf-smtp/>
List-Post: <mailto:ietf-smtp@ietf.org>
List-Help: <mailto:ietf-smtp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ietf-smtp>, <mailto:ietf-smtp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Wed, 10 Jun 2020 18:12:50 -0000

In article <d73baf1d-ef7f-7c0e-1e5e-10d8ba748af7@pscs.co.uk> you write:
>CR takes you back to the start of the current line, and LF takes you to 
>the next line (at the current position), ...

Except when it doesn't. In 1969 when people at Bell Labs were writing
the early versions of Unix, they had a lot of the otherwise obscure
Model 37 Teletype, which had upper and lower case and where the 012
character was a new line (NL), moving the print position to the
beginning of the next line. It had unusually sophisticated buffering
for the era and didn't need any delay characters. Teletype was an
AT&T subsidiary so it's not surprising that the Labs would get early
versions of their products.

Other places the models 33 and 35 were the most popular terminals,
both of which needed CR/LF to print properly. But as Dave noted, we
had to pick some line end convention and given how common CR/LF was at
the time, it was as good a convention as any.

Even the earliest Unix systems had tty drivers that could adapt to
model 33 or 35, adding CR in front of NL and providing escapes to
enter lower case letters and other characters not on the keyboard.