AWS Certified Solutions Architect Professional SAP-C02 Practice Question
A solutions architect is hardening a private application subnet (Subnet-App) in a production VPC. The subnet contains Amazon Linux EC2 instances that call an external SaaS endpoint over HTTPS through a NAT gateway in a public subnet.
The security group attached to the instances already allows all outbound traffic and no inbound traffic.
A new compliance requirement states that:
Only HTTPS (TCP 443) egress to the internet must be allowed, and
All other ports must be blocked, while
Return traffic for legitimate connections must continue to function.
The architect attaches a custom network ACL (NACL) to Subnet-App with these rules:
Network ACLs are stateless; each return packet is evaluated against the opposite (inbound) rule set. When an instance initiates a TLS session, its source port is a random ephemeral port (>1023) while the destination port is 443.
The outbound rule that allows traffic to destination port 443 is sufficient for the request, but the response from the NAT gateway has source 443 and destination = the instance's ephemeral port. Because rule 100 only allows destination port 443, the return packet is blocked by rule 120. Adding an inbound rule that allows TCP destination ports 1024-65535 from any source lets the response through while continuing to deny every other port range and protocol.
Adding a similar outbound rule is unnecessary (the request already matches rule 100), and replacing the NACL with a security group would not meet the explicit requirement for a subnet-level control. Therefore, allowing inbound TCP 1024-65535 is the minimal and correct fix.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
Why do NACLs require explicit inbound and outbound rules separately?
Open an interactive chat with Bash
What are ephemeral ports and why are they important for TCP connections?
Open an interactive chat with Bash
When should you use NACLs vs. security groups for network control?
Open an interactive chat with Bash
AWS Certified Solutions Architect Professional SAP-C02
Design for New Solutions
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
IT & Cybersecurity Package Join Premium for Full Access