spec

Implemented in src/PQ.sol and src/Vault.sol, and checked against a second implementation written from this page rather than from the contract.

PARAMETERSKECCAK256
n32 · hash output in bytes
w16 · message read four bits at a time
len1 / len264 message digits, 3 checksum digits
len67 chains per key
h8 · 256 keys per identity
WHY THE CHECKSUM IS THE WHOLE SCHEME

A verifier only ever hashes forward, so raising any message digit is free for a forger: take the element you were given and walk it one step further. What stops that is the checksum, which counts the distance every chain still has left to run. Raising a message digit lowers the checksum, and lowering a checksum digit means walking a chain backwards, which is a preimage of keccak256.

C = Σ (15 − di) ≤ 960 < 16³
σi = Fdi(ski)  ·  verify: F15−di(σi) =? pki

QUANTUM THREAT MODELAFTER A QUANTUM BREAK
ETH in an ordinary accountexposed · the address is the public key
ETH in a quantum vaultsafe · spending needs a hash-based signature
who launched a coinsafe · the attestation still verifies
identity from a wallet alonere-derivable by whoever recovers the wallet key
identity with a passphrasesafe, given the passphrase has real entropy