Re: [EXIM] How to use dnsdb query lookup

Top Page
Delete this message
Reply to this message
Author: Vadim Vygonets
Date:  
To: exim-users
Subject: Re: [EXIM] How to use dnsdb query lookup
Nobody seems to answer this, so I'll try.

Quoth Rick Ballard on Fri, May 14, 1999:
> The new company has set up a dns lookup for the
> addresses, so I presume I can use the new style dnsdb query-style
> lookup to do this.


Do they use the IN (Internet) class or HS (Hesiod) class for the
database?

> How do I use the dnsdb query-style lookup in a rewrite rule ?
>
> Here is my current rewrite rule:
>
> #--- replace old addresses with new addresses everywhere
> #------ If not found in the lookup table, do not rewrite
> *@old.com               ${lookup{lc:$1}dbm{/usr/exim/newaddresses}{$value@???}fail}


Hmm.  I think you should try something like:
*@old.com               ${lookup dnsdb{lc:$1.the.dom.ain}{$value@???}fail}


Where 'the.dom.ain' may be something like 'usermap.new.com', and
if foo@??? returns bar@???, a query for
foo.usermap.new.com must return 'bar'.

Vadik.

-- 
Any language that involves exposing private parts to friends is a
tad suspect...
    -- Geoff Lane in the Monastery, about C++


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