add remove session reason, header skip, etc
This commit is contained in:
parent
568ab16185
commit
77bac3cdad
@ -71,7 +71,7 @@ while (my $line = <>) {
|
||||
dolog($fh, "$sid created session", $opt_l);
|
||||
if ($from =~ m/^(postmaster|hostmaster|noreply.*|no-reply.*|bounce.*)@/i) {
|
||||
$ooo{$sid} = 0;
|
||||
dolog($fh, "$sid from found $from", $opt_l);
|
||||
dolog($fh, "$sid from skip $from", $opt_l);
|
||||
}
|
||||
} elsif ($event eq "tx-mail" && $code ne "ok") {
|
||||
$ooo{$sid} = 0;
|
||||
@ -80,7 +80,7 @@ while (my $line = <>) {
|
||||
$email = $address;
|
||||
} elsif ($event eq "tx-rcpt" && $code ne "ok") {
|
||||
delete $ooo{$sid};
|
||||
dolog($fh, "$sid removed session", $opt_l);
|
||||
dolog($fh, "$sid removed session - rcpt doesn't exist", $opt_l);
|
||||
}
|
||||
}
|
||||
if ($line =~ m/^filter/) {
|
||||
@ -90,15 +90,15 @@ while (my $line = <>) {
|
||||
if (!$data) { $data = ""; }
|
||||
if ($data =~ m/^precedence:\s+(bulk|list|junk)/i) {
|
||||
$ooo{$sid} = 0;
|
||||
dolog($fh, "$sid header found $data", $opt_l);
|
||||
dolog($fh, "$sid header skip $data", $opt_l);
|
||||
}
|
||||
if ($data =~ m/^list-(help|id|owner|post|subscribe|unsubscribe):.*/i) {
|
||||
$ooo{$sid} = 0;
|
||||
dolog($fh, "$sid header found $data", $opt_l);
|
||||
dolog($fh, "$sid header skip $data", $opt_l);
|
||||
}
|
||||
if ($data =~ m/^x-loop:\s+opensmtpd\ admin\ virtual\ vacation/i) {
|
||||
$ooo{$sid} = 0;
|
||||
dolog($fh, "$sid header found $data", $opt_l);
|
||||
dolog($fh, "$sid header skip $data", $opt_l);
|
||||
}
|
||||
print STDOUT "filter-dataline|$sid|$token|$data\n";
|
||||
}
|
||||
@ -127,15 +127,15 @@ while (my $line = <>) {
|
||||
close $fh_email;
|
||||
}
|
||||
delete $ooo{$sid};
|
||||
dolog($fh, "$sid removed session", $opt_l);
|
||||
dolog($fh, "$sid removed session - OOO done", $opt_l);
|
||||
} else {
|
||||
delete $ooo{$sid};
|
||||
dolog($fh, "$sid removed session", $opt_l);
|
||||
dolog($fh, "$sid removed session - OOO cache hit", $opt_l);
|
||||
}
|
||||
|
||||
} elsif ($line =~ m/data-line/ && $data eq '.' && $ooo{$sid} == 0) {
|
||||
delete $ooo{$sid};
|
||||
dolog($fh, "$sid removed session", $opt_l);
|
||||
dolog($fh, "$sid removed session - OOO skip", $opt_l);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user