v150 · Web Cryptography
ML-DSA signatures
Module-Lattice Digital Signature Algorithm (FIPS 204) is the post-quantum replacement for ECDSA/RSA signatures. Sign a message, verify it, then flip the tamper switch to prove a modified message fails verification. Larger parameter sets trade bigger signatures for higher security levels — see the real byte sizes below.
Post-quantum WebCrypto isn't enabled in this browser.
Launch Chrome 150+ with
Launch Chrome 150+ with
--enable-blink-features=WebCryptoPQC, or enable
chrome://flags/#enable-experimental-web-platform-features. Origin-trial token:
WebCryptoAdditionalAlgorithms202606. Buttons call the real crypto.subtle
sign/verify and report exactly what the browser returns.
Pick a parameter set and sign the message.
Public key — via getPublicKey(privateKey)
—
Signature
—
Verification of the (possibly tampered) message
not verified
const alg = { name: "ML-DSA-65" };
const { privateKey, publicKey } =
await crypto.subtle.generateKey(alg, true, ["sign", "verify"]);
// Derive the public key from the private key alone (new getPublicKey())
const derivedPub = await crypto.subtle.getPublicKey(privateKey, ["verify"]);
const message = new TextEncoder().encode("Transfer 100 credits…");
const signature = await crypto.subtle.sign(alg, privateKey, message);
const ok = await crypto.subtle.verify(alg, derivedPub, signature, message);
// ok === true; change one byte of `message` and verify() returns false
see also
- ML-KEM key exchange — the post-quantum KEM companion
- Capability matrix — which algorithms this browser supports
- ChaCha20-Poly1305 — modern symmetric AEAD
implementation reference
Need the exact API surface, compatibility boundaries, errors, lifecycle, and source links? Read the matching gendn reference ↗