Pcornel
Browse topics
Options
Recent
Favorites
Security · Technical reference

Rotation

Direct answer

Secret rotation replaces credentials regularly or after suspected exposure, ideally automatically, with applications fetching the new value from the vault so rotation does not cause outages.

When to use this

Use this when changing secrets regularly or after exposure.

First 30 seconds

1. Rotate secrets regularly and after exposure.

2. Automate (dynamic secrets, managed rotation).

3. Apps must reload new secrets.

4. Overlap periods to avoid outages.

5. Track last rotation.

Operational verification

old secret → new secret issued → apps updated → old revoked

Context & applicabilityCommon mistakes · platform/version boundaries
Common mistakes
Common mistakes
  • Rotating the secret but not restarting or reloading apps, causing outages.
  • No overlap period for dual secrets (old and new valid at the same time).
  • Rotation scripts that log the new secret.
  • Rotating only after a breach instead of on a schedule.
Platform / version applicability
Cryptography, PKI and secrets
applies
Structured applicability is explicit Topic metadata; it does not infer compatibility beyond the stored rows.
At a glance

Operational reference

Fast context before you go deeper.

PlatformCryptography, PKI and secrets
Scope / prerequisiteUse this when changing secrets regularly or after exposure.
What next?2 suggested next steps
Evidence1
On this pageJump to a specific section
Evidence references

Evidence · 1 on this Topic

Expected observations and documentation recipes are reference material. Record actual output, device identity, scope and time before claiming a verified result.

observation · 1
Key points
  • Automate rotation.
  • Update both target and vault.
  • Test applications after rotation.
Key checks
  • Rotation schedule per secret type — policy
  • vault lease renew/revoke — dynamic secrets
  • aws secretsmanager describe-secret --secret-id <id> | grep Rotation — rotation enabled
ReferenceWhy it matters1 section · depth on demand

Rotation approaches

1. Create the new secret.

2. Deploy it to all consumers (or support two valid secrets during the overlap).

3. Revoke the old secret.

4. Verify nothing still uses the old one (logs, failed authentication).

Automate with secret-manager rotation functions (AWS Secrets Manager Lambda, Key Vault rotation, Vault dynamic secrets). Manual rotation is often skipped and breaks applications.

ReferenceImportant terms & boundaries1 section · depth on demand

In depth

Rotation replaces secrets regularly and after any suspected exposure, limiting how long a stolen secret remains useful. Manual rotation is error-prone and often skipped, so automation is key.

Rotation approaches:

ApproachExample
Dynamic secretsVault creates DB credentials per request, auto-expiring
Managed rotationCloud secret managers rotating database passwords; gMSA in AD
Dual secretsTwo valid keys during transition so services switch without downtime
Certificate automationACME for TLS certificates

Test rotation before relying on it: applications must reload new secrets without restarts or outages. Rotate immediately — not on the next schedule — when a secret may have leaked.

ReferenceConfiguration & state1 section · depth on demand

Example: dual-secret rotation

1. Generate a new secret and add it alongside the old (both valid).

2. Update all consumers to the new secret.

3. Confirm no use of the old secret (logs/metrics).

4. Revoke the old secret.

Database users and cloud keys often support two active credentials for this.

Source basisSource attribution states what this section is based on; it is not independent proof that the current environment matches it.
Additional reference context Scope · expected state · examples · history · terminology Open only when you need the supporting context
Technical verification history

Verification history & basis

When and against what this Topic was checked. Later text edits do not count as a new check.

2026-09-14 · vendor docCryptography, PKI and secrets current

Authoritative/upstream documentation reviewed for bounded claims in Secrets Management → Rotation. Documentation verification only; this is not observed lab or production Evidence.

Basis: https://cheatsheetseries.owasp.org/cheatsheets/Secrets_Management_Cheat_Sheet.html · confidence 94%
Confirmation

Confirm action

Continue?