CSF to block dovecot login failures?
Hi,
I'm getting hundreds of errors from people presumably trying to brute force attack my server. There are 3-4 tries for random common usernames for dovecot, presumably picked from a list of common usernames, and I'd like to block the attacker. The only problem is that I can't see an IP address in the log. Is this something that can be done with CSF, or do I need to enable CPHulk too for this kind of issue?
dovecot: auth: Error: Cpanel::MailAuth: Failed to getpwnam for user abc123
dovecot: auth: Error: Cpanel::MailAuth: Failed to getpwnam for user access
Thanks!
-
Hello, Have you enable " Login Failure Detection " in your CSF firewall setting ? I will suggest you to enable it and configure it as per your setting 0 -
Hello :) You can have CSF/LFD detect and block the brute force attempt automatically. Or, if you prefer to manually block the IP address, you should be able to find the IP address in /var/log/maillog directly before/after the entries you posted. Thank you. 0 -
LFD should be parsing dovecot failures already. If you are experienced with regex (regular expressions) you can use a custom file (regex.custom.pm) with CSF to create your own ways to block based on log entries. This requires setting the custom log paths in csf.conf in addition to the needed regex knowledge. 0
Please sign in to leave a comment.
Comments
3 comments