In this tutorial, we'll develop a script that will get all the IP addresses blocked by
fail2ban
on the ssh
chain and then add them to an ipset
that will be automatically
blocked by iptables.
Talk about power traffic management!
One of the most frustrating parts about running a web hosting company is the exposure to spam and bad bot traffic. At my old hosting company, I often had to scrub through IP logs to determine what traffic was legitimate and what traffic should have been blocked outright. In fact, more web hosting companies could do this but they choose not to because more traffic = more money.