More Info:

Ensure that your Microsoft Azure network security groups (NSGs) allow inbound/ingress access on TCP port 5432 to trusted IP addresses only, in order to implement the principle of least privilege and greatly reduce the attack surface. TCP port 5432 is used by the PostgreSQL Database Server, an object-relational database management system (RDBMS) server developed by PostgreSQL Global Development Group.

Risk Level

High

Address

Security

Compliance Standards

SOC2, GDPR, ISO27001, HIPAA, CISAZURE, CBP, NISTCSF, PCIDSS, FedRAMP

Triage and Remediation

Remediation

Sure, here are the step-by-step instructions to remediate the unrestricted PostgreSQL database access misconfiguration in Azure using the Azure console:

  1. Login to the Azure portal (https://portal.azure.com/).

  2. Navigate to the “Azure Database for PostgreSQL servers” service.

  3. Select the PostgreSQL server that you want to remediate.

  4. Click on the “Firewalls and virtual networks” option from the left-hand menu.

  5. Under the “Firewall Rules” section, click on the “Add client IP” button to add a new firewall rule.

  6. You can also specify a specific IP address range or subnet that is allowed to access the PostgreSQL database. To do this, click on the “Add existing virtual network” option and select the virtual network and subnet that you want to allow access from.

  7. Once you have added the required firewall rules, click on the “Save” button to apply the changes.

  8. Finally, make sure to review the other security-related settings for your PostgreSQL server, such as SSL/TLS encryption, access policies, and authentication methods, to ensure that your database is properly secured.

By following these steps, you can remediate the unrestricted PostgreSQL database access misconfiguration in Azure using the Azure console.