AWS Certified Solutions Architect – Professional — Question 557

A user is hosting a public website on AWS. The user wants to have the database and the app server on the AWS VPC. The user wants to setup a database that can connect to the Internet for any patch upgrade but cannot receive any request from the internet. How can the user set this up?

Answer options

Correct answer: D

Explanation

To allow resources in a private subnet to initiate outbound connections to the internet for updates while blocking unsolicited inbound connections, you must use a NAT gateway or NAT instance. Placing the database in a private subnet ensures it has no public IP address, preventing direct internet access, while the NAT device safely routes the outbound-only traffic. Simply modifying security group rules in a private subnet without a NAT gateway will not grant internet access, as the subnet lacks a route to the internet.