Check ID:
Provider: Azure
Service:
Severity: HIGH
Categories:
Resource type:
keyvault_key_expiration_set_in_non_rbacProvider: Azure
Service:
keyvaultSeverity: HIGH
Categories:
encryptionResource type:
microsoft.keyvault/vaults/keysWhat this check verifies
Each enabled key in an Azure Key Vault using access policies (non-RBAC) is assessed to confirm it has anexpiration (exp) attribute defined.
Risk
Non-expiring keys enable indefinite use, degrading confidentiality and integrity. Stale or compromised keys can decrypt data, forge signatures, and maintain persistence. Absent lifetimes weaken rotation discipline and impede timely revocation, increasing exposure to cryptographic and operational drift.Recommendation
Set anexpiration on all keys and enforce automated rotation with advance alerts. Retire or disable old versions promptly and rotate after any suspected exposure. Apply least privilege and separation of duties for key administration. Prefer standardized lifecycle policies (e.g., RBAC-based governance) to enforce consistent control.
Remediation
- CLI
- Terraform
- Native IaC
- Dashboard steps
az keyvault key set-attributes —vault-name <example_resource_name> —name <example_resource_name> —expires 2030-01-01T00:00:00Z
References
- https://learn.microsoft.com/en-us/azure/key-vault/general/basic-concepts
- https://learn.microsoft.com/en-us/azure/key-vault/general/about-keys-secrets-certificates#key-vault-keys
- https://www.trendmicro.com/trendaivisiononecloudriskmanagement/knowledge-base/azure/KeyVault/key-expiration-check.html#
Where this check fires
This check runs on every scheduled scan against your Azure account. Findings appear at Cloud Security → Findings filterable byCheck ID = keyvault_key_expiration_set_in_non_rbac. To re-evaluate after a fix, hit Run now on the account’s schedule under Cloud Security → Schedules — the next scan re-checks this control and marks the finding fixed or keeps it persistent.
← Back to Azure checks