IPTables: Blocking your favorite Brute Force Attacker

If you happen to detect a bruteforce attack on your self-hosted WP instance, this would be the IPTables syntax to block it:

iptables -A INPUT -s -j DROP

Whenever you miss the attacker, and you’re ready to unblock, you may just type:

iptables -D INPUT -s -j DROP

Hope this helps!