Ban abusive IP(s)

Hello,
Is there any script that we can run in our server so that those ips that surpass certain thresh hold, receive a challenge?
Best Regards.

Hello,
I’m not really looking to use the rate limit offered by Cloudflare as the billing can become quite expensive…

You’re free to use any software or rate limiting products you’d like to on your origin. One that comes to mind is fail2ban but going in depth on how to set up that or other solutions is outside the scope of this forum. The only relevant piece of information you need is that the HTTP header containing the actual IP address of the visitor is Cf-Connecting-Ip.

1 Like

Following on from @Judge reply, if you were happy to use fail2ban there’s plenty of examples online of how to integrate it with Cloudflare via the API such that abusive IPs seen in local logs can be banned at Cloudflare automatically.

eg: first hit on Google I found: https://guides.wp-bullet.com/integrate-fail2ban-Cloudflare-api-v4-guide/

1 Like

This topic was automatically closed after 30 days. New replies are no longer allowed.