Re: [exim] A query re loopups

Góra strony
Delete this message
Reply to this message
Autor: Tony Finch
Data:  
Dla: exim-users
Temat: Re: [exim] A query re loopups
On Tue, 9 Nov 2004, Philip Hazel wrote:

> On Tue, 9 Nov 2004 russell-exim@??? wrote:
>
> > I am using Exim from Debian's Sarge, version 4.34-6.
> > I had a lookup of the form:
> >
> > ${lookup {$local_part@$domain} partial1-lsearch*@ {somefile}}
>
> The two searches are not designed to be combined. The partial one is
> designed for domains. I had never thought about combining the two. It
> seems that the code is taking the partial setting first, and then the *@
> setting. I will add an item to the Wish List suggesting that the
> combination be made more useful, along the lines of what you suggest.


I encountered this recently with our configuration. It used to
include the ACL clause:

  accept   senders       = cdb*@;DB/nocallout.cdb


but I needed to be able to add wildcards to cover all of a domain's
subordinates, and the partial- lookups didn't do the right thing with
whole email addresses. I now have the following, along with an adjusted
table:

  accept   condition     = ${lookup{${lc:$sender_address}} \
                             cdb{DB/nocallout.cdb} {yes} \
                              {${lookup{${lc:$sender_address_domain}} \
                                 partial-cdb{DB/nocallout.cdb} {yes} \
                                    {no} }} }


Tony.
--
f.a.n.finch <dot@???> http://dotat.at/
MALIN HEBRIDES: NORTHEAST 4 OR 5 INCREASING 6. RAIN LATER. GOOD BECOMING
MODERATE.