Skip to content

Instantly share code, notes, and snippets.

@pointhi
Last active March 3, 2016 12:00
Show Gist options
  • Save pointhi/96b86a39bfc510d21537 to your computer and use it in GitHub Desktop.
Save pointhi/96b86a39bfc510d21537 to your computer and use it in GitHub Desktop.
fail2ban rule to block bots which are abusing the searx search
# Fail2Ban configuration file
#
# List of search requests using searx
#
# Author: Thomas Pointhuber
#
# revision: 1.0
#
[Definition]
# Option: failregex
# Notes.: Regexp to catch search requests (no static requests and no proxy access)
# Values: TEXT
#
failregex = ^<HOST> -.*"(GET|POST)\s*/(search)?\s
# Option: ignoreregex
# Notes.: regex to ignore. If this regex matches, the line is ignored.
# Values: TEXT
#
ignoreregex =
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment