Snapshot should restrict network access policy
High
Azure
General
snapshot-network-deny
Applies to
Microsoft.Compute/snapshots
What CGPulse checks
A resource passes this rule when networkAccessPolicy must be one of ["AllowPrivate","DenyAll"]. Anything else is reported as a finding with the evaluated property value attached as evidence.
How to fix it
Set network access policy to AllowPrivate or DenyAll to restrict snapshot data access. In Azure Portal: Snapshot > Networking > set Network access policy. See: https://learn.microsoft.com/en-us/azure/virtual-machines/disks-enable-private-links-for-import-export-portal
Careful: Restricting network access may block existing export/copy operations. Ensure private endpoints are configured if using AllowPrivate
CLI
az snapshot update --ids "{id}" --network-access-policy DenyAllTerraform
resource "azurerm_snapshot" "{name}" {
name = "{name}"
resource_group_name = "{rg}"
location = var.location
create_option = "Copy"
source_uri = "<source-disk-id>"
network_access_policy = "DenyAll"
}
Compliance frameworks
Is your environment compliant with this rule?
CGPulse checks it — and 621 others — against your Azure and AWS accounts with read-only access.
Related Azure rules
- Action Group should be enabled
- Activity Log Alert should be enabled
- AKS cluster logs should be sent to Log Analytics
- AKS cluster must enable RBAC
- AKS cluster must enable RBAC
- AKS cluster should be a private cluster
- AKS cluster should disable local accounts
- AKS cluster should enable Azure RBAC for Kubernetes