Designing Secrets, Keys and Certificates: Key Vault Architecture, Access Models, HSM Choices and Rotation
How Many Vaults?
| Approach | Notes |
|---|---|
| One vault per application per environment per region | Recommended. Limits blast radius, simple access, fits throttling limits |
| Shared vault for many apps | Easy but risky: broad access, throttling, one failure affects all |
| Separate vault for encryption keys vs app secrets | Good when key custodians differ from app teams |
Which Service?
| Service | Use |
|---|---|
| Key Vault Standard | Secrets, certificates and software keys |
| Key Vault Premium | HSM-protected keys in a multi-tenant HSM service |
| Managed HSM | Dedicated single-tenant HSM, full control and strict compliance |
| Dedicated HSM / Payment HSM | Special regulated cases (check current availability) |
Access Model Design
- Use Azure RBAC for the data plane, with roles such as Secrets User, Crypto User, Certificates Officer
- Give apps managed identities, never shared accounts
- Humans get read access via PIM only when needed
- Separate roles: who manages the vault and who uses secrets
- Use Azure Policy to require RBAC mode, soft delete, purge protection and private endpoints
Resilience
- Vaults replicate within the region and to the paired region (read-only in a regional failover). Check current behavior
- For active-active multi-region, keep one vault per region and deploy the same secrets to both with automation
- Back up keys and secrets as needed. Purge protection prevents permanent loss
Network
- Private endpoint and disable public access, or firewall to selected networks
- Allow trusted Microsoft services only if needed
- Plan DNS for
privatelink.vaultcore.azure.net
Rotation and Lifecycle
| Item | Practice |
|---|---|
| Secrets | Prefer no secrets with managed identity. Otherwise rotate on schedule with automation and Event Grid notifications |
| Keys | Key rotation policy with versionless URIs so services pick up the new version |
| Certificates | Integrated CA auto-renew, alerts before expiry |
| Storage keys / connection strings | Replace with Entra ID auth where possible |
Design Example
Three apps in two environments and two regions: 12 vaults named by pattern, RBAC-only, private endpoints, diagnostic logs to a central workspace, Policy enforcing purge protection, PIM-eligible access for the security team and automated deployment of secrets from a secure pipeline.
Practice
- Decide the number of vaults for five apps in dev and prod
- Explain why purge protection matters for customer-managed keys
- Choose between Premium and Managed HSM for a bank
Conclusion
Use focused vaults per app, environment and region, RBAC with managed identities, private networking, purge protection and automated rotation. Choose HSM options by compliance need.
Quick Summary: vault count; services; access; resilience; network; rotation; example.

