]> git.ipfire.org Git - thirdparty/postfix.git/commitdiff
postfix-2.3-20051121
authorWietse Venema <wietse@porcupine.org>
Mon, 21 Nov 2005 05:00:00 +0000 (00:00 -0500)
committerViktor Dukhovni <viktor@dukhovni.org>
Tue, 5 Feb 2013 06:31:44 +0000 (06:31 +0000)
postfix/HISTORY
postfix/RELEASE_NOTES
postfix/html/postconf.5.html
postfix/man/man5/postconf.5
postfix/proto/postconf.proto
postfix/src/bounce/Makefile.in
postfix/src/global/mail_version.h
postfix/src/smtpd/smtpd_check.c

index bc68e68ed43d724b0201abcbe8c793f130f98fa4..c220acc036a3971fb0d1b0a869f0e8fe4a2d23a8 100644 (file)
@@ -11424,6 +11424,18 @@ Apologies for any names omitted.
        code that handles unavailable transports or destinations.
        Files: *qmgr/qmgr_deliver.c.
 
+20051121
+
+       Workaround: do not build the bounce.cf.default template
+       while compiling Postfix  - it breaks when the default
+       mail_owner etc. accounts don't exist.  Reported by Liviu
+       Daia.
+
+       Compatibility: added permit_auth_destination emulation to
+       the permit_mx_backup feature. This avoids surprises with
+       sites that used permit_mx_backup to authorize all their
+       incoming mail.
+
 Open problems:
 
        "postsuper -r" no longer resets the message arrival time,
index a5f0336fd768be1cce897b5216d1eae47d8e8e24..044ddf5651ba447cb16acff656ded56b64e6f91c 100644 (file)
@@ -17,6 +17,14 @@ Incompatibility with Postfix 2.1 and earlier
 If you upgrade from Postfix 2.1 or earlier, read RELEASE_NOTES-2.2
 before proceeding.
 
+Incompatibility with snapshot 20051121
+======================================
+
+For compatibility reasons, the permit_mx_backup feature will accept
+mail for authorized destinations (see permit_mx_backup for definition).
+Only with other destinations will it require that the local MTA is
+listed as non-primary MX.
+
 Incompatibility with snapshot 20051120
 ======================================
 
index 242d8643e3c8056453a5319636c2761af978d4eb..c9084d6e4df758b9dbfe4942889fe43fbd94f497 100644 (file)
@@ -8299,22 +8299,28 @@ contains no sender-specified routing (user@elsewhere@domain).
 
 <dt><b><a name="permit_mx_backup">permit_mx_backup</a></b></dt>
 
-<dd>Permit the request when the local mail system is MX host for
-the RCPT TO address. This includes the case that the local mail
-system is the final destination. However, the SMTP server will not
-forward mail with addresses that have sender-specified routing
-information (example: user@elsewhere@domain).  Use the optional
-<a href="postconf.5.html#permit_mx_backup_networks">permit_mx_backup_networks</a> parameter to require that the primary
-MX hosts match a list of network blocks. <br> NOTE: prior to
-Postfix version 2.0, use of <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> is not recommended;
-mail may be rejected in case of a temporary DNS lookup problem.
-
-<br> NOTE: as of Postfix version 2.3, <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> requires
-that the local MTA is not listed as primary MX for the recipient
-domain.  This is for safety reasons.
-
-<br> NOTE: use of <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> is not recommended without
-restricting its use with <a href="postconf.5.html#permit_mx_backup_networks">permit_mx_backup_networks</a>. </dd>
+<dd>Permit the request when the local mail system is backup MX for
+the RCPT TO address, or when the address is an authorized destination
+(see <a href="postconf.5.html#permit_auth_destination">permit_auth_destination</a> for definition).
+
+<ul>
+
+<li> Safety: <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> does not accept addresses that have
+sender-specified routing information (example: user@elsewhere@domain).
+
+<li> Safety: <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> can be vulnerable to mis-use when
+access is not restricted with <a href="postconf.5.html#permit_mx_backup_networks">permit_mx_backup_networks</a>.
+
+<li> Safety: as of Postfix version 2.3, <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> no longer
+accepts the address when the local mail system is primary MX for
+the recipient domain.  Exception: <a href="postconf.5.html#permit_mx_backup">permit_mx_backup</a> accepts the address
+when it specifies an authorized destination (see <a href="postconf.5.html#permit_auth_destination">permit_auth_destination</a>
+for definition).
+
+<li> Limitation: mail may be rejected in case of a temporary DNS
+lookup problem with Postfix prior to version 2.0.
+
+</ul></dd>
 
 <dt><b><a name="reject_non_fqdn_recipient">reject_non_fqdn_recipient</a></b></dt>
 
