🔑Fail2ban
Also known as fail2ban, fail2ban-client, SSH Ban Tool
A tool that blocks an address when it fails to log in too often.
Think of it like
Think of it like a guard at a door. Get the word wrong too many times, and he sends you away.
Example
A bot tries hundreds of passwords on Jack's server. Fail2ban spots it in the log and blocks its address at the firewall.
Why it matters
It cuts the noise of attacks and blocks slow password guessing on any service with a log.
Definition
Example code
bash
sudo apt install fail2ban
sudo fail2ban-client status sshdCommon mistake
Key takeaways
- 1Reads logs. Counts failed logins.
- 2Bans at the firewall. Blocks the address for a while.
- 3Not a lock. Keys still matter most.