Public: anyone can read this; nobody can change it.

SEC-1: sovereign age-key backup + rotation tooling + runbook #52

Merged opened this view on origin

Check · Review · Land done · Live — Landed; nothing deploys from this branch, so this is the end of its path.

Merged

Implements roadmap SEC-1 (plat/mitosis#26): backup + rotation lifecycle for the sovereign age key.

Notes

shipped merged

opened this view on origin

Implements roadmap SEC-1 (plat/mitosis#26): backup + rotation lifecycle for the sovereign age key.

What

bin/lib.sh

  • fork_backup_key — at germination, writes an age-encrypted (or clearly operator-guarded) backup of the sovereign key to FORK_KEY_BACKUP, encrypting to FORK_KEY_BACKUP_RECIPIENT when given, and forces an explicit custody acknowledgment (FORK_KEY_ACK=1 or a typed YES on a TTY) before the platform is built. No backup path → loud instruction, never a silent skip. The on-disk key is unchanged and remains the sole key — sovereignty is not weakened.
  • rotate_age_key (+ _rotate_* helpers) — mints a new keypair, re-seals every clusters/ sops file preserving values** via sops updatekeys (not the regenerate-fresh shortcut), rotates the data key so the retired key decrypts nothing, updates .sops.yaml and the in-cluster sops-age Secret, removes the old recipient, and gates on fork_verify_all_sealed. Safe live ordering (add recipient+push → swap in-cluster key → remove old+rotate+push) so Flux never loses the ability to decrypt.

bin/germinate — calls fork_backup_key at key creation; the YOUR PLATFORM card notes the backup path.

docs/ops/age-key-rotation.md — runbook: backup, lost-key recovery, suspected-compromise rotation.

Validation

Validated LIVE on a throwaway vxrail k3d platform (see PR thread for evidence): values preserved in a running pod after rotation; new key verifies + old key fails; old key decrypts nothing under clusters/**; restore-from-backup recovers a platform whose local key was moved aside.

Closes #26.

🤖 Generated with Claude Code

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs