[exim] Re: Extract email address from From header

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Andreas Metzler
Date:  
À: exim-users
Sujet: [exim] Re: Extract email address from From header
Marc Perkel <marc@???> wrote:
[...]
> The first one works. It tests the sender. The second one tests the From
> header and it soesn't seem to work.


> # - Master Block List Sender


> deny    message = REJECTED - Sender listed in master block list
>        condition = ${if exists{/etc/exim/acllists/blockfrom.txt}\


> {${lookup{$sender_address}wildlsearch{/etc/exim/acllists/blockfrom.txt}{yes}{no}}}\
>    {no}}


> # - Master Block List From


> deny    message = REJECTED - Sender listed in master block list
>        condition = ${if exists{/etc/exim/acllists/blockfrom.txt}\


> {${lookup{${local_part:$h_From:}@${domain:$h_From:}}wildlsearch{/etc/exim/acllists/blockfrom.txt}{yes}{no}}}\
>    {no}}


Looks like you are running these tests in RCPT acl, before the
 From:-header is transfered. You'll need to move the second test to
the DATA-acl. (And as previously said $address instead will make the
whole thing a lot more readable.)
             cu andreas


-- 
The 'Galactic Cleaning' policy undertaken by Emperor Zhark is a personal
vision of the emperor's, and its inclusion in this work does not constitute
tacit approval by the author or the publisher for any such projects,
howsoever undertaken.                                (c) Jasper Ffforde