D8Defect 7 of 17, in the order they close

The origin is not locked to Cloudflare

The load balancer accepts connections from any source.

Severity
high
Closes in
phase 3, Close the bypasses
Closed by
Address groups
Breaks
1 journey
  • Your VPC
  • Run by Google
  • Firewall and access rules
  • Allowed traffic
  • Where it breaks
Shoppersbrowser · appCloudflareWAF · bot checksrate limitsDDoS protectionGlobal external ALB34.120.95.195:443harbour-wafCloud Armorno source ruleanything passesD8harbour-apiCloud RunAnyonefound its IPin old DNSstraight to the origin, past Cloudflare

Only what D8 touches. Red is the defect and what it lets through; switch to fixed to see the same parts with only D8 closed. Struck IDs are closed.

As foundNo source restriction on the backend service’s security policy.

Wide by design - scroll it sideways.

Notes

open one at a time

1.

What it can cause

Anyone who learns the load balancer's address can skip Cloudflare: its WAF, its bot protection and its rate limits.
  • Anyone who learns the load balancer's address can skip Cloudflare: its WAF, its bot protection and its rate limits.
  • DDoS protection bought at the edge does nothing for traffic sent straight to the origin.
  • The address is easy to find. Old DNS records and certificate scans give it away.
2.

Why it is wrong

Address groups express intent - “the CDN’s edge” - instead of an IP list that goes stale the next time the provider publishes new ranges.

Traffic can bypass the CDN and the WAF by hitting the load balancer directly. Locking it means allowing only Cloudflare’s published ranges, which change, which is exactly what an address group is for.

The idea

Address groups express intent - “the CDN’s edge” - instead of an IP list that goes stale the next time the provider publishes new ranges.

3.

How you would find it

curl -sI --resolve harbour.example:443:34.120.95.195 https://harbour.example/ | head -1
detect
# does the origin answer someone who is not the CDN?curl -sI --resolve harbour.example:443:34.120.95.195 \  https://harbour.example/ | head -1 gcloud compute security-policies describe harbour-waf \  --format="yaml(rules)"
4.

The change that closes it

Cloud Armor policy: default deny, allow only the cloudflare-edge address group.
As found
No source restriction on the backend service’s security policy.
Fixed
Cloud Armor policy: default deny, allow only the cloudflare-edge address group.
fix
gcloud network-security address-groups create cloudflare-edge \  --type=IPV4 --capacity=100 --location=global gcloud compute security-policies rules create 1000 \  --security-policy=harbour-waf --action=allow \  --src-ip-ranges="$(cat cloudflare-ranges.txt)"
5.

When to fix it

Phase 3, Close the bypasses

Phase 3, Close the bypasses, together with D6. Makes the protections that already exist actually apply. Cheaper than adding new ones.

Cannot start until

Nothing. It can start as soon as its phase does.

Unblocks

Nothing waits on it.

6.

Journeys it breaks

A shopper loads a product page