FastNetMon

Wednesday, 24 February 2010

Исправленное правило для fail2ban для защиты Postfix / Debian

Необходимо заменить содержимое файла /etc/fail2ban/filter.d/sasl.conf на следующее (в стандартной версии баг в регулярном выражении):


# Fail2Ban configuration file
#
# Author: Yaroslav Halchenko
#
# $Revision: 510 $
#

[Definition]

# Option: failregex
# Notes.: regex to match the password failures messages in the logfile. The
# host must be matched by a group named "host". The tag "" can
# be used for standard IP/hostname matching and is only an alias for
# (?:::f{4,6}:)?(?P\S+)
# Values: TEXT
#

# Example:
# Feb 25 00:38:07 v1 postfix/smtpd[11100]: warning: unknown[95.79.205.2]: SASL PLAIN authentication failed: authentication failure

# fixed by FastVPS version:
failregex = : warning: [-._\w]+\[\]: SASL (?:LOGIN|PLAIN|(?:CRAM|DIGEST)-MD5) authentication failed: authentication failure$

# Option: ignoreregex
# Notes.: regex to ignore. If this regex matches, the line is ignored.
# Values: TEXT
#
ignoreregex =

No comments :

Post a Comment

Note: only a member of this blog may post a comment.