From e0e9b2ef037136f97323081921c906a0dbc87d59 Mon Sep 17 00:00:00 2001 From: Matthew Saunders Brown Date: Fri, 16 Dec 2022 11:22:06 -0800 Subject: [PATCH] harden up f2b ssh --- install.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/install.sh b/install.sh index 9700d18..8bac59a 100644 --- a/install.sh +++ b/install.sh @@ -101,6 +101,9 @@ chmod 644 fail2ban/*.local chmod 644 fail2ban/*/*.conf cp -a fail2ban/* /etc/fail2ban/ echo "destemail = $WEBMASTER" >> /etc/fail2ban/jail.local +echo "bantime = 24h" >> /etc/fail2ban/jail.d/defaults-debian.conf +echo "maxretry = 3" >> /etc/fail2ban/jail.d/defaults-debian.conf +echo "logpath = /var/log/auth.log tail" >> /etc/fail2ban/jail.d/defaults-debian.conf systemctl enable fail2ban systemctl start fail2ban