X-Git-Url: https://git.exim.org/users/heiko/exim.git/blobdiff_plain/6e62c454f618d77c69bea88c01e71765a1320dce..f3d8f75105d83b511cf0cf43d3f8b23323d1106b:/doc/doc-docbook/spec.xfpt?ds=inline diff --git a/doc/doc-docbook/spec.xfpt b/doc/doc-docbook/spec.xfpt index 1ba0a10dd..7c34bbbc7 100644 --- a/doc/doc-docbook/spec.xfpt +++ b/doc/doc-docbook/spec.xfpt @@ -52,7 +52,7 @@ .set I "    " .macro copyyear -2013 +2014 .endmacro . ///////////////////////////////////////////////////////////////////////////// @@ -4221,6 +4221,20 @@ option sets the IP interface address value. A port number may be included, using the same syntax as for &%-oMa%&. The interface address is placed in &$received_ip_address$& and the port number, if present, in &$received_port$&. +.vitem &%-oMm%&&~<&'message&~reference'&> +.oindex "&%-oMm%&" +.cindex "message reference" "message reference, specifying for local message" +See &%-oMa%& above for general remarks about the &%-oM%& options. The &%-oMm%& +option sets the message reference, e.g. message-id, and is logged during +delivery. This is useful when some kind of audit trail is required to tie +messages together. The format of the message reference is checked and will +abort if the format is invalid. The option will only be accepted if exim is +running in trusted mode, not as any regular user. + +The best example of a message reference is when Exim sends a bounce message. +The message reference is the message-id of the original message for which Exim +is sending the bounce. + .vitem &%-oMr%&&~<&'protocol&~name'&> .oindex "&%-oMr%&" .cindex "protocol, specifying for local message" @@ -6840,7 +6854,7 @@ is used on its own as the result. If the lookup does not succeed, the &`fail`& keyword causes a &'forced expansion failure'& &-- see section &<>& for an explanation of what this means. -The supported DNS record types are A, CNAME, MX, NS, PTR, SPF, SRV, and TXT, +The supported DNS record types are A, CNAME, MX, NS, PTR, SPF, SRV, TLSA and TXT, and, when Exim is compiled with IPv6 support, AAAA (and A6 if that is also configured). If no type is given, TXT is assumed. When the type is PTR, the data can be an IP address, written as normal; inversion and the addition of @@ -6959,11 +6973,16 @@ The data from each lookup is concatenated, with newline separators by default, in the same way that multiple DNS records for a single item are handled. A different separator can be specified, as described above. +Modifiers for &(dnsdb)& lookups are givien by optional keywords, +each followed by a comma, +that may appear before the record type. + The &(dnsdb)& lookup fails only if all the DNS lookups fail. If there is a temporary DNS error for any of them, the behaviour is controlled by -an optional keyword followed by a comma that may appear before the record -type. The possible keywords are &"defer_strict"&, &"defer_never"&, and -&"defer_lax"&. With &"strict"& behaviour, any temporary DNS error causes the +a defer-option modifier. +The possible keywords are +&"defer_strict"&, &"defer_never"&, and &"defer_lax"&. +With &"strict"& behaviour, any temporary DNS error causes the whole lookup to defer. With &"never"& behaviour, a temporary DNS error is ignored, and the behaviour is as if the DNS lookup failed to find anything. With &"lax"& behaviour, all the queries are attempted, but a temporary DNS @@ -6976,6 +6995,21 @@ ${lookup dnsdb{a=one.host.com:two.host.com}} Thus, in the default case, as long as at least one of the DNS lookups yields some data, the lookup succeeds. +.new +.cindex "DNSSEC" "dns lookup" +Use of &(DNSSEC)& is controlled by a dnssec modifier. +The possible keywords are +&"dnssec_strict"&, &"dnssec_lax"&, and &"dnssec_never"&. +With &"strict"& or &"lax"& DNSSEC information is requested +with the lookup. +With &"strict"& a response from the DNS resolver that +is not labelled as authenticated data +is treated as equivalent to a temporary DNS error. +The default is &"never"&. + +See also the &$lookup_dnssec_authenticated$& variable. +.wen + @@ -7198,6 +7232,9 @@ them. The following names are recognized: &`USER `& set the DN, for authenticating the LDAP bind &`PASS `& set the password, likewise &`REFERRALS `& set the referrals parameter +.new +&`SERVERS `& set alternate server list for this query only +.wen &`SIZE `& set the limit for the number of entries returned &`TIME `& set the maximum waiting time for a query .endd @@ -7219,6 +7256,15 @@ Netscape SDK; for OpenLDAP no action is taken. The TIME parameter (also a number of seconds) is passed to the server to set a server-side limit on the time taken to complete a search. +.new +The SERVERS parameter allows you to specify an alternate list of ldap servers +to use for an individual lookup. The global ldap_servers option provides a +default list of ldap servers, and a single lookup can specify a single ldap +server to use. But when you need to do a lookup with a list of servers that is +different than the default list (maybe different order, maybe a completely +different set of servers), the SERVERS parameter allows you to specify this +alternate list. +.wen Here is an example of an LDAP query in an Exim lookup that uses some of these values. This is a single line, folded to fit on the page: @@ -8298,7 +8344,14 @@ Both &`+include_unknown`& and &`+ignore_unknown`& may appear in the same list. The effect of each one lasts until the next, or until the end of the list. -To explain the host/ip processing logic a different way for the same ACL: +.new +.section "Mixing wildcarded host names and addresses in host lists" &&& + "SECTmixwilhos" +.cindex "host list" "mixing names and addresses in" + +This section explains the host/ip processing logic with the same concepts +as the previous section, but specifically addresses what happens when a +wildcarded hostname is one of the items in the hostlist. .ilist If you have name lookups or wildcarded host names and @@ -8327,7 +8380,7 @@ If the first &%accept%& fails, Exim goes on to try the second one. See chapter &`+ignore_unknown`&, which was discussed in depth in the first example in this section. .endlist - +.wen .section "Temporary DNS errors when looking up host information" &&& @@ -8399,33 +8452,6 @@ See section &<>&.) -.section "Mixing wildcarded host names and addresses in host lists" &&& - "SECTmixwilhos" -.cindex "host list" "mixing names and addresses in" -If you have name lookups or wildcarded host names and IP addresses in the same -host list, you should normally put the IP addresses first. For example, in an -ACL you could have: -.code -accept hosts = 10.9.8.7 : *.friend.example -.endd -The reason for this lies in the left-to-right way that Exim processes lists. -It can test IP addresses without doing any DNS lookups, but when it reaches an -item that requires a host name, it fails if it cannot find a host name to -compare with the pattern. If the above list is given in the opposite order, the -&%accept%& statement fails for a host whose name cannot be found, even if its -IP address is 10.9.8.7. - -If you really do want to do the name check first, and still recognize the IP -address, you can rewrite the ACL like this: -.code -accept hosts = *.friend.example -accept hosts = 10.9.8.7 -.endd -If the first &%accept%& fails, Exim goes on to try the second one. See chapter -&<>& for details of ACLs. - - - .section "Address lists" "SECTaddresslist" @@ -8849,6 +8875,55 @@ the expansion result is an empty string. If the ACL returns defer the result is a forced-fail. Otherwise the expansion fails. +.new +.vitem "&*${certextract{*&<&'field'&>&*}{*&<&'certificate'&>&*}&&& + {*&<&'string2'&>&*}{*&<&'string3'&>&*}}*&" +.cindex "expansion" "extracting cerificate fields" +.cindex "&%certextract%&" "certificate fields" +.cindex "certificate" "extracting fields" +The <&'certificate'&> must be a variable of type certificate. +The field name is expanded and used to retrive the relevant field from +the certificate. Supported fields are: +.display +&`version `& +&`serial_number `& +&`subject `& +&`issuer `& +&`notbefore `& +&`notafter `& +&`sig_algorithm `& +&`signature `& +&`subj_altname `& tagged list +&`ocsp_uri `& list +&`crl_uri `& list +.endd +If the field is found, +<&'string2'&> is expanded, and replaces the whole item; +otherwise <&'string3'&> is used. During the expansion of <&'string2'&> the +variable &$value$& contains the value that has been extracted. Afterwards, it +is restored to any previous value it might have had. + +If {<&'string3'&>} is omitted, the item is replaced by an empty string if the +key is not found. If {<&'string2'&>} is also omitted, the value that was +extracted is used. + +Some field names take optional modifiers, appended and separated by commas. + +The field selectors marked as "list" above return a list, +newline-separated by default, +(embedded separator characters in elements are doubled). +The separator may be changed by a modifier of +a right angle-bracket followed immediately by the new separator. + +The field selectors marked as "tagged" above +prefix each list element with a type string and an equals sign. +Elements of only one type may be selected by a modifier +which is one of "dns", "uri" or "mail"; +if so the elenment tags are omitted. + +Field values are generally presented in human-readable form. +.wen + .vitem "&*${dlfunc{*&<&'file'&>&*}{*&<&'function'&>&*}{*&<&'arg'&>&*}&&& {*&<&'arg'&>&*}...}*&" .cindex &%dlfunc%& @@ -9961,6 +10036,7 @@ Letters in IPv6 addresses are always output in lower case. .vitem &*${md5:*&<&'string'&>&*}*& .cindex "MD5 hash" .cindex "expansion" "MD5 hash" +.cindex "certificate fingerprint" .cindex "&%md5%& expansion item" The &%md5%& operator computes the MD5 hash value of the string, and returns it as a 32-digit hexadecimal number, in which any letters are in lower case. @@ -10098,11 +10174,24 @@ variables or headers inside regular expressions. .vitem &*${sha1:*&<&'string'&>&*}*& .cindex "SHA-1 hash" .cindex "expansion" "SHA-1 hashing" +.cindex "certificate fingerprint" .cindex "&%sha2%& expansion item" The &%sha1%& operator computes the SHA-1 hash value of the string, and returns it as a 40-digit hexadecimal number, in which any letters are in upper case. +.vitem &*${sha256:*&<&'certificate'&>&*}*& +.cindex "SHA-256 hash" +.cindex "certificate fingerprint" +.cindex "expansion" "SHA-256 hashing" +.cindex "&%sha256%& expansion item" +The &%sha256%& operator computes the SHA-256 hash fingerprint of the +certificate, +and returns +it as a 64-digit hexadecimal number, in which any letters are in upper case. +Only arguments which are a single variable of certificate type are supported. + + .vitem &*${stat:*&<&'string'&>&*}*& .cindex "expansion" "statting a file" .cindex "file" "extracting characteristics" @@ -10171,6 +10260,14 @@ number of larger units and output in Exim's normal time format, for example, .cindex "expansion" "case forcing" .cindex "&%uc%& expansion item" This forces the letters in the string into upper-case. + +.vitem &*${utf8clean:*&<&'string'&>&*}*& +.cindex "correction of invalid utf-8 sequences in strings" +.cindex "utf-8" "utf-8 sequences" +.cindex "incorrect utf-8" +.cindex "expansion" "utf-8 forcing" +.cindex "&%utf8clean%& expansion item" +This replaces any invalid utf-8 sequence in the string by the character &`?`&. .endlist @@ -10239,7 +10336,7 @@ If the ACL returns defer the result is a forced-fail. .cindex "&%bool%& expansion condition" This condition turns a string holding a true or false representation into a boolean state. It parses &"true"&, &"false"&, &"yes"& and &"no"& -(case-insensitively); also positive integer numbers map to true if non-zero, +(case-insensitively); also integer numbers map to true if non-zero, false if zero. An empty string is treated as false. Leading and trailing whitespace is ignored; @@ -11433,6 +11530,16 @@ ability to find the amount of free space (only true for experimental systems), the space value is -1. See also the &%check_log_space%& option. +.new +.vitem &$lookup_dnssec_authenticated$& +.vindex "&$lookup_dnssec_authenticated$&" +This variable is set after a DNS lookup done by +a dnsdb lookup expansion, dnslookup router or smtp transport. +It will be empty if &(DNSSEC)& was not requested, +&"no"& if the result was not labelled as authenticated data +and &"yes"& if it was. +.wen + .vitem &$mailstore_basename$& .vindex "&$mailstore_basename$&" This variable is set only when doing deliveries in &"mailstore"& format in the @@ -11978,7 +12085,7 @@ other times, this variable is false. It is likely that you will need to coerce DNSSEC support on in the resolver library, by setting: .code -dns_use_dnssec = 1 +dns_dnssec_ok = 1 .endd Exim does not perform DNSSEC validation itself, instead leaving that to a @@ -12209,6 +12316,44 @@ on an outbound SMTP connection; the meaning of this depends upon the TLS implementation used. If TLS has not been negotiated, the value will be 0. +.new +.vitem &$tls_in_ourcert$& +.vindex "&$tls_in_ourcert$&" +This variable refers to the certificate presented to the peer of an +inbound connection when the message was received. +It is only useful as the argument of a +&%certextract%& expansion item, &%md5%& or &%sha1%& operator, +or a &%def%& condition. +.wen + +.new +.vitem &$tls_in_peercert$& +.vindex "&$tls_in_peercert$&" +This variable refers to the certificate presented by the peer of an +inbound connection when the message was received. +It is only useful as the argument of a +&%certextract%& expansion item, &%md5%& or &%sha1%& operator, +or a &%def%& condition. +.wen + +.new +.vitem &$tls_out_ourcert$& +.vindex "&$tls_out_ourcert$&" +This variable refers to the certificate presented to the peer of an +outbound connection. It is only useful as the argument of a +&%certextract%& expansion item, &%md5%& or &%sha1%& operator, +or a &%def%& condition. +.wen + +.new +.vitem &$tls_out_peercert$& +.vindex "&$tls_out_peercert$&" +This variable refers to the certificate presented by the peer of an +outbound connection. It is only useful as the argument of a +&%certextract%& expansion item, &%md5%& or &%sha1%& operator, +or a &%def%& condition. +.wen + .vitem &$tls_in_certificate_verified$& .vindex "&$tls_in_certificate_verified$&" This variable is set to &"1"& if a TLS certificate was verified when the @@ -12990,6 +13135,7 @@ listed in more than one group. .row &%acl_smtp_auth%& "ACL for AUTH" .row &%acl_smtp_connect%& "ACL for connection" .row &%acl_smtp_data%& "ACL for DATA" +.row &%acl_smtp_data_prdr%& "ACL for DATA, per-recipient" .row &%acl_smtp_dkim%& "ACL for DKIM verification" .row &%acl_smtp_etrn%& "ACL for ETRN" .row &%acl_smtp_expn%& "ACL for EXPN" @@ -13145,6 +13291,7 @@ See also the &'Policy controls'& section above. .row &%ignore_fromline_hosts%& "allow &""From ""& from these hosts" .row &%ignore_fromline_local%& "allow &""From ""& from local SMTP" .row &%pipelining_advertise_hosts%& "advertise pipelining to these hosts" +.row &%prdr_enable%& "advertise PRDR to all hosts" .row &%tls_advertise_hosts%& "advertise TLS to these hosts" .endtable @@ -13190,10 +13337,10 @@ See also the &'Policy controls'& section above. .row &%disable_ipv6%& "do no IPv6 processing" .row &%dns_again_means_nonexist%& "for broken domains" .row &%dns_check_names_pattern%& "pre-DNS syntax check" +.row &%dns_dnssec_ok%& "parameter for resolver" .row &%dns_ipv4_lookup%& "only v4 lookup for these domains" .row &%dns_retrans%& "parameter for resolver" .row &%dns_retry%& "parameter for resolver" -.row &%dns_use_dnssec%& "parameter for resolver" .row &%dns_use_edns0%& "parameter for resolver" .row &%hold_domains%& "hold delivery for these domains" .row &%local_interfaces%& "for routing checks" @@ -13296,6 +13443,16 @@ This option defines the ACL that is run after an SMTP DATA command has been processed and the message itself has been received, but before the final acknowledgment is sent. See chapter &<>& for further details. +.option acl_smtp_data_prdr main string&!! unset +.cindex "DATA" "ACL for" +.cindex "&ACL;" "PRDR-related" +.cindex "&ACL;" "per-user data processing" +This option defines the ACL that, +if the PRDR feature has been negotiated, +is run for each recipient after an SMTP DATA command has been +processed and the message itself has been received, but before the +acknowledgment is sent. See chapter &<>& for further details. + .option acl_smtp_etrn main string&!! unset .cindex "ETRN" "ACL for" This option defines the ACL that is run when an SMTP ETRN command is @@ -13814,6 +13971,17 @@ This option controls whether or not an IP address, given as a CSA domain, is reversed and looked up in the reverse DNS, as described in more detail in section &<>&. + +.option dns_dnssec_ok main integer -1 +.cindex "DNS" "resolver options" +.cindex "DNS" "DNSSEC" +If this option is set to a non-negative number then Exim will initialise the +DNS resolver library to either use or not use DNSSEC, overriding the system +default. A value of 0 coerces DNSSEC off, a value of 1 coerces DNSSEC on. + +If the resolver library does not support DNSSEC then this option has no effect. + + .option dns_ipv4_lookup main "domain list&!!" unset .cindex "IPv6" "DNS lookup for AAAA records" .cindex "DNS" "IPv6 lookup for AAAA records" @@ -13844,16 +14012,6 @@ to set in them. See &%dns_retrans%& above. -.option dns_use_dnssec main integer -1 -.cindex "DNS" "resolver options" -.cindex "DNS" "DNSSEC" -If this option is set to a non-negative number then Exim will initialise the -DNS resolver library to either use or not use DNSSEC, overriding the system -default. A value of 0 coerces DNSSEC off, a value of 1 coerces DNSSEC on. - -If the resolver library does not support DNSSEC then this option has no effect. - - .option dns_use_edns0 main integer -1 .cindex "DNS" "resolver options" .cindex "DNS" "EDNS0" @@ -14937,6 +15095,15 @@ that clients will use it; &"out of order"& commands that are &"expected"& do not count as protocol errors (see &%smtp_max_synprot_errors%&). +.option prdr_enable main boolean false +.cindex "PRDR" "enabling on server" +This option can be used to enable the Per-Recipient Data Response extension +to SMTP, defined by Eric Hall. +If the option is set, PRDR is advertised by Exim when operating as a server. +If the client requests PRDR, and more than one recipient, for a message +an additional ACL is called for each recipient after the message content +is recieved. See section &<>&. + .option preserve_message_logs main boolean false .cindex "message logs" "preserving" If this option is set, message log files are not deleted when messages are @@ -16738,11 +16905,12 @@ and the discussion in chapter &<>&. -.option headers_add routers string&!! unset +.option headers_add routers list&!! unset .cindex "header lines" "adding" .cindex "router" "adding header lines" -This option specifies a string of text that is expanded at routing time, and -associated with any addresses that are accepted by the router. However, this +This option specifies a list of text headers, newline-separated, +that is associated with any addresses that are accepted by the router. +Each item is separately expanded, at routing time. However, this option has no effect when an address is just being verified. The way in which the text is used to add header lines at transport time is described in section &<>&. New header lines are not actually added until the @@ -16751,8 +16919,8 @@ header lines in string expansions in the transport's configuration do not &"see"& the added header lines. The &%headers_add%& option is expanded after &%errors_to%&, but before -&%headers_remove%& and &%transport%&. If the expanded string is empty, or if -the expansion is forced to fail, the option has no effect. Other expansion +&%headers_remove%& and &%transport%&. If an item is empty, or if +an item expansion is forced to fail, the item has no effect. Other expansion failures are treated as configuration errors. Unlike most options, &%headers_add%& can be specified multiple times @@ -16774,11 +16942,12 @@ avoided. The &%repeat_use%& option of the &%redirect%& router may be of help. -.option headers_remove routers string&!! unset +.option headers_remove routers list&!! unset .cindex "header lines" "removing" .cindex "router" "removing header lines" -This option specifies a string of text that is expanded at routing time, and -associated with any addresses that are accepted by the router. However, this +This option specifies a list of text headers, colon-separated, +that is associated with any addresses that are accepted by the router. +Each item is separately expanded, at routing time. However, this option has no effect when an address is just being verified. The way in which the text is used to remove header lines at transport time is described in section &<>&. Header lines are not actually removed until @@ -16787,8 +16956,8 @@ to header lines in string expansions in the transport's configuration still &"see"& the original header lines. The &%headers_remove%& option is expanded after &%errors_to%& and -&%headers_add%&, but before &%transport%&. If the expansion is forced to fail, -the option has no effect. Other expansion failures are treated as configuration +&%headers_add%&, but before &%transport%&. If an item expansion is forced to fail, +the item has no effect. Other expansion failures are treated as configuration errors. Unlike most options, &%headers_remove%& can be specified multiple times @@ -17631,6 +17800,33 @@ when there is a DNS lookup error. +.new +.option dnssec_request_domains dnslookup "domain list&!!" unset +.cindex "MX record" "security" +.cindex "DNSSEC" "MX lookup" +.cindex "security" "MX lookup" +.cindex "DNS" "DNSSEC" +DNS lookups for domains matching &%dnssec_request_domains%& will be done with +the dnssec request bit set. +This applies to all of the SRV, MX A6, AAAA, A lookup sequence. +.wen + + + +.new +.option dnssec_require_domains dnslookup "domain list&!!" unset +.cindex "MX record" "security" +.cindex "DNSSEC" "MX lookup" +.cindex "security" "MX lookup" +.cindex "DNS" "DNSSEC" +DNS lookups for domains matching &%dnssec_request_domains%& will be done with +the dnssec request bit set. Any returns not having the Authenticated Data bit +(AD bit) set wil be ignored and logged as a host-lookup failure. +This applies to all of the SRV, MX A6, AAAA, A lookup sequence. +.wen + + + .option mx_domains dnslookup "domain list&!!" unset .cindex "MX record" "required to exist" .cindex "SRV record" "required to exist" @@ -19788,10 +19984,11 @@ value that the router supplies, and also overriding any value associated with &%user%& (see below). -.option headers_add transports string&!! unset +.option headers_add transports list&!! unset .cindex "header lines" "adding in transport" .cindex "transport" "header lines; adding" -This option specifies a string of text that is expanded and added to the header +This option specifies a list of text headers, newline-separated, +which are (separately) expanded and added to the header portion of a message as it is transported, as described in section &<>&. Additional header lines can also be specified by routers. If the result of the expansion is an empty string, or if the expansion @@ -19812,18 +20009,20 @@ transports, the settings of &%message_prefix%& and &%message_suffix%& should be checked, since this option does not automatically suppress them. -.option headers_remove transports string&!! unset +.option headers_remove transports list&!! unset .cindex "header lines" "removing" .cindex "transport" "header lines; removing" -This option specifies a string that is expanded into a list of header names; +This option specifies a list of header names, colon-separated; these headers are omitted from the message as it is transported, as described in section &<>&. Header removal can also be specified by -routers. If the result of the expansion is an empty string, or if the expansion +routers. +Each list item is separately expanded. +If the result of the expansion is an empty string, or if the expansion is forced to fail, no action is taken. Other expansion failures are treated as errors and cause the delivery to be deferred. Unlike most options, &%headers_remove%& can be specified multiple times -for a router; all listed headers are added. +for a router; all listed headers are removed. @@ -22531,6 +22730,33 @@ See the &%search_parents%& option in chapter &<>& for more details. +.new +.option dnssec_request_domains smtp "domain list&!!" unset +.cindex "MX record" "security" +.cindex "DNSSEC" "MX lookup" +.cindex "security" "MX lookup" +.cindex "DNS" "DNSSEC" +DNS lookups for domains matching &%dnssec_request_domains%& will be done with +the dnssec request bit set. +This applies to all of the SRV, MX A6, AAAA, A lookup sequence. +.wen + + + +.new +.option dnssec_require_domains smtp "domain list&!!" unset +.cindex "MX record" "security" +.cindex "DNSSEC" "MX lookup" +.cindex "security" "MX lookup" +.cindex "DNS" "DNSSEC" +DNS lookups for domains matching &%dnssec_request_domains%& will be done with +the dnssec request bit set. Any returns not having the Authenticated Data bit +(AD bit) set wil be ignored and logged as a host-lookup failure. +This applies to all of the SRV, MX A6, AAAA, A lookup sequence. +.wen + + + .option dscp smtp string&!! unset .cindex "DCSP" "outbound" This option causes the DSCP value associated with a socket to be set to one @@ -22768,6 +22994,12 @@ connects. If authentication fails, Exim will try to transfer the message unauthenticated. See also &%hosts_require_auth%&, and chapter &<>& for details of authentication. +.option hosts_try_prdr smtp "host list&!!" unset +.cindex "PRDR" "enabling, optional in client" +This option provides a list of servers to which, provided they announce +PRDR support, Exim will attempt to negotiate PRDR +for multi-recipient messages. + .option interface smtp "string list&!!" unset .cindex "bind IP address" .cindex "IP address" "binding" @@ -23018,6 +23250,14 @@ unknown state), opens a new one to the same host, and then tries the delivery in clear. +.option tls_try_verify_hosts smtp "host list&!! unset +.cindex "TLS" "server certificate verification" +.cindex "certificate" "verification of server" +This option gives a list of hosts for which, on encrypted connections, +certificate verification will be tried but need not succeed. +The &%tls_verify_certificates%& option must also be set. + + .option tls_verify_certificates smtp string&!! unset .cindex "TLS" "server certificate verification" .cindex "certificate" "verification of server" @@ -23032,6 +23272,20 @@ single file if you are using GnuTLS. The values of &$host$& and &$host_address$& are set to the name and address of the server during the expansion of this option. See chapter &<>& for details of TLS. +For back-compatability, +if neither tls_verify_hosts nor tls_try_verify_hosts are set +and certificate verification fails the TLS connection is closed. + + +.option tls_verify_hosts smtp "host list&!! unset +.cindex "TLS" "server certificate verification" +.cindex "certificate" "verification of server" +This option gives a list of hosts for which. on encrypted connections, +certificate verification must succeed. +The &%tls_verify_certificates%& option must also be set. +If both this option and &%tls_try_verify_hosts%& are unset +operation is as if this option selected all hosts. + @@ -25933,6 +26187,12 @@ for OpenSSL only (not GnuTLS), a directory, that contains a collection of expected server certificates. The client verifies the server's certificate against this collection, taking into account any revoked certificates that are in the list defined by &%tls_crl%&. +Failure to verify fails the TLS connection unless either of the +&%tls_verify_hosts%& or &%tls_try_verify_hosts%& options are set. + +The &%tls_verify_hosts%& and &%tls_try_verify_hosts%& options restrict +certificate verification to the listed servers. Verification either must +or need not succeed respectively. If &%tls_require_ciphers%& is set on the &(smtp)& transport, it must contain a @@ -26227,6 +26487,7 @@ options in the main part of the configuration. These options are: .cindex "SMTP" "connection, ACL for" .cindex "non-SMTP messages" "ACLs for" .cindex "MIME content scanning" "ACL for" +.cindex "PRDR" "ACL for" .table2 140pt .irow &%acl_not_smtp%& "ACL for non-SMTP messages" @@ -26235,6 +26496,7 @@ options in the main part of the configuration. These options are: .irow &%acl_smtp_auth%& "ACL for AUTH" .irow &%acl_smtp_connect%& "ACL for start of SMTP connection" .irow &%acl_smtp_data%& "ACL after DATA is complete" +.irow &%acl_smtp_data_prdr%& "ACL for each recipient, after DATA is complete" .irow &%acl_smtp_etrn%& "ACL for ETRN" .irow &%acl_smtp_expn%& "ACL for EXPN" .irow &%acl_smtp_helo%& "ACL for HELO or EHLO" @@ -26349,8 +26611,10 @@ before or after the data) correctly &-- they keep the message on their queues and try again later, but that is their problem, though it does waste some of your resources. -The &%acl_smtp_data%& ACL is run after both the &%acl_smtp_dkim%& and -the &%acl_smtp_mime%& ACLs. +The &%acl_smtp_data%& ACL is run after +the &%acl_smtp_data_prdr%&, +the &%acl_smtp_dkim%& +and the &%acl_smtp_mime%& ACLs. .section "The SMTP DKIM ACL" "SECTDKIMACL" The &%acl_smtp_dkim%& ACL is available only when Exim is compiled with DKIM support @@ -26372,6 +26636,34 @@ content-scanning extension. For details, see chapter &<>&. This ACL is evaluated after &%acl_smtp_dkim%& but before &%acl_smtp_data%&. +.section "The SMTP PRDR ACL" "SECTPRDRACL" +.oindex "&%prdr_enable%&" +The &%acl_smtp_data_prdr%& ACL is available only when Exim is compiled +with PRDR support enabled (which is the default). +It becomes active only when the PRDR feature is negotiated between +client and server for a message, and more than one recipient +has been accepted. + +The ACL test specfied by &%acl_smtp_data_prdr%& happens after a message +has been recieved, and is executed for each recipient of the message. +The test may accept or deny for inividual recipients. +The &%acl_smtp_data%& will still be called after this ACL and +can reject the message overall, even if this ACL has accepted it +for some or all recipients. + +PRDR may be used to support per-user content filtering. Without it +one must defer any recipient after the first that has a different +content-filter configuration. With PRDR, the RCPT-time check +for this can be disabled when the MAIL-time $smtp_command included +"PRDR". Any required difference in behaviour of the main DATA-time +ACL should however depend on the PRDR-time ACL having run, as Exim +will avoid doing so in some situations (eg. single-recipient mails). + +See also the &%prdr_enable%& global option +and the &%hosts_try_prdr%& smtp transport option. + +This ACL is evaluated after &%acl_smtp_dkim%& but before &%acl_smtp_data%&. + .section "The QUIT ACL" "SECTQUITACL" .cindex "QUIT, ACL for" The ACL for the SMTP QUIT command is anomalous, in that the outcome of the ACL @@ -27293,8 +27585,12 @@ from one SMTP connection to another. If a recipient-verify callout connection i requested in the same ACL it is held open and used for the data, otherwise one is made after the ACL completes. -Note that routers are used in verify mode. Note also that headers cannot be +Note that routers are used in verify mode, +and cannot depend on content of received headers. +Note also that headers cannot be modified by any of the post-data ACLs (DATA, MIME and DKIM). +Headers may be modified by routers (subject to the above) and transports. + Cutthrough delivery is not supported via transport-filters or when DKIM signing of outgoing messages is done, because it sends data to the ultimate destination before the entire message has been received from the source. @@ -27982,6 +28278,23 @@ This condition checks whether the sending host (the client) is authorized to send email. Details of how this works are given in section &<>&. +.new +.vitem &*verify&~=&~header_names_ascii*& +.cindex "&%verify%& ACL condition" +.cindex "&ACL;" "verifying header names only ASCII" +.cindex "header lines" "verifying header names only ASCII" +.cindex "verifying" "header names only ASCII" +This condition is relevant only in an ACL that is run after a message has been +received, that is, in an ACL specified by &%acl_smtp_data%& or +&%acl_not_smtp%&. It checks all header names (not the content) to make sure +there are no non-ASCII characters, also excluding control characters. The +allowable characters are decimal ASCII values 33 through 126. + +Exim itself will handle headers with non-ASCII characters, but it can cause +problems for downstream applications, so this option will allow their +detection and rejection in the DATA ACL's. +.wen + .vitem &*verify&~=&~header_sender/*&<&'options'&> .cindex "&%verify%& ACL condition" .cindex "&ACL;" "verifying sender in the header" @@ -28593,6 +28906,13 @@ deny condition = ${if isip4{$sender_host_address}} dnslists = some.list.example .endd +If an explicit key is being used for a DNS lookup and it may be an IPv6 +address you should specify alternate list separators for both the outer +(DNS list name) list and inner (lookup keys) list: +.code + dnslists = <; dnsbl.example.com/<|$acl_m_addrslist +.endd + .section "Rate limiting incoming messages" "SECTratelimiting" .cindex "rate limiting" "client sending" .cindex "limiting client sending rates" @@ -28974,6 +29294,7 @@ router that does not set up hosts routes to an &(smtp)& transport with a &%hosts%& setting, the transport's hosts are used. If an &(smtp)& transport has &%hosts_override%& set, its hosts are always used, whether or not the router supplies a host list. +Callouts are only supported on &(smtp)& transports. The port that is used is taken from the transport, if it is specified and is a remote transport. (For routers that do verification only, no transport need be @@ -29777,6 +30098,24 @@ av_scanner = mksd:2 .endd You can safely omit this option (the default value is 1). +.vitem &%sock%& +.cindex "virus scanners" "simple socket-connected" +This is a general-purpose way of talking to simple scanner daemons +running on the local machine. +There are four options: +an address (which may be an IP addres and port, or the path of a Unix socket), +a commandline to send (may include a single %s which will be replaced with +the path to the mail file to be scanned), +an RE to trigger on from the returned data, +an RE to extract malware_name from the returned data. +For example: +.code +av_scanner = sock:127.0.0.1 6001:%s:(SPAM|VIRUS):(.*)\$ +.endd +Default for the socket specifier is &_/tmp/malware.sock_&. +Default for the commandline is &_%s\n_&. +Both regular-expressions are required. + .vitem &%sophie%& .cindex "virus scanners" "Sophos and Sophie" Sophie is a daemon that uses Sophos' &%libsavi%& library to scan for viruses. @@ -31899,7 +32238,7 @@ they do not affect the values of the variables that refer to header lines. the transport cannot refer to the modified header lines, because such expansions all occur before the message is actually transported. -For both routers and transports, the result of expanding a &%headers_add%& +For both routers and transports, the argument of a &%headers_add%& option must be in the form of one or more RFC 2822 header lines, separated by newlines (coded as &"\n"&). For example: .code @@ -31909,10 +32248,10 @@ headers_add = X-added-header: added by $primary_hostname\n\ Exim does not check the syntax of these added header lines. Multiple &%headers_add%& options for a single router or transport can be -specified; the values will be concatenated (with a separating newline -added) before expansion. +specified; the values will append to a single list of header lines. +Each header-line is separately expanded. -The result of expanding &%headers_remove%& must consist of a colon-separated +The argument of a &%headers_remove%& option must consist of a colon-separated list of header names. This is confusing, because header names themselves are often terminated by colons. In this case, the colons are the list separators, not part of the names. For example: @@ -31921,11 +32260,12 @@ headers_remove = return-receipt-to:acknowledge-to .endd Multiple &%headers_remove%& options for a single router or transport can be -specified; the values will be concatenated (with a separating colon -added) before expansion. +specified; the arguments will append to a single header-names list. +Each item is separately expanded. -When &%headers_add%& or &%headers_remove%& is specified on a router, its value -is expanded at routing time, and then associated with all addresses that are +When &%headers_add%& or &%headers_remove%& is specified on a router, +items are expanded at routing time, +and then associated with all addresses that are accepted by that router, and also with any new addresses that it generates. If an address passes through several routers as a result of aliasing or forwarding, the changes are cumulative. @@ -34023,6 +34363,7 @@ the following table: &`R `& on &`<=`& lines: reference for local bounce &` `& on &`=>`& &`**`& and &`==`& lines: router name &`S `& size of message +&`SNI `& server name indication from TLS client hello &`ST `& shadow transport name &`T `& on &`<=`& lines: message subject (topic) &` `& on &`=>`& &`**`& and &`==`& lines: transport name @@ -34332,7 +34673,8 @@ The message that is written is &"spool file is locked"&. .next .cindex "log" "smtp confirmation" .cindex "SMTP" "logging confirmation" -&%smtp_confirmation%&: The response to the final &"."& in the SMTP dialogue for +.cindex "LMTP" "logging confirmation" +&%smtp_confirmation%&: The response to the final &"."& in the SMTP or LMTP dialogue for outgoing messages is added to delivery log lines in the form &`C=`&<&'text'&>. A number of MTAs (including Exim) return an identifying string in this response. @@ -34561,9 +34903,17 @@ This utility is a Perl script contributed by Matt Hubbard. It runs .code exim -bpu .endd -to obtain a queue listing with undelivered recipients only, and then greps the -output to select messages that match given criteria. The following selection -options are available: +or (in case &*-a*& switch is specified) +.code +exim -bp +.endd +.new +The &*-C*& option is used to specify an alternate &_exim.conf_& which might +contain alternate exim configuration the queue management might be using. +.wen + +to obtain a queue listing, and then greps the output to select messages +that match given criteria. The following selection options are available: .vlist .vitem &*-f*&&~<&'regex'&> @@ -34610,6 +34960,9 @@ Brief format &-- one line per message. .vitem &*-R*& Display messages in reverse order. + +.vitem &*-a*& +Include delivered recipients in queue listing. .endlist There is one more option, &%-h%&, which outputs a list of options.