Skip to content

audit: Ed25519 seed verification + journal sealing#6

Merged
jaschadub merged 1 commit into
mainfrom
audit-signing
Jun 15, 2026
Merged

audit: Ed25519 seed verification + journal sealing#6
jaschadub merged 1 commit into
mainfrom
audit-signing

Conversation

@jaschadub

Copy link
Copy Markdown
Contributor

Summary

Adds Ed25519 signing to redteam in two roles:

  • Consumer: verify incoming signed validation seeds against pinned producer keys before any objective is acted on (redteam-seed verify). Canonical signing recipe documented to match the producer byte-for-byte.
  • Producer/self: seal redteam's own hash-chained audit journal by signing the chain head (redteam-seal); the web viewer's audit badge upgrades to AUDIT SEALED when a valid seal matches the head.

New modules: crypto.rs, seed.rs, audit.rs (journal linkage moved here from the web crate + sealing). Private keys gitignored; keys/producers.toml.example documents the keyring.

Test Plan

  • 14 new lib tests (crypto / seed / audit) + redteam-seed CLI e2e
  • full suite green (0 failed suites), clippy --all-targets clean
  • live CLI: seal create→verify→tamper, seed keyring/unknown-key rejection

🤖 Generated with Claude Code

Add Ed25519 signing to redteam, ported from the codered substrate, in two
roles:

- Consumer: verify incoming signed validation seeds against PINNED PRODUCER
  keys before any objective is acted on. Keyring resolves from
  CODERED_PRODUCER_PUBKEYS or keys/producers.toml (public keys only). The
  canonical signing recipe (signature field reset to "", compact JSON) is
  documented and matches the producer side byte-for-byte. New redteam-seed
  binary gates a seed file; non-zero exit means do not act.

- Producer/self: seal redteam's own audit journal. The runtime hash-chains
  the journal but does not sign it; redteam-seal verifies linkage then signs
  the chain head with a per-engagement key, so one signature attests the whole
  journal and a forged-but-relinked journal fails. The web viewer's audit
  badge upgrades to AUDIT SEALED when a valid seal matches the head.

Shared crypto.rs (sign/verify + verify-only path), seed.rs (keyring + verify),
and audit.rs (linkage moved here from the web crate + sealing). Private keys
are gitignored; producers.toml.example documents the keyring format.

Covered by 14 lib tests + a redteam-seed CLI e2e. Clippy clean.
@jaschadub jaschadub merged commit 16572d9 into main Jun 15, 2026
1 check passed
@jaschadub jaschadub deleted the audit-signing branch June 15, 2026 23:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant