[Amavisd-new-commits] [SCM] Debian packaging for amavisd-new branch, master, updated. debian/1%2.6.4-4-15-gd7e2402

Alexander Wirt formorer at debian.org
Tue Aug 9 08:11:29 UTC 2011


The following commit has been merged in the master branch:
commit 1096aa6f576f2e1fdcedc22f9bca3713346ab4c7
Author: Alexander Wirt <formorer at debian.org>
Date:   Tue Aug 9 09:28:19 2011 +0200

    Remove 90_do_not_send_dsn_if_D_REJECT (added upstream)

diff --git a/debian/patches/00list b/debian/patches/00list
index aecc139..b95f4a9 100644
--- a/debian/patches/00list
+++ b/debian/patches/00list
@@ -4,4 +4,3 @@
 45_misc_doc_changes
 60-amavisd-snmp-subagent_paths
 85-clarify_fqdn_error.dpatch
-90_do_not_send_dsn_if_D_REJECT.dpatch
diff --git a/debian/patches/90_do_not_send_dsn_if_D_REJECT.dpatch b/debian/patches/90_do_not_send_dsn_if_D_REJECT.dpatch
deleted file mode 100755
index cf21f56..0000000
--- a/debian/patches/90_do_not_send_dsn_if_D_REJECT.dpatch
+++ /dev/null
@@ -1,78 +0,0 @@
-#! /bin/sh /usr/share/dpatch/dpatch-run
-## 90_do_not_send_dsn_if_D_REJECT.dpatch by Alexander Wirt <formorer at debian.org>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: ported from trunk (http://marc.info/?l=amavis-user&m=124725226106875&w=2)
-
- at DPATCH@
-diff -urNad pkg-amavisd-new~/amavisd pkg-amavisd-new/amavisd
---- pkg-amavisd-new~/amavisd	2009-02-26 20:39:17.000000000 +0100
-+++ pkg-amavisd-new/amavisd	2009-07-11 20:07:27.000000000 +0200
-@@ -1425,6 +1425,7 @@
-     CC_BANNED,      sub { c('final_banned_destiny') },
-     CC_SPAM,        sub { c('final_spam_destiny') },
-     CC_BADH,        sub { c('final_bad_header_destiny') },
-+    CC_MTA.',2',    D_REJECT,
-     CC_OVERSIZED,   D_BOUNCE,
-     CC_CATCHALL,    D_PASS,
-   );
-@@ -11021,6 +11022,32 @@
-         $r->blocking_ccat($blocking_ccat) if !defined($r->blocking_ccat);
-         $msginfo->blocking_ccat($blocking_ccat)
-                                           if !defined($msginfo->blocking_ccat);
-+        my($final_destiny) =
-+          $r->setting_by_contents_category(cr('final_destiny_by_ccat'));
-+        if ($final_destiny == D_PASS) {
-+          $final_destiny = D_REJECT;  # impossible to pass, change to reject
-+        }
-+        local($1,$2);
-+        $r->recip_destiny($final_destiny);
-+        if ($final_destiny == D_DISCARD && $smtp_resp =~ /^5/) {
-+          $smtp_resp =~ s{^5(\d\d) 5(\.\d\.\d)}{250 2$2};  # 5xx -> 250
-+        }
-+        my($smtp_reason) =  # get the custom smtp response reason text
-+          $r->setting_by_contents_category(cr('smtp_reason_by_ccat'));
-+        $smtp_reason = ''  if !defined $smtp_reason;
-+        if ($smtp_reason ne '') {
-+          my(%mybuiltins) = %builtins;  # make a local copy
-+          $smtp_reason = expand(\$smtp_reason, \%mybuiltins);
-+          $smtp_reason = !ref($smtp_reason) ? '' : $$smtp_reason;
-+          chomp($smtp_reason); $smtp_reason = sanitize_str($smtp_reason,1);
-+          $smtp_reason = substr($smtp_reason,0,100) . "..."
-+            if length($smtp_reason) > 100+3;
-+        }
-+        $smtp_resp =~ /^(\d\d\d(?: \d\.\d\.\d)?)\s*(.*)\z/;
-+        my($dis) = $final_destiny == D_DISCARD ? ' Discarded' : '';
-+        $r->recip_smtp_response("$1$dis $smtp_reason, $2");
-+        $r->recip_done(1); # fake a delivery (confirm delivery to a bit bucket)
-+        # note that 5xx status rejects may later be converted to bounces
-       }
-       $msginfo->header_edits($hdr_edits); # restore original edits just in case
-       $elapsed{'TimeElapsedForwarding'} = Time::HiRes::time - $t0_sect;
-@@ -17270,23 +17297,21 @@
- #
- sub enhance_smtp_response($$$$$) {
-   my($smtp_resp,$am_id,$mta_id,$dflt_enhcode,$cmd_name) = @_;
--  local($1,$2,$3); my($resp_shortmsg,$resp_msg);
-+  local($1,$2,$3); my($resp_msg);
-   my($resp_code,$resp_enhcode) = ('451', '4.5.0');
-   if (!defined($smtp_resp) || $smtp_resp eq '') {
--    $resp_shortmsg = 'No resp. to '.$cmd_name;
-+    $smtp_resp = sprintf('No resp. to %s', $cmd_name);
-   } elsif ($smtp_resp !~ /^[245]\d{2}/) {
--    $resp_shortmsg = 'Bad resp. to '.$cmd_name;
-+    $smtp_resp = sprintf('Bad resp. to %s: %s', $cmd_name,$smtp_resp);
-   } elsif ($smtp_resp =~ /^ (\d{3}) [ \t]+ ([245] \. \d{1,3} \. \d{1,3})?
-                           \s* (.*) \z/xs) {
-     ($resp_code, $resp_enhcode, $resp_msg) = ($1, $2, $3);
-     my($c) = substr($resp_code,0,1);
-     if ($resp_enhcode eq '' && $resp_code =~ /^[245]/)
-       { $resp_enhcode = $dflt_enhcode; $resp_enhcode =~ s/^\d*/$c/ }
--    $resp_shortmsg = $c eq '2' ? 'Ok' : $c eq '4' ? 'TempFailed' : 'Failed';
-   }
--  sprintf("%s %s %s, id=%s, from MTA(%s): %s",
--          $resp_code, $resp_enhcode, $resp_shortmsg,
--          $am_id, $mta_id, $smtp_resp);
-+  sprintf("%s %s from MTA(%s): %s",
-+          $resp_code, $resp_enhcode, $mta_id, $smtp_resp);
- }

-- 
Debian packaging for amavisd-new



More information about the Amavisd-new-commits mailing list