Cloudflare IP's getting ban fail2ban for no-script and 404 URL's


I have installed Fail2ban on my Ubuntu VPS. After I added nginx-noscript and nginx-404 configuration filters to fail2ban, Cloudflare’s following IP address keep blocking.

I already added “real_ip_header CF-Connecting-IP;” to nginx file and looks like visitors IP addresses are properly restored (because my PC IP properly visible in access log). What could be the reason for this?

When I’m checking the who’s details for above IP’s it shows they belongs to Cloudflare.

Are there any solution? Or someone abusing my VPS?

Thank in advance.

Did you also configure set_real_ip_from?

Yes Sandro. I already added set_real_ip_from but following IP’s are not mentioned in Cloudflare site, so they are not added.

Where did you take the IPs from? These are listed at IP Ranges

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