:: Steve.org.uk
[ Home | About Steve | Free Software | Images ]



Note

This code is unmaintained.



mod_ifier
Free Software

Apache2 request filtering and rejection

mod_ifier is an Apache2 module which allows you to filter each incoming HTTP request to your webserver - allowing you to drop Referer-spam, exploit attempts, and more.

Using this module you can define a collection of rules which will be processed for each incoming request. If a rule matches then you can respond in several different ways:

  • Return a specific HTTP status code.
  • Redirect the visitor to a different URL
  • Execute a local program.

The available rule-types allow you to perform matching on many aspects of the incoming request - and new rules will be added if you suggest them to the author.

For example you may:

  • Deny requests based upon arbitary incoming HTTP headers.
    • e.g. Drop Referer-spam
    • e.g. Drop badly behaved user-agents.
  • Deny requests based upon the request method
    • GET, POST, TRACE, SEARCH, OPTIONS, PROPFIND & etc.
  • Deny requests based upon submitted CGI parameters.
    • Both GET & POST requests are supported
  • Deny requests based upon the file/path requested.
  • Blacklist/Whitelist IP addresses.
  • Log which clients were dropped.
  • Execute commands when clients are dropped.
    • (To add them to a firewall, for example.)
top
Download

You may download the source code for this module from the following URL:

top
License

The module is licensed under the terms of the GNU General Public License, with an exception allowing linking with both Apache & libssl/mod_ssl.

top
Feedback

If you are interested in following the development of the module you may be interested in the mod_ifier mercurial repository. Please feel free to get in touch if you have any suggestions or comments.

top