• Plesk Uservoice will be deprecated by October. Moving forward, all product feature requests and improvement suggestions will be managed through our new platform Plesk Productboard.
    To continue sharing your ideas and feedback, please visit features.plesk.com

Question Fail2Ban custom jail

kojot

Regular Pleskian
I have one problematic site with some guestbook page which is spamed.
We added google recaptcha, and on that way we solved that problem,

But now in logs I see a lot of logs like
mod_fcgid: stderr: PHP Notice: Undefined index: Anfangsposition in /var/www/vhosts/kringers.at/httpdocs/guestbox0.93/gbshow.php on line 24
mod_fcgid: stderr: PHP Notice: Undefined index: Anfangsposition in /var/www/vhosts/kringers.at/httpdocs/guestbox0.93/gbshow.php on line 24, referer: http://www.kringers.at/guestbox0.93/guestbox.php

I think that maybe bots trying to pass that recaptcha, but I don't know how to ban it with Fail2ban.

I added firstly filter like
[Definition]
failregex = ^<HOST> .* "GET /guestbox0.93/guestbox.php?* HTTP/.*" 200
ignoreregex =

And after that I tried to create jail with that filter, but got errors. Obviously I did not created filter properly.
Code:
Error: f2bmng failed: ERROR NOK: ('kringers',)
ERROR NOK: ('Unable to compile regular expression \'^(?:::f{4,6}:)?(?P<host>[\\w\\-.^_]*\\w) .* "GET /guestbox0.93/guestbox.php?* HTTP/.*" 200\'',)
ERROR:f2bmng:Command '['/usr/bin/fail2ban-client', 'reload', 'kringers']' returned non-zero exit status 255
ERROR:f2bmng:Failed to reload following jails due to errors in configuration: kringers

Can you help me how to solve those attacks?
 

Attachments

  • logs.zip
    1.1 MB · Views: 0
Back
Top