diff -ur old/postfix-2.9.6/src/global/post_mail.c new/postfix-2.9.6/src/global/post_mail.c
--- old/postfix-2.9.6/src/global/post_mail.c 2007-02-12 15:34:48.000000000 -0500
+++ new/postfix-2.9.6/src/global/post_mail.c 2014-03-08 07:31:00.000000000 -0500
@@ -165,6 +165,10 @@
#include <post_mail.h>
#include <mail_date.h>
+/* Client stubs. */
+
+#include <resolve_clnt.h>
+
/*
* Call-back state for asynchronous connection requests.
*/
@@ -207,6 +211,23 @@
msg_fatal("unable to contact the %s service", var_cleanup_service);
/*
+ * If trying to send to a domain which "should be limited to
+ * authorized senders only", this is probably an attempt to do
+ * "accept-then-bounce". Send to the local postmaster instead.
+ */
+ if (filter_class & INT_FILT_MASK_BOUNCE) {
+ RESOLVE_REPLY reply;
+ resolve_clnt_init(&reply);
+ resolve_clnt_query(recipient, &reply);
+ if (reply.flags & RESOLVE_CLASS_DEFAULT) {
+ msg_warn("%s: blocking outbound message; diverting to postmaster",
+ vstring_str(id));
+ recipient = "postmaster";
+ }
+ resolve_clnt_free(&reply);
+ }
+
+ /*
* Generate a minimal envelope section. The cleanup service will add a
* size record.
*/
_______________________________________________
Secure-testing-team mailing list
[email protected]
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/secure-testing-team