Re: [exim] stupid ACL named list question using match

Pàgina inicial
Delete this message
Reply to this message
Autor: Chad Leigh
Data:  
A: exim-users
Assumpte: Re: [exim] stupid ACL named list question using match
Hi Philip

Thanks!

(continued below)

On Dec 22, 2006, at 2:52 AM, Philip Hazel wrote:

> On Fri, 22 Dec 2006, Chad Leigh -- Shire.Net LLC wrote:
>
>> check_helo:
>>    accept hosts = 166.70.252.0/24 : webmail.shire.net :  
>> lists.shire.net
>>    deny message  = Go away, impostor!
>>          condition = ${if match{${lc:$sender_helo_name}}{shire.net}
>> {true}{false}}
>>    accept hosts = *

>>
>>
>> I got this from some samples that I munged together.
>
> You have overlooked the fact that that will also match shirelnet,
> shireOnet, etc., and also not necessarily at the start or end of the
> name. So something like wiltshiresnet.com would match.


yes, I should probably read up on regular expressions. The incidents
of someone trying to use one of these other domains that would
happen to match is probably pretty low so while I should go read up
on regex, I will add it to my todo and get around to it... :-(

>
>> If I do
>>
>>     domainlist    local domains = shire.net : objectwerks.com

>>
>> for example
>> and do
>>
>>    deny message  = Go away, impostor!
>>          condition = ${if match{${lc:$sender_helo_name}}
>> {+local_domains}{true}{false}}

>>
>> I get an error
>
> Well yes, because +local_domains is not a valid regular expression.
> You need match_domain, not match, to match a list of domains.
> There's an
> example in the manual.


ok, I found it. My question, then, is if the match_domain is still a
regular expression match? It does not sound like it. What I really
want is to match *.domain.tld for each one in my local_domains, so if
someone tries any host.my.domain , for example, mail.shire.net then
having shire.net in local_domains is sufficient...

Chad

>
> -- 
> Philip Hazel            University of Cambridge Computing Service
> Get the Exim 4 book:    http://www.uit.co.uk/exim-book


---
Chad Leigh -- Shire.Net LLC
Your Web App and Email hosting provider
chad at shire.net