mrfroasty schrieb:
I finally got my hands on the subject, but I am not in a position to
play with regular expression.

REGEX:
#failregex = USER \S+: no such user found from \S* ?\[<HOST>\] to \S+\s*$

This captures only this kinds of logs on auth.log:
#Aug  6 22:25:59 fileserver proftpd[18234]: fileserver.mzalendo.net
(202.102.135.54[202.102.135.54]) - USER !...@#$%^&*: no such user found
from 202.102.135.54 [202.102.135.54] to 192.168.1.34:21

It misses this:
#Aug  7 20:47:18 fileserver proftpd[23323]: fileserver.mzalendo.net
(gendesktop.mzalendo.net[192.168.1.33]) - USER mysql (Login failed):
Incorrect password.

Anyone with a smarter regex and interested to share it with me?
I will see if I can learn regex and try to manipulate this expressions.
Not really. IMO all these brute-force-polling-logwatcher are pretty bad design. If proftpd uses pam you should search for pam_shield, it can recognize failed logins and insert the appropriate rules into your firewall.

cheers
 Paul


Thanks

GR
mrfroasty



Reply via email to