mitchellkrogza / nginx-ultimate-bad-bot-blocker

Nginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail for Repeat Offenders
Other
4.05k stars 482 forks source link

[BUG] (Please add a way to uninstall completely) #573

Open Sharlyll opened 6 months ago

Sharlyll commented 6 months ago

Describe the bug

I wrote an ansible playbook for this blocker here After installation, I got this "bad_bot variable" emergency error. I could not figure out where the error was because the entries were successful in the vhost. I added

include /etc/nginx/conf.d/botblocker-nginx-settings.conf; include /etc/nginx/conf.d/globalblacklist.conf; to nginx.conf but no luck.

Suggestion: It would be great is there was a way to completely uninstall this git for proper reinstall.

To Reproduce

Follow the installation guide as detailed on this git.

Expected behavior

clean installation without errors

Server (please complete the following information):

Operating System:

Additional information

Please add a way to completely uninstall.

mdestafadilah commented 6 months ago

i never finding best action to uninstall this, so i'm deleteing my os's then reconfigure again. huft.

stevekanger commented 5 months ago

Did we ever find a way to uninstall this? I installed it and it doesn't work. Went through the install step by step several times but still doesn't work. None of the tests work and if I add my own ip to the blocked list it doesn't do anything. All traffic still gets through. So I just want it off of my system but now I come to find out there is no mechanism to get this thing off my system. This has been a terrible experience.

HKPhysicist commented 2 months ago

You have to configure fail2ban as well.

It works very well in my case, Ubuntu 20.04 and then Ubuntu 22.04.

This software do bar many unwanted spiders which slowing down my web sites very much!

nginxoffender

The only drawback is: It may still ban Microsoft Clarity spiders.

Sharlyll commented 2 months ago

Please tell how to configure fail2ban to work with it.

On Fri 13. Sep 2024 at 20.20, HKPhysicist @.***> wrote:

You have to configure fail2ban as well.

It works very well in my case, Ubuntu 20.04 and then Ubuntu 22.04.

This software do bar many unwanted spiders which slowing down my web sites very much!

— Reply to this email directly, view it on GitHub https://github.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker/issues/573#issuecomment-2349533468, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFOK5R5L5V2FV3KJ5EUQOELZWMNGLAVCNFSM6AAAAABHT4D7AWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGNBZGUZTGNBWHA . You are receiving this because you authored the thread.Message ID: <mitchellkrogza/nginx-ultimate-bad-bot-blocker/issues/573/2349533468@ github.com>

HKPhysicist commented 2 months ago

10.3) Integration with fail2ban

enable this jail action of fai2ban in file /etc/fail2ban/jail.local

[nginx-limit-req] enabled = true port = http,https logpath = %(nginx_error_log)s /var/www/yoursite1/log/error.log /var/www/yoursite2/log/error.log

Then, run: sudo systemctl reload fail2ban.service

10.4) Additional Repeat Offender Jail Action

cd /usr/local/src/ sudo git clone https://github.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker.git cd nginx*/_fail2ban_addon/ sudo mv ./filter.d/nginxrepeatoffender.conf /etc/fail2ban/filter.d/ sudo mv ./action.d/nginxrepeatoffender.conf /etc/fail2ban/action.d/

Then, add this jail action in file /etc/fail2ban/jail.local:

[nginxrepeatoffender] enabled = true logpath = %(nginx_access_log)s /var/www/yoursite1/log/access.log /var/www/yoursite2/log/access.log filter = nginxrepeatoffender banaction = nginxrepeatoffender bantime = 86400 ; 1 day findtime = 604800 ; 1 week maxretry = 20

Then, run: sudo systemctl reload fail2ban.service

GitHub
GitHub - mitchellkrogza/nginx-ultimate-bad-bot-blocker: Nginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail for Repeat Offenders
Nginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail f...
mdestafadilah commented 2 months ago

You have to configure fail2ban as well.

It works very well in my case, Ubuntu 20.04 and then Ubuntu 22.04.

This software do bar many unwanted spiders which slowing down my web sites very much!

nginxoffender

The only drawback is: It may still ban Microsoft Clarity spiders

whats is your panel using?

HKPhysicist commented 2 months ago

whats is your panel using?

I use ISPConfig3 to create and manage webs. I use webmin to view other server parameters such as CSF firewall.

Nginx bad bot Blocker does not rely on them. Tune it to match your own server OS. So Nginx bad bot blocker installer is not complete. You must tune it afterward.

mdestafadilah commented 2 months ago

whats is your panel using?

I use ISPConfig3 to create and manage webs. I use webmin to view other server parameters such as CSF firewall.

Nginx bad bot Blocker does not rely on them. Tune it to match your own server OS. So Nginx bad bot blocker installer is not complete. You must tune it afterward.

okay thanks for your confirmation, may can you give me some tutorials?

HKPhysicist commented 2 months ago

whats is your panel using?

I use ISPConfig3 to create and manage webs. I use webmin to view other server parameters such as CSF firewall. Nginx bad bot Blocker does not rely on them. Tune it to match your own server OS. So Nginx bad bot blocker installer is not complete. You must tune it afterward.

okay thanks for your confirmation, may can you give me some tutorials?

Summarise the readme installation note for your OS: https://github.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker/blob/master/README.md

Then, follow my notes above. I only take notes for myself.

GitHub
nginx-ultimate-bad-bot-blocker/README.md at master · mitchellkrogza/nginx-ultimate-bad-bot-blocker
Nginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail f...
mdestafadilah commented 1 month ago

whats is your panel using?

I use ISPConfig3 to create and manage webs. I use webmin to view other server parameters such as CSF firewall. Nginx bad bot Blocker does not rely on them. Tune it to match your own server OS. So Nginx bad bot blocker installer is not complete. You must tune it afterward.

okay thanks for your confirmation, may can you give me some tutorials?

Summarise the readme installation note for your OS: https://github.com/mitchellkrogza/nginx-ultimate-bad-bot-blocker/blob/master/README.md

Then, follow my notes above. I only take notes for myself.

GitHubnginx-ultimate-bad-bot-blocker/README.md at master · mitchellkrogza/nginx-ultimate-bad-bot-blockerNginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail f...

not for beginer. i'm difficult to follow instalation documentation, i' mean it's for clean instalation, cz i'm using aaPanel

GitHub
nginx-ultimate-bad-bot-blocker/README.md at master · mitchellkrogza/nginx-ultimate-bad-bot-blocker
Nginx Block Bad Bots, Spam Referrer Blocker, Vulnerability Scanners, User-Agents, Malware, Adware, Ransomware, Malicious Sites, with anti-DDOS, Wordpress Theme Detector Blocking and Fail2Ban Jail f...
HKPhysicist commented 1 month ago

It is not for you, then. You must have root access to your own OS.

mdestafadilah commented 1 month ago

It is not for you, then. You must have root access to your own OS.

I know, i have root access. but, may can you do with aaPanel.

HKPhysicist commented 1 month ago

It is not for you, then. You must have root access to your own OS.

I know, i have root access. but, may can you do with aaPanel.

Please try to donate to the original author if you want some extra features. https://github.com/mitchellkrogza

GitHub
mitchellkrogza - Overview
Linux Specialist focus on network security, intrusion detection, SSL and generally a safer internet. Proxmox, Wordpress, Woocommerce, Server Setup Expert 4 Hire - mitchellkrogza
itoffshore commented 1 month ago

A "lowend" OpenVZ VPS server with root access costs around $15-$20 / year (you do not need a KVM VPS to run a web panel)

Running your own server means you will learn more & get better performance