Hallo zusammen,
Zum Glück kann man fail2ban jetzt in 5.0 einfach über apt installieren und wir haben es auf einem Kundensystem jetzt bereits für postfix-sasl, SSL und dovecot am laufen, um Brute-Force-Passwort-Angriffe abzuwehren.
Wir würden jetzt noch gerne das Portal selbst absichern, scheitern aber mit den Filtern.
fail2ban-regex -v '24.03.22 14:11:08.351 MAIN ( PROCESS ) : CPAuth (185.214.223.14:44560) response message: The authentication has failed, please login again.' '^.+CPAuth .\(<ADDR>\:\d+\) response message\: The authentication has failed\, please login again\.$'
spuckt leider folgendes aus:
Lines: 1 lines, 0 ignored, 0 matched, 1 missed
[processed in 0.02 sec]
|- Missed line(s):
| 24.03.22 14:11:08.351 MAIN ( PROCESS ) : CPAuth (185.214.223.14:44560) response message: The authentication has failed, please login again.
`-
Wenn ich ADDR durch HOST ersetze, derselbe Effekt.
Hier das filter-File:
# Fail2Ban filter for unsuccesful Univention Web Console Login attempts
#
#
# log-error=/var/log/univention/management-console-web-server.log
#
[INCLUDES]
# Read common prefixes. If any customizations available -- read them from
# common.local
before = common.conf
[Definition]
failregex = ^.+CPAuth .\(<ADDR>\:\d+\) response message\: The authentication has failed\, please login again\.$
ignoreregex =
# DEV Notes:
#
# Example:
# 24.03.22 14:11:08.351 MAIN ( PROCESS ) : CPAuth (185.214.223.14:44560) response message: The authentication has failed, please login again.
Für Hilfe bin ich mehr als dankbar und würde den Filter gerne auch veröffentlichen - das Problem sollten ja eigentlich alle Univention-Portalbetreiber haben?