11.6 Ensure locked immutability policies are used for containers storing business-critical blob data (Automated)
Description
Require locked immutability policies for all containers that store business-critical blob data. This measure protects the data from modifications or deletions, ensuring that critical information remains intact and unaltered, regardless of user actions or access permissions.
Rationale
Implementing a locked immutability policy creates a Write Once, Read Many (WORM) storage model that safeguards critical data from accidental or malicious changes and deletions. Enforcing immutability minimizes data loss and tampering risks, enhancing data security and supporting regulatory requirements for data retention and integrity.
Impact
Enforcing locked immutability policies for blob storage may increase long-term retention costs and require additional administrative effort for policy management.
Once the policy is locked, the container cannot be deleted or edited, and the storage account cannot be deleted until the retention period has elapsed.
Audit Procedure
Audit from Azure Portal
- Go to
Storage accounts. - Click the name of a storage account.
- Under
Data storage, clickContainers. - Click the three dots next to a container.
- Click
Access policy. - Ensure a locked policy is listed under
Immutable blob storage. - Repeat steps 1-6 for each blob container with business-critical blob data.
Audit from Azure CLI
Run the following command to list storage accounts:
az storage account list
Run the following command to determine if a storage account has containers:
az storage container list --account-name <storage-account>
For each container, run the following command to view immutability policies:
az storage container immutability-policy show --account-name <storage-account> --container <blob-container>
Ensure that an immutability policy is listed with "state": "Locked" for each blob container with business-critical blob data.
Expected Result
An immutability policy with "state": "Locked" exists for each blob container storing business-critical data.
Remediation
Remediate from Azure Portal
- Go to
Storage accounts. - Click the name of a storage account.
- Under
Data storage, clickContainers. - Click the three dots next to a container.
- Click
Access policy. - Under
Immutable blob storage, click+ Add policy. - From the
Policy typedrop-down, selectLegal holdorTime-based retention. - If selecting legal hold:
- Provide at least one tag for the policy.
- Under
Allow protected append writes to, selectNoneorBlock and append blobs.
- If selecting time-based retention:
- Under
Set retention period for, enter a number of days for retention. - Check the box next to
Enable version-level immutabilityif appropriate. Versioning must be enabled for this option to be available. - Under
Allow protected append writes to, selectNone,Append blobs, orBlock and append blobs.
- Under
- Click
Save. - Click the three dots next to the policy.
- Click
Lock policy. - Enter
yesto confirm. - Click
OK. - Repeat steps 1-14 for each blob container requiring remediation.
Default Value
By default, no immutability policies are configured on blob containers.
References
- https://learn.microsoft.com/en-us/azure/storage/blobs/immutable-storage-overview
- https://learn.microsoft.com/en-us/cli/azure/storage/container/immutability-policy
Profile
Level 2 | Automated