X-Git-Url: https://git.exim.org/exim.git/blobdiff_plain/c566dd90401a8b20b873644e3cdab175f1e86ede..ccee17956fb0d611dd5f45adb6ba31afc4eafd01:/doc/doc-docbook/spec.xfpt diff --git a/doc/doc-docbook/spec.xfpt b/doc/doc-docbook/spec.xfpt index 51c9b8bab..0641ad124 100644 --- a/doc/doc-docbook/spec.xfpt +++ b/doc/doc-docbook/spec.xfpt @@ -46,7 +46,7 @@ . ///////////////////////////////////////////////////////////////////////////// .set previousversion "4.75" -.set version "4.76" +.set version "4.77" .set ACL "access control lists (ACLs)" .set I "    " @@ -174,8 +174,8 @@ EximMaintainers EM - 4.76 - 06 May 2011 + 4.77 + 10 Oct 2011 EM 2011University of Cambridge @@ -7779,7 +7779,7 @@ pattern must be an appropriate query for the lookup type, as described in chapter &<>&. For example: .code hold_domains = mysql;select domain from holdlist \ - where domain = '$domain'; + where domain = '${quote_mysql:$domain}'; .endd In most cases, the data that is looked up is not used (so for an SQL query, for example, it doesn't matter what field you select). Exim is interested only in @@ -10079,6 +10079,25 @@ string is lexically greater than the second string. For &%gt%& the comparison includes the case of letters, whereas for &%gti%& the comparison is case-independent. +.new +.vitem &*inlist&~{*&<&'string1'&>&*}{*&<&'string2'&>&*}*& &&& + &*inlisti&~{*&<&'string1'&>&*}{*&<&'string2'&>&*}*& +.cindex "string" "comparison" +.cindex "list" "iterative conditions" +Both strings are expanded; the second string is treated as a list of simple +strings; if the first string is a member of the second, then the condition +is true. + +These are simpler to use versions of the more powerful &*forany*& condition. +Examples, and the &*forany*& equivalents: +.code +${if inlist{needle}{foo:needle:bar}} + ${if forany{foo:needle:bar}{eq{$item}{needle}}} +${if inlisti{Needle}{fOo:NeeDLE:bAr}} + ${if forany{fOo:NeeDLE:bAr}{eqi{$item}{Needle}}} +.endd +.wen + .vitem &*isip&~{*&<&'string'&>&*}*& &&& &*isip4&~{*&<&'string'&>&*}*& &&& &*isip6&~{*&<&'string'&>&*}*& @@ -10189,10 +10208,12 @@ See &*match_local_part*&. .vitem &*match_ip&~{*&<&'string1'&>&*}{*&<&'string2'&>&*}*& .cindex "&%match_ip%& expansion condition" +.new This condition matches an IP address to a list of IP address patterns. It must be followed by two argument strings. The first (after expansion) must be an IP -address or an empty string. The second (after expansion) is a restricted host +address or an empty string. The second (not expanded) is a restricted host list that can match only an IP address, not a host name. For example: +.wen .code ${if match_ip{$sender_host_address}{1.2.3.4:5.6.7.8}{...}{...}} .endd @@ -10238,6 +10259,11 @@ just as easy to use the fact that a lookup is itself a condition, and write: .endd .endlist ilist +.new +Note that <&'string2'&> is not itself subject to string expansion, unless +Exim was built with the EXPAND_LISTMATCH_RHS option. +.wen + Consult section &<>& for further details of these patterns. .vitem &*match_local_part&~{*&<&'string1'&>&*}{*&<&'string2'&>&*}*& @@ -10265,6 +10291,11 @@ item can be used, as in all address lists, to cause subsequent items to have their local parts matched casefully. Domains are always matched caselessly. +.new +Note that <&'string2'&> is not itself subject to string expansion, unless +Exim was built with the EXPAND_LISTMATCH_RHS option. +.wen + &*Note*&: Host lists are &'not'& supported in this way. This is because hosts have two identities: a name and an IP address, and it is not clear how to specify cleanly how such a test would work. However, IP addresses can be @@ -10632,7 +10663,7 @@ number of lines in the message's body. See also &$message_linecount$&. .cindex "binary zero" "in message body" .vindex "&$body_zerocount$&" When a message is being received or delivered, this variable contains the -number of binary zero bytes in the message's body. +number of binary zero bytes (ASCII NULs) in the message's body. .vitem &$bounce_recipient$& .vindex "&$bounce_recipient$&"