Is this a mimetools/rfc822 bug?

Steve Holden sholden at holdenweb.com
Tue Jun 26 08:26:57 EDT 2001


"Sheila King" <sheila at thinkspot.net> wrote in ...
> On Mon, 25 Jun 2001 16:37:51 -0400, barry at digicool.com (Barry A. Warsaw)
> wrote about Re: Is this a mimetools/rfc822 bug?:
>
> :
> :>>>>> "SK" == Sheila King <sheila at spamcop.net> writes:
> :
> :    SK> So far as I know, leading newline characters are not allowed
> :    SK> in the header. A newline character indicates the end of the
> :    SK> headers.
> :
> :Correct, and rfc822 is fairly strict about what it accepts.  Leading
> :empty lines in the text will toggle it over from "reading-headers"
> :mode to "reading-body" mode.  It's even worse if you have no headers,
> :but your first body line has a colon in it!
>
> But, according to the RFC's a header is required. A message body is not
> required.
>
> According to RFCs I recall: Your message header must have at least one
> of the following headers: To, Bcc, or CC. I believe that is the minimal
> header: any one of the To-type fields. No other headers are required,
> and no message body is required.
>
You don't always get to deal with standards-conformant mail systems, though,
so the classic Internet advice still stands: be precise in what you generate
and tolerant about what you'll accept. I've had to deal with some mailers
which will reject SMTP transactions because there was no Date: header!

regards
 Steve
--
http://www.holdenweb.com/








More information about the Python-list mailing list