Re: [exim] Outlook and Exim filter

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Odhiambo Washington
Datum:  
To: Hung Pham
CC: exim users
Betreff: Re: [exim] Outlook and Exim filter
On Sun, Sep 26, 2021 at 1:09 PM Hung Pham via Exim-users <
exim-users@???> wrote:

> Hi.
>
> I have a filter likes this in /etc/system_filter.exim file
>
> if
>   $h_to: is "all@???"
> then
>     if $sender_address: does not match "(user1|user2|user3)@mydomain.com"
>         then
>                 fail text "You are not in the allowed list"
>                 seen finish
>         endif
> endif

>
> It works well with emails sending from webmail, or other email
> clients. But with Outlook, all emails can pass the filter, and be
> processed as a normal message. It looks like Exim and Outlook don't
> match headers, or something like that?
>
> Any ideas?
>


Try ANDing the conditions and see the result:

if
  $h_to: is "all@???"
and
$sender_address: does not match "(user1|user2|user3)@mydomain.com"
        then
                fail text "You are not in the allowed list"
                seen finish
        endif


--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254 7 3200 0004/+254 7 2274 3223
"Oh, the cruft.", egrep -v '^$|^.*#' :-)