Responsible secret operations
A secret manager is not a rotation plan
Move an exact accepted credential set—and prove what was issued, loaded, accepted, retired, and reconciled.
Putting a credential in a secret manager can improve storage, access control, and auditability. It does not prove that every consumer can discover a replacement, that new instances use it, that long-lived processes have stopped using the old value, that the verifier rejects the old value, or that a failed rollout can be recovered without restoring a compromised credential.
A defensible rotation changes an accepted credential set through explicit states. It binds one rotation intent to the issuer, verifier, consumers, deployment waves, overlap policy, retirement deadline, break-glass path, and evidence retained at each boundary. Storage is one capability inside that protocol, not the protocol itself.
This note provides a rotation contract, an illustrative dual-credential transition, evidence states, a decision order, capability boundaries, failure-shaped tests, and a compact operational checklist. It is a proposed method, not production experience or evidence about a real secret, account, incident, provider, customer, deployment, or compromise. Exact credential type, cryptoperiod, propagation, cache, reload, revocation, audit, and emergency requirements remain system-specific.
Research boundary and source notes
Use these sources narrowly:
- OWASP Secrets Management Cheat Sheet describes secrets as lifecycle-managed material. Its guidance covers creation, rotation, revocation, expiration, access control, auditing, and automation. It recommends regular rotation and says automation reduces the risk of manual handling. This supports treating issuance, distribution, use, rotation, and revocation as separate lifecycle concerns. It does not prove that a particular manager updates every consumer or that an old credential is no longer accepted.
- NIST SP 800-57 Part 1 Revision 5 defines key-management lifecycle concepts and cryptoperiods. It describes key states, transitions, protection requirements, and the limited period during which key material is authorized for use. This supports naming activation, deactivation, compromise, destruction, and retention boundaries for cryptographic keys. It does not prescribe one universal rotation interval for every application secret or prove deployment convergence.
- RFC 7009 defines an OAuth token-revocation endpoint and narrow revocation behavior. It specifies a way for a client to notify an authorization server that a token is no longer needed, and notes that revocation may invalidate the token and, when applicable, related tokens based on authorization-server policy. This is useful evidence that issuing replacement credentials and invalidating old credentials are distinct operations. Its rules apply to OAuth tokens, not arbitrary passwords, API keys, signing keys, certificates, or database credentials.
All three source URLs returned HTTPS 200 during research on 2026-08-15:
- OWASP, Secrets Management Cheat Sheet
- NIST, Recommendation for Key Management: Part 1 — General, Revision 5
- RFC 7009, OAuth 2.0 Token Revocation
The standards, provider documentation, and target system's security policy remain controlling. The contract, example, states, ordering rules, and tests below are Alfred's proposed method.
Core thesis
A secret manager can answer “where is credential material stored and who may retrieve it?” Rotation must also answer “which credential is issued, distributed, loaded, presented, accepted, retired, recoverable, and auditable now?”
Keep these facts separate:
- Secret identity: the logical credential role, not its reusable bytes.
- Version identity: one immutable generation or fingerprint under a protected derivation rule.
- Rotation intent: the approved transition from an exact prior accepted set to an exact target set.
- Issuance evidence: proof that a replacement was generated by the intended authority under the intended policy.
- Storage evidence: proof that the version was committed to the intended manager and path with expected access controls.
- Distribution evidence: proof that authorized consumers could obtain the intended version.
- Load evidence: proof that one process or instance actually loaded a named version.
- Presentation evidence: proof that a consumer attempted to use a named version, without logging its secret bytes.
- Verifier evidence: proof of which versions an authority accepted or rejected at an observed time.
- Effect evidence: the authoritative result of operations attempted during the transition.
- Retirement evidence: proof that the old version is no longer accepted for the declared scope.
- Recovery evidence: proof that rollback or forward repair can restore service without silently restoring unsafe authority.
A successful write to a vault, a changed environment variable, a deployment completion signal, a healthy process, one successful request, or deletion of one stored version proves only part of this chain.
Work one dual-credential transition through the hard case
Consider an illustrative service credential:
logical_secret = billing_export_writer
old_version = version_example_12
new_version = version_example_13
consumers = worker_pool_a + scheduled_exporter_b
verifier = destination_example
normal_overlap = 20 minutes
retirement_deadline = t+30m
These identifiers and times are placeholders, not evidence about a real provider, account, secret, workload, or customer.
At t=0, the issuer creates version_example_13. The manager stores it and reports success. Worker pool A reloads it, but the scheduled exporter keeps the old value in memory because it reads only at process start. A rollout dashboard shows all newly created workers healthy. One new-version request succeeds at the destination.
None of those observations proves rotation complete. Exporter B may still present version 12. The verifier may accept both versions during an intended overlap, or may still accept version 12 because retirement was never applied. Deleting version 12 from the manager would prevent new retrieval without removing copies already held in process memory, environment blocks, local caches, deployment history, crash dumps, or another replica. Restarting every consumer without controlling in-flight effects may duplicate or abandon work.
A safer path:
- define one immutable rotation intent and target accepted-version set;
- issue the replacement under the named authority and policy;
- store and distribute it without exposing reusable bytes in logs or evidence;
- enable only the overlap required by the target's capabilities;
- roll consumers in bounded waves and record per-instance loaded-version evidence;
- reconcile in-flight and uncertain effects before terminating old attempts;
- prove every required consumer can operate with the new version;
- disable old-version acceptance at the authoritative verifier;
- test old-version rejection through a safe non-destructive probe or verifier state;
- retain privacy-minimized transition evidence and destroy obsolete material according to policy.
If the destination cannot accept two credentials concurrently, rotation needs another mechanism: a coordinated cutover, a proxy that separates consumer and destination credentials, a connection-drain boundary, or a scoped outage. Pretending that an atomic global swap exists creates an unmeasured failure window.
Define a rotation contract
rotation_id: stable identity for one approved transition
logical_secret: role and scope, never reusable bytes
credential_type: password, API key, token, certificate, signing key, or other profile
issuer_authority: who may create, activate, revoke, and destroy versions
old_accepted_set: exact versions expected before transition
new_accepted_set: exact versions expected after transition
consumer_inventory: required workloads, instances, jobs, regions, and offline consumers
retrieval_rule: manager paths, identities, authorization, and failure behavior
reload_rule: startup-only, watch, polling, signal, sidecar, or explicit API
overlap_rule: whether dual acceptance exists and its maximum duration
attempt_rule: ownership, fencing, cancellation, and in-flight handling
verifier_rule: authoritative acceptance and rejection evidence
retirement_rule: deadline, safe probe, remaining-copy handling, and approval
recovery_rule: rollback versus forward repair and compromised-version prohibition
retention_rule: evidence, redaction, access, and destruction horizons
terminal_outcomes: completed, rolled_forward, rolled_back_safe, blocked, failed, or indeterminate
Questions to resolve before changing a credential:
- What exact credential role and authority boundary are changing?
- Which version set is accepted now, and which set must be accepted afterward?
- Which issuer is authoritative for creation, activation, revocation, and destruction?
- Which consumers exist, including dormant jobs, autoscaling templates, disaster-recovery paths, and offline clients?
- How does each consumer discover and load a version?
- Does retrieval success mean immediate use, next request, next connection, or next restart?
- Can the verifier accept old and new concurrently, and for how long?
- Which observations prove the version loaded without exposing the credential?
- What happens to open connections, queued work, retries, and uncertain effects?
- How is old-version rejection established at every authoritative verifier?
- What is the repair path if only part of the fleet changes?
- May rollback reactivate the old version, or must recovery roll forward?
- How are compromise rotations different from routine rotations?
- Which secret copies, caches, backups, and logs can outlive manager deletion?
- Which evidence can be retained without creating a new secret repository?
Match system capability to a safe transition
| Capability | Safe use | Required evidence | Residual limit or stop rule |
|---|---|---|---|
| Manager with versioned values | Store immutable generations and grant scoped retrieval. | Logical identity, version reference, write result, access policy, and audit event. | Storage does not prove load, presentation, acceptance, or retirement. |
| Dynamic credentials | Issue bounded credentials per workload or session. | Issuer, subject, scope, issue time, expiry, and revocation behavior. | Expiry still needs clock, cache, renewal, and outage handling. |
| Dual acceptance | Add new, migrate consumers, then reject old. | Exact accepted set, overlap start, consumer version evidence, and retirement deadline. | Overlap increases the valid credential set; keep it bounded. |
| Startup-only loading | Restart or replace instances in controlled waves. | Instance identity, template version, loaded-version reference, drain, and readiness. | A healthy replacement does not prove the old process stopped or its effects settled. |
| Live reload | Change a process version without replacement. | Reload trigger, parse result, loaded version, connection behavior, and fallback. | File change or signal delivery is not successful reload. |
| Single-slot verifier | Coordinate a bounded cutover or introduce an indirection layer. | Cutover authority, consumer readiness, exact switch time, and outage plan. | Stop if consumer and verifier transitions cannot be safely ordered. |
| No authoritative acceptance telemetry | Use safe probes and explicit verifier configuration reads where available. | Probe scope, observation time, route, and limitations. | Do not infer fleet-wide rejection from silence or one success. |
Match evidence to the authority that produced it
Each observation has a narrow owner and conclusion. A manager cannot speak for a process's memory, and a deployment controller cannot speak for a verifier's accepted set.
| Authority | Observation | Narrow conclusion | Evidence still required |
|---|---|---|---|
| Issuer | Version 13 was generated under policy P at time T. | The intended authority issued one named replacement. | Storage, retrieval, loading, acceptance, and retirement. |
| Secret manager | Version 13 was committed at path S; identity C may read it. | One stored generation and access rule exist. | Whether C retrieved it or an active process loaded it. |
| Consumer | Instance I reports protected fingerprint F as loaded. | One named instance reports one in-memory generation. | Presentation, verifier acceptance, remaining consumers, and effect state. |
| Deployment controller | Wave W reached its declared rollout state. | The controller observed its own rollout conditions. | Old-process termination, active version, scheduled consumers, and verifier state. |
| Verifier | Version 13 was accepted and version 12 rejected for safe probe Q at time T. | One authoritative route produced scoped acceptance and rejection evidence. | Other verifier replicas or routes, late presentations, and effect reconciliation. |
| Effect authority | Intent E has terminal result R. | The protected operation has a retained outcome. | Nothing beyond the declared intent and authority scope; it does not prove fleet convergence. |
When observations conflict, preserve both. For example, deployment_complete + old_still_presented is a conflict to investigate, not evidence that the verifier log is stale merely because the rollout dashboard is green.
Separate routine rotation from compromise response
Routine and compromise-triggered rotations can share machinery, but they do not share every safe fallback.
| Decision | Routine rotation | Suspected or confirmed compromise |
|---|---|---|
| Old-version overlap | May be allowed for a short declared window when risk policy permits. | Minimize or prohibit; continuing acceptance extends exposed authority. |
| Rollback target | May restore the prior accepted set if policy permits and its material remains trustworthy. | Must not reactivate suspect material; prefer forward repair or a separately issued emergency credential. |
| Consumer migration | Bounded waves with stop conditions. | Risk-prioritized waves or coordinated cutover, with explicit service-impact authority. |
| Old-version probe | Safe non-effecting rejection probe or authoritative configuration evidence. | Do not present known-compromised material when doing so increases exposure; prefer verifier state and protected telemetry. |
| Evidence and notification | Normal audit and retention policy. | Incident policy, legal and regulatory obligations, and tighter access controls may apply. |
| Completion | New accepted, old rejected, consumers converged, effects reconciled. | The same, plus compromise-specific containment and evidence requirements under the incident plan. |
Classify the trigger before choosing rollback behavior. Automation that blindly restores “last known good” can turn a successful compromise rotation into renewed exposure.
Refer to versions without creating another secret
Evidence should identify a generation without retaining reusable credential bytes. Prefer an issuer- or manager-provided immutable version identifier when it is non-secret and access-controlled. If a derived fingerprint is needed, compute it inside a protected boundary with a versioned keyed derivation over the secret and stable context such as the logical secret and credential type:
version_reference = derivation_version + HMAC(protected_evidence_key,
logical_secret + credential_type + credential_bytes)
The evidence key is itself protected material. Restrict access, rotate it under policy, and retain the derivation version needed to interpret existing records. Do not expose the reference publicly, use a plain hash for low-entropy passwords or tokens, permit arbitrary online fingerprint queries, or treat a fingerprint match as proof of authorization. A reference can correlate observations; issuer authority, active loading, verifier acceptance, and effect evidence still require their own checks.
Bound overlap, evidence, and retirement horizons
Retention is not “keep the logs.” Derive it from named horizons and apply the least detail and access needed to satisfy them:
dormant_consumer_horizon = latest approved interval before an offline consumer must run
overlap_horizon = maximum period in which old and new may both be accepted
late_presentation_horizon = period in which old-version use must still be detected
duplicate_effect_horizon = period in which repeated intents must reconcile
incident_horizon = bounded investigation requirement
audit_minimum_horizon = minimum policy or accountability requirement
privacy_maximum_horizon = longest permitted retention for consumer and request detail
Keep non-secret rotation identity, accepted-set transitions, protected version references, verifier outcomes, and terminal effect references only as long as their applicable purpose requires. Keep reusable credentials out of evidence. If a dormant consumer can wake after all version evidence expires, either lengthen the minimum evidence horizon within privacy policy, shorten the supported dormancy, or classify that consumer as unsupported; do not claim complete coverage.
The overlap deadline is operational, not decorative. On expiry without old-version rejection and consumer convergence, emit rotation_overdue, prevent ordinary completion, and follow the declared stop, containment, or forward-repair rule.
Proposed evidence states
- Intent approved: exact old and target sets, scope, deadline, and authority are fixed.
- Inventory incomplete: one or more required consumers or verifiers are unknown.
- Replacement issued: the intended issuer created a named version.
- Replacement stored: the manager committed the named version under expected policy.
- Retrieval authorized: a consumer identity may retrieve the named version.
- Retrieval observed: one consumer obtained the named version.
- Load observed: one consumer reports the protected version reference as active.
- Load unknown: configuration changed but active in-memory state is not established.
- New presentation observed: a protected fingerprint or verifier event identifies new-version use.
- New accepted: the authoritative verifier accepted the new version for a scoped probe or operation.
- Old still presented: at least one consumer continues to use the old version.
- Overlap active: old and new versions are intentionally accepted.
- Overlap expired: the declared overlap deadline passed without terminal retirement evidence.
- Old disabled: the verifier configuration excludes the old version.
- Old rejection observed: a safe scoped check confirms old-version rejection.
- Effect unsettled: an attempt under either version lacks authoritative terminal effect evidence.
- Consumer blocked: a required consumer cannot retrieve, load, or use the replacement.
- Evidence conflicted: consumer, manager, deployment, or verifier observations disagree.
- Rollback unsafe: recovery would restore a compromised or policy-forbidden version.
- Forward repair active: the system is recovering by completing replacement adoption.
- Material destroyed: obsolete managed material was destroyed under policy.
- Completed: required consumers use the replacement, the old version is rejected, effects are reconciled, and evidence is retained.
- Indeterminate: available evidence cannot establish the accepted set or consumer state.
Do not collapse replacement stored, load observed, new accepted, old disabled, old rejection observed, material destroyed, and completed.
A compact rotation-evidence card
The card works an explicitly illustrative dual-credential transition through one accepted-set intent, issuer and manager evidence, per-consumer loaded-version evidence, bounded overlap, in-flight effect reconciliation, authoritative old-version disablement and rejection evidence, late-presentation monitoring, and a forward-repair stop path. It keeps issued, stored, retrieved, loaded, accepted, old rejected, and completed states distinct without exposing reusable credential bytes.
Return evidence-shaped outcomes
Expose typed internal results rather than one ambiguous rotated boolean:
| Result | Meaning | Required handling |
|---|---|---|
rotation_blocked |
Inventory, authority, capability, or approval is missing before a safe transition. | Do not issue or cut over; preserve the blocking reason. |
rotation_in_progress |
The transition is within its declared window and required evidence is accumulating. | Continue only through approved waves and stop conditions. |
rotation_conflicted |
Trusted authorities report incompatible version, consumer, verifier, or effect state. | Freeze advancement, preserve both observations, and reconcile. |
rotation_overdue |
The overlap or retirement deadline passed without terminal evidence. | Escalate under policy; do not silently extend dual acceptance. |
forward_repair_required |
Restoring the prior version is prohibited or unsafe. | Issue or propagate safe replacement authority; fence suspect work. |
rotation_failed_safe |
The attempt ended without reaching the target set and the declared safe fallback is established. | Record the exact accepted set and remaining work. |
rotation_indeterminate |
Available evidence cannot establish consumer or verifier state. | Restrict authority or stop; do not infer completion from silence. |
rotation_completed |
Required consumers use the target set, old acceptance is rejected, effects are reconciled, and evidence is retained. | Report only the declared scope and observation boundary. |
External status can be simpler, but the operational record must retain the distinction. In particular, rotation_overdue is not automatically rotation_completed when the old credential eventually expires; expiry and authoritative rejection are different evidence.
Proposed decision order
1. Classify the credential type, compromise state, and authority boundary.
2. Freeze one rotation intent with exact old and target accepted sets.
3. Inventory required consumers, verifiers, reload methods, and in-flight effects.
4. Select routine-overlap, emergency-forward-only, or coordinated-cutover policy.
5. Issue a replacement through the intended authority.
6. Commit it to the intended manager path with scoped access controls.
7. Verify retrieval through each required identity class without exposing bytes.
8. Activate bounded dual acceptance only when supported and approved.
9. Roll consumers in waves and record active loaded-version evidence.
10. Verify new-version use and authoritative acceptance for each critical path.
11. Stop or repair on unknown consumers, conflicting versions, or unsafe effects.
12. Reconcile queued, in-flight, retried, and indeterminate operations.
13. Disable old-version acceptance at each authoritative verifier.
14. Establish old-version rejection with a safe scoped method.
15. Watch for late old-version presentations through the declared deadline.
16. Destroy obsolete material and residual managed copies according to policy.
17. Retain redacted transition, verifier, effect, and terminal evidence.
18. Declare only completed, safe rollback, forward repair, blocked, failed, or indeterminate.
Failure-shaped test matrix
Before publication, turn each row into a concrete expected result for the target system:
- replacement stored but a startup-only consumer is never restarted;
- consumer reload signal delivered but parsing or activation fails;
- all new instances use the replacement while one old instance remains alive;
- scheduled job wakes after the overlap window with a cached old version;
- manager version deleted while the verifier still accepts that version;
- verifier disables old before one critical consumer can load new;
- destination supports only one credential and rollout is partially complete;
- rollback automation restores the old version after a compromise-triggered rotation;
- autoscaling template still references the old manager version;
- disaster-recovery environment is omitted from the consumer inventory;
- open connection remains authorized after credential replacement;
- new credential succeeds on one route but fails on another verifier replica;
- old-version probe could cause a destructive effect;
- audit logs accidentally capture reusable credential bytes;
- rotation overlaps with an uncertain external effect and a retry;
- version evidence is retired before the latest dormant consumer can run;
- issuer, manager, consumer, and verifier clocks disagree near expiry;
- a late old-version presentation appears after completion was declared.
Make rejection probes incapable of business effects
Prefer an authoritative verifier configuration read or a dedicated validation endpoint that performs authentication only and cannot enqueue, mutate, bill, notify, export, or trigger another downstream action. If no such capability exists, use a purpose-built canary resource and operation whose contract is read-only and side-effect free, with a unique rotation probe identity, bounded rate, protected logging, and an expected old-version rejection result.
Do not use a normal business request with “test” parameters and assume downstream systems will ignore it. Do not retry an ambiguous probe. If the probe times out or its route cannot be shown to exercise the authoritative verifier, record rejection as indeterminate. For compromised credentials, avoid presenting the old material when verifier state or protected telemetry can establish retirement without extending exposure.
Compact rotation-evidence checklist
- Name the logical secret, credential type, trigger, compromise state, issuer, verifier, and exact old and target accepted sets.
- Inventory every required workload, instance class, scheduled job, offline client, region, recovery path, template, cache, and verifier route.
- Record how each consumer retrieves and reloads a version and whether the change affects existing connections.
- Choose routine overlap, coordinated cutover, or compromise forward-repair policy before issuing material.
- Set one overlap limit, retirement deadline, late-presentation window, and safe stop rule.
- Issue and store the replacement through named authorities without exposing bytes in logs, commands, or evidence.
- Use an immutable provider version or protected keyed reference; never publish a low-entropy plain hash or offer a fingerprint oracle.
- Verify retrieval through each identity class, then active loading on every required consumer class; do not infer memory state from a manager write.
- Roll in bounded waves and preserve deployment, old-process termination, connection, and loaded-version evidence separately.
- Verify new-version presentation and acceptance on every critical verifier path.
- Reconcile queued, in-flight, retried, cancelled, and indeterminate effects by stable operation identity.
- Stop on unknown consumers, version conflicts, missed waves, unsafe effects, or an expired overlap window.
- Disable old acceptance at the authoritative verifier; deleting manager storage is not revocation.
- Establish old rejection through configuration evidence or a non-effecting scoped probe; never test with a destructive business operation.
- Watch for late old-version presentations through the declared horizon and reopen the transition if one appears.
- Destroy obsolete managed material and address caches, templates, backups, process memory, and residual copies under policy.
- Return blocked, conflicted, overdue, safe-failed, forward-repair, indeterminate, or completed according to collected evidence.
- Retain privacy-minimized transition, version, verifier, and effect references through named horizons, then delete or aggregate them.
The OWASP, NIST, and RFC sources were re-checked during completion on 2026-08-15. Their narrow limits remain controlling: lifecycle guidance is not deployment evidence; NIST's key states and cryptoperiod guidance is specific to cryptographic key management; and RFC 7009 defines OAuth token revocation rather than universal revocation behavior for every credential type. This finished draft remains local until its disclosure, sources, content, original asset, and publication bundle pass the separate publication workflow.
Working takeaway
Secure storage is necessary but narrow evidence. The defensible completion claim is: one approved rotation intent moved every required consumer and verifier from an exact old accepted set to an exact target set; new-version loading and acceptance were observed; uncertain effects were reconciled; old-version rejection was established within a declared boundary; obsolete material was handled under policy; and the retained record contains version references rather than reusable secret bytes. Anything less should remain blocked, failed, or indeterminate—not “rotated.”