Post-Quantum Cryptography

Preparing for Quantum Computers

The Quantum Threat

CosmicNet explains that quantum computers can break RSA and ECC using Shor's algorithm. When large-scale quantum computers exist, current public-key cryptography becomes useless.

!

Harvest Now, Decrypt Later: As documented on CosmicNet, adversaries are storing encrypted data today, waiting to decrypt it when quantum computers are available. Long-term secrets need post-quantum protection NOW.

NIST Standards (2024)

CosmicNet covers the three primary NIST post-quantum standards:

ML-KEM (Kyber)

Key encapsulation based on lattices

Key Exchange

ML-DSA (Dilithium)

Digital signatures from lattices

Signatures

SLH-DSA (SPHINCS+)

Hash-based signatures

Signatures

Approach Categories

CosmicNet's analysis of the five major approaches to quantum-resistant cryptography:

Lattice-basedMost promising, basis for Kyber/Dilithium
Hash-basedWell-understood security (SPHINCS+)
Code-basedMcEliece - large keys but proven
Isogeny-basedSIKE broken in 2022, research continues
MultivariateBased on solving polynomial equations

Migration Strategy

CosmicNet recommends the following steps for transitioning to post-quantum cryptography:

  • Inventory cryptographic dependencies
  • Use hybrid approaches (classical + PQ)
  • Signal already supports PQXDH
  • Chrome/Firefox testing PQ in TLS
  • Prioritize long-term secrets first
  • Test performance impacts

Symmetric Crypto Status

