Full package name: app-admin/blockhosts
Ok, this isn't really new; I decided to extract the ebuild from the HowTo.
So here is the blockhosts ebuild.
Some information about the package:
Blockhosts is a python script which records how many times a system service has been probed, using configurable pattern matching to recognize failed accesses (such as for "sshd" or "proftpd" or any service), and when a particular IP address exceeds a certain number of failed attempts that IP address is blocked by using one of the following techniques, e.g.: