On Tue, 9 Dec 2003, Nico Erfurth wrote:
> John Jetmore wrote:
> > I looked in the docs and either it's not there or I overlooked it multiple
> > times. How do I test whether an element is in a named list in a free
> > manner. By this I mean I want to check in a condition= statement, not in
> > domains= or hosts= or the like. As a specific example I would like to
> > check whether $sender_helo_name is an element in @[] or +local_domains.
>
> You can't, IIRC there is an item on the wishlist about this.
Indeed there is:
------------------------------------------------------------------------------
(73) 17-Jul-02 M Match a list from within a condition
e.g. ${if matchdomain {$domain}{+domainlist} ...
${if matchhost {$sender_host_address}{1.2.3.4/10:2.3.4.5/16}...
Thought needed about how to handle host names. This may be too messy to specify
cleanly.
------------------------------------------------------------------------------
When I last looked at this, it was before the modification to $sender_host_
name that causes an automatic rDNS lookup if necessary whenever the
variable is referenced. It may therefore be easier now to specify this,
but there are still problems, especially when query-style lookups are
involved.
--
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