mirror of
https://github.com/Cacti/cacti.git
synced 2026-10-23 03:27:02 +09:00
* Add fail2ban support for authentication failures Emit a fixed, machine-parseable AUTH FAILURE line (user, realm, ip, reason) from the universal login-failure path and the 2FA branch, normalise the human AUTH strings, and ship a fail2ban filter, jail example, and README. The IP comes from get_client_addr(); a crafted username cannot forge fields. Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> * test: resolve includes through Cacti path constants Signed-off-by: Thomas Vincent <thomasvincent@gmail.com> --------- Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
19 lines
600 B
Plaintext
19 lines
600 B
Plaintext
# Example Fail2Ban jail for Cacti. Merge this into /etc/fail2ban/jail.local (or
|
|
# drop it in /etc/fail2ban/jail.d/cacti.local) and adjust logpath to your install.
|
|
#
|
|
# Copy misc/fail2ban/cacti.conf to /etc/fail2ban/filter.d/cacti.conf first.
|
|
|
|
[cacti]
|
|
enabled = true
|
|
filter = cacti
|
|
port = http,https
|
|
|
|
# Path to Cacti's log. This is the file behind the "path_cactilog" setting,
|
|
# by default <cacti>/log/cacti.log. Point this at your actual install.
|
|
logpath = /var/www/html/cacti/log/cacti.log
|
|
|
|
# Ban an address after this many failures within findtime.
|
|
maxretry = 5
|
|
findtime = 10m
|
|
bantime = 1h
|