question about blocking an IP /IPtables, modsec

Discussion in 'Server Operation' started by manarak, Jan 24, 2014.

  1. manarak

    manarak Member

    I have modsecurity2 installed on the server which blocks dangerous HTTP requests, and also use fail2ban to block brute force.

    I have additional security scripts that run under PHP.

    I would like these scripts to be able to put an IP on the block list too, either in mod_security or in IP tables.

    Are there scripts around which can handle these bans? For example, PHP could call a URL on the same server to ban an IP.

    Thank you for help.
  2. manarak

    manarak Member

    ok, I've probably found an answer to my question - make the PHP script that detect the offender to write a log txt file and then configure fail2ban to read that log.

Share This Page