Re: Wrong FQDN in "From"

2009-07-13 Thread Jaime Kikpole
On Mon, Jul 13, 2009 at 1:47 PM, Victor
Duchovni wrote:
>> Don't use a CNAME in a mail address.

Why not?  After all, how would you handle vhosts if you can't send as
the CNAME record?


> Sendmail often rewrites these. Postfix typically leaves CNAME domains
> alone. The OP should avoid these, but otherwise, should find out *where*
> along the delivery path the CNAME is replaced with the underlying name.

I'm the OP.  Based on the data I have, I believe that what goes into
postfix uses the CNAME but what comes out is using the A record.  I do
have a little doubt, though, as the /var/log/maillog file shows
"w...@atlas.cairodurham.org" connecting to postfix.

If I "grep cairo main.cf*" and "grep atlas main.cf*", I don't see
anything that should be rewriting this.

I just tried a test with "telnet localhost 25" to be sure about this.
That test appears to have worked out the way that I want.  IOW, that
it came from local_u...@cns.cairodurham.org.  This gave me some
doubts.  However, when I change DNS so that both atlas.cairodurham.org
and cns.cairodurham.org are A records (and the reverse DNS points to
atlas) and try to send email from Request Tracker again, I find that
it works the way that I want.

So its caused by some combination of factors which includes the CNAME
and Request Tracker.  (Remember, using telnet to manually build and
send a message sent it as cns.cairodurham.org before the DNS changed.)

Any reason I shouldn't leave the DNS like this?

Also, that question about virtual hosting of several email domains was
not rhetorical.  How is a sysadmin supposed to configure their DNS for
such a thing?

Thanks,
Jaime

-- 
Network Administrator
Cairo-Durham Central School District
http://cns.cairodurham.org


Wrong FQDN in "From"

2009-07-13 Thread Jaime Kikpole
I just migrated most users from one server to another one.  However, a
few things still need to work on the first server.  One of them is a
web-based program named Request Tracker (RT).

When RT sends an email to me, it is coming from
r...@atlas.cairodurham.org.  I am trying to make that say
r...@cns.cairodurham.org, instead.

The reverse DNS lookup is atlas, but there is also a CNAME for cns.
The original email coming out of RT says "From: "Enoch Root via RT"
".  However, it seems to be rewrtiten as
"From: "Enoch Root via RT" " by the time it
arrives in my inbox.

The mail logs show w...@atlas.cairodurham.org making a connection to
send email.  The webapp is installed on the same host as postfix.

I have the following settings:
atlas:etc>grep cairo *
RT_SiteConfig.pm:Set($rtname , "cairodurham.org");
RT_SiteConfig.pm:Set($Organization , "cairodurham.org");
RT_SiteConfig.pm:Set($RTAddressRegexp ,
'^{rt|help|rt-commen...@{cns.|}cairodurham.org$');
RT_SiteConfig.pm:Set($CorrespondAddress , 'r...@cns.cairodurham.org');
RT_SiteConfig.pm:Set($CommentAddress , 'rt-comm...@cns.cairodurham.org');
RT_SiteConfig.pm:Set($WebBaseURL , "http://cns.cairodurham.org";);
atlas:etc>grep atlas *
atlas:etc>

What do you guys think?  Am I missing something obvious here?

Thanks in advance,
Jaime

-- 
Network Administrator
Cairo-Durham Central School District
http://cns.cairodurham.org