apt install -y sudo wget
sudo -i
wget "https://raw.githubusercontent.com/Onair-santa/Fail2ban-1-click/main/fail2ban.sh" -O fail2ban.sh && chmod +x fail2ban.sh && bash fail2ban.sh
- Remove firewalld, ufw or iptables
- Install nftables
- Open ports 22, 443, 80
- Install Fail2ban
- install config jail.local
- Starting fail2ban
-
jail enabled: sshd(port 22), recidive(allport)
-
Status command:
fail2ban-client status fail2ban-client status sshd fail2ban-client status recidive