Re: [exim] Reject connects from hostnames containing special…

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Philip Hazel
Date:  
À: Nigel Metheringham
CC: exim-users
Sujet: Re: [exim] Reject connects from hostnames containing special words
On Thu, 16 Sep 2004, Nigel Metheringham wrote:

> > deny host = \N^\adsl$\N
>
> Thats using a hostlist and putting a regexp in it, which is an odd mix.


But it's permitted (see 10.13). However, you have written a regex that
matches the host name "adsl", which is not what you want. Try

deny hosts = \N(^|\.)adsl\.\N

which matches the string "adsl" either at the start of the string or
preceded by a dot, and followed by a dot.

> $sender_host_name using a regexp match:-
> deny condition = ${if match {$sender_host_name}{adsl} {1}{0}}
>
> The regexp has been simplified to a minimum.


Too much! It matches hosts called xxx.thingyadslpqr.com for instance...


-- 
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