Google PCNE: Firewall Policy, Cloud Armor and Network Security — Study Guide

Part of the Google Professional Cloud Network Engineer — Study Guide. Practice with verified answers in the Google exam hub, or take timed practice tests on ExamRoll.io.

Overview

Firewall policy, Cloud Armor, and network security on Google Cloud together provide layered controls for segmentation, attack surface reduction, DDoS resilience, and observability. Effective designs combine identity-aware targeting, hierarchical enforcement, least-privilege ingress and egress, and edge protections tied to Google’s global load balancers. Operational success depends on understanding rule evaluation, implied behaviors, logging scope, and where traffic actually originates for different load-balancing modes.

VPC firewall rules and identity-aware targeting

VPC firewall rules are stateful and evaluated per network, direction, and priority.

Design and operations:

Short example, identity-aware ingress allow with logging:

Hierarchical firewall policy, segmentation, and service perimeters

Hierarchical firewall policies enforce organization- or folder-wide rules before any VPC-level rules. Use them to guarantee guardrails (for example, “deny all ingress from the internet to non‑load‑balanced VMs” or “deny RDP/SSH from 0.0.0.0/0”). Lower-level VPC rules cannot override an org/folder deny that already matched.

Segmentation strategy:

Service perimeter interactions:

Trade-offs:

Cloud Armor, WAF, and global edge protections

Cloud Armor binds security policies to external HTTP(S) and external TCP/SSL Proxy load balancers to protect at the edge.

DDoS defense and global load balancer controls:

Operational cautions:

Visibility, inspection, and incident response

Observability:

Inspection and detection:

Incident response practices:

Practical Problem Scenario

Contoso Retail runs a multi-tier web platform on Google Cloud. Frontend traffic is served by a global external HTTP(S) load balancer; application VMs run in multiple regions without external IPs. Egress must hairpin through a third-party NGFW except for Google APIs (BigQuery and Pub/Sub). The security team wants org-wide guardrails, client IP allowlists for a partner pilot, and minimal risk when testing a suspected malicious client.

Approach:

  1. Establish hierarchical guardrails

    • Create an organization-level hierarchical firewall policy that denies all ingress from 0.0.0.0/0 to VM targets lacking the secure tag env=public-entry, and denies administrative ports (SSH, RDP) from the internet.
    • Rationale: Stops unsafe exposure globally; developers cannot self-assign the secure tag due to IAM on tags.
  2. Identity-aware workload targeting

    • Assign distinct service accounts to frontend, application, and database tiers. Reference these service accounts in VPC-level firewall rules to permit only required east-west flows (for example, frontend→app tcp:443, app→db tcp:5432).
    • Rationale: Ties policy to workload identity and resists accidental tag misuse.
  3. Ingress allows for load-balanced backends

    • On the app VMs, create a high-priority ingress allow rule targeted by the app service account, with source ranges equal to Google Front End proxies and Google health check ranges; enable logging.
    • Rationale: For HTTP(S) L7, backends should only accept connections from GFE and health check IPs; client IP allowlists are enforced at the edge.
  4. Cloud Armor edge policy

    • Attach a Cloud Armor policy to the external HTTP(S) load balancer backend service:
      • Add a partner client IP allowlist rule.
      • Enable preconfigured WAF rules for OWASP Top 10.
      • Configure a rate limit keyed by client IP with conservative thresholds.
    • Rationale: Enforces client source restrictions and application-layer protections where the client IP is visible and before traffic reaches the VPC.
  5. Adaptive protection and safe testing

    • Enable Adaptive Protection and create a deny rule for the suspected client IP in preview mode.
    • Rationale: Preview allows behavior verification without impacting real users; logs confirm whether the client is malicious before enforcing.
  6. Egress segmentation with Private Google Access

    • Keep a 0.0.0.0/0 route to the third‑party NGFW. Add custom static routes for Google APIs VIPs to the default internet gateway and enable Private Google Access on subnets. Add an explicit high-priority egress deny-all rule, then specific allows for NGFW next-hop and Google APIs; enable logging.
    • Rationale: Forces general internet egress through the NGFW while allowing BigQuery and Pub/Sub to be reached privately without unnecessary hairpinning.
  7. NAT and external IP controls

    • Use Cloud NAT for instances that need internet egress but have no external IPs. Audit and remove any external IPs on compute instances that must use NAT.
    • Rationale: Prevents NAT bypass and preserves a single egress posture.
  8. Inspection and monitoring

    • Enable Packet Mirroring in each region for the app tier, targeting the app service account, and send mirrored traffic to a regional IDS collector. Enable VPC Flow Logs and firewall rule logging for key rules; export Cloud Armor and VPC logs to a central security project and BigQuery.
    • Rationale: Provides deep visibility for threat hunting and performance baselines without in-path latency.
  9. Incident-ready operations

    • Build alerting on spikes in Cloud Armor denies, firewall deny logs, or changes to hierarchical policies. Document a break-glass SSH procedure using Cloud Shell gcloud compute ssh for controlled emergency access.
    • Rationale: Detects active abuse rapidly and preserves a secure operational path for remediation.
  10. Change safety and rollback


VPC Architecture · All domains · Hybrid Connectivity

Practice these questions → · Timed practice on ExamRoll.io →

Pass the whole exam — not just this question

You found this answer. Get every verified question and explanation in one place, and save hours of prep. Free to start.

Pass your exam →

Browse Google →

Related guides

All-in-one access

One subscription. Every exam.

Every plan unlocks unlimited answer search, practice tests, AI explanations, and the full resource library — in 20+ languages.

Monthly
24.87
Just €0.83/day
Everything included:
  • Unlimited answer search
  • Unlimited practice tests
  • AI-powered explanations
  • Full resource library
  • 20+ languages
  • Weekly content updates
  • Rewards & referrals
  • Priority support
Start free trial

No credit card required*

Best value
12 months
179.87
Just €0.49/daySave 40%
Everything included:
  • Unlimited answer search
  • Unlimited practice tests
  • AI-powered explanations
  • Full resource library
  • 20+ languages
  • Weekly content updates
  • Rewards & referrals
  • Priority support
Start free trial

No credit card required*

✓ Free plan included · ✓ Cancel anytime · ✓ All plans unlock the full product