What happened
In the signing flow, the key stays in the backend while data is sent for signing and returned signed. A key is eligible for retirement once every certificate it backs is revoked or expired; credentials signed by a certificate do not outlast that certificate. (hacdias.com) But an imported certificate submitted through a CSR can only be revoked by its issuer, so the system also offers early release to mark a key as no longer needed even if that certificate may remain valid. (hacdias.com) Retirement immediately stops signing and expires other scheduled actions. (hacdias.com) Material is destroyed only after a grace period—30 days is one example. (hacdias.com) Initially, Google Cloud KMS keys used Google's minimum 24-hour destroy window; the team now sets the backend destroy window to match the grace period where supported. (hacdias.com) Before sending a destroy request, the system claims the key; once claimed, cancellation is refused.
With a 30-day grace period and the initial 24-hour backend window, the application's check alone prevented destruction for 29 of the 30 days. The author describes matching the backend window to the grace period as added protection against application bugs or changes made through the backend dashboard. The claim-and-refuse rule is intended to make the race resolve one way: cancellation wins without destruction, or destruction wins and cancellation is refused. These are described safeguards, not measured reliability outcomes.
Why it matters
For a team lead, the design lesson is to place the waiting period in the backend where possible, then serialize cancellation against the destroy request. An application-only timer leaves the grace period dependent on application behavior; a backend that destroys immediately makes the cancellation race especially consequential.
Limits and uncertainty
This is one practitioner's account. The author says OpenBao has no backend-enforced destroy limit, leaving the application check as the only protection in that case; some backends, including OpenBao, destroy on request without a later undo window. (hacdias.com)
Reader takeaway
Treat stopping a key from signing and destroying its material as separate operations. Enforce the waiting period in the key backend where possible, and make cancellation and destruction mutually exclusive before sending a destroy request. The account describes safeguards, not measured reliability gains, and one backend is said to lack a built-in delay.
Open question
If the backend cannot enforce a delay, what independent control can prevent early destruction if the application check fails?