On 05-Aug-2012 11:55:47 MJ Ray wrote:
(Ted Harding) Ted.Harding@wlandres.net
However, when I send the mail out, it seems that exim4 changes the "Sender:" address to "ted@deb", "deb" being the name of my machine on my home LAN (as set in /etc/hosts), and "ted" being the user. [...] What I want to do is ensure that exim4 (aliased as 'sendmail') either does not change the "Sender:" header as it is while still in the outbox, or else sets it anyway to [...]
/etc/email-addresses defines the outgoing externally-safe address for each user in the usual debian exim4-config.
If a user is not listed in there, you're getting the default hostname (FQDN).
Thanks for this tip. I edited that file to add (see below) what I inferred should be the correct entry:
# This is /etc/email-addresses. It is part of the exim package # # This file contains email addresses to use for outgoing mail. Any local # part not in here will be qualified by the system domain as normal. # # It should contain lines of the form: # #user: someone@isp.com #otheruser: someoneelse@anotherisp.com ted: ted.harding@wlandres.net
Unfortunately, this seems to have had no effect, even after I rebooted! I am now tryiong to suss out how to promote user "ted" to trusted user status. Currently reading though
/usr/share/doc/exim4-base/spec.txt.gz
and trying to locate specific instructions!
Maybe I'll get there, but anyway thanks for the tip. Ted.
I don't think "deb" should be the FQDN of any machine, so there's probably some problem with /etc/hosts or /etc/hostname but setting the address in email-addresses would be OK.
My LAN domain is locally called "fort.knox.uk" (unknown to the outside world, of course), and the /etc/hosts entry is:
192.168.1.15 deb.fort.knox.uk deb
so "deb" is the abbreviated alias (used when I e.g. "ssh -X deb" from another machine). Not sure why exim4 picked that rather than the full name "deb.fort.knox.uk". (BTW, "deb" was chosen because at the time it was the only machine with a Debian OS; now there is "deb2"...).
If you prefer to do it with command-line options, -f might do it, but I suspect email-addresses may override it.
I rather fear it would (given what I have managed to suss out so far).
Hope that informs,
MJ Ray (slef), member of www.software.coop, a for-more-than-profit co-op.
Best wishes, Ted.
------------------------------------------------- E-Mail: (Ted Harding) Ted.Harding@wlandres.net Date: 05-Aug-2012 Time: 19:39:58 This message was sent by XFMail -------------------------------------------------