[5875] in Athena Bugs
sendmail and return-receipt addresses (comp.bugs.4bsd)
daemon@ATHENA.MIT.EDU (Jonathan I. Kamens)
Tue Aug 28 10:37:13 1990
Date: Tue, 28 Aug 90 10:37:02 -0400
From: Jonathan I. Kamens <jik@PIT-MANAGER.MIT.EDU>
To: bugs@ATHENA.MIT.EDU
Cc: jik@PIT-MANAGER.MIT.EDU
In article <976@nikhefh.nikhef.nl>, e07@nikhefh.nikhef.nl (Eric Wassenaar) writes:
|>
|> Ref: All versions of sendmail up to/including 5.64
|>
|> Description:
|> Sendmail will rewrite 'new style' addresses in the header
|> lines incorrectly when returning a message to the sender,
|> e.g. when mailing back a return receipt or an error message.
|>
|> Repeat-by:
|> Send a message To: him@hisdomain
|> and ask for a Return-Receipt-To: Your Name <you@yourdomain>
|>
|> Most probably (assuming his sendmail generates fully qualified
|> addresses, and can handle 'old style' addresses) this appears
|> in the return message as
|> To: Your@hisdomain, Name@hisdomain, <you@yourdomain>
|>
|> Analysis:
|> Sendmail returns a message using the sequence
|> sendtolist(recipient_list, ...)
|> returntosender(...)
|> The recipient(s) are parsed within sendtolist(), the 'new style'
|> address is recognized, and the EF_OLDSTYLE bit is cleared in the
|> envelope e_flags field.
|> The actual delivery is done within returntosender(), but this
|> routine switches to a temporary envelope which gets the default
|> e_flags with the EF_OLDSTYLE bit set.
|> During subsequent header rewriting, in putheader() and commaize(),
|> the headers are handled incorrectly, with the above result.
|>
|> Fix:
|> In the routine returntosender() in the file savemail.c, after
|> switching to the temporary envelope ee, add the following lines:
|>
|> if (!bitset(EF_OLDSTYLE, CurEnv->e_flags))
|> ee->e_flags &= ~EF_OLDSTYLE;
|>
|> Eric Wassenaar
|> --
|> Organization: NIKHEF-H, National Institute for Nuclear and High-Energy Physics
|> Address: Kruislaan 409, P.O. Box 41882, 1009 DB Amsterdam, the Netherlands
|> Phone: +31 20 592 0412, Home: +31 20 909449, Telefax: +31 20 592 5155
|> Internet: e07@nikhef.nl
Jonathan Kamens USnail:
MIT Project Athena 11 Ashford Terrace
jik@Athena.MIT.EDU Allston, MA 02134
Office: 617-253-8495 Home: 617-782-0710