[exim] Destination IP-based routing

Pàgina inicial
Delete this message
Reply to this message
Autor: Phill Wood
Data:  
A: exim-users
Assumpte: [exim] Destination IP-based routing
Hi All
I'm running Exim 4.34 which relays mail for serveral internal
networks (with internal DNS) together with with an Internet gateway.
It works great. But what I've been asked to do now is to deny routing
to the Internet gateway machine for one network. This network must,
however, be allowed to mail the other internal networks. I *need* to
do this by IP. I wish I could do it by domain, but I'm not allowed for
various reasons I won't go into.

Since I already have other dnslookup routers which differentiate
between Internet gateway & Internal (based on the IP of the target
host) I thought I could do something similar. However, I need the
router to fail, not defer, and I couldn't find a way of doing this. I
therefore ended up with:

refuse_internet::
driver = redirect
allow_fail
data = ":fail:"
ignore_target_hosts = 10.10.0.0/18:192.168.3.0/23:192.168.12.0/23
condition = ${lookup{$sender_host_address}iplsearch{/usr/local/etc/no_internet_relay}{yes}{no}}
self = pass


.. which doesn't work. I suspect this is because the MX records
haven't been looked up so I really need a dnslookup router but I don't
know how to make it fail!

All help appreciated.


Thanks

Phill