0
0
GCPcloud~20 mins

Firewall rule components (target, source, protocol) in GCP - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Firewall Rule Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Identify the source in a GCP firewall rule

In a Google Cloud firewall rule, which component specifies where the incoming traffic originates from?

AThe target specifies the source IP addresses or ranges.
BThe source specifies the IP addresses or ranges from which traffic is allowed or denied.
CThe protocol defines the source of the traffic.
DThe destination specifies the source IP addresses.
Attempts:
2 left
💡 Hint

Think about where the traffic comes from before it reaches your resources.

Configuration
intermediate
2:00remaining
Determine the target of a firewall rule

Which part of a GCP firewall rule defines the instances or resources that the rule applies to?

AThe destination IP ranges.
BThe protocol and ports.
CThe source IP ranges.
DThe target tags or service accounts.
Attempts:
2 left
💡 Hint

Think about which virtual machines or resources the rule protects.

service_behavior
advanced
2:00remaining
Effect of protocol specification in firewall rules

What happens if a GCP firewall rule specifies tcp as the protocol but traffic arrives using udp?

AThe traffic is allowed because the rule applies to all protocols by default.
BThe traffic is allowed only if the ports match.
CThe traffic is denied because the protocol does not match the rule's specification.
DThe traffic is logged but neither allowed nor denied.
Attempts:
2 left
💡 Hint

Consider how firewall rules filter traffic by protocol type.

security
advanced
2:00remaining
Security risk of overly broad source ranges

What is a potential security risk of setting the source IP range to 0.0.0.0/0 in a GCP firewall rule?

AIt allows traffic from any IP address, increasing exposure to attacks.
BIt restricts access to only local network traffic.
CIt blocks all incoming traffic.
DIt only allows traffic from private IP addresses.
Attempts:
2 left
💡 Hint

Think about what 0.0.0.0/0 means in networking.

Architecture
expert
3:00remaining
Designing firewall rules for multi-tier applications

You have a multi-tier application with web, app, and database layers in GCP. Which firewall rule setup best isolates the database layer from direct internet access while allowing the app layer to communicate with it?

ASet the database layer's firewall rule to allow traffic only from the app layer's network tags on required ports.
BAllow the web layer to access the database layer directly on all ports.
CAllow all traffic from <code>0.0.0.0/0</code> to the database layer on all ports.
DBlock all traffic to the database layer.
Attempts:
2 left
💡 Hint

Consider the principle of least privilege and network segmentation.