A SysOps Administrator is troubleshooting a connectivity issue where an application on Amazon EC2 instances in Subnet A (CIDR ) cannot connect to a PostgreSQL database on Amazon EC2 instances in Subnet B (CIDR ). Both subnets are associated with different Network Access Control Lists (NACLs). The application security group allows outbound traffic to the database security group on TCP port 5432. The database security group allows inbound traffic from the application security group on TCP port 5432. Which two configuration changes must be made to the subnet NACLs to successfully permit this database traffic? (Select TWO.)
- In the Network ACL associated with Subnet A, add an outbound rule allowing TCP port 5432 to Subnet B's CIDR, and an inbound rule allowing TCP ports from Subnet B's CIDR.Answer
- In the Network ACL associated with Subnet B, add an inbound rule allowing TCP port 5432 from Subnet A's CIDR, and an outbound rule allowing TCP ports to Subnet A's CIDR.Answer
- CIn the Network ACL associated with Subnet B, add an inbound rule allowing TCP port 5432 from Subnet A's CIDR. No outbound rules are required because Network ACLs are stateful.
- DIn the Network ACL associated with Subnet A, add an outbound rule allowing TCP port 5432 to Subnet B's CIDR. No inbound rules are required because Network ACLs automatically track connection states.
- EIn the Network ACL associated with Subnet A, add an inbound rule allowing TCP port 5432 from Subnet B's CIDR, and an outbound rule allowing TCP ports to Subnet B's CIDR.
Answer
The correct configurations are to add rules to the Network ACL of Subnet A allowing outbound traffic on TCP port 5432 and inbound traffic on the ephemeral port range , and to the Network ACL of Subnet B allowing inbound traffic on TCP port 5432 and outbound traffic on the ephemeral port range .
The correct options properly configure the stateless Network ACLs on both sides. In the subnet containing the application, we must allow outbound traffic on TCP port 5432 to the database CIDR and inbound traffic on the ephemeral port range from the database CIDR. In the subnet containing the database, we must allow inbound traffic on TCP port 5432 from the application CIDR and outbound traffic on the ephemeral port range to the application CIDR.
Step-by-Step Solution
Key Concept
Network ACLs are stateless, meaning return traffic must be explicitly allowed. In addition to the destination port, rules must allow the return traffic on ephemeral ports ().
Estimated Time:2m 0s