Lesson 10 of 14 · 14m
The PaaS Endpoint Is Public Until You Change It
0.0.0.0/0 firewall rules, enabled-from-all-networks defaults, and the private-endpoint DNS debt you actually pay.
Authentication is the only wall
Most cloud service endpoints are public DNS names answering on the internet. Azure storage accounts ship Enabled from all networks. AKS exposes its API server publicly by default. Cosmos DB, PostgreSQL flexible servers, Key Vault — each carries its own publicNetworkAccess-style flag, and the managed-service framing invites the assumption that the provider built a wall. The provider built the service. The path to it is yours.
GCP's equivalent is the VPC firewall rule: gcloud compute firewall-rules list showing an ingress allow 0.0.0.0/0 → tcp:22 or tcp:3389 applies to every VM with an external IP in that network, regardless of whose VM it is. Firewall rules belong to the network, not the instance — one sloppy rule is every box. SSH and RDP brute force are background radiation on the internet; an open admin port is just waiting on a weak password, a reused credential, or an unpatched service.
The modern replacement isn't a tighter CIDR — it's removing the open port entirely. GCP IAP TCP forwarding (gcloud compute start-iap-tunnel, gated by roles/iap.tunnelResourceAccessor) and Azure Bastion put admin access behind your IAM and MFA instead of behind the port. Pair with constraints/compute.vmExternalIpAccess to keep VMs off public IPs unless explicitly allow-listed — the combination turns "is SSH open" into a question that can't be answered wrong.
Two GCP details decide whether IAP actually works. IAP TCP forwarding needs a firewall rule allowing 35.235.240.0/20 — Google's IAP ingress range — to the target port on the VM; "IAP is configured but tunnels fail" is that missing rule. And firewall evaluation has an implied-deny shape: ingress defaults deny, egress defaults allow — so outbound filtering is its own job (0.0.0.0/0 egress is open until you write the deny), which matters the day exfiltration is the threat and not just entry. Azure Bastion is the counterpart — browser or az network bastion ssh RDP/SSH with no inbound port on the VM at all; it bills per hour, and what it buys is that 22/3389 can be denied outright.
The forgotten perimeter is the breached one
Midnight Blizzard, disclosed by Microsoft January 19, 2024: SVR operators password-sprayed a legacy, non-production test tenant account with no MFA, then registered an OAuth application for mailbox access and read Microsoft corporate email for weeks. Nothing in hardened production broke. The estate's forgotten corner was the door. Every "temporary" public endpoint, legacy tenant, and default-enabled flag is inside your attack surface whether it's inside your threat model or not.
Private endpoints: the fix and its price
Azure Private Link / private endpoints and GCP Private Service Connect — plus Private Google Access for API reach — put the service on an IP inside your network. State the real costs, because people discover them in production: private endpoints bill per hour plus data processed; DNS becomes a project — privatelink.blob.core.windows.net zones, conditional forwarders, split-horizon configs — and when it's wrong the failure mode is a service that resolves to nothing; local development breaks until office IPs or VPN joins the allowlist. You pay for the perimeter in ops burden, and it is still worth paying for anything holding data.
Land it
Deny-by-default posture: no 0.0.0.0/0 on admin ports anywhere; admin access through IAP/Bastion; external IPs denied by org policy except where justified. Azure side: deny publicNetworkAccess: Enabled via Azure Policy and default data-bearing PaaS to private endpoints. Then audit the second-order holes — the AzureServices trusted-services bypass, NSGs on the wrong subnet, firewall rules added "temporarily" a year ago. The open door is usually the flag nobody removed, not the feature nobody enabled.
Was this lesson helpful?
Keep reading
Related articles from the SudoSecurity blog.
AWS Emulator Puts AWS on Your Laptop. Keep Your IAM Tests Off It.
AWS released AWS Emulator on November 11, a free local server that answers AWS API calls on 127.0.0.1 with per-run keys and fresh certificates.
Big Tech Plans to Work with the Public Sector for Cybersecurity
Both Microsoft, Inc. and Alphabet, Inc. will put a combined $30 billion dollars into cybersecurity over the next five years and work with the public sector on several initiatives to help improve cybersecurity.
Zero Trust Everything: The Complete Guide to Self-Hosting Teleport for Secure Infrastructure Access
SudoSecurity runs Teleport internally for everything — admin panel access, secure database connections, Kubernetes, and zero-trust philosophy across our entire team. This is the complete technical guide to installing, configuring, and running your own self-hosted Teleport cluster from scratch.
What is SSRF? Server-Side Request Forgery and the Attack That Breached Capital One
SSRF tricks your server into making requests to internal systems — cloud metadata services, internal APIs, AWS credentials endpoints. It turned a WAF misconfiguration into 100 million stolen Capital One records