I've been having a battle confirming fail2ban was actually working, as I couldn't see anything in the pf showing it was there.
After much research and testing, I discovered it was just hiding from view rather well.
The man page, and online references suggest that you can recursively list tables in an anchor with
For my install (14.5p2), this returns nothing.
Specifying it fully,
e.g.
will return an ip address list.
and listing rules works provided I specify the full anchor name.
So there are fail2ban tables present, but how do you list them all using pfctl?
After much research and testing, I discovered it was just hiding from view rather well.
The man page, and online references suggest that you can recursively list tables in an anchor with
pfctl -a "f2b/*" -srFor my install (14.5p2), this returns nothing.
Specifying it fully,
e.g.
pfctl -a f2b/nginx-bad-request -t f2b-nginx-bad-request -T showwill return an ip address list.
and listing rules works provided I specify the full anchor name.
pfctl -a f2b/nginx-bad-request -sr
Code:
block drop quick proto tcp from <f2b-nginx-bad-request> to any port = http
block drop quick proto tcp from <f2b-nginx-bad-request> to any port = https