|
@@ -0,0 +1,20 @@
|
|
|
+# Fail2Ban configuration file
|
|
|
+#
|
|
|
+# Regexp to catch known spambots and software alike. Please verify
|
|
|
+# that it is your intent to block IPs which were driven by
|
|
|
+# above mentioned bots.
|
|
|
+
|
|
|
+
|
|
|
+[Definition]
|
|
|
+
|
|
|
+# To test, you can inject this example into log
|
|
|
+# echo `date +'%Y-%m-%d %H:%M:%S'`" INFO 1.2.3.4 --- Access to GET /passwordforgotten.php - action=buildnewpassword, massaction=" >> /mypath/documents/dolibarr.log
|
|
|
+#
|
|
|
+# then
|
|
|
+# fail2ban-client status web-dol-passforgotten
|
|
|
+#
|
|
|
+# To test rule file on a existing log file
|
|
|
+# fail2ban-regex /mypath/documents/dolibarr.log /etc/fail2ban/filter.d/web-dolibarr-rulespassforgotten.conf
|
|
|
+
|
|
|
+failregex = ^ [A-Z\s]+ <HOST>\s+--- Access to .*/passwordforgotten.php - action=buildnewpassword
|
|
|
+ignoreregex =
|