Lion Cipher Lab

Encrypt Kubernetes Secrets at rest, part 2: rotate the key and catch the silent failures

Why it matters

Turning on encryption at rest is a one-time change. Keeping it on is operations, and the failures there are quiet. A provider list with identity at the top still looks enabled while every new Secret goes to etcd in the clear. A rotation done in the wrong order leaves some API servers unable to read what others wrote, or strands Secrets on a key that has been deleted. A migration that missed a few records passes a spot check of one Secret. None of these shows up as an error. You find them by knowing what each change should do to etcd and checking every stored Secret, not a sample. This part…

What you'll learn

Steps in this lab

  1. Where Part 1 left you, and the failures it could not show
  2. Rebuild Part 1's end state in one pass, with secretbox and automatic reload
  3. Break it on purpose: put identity first
  4. Rotate the key, in the order the docs give
  5. Audit every Secret, then retire key1 and identity
  6. The judgment: what this defends, and the problem it leaves

Open the full interactive lab →