  | |  | Sendmail masquerading not working | Sendmail masquerading not working 2005-06-06 - By Greg Hosler
Back Your original mail had 2 "MASQUERADE_AS" lines. I believe that you don't want that. only one.
as for your most recent question, to quote or not to quote, I believe either is acceptable. the quotes (single open, and single close) prevent expansion. Otherwise, any wildcard characters in the text string might get expanded. (ref: /usr/share/sendmail-cf/README)
and as originally noted, you probably do NOT want a trailing dot in any of your MASQUERADE lines.
finally, the MASQUERADE_DOMAIN is used to map one domain (the listed domain in MASQUERADE_DOMAIN) to another domain (the listed MASQUERADE_AS one, which is why you do NOT want more than one MASQUERADE_AS line!)
it's not clear whether using MASQUERADE_AS *along with* MASQUERADE_DOMAIN will map the local domain ALONG WITH the specified domain (i.e. the MASQUERADE_AS domain) or not. (You might be getting bit here if it does not!). i.e. you are showing BOTH
MASQUERADE_AS(`bigcorp.com') and MASQUERADE_DOMAIN(`bigcorp.com')
That almost certainly is NOT what you want. i.e. you want something like this:
MASQUERADE_AS(`<your external domain name>') and MASQUERADE_DOMAIN(`<your internal DIFFERENT from external domain name>')
If you have several internal domain names to masquerade, (or some that you do NOT want to masquerade!) that is all covered in /usr/share/sendmail-cf/README!
The noted README file has quite a bit of information on the various sendmail.mc options. You might want to search for MASQUERADE and review the various sections.
Hope that is helpful,
-Greg
On 07-Jun-2005 IECISA.Ortega Gonzalez, Carlos wrote: > Kevin Jackson wrote: > > > >>make sure you have the package sendmail-cf installed. > >>Then make the change in /etc/mail/sendmail.mc > >>make -C /etc/mail/ > >>service sendmail restart > > > > I've tried this, and still the emails keep the original email address. > > > >>I'm presuming this is a typo too in just your email: > >>MASQUERADE_AS(`bigcorp.com.') > >>MASQUERADE_DOMAIN(`bigcorp.com.') > >>should be > >>MASQUERADE_AS(`bigcorp.com') > >>MASQUERADE_DOMAIN(`bigcorp.com') > >>Without the period at the end. > > > > I copied that extract from the RedHat Reference Guide for RHEL 3.0. I've > tried using the period at the end, and also not using the period. The result > is the same. > > I've also noticed that there are differences between this code and my > default sendmail.mc file. My default sendmail.mc file has the following > values: > > > > FEATURE(always_add_domain)dnl > > dnl MASQUERADE_AS(`mydomain.com')dnl > > dnl MASQUERADE_DOMAIN(localhost)dnl > > dnl FEATURE(masquerade_envelope)dnl > > dnl FEATURE(masquerade_entire_domain)dnl > > > > Appart from the dnls, the quotes vary. Which format is correct? Or are both > formats ok? > > > > When I send a mail with the -v option, I see > > > >>>> MAIL From:<the original address> > > > > Shouldn't I see > > > >>>> MAIL From:<the new address> ??? > > > > Thanks a lot for your help. > > > > Regards, > > > > Carlos Ortega Gonz??lez > > Iberia Sistemas > > DS/SP/Unidad Prod. Ordenadores > > email: HYPERLINK > "mailto:iecisa.cortegag@(protected)"iecisa.cortegag@(protected) > > Extensi??n: 4691 > > > > > -- > No virus found in this outgoing message. > Checked by AVG Anti-Virus. > Version: 7.0.322 / Virus Database: 267.4.1 - Release Date: 02/06/2005 > > > -- ---- ---- ---- ---- ---- ---- ---- ---- --- > Has decidido el mejor precio. Has decidido IBERIA.com > You?ve chosen the best price. You?ve chosen IBERIA.com > -- ---- ---- ---- ---- ---- ---- ---- ---- --- > http://www.iberia.com >
+-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------+ You can release software that's good, software that's inexpensive, or software that's available on time. You can usually release software that has 2 of these 3 attributes -- but not all 3. | Greg Hosler greg@(protected) | +-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------+
-- Taroon-list mailing list Taroon-list@(protected) http://www.redhat.com/mailman/listinfo/taroon-list
Earn $52 per hosting referral at Lunarpages.
|
|
 |