I want to use fail2ban to block specific ip addresses with:
sudo fail2ban-client set apache banip 111.111.111.111
I get:
NOK: ('apache',)
Sorry but the jail 'apache' does not exist
I'm also confused because the jail.conf
file does not contain an entry for [apache]
. I tried adding it manually and restarting fail2ban. That didn't help.
All the tutorials I've found talk about the [apache]
jail but it's absent on my stock version of jail.conf
.
I'm running Debian 10 (buster).
There may not be a single
[apache]
jail, but it might be split to multiple jails for different purposes. As the[apache]
jail is typically handling the authentication failures, you could be looking for[apache-auth]
.Additionally, there might be
[apache-noscript]
to detect clients trying to find exploitable scripts,[apache-overflows]
for suspiciously long requests, and[apache-badbots]
for known user-agents of spammer robots etc. The name for[apache-fakegooglebot]
is self-explanatory.