Skip to content

Instantly share code, notes, and snippets.

Last active Jun 29, 2020
What would you like to do?
set -eu
date=`date +%s`
drop=`iptables -nL |grep f2b-blacklist -A 10000 | grep \^DROP|wc -l`
reject=`iptables -nL|grep f2b-sshd -A 10000|grep REJECT|wc -l`
echo -e "fail2ban.ipv4.drop\t${drop}\t${date}"
echo -e "fail2ban.ipv4.reject\t${reject}\t${date}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment