[wellylug] sendmail - enough for today!
Ewen McNeill
wellylug at ewen.mcneill.gen.nz
Mon Aug 25 10:31:51 NZST 2003
In message <20030825190704.GA1786 at Mercury>, Persian writes:
>I put the line in .muttrc as set envelope_from=yes
>but I am not sure what it is doing. My from header in the .muttrc was
>already correct, it is the same .muttrc I used on my old system.
There are two "From" headers in an email message (at least one sent
through SMTP). The first is sometimes called the "envelope" From
header, and is the one that sendmail uses. Effectively when the mail is
transfered your sendmail connects to a mail server on the Internet and
says "I've got a message here from X, to Y", it only looks at the
"envelope" addresses.
The other header is the From: header in the message itself, which is the
one that is normally displayed in the email client. (Microsoft Outlook
being the main exception I'm aware of.)
Traditionally command line email clients will only set the From: header
in the message itself, and leave the rest for the mail system to sort out
including the envelope address. This worked well when all Unix systems
had a permanent domain name, and were connected to a big network which
could give them all the required information. And was done mainly to
make it harder for people to pretend to be someone else.
It all works much less well in the world of dynamic IP address, and
temporary connections to the Internet.
(Windows email clients have pretty much always set both of these
addresses from one source, because they usually had nothing else to get
the information from. And GUI based email clients for Linux seem to
have followed the Windows tradition.)
Since mutt is trying to keep up with the times, it offers an option (set
envelope_from) which tells it to set both the displayed From: header,
and the "hidden" envelope From address known to the mail server, to be
the same thing.
In order for this to work your local mail server must "believe" what
mutt tells it (which is the purpose of the trusted-users entry -- only
certain users are given this privilege of making up their own name).
Anyway, as of when I last looked, your messages had the correct details
in the displayed From: line, so most people should be able to reply
fine.
Hoewver the envelope From address had a curious mix of your local
machine log in name (lyndsay) and your ISP name (ihug.co.nz); I think it
got the latter from /etc/mailname. Which suggests that either mutt
wasn't setting the envelope From line like it was told to, or sendmail
was refusing to believe it.
As I said at the time, it's sufficiently close that it means you should
now be able to get mail through even to people who filter out the
localhost.localdomain bit (which was your original source of problems).
But, technically, it's not correct.
FWIW, I strongly suspect that this was the situation you were in with
mutt and exim before, so you're probably back to as good as it was
before.
The only real catch with the current setup is that you're unlikely to
get the bounce messages if your mail cannot be delivered (because bounce
messages are generally -- well supposed to be -- delivered to the
envelope From address).
If you do happen to take your machine along to next month's Wellylug
meeting perhaps you could ask someone there to take another look at the
sendmail/mutt configuration and see if they can identify anything else
to change.
Ewen
More information about the wellylug
mailing list