Blockhosts is an application that provides a way to automatically block abusive IP hosts. Here are the steps required to get blockhosts installed.

Install Blockhosts

  1. Download blockhosts

  2. Read over the install doc that is contained in the download.

  3. Install the Software. You can either choose to install it locally or use the remote rpm command (see install doc)

  4. Read the install doc for configuration of the software. You have to configure it before you run it the first time.

  5.      # python install --force
         # python --dry-run install --force
  6. edit the /etc/hosts.allow file and insert the required elements (see install doc)

  7. Test your install. # /usr/bin/ --verbose

  8. Examine /etc/hosts.allow and you will probably have new information stored between "#---- BlockHosts Additions"

  9. Now edit /etc/blockhosts.cfg and uncomment the line COUNT_THRESHOLD = 7 so that the system will block connections after 7 failed attempts. Note: I normally run this at like 5 or less.

  10. You can also uncomment the line AGE_THRESHOLD to increase how long something is blocked.

  11. For further testing, have someone you know try to ssh into your system more than the level you have set and see if they appear in the blockhost file.
An overview of installing Blockhost