Soru

Zorluk: KolayDeploying Virtual Private Cloud (VPC) Networks, Subnets, and Firewall Rules

A cloud engineer is deploying ingress VPC firewall rules to allow HTTPS (TCP port 443) traffic from any external client specifically to a set of Compute Engine virtual machine instances labeled with the network tag `web-frontend`. Which TWO parameters or configurations must be included in the firewall rule specification to achieve this requirement? (Select TWO)

  1. Set the direction to INGRESS and specify the source IPv4 ranges as 0.0.0.0/0.Cevap
  2. Specify the target tags parameter as `web-frontend` and set the allowed protocol and port to tcp:443.Cevap
  3. C
    Set the rule priority value to 65535 so that it takes precedence over lower numbered rules.
  4. D
    Assign the Project Owner primitive role to the Compute Engine default service account to enable network traffic routing.

Cevap

The correct configurations are setting the rule direction to INGRESS with source ranges 0.0.0.0/0, and specifying the target tags as `web-frontend` with allowed protocol and port tcp:443.
To allow external HTTPS traffic to targeted instances, a VPC firewall rule must specify INGRESS direction with source range 0.0.0.0/0, match target tag `web-frontend`, and allow protocol and port tcp:443. These parameters correctly scope the traffic origin, destination instances, and permitted network port.

Adım Adım Çözüm

1
Define traffic direction and source CIDR range
Setting direction to INGRESS targets incoming traffic, and defining source range 0.0.0.0/0 opens the rule to public internet traffic.
Firewall rules require explicit traffic direction and source IP ranges to determine which incoming requests to evaluate.
2
Specify target network tags and allowed protocols/ports
Configuring target tag `web-frontend` applies the rule exclusively to tagged instances, while `--allow=tcp:443` restricts access to secure HTTPS traffic.
Targeting tags ensures the principle of least privilege scoping across Compute Engine virtual machine instances.

Anahtar Kavram

Configuring GCP VPC Ingress Firewall Rules with Target Network Tags and Port Restrictions
Bu soruyu puanla