From 5c008c6a35177bdbb220f77ef53ddc73d5be5f7b Mon Sep 17 00:00:00 2001 From: Filippo Berto Date: Wed, 25 Jan 2023 22:58:54 +0100 Subject: [PATCH] Fail2ban jails update --- baldur/configuration.nix | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/baldur/configuration.nix b/baldur/configuration.nix index 70eff7e..2b682b7 100644 --- a/baldur/configuration.nix +++ b/baldur/configuration.nix @@ -60,6 +60,20 @@ with lib; { fail2ban = { enable = true; bantime-increment.enable = true; + jails = { + "nginx-botsearch" = '' + filter = nginx-botsearch + action = nftables-multiport[name=HTTP, port="http,https"] + logpath = /var/log/nginx/error.log* + backend = auto + ''; + "nginx-http-auth" = '' + filter = nginx-http-auth + action = nftables-multiport[name=HTTP, port="http,https"] + logpath = /var/log/nginx/error.log* + backend = auto + ''; + }; }; nginx = { enable = true;