A financial services company runs a three-tier web application in OCI. The security team wants to ensure that traffic to the database tier is restricted to only the application tier's subnet, and that all traffic is logged for auditing. They have already created a VCN with separate subnets for web, application, and database tiers. Which OCI feature should they use to enforce these subnet-level traffic restrictions?
Trap 1: Route Tables
Route tables determine where network traffic is directed, such as to a gateway or a local peering connection. They do not filter traffic based on source or destination IP addresses or ports. While route tables could direct traffic, they cannot enforce the restriction that only the application subnet can access the database subnet, nor do they provide traffic logging.
Trap 2: Network Security Groups (NSGs)
NSGs are virtual firewalls that apply to individual VNICs, not to subnets. They are useful for micro-segmentation within a subnet, but the requirement here is to restrict traffic at the subnet level. Using NSGs would require associating them with each VNIC in the database subnet, which is less efficient and does not enforce the boundary between subnets as directly as security lists do.
Trap 3: Internet Gateway
An Internet Gateway provides a path for traffic to and from the internet for resources in a VCN. It is not a security control and does not restrict subnet-to-subnet traffic. The database subnet likely should not have an Internet Gateway at all. Using it would not meet the requirement of restricting traffic to only the application tier.
- A
Route Tables
Why it fails: Route tables determine where network traffic is directed, such as to a gateway or a local peering connection. They do not filter traffic based on source or destination IP addresses or ports. While route tables could direct traffic, they cannot enforce the restriction that only the application subnet can access the database subnet, nor do they provide traffic logging.
- B
Network Security Groups (NSGs)
Why it fails: NSGs are virtual firewalls that apply to individual VNICs, not to subnets. They are useful for micro-segmentation within a subnet, but the requirement here is to restrict traffic at the subnet level. Using NSGs would require associating them with each VNIC in the database subnet, which is less efficient and does not enforce the boundary between subnets as directly as security lists do.
- C
Security Lists
Security lists act as virtual firewalls for a subnet, controlling ingress and egress traffic at the subnet level. By configuring a security list on the database subnet to allow traffic only from the application subnet's CIDR, the company enforces the required restriction. Security lists also support logging via VCN Flow Logs, satisfying the auditing requirement.
- D
Internet Gateway
Why it fails: An Internet Gateway provides a path for traffic to and from the internet for resources in a VCN. It is not a security control and does not restrict subnet-to-subnet traffic. The database subnet likely should not have an Internet Gateway at all. Using it would not meet the requirement of restricting traffic to only the application tier.