|
| 1 | +<!-- markdownlint-disable MD022 MD032 --> |
| 2 | + |
| 3 | +# Quantum KEX Rotation Drill Runbook (Genesis Testnet) |
| 4 | + |
| 5 | +## Purpose |
| 6 | +This runbook defines a public, repeatable post-quantum key exchange (KEX) rotation drill on Genesis Testnet. |
| 7 | + |
| 8 | +The drill demonstrates three things in one auditable sequence: |
| 9 | +1. Transport security controls execute a key rotation path successfully. |
| 10 | +2. Proof verification and ledger writes remain healthy before and after rotation. |
| 11 | +3. Operators can publish a concrete evidence bundle for community and investor review. |
| 12 | + |
| 13 | +## Scope |
| 14 | +- Environment: Genesis Testnet |
| 15 | +- Runtime surface: node-agent auth-gated proof and ledger endpoints |
| 16 | +- Evidence source: local artifact bundle produced by the drill script |
| 17 | + |
| 18 | +## Controls Exercised |
| 19 | +- Session key rotation pathway in crypto transport tests: |
| 20 | + - TestRotateSessionKeyNoDeadlock |
| 21 | + - TestRotateSessionKeyReestablishesSharedSecret |
| 22 | + - TestHandshakeVerification |
| 23 | +- Hybrid verification continuity: |
| 24 | + - POST /api/v1/proof/hybrid/verify |
| 25 | +- Fallback backend rehearsal: |
| 26 | + - POST /api/v1/proof/hybrid/verify with `stark_backend=winterfell_mock` |
| 27 | +- Ledger integrity continuity: |
| 28 | + - GET /api/v1/ledger |
| 29 | + - GET /api/v1/ledger/reconcile |
| 30 | +- Role policy enforcement negative-path: |
| 31 | + - GET /api/v1/ledger with unauthorized role (expects 401/403) |
| 32 | + |
| 33 | +## Preconditions |
| 34 | +- Genesis Testnet stack reachable, with node-agent endpoint available. |
| 35 | +- API token available via one of: |
| 36 | + - MOHAWK_API_TOKEN environment variable |
| 37 | + - MOHAWK_API_TOKEN_FILE (default /run/secrets/mohawk_api_token) |
| 38 | +- Tooling: curl, go, python3 |
| 39 | + |
| 40 | +## Execution |
| 41 | +### Recommended one-command path |
| 42 | + |
| 43 | +```bash |
| 44 | +make quantum-kex-rotation-drill |
| 45 | +``` |
| 46 | + |
| 47 | +### Direct script path |
| 48 | + |
| 49 | +```bash |
| 50 | +NODE_AGENT_BASE_URL=http://localhost:8082 \ |
| 51 | +MOHAWK_API_TOKEN_FILE=/run/secrets/mohawk_api_token \ |
| 52 | +bash scripts/quantum-kex-rotation-drill.sh |
| 53 | +``` |
| 54 | + |
| 55 | +### Optional explicit token override |
| 56 | + |
| 57 | +```bash |
| 58 | +NODE_AGENT_BASE_URL=http://localhost:8082 \ |
| 59 | +MOHAWK_API_TOKEN="<redacted-token>" \ |
| 60 | +bash scripts/quantum-kex-rotation-drill.sh |
| 61 | +``` |
| 62 | + |
| 63 | +## Artifact Output |
| 64 | +Default output directory: |
| 65 | + |
| 66 | +```text |
| 67 | +artifacts/quantum-kex-rotation/<drill-id>/ |
| 68 | +``` |
| 69 | + |
| 70 | +Expected files: |
| 71 | +- readiness_pre.json |
| 72 | +- ledger_pre.json |
| 73 | +- hybrid_verify_pre_rotation.json |
| 74 | +- crypto_rotation_test.log |
| 75 | +- hybrid_verify_post_rotation.json |
| 76 | +- hybrid_verify_fallback_backend.json |
| 77 | +- role_failure_negative_response.txt |
| 78 | +- role_failure_negative_test.json |
| 79 | +- ledger_post.json |
| 80 | +- ledger_reconcile_post.json |
| 81 | +- retention-policy.json |
| 82 | +- immutability-notice.txt |
| 83 | +- checksums.sha256 |
| 84 | +- drill-summary.json |
| 85 | +- drill-summary.md |
| 86 | + |
| 87 | +Generated cross-run index files: |
| 88 | +- artifacts/quantum-kex-rotation/public-drill-index.json |
| 89 | +- artifacts/quantum-kex-rotation/public-drill-index.md |
| 90 | + |
| 91 | +## Success Criteria |
| 92 | +- Readiness pre-check is true. |
| 93 | +- Hybrid verification accepted both before and after rotation tests. |
| 94 | +- Fallback backend rehearsal is accepted. |
| 95 | +- Unauthorized role negative test returns 401/403. |
| 96 | +- Ledger reconciliation healthy after the drill. |
| 97 | +- Ledger entry count increases by at least 2 during the drill. |
| 98 | +- All artifact files present and readable. |
| 99 | + |
| 100 | +## Public Disclosure Template |
| 101 | +Use the generated drill summary values and publish a concise statement: |
| 102 | + |
| 103 | +```text |
| 104 | +Genesis Testnet Quantum KEX Rotation Drill complete. |
| 105 | +
|
| 106 | +- Drill ID: <drill-id> |
| 107 | +- Window (UTC): <start> -> <end> |
| 108 | +- Pre/Post hybrid verification accepted: true/true |
| 109 | +- Ledger reconcile healthy after drill: true |
| 110 | +- Ledger entries added: <n> |
| 111 | +
|
| 112 | +Evidence bundle path: artifacts/quantum-kex-rotation/<drill-id>/ |
| 113 | +``` |
| 114 | + |
| 115 | +## Operational Notes |
| 116 | +- This drill is non-destructive and uses existing verification endpoints. |
| 117 | +- If auth fails, recheck token source and X-API-Role permissions. |
| 118 | +- If reconciliation fails, stop public messaging and open incident triage before rerun. |
| 119 | + |
| 120 | +## Retention and Compliance |
| 121 | +- Canonical policy: [Documentation/Security/QUANTUM_KEX_DRILL_RETENTION_POLICY.md](Documentation/Security/QUANTUM_KEX_DRILL_RETENTION_POLICY.md) |
| 122 | +- Treat each bundle as immutable security evidence for at least 2555 days. |
| 123 | +- Validate `checksums.sha256` before and after archival transfer. |
| 124 | + |
| 125 | +## Suggested Cadence Through 2027 Epoch Deadline |
| 126 | +- Public drill cadence: monthly |
| 127 | +- Add an additional ad hoc drill after any transport/auth policy change |
| 128 | +- Keep the last 12 drill summaries in release and governance reporting channels |
0 commit comments