Blocking access to my server by IP except from Cloudflare?

New to Cloudflare so sorry if I’m asking a dumb question, I did search quite a bit but couldn’t find anything or exactly what to search for.

I’m running a WordPress site on Amazon AWS EC2. I’d like to setup the firewall there to block access from anywhere except for Cloudflare (and my home, office, etc). It seems this isn’t how you do things as I don’t see anywhere that lists the block of IPs that CF would be accessing my site from (guessing it’s just too big/many). Is that correct or is there a block of IPs I’d allow - or is there a better way to do this?

I’m using the free account as this is a not-for-profit gaming site and I can’t afford the paid plans (at least not yet). So what are my options?

Thanks much!

~Exigeous

Here’s a listing that hasn’t changed in…years, I suppose:

Well ■■■■, seems my Google-Fu is weak tonight!

So then to ask is that an acceptable way to lock things down? I’ve seen some other things with the Access tool in the Dashboard but it seemed I don’t get access to all that with a free account.

Thanks so much for the VERY quick reply!

You need to seup CSF kind of firewall at your origin server.

What do you mean? If you don’t want your infrastructure being accessible from the Internet you need to lock it down. With Hardware, software like iptables, Windows Firewall, or even with Amazon’s ACL.

Even then you need to lock down your servers to the networks mentioned above. Otherwise it would be possible to bypass restrictions by using your server’s IP to connect.

1 Like

Well I meant is that the best practice way to lock things down vs. some of the other tools built in - obviously I realize I need to look down access to just CF as that’s the entire reason I started the thread. As there are multiple ways something like this could be done, as I read some of CF’s guides on creating a VPN, etc. I’m checking to see.

Seems it is as I locked it with AWS ACLs last night and all it working perfectly so big thanks to sdayman for giving me exactly what I needed.

~X

1 Like

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