Trail of Bits, funded by the Sovereign Tech Agency, has added post-quantum cryptography support to pyca/cryptography (the 11th most-downloaded Python package on PyPI). Starting with version 48, ML-KEM (FIPS 203, key encapsulation) and ML-DSA (FIPS 204, digital signatures) are available via a simple pip install. These NIST-standardized algorithms replace classical primitives like X25519 and Ed25519 but come with significant size tradeoffs — public keys and signatures are 1–2 orders of magnitude larger. The post covers the API design, size comparisons between classical and post-quantum algorithms, and notes that SLH-DSA (FIPS 205) support is in progress. Protocol-level integration (e.g., in Certbot, Ansible) remains future work.
Table of contents
Post-quantum support is now one pip install awayPQ algorithm tradeoffsUsing ML-DSA ( FIPS 204 ): Quantum-resistant signaturesUsing ML-KEM ( FIPS 203 ): Key encapsulation for the post-quantum eraThe road ahead: SLH-DSA and protocol integrationAcknowledgments933 Impressions