nominatim: ban IPs that repeatedly send bad requests
authorSarah Hoffmann <lonvia@denofr.de>
Fri, 24 Mar 2017 16:33:04 +0000 (17:33 +0100)
committerSarah Hoffmann <lonvia@denofr.de>
Fri, 24 Mar 2017 16:33:04 +0000 (17:33 +0100)
cookbooks/nominatim/recipes/default.rb

index 5dedfd4e7574b38fa67d94706a4f456ea65b3e25..22947a06d94514e3ad2d7745e9b19abffc1799a5 100644 (file)
@@ -353,7 +353,7 @@ end
 include_recipe "fail2ban"
 
 fail2ban_filter "nominatim" do
 include_recipe "fail2ban"
 
 fail2ban_filter "nominatim" do
-  failregex '^<HOST> - - \[\] "[^"]+" 429 '
+  failregex '^<HOST> - - \[\] "[^"]+" (400|429) '
 end
 
 fail2ban_jail "nominatim" do
 end
 
 fail2ban_jail "nominatim" do