Re: [Exim] pull back lookup info as variable

Pàgina inicial
Delete this message
Reply to this message
Autor: Philip Hazel
Data:  
A: Dave Markham
CC: exim-users
Assumpte: Re: [Exim] pull back lookup info as variable
On Mon, 12 Jul 2004, Dave Markham wrote:

> Does anyone know how to pull back the result of a lookup in a router
> so you can run a condition based on the ip the lookup gets back??


If you mean DNS lookup, see the "dnsdb" lookup type.

> I need to lookup stuff based on domain name and depending on the MX ip
> address it gets back i need the router to pass or fail so it can go to
> transport or onto the next router. I am required to route mails to
> different locations depending on the ip address of the MX record for
> domains. I cannot determine and list all the domains see as they are
> unknown, but the ip address range is known.


MX records do not contain IP addresses. They contain host names. You
would have to lookup up the MX records (plural) and then the hosts' A or
AAAA records. This is not easy to do manually.

There is another Exim feature that might help. Take a look at the
translate_ip_address generic router option. At first sight, it looks as
though it will do what you want.

--
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.
Get the Exim 4 book:    http://www.uit.co.uk/exim-book