| [ Web Proxy ] |
| Viewing: https://developers.cloudflare.com/waf/custom-rules/use-cases/block-traffic-from-specific-countries/ | [Back] [Original] |
This example custom rule blocks requests based on country code using the ip.src.country field.
When incoming requests match:
| Field | Operator | Value |
|---|---|---|
| Country | is in | Korea, North, Syria |
If you are using the expression editor:
(ip.src.country in {"KP" "SY"})
Then take action: Block
| Web Proxy Viewer | New URL | Original Page |