More Info:

No AWS RDS database instances should be provisioned inside VPC public subnets in order to protect them from direct exposure to the Internet

Risk Level

High

Address

Security

Compliance Standards

SOC2, HITRUST, GDPR, NISTCSF, PCIDSS, FedRAMP

Triage and Remediation

Remediation

To remediate the misconfiguration of having RDS DB instances provisioned in VPC public subnets in AWS, follow these steps using the AWS Management Console:

  1. Identify RDS Instances in Public Subnets:

    • Go to the AWS Management Console and navigate to the RDS service.
    • Click on “Databases” from the left-hand menu to view all your RDS instances.
    • Identify the RDS instances that are provisioned in VPC public subnets.
  2. Create New Private Subnet:

    • Go to the VPC service in the AWS Management Console.
    • Click on “Subnets” from the left-hand menu.
    • Create a new private subnet within the same VPC where the RDS instances are located. Ensure that this subnet is not associated with a route table that has an internet gateway.
  3. Modify RDS Instance:

    • Go back to the RDS service in the AWS Management Console.
    • Select the RDS instance that you want to move to the private subnet.
    • Click on the “Modify” button to change the subnet group.
    • In the “Network & Security” section, select the newly created private subnet from the “Subnet group” dropdown.
    • Click “Continue” and then “Modify DB Instance” to apply the changes.
  4. Verify the Changes:

    • Wait for the modification process to complete. This may take a few minutes.
    • Once the modification is complete, verify that the RDS instance is now running in the private subnet.
  5. Update Security Group Rules:

    • Update the security group associated with the RDS instance to allow necessary inbound and outbound traffic from other resources within the VPC.

By following these steps, you can remediate the misconfiguration of having RDS DB instances provisioned in VPC public subnets in AWS and ensure that they are running in private subnets for improved security.

Additional Reading: