pycryptodome
pycryptodome 4.x is the only self-contained Python library with ML-KEM, ML-DSA, all twelve SLH-DSA sets and X-Wing HPKE, but its post-quantum code is about six weeks old and it has no X.509 tooling.
- PyPI
pycryptodome- Version cited
- 4.7.030 Nov 2026
- Downloads
- 87.4M/mo
Key exchange and encryption
PQ with action
ML-KEM, X-Wing HPKE from 4.2
Signatures and identity
PQ with action
ML-DSA ≥4.1, SLH-DSA ≥4.6
What to do
Upgrade to pycryptodome>=4.7.0 (from 3.x or pycryptodomex), use it where you need SLH-DSA, and keep pyca/cryptography for X.509 and PKI.
Since 1 Dec 2026 4.7.0 (30 Nov 2026) predates the advisory; nothing advisory-related found as of 3 Dec 2026.
Details
ML-KEM, ML-DSA, SLH-DSA, HPKE
pycryptodome 4.7.0 (30 Nov 2026; 87,360,444 downloads per 30 days) ships self-contained, constant-time C implementations of ML-KEM-512/768/1024, ML-DSA-44/65/87, all twelve FIPS 205 SLH-DSA sets, X-Wing and PQ-HPKE with no OpenSSL dependency. P-256 and Ed25519 remain available and caller-chosen. The Claude report calls it the only self-contained, production-oriented alternative with full NIST PQ coverage; the AGY report calls it production-ready and the best production Python library for SLH-DSA today, for example ultra-conservative firmware or root signing.
Caveat. Its PQ code is only about six weeks old (ML-DSA landed 19 Oct 2026).
The 4.x series#
Sources: pycryptodome Changelog, v4.7.0 Changelog, repository.
- 4.0.0 (14 Oct 2026): stopped releasing pycryptodomex (the
Cryptodomenamespace) except for security patches on 3.x. Removed GMP in favor of constant-time big-integer C code (_nat/_ec_nat). - 4.1.0 (19 Oct):
Crypto.PublicKey.MLDSAandCrypto.Signature.mldsa(ML_DSA_44/65/87), via portable constant-time Cmldsa-nativev2.0.0 plus AVX2/BMI2 SHA-3. HashML-DSA, hedged or deterministic signing, contexts andMLDSAMuHash. - 4.2.0 (24 Oct):
Crypto.PublicKey.MLKEM(ML_KEM_512/768/1024,mlkem-nativev2.0.0).Crypto.PublicKey.Hybridwith “MLKEM768-X25519 (X-Wing)”, usable only within HPKE and not exportable.Crypto.Protocol.HPKEfor “post-quantum HPKE (draft-ietf-hpke-pq)”. - 4.6.0 (22 Nov):
Crypto.PublicKey.SLHDSAandCrypto.Signature.slhdsa: all twelve FIPS 205 parameter sets, RFC 9909 SPKI/PKCS#8 encodings, HashSLH-DSA. Also AEGIS-128L/256. - 4.7.0 (30 Nov): native C/SIMD Argon2 and OpenSSH certificate import.
Limits#
- No X.509 certificate builders or verifiers; use cryptography for PKI.
- A released implementation is not an automatic upgrade of existing ciphertext.
- An HPKE hybrid is not a TLS group or an SSH algorithm.
- python-jose 3.5.0 pins
pycryptodome<4.0.0via its extra, which blocks it from all of this (PyPI python-jose).
Uses#
- Re-encrypting stored X25519 or P-256 envelopes with pycryptodome ≥4.2 HPKE X-Wing.
- SLH-DSA, which pyca does not implement (see gaps).
Full discussion: Crypto libraries
Sources cited on this page 4
- pycryptodome Changelog github.com
- v4.7.0 Changelog github.com
- repository github.com
- PyPI python-jose pypi.org