Hi all,
I'm trying to switch from sendmail to exim, and I'm facing some problems.
I have a small net and a dialup connection to internet. Since only some accounts
on one machine are enabled to internet mail usage, I'd like to rewrite headers
to supply correct reply-to and From field (and maybe some host masquerading,
since my small net has no offical IP/DNS enties) for mail leaving my net, while
maintaining as is for internal mail user. I'd also like to keep it trasparent
to users (i.e. not using MUA headers rewrite)

Here are the simple rules for rewriting I'm trying (and failing) to implement:

Source Addr     Dest. Addr      Rule
userA           UserB           don't do anything (local mail)
userA           [EMAIL PROTECTED]       don't do anything (LAN mail), route it
userA           [EMAIL PROTECTED] rewrite From,Reply-To and route thru IPS 
mailhub

Here are the relevant parts from my exim.conf

qualify_domain = machine.my.net
local_domains = localhost:@

...

# ROUTERS CONFIG

# for LAN mail
lookuphost:
  driver = lookuphost,
  domains = "*.my.net",
  transport = smtp;

# for internet mail
smarthost:
  driver = domainlist,
  transport = smtp,
  route_list = "* my.isp.mailhub byname";

...

# REWRITE CONFIGURATION

# for outbound mail
[EMAIL PROTECTED] "[EMAIL PROTECTED] match {$h_to:} {my.net} {my.net} {my.isp} 
}"  Ffrs

This rule doesn't seem to work. I read this (but I'm surely wrong)

for every addr, if the To: header matches "my.net", let it go, else go with 
my.isp

The effect of the above rule is that all mail except local have rewritten 
headers. It looks to me that the problem is with $h_to:
Can somebody shed some light on what I'm doing wrong, or suggest a better 
approach?
Thanks

PS: I think exim should become debian default MTA.
-- 
||    || |||||||  Marco Frattola                     Microsoft is not the answer
||`..'|| |||...   Piacenza, Italy                    Microsoft is the question
|||  ||| |||''    [EMAIL PROTECTED]            "No" is the answer
|||  ||| |||      www.enjoy.it/users/~mk/index.html  Live Linux, live free!


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to