]> gitweb.michael.orlitzky.com - postfix-logwatch.git/blobdiff - postfix-logwatch
Ignore postscreen "BDAT/DATA without valid RCPT" lines.
[postfix-logwatch.git] / postfix-logwatch
index 827dfe0d968806e7a7b4d322b86cdfa0b5271e93..1b89ad6382b35928eccb9bb9e82bce5673c12b41 100644 (file)
@@ -4359,7 +4359,8 @@ sub postfix_postscreen {
       $line =~ /discarding EHLO keywords: / or
       $line =~ /: discard_mask / or
       $line =~ /: sq=\d+ cq=\d+ event/ or
-      $line =~ /: replacing command "/
+      $line =~ /: replacing command "/ or
+      $line =~ /^(DATA|BDAT) without valid RCPT/
    );
 
 
@@ -4399,14 +4400,11 @@ sub postfix_postscreen {
       }
    }
 
-   elsif ($line =~ /^NOQUEUE: reject: CONNECT from \[([^]]+)\](?::\d+)?: too many connections/) {
-      # NOQUEUE: reject: CONNECT from [192.168.0.1]:7197: too many connections
-      $Counts{'postscreen'}{'reject'}{'Too many connections'}{$1}{$END_KEY}++      if $Collecting{'postscreen'};
-   }
-
-   elsif ($line =~ /^reject: connect from \[([^]]+)\](?::\d+)?: (.+)$/) {
-      # reject: connect from [192.168.0.1]:21225: all screening ports busy
-      $Counts{'postscreen'}{'reject'}{"\u$2"}{$1}{$END_KEY}++      if $Collecting{'postscreen'};
+   elsif ($line =~ /^(NOQUEUE: )?reject: (connect|CONNECT) from \[([^]]+)\](?::\d+)?: (.+)$/) {
+       # NOQUEUE: reject: CONNECT from [192.168.0.1]:7197: too many connections
+       # NOQUEUE: reject: CONNECT from [192.168.0.1]:39410: all server ports busy
+       # reject: connect from [192.168.0.1]:21225: all screening ports busy
+      $Counts{'postscreen'}{'reject'}{"\u$4"}{$3}{$END_KEY}++      if $Collecting{'postscreen'};
    }
 
    elsif ($line =~ /^(?:WHITELIST VETO) \[([^]]+)\](?::\d+)?$/) {