From: Wietse Venema
NOTE: Postfix versions 2.2 and later rewrite message headers -from remote SMTP clients only if the client matches the -local_header_rewrite_clients parameter, or if the -remote_header_rewrite_domain configuration parameter specifies a -non-empty value. To get the behavior before Postfix 2.2, specify -"local_header_rewrite_clients = static:all".
-The Postfix trivial-rewrite(8) daemon implements the following hard-coded address manipulations:
@@ -434,21 +427,41 @@ hard-coded address manipulations: is called a route address, and specifies that mail for "user@site" be delivered via "hosta" and "hostb". Usage of this form has been deprecated for a long time. Postfix has no ability to handle route -addresses, other than to strip off the route part. +addresses, other than to strip off the route part. + +NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
This feature is controlled by the boolean swap_bangpath parameter (default: yes). The purpose is to rewrite UUCP-style addresses to domain style. This is useful only when you receive -mail via UUCP, but it probably does not hurt otherwise.
NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
This feature is controlled by the boolean allow_percent_hack parameter (default: yes). Typically, this is used in order to deal with monstrosities such as "user%domain@otherdomain".
-NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
A single trailing dot is silently removed. However, an address that ends in multiple dots will be rejected as an invalid -address.
NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
diff --git a/postfix/html/STANDARD_CONFIGURATION_README.html b/postfix/html/STANDARD_CONFIGURATION_README.html index 00411616a..188e023f4 100644 --- a/postfix/html/STANDARD_CONFIGURATION_README.html +++ b/postfix/html/STANDARD_CONFIGURATION_README.html @@ -430,7 +430,7 @@ listening on the internal interface. In such a configuration is it is tempting to configure $inet_interfaces in each instance with just the corresponding interface address. -In most cases using inet_interaces in this way will not work, +
In most cases, using inet_interfaces in this way will not work, because as documented in the $inet_interfaces reference manual, the smtp(8) delivery agent will also use the specified interface address as the source address for outbound connections and will be unable to diff --git a/postfix/html/canonical.5.html b/postfix/html/canonical.5.html index ce76539ba..d5c9d4dd8 100644 --- a/postfix/html/canonical.5.html +++ b/postfix/html/canonical.5.html @@ -47,6 +47,14 @@ CANONICAL(5) CANONICAL(5) Sendmail rule set S3, if you like. This is controlled with the canonical_classes parameter. + NOTE: Postfix versions 2.2 and later rewrite message head- + ers from remote SMTP clients only if the client matches + the local_header_rewrite_clients parameter, or if the + remote_header_rewrite_domain configuration parameter spec- + ifies a non-empty value. To get the behavior before Post- + fix 2.2, specify "local_header_rewrite_clients = + static:all". + Typically, one would use the canonical(5) table to replace login names by Firstname.Lastname, or to clean up addresses produced by legacy mail systems. @@ -195,6 +203,15 @@ CANONICAL(5) CANONICAL(5) receives mail on. You need to stop and start Post- fix when this parameter changes. + local_header_rewrite_clients + Rewrite message header addresses in mail from these + clients and update incomplete addresses with the + domain name in $myorigin or $mydomain; either don't + rewrite message headers from other clients at all, + or rewrite message headers and update incomplete + addresses with the domain specified in the + remote_header_rewrite_domain parameter. + proxy_interfaces Other interfaces that this machine receives mail on by way of a proxy agent or network address transla- @@ -224,6 +241,12 @@ CANONICAL(5) CANONICAL(5) Give special treatment to owner-xxx and xxx-request addresses. + remote_header_rewrite_domain + Don't rewrite message headers from remote clients + at all when this parameter is empty; otherwise, re- + write message headers and append the specified + domain name to incomplete addresses. + SEE ALSO cleanup(8), canonicalize and enqueue mail postmap(1), Postfix lookup table manager @@ -235,7 +258,7 @@ CANONICAL(5) CANONICAL(5) ADDRESS_REWRITING_README, address rewriting guide LICENSE - The Secure Mailer license must be distributed with this + The Secure Mailer license must be distributed with this software. AUTHOR(S) diff --git a/postfix/html/cleanup.8.html b/postfix/html/cleanup.8.html index 4f187e1bd..792188942 100644 --- a/postfix/html/cleanup.8.html +++ b/postfix/html/cleanup.8.html @@ -245,8 +245,8 @@ CLEANUP(8) CLEANUP(8) remote_header_rewrite_domain (empty) Don't rewrite message headers from remote clients at all when this parameter is empty; otherwise, re- - write remote message headers and append the speci- - fied domain name to incomplete addresses. + write message headers and append the specified + domain name to incomplete addresses. RESOURCE AND RATE CONTROLS duplicate_filter_limit (1000) diff --git a/postfix/html/ldap_table.5.html b/postfix/html/ldap_table.5.html index c989d3089..768dabb4a 100644 --- a/postfix/html/ldap_table.5.html +++ b/postfix/html/ldap_table.5.html @@ -273,7 +273,7 @@ LDAP_TABLE(5) LDAP_TABLE(5) %[SUD1-9] The upper-case and decimal digit expansions interpolate the parts of the input key - rather than the result. Their behaviour is + rather than the result. Their behavior is identical to that described with query_fil- ter, and in fact because the input key is known in advance, lookups whose key does not diff --git a/postfix/html/local.8.html b/postfix/html/local.8.html index 1ed9eb5a9..c7c0f03c7 100644 --- a/postfix/html/local.8.html +++ b/postfix/html/local.8.html @@ -565,7 +565,7 @@ LOCAL(8) LOCAL(8) FILES The following are examples; details differ between systems. $HOME/.forward, per-user aliasing - /etc/aliases, sytem-wide alias database + /etc/aliases, system-wide alias database /var/spool/mail, system mailboxes SEE ALSO diff --git a/postfix/html/mysql_table.5.html b/postfix/html/mysql_table.5.html index fc75c4d2c..23ed116ae 100644 --- a/postfix/html/mysql_table.5.html +++ b/postfix/html/mysql_table.5.html @@ -207,7 +207,7 @@ MYSQL_TABLE(5) MYSQL_TABLE(5) %[SUD1-9] The upper-case and decimal digit expansions interpolate the parts of the input key - rather than the result. Their behaviour is + rather than the result. Their behavior is identical to that described with query, and in fact because the input key is known in advance, queries whose key does not contain diff --git a/postfix/html/pgsql_table.5.html b/postfix/html/pgsql_table.5.html index 28412b428..13152c9a5 100644 --- a/postfix/html/pgsql_table.5.html +++ b/postfix/html/pgsql_table.5.html @@ -61,7 +61,7 @@ PGSQL_TABLE(5) PGSQL_TABLE(5) query = SELECT select_function('%s') - or in the absense of selection_function, the lower prece- + or in the absence of selection_function, the lower prece- dence: query = SELECT select_field @@ -212,7 +212,7 @@ PGSQL_TABLE(5) PGSQL_TABLE(5) %[SUD1-9] The upper-case and decimal digit expansions interpolate the parts of the input key - rather than the result. Their behaviour is + rather than the result. Their behavior is identical to that described with query, and in fact because the input key is known in advance, queries whose key does not contain diff --git a/postfix/html/postconf.5.html b/postfix/html/postconf.5.html index db9d2883e..71800a22c 100644 --- a/postfix/html/postconf.5.html +++ b/postfix/html/postconf.5.html @@ -559,7 +559,7 @@ Enable the rewriting of the form "user%domain" to "user@domain". This is enabled by default.
-Note: With Postfix version 2.2, message header address rewriting +
Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -707,11 +707,11 @@ append the string "@$remo-Note 1: This feature is enabled by default and must not be turned off. +Note 1: this feature is enabled by default and must not be turned off. Postfix does not support domain-less addresses.
-Note 2: With Postfix version 2.2, message header address rewriting +
Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-Note 1: This feature is enabled by default. If disabled, users will not be +Note 1: this feature is enabled by default. If disabled, users will not be able to send mail to "user@partialdomainname" but will have to specify full domain names instead.
-Note 2: With Postfix version 2.2, message header address rewriting +
Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
NOTE: Do not use the fallback_relay feature when relaying mail +
Note: do not use the fallback_relay feature when relaying mail for a backup or primary MX domain. Mail would loop between the Postfix MX host and the fallback_relay host when the final destination is unavailable.
@@ -3291,10 +3291,12 @@ into concurrency per domain.Append the domain name in $myorigin or $mydomain to message -header addresses from these clients only; either don't rewrite -message headers from other clients at all, or append the domain -specified with the remote_header_rewrite_domain parameter.
+Rewrite message header addresses in mail from these clients and +update incomplete addresses with the domain name in $myorigin or +$mydomain; either don't rewrite message headers from other clients +at all, or rewrite message headers and update incomplete addresses +with the domain specified in the remote_header_rewrite_domain +parameter.
See the append_at_myorigin and append_dot_mydomain parameters for details of how domain names are appended to incomplete addresses. @@ -3369,7 +3371,7 @@ from Postfix sendmail and in SMTP mail from this machine.
$myorigin or $mydomain information only with mail from Postfix sendmail, from local clients, or from authorized SMTP clients. -NOTE: This setting will not prevent remote mail header address +
Note: this setting will not prevent remote mail header address rewriting when mail from a remote client is forwarded by a neighboring system.
@@ -3537,7 +3539,7 @@ Note: luser_relay works only for the P-NOTE: if you use this feature for accounts not in the UNIX password +Note: if you use this feature for accounts not in the UNIX password file, then you must specify "local_recipient_maps =" (i.e. empty) in the main.cf file, otherwise the Postfix SMTP server will reject mail for non-UNIX accounts with "User unknown in local recipient table". @@ -5058,11 +5060,11 @@ run "postmap /etc/postfix/recipient_bcc".
-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -5231,7 +5233,7 @@ recipient addresses with $relay_r recipients. See also the relay domains address class in the ADDRESS_CLASS_README file. -NOTE: Postfix will not automatically forward mail for domains +
Note: Postfix will not automatically forward mail for domains that list this system as their primary or backup MX host. See the permit_mx_backup restriction in the postconf(5) manual page.
@@ -5395,8 +5397,8 @@ Examples: (default: empty)Don't rewrite message headers from remote clients at all when -this parameter is empty; otherwise, rewrite remote message headers -and append the specified domain name to incomplete addresses. The +this parameter is empty; otherwise, rewrite message headers and +append the specified domain name to incomplete addresses. The local_header_rewrite_clients parameter controls what clients Postfix considers local.
@@ -5548,11 +5550,11 @@ run "postmap /etc/postfix/sender_bcc".-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -6790,7 +6792,7 @@ TLS session cache. Specify a database type that supports enumeration, such as btree or sdbm; there is no need to support concurrent access. The file is created if it does not exist. -NOTE: dbm databases are not suitable. TLS +
Note: dbm databases are not suitable. TLS session objects are too large.
Example:
@@ -7291,7 +7293,7 @@ a restriction list, to make the default policy explicit.NOTE: dbm databases are not suitable. TLS +
Note: dbm databases are not suitable. TLS session objects are too large.
Example:
@@ -9135,7 +9137,7 @@ necessary if your machine is connected to UUCP networks. It is enabled by default. -Note: With Postfix version 2.2, message header address rewriting +
Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-Note 1: The dotlock method requires that the recipient UID +Note 1: the dotlock method requires that the recipient UID or GID has write access to the parent directory of the recipient's mailbox file.
diff --git a/postfix/html/smtpd.8.html b/postfix/html/smtpd.8.html index 6af8d162b..a6362559e 100644 --- a/postfix/html/smtpd.8.html +++ b/postfix/html/smtpd.8.html @@ -130,11 +130,13 @@ SMTPD(8) SMTPD(8) Available in Postfix version 2.2 and later: local_header_rewrite_clients (permit_inet_interfaces) - Append the domain name in $myorigin or $mydomain to - message header addresses from these clients only; - either don't rewrite message headers from other - clients at all, or append the domain specified with - the remote_header_rewrite_domain parameter. + Rewrite message header addresses in mail from these + clients and update incomplete addresses with the + domain name in $myorigin or $mydomain; either don't + rewrite message headers from other clients at all, + or rewrite message headers and update incomplete + addresses with the domain specified in the + remote_header_rewrite_domain parameter. AFTER QUEUE EXTERNAL CONTENT INSPECTION CONTROLS As of version 1.0, Postfix can be configured to send new diff --git a/postfix/man/man5/canonical.5 b/postfix/man/man5/canonical.5 index 36ce43938..4cf4253c5 100644 --- a/postfix/man/man5/canonical.5 +++ b/postfix/man/man5/canonical.5 @@ -44,6 +44,13 @@ that are used in SMTP protocol commands). Think Sendmail rule set \fBS3\fR, if you like. This is controlled with the \fBcanonical_classes\fR parameter. +NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies +a non-empty value. To get the behavior before Postfix 2.2, +specify "local_header_rewrite_clients = static:all". + Typically, one would use the \fBcanonical\fR(5) table to replace login names by \fIFirstname.Lastname\fR, or to clean up addresses produced by legacy mail systems. @@ -191,6 +198,13 @@ Other parameters of interest: .IP \fBinet_interfaces\fR The network interface addresses that this system receives mail on. You need to stop and start Postfix when this parameter changes. +.IP \fBlocal_header_rewrite_clients\fR +Rewrite message header addresses in mail from these clients +and update incomplete addresses with the domain name in +$myorigin or $mydomain; either don't rewrite message headers +from other clients at all, or rewrite message headers and +update incomplete addresses with the domain specified in +the remote_header_rewrite_domain parameter. .IP \fBproxy_interfaces\fR Other interfaces that this machine receives mail on by way of a proxy agent or network address translator. @@ -209,6 +223,11 @@ The domain that is appended to locally-posted mail. .IP \fBowner_request_special\fR Give special treatment to \fBowner-\fIxxx\fR and \fIxxx\fB-request\fR addresses. +.IP \fBremote_header_rewrite_domain\fR +Don't rewrite message headers from remote clients at all +when this parameter is empty; otherwise, rewrite message +headers and append the specified domain name to incomplete +addresses. .SH "SEE ALSO" .na .nf diff --git a/postfix/man/man5/ldap_table.5 b/postfix/man/man5/ldap_table.5 index c4b1d8f8a..3aa9e1e63 100644 --- a/postfix/man/man5/ldap_table.5 +++ b/postfix/man/man5/ldap_table.5 @@ -262,7 +262,7 @@ is skipped. .IP "\fB\fB%[SUD1-9]\fR\fB" The upper-case and decimal digit expansions interpolate the parts of the input key rather than the result. Their -behaviour is identical to that described with \fBquery_filter\fR, +behavior is identical to that described with \fBquery_filter\fR, and in fact because the input key is known in advance, lookups whose key does not contain all the information specified in the result template are suppressed and return no results. diff --git a/postfix/man/man5/mysql_table.5 b/postfix/man/man5/mysql_table.5 index 4ccb097ba..b3f3c3eb2 100644 --- a/postfix/man/man5/mysql_table.5 +++ b/postfix/man/man5/mysql_table.5 @@ -214,7 +214,7 @@ is skipped. .IP "\fB\fB%[SUD1-9]\fR\fB" The upper-case and decimal digit expansions interpolate the parts of the input key rather than the result. Their -behaviour is identical to that described with \fBquery\fR, +behavior is identical to that described with \fBquery\fR, and in fact because the input key is known in advance, queries whose key does not contain all the information specified in the result template are suppressed and return no results. diff --git a/postfix/man/man5/pgsql_table.5 b/postfix/man/man5/pgsql_table.5 index 6a3925c47..ccf886457 100644 --- a/postfix/man/man5/pgsql_table.5 +++ b/postfix/man/man5/pgsql_table.5 @@ -63,7 +63,7 @@ migrate to the new interface set: .ti +4 \fBquery\fR = SELECT \fIselect_function\fR('%s') -or in the absense of \fBselection_function\fR, the lower precedence: +or in the absence of \fBselection_function\fR, the lower precedence: .ti +4 \fBquery\fR = SELECT \fIselect_field\fR @@ -215,7 +215,7 @@ is skipped. .IP "\fB\fB%[SUD1-9]\fR\fB" The upper-case and decimal digit expansions interpolate the parts of the input key rather than the result. Their -behaviour is identical to that described with \fBquery\fR, +behavior is identical to that described with \fBquery\fR, and in fact because the input key is known in advance, queries whose key does not contain all the information specified in the result template are suppressed and return no results. diff --git a/postfix/man/man5/postconf.5 b/postfix/man/man5/postconf.5 index 3e60aa7fc..4e3570cd5 100644 --- a/postfix/man/man5/postconf.5 +++ b/postfix/man/man5/postconf.5 @@ -306,7 +306,7 @@ difficult to enforce consistently and globally. Enable the rewriting of the form "user%domain" to "user@domain". This is enabled by default. .PP -Note: With Postfix version 2.2, message header address rewriting +Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true: .IP \(bu The message is received with the Postfix \fBsendmail\fR(1) command, @@ -352,10 +352,10 @@ and \fBpostdrop\fR(1). Optional address that receives a "blind carbon copy" of each message that is received by the Postfix mail system. .PP -NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender. .PP -NOTE: automatic BCC recipients are produced only for new mail. +Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself. @@ -385,10 +385,10 @@ With locally submitted mail, append the string "@$myorigin" to mail addresses without domain information. With remotely submitted mail, append the string "@$remote_header_rewrite_domain" instead. .PP -Note 1: This feature is enabled by default and must not be turned off. +Note 1: this feature is enabled by default and must not be turned off. Postfix does not support domain-less addresses. .PP -Note 2: With Postfix version 2.2, message header address rewriting +Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true: .IP \(bu The message is received with the Postfix \fBsendmail\fR(1) command, @@ -407,11 +407,11 @@ addresses that have no ".domain" information. With remotely submitted mail, append the string ".$remote_header_rewrite_domain" instead. .PP -Note 1: This feature is enabled by default. If disabled, users will not be +Note 1: this feature is enabled by default. If disabled, users will not be able to send mail to "user@partialdomainname" but will have to specify full domain names instead. .PP -Note 2: With Postfix version 2.2, message header address rewriting +Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true: .IP \(bu The message is received with the Postfix \fBsendmail\fR(1) command, @@ -1172,7 +1172,7 @@ host, host:port, [host]:port, [address] or [address]:port; the form [host] turns off MX lookups. If you specify multiple SMTP destinations, Postfix will try them in the specified order. .PP -NOTE: Do not use the fallback_relay feature when relaying mail +Note: do not use the fallback_relay feature when relaying mail for a backup or primary MX domain. Mail would loop between the Postfix MX host and the fallback_relay host when the final destination is unavailable. @@ -1737,10 +1737,12 @@ Setting this parameter to a value > 1 changes the meaning of local_destination_concurrency_limit from concurrency per recipient into concurrency per domain. .SH local_header_rewrite_clients (default: permit_inet_interfaces) -Append the domain name in $myorigin or $mydomain to message -header addresses from these clients only; either don't rewrite -message headers from other clients at all, or append the domain -specified with the remote_header_rewrite_domain parameter. +Rewrite message header addresses in mail from these clients and +update incomplete addresses with the domain name in $myorigin or +$mydomain; either don't rewrite message headers from other clients +at all, or rewrite message headers and update incomplete addresses +with the domain specified in the remote_header_rewrite_domain +parameter. .PP See the append_at_myorigin and append_dot_mydomain parameters for details of how domain names are appended to incomplete addresses. @@ -1805,7 +1807,7 @@ The intermediate setting: rewrite header addresses and append $myorigin or $mydomain information only with mail from Postfix sendmail, from local clients, or from authorized SMTP clients. .PP -NOTE: This setting will not prevent remote mail header address +Note: this setting will not prevent remote mail header address rewriting when mail from a remote client is forwarded by a neighboring system. .PP @@ -1908,7 +1910,7 @@ Instead of $name you can also specify ${name} or $(name). .PP Note: luser_relay works only for the Postfix \fBlocal\fR(8) delivery agent. .PP -NOTE: if you use this feature for accounts not in the UNIX password +Note: if you use this feature for accounts not in the UNIX password file, then you must specify "local_recipient_maps =" (i.e. empty) in the main.cf file, otherwise the Postfix SMTP server will reject mail for non-UNIX accounts with "User unknown in local recipient table". @@ -2739,10 +2741,10 @@ Look up the "@domain.tld" part. Specify the types and names of databases to use. After change, run "\fBpostmap /etc/postfix/recipient_bcc\fR". .PP -NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender. .PP -NOTE: automatic BCC recipients are produced only for new mail. +Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself. @@ -2862,7 +2864,7 @@ recipient addresses with $relay_recipient_maps and rejects non-existent recipients. See also the relay domains address class in the ADDRESS_CLASS_README file. .PP -NOTE: Postfix will not automatically forward mail for domains +Note: Postfix will not automatically forward mail for domains that list this system as their primary or backup MX host. See the permit_mx_backup restriction in the \fBpostconf\fR(5) manual page. .PP @@ -2966,8 +2968,8 @@ relocated_maps = hash:/etc/postfix/relocated .ft R .SH remote_header_rewrite_domain (default: empty) Don't rewrite message headers from remote clients at all when -this parameter is empty; otherwise, rewrite remote message headers -and append the specified domain name to incomplete addresses. The +this parameter is empty; otherwise, rewrite message headers and +append the specified domain name to incomplete addresses. The local_header_rewrite_clients parameter controls what clients Postfix considers local. .PP @@ -3064,10 +3066,10 @@ Look up the "@domain.tld" part. Specify the types and names of databases to use. After change, run "\fBpostmap /etc/postfix/sender_bcc\fR". .PP -NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender. .PP -NOTE: automatic BCC recipients are produced only for new mail. +Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself. @@ -3785,7 +3787,7 @@ TLS session cache. Specify a database type that supports enumeration, such as \fBbtree\fR or \fBsdbm\fR; there is no need to support concurrent access. The file is created if it does not exist. .PP -NOTE: \fBdbm\fR databases are not suitable. TLS +Note: \fBdbm\fR databases are not suitable. TLS session objects are too large. .PP Example: @@ -4112,7 +4114,7 @@ and the message has multiple envelope recipients. Although this usage is technically allowed, it seems to have no legitimate application. .br -NOTE: this restriction can only work reliably +Note: this restriction can only work reliably when used in smtpd_data_restrictions or smtpd_end_of_data_restrictions, because the total number of recipients is not known at an earlier stage of the SMTP conversation. @@ -4129,7 +4131,7 @@ ESMTP command pipelining. This stops mail from bulk mail software that improperly uses ESMTP command pipelining in order to speed up deliveries. .br -NOTE: reject_unauth_pipelining is not useful +Note: reject_unauth_pipelining is not useful outside smtpd_data_restrictions when 1) the client uses ESMTP (EHLO instead of HELO) and 2) with "smtpd_delay_reject = yes" (the default). The use of reject_unauth_pipelining in the other @@ -4548,7 +4550,7 @@ information (example: user@elsewhere@domain). Use the optional permit_mx_backup_networks parameter to require that the primary MX hosts match a list of network blocks. .br -NOTE: prior to +Note: prior to Postfix version 2.0, use of permit_mx_backup is not recommended; mail may be rejected in case of a temporary DNS lookup problem. .IP "\fBreject_non_fqdn_recipient\fR" @@ -5170,7 +5172,7 @@ TLS session cache. Specify a database type that supports enumeration, such as \fBbtree\fR or \fBsdbm\fR; there is no need to support concurrent access. The file is created if it does not exist. .PP -NOTE: \fBdbm\fR databases are not suitable. TLS +Note: \fBdbm\fR databases are not suitable. TLS session objects are too large. .PP Example: @@ -5276,7 +5278,7 @@ Enable the rewriting of "site!user" into "user@site". This is necessary if your machine is connected to UUCP networks. It is enabled by default. .PP -Note: With Postfix version 2.2, message header address rewriting +Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true: .IP \(bu The message is received with the Postfix \fBsendmail\fR(1) command, @@ -5629,7 +5631,7 @@ delivery. For a list of available file locking methods, use the This setting is ignored with \fBmaildir\fR style delivery, because such deliveries are safe without application-level locks. .PP -Note 1: The \fBdotlock\fR method requires that the recipient UID +Note 1: the \fBdotlock\fR method requires that the recipient UID or GID has write access to the parent directory of the recipient's mailbox file. .PP diff --git a/postfix/man/man8/cleanup.8 b/postfix/man/man8/cleanup.8 index 0093e4113..f1cce61e6 100644 --- a/postfix/man/man8/cleanup.8 +++ b/postfix/man/man8/cleanup.8 @@ -209,8 +209,8 @@ What addresses are subject to sender_canonical_maps address mapping. .IP "\fBremote_header_rewrite_domain (empty)\fR" Don't rewrite message headers from remote clients at all when -this parameter is empty; otherwise, rewrite remote message headers -and append the specified domain name to incomplete addresses. +this parameter is empty; otherwise, rewrite message headers and +append the specified domain name to incomplete addresses. .SH "RESOURCE AND RATE CONTROLS" .na .nf diff --git a/postfix/man/man8/local.8 b/postfix/man/man8/local.8 index 00156aa8f..7165dddf3 100644 --- a/postfix/man/man8/local.8 +++ b/postfix/man/man8/local.8 @@ -537,7 +537,7 @@ records, so that "smtpd" becomes, for example, "postfix/smtpd". .nf The following are examples; details differ between systems. $HOME/.forward, per-user aliasing -/etc/aliases, sytem-wide alias database +/etc/aliases, system-wide alias database /var/spool/mail, system mailboxes .SH "SEE ALSO" .na diff --git a/postfix/man/man8/smtpd.8 b/postfix/man/man8/smtpd.8 index 194cb0266..1a5b2b35a 100644 --- a/postfix/man/man8/smtpd.8 +++ b/postfix/man/man8/smtpd.8 @@ -127,10 +127,12 @@ filtering, or address mapping. .PP Available in Postfix version 2.2 and later: .IP "\fBlocal_header_rewrite_clients (permit_inet_interfaces)\fR" -Append the domain name in $myorigin or $mydomain to message -header addresses from these clients only; either don't rewrite -message headers from other clients at all, or append the domain -specified with the remote_header_rewrite_domain parameter. +Rewrite message header addresses in mail from these clients and +update incomplete addresses with the domain name in $myorigin or +$mydomain; either don't rewrite message headers from other clients +at all, or rewrite message headers and update incomplete addresses +with the domain specified in the remote_header_rewrite_domain +parameter. .SH "AFTER QUEUE EXTERNAL CONTENT INSPECTION CONTROLS" .na .nf diff --git a/postfix/proto/ADDRESS_REWRITING_README.html b/postfix/proto/ADDRESS_REWRITING_README.html index a8ac3d1bd..4955a6e8b 100644 --- a/postfix/proto/ADDRESS_REWRITING_README.html +++ b/postfix/proto/ADDRESS_REWRITING_README.html @@ -153,21 +153,21 @@ how it works:NOTE: Postfix versions 2.2 and later rewrite message headers -from remote SMTP clients only if the client matches the -local_header_rewrite_clients parameter, or if the -remote_header_rewrite_domain configuration parameter specifies a -non-empty value. To get the behavior before Postfix 2.2, specify -"local_header_rewrite_clients = static:all".
-The Postfix trivial-rewrite(8) daemon implements the following hard-coded address manipulations:
@@ -434,21 +427,41 @@ hard-coded address manipulations: is called a route address, and specifies that mail for "user@site" be delivered via "hosta" and "hostb". Usage of this form has been deprecated for a long time. Postfix has no ability to handle route -addresses, other than to strip off the route part.NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
This feature is controlled by the boolean swap_bangpath parameter (default: yes). The purpose is to rewrite UUCP-style addresses to domain style. This is useful only when you receive -mail via UUCP, but it probably does not hurt otherwise.
NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
This feature is controlled by the boolean allow_percent_hack parameter (default: yes). Typically, this is used in order to deal with monstrosities such as "user%domain@otherdomain".
-NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
A single trailing dot is silently removed. However, an address that ends in multiple dots will be rejected as an invalid -address.
NOTE: Postfix versions 2.2 and later rewrite message headers +from remote SMTP clients only if the client matches the +local_header_rewrite_clients parameter, or if the +remote_header_rewrite_domain configuration parameter specifies a +non-empty value. To get the behavior before Postfix 2.2, specify +"local_header_rewrite_clients = static:all".
diff --git a/postfix/proto/STANDARD_CONFIGURATION_README.html b/postfix/proto/STANDARD_CONFIGURATION_README.html index e97ff32fb..9b0ae01cb 100644 --- a/postfix/proto/STANDARD_CONFIGURATION_README.html +++ b/postfix/proto/STANDARD_CONFIGURATION_README.html @@ -430,7 +430,7 @@ listening on the internal interface. In such a configuration is it is tempting to configure $inet_interfaces in each instance with just the corresponding interface address. -In most cases using inet_interaces in this way will not work, +
In most cases, using inet_interfaces in this way will not work, because as documented in the $inet_interfaces reference manual, the smtp(8) delivery agent will also use the specified interface address as the source address for outbound connections and will be unable to diff --git a/postfix/proto/canonical b/postfix/proto/canonical index 2d7f17b72..fa04fbf74 100644 --- a/postfix/proto/canonical +++ b/postfix/proto/canonical @@ -38,6 +38,13 @@ # rule set \fBS3\fR, if you like. This is controlled with # the \fBcanonical_classes\fR parameter. # +# NOTE: Postfix versions 2.2 and later rewrite message headers +# from remote SMTP clients only if the client matches the +# local_header_rewrite_clients parameter, or if the +# remote_header_rewrite_domain configuration parameter specifies +# a non-empty value. To get the behavior before Postfix 2.2, +# specify "local_header_rewrite_clients = static:all". +# # Typically, one would use the \fBcanonical\fR(5) table to replace login # names by \fIFirstname.Lastname\fR, or to clean up addresses produced # by legacy mail systems. @@ -169,6 +176,13 @@ # .IP \fBinet_interfaces\fR # The network interface addresses that this system receives mail on. # You need to stop and start Postfix when this parameter changes. +# .IP \fBlocal_header_rewrite_clients\fR +# Rewrite message header addresses in mail from these clients +# and update incomplete addresses with the domain name in +# $myorigin or $mydomain; either don't rewrite message headers +# from other clients at all, or rewrite message headers and +# update incomplete addresses with the domain specified in +# the remote_header_rewrite_domain parameter. # .IP \fBproxy_interfaces\fR # Other interfaces that this machine receives mail on by way of a # proxy agent or network address translator. @@ -187,6 +201,11 @@ # .IP \fBowner_request_special\fR # Give special treatment to \fBowner-\fIxxx\fR and \fIxxx\fB-request\fR # addresses. +# .IP \fBremote_header_rewrite_domain\fR +# Don't rewrite message headers from remote clients at all +# when this parameter is empty; otherwise, rewrite message +# headers and append the specified domain name to incomplete +# addresses. # SEE ALSO # cleanup(8), canonicalize and enqueue mail # postmap(1), Postfix lookup table manager diff --git a/postfix/proto/ldap_table b/postfix/proto/ldap_table index c3a0fdf13..13dc54972 100644 --- a/postfix/proto/ldap_table +++ b/postfix/proto/ldap_table @@ -250,7 +250,7 @@ # .IP "\fB\fB%[SUD1-9]\fR\fB" # The upper-case and decimal digit expansions interpolate # the parts of the input key rather than the result. Their -# behaviour is identical to that described with \fBquery_filter\fR, +# behavior is identical to that described with \fBquery_filter\fR, # and in fact because the input key is known in advance, lookups # whose key does not contain all the information specified in # the result template are suppressed and return no results. diff --git a/postfix/proto/mysql_table b/postfix/proto/mysql_table index f3b3837ad..1ddc07aa9 100644 --- a/postfix/proto/mysql_table +++ b/postfix/proto/mysql_table @@ -202,7 +202,7 @@ # .IP "\fB\fB%[SUD1-9]\fR\fB" # The upper-case and decimal digit expansions interpolate # the parts of the input key rather than the result. Their -# behaviour is identical to that described with \fBquery\fR, +# behavior is identical to that described with \fBquery\fR, # and in fact because the input key is known in advance, queries # whose key does not contain all the information specified in # the result template are suppressed and return no results. diff --git a/postfix/proto/pgsql_table b/postfix/proto/pgsql_table index 2a3be10c3..074ec7f0f 100644 --- a/postfix/proto/pgsql_table +++ b/postfix/proto/pgsql_table @@ -55,7 +55,7 @@ # .ti +4 # \fBquery\fR = SELECT \fIselect_function\fR('%s') # -# or in the absense of \fBselection_function\fR, the lower precedence: +# or in the absence of \fBselection_function\fR, the lower precedence: # # .ti +4 # \fBquery\fR = SELECT \fIselect_field\fR @@ -203,7 +203,7 @@ # .IP "\fB\fB%[SUD1-9]\fR\fB" # The upper-case and decimal digit expansions interpolate # the parts of the input key rather than the result. Their -# behaviour is identical to that described with \fBquery\fR, +# behavior is identical to that described with \fBquery\fR, # and in fact because the input key is known in advance, queries # whose key does not contain all the information specified in # the result template are suppressed and return no results. diff --git a/postfix/proto/postconf.proto b/postfix/proto/postconf.proto index d97a5c478..83eedcdda 100644 --- a/postfix/proto/postconf.proto +++ b/postfix/proto/postconf.proto @@ -511,7 +511,7 @@ Enable the rewriting of the form "user%domain" to "user@domain". This is enabled by default.
-Note: With Postfix version 2.2, message header address rewriting +
Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -1217,7 +1217,7 @@ host, host:port, [host]:port, [address] or [address]:port; the form [host] turns off MX lookups. If you specify multiple SMTP destinations, Postfix will try them in the specified order. -NOTE: Do not use the fallback_relay feature when relaying mail +
Note: do not use the fallback_relay feature when relaying mail for a backup or primary MX domain. Mail would loop between the Postfix MX host and the fallback_relay host when the final destination is unavailable.
@@ -2146,7 +2146,7 @@ Note: luser_relay works only for the Postfix local(8) delivery agent.-NOTE: if you use this feature for accounts not in the UNIX password +Note: if you use this feature for accounts not in the UNIX password file, then you must specify "local_recipient_maps =" (i.e. empty) in the main.cf file, otherwise the Postfix SMTP server will reject mail for non-UNIX accounts with "User unknown in local recipient table". @@ -3094,11 +3094,11 @@ run "postmap /etc/postfix/recipient_bcc".
-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -3175,7 +3175,7 @@ recipient addresses with $relay_recipient_maps and rejects non-existent recipients. See also the relay domains address class in the ADDRESS_CLASS_README file. -NOTE: Postfix will not automatically forward mail for domains +
Note: Postfix will not automatically forward mail for domains that list this system as their primary or backup MX host. See the permit_mx_backup restriction in the postconf(5) manual page.
@@ -3367,11 +3367,11 @@ run "postmap /etc/postfix/sender_bcc".-NOTE: if mail to the BCC address bounces it will be returned to +Note: if mail to the BCC address bounces it will be returned to the sender.
-NOTE: automatic BCC recipients are produced only for new mail. +
Note: automatic BCC recipients are produced only for new mail. To avoid mailer loops, automatic BCC recipients are not generated for mail that Postfix forwards internally, nor for mail that Postfix generates itself.
@@ -4500,7 +4500,7 @@ a restriction list, to make the default policy explicit.Note: With Postfix version 2.2, message header address rewriting +
Note: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-Note 1: This feature is enabled by default and must not be turned off. +Note 1: this feature is enabled by default and must not be turned off. Postfix does not support domain-less addresses.
-Note 2: With Postfix version 2.2, message header address rewriting +
Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-Note 1: This feature is enabled by default. If disabled, users will not be +Note 1: this feature is enabled by default. If disabled, users will not be able to send mail to "user@partialdomainname" but will have to specify full domain names instead.
-Note 2: With Postfix version 2.2, message header address rewriting +
Note 2: with Postfix version 2.2, message header address rewriting happens only when one of the following conditions is true:
-Note 1: The dotlock method requires that the recipient UID +Note 1: the dotlock method requires that the recipient UID or GID has write access to the parent directory of the recipient's mailbox file.
@@ -7665,8 +7665,8 @@ physical endpoints. %PARAM remote_header_rewrite_domainDon't rewrite message headers from remote clients at all when -this parameter is empty; otherwise, rewrite remote message headers -and append the specified domain name to incomplete addresses. The +this parameter is empty; otherwise, rewrite message headers and +append the specified domain name to incomplete addresses. The local_header_rewrite_clients parameter controls what clients Postfix considers local.
@@ -7689,10 +7689,12 @@ clients at all. %PARAM local_header_rewrite_clients permit_inet_interfaces -Append the domain name in $myorigin or $mydomain to message -header addresses from these clients only; either don't rewrite -message headers from other clients at all, or append the domain -specified with the remote_header_rewrite_domain parameter.
+Rewrite message header addresses in mail from these clients and +update incomplete addresses with the domain name in $myorigin or +$mydomain; either don't rewrite message headers from other clients +at all, or rewrite message headers and update incomplete addresses +with the domain specified in the remote_header_rewrite_domain +parameter.
See the append_at_myorigin and append_dot_mydomain parameters for details of how domain names are appended to incomplete addresses. @@ -7767,7 +7769,7 @@ from Postfix sendmail and in SMTP mail from this machine.
$myorigin or $mydomain information only with mail from Postfix sendmail, from local clients, or from authorized SMTP clients. -NOTE: This setting will not prevent remote mail header address +
Note: this setting will not prevent remote mail header address rewriting when mail from a remote client is forwarded by a neighboring system.
@@ -7989,7 +7991,7 @@ TLS session cache. Specify a database type that supports enumeration, such as btree or sdbm; there is no need to support concurrent access. The file is created if it does not exist. -NOTE: dbm databases are not suitable. TLS +
Note: dbm databases are not suitable. TLS session objects are too large.
Example:
@@ -8186,7 +8188,7 @@ TLS session cache. Specify a database type that supports enumeration, such as btree or sdbm; there is no need to support concurrent access. The file is created if it does not exist. -NOTE: dbm databases are not suitable. TLS +
Note: dbm databases are not suitable. TLS session objects are too large.
Example:
diff --git a/postfix/src/cleanup/cleanup.c b/postfix/src/cleanup/cleanup.c index a8a3ee083..720e4fe97 100644 --- a/postfix/src/cleanup/cleanup.c +++ b/postfix/src/cleanup/cleanup.c @@ -185,8 +185,8 @@ /* mapping. /* .IP "\fBremote_header_rewrite_domain (empty)\fR" /* Don't rewrite message headers from remote clients at all when -/* this parameter is empty; otherwise, rewrite remote message headers -/* and append the specified domain name to incomplete addresses. +/* this parameter is empty; otherwise, rewrite message headers and +/* append the specified domain name to incomplete addresses. /* RESOURCE AND RATE CONTROLS /* .ad /* .fi diff --git a/postfix/src/global/mail_version.h b/postfix/src/global/mail_version.h index 7a911e3cd..a1766cde0 100644 --- a/postfix/src/global/mail_version.h +++ b/postfix/src/global/mail_version.h @@ -20,7 +20,7 @@ * Patches change the patchlevel and the release date. Snapshots change the * release date only. */ -#define MAIL_RELEASE_DATE "20050308" +#define MAIL_RELEASE_DATE "20050309" #define MAIL_VERSION_NUMBER "2.3" #define VAR_MAIL_VERSION "mail_version" diff --git a/postfix/src/local/local.c b/postfix/src/local/local.c index 413b6fdce..7dfc6770e 100644 --- a/postfix/src/local/local.c +++ b/postfix/src/local/local.c @@ -493,7 +493,7 @@ /* FILES /* The following are examples; details differ between systems. /* $HOME/.forward, per-user aliasing -/* /etc/aliases, sytem-wide alias database +/* /etc/aliases, system-wide alias database /* /var/spool/mail, system mailboxes /* SEE ALSO /* qmgr(8), queue manager diff --git a/postfix/src/smtpd/smtpd.c b/postfix/src/smtpd/smtpd.c index 811f75c26..756a4cd93 100644 --- a/postfix/src/smtpd/smtpd.c +++ b/postfix/src/smtpd/smtpd.c @@ -109,10 +109,12 @@ /* .PP /* Available in Postfix version 2.2 and later: /* .IP "\fBlocal_header_rewrite_clients (permit_inet_interfaces)\fR" -/* Append the domain name in $myorigin or $mydomain to message -/* header addresses from these clients only; either don't rewrite -/* message headers from other clients at all, or append the domain -/* specified with the remote_header_rewrite_domain parameter. +/* Rewrite message header addresses in mail from these clients and +/* update incomplete addresses with the domain name in $myorigin or +/* $mydomain; either don't rewrite message headers from other clients +/* at all, or rewrite message headers and update incomplete addresses +/* with the domain specified in the remote_header_rewrite_domain +/* parameter. /* AFTER QUEUE EXTERNAL CONTENT INSPECTION CONTROLS /* .ad /* .fi