index 14fe1e75b4cfa8e307ffd9e4cf5af77aff516f97..34f297472d9f9367f4da8a4f9ea1755c067f5f77 100644 (file)
@@ -4769,24 +4769,24 @@ matches $mydestination, $inet_interfaces, $proxy_interfaces,
 $virtual_alias_domains, or $virtual_mailbox_domains, and the address
 contains no sender-specified routing (user@elsewhere@domain).
 .IP "\fBpermit_mx_backup\fR"
-Permit the request when the local mail system is MX host for
-the RCPT TO address. This includes the case that the local mail
-system is the final destination. However, the SMTP server will not
-forward mail with addresses that have sender-specified routing
-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
-Postfix version 2.0, use of permit_mx_backup is not recommended;
-mail may be rejected in case of a temporary DNS lookup problem.
-.br
-NOTE: as of Postfix version 2.3, permit_mx_backup requires
-that the local MTA is not listed as primary MX for the recipient
-domain.  This is for safety reasons.
-.br
-NOTE: use of permit_mx_backup is not recommended without
-restricting its use with permit_mx_backup_networks.
+Permit the request when the local mail system is backup MX for
+the RCPT TO address, or when the address is an authorized destination
+(see permit_auth_destination for definition).
+.IP \(bu
+Safety: permit_mx_backup does not accept addresses that have
+sender-specified routing information (example: user@elsewhere@domain).
+.IP \(bu
+Safety: permit_mx_backup can be vulnerable to mis-use when
+access is not restricted with permit_mx_backup_networks.
+.IP \(bu
+Safety: as of Postfix version 2.3, permit_mx_backup no longer
+accepts the address when the local mail system is primary MX for
+the recipient domain.  Exception: permit_mx_backup accepts the address
+when it specifies an authorized destination (see permit_auth_destination
+for definition).
+.IP \(bu
+Limitation: mail may be rejected in case of a temporary DNS
+lookup problem with Postfix prior to version 2.0.
 .IP "\fBreject_non_fqdn_recipient\fR"
 Reject the request when the RCPT TO address is not in
 fully-qualified domain form, as required by the RFC.
index fb3172d14f9a4d5bf411747ce57f57fb0458d0dc..1bb8b407ede961486424edcf309b60b7c0cfa354 100644 (file)
@@ -5192,22 +5192,28 @@ contains no sender-specified routing (user@elsewhere@domain).
 
 <dt><b><a name="permit_mx_backup">permit_mx_backup</a></b></dt>
 
-<dd>Permit the request when the local mail system is MX host for
-the RCPT TO address. This includes the case that the local mail
-system is the final destination. However, the SMTP server will not
-forward mail with addresses that have sender-specified routing
-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
-Postfix version 2.0, use of permit_mx_backup is not recommended;
-mail may be rejected in case of a temporary DNS lookup problem.
-
-<br> NOTE: as of Postfix version 2.3, permit_mx_backup requires
-that the local MTA is not listed as primary MX for the recipient
-domain.  This is for safety reasons.
-
-<br> NOTE: use of permit_mx_backup is not recommended without
-restricting its use with permit_mx_backup_networks. </dd>
+<dd>Permit the request when the local mail system is backup MX for
+the RCPT TO address, or when the address is an authorized destination
+(see permit_auth_destination for definition).
+
+<ul>
+
+<li> Safety: permit_mx_backup does not accept addresses that have
+sender-specified routing information (example: user@elsewhere@domain).
+
+<li> Safety: permit_mx_backup can be vulnerable to mis-use when
+access is not restricted with permit_mx_backup_networks.
+
+<li> Safety: as of Postfix version 2.3, permit_mx_backup no longer
+accepts the address when the local mail system is primary MX for
+the recipient domain.  Exception: permit_mx_backup accepts the address
+when it specifies an authorized destination (see permit_auth_destination
+for definition).
+
+<li> Limitation: mail may be rejected in case of a temporary DNS
+lookup problem with Postfix prior to version 2.0.
+
+</ul></dd>
 
 <dt><b><a name="reject_non_fqdn_recipient">reject_non_fqdn_recipient</a></b></dt>
 
index 9535f27ccbe095491e348f92277379216c48c773..2c0fe4982d39129fce0f10e79759d59dce7e5b5d 100644 (file)
@@ -19,16 +19,19 @@ LIBS        = ../../lib/libmaster.a ../../lib/libglobal.a ../../lib/libutil.a
 
 .c.o:;  $(CC) $(CFLAGS) -c $*.c
 
+all:   $(PROG) ../../conf/bounce.cf.default
+
 $(PROG):       $(OBJS) $(LIBS)
        $(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBS) $(SYSLIBS)
 
-# Avoid dependency on installed Postfix.
-../../conf/bounce.cf.default: $(PROG) annotate.pl main.cf
+# Eliminate dependency on installed Postfix.
+../../conf/bounce.cf.default: template_test.ref annotate.pl
        rm -f $@
-       MAIL_CONFIG=. ./$(PROG) -SVzndump_templates | perl annotate.pl >$@
+       perl annotate.pl <template_test.ref >$@
 
 main.cf:
        echo queue_directory=. >main.cf
+       echo myhostname=example.com >>main.cf
 
 $(OBJS): ../../conf/makedefs.out
 
@@ -62,6 +65,7 @@ clean:
 tidy:  clean
 
 # Avoid dependency on installed Postfix.
+# XXX This still requires that default_privs, mail_owner etc. accounts exist.
 template_test: $(PROG) main.cf template_test.ref
        MAIL_CONFIG=. ./$(PROG) -SVzndump_templates >template_test.tmp
        diff template_test.ref template_test.tmp
index 95a6c3009b832eebe16db83c2900028b0c7986d0..0d800ba0908cd9507138fbba70dcd9669f741bf1 100644 (file)
@@ -20,7 +20,7 @@
   * Patches change both the patchlevel and the release date. Snapshots have no
   * patchlevel; they change the release date only.
   */
-#define MAIL_RELEASE_DATE      "20051120"
+#define MAIL_RELEASE_DATE      "20051121"
 #define MAIL_VERSION_NUMBER    "2.3"
 
 #ifdef SNAPSHOT
index 0d9b1c6fa921c59a7781a562d51344a2cf29c9b8..e37c956d2b678759137ebaf6d75cda84ffd1ee76 100644 (file)
@@ -1560,26 +1560,23 @@ static int permit_mx_backup(SMTPD_STATE *state, const char *recipient,
        reject_dict_retry(state, recipient);
 
     /*
-     * If the destination is local, it is acceptable, because we are
-     * supposedly MX for our own address.
+     * For backwards compatibility, emulate permit_auth_destination. However,
+     * old permit_mx_backup implementations allow source routing with local
+     * address class.
      */
     if ((domain = strrchr(CONST_STR(reply->recipient), '@')) == 0)
        return (SMTPD_CHECK_OK);
     domain += 1;
+#if 0
     if (reply->flags & RESOLVE_CLASS_LOCAL)
        return (SMTPD_CHECK_OK);
-
-    /*
-     * Skip source-routed non-local or virtual mail (uncertain destination).
-     */
+#endif
     if (var_allow_untrust_route == 0 && (reply->flags & RESOLVE_FLAG_ROUTED))
        return (SMTPD_CHECK_DUNNO);
-
-    /*
-     * The destination is local, or it is a local virtual destination.
-     */
     if (reply->flags & RESOLVE_CLASS_FINAL)
        return (SMTPD_CHECK_OK);
+    if (reply->flags & RESOLVE_CLASS_RELAY)
+       return (SMTPD_CHECK_OK);
 
     if (msg_verbose)
        msg_info("%s: not local: %s", myname, recipient);
@@ -1617,7 +1614,7 @@ static int permit_mx_backup(SMTPD_STATE *state, const char *recipient,
      */
     mx_list = dns_rr_sort(mx_list, dns_rr_compare_pref);
     for (middle = mx_list; /* see below */ ; middle = rest) {
-       rest = middle->next; 
+       rest = middle->next;
        if (rest == 0)
            break;
        if (rest->pref != mx_list->pref) {