mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-02-25 08:43:36 +00:00
wordpress: Add fail2ban filter and jail
- I tested the changes with the VirtualBox image with a bridged network adapter. After ten failed authentication attempts, my IP got blocked as expected. - This setup uses apache's logs to filter the attempts. A wordpress [plugin](https://wordpress.org/plugins/wp-fail2ban/) exists for redirecting the logs to syslog, but that needs to be packaged. Signed-off-by: nbenedek <contact@nbenedek.me> [sunil: Drop logpath as logs are expected to go to journald] [sunil: Update regex to match only failures and not successful logins] Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: Sunil Mohan Adapa <sunil@medhas.org>
This commit is contained in:
parent
9a0be419f5
commit
663cd4ac22
@ -0,0 +1,2 @@
|
||||
[Definition]
|
||||
failregex = .* <HOST> .* "POST /wordpress/wp-login.php HTTP/\S+" 200
|
||||
@ -0,0 +1,3 @@
|
||||
[wordpress-auth-freedombox]
|
||||
enabled = true
|
||||
filter = wordpress-auth-freedombox
|
||||
Loading…
x
Reference in New Issue
Block a user