Re: [EXIM] Negation in domain/host/net/address lists

Top Page
Delete this message
Reply to this message
Author: Philip Hazel
Date:  
To: exim-users
Subject: Re: [EXIM] Negation in domain/host/net/address lists
I have received only two responses so far to the message I sent
yesterday on this topic, but as both were supportive, I am planning on
going ahead and working on the proposed changes. This will mean that the
next release will be some time off, and will not be backwards compatible
as far as the configuration options go. I will take the opportunity to
remove as much obsolete stuff as possible. I will produce documentation
telling you how to change your configuration files. If you want to put
in objections, please do so soon.

One of the responses suggested that, in addition to what I proposed,
there should be an amalgamation of the "hosts" options and the "nets"
options into a single option, so there would be, for example, just
"sender_accept_hosts" and no "sender_accept_nets". The items in such an
amalgamated option have to be defined so that they can be recognized as
either relating to the host name, or the IP address. I have thought
about this, and think it can be done. The following rules for handling
such items are proposed. Can anybody see anything I've overlooked?

. If the item is precisely "@", match against the primary host name.

. If the item has the form of an IP address (e.g. 10.9.9.7), treat it as such,
and match against the host's IP address.

. If the item has the form of an IP address followed by / and a number
(e.g. 10.9.8.0/24), treat it as a masked IP address (i.e. like current
"net" items).

. If the item has the form of a domain name (dot-separated components,
each containing only letters, digits, and hyphen), match against the
host name.

. If the item starts with / treat it as a file name; read each line in
the file and treat it independently as one of these items. This is
like file names in current net lists - making it general here adds a
sort of "include" facility for host lists.

. If the item starts with * (e.g. *.a.b.c) match the end of the host
name against whatever follows the *.

. If the item starts with ^ (e.g. ^(a|b)\.c\.d) it is a regular
expression to be matched against the host name.

. If the item starts with net-^ (e.g. net-^(10|11)\.) it is a regular
expression to be matched against the textual form of the IP address.

. It the item starts with a lookup name terminated by a semicolon (e.g.
dbm;/some/file), it specifies a lookup that is to be done for the host
name.

. If the item starts with net- followed by a hyphen-separated list of
numbers, followed by a lookup name terminated by a semicolon (e.g.
net-16-24-dbm;/some/file) then a series of lookups are done using keys
created by masking the IP address with each mask in turn, and then
looking up the result as a text item. For example, for the above item,
if the incoming address were 131.111.8.9 then the keys that would be
looked up up would be "131.111.0.0" and "131.111.8.0". This provides a
long-requested facility for more efficient network lookups.



-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.




--
*** Exim information can be found at http://www.exim.org/ ***