Debian: Debian Jessie Fail2Ban Implementation

Debian: Debian Jessie Fail2Ban Implementation

A simple guide on how to perform an implementation of Fail2Ban on Debian Jessie for SSH.

Download and Install Fail2Ban

sudo apt-get install -y fail2ban

Create a local config file

cp /etc/fail2ban/jail.conf /etc/fail2ban/jail.local

Open new local config file in nano text editor

nano /etc/fail2ban/jail.local

Configure Default Ignore IP and ban time

ignoreip =
bantime  = 3600 
findtime = 600
maxretry = 3

Enable SSHD jail

enabled = true

Restart the Fail2Ban Service

service fail2ban stop
service fail2ban start
# Or Run the following
service fail2ban restart
# Check service status
service fail2ban status

Check IPtables new rules implemented by Fail2Ban

iptables -L