Also mentioned
RSARSARivest, Shamir and AdlemanA widely used public-key algorithm for encryption and digital signatures whose security relies on the difficulty of factoring large numbers.Read the full entry (new tab), ECDSAECDSAElliptic Curve Digital Signature AlgorithmElliptic Curve Digital Signature Algorithm, a widely deployed signature scheme based on elliptic-curve cryptography, offering strong security with compact keys.Read the full entry (new tab), ML-KEMML-KEMModule-Lattice-based Key Encapsulation MechanismModule-Lattice-Based Key-Encapsulation Mechanism, the NIST-standardized post-quantum KEM derived from CRYSTALS-Kyber and specified in FIPS 203.Read the full entry (new tab), TLSTLSTransport Layer SecurityTransport Layer Security, the protocol that encrypts and authenticates most internet traffic, including HTTPS. It uses key exchange, certificates, and symmetric encryption to protect a session.Read the full entry (new tab), FIPSFIPSFederal Information Processing StandardFederal Information Processing Standards, publicly announced standards developed by NIST for use in U.S. government computer systems, including cryptographic algorithms and modules.Read the full entry (new tab), NISTNISTNational Institute of Standards and TechnologyThe U.S. National Institute of Standards and Technology, the agency that develops and publishes cryptographic standards, including the FIPS series and post-quantum algorithms.Read the full entry (new tab) are defined in the glossary.
Read this first
A post-quantum SSH test must prove the algorithm negotiated on every real connection, not merely that client and server binaries list it. Require a hybrid ML-KEM key exchange, capture the negotiated name, test failure below the cryptographic floor, and repeat through jump hosts, automation and rekeying. The hybrid exchange protects session confidentiality, but it does not make a classical SSH host key post-quantum.
| Component | Client value | Server value | Purpose |
|---|---|---|---|
| ML-KEM-768 | 1,184-byte encapsulation key | 1,088-byte ciphertext | Post-quantum shared secret |
| X25519 | 32-byte public key | 32-byte public key | Traditional shared secret |
| Combined KEX | mlkem768x25519-sha256 | mlkem768x25519-sha256 | One SSH exchange secret derived from both components |
RFC 10042 standardizes three post-quantum and traditional hybrid key exchanges for SSH. The profile most widely deployed by OpenSSH is mlkem768x25519-sha256. It combines the FIPS 203 ML-KEM-768 secret with an X25519 secret so the session remains protected when at least one component resists the attacker.
Distinguish support, policy and negotiation
Three different observations are often collapsed into one. ssh -Q kex shows algorithms compiled into a client. ssh -G host and sshd -T show effective policy after configuration is applied. Only a connection trace shows what the peers selected. A useful cryptographic inventory records all three, with the binary version, configuration source, host and collection time.
- Record
ssh -Vfor every client and server implementation in scope. - Run
ssh -Q kexon each client to establish compiled capability. - Inspect
ssh -G hostnamefor the effective client KexAlgorithms order, including Match and Include processing. - Inspect
sshd -Twith representative connection criteria for the effective server list. - Connect with verbose logging and capture the exact
kex: algorithmresult. - Store the negotiated algorithm beside the destination, route, jump host and automation identity.
An advertised algorithm is not a negotiated algorithm
A modern client can support ML-KEM while selecting a classical exchange because the server lacks the hybrid, configuration removed it, a jump host terminated a different connection, or policy ordering changed. Capability evidence cannot substitute for a connection trace.
Set a floor that produces a visible failure
| Case | Expected result | Evidence |
|---|---|---|
| Both peers permit the hybrid | Connection succeeds with mlkem768x25519-sha256 | Verbose client trace and server event |
| Server removes every hybrid | Strict test client fails before authentication | Client error and effective server policy |
| Client offers hybrid after classical options | Selected result matches the declared policy | Client proposal, server proposal and negotiated name |
| Configuration includes an unsupported name | Startup or connection fails clearly | Configuration validation output |
| Legacy exception is used | Only the named host receives the exception | Effective per-host configuration and expiry owner |
OpenSSH chooses the first client preference also accepted by the server. RFC 4253 includes both KEXINIT payloads in the exchange hash authenticated by the server host key, so an on-path attacker cannot simply rewrite the lists without detection. Operational downgrade still exists when policy intentionally offers a classical path or when a different connection endpoint has weaker configuration. The release gate should therefore assert the selected algorithm, not assume negotiation from the ordering.
Test the route users actually take
- Direct administrative SSH from every supported workstation image.
- ProxyJump and bastion paths, treating each SSH leg as a separate negotiation.
- CI runners, deployment agents, backup jobs and configuration-management clients.
- SFTP and scp paths that may invoke a different binary or configuration.
- Port-forwarding and control-master reuse, including a fresh master after policy changes.
- Third-party SSH libraries embedded in products that do not use the system OpenSSH client.
A bastion does not extend one hybrid exchange to the destination. The client-to-bastion and bastion-to-target legs negotiate independently. Capture both. A post-quantum migration plan should assign an owner and exception date to each classical leg rather than marking the workflow compliant because its first hop is hybrid.
Exercise rekeying and long-lived sessions
SSH can replace its session keys after the initial handshake. Force a low rekey limit in a controlled environment, transfer enough data to trigger it and confirm the hybrid algorithm is used again. Repeat after configuration reloads, daemon restarts, host failover and connection multiplexing. Long-lived administration and backup sessions should not begin above the floor and later rekey below it.
A warning is not an enforcement control
OpenSSH 10.1 warns when a connection selects a non-post-quantum key exchange. That helps discovery, but WarnWeakCrypto can be disabled and a warning does not stop the connection. A strict environment needs an explicit KexAlgorithms policy plus evidence from connection tests.
Keep host authentication as a separate result
Hybrid key exchange and host authentication answer different questions. mlkem768x25519-sha256 protects the creation of session keys against a future quantum attacker while retaining an X25519 hedge. The server still proves its identity with the negotiated host-key algorithm. If that is RSA, ECDSA or Ed25519, the authentication layer remains vulnerable to a sufficiently capable quantum computer even though the session key exchange is hybrid.
Record kex: host key algorithm separately from kex: algorithm. Do the same for user authentication, certificates and hardware-backed keys. A hybrid TLS test uses the same discipline: confidentiality, server authentication and client authentication are separate cryptographic surfaces. Do not compress them into one post-quantum label.
Run negative tests before rollout
- Remove the hybrid from the server and verify that a strict client fails rather than continuing classically.
- Remove it from the client and verify the server cannot make that connection appear compliant.
- Alter Match and Include files to confirm the effective configuration catches scope mistakes.
- Test an old jump host, container image and automation runner that cannot offer the hybrid.
- Interrupt the first exchange and a rekey to confirm bounded failure without a weaker retry.
- Verify monitoring records the selected KEX and distinguishes policy failure from host-key or user-authentication failure.
These cases belong in a scoped implementation audit, not only in a migration spreadsheet. Migration support can sequence upgrades and exceptions across clients, bastions and servers, while conformance work can preserve versions, vectors and negative cases as reviewable evidence.
References
- RFC 10042: Post-Quantum and Traditional Hybrid Key Exchange with ML-KEM for SSH. The three standardized hybrid methods, encodings and combiner.
- NIST FIPS 203. ML-KEM definition and parameter sizes.
- RFC 4253: The Secure Shell Transport Layer Protocol. Negotiation, exchange hash and server authentication.
- OpenSSH post-quantum cryptography guidance. Version history, default hybrids and weak-crypto warning.
- OpenSSH ssh_config manual. Client KexAlgorithms policy and effective configuration behavior.
- OpenSSH sshd_config manual. Server KexAlgorithms policy and supported hybrid names.
The acceptance result is one reproducible statement per connection path: which hybrid exchanged the session secret, which host key authenticated the server, what failed below the floor, and which temporary exception remains. Anything less leaves a deployment label that cannot be audited.
Where this goes next