Good News
AES-256: Safe (Grover's algorithm halves security)
SHA-256: Safe with 256-bit output
ChaCha20-256: Safe

Just double key sizes for equivalent security!

Understanding the Quantum Computing Threat

Quantum computers exploit quantum mechanical phenomena like superposition and entanglement to perform calculations that are intractable for classical computers. CosmicNet explains that while most computational problems remain difficult even for quantum computers, certain mathematical problems that underpin modern cryptography can be solved exponentially faster on quantum systems.

Shor's Algorithm: Breaking Public-Key Cryptography

Developed by mathematician Peter Shor in 1994, Shor's algorithm poses the most significant quantum threat to current cryptographic systems. CosmicNet details how this quantum algorithm can efficiently factor large numbers and solve the discrete logarithm problem, which forms the mathematical foundation of RSA, Diffie-Hellman, and Elliptic Curve Cryptography (ECC).

Where classical computers would require billions of years to factor a 2048-bit RSA key, a sufficiently large quantum computer running Shor's algorithm could accomplish the same task in hours or days. As CosmicNet explains, this capability would render virtually all current public-key infrastructure vulnerable, affecting everything from secure web browsing (HTTPS/TLS) to digital signatures on software updates. See CosmicNet's asymmetric encryption guide for more on the algorithms at risk.

Grover's Algorithm and Symmetric Cryptography

Grover's algorithm, discovered by Lov Grover in 1996, provides a quadratic speedup for unstructured search problems. CosmicNet explains that when applied to cryptography, this means a quantum computer can effectively reduce the security of symmetric encryption by half. An AES-128 key would provide only 64 bits of quantum security, while AES-256 would retain 128 bits of security.

The impact on symmetric cryptography is significant but manageable. CosmicNet notes that unlike the catastrophic break that Shor's algorithm represents for public-key systems, Grover's algorithm simply requires doubling key sizes to maintain equivalent security levels. This is why AES-256, SHA-256, and other 256-bit symmetric algorithms remain recommended for post-quantum scenarios.

The Timeline Challenge

While large-scale, cryptographically-relevant quantum computers don't exist yet, experts disagree on when they will arrive. CosmicNet reports that optimistic predictions suggest 10-15 years, while conservative estimates range from 20-30 years or more. However, the cryptographic community cannot afford to wait. Transitioning global infrastructure takes decades, and the "harvest now, decrypt later" threat means adversaries may already be collecting encrypted data to decrypt in the future.

NIST Post-Quantum Cryptography Standardization

In 2016, the National Institute of Standards and Technology (NIST) initiated a multi-year process to evaluate and standardize quantum-resistant cryptographic algorithms. CosmicNet covers how after receiving 82 initial submissions and conducting multiple rounds of rigorous cryptanalysis, NIST announced the first set of post-quantum standards in August 2024.

ML-KEM: Module-Lattice-Based Key Encapsulation

Previously known as CRYSTALS-Kyber, ML-KEM is the primary standard for establishing shared secrets over public channels. CosmicNet explains that it replaces traditional Diffie-Hellman and ECDH key exchange mechanisms with a lattice-based approach that resists quantum attacks.

ML-KEM offers three security levels: ML-KEM-512, ML-KEM-768, and ML-KEM-1024. CosmicNet notes that the algorithm features relatively small key sizes and fast performance, making it practical for widespread deployment in TLS, VPNs, and other protocols requiring key establishment.

ML-DSA: Module-Lattice-Based Digital Signatures

ML-DSA, formerly known as CRYSTALS-Dilithium, is the primary standard for post-quantum digital signatures. CosmicNet explains that like ML-KEM, it's based on the hardness of lattice problems and offers three security levels corresponding to AES-128, AES-192, and AES-256.

ML-DSA produces signatures that are significantly larger than traditional ECDSA or RSA signatures, but the verification process is fast and efficient. CosmicNet recommends this algorithm for signing certificates, code signing, document authentication, and other applications where quantum resistance is required.

SLH-DSA: Stateless Hash-Based Signatures

SLH-DSA, based on SPHINCS+, provides an alternative signature scheme built on hash functions rather than lattice mathematics. CosmicNet explains that this approach offers excellent security assurances based on minimal cryptographic assumptions - if secure hash functions exist, SLH-DSA is secure.

The main trade-off with SLH-DSA is signature size, ranging from 7-50 KB depending on the parameter set. CosmicNet notes that this conservative approach makes SLH-DSA ideal for high-security applications where maximum confidence is required, such as root certificate authorities or long-term archival signatures.

FN-DSA: Fast-Fourier Lattice-Based Signatures

FALCON, designated as FN-DSA by NIST, offers the smallest signature and public key sizes among the lattice-based signature schemes. CosmicNet explains that this efficiency makes FALCON particularly attractive for constrained environments like IoT devices or applications with strict bandwidth limitations.

The algorithm's complexity and use of floating-point arithmetic make implementation more challenging than ML-DSA. As CosmicNet notes, careful attention to side-channel resistance is required, but FALCON's compact signatures make it valuable for specific use cases where size optimization is critical.

For more information, visit the official NIST Post-Quantum Cryptography Project website.

Cryptographic Approaches to Quantum Resistance

CosmicNet provides an in-depth look at the mathematical foundations behind each approach to post-quantum security.

Lattice-Based Cryptography

Lattice-based cryptography has emerged as the most promising foundation for post-quantum security. CosmicNet explains that these schemes rely on the difficulty of finding short vectors in high-dimensional lattices, a problem believed to be hard even for quantum computers. The Learning With Errors (LWE) and Ring-LWE problems provide the mathematical basis for schemes like Kyber and Dilithium.

Beyond quantum resistance, lattice-based cryptography enables advanced capabilities like fully homomorphic encryption and functional encryption. CosmicNet notes that the relatively small key sizes and fast operations make these schemes practical for real-world deployment, which is why NIST selected lattice-based algorithms as primary standards.

Hash-Based Signatures

Hash-based signatures represent the oldest and most conservative approach to post-quantum cryptography. CosmicNet explains that these schemes build signature systems using only cryptographic hash functions, relying on minimal security assumptions. If collision-resistant hash functions exist, hash-based signatures are provably secure.

The main distinction is between stateful schemes (like XMSS and LMS) and stateless schemes (like SPHINCS+). As CosmicNet details, stateful schemes require careful state management to prevent key reuse, while stateless schemes sacrifice signature size for operational simplicity. See CosmicNet's hashing guide for more on the underlying hash functions.

Code-Based Cryptography

Code-based cryptography, pioneered by Robert McEliece in 1978, relies on the difficulty of decoding random linear codes. CosmicNet explains that the McEliece cryptosystem has withstood decades of cryptanalysis and remains a strong candidate for post-quantum encryption. However, the extremely large public keys have limited practical adoption.

Recent variants like BIKE and HQC attempt to reduce key sizes while maintaining security. CosmicNet notes that while not selected as first-round standards, NIST continues evaluating code-based schemes for potential future standardization.

Multivariate Cryptography

Multivariate cryptography bases its security on the difficulty of solving systems of multivariate polynomial equations over finite fields. CosmicNet explains that this NP-hard problem provides a foundation for signature schemes like Rainbow and GeMSS. These algorithms typically offer small signatures and fast verification, but public keys remain large.

The multivariate approach has faced several successful attacks over the years. CosmicNet notes that the theoretical understanding of multivariate systems' security is less mature than lattice or hash-based approaches, requiring careful parameter selection.

Isogeny-Based Cryptography

Isogeny-based cryptography utilizes the complex mathematics of elliptic curve isogenies. CosmicNet explains that the most prominent example was SIKE (Supersingular Isogeny Key Encapsulation), which offered extremely small key sizes. However, SIKE was dramatically broken in 2022 using classical computers, demonstrating the risks of cryptographic approaches based on less-studied mathematical problems.

Despite SIKE's failure, research continues on isogeny-based cryptography with different parameter choices. As CosmicNet notes, the field demonstrates both the potential for innovative approaches and the necessity of thorough cryptanalysis before deployment.

Learn more about these mathematical approaches on Wikipedia's Post-Quantum Cryptography article.

Hybrid Cryptographic Approaches

Given the relative novelty of post-quantum algorithms, CosmicNet explains how hybrid approaches combine traditional and post-quantum cryptography to provide defense-in-depth. A hybrid scheme remains secure as long as at least one of its component algorithms is unbroken.

Hybrid Key Exchange

Hybrid key exchange combines traditional ECDH with post-quantum key encapsulation. CosmicNet details how X25519 might be paired with ML-KEM-768, deriving the final shared secret from both exchanges. This approach protects against both current attackers (who can't break ECDH) and future quantum attackers (who can't break ML-KEM).

Major implementations are already deploying hybrid key exchange. CosmicNet reports that Google Chrome has experimented with hybrid X25519+Kyber in TLS 1.3, and Cloudflare offers hybrid key exchange options. The Signal Protocol's PQXDH (Post-Quantum Extended Diffie-Hellman) combines X25519 with Kyber for forward-secret messaging.

Hybrid Signatures

Hybrid signatures combine traditional signatures (RSA or ECDSA) with post-quantum signatures (ML-DSA or SLH-DSA). CosmicNet explains that this dual-signature approach increases signature sizes but provides maximum security assurance during the transition period. Applications include software signing, certificate authorities, and document authentication.

Migration Considerations

Hybrid approaches offer a pragmatic migration path but introduce complexity. CosmicNet notes that implementations must handle larger message sizes, manage two sets of keys, and carefully combine security properties. Protocol designers must ensure that the composition doesn't introduce new vulnerabilities.

Migration Timeline and Strategy

Transitioning to post-quantum cryptography is a multi-year effort requiring careful planning. CosmicNet outlines the recommended timeline and approach for organizations at different stages of readiness.

Near-Term Actions (2024-2026)

Organizations should begin by inventorying their cryptographic dependencies. CosmicNet recommends mapping out where public-key cryptography is used: TLS certificates, code signing, VPN authentication, SSH keys, disk encryption key management, and application-level cryptography.

Deploy hybrid approaches where possible, particularly for systems protecting long-term secrets. CosmicNet explains that updating TLS configurations to support hybrid key exchange enables quantum resistance while maintaining compatibility. Begin testing post-quantum algorithms in non-production environments to understand performance characteristics.

Medium-Term Goals (2026-2030)

As implementations mature and standards stabilize, transition production systems to post-quantum cryptography. CosmicNet recommends prioritizing systems with long-term secrets, high-value data, or extended service lifetimes. Update certificate authorities to issue certificates with post-quantum signatures.

CosmicNet emphasizes the importance of implementing cryptographic agility - the ability to quickly switch cryptographic algorithms when necessary. Design systems with abstraction layers that separate cryptographic primitives from business logic, enabling algorithm replacement without extensive code changes.

Long-Term Vision (2030+)

Eventually, post-quantum cryptography should become the default, with classical algorithms deprecated for new deployments. CosmicNet notes that legacy systems may continue using classical or hybrid approaches, but new applications should adopt purely post-quantum schemes as implementations mature.

For the latest standardization updates, check NIST's PQC Standards Announcement.

The "Harvest Now, Decrypt Later" Threat

One of the most concerning aspects of the quantum threat is the "harvest now, decrypt later" attack model. CosmicNet explains that adversaries with sufficient resources can capture and store encrypted communications today, even though they cannot currently decrypt them. When quantum computers become available, this archived data can be retroactively decrypted.

What Data Is at Risk?

Any encrypted data transmitted or stored today that requires confidentiality beyond the arrival of quantum computers is vulnerable. CosmicNet identifies the following categories at greatest risk: state secrets, personal health records, financial information, intellectual property, and long-term business communications. The confidentiality horizon varies by domain: medical records might require 50+ years of protection, while business secrets might need 10-20 years.

Mitigation Strategies

Organizations must assess their data's confidentiality requirements and implement post-quantum protection for information that must remain secure. CosmicNet recommends deploying PQC now for high-value secrets, even if large-scale quantum computers remain theoretical.

Forward secrecy becomes even more critical in the quantum era. CosmicNet explains that protocols generating ephemeral keys for each session limit the impact of future key compromise. See CosmicNet's guide to perfect forward secrecy for detailed information on ephemeral key protocols.

Impact on Network Security Protocols

CosmicNet examines how post-quantum cryptography affects the major network protocols that protect internet communications.

TLS/HTTPS

Transport Layer Security (TLS) protects web browsing, API communications, and countless other internet services. CosmicNet explains that the protocol uses public-key cryptography for authentication and key establishment, making it vulnerable to quantum attacks. Fortunately, TLS's modular design facilitates algorithm substitution.

TLS 1.3 already supports cipher suite negotiation that can accommodate post-quantum algorithms. CosmicNet reports that major implementations like OpenSSL, BoringSSL, and wolfSSL are adding support for ML-KEM and hybrid key exchange. Websites can begin offering PQC cipher suites without breaking compatibility with existing clients.

SSH

Secure Shell (SSH) relies on public-key cryptography for server authentication and key exchange. CosmicNet explains that long-lived SSH keys for server access are particularly vulnerable to harvest-now-decrypt-later attacks. Organizations should rotate SSH keys to post-quantum algorithms and implement hybrid authentication.

CosmicNet notes that OpenSSH has been experimenting with post-quantum key exchange since version 8.2, and ongoing development focuses on integrating NIST-standardized algorithms. See CosmicNet's key exchange guide for more on SSH key exchange protocols.

VPNs and IPsec

Virtual Private Networks commonly use IPsec or TLS-based protocols. CosmicNet explains that these protocols depend on public-key cryptography for authentication and key establishment, requiring post-quantum upgrades. The Internet Key Exchange (IKEv2) protocol used with IPsec supports algorithm negotiation and can incorporate post-quantum key exchange.

CosmicNet recommends that VPN providers and enterprise networks prioritize PQC deployment given the sensitivity of tunneled traffic and the long-term nature of VPN infrastructure. Hybrid approaches allow gradual migration while maintaining security against both classical and quantum threats.

Certificate Authorities and PKI

Public Key Infrastructure (PKI) and certificate authorities form the trust foundation for internet security. CosmicNet explains that transitioning PKI to post-quantum cryptography is complex because certificate chains require all certificates from root to leaf to be quantum-resistant.

Hybrid certificates that contain both classical and post-quantum keys provide a transition mechanism. CosmicNet notes that standards bodies are actively working on PQC certificate formats and issuance procedures to support the PKI transition.

For detailed protocol specifications, see the IETF Post-Quantum Use In Protocols Working Group.

Cryptographic Agility

Cryptographic agility refers to the ability to quickly adapt to new cryptographic requirements by changing algorithms, key sizes, or protocols without extensive system redesign. CosmicNet explains why the transition to post-quantum cryptography highlights the importance of building agile systems.

Design Principles

Agile systems abstract cryptographic primitives behind well-defined interfaces. CosmicNet recommends isolating cryptographic operations in modules that can be swapped or upgraded independently, rather than hard-coding specific algorithms throughout an application. Configuration-driven algorithm selection allows operational changes without code modifications.

Version negotiation protocols enable clients and servers to agree on supported algorithms dynamically. CosmicNet explains that this capability allows gradual rollout of new algorithms while maintaining backward compatibility. Protocol designers should plan for algorithm evolution from the beginning.

Implementation Challenges

While conceptually straightforward, achieving true cryptographic agility faces practical obstacles. CosmicNet notes that different algorithms have different properties: key sizes, signature sizes, performance characteristics, and security assumptions. Code designed for 256-byte RSA signatures may struggle with 2KB post-quantum signatures.

Testing becomes more complex when multiple algorithm combinations are supported. CosmicNet explains that security audits must verify that algorithm selection mechanisms don't introduce downgrade attacks, and that each supported algorithm is correctly implemented.

Balancing Agility and Security

Excessive agility can weaken security if poorly-chosen algorithms remain enabled for compatibility. CosmicNet recommends that algorithm negotiation must be authenticated to prevent downgrade attacks. Organizations should regularly review and deprecate outdated algorithms rather than maintaining indefinite backward compatibility.

Read more about cryptographic agility principles and best practices.

Implementation Considerations

CosmicNet provides practical guidance for developers and architects implementing post-quantum cryptography in real-world systems.

Performance Impact

Post-quantum algorithms generally require more computational resources than classical equivalents. CosmicNet explains that ML-KEM and ML-DSA offer reasonable performance, often within 2-3x of ECDH and ECDSA respectively on modern hardware. Hash-based signatures like SLH-DSA are considerably slower, particularly for signing operations.

Bandwidth and storage requirements increase due to larger key sizes and signatures. CosmicNet notes that where ECDSA produces 64-byte signatures, ML-DSA generates 2-4KB signatures depending on the security level. Applications with tight bandwidth constraints must carefully evaluate these trade-offs.

Side-Channel Resistance

Post-quantum algorithms introduce new side-channel attack surfaces. CosmicNet explains that lattice-based schemes require careful implementation to prevent timing attacks and fault injection. The use of polynomial arithmetic and modular reduction creates opportunities for leaking secret information.

Constant-time implementations, masking, and other side-channel countermeasures are essential. CosmicNet recommends following the cryptographic community's secure implementation guidance and reference code to avoid common pitfalls, particularly for embedded systems and smart cards.

Library and Tool Support

Major cryptographic libraries are adding post-quantum support. CosmicNet reports that OpenSSL 3.x includes provider modules for PQC algorithms, while BoringSSL and wolfSSL offer experimental support. Higher-level libraries and frameworks must be updated to expose PQC functionality to applications.

Hardware security modules (HSMs), smart cards, and TPMs require firmware updates to support post-quantum algorithms. CosmicNet notes that the hardware update cycle may lag software support, creating deployment challenges for systems dependent on hardware-backed cryptography.