Docs / Concepts

Suites

A suite fixes every algorithm for a key and for the bytes it produces. The suite id travels inside each envelope and signature, so there is no negotiation and no downgrade.

01Suites at a glance

SuiteSealSignPick it when
PQL-DEFAULTX-Wing (ML-KEM-768 + X25519), AES-256-GCMML-DSA-65 + Ed25519Almost always
PQL-HIGHML-KEM-1024 + P-384, AES-256-GCM, SHA-384 KDFML-DSA-87 + ECDSA P-384NIST category 5 with a classical half, or P-384 for compliance
PQL-CNSAML-KEM-1024, AES-256-GCM, SHA-384 KDFML-DSA-87CNSA 2.0: post-quantum only, category 5
PQL-LEGACYNeverNeverImporting RSA and ECC keys read-only during migration

02Sizes in bytes

SuiteSeal public keyEnvelope overheadSign public keySignature
PQL-DEFAULT1,2161,1951,9843,388
PQL-HIGH1,6651,7402,6894,738
PQL-CNSA1,5681,6432,5924,642

Envelope overhead is fixed: a 10-byte secret and a 10 MB file both carry the same 1,195 bytes in PQL-DEFAULT. Signature sizes include the 15-byte PQLG header.

03Why hybrid

ML-KEM and ML-DSA are new. Hybrid suites combine them with a classical algorithm so that breaking the data requires breaking both: a quantum computer breaks X25519 and Ed25519, and an unexpected classical attack on lattices would need to break those too. PQL-CNSA is the exception: CNSA 2.0 requires post-quantum algorithms alone, so it has no classical fallback.

04Choosing a suite

Set the suite once for the whole application in pql.policy.yaml, or per keyset when creating it. Existing data keeps opening under its original suite, because the suite is read from the bytes.

Limits in v0.1

Token keysets are PQL-DEFAULT only. Data-key records used by seal_batch, stream and rotate have a fixed size for PQL-DEFAULT, so the seal keyset behind them stays on PQL-DEFAULT until a later record format.

pqlock v0.1.0 · unaudited preview · source of truth: spec/