custom failure message?
Posted: 25 Feb 2011, 22:14
Not a big deal, but...
I have three custom rules in regex.custom.pm for Postfix handling, and the "custom failure message" in each does not seem to be used anywhere. The email notifications and lfd.log simply say "login failures....". Am I missing something?
My rules are as follows for anyone who needs them. They work great - the first one I got from this forum.
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: warning:.*\[(\d+\.\d+\.\d+\.\d+)\]: SASL [A-Z]*? authentication failed/)) {
return ("Failed SASL login from",$1,"mysaslmatch","3","25","600");
}
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: NOQUEUE:.*\[(\d+\.\d+\.\d+\.\d+)\]: 554 5\.7\.1*? Service unavailable; Client host \[(\d+\.\d+\.\d+\.\d+)\] blocked using.*/)) {
return ("RBL blocked from",$1,"myrblmatch","3","25","3600");
}
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: NOQUEUE: reject: RCPT from.*\[(\d+\.\d+\.\d+\.\d+)\]: 554 5\.7\.1.*? Relay access denied.*/)) {
return ("Failed relay attempt from",$1,"myrelaymatch","3","25","1");
}
I have three custom rules in regex.custom.pm for Postfix handling, and the "custom failure message" in each does not seem to be used anywhere. The email notifications and lfd.log simply say "login failures....". Am I missing something?
My rules are as follows for anyone who needs them. They work great - the first one I got from this forum.
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: warning:.*\[(\d+\.\d+\.\d+\.\d+)\]: SASL [A-Z]*? authentication failed/)) {
return ("Failed SASL login from",$1,"mysaslmatch","3","25","600");
}
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: NOQUEUE:.*\[(\d+\.\d+\.\d+\.\d+)\]: 554 5\.7\.1*? Service unavailable; Client host \[(\d+\.\d+\.\d+\.\d+)\] blocked using.*/)) {
return ("RBL blocked from",$1,"myrblmatch","3","25","3600");
}
if (($lgfile eq $config{CUSTOM1_LOG}) and ($line =~ /^\S+\s+\d+\s+\S+ \S+ postfix\/smtpd\[\d+\]: NOQUEUE: reject: RCPT from.*\[(\d+\.\d+\.\d+\.\d+)\]: 554 5\.7\.1.*? Relay access denied.*/)) {
return ("Failed relay attempt from",$1,"myrelaymatch","3","25","1");
}