[Mimedefang] Bare returns in message body
Les Mikesell
les at futuresource.com
Wed Nov 9 13:44:42 EST 2005
On Wed, 2005-11-09 at 07:35, David F. Skoll wrote:
> Joseph Brennan wrote:
>
> > We're interested in patching mimedefang.c to do this, but have this
> > funny feeling that there is a good reason David removes them. What
> > would it break?
>
> I can't remember why I remove them (it's been a while), but I did
> have a good reason.
>
> RFC 2821 says:
>
> In addition, the appearance of "bare" "CR" or "LF" characters in text
> (i.e., either without the other) has a long history of causing
> problems in mail implementations and applications that use the mail
> system as a tool. SMTP client implementations MUST NOT transmit
> these characters except when they are intended as line terminators
> and then MUST, as indicated above, transmit them only as a <CRLF>
> sequence.
>
> RFC 2822 says:
>
> - CR and LF MUST only occur together as CRLF; they MUST NOT appear
> independently in the body.
>
> Note that these are MUST NOT requirements, not SHOULD NOT requirements.
> So in theory, it is OK to reject such messages.
The RFC's deal only in 'wire level' representation during the SMTP
conversation. Mail transports/delivery agents normally convert
to/from the local line endings. I don't think there is any such
thing as a universal file representation (the MIME folks really
missed a need here). Since MimeDefang's copy is sort-of still
in transport but is actually a local file copy it is bound to be
wrong for something.
--
Les Mikesell
les at futuresource.com
More information about the MIMEDefang
mailing list