I'm trying to implement this also but not getting anything in csf.deny.
my regex.custom.pm
Code: Select all
# DETECT AND BLOCK wp-login.php POST DOS attacks (requires: CUSTOM2_LOG = "/home/*/access-logs/*" in csf.conf)
if (($globlogs{CUSTOM2_LOG}{$lgfile}) and ($line =~ /(\S+).*] "POST \/wp-login\.php.*" 200/)) {
return ("Failed Wordpress login from",$1,"wordpress","5","80,443","3600");
}
in my csf.conf CUSTOM2_LOG
Code: Select all
CUSTOM2_LOG = "/home/*/access-logs/*"
I restarted csf with csf -r then tried accessing a wordpress site wp-login.php more than 5 times. I still get to the wp-login.php on the website and DO NOT see any entry in /etc/csf/csf.deny file.
I DO see 12 failed attempts in my /home/user/access-logs/domain-ssl_log file
I made sure my IP is not in /etc/csf/csf.allow
Has anyone been able to get this to work? Is it supposed to place entry into csf.deny? It is my understanding it should.