Quantum Vault
2-of-3 Shamir · AES-256-GCM · SMAUG-T · HAETAE
Seals a secret under an AES-256-GCM key that is split 2-of-3 with Shamir, wraps each share with the SMAUG-T post-quantum KEM, and signs the container with HAETAE — so you can watch several primitives compose into one seal/open pipeline.
Vault — Safety Deposit Boxes
👉 Try it: click box 03 and enter any 2 of ruby / emerald / diamond to open it.
How this box works
Four cryptographic primitives compose into one seal. This is the envelope story, in order:
- 1 Your secret is locked with one random AES-256 key.
- 2 That key is split into 3 pieces — any 2 rebuild it exactly, 1 alone reveals nothing.
- 3 Each piece is sealed to one keyholder with SMAUG-T, a final KpqC competition KEM still in standardization.
- 4 HAETAE signs the container under a fresh included key. That key is not authenticated; replacing it and re-signing can still pass.
The embedded signature key is not authenticated. Someone can replace the key and re-sign public container data; this does not unlock encrypted shares. Trust requires a key authenticated outside the container.
Inside step 3: a two-step recovery path
The password and KEM protect different links in the recovery path. They are not additive barriers: defeating either one can expose the share.
- Layer 1 — your password Password → PBKDF2 (600k iters) → an AES key that unlocks this keyholder’s SMAUG-T secret key. This is the ONLY step your password touches.
- Layer 2 — the post-quantum KEM At seal time SMAUG-T encapsulated a random 32-byte shared secret against the keyholder’s public key. On open, decapsulate with the secret key recovers that wrapping key. The public record is designed not to reveal it under SMAUG-T’s stated assumptions; this demo does not prove those assumptions or the implementation.
Normal recovery uses the password to obtain the SMAUG-T secret key, then decapsulates. An attacker who guesses the password can follow that route; one who breaks the KEM can derive the wrapping key without the password. The weaker route sets the protection level.
Why is layer 2 considered a post-quantum candidate?
The 2-D picture is only an analogy. SMAUG-T relies on structured high-dimensional lattice assumptions for which no efficient classical or quantum attack is currently known. That is evidence for a security design, not a proof or guarantee.
New to these terms? Expand any for a plain-language definition:
What is a KEM?
KEM = Key Encapsulation Mechanism: public-key crypto that produces a shared secret for an encapsulator and the matching private-key holder. SMAUG-T is designed against known quantum attacks, but remains a standardization candidate rather than a published standard or guarantee.
Shamir sharing & GF(2⁸)?
Shamir Secret Sharing splits a secret into n pieces so any t of them rebuild it and fewer reveal nothing. It works by fitting a random polynomial through the secret over GF(2⁸) — the finite field of one byte (values 0–255 with wrap-around arithmetic). Analogy: 2 points fix a straight line, so any 2 shares fix the same line and recover the secret; 1 point leaves infinitely many lines.
What does “lattice-based” mean?
Lattice-based crypto relies on mathematical problems over high-dimensional lattices for which no efficient classical or quantum attack is known. The grid picture is a rough analogy; each scheme needs its own assumptions, parameters and implementation review.
Signature vs. verify?
Signing uses a private key; verification checks the data and signature under a public key. Trusting who signed requires authenticating that public key independently. This demo checks the key inside the same container: edits with the old signature fail, but replacing the key and re-signing can pass. That does not recover the encrypted secret.
Why study a post-quantum KEM? Step 3 uses SMAUG-T instead of classical RSA/ECDH. Toggle to compare the assumptions:
A quantum computer running Shor's algorithm factors RSA and breaks ECDH. An attacker who copies this sealed box today — “harvest now, decrypt later” — retroactively unwraps every share once such a machine exists. The box you sealed years ago pops open.
SMAUG-T relies on structured lattice assumptions for which no efficient quantum attack is currently known. If those assumptions, parameters and this implementation hold, a harvested box is intended to resist that attack class; the demo does not turn that intent into a guarantee.
Research Origin
This project demonstrates Korean post-quantum cryptographic algorithms compiled to WebAssembly for educational and experimental use.
Algorithms included:
- SMAUG-T (스마우그-T) — lattice-based Key Encapsulation Mechanism (KEM)
- HAETAE (해태) — post-quantum digital signature algorithm
Parameter sets in this build:
This browser demo runs SMAUG-T Level 1 and HAETAE Mode 2 — the lowest parameter set in each family, chosen for smaller keys and a faster load. Their stated targets are NIST PQC categories 1 and 2, so the pair is bounded by category 1. The Rust crates define a separate Level 3 / Mode 3 native FFI path, but it works only after authenticated external C sources are supplied; this checkout does not by itself demonstrate a working Level 3 CLI.
The implementations are derived from reference code produced by Korean cryptography researchers as part of the KpqC competition.
Go deeper — when to use each primitive (and what breaks if you don’t)
⚡ Quick Decision Rules
When unsure → AES-256-GCM + Argon2id + ML-KEM. These are safe defaults.
💥 What Breaks If You Choose Wrong
Nonce reuse (AES-GCM)
Repeated keystream leaks plaintext relations and enables practical forgery attacks. Confidentiality and integrity both fail.
Too few Shamir shares
Interpolation returns an unauthenticated candidate, while every possible secret remains equally likely in the ideal scheme. AES-GCM rejects an incorrect candidate.
Skip signature verification
Changes with the old signature bypass this early check. Signature checks still require an independently authenticated key to defend against a replacement key and signature; AES-GCM authentication is a separate gate.
Classical-only key exchange
Harvest now, decrypt later. Quantum computer breaks RSA/ECDH retroactively.
⚠️ Disclaimers
- Educational only — do not use for production data protection.
- No independent production attestation — competition analysis and this repository review are not a formal audit of the deployed composition.
- Browser WASM has not been established as constant-time. Side-channel resistance is not guaranteed.