Firewall rules block access to individual countries

I have created a firewall rule that blocks access from the country in the list.

Then I tried to fake the country IP that was blocked in the list.

Try to access the website still can’t access.

I don’t know if it’s because I misconfigured the rules or because the country blocking firewall isn’t working.

Please help me thanks.

Using AND means that the request would have to originate from all those countries at the same time to match. Either use OR instead of AND or use a single IS IN rather than all those EQUALS.


Thank you very much

I have successfully blocked the access country is Germany.

Like I still get bots from Germany accessing my website.

When blocking access to a country, is it correct that bots from that country are still not blocked?

Not unless you explicitly configure it. I usually use a rule like this to block certain countries, but allow Known Bots. Known Bots is a Cloudflare managed list of known, verified and well behaved bots.

( in {"AF" "AX" "AL"} and not

So with the above algorithm.
I block some territories and block bots from that territory. Except the list of known bots from CL is not blocked.
Is it right?

Using the firewall rule posted by @michael, for example, all requests from countries AF/AL/AX would be matched with exception of verified bots. Verified bots, even if they’re requesting from those countries, wouldn’t match.

I followed. Currently waiting for the results to return.
My firewall 1 only blocks the country.
My Firewall 3 blocks the country and allows known bots.

You are aware that rule 1 is disabled?

Thank you michael.
Can you just help me.
I have 2 firewall rules.
Rule 1: ( eq “DE”) or ( eq “CN”) or ( eq “IN”)
Rule 2: ( in {“AF” “BY” “CN” “CO” “DE” “IN” “IL” “MD” “NL” “AN” “RU” “TW” “TR” " “UA” “AE” “AU”} and not
What if I turn on of 2 rules?
Right now I’m seeing both rules running.

You only need rule #2, if you want to match requests from those countries with exception of verified bots. If you were to have both rules active, only #1 would be applied for the countries CN/DE/IN, and rule #2 would never apply for those same countries.


thank you very much.
I will apply rule number 2.

I applied firewall rule 2.
Like why am I still being notified of these bots access.
What are these bots? Why do they visit my website?
I blocked IP and Firewall rule 2.
As the bot above still access?
Where is the error.
Please guide me thanks.

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.