π Azure Key Vault Automatic Key Rotation is not enabled π π’
- Contextual name: π Automatic Key Rotation is not enabled π π’
- ID:
/ce/ca/azure/key-vault/automatic-key-rotation
- Located in: π Azure Key Vault
Flagsβ
- π’ Policy with categories
- π’ Policy with type
- π WIP policy
Our Metadataβ
- Policy Type:
COMPLIANCE_POLICY
- Policy Category:
RELIABILITY
Logicβ
- π§ wip.logic.yaml π’
Descriptionβ
Descriptionβ
Automatic Key Rotation is available in Public Preview. The currently supported applications are Key Vault, Managed Disks, and Storage accounts accessing keys within Key Vault. The number of supported applications will incrementally increased.
Rationaleβ
Once set up, Automatic Private Key Rotation removes the need for manual administration when keys expire at intervals determined by your organization's policy. The recommended key lifetime is 2 years. Your organization should determine its own key expiration policy.
Impactβ
There are an additional costs per operation in running the needed applications.
Auditβ
From Azure Portalβ
- From Azure Portal select the Portal Menu in the top left.
- Select
Key Vaults
.- Select a Key Vault to audit.
- Under
Objects
selectKeys
.- Select a key to audit.
- In the top row select
Rotation policy
.- Ensure
Enable auto rotation
is set toEnabled
.- Repeat steps 3-7 for each Key Vault and Key.
From Azure CLIβ
Run the following command:
az keyvault key rotation-policy show --vaultname <vaultName> --name <keyName>
... [see more](description.md)
Remediationβ
Remediationβ
Note: Azure CLI and Powershell use ISO8601 flags to input timespans. Every timespan input will be in the format P
(Y,M,D). The leading P is required with it denoting period
. The (Y,M,D) are for the duration of Year, Month,and Day respectively. A time frame of 2 years, 2 months, 2 days would be (P2Y2M2D).From Azure Portalβ
- From Azure Portal select the Portal Menu in the top left.
- Select
Key Vaults
.- Select a Key Vault to audit.
- Under
Objects
selectKeys
.- Select a key to audit.
- In the top row select
Rotation policy
.- Select an
Expiry time
.- Set
Enable auto rotation
toEnabled
.- Set an appropriate Rotation option and
Rotation time
.- Optionally set the
Notification time
.- Select
Save
.- Repeat steps 3-11 for each Key Vault and Key.
From Azure CLIβ
Run the following command for each key to update its policy to be auto-rotated:
az keyvault key rotation-policy update -n <keyName> --vault-name <vaultName> --value <path/to/policy.json>
... [see more](remediation.md)
policy.yamlβ
Linked Framework Sectionsβ
Section | Sub Sections | Internal Rules | Policies | Flags |
---|---|---|---|---|
πΌ CIS Azure v2.1.0 β πΌ 8.8 Ensure Automatic Key Rotation is Enabled Within Azure Key Vault for the Supported Services - Level 2 (Manual) | 1 | |||
πΌ CIS Azure v3.0.0 β πΌ 3.3.8 Ensure Automatic Key Rotation is Enabled Within Azure Key Vault for the Supported Services (Automated) | 1 | |||
πΌ Cloudaware Framework β πΌ Expiration Management | 12 |