| name | cis-azure-database-3.2 |
| description | Ensure that Cosmos DB uses Private Endpoints where possible |
| category | cis-azure-database |
| version | 2.0.0 |
| author | cyberstrike-official |
| tags | ["cis","azure","cosmos-db","nosql"] |
| cis_id | 3.2 |
| cis_benchmark | CIS Microsoft Azure Database Services Benchmark v2.0.0 |
| tech_stack | ["azure"] |
| cwe_ids | [] |
| chains_with | [] |
| prerequisites | [] |
| severity_boost | {} |
3.2 Ensure that Cosmos DB uses Private Endpoints where possible (Automated)
Profile Applicability
Description
Private endpoints limit network traffic to approved sources.
Rationale
For sensitive data, private endpoints allow granular control of which services can communicate with Cosmos DB and ensure that this network traffic is private. This can be set this up on a case by case basis for each service to be connected.
Impact
Only whitelisted services will have access to communicate with the Cosmos DB.
Audit Procedure
Audit From Azure Portal
- Open the portal menu.
- Select the Azure Cosmos DB blade.
- Select the Azure Cosmos DB account.
- Select Networking.
- Ensure
Public network access is set to Selected networks.
- Ensure the listed networks are set appropriately.
- Select Private access.
- Ensure a private endpoint exists and
Connection state is Approved.
Audit From Azure Policy
- Policy ID:
58440f8a-10c5-4151-bdce-dfbaad4a20b7 - Name: 'CosmosDB accounts should use private link'
Expected Result
A private endpoint should exist with Connection state set to Approved, and Public network access should be set to Selected networks.
Remediation
Remediate From Azure Portal
- Open the portal menu.
- Select the Azure Cosmos DB blade.
- Select the Azure Cosmos DB account.
- Select Networking.
- Select Private access.
- Click
+ Private Endpoint.
- Provide a Name.
- Click Next.
- From the Resource type drop down, select
Microsoft.AzureCosmosDB/databaseAccounts.
- From the Resource drop down, select the Cosmos DB account.
- Click Next.
- Provide appropriate Virtual Network details.
- Click Next.
- Provide appropriate DNS details.
- Click Next.