ODPOVĚĎ
Provedeme instalaci fail2ban a povolíme službu
apt install fail2ban && systemctl enable fail2banPřidáme jail pro službu sshd
vim /etc/fail2ban/jail.local
[DEFAULT]
# Ban hosts for one hour:
bantime = 3600
# Override /etc/fail2ban/jail.d/00-firewalld.conf:
banaction = iptables-multiport
[sshd]
enabled = true
Restart fail2ban
systemctl restart fail2banDodatek
Poslední logy
tail /var/log/fail2ban.logStav sshd jailu
fail2ban-client status sshdOdebrat zablokovanou IP adresu 10.11.10.10 z sshd jailu
fail2ban-client set sshd unbanip 10.11.10.10
Komentáře (0)
Přidat komentář