[EXIM] Planning a mail gateway

Top Page
Delete this message
Reply to this message
Author: Peter Burgess
Date:  
To: EXIM users list
Subject: [EXIM] Planning a mail gateway
Hi,
I have set up exim with a trivial setup on a couple of boxes to handle
local mail, but now I am intending to replace sendmail8.8.8 on our
"gateway" box with Exim 3.02 as looks like an "industrial strength" MTA
with good documentation and support.

I would like a bit of advice to help with my planning...

The firewall directs all mail to this machine on port 25 and all mail to
external domains is relayed through this box to the firewall (the
firewall is dumb).
Here are the rules I want to implement:
1. most mail is addressed to user@??? which goes to
user@???
2. some mail is addressed to user@??? which goes to
user2@???
3. some mail is addressed to user@??? is just relayed
4. all mail to external domains is relayed through this box to the
firewall

All mail from internal mail domains is relayed to other hosts or the
firewall
1. most mail is addressed FROM user@??? and is rewritten as
user@???
2. some mail is addressed FROM user@??? and is rewritten as
user2@???

What is the best configuration to achieve this, at first I was going to
set local_domains to *my.domain and use an alias list and probably use a
filter to rewrite the From or Sender etc. to the masqueraded form with a
"central filter"?

Or would I be better off setting local_domain to mailhub.my.domain and
doing all the rewriting with a filter and maybe a perl subroutine?

In sendmail I do this with a single dbm lookup in the local part of
ruleset 0 and a rewrite rule to get rid of the "gwmail" in the "From"
headers followed by a dbm lookup to handle the rest in "Ruleset 93 --
convert header names to masqueraded form". This was a fairly
unmaintainable hack that I want to get away from - hence Exim.

I need a few hints to get me started!

Thanks
Peter

-- 
Peter Burgess                 email: pburgess@???
UNIX Systems Administrator         phone: +64 4 4600 184
Land Information New Zealand           fax: +64 4 4600 373
Wellington, New Zealand            mobile: 025 51 44 57


--
*** Exim information can be found at http://www.exim.org/ ***