Keyboard shortcuts

Press ← or → to navigate between chapters

Press ? to show this help

Press Esc to hide this help

Sign data with ML-DSA

ML-DSA is the lattice-based signature scheme defined in FIPS 204. The signer uses the private key to produce a response tied to the message and its intended use, which is identified by the context. The verifier uses the public key to check that the response matches the message. For example, if you sign an update before distributing it, anyone with the corresponding public key can verify it independently.

How it works · ML-DSA challenge and response

Parameter setPublic key (bytes)Signature (bytes)Python class
ML-DSA-4413122420MlDsa44
ML-DSA-6519523309MlDsa65
ML-DSA-8725924627MlDsa87

The standard sign operation uses fresh randomness for each signature. Signatures for the same message can differ, so use verify to check validity. The context can be 0 to 255 bytes long and must match between signing and verification. Sign and verify a file · Rust API · FIPS 204