Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Nov 2005 11:41:15 -0600
From:      Greg Barniskis <nalists@scls.lib.wi.us>
To:        "Mark J. Sommer" <msommer@argotsoft.com>
Cc:        'Hans Nieser' <hans@nieser.net>, freebsd-questions@freebsd.org
Subject:   Re: How to redirect mail sent to root to external mailbox?
Message-ID:  <4378CC3B.901@scls.lib.wi.us>
In-Reply-To: <200511141556.jAEFue6C064881@argotsoft.com>
References:  <200511141556.jAEFue6C064881@argotsoft.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Mark J. Sommer wrote:
>>-----Original Message-----
>>From: Greg Barniskis [mailto:nalists@scls.lib.wi.us] 
>>Sent: Monday, November 14, 2005 8:02 AM
>>To: Mark J. Sommer
>>Cc: 'Hans Nieser'; freebsd-questions@freebsd.org
>>Subject: Re: How to redirect mail sent to root to external mailbox?
>>
>>Mark J. Sommer wrote:
>>
>>
>>>This is really a sendmail question I believe.  Your problem is 
>>>probably because root doesn't get masqueraded.  In your 
>>
>>sendmail.cf, 
>>
>>>is there a line like the following:
>>>
>>>CEroot
>>>
>>>or
>>>
>>>C{E}root
>>>
>>>If so, comment it out and restart sendmail.
>>
>>That will work but the config will get overwritten on 
>>upgrades. It is best to override the defaults via the mc 
>>config generator, so that "CE root" doesn't appear in the first place.
> 
> 
> Yeah, I looked all over /usr/share/sendmail to find that config, but I
> couldn't.  When I resolved this, I think I modified the template that the
> macros start from to avoid having it re-written.  I'd appreciate it if
> anyone can pass on what macro it is that controls this.

A glance at the bat book tells me the exception (no masquerading) is 
  inserted by

EXPOSED_USER(root)

Doh! I see it now. FreeBSD doesn't do it this way (so no "CE root").

For FreeBSD, non-masquerading for root is simply set by an entry in 
/etc/mail/exposed-user-names, which is brought in by the 
EXPOSED_USER_FILE directive in the default mc file. Edit 
exposed-user-names to your heart's content (and pay attention in 
case mergemaster throws it back at you during upgrades), and all 
should be well.

-- 
Greg Barniskis, Computer Systems Integrator
South Central Library System (SCLS)
Library Interchange Network (LINK)
<gregb at scls.lib.wi.us>, (608) 266-6348



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4378CC3B.901>