Brian Candler writes:
On Thu, Nov 02, 2006 at 06:20:12PM -0500, Sam Varshavchik wrote:
Craig Jackson writes:
I have created the hostname file so that the domain on outgoing email is
correct. However, the mail from: domain continues to be the host name of
the server. Mail is being bounced by servers that perform DNS lookups.
Why would sqwebmail do this? How do I fix this?
The return address is set based on the login address. If you are using
system accounts, the login address does not return a domain, so your mail
server will use its own default for the return address, and that's what you
need to reconfigure.
You mean, when sqwebmail invokes sendit.sh:
exec @mailer@ $DSN -f "$1"
that sqwebmail sets $1 to "username" and not "username@<hostname-setting>" ?
Looking at the code (newmsg.c where it execs SENDITSH), I think this
argument is set to login_returnaddr(). In that function, if the login name
doesn't contain "@" then the configured domain is appended by calling
myhostname(). Therefore, the MTA never has to add its own default domain. Or
have I misread the code?
That's true, but myhostname() will return the system hostname, if all else
fails.