What a post-quantum upgrade of Rust involves: runtimes and code

A Rust post-quantum upgrade is mostly a TLS provider decision: rustls with the aws-lc-rs provider ships hybrid X25519MLKEM768 key exchange, while ML-DSA certificates and standalone RustCrypto crates need separate planning.

On this page

Which Rust post-quantum upgrade work depends on your provider choice

If your team runs Rust services that terminate or open TLS and is planning a post-quantum upgrade, the main lever is the rustls crypto provider. As of 2026-12-04, rustls 0.23.48 prefers hybrid X25519MLKEM768 key exchange when the aws-lc-rs provider is in use, regardless of crate features. The ring provider does not support post-quantum algorithms, and rustls 0.23.48 deprecates rustls::crypto::ring::default_provider() for that reason. Owners of services, build pipelines and FIPS-scoped deployments all need to care, because the provider you select determines what your binaries can negotiate.

Rust has no single built-in cryptography stack, so this page covers several layers: rustls for TLS, aws-lc-rs and ring as providers, the openssl crate as bindings to OpenSSL or LibreSSL, and the RustCrypto ml-kem, ml-dsa and slh-dsa crates as pure Rust implementations. Each layer has a different role, and a post-quantum change in one does not automatically reach the others. Confirm which provider each service links, and whether the openssl crate is used for any TLS path, since the openssl crate documentation as fetched on 2026-12-03 does not mention post-quantum cryptography.

For FIPS-scoped deployments, the rustls FIPS guide requires the fips crate feature and installing default_fips_provider() as the process default. Its FIPS use is covered by FIPS 140-3 certificate #4816, and later aws-lc-rs releases may be covered by later certificates or may be pending certification. Confirm with your assessor whether the post-quantum key exchange in your chosen build falls within the certified boundary, and record the exact aws-lc-rs and AWS-LC-FIPS versions you run, because the aws-lc-rs 1.19.0 docs tie the fips feature to AWS-LC-FIPS 4.x.

What each Rust component supports, by version and source date

This table lists each Rust component in the post-quantum inventory, the post-quantum support recorded for it in the cited release notes, docs or README, and what does not apply. Read the rows by component version and source date, since support in one crate does not carry over to another. The main takeaway is that key exchange support is present in rustls with aws-lc-rs, while post-quantum certificate and signature support remains limited or unsupported in the public web PKI.

ComponentPost-quantum support recordedWhat does not apply
rustls 0.23.48 (aws-lc-rs provider)Prefers X25519MLKEM768 key exchange regardless of crate features, per the 03 Dec release notes (year not shown).Applies to key exchange only, not to certificates or signatures. Confirm the release year on the releases page.
rustls 0.23.44Enables ML-DSA certificate support by default in the aws-lc-rs provider, per the 07 Sep release notes (year not shown).The same notes state ML-DSA certificates are not supported in the public web PKI.
aws-lc-rs provider (rustls default)Complete feature set, including post-quantum algorithms, per the rustls README.Standalone MLKEM768 is available but not enabled by default, per the rustls defaults page.
ring provider (rustls-ring)None. The rustls README states ring does not support post-quantum algorithms.The rustls 0.23.48 release notes deprecate rustls::crypto::ring::default_provider() for this reason.
openssl crate 0.10.82None recorded. The crate documentation, as fetched on 2026-12-03, does not mention post-quantum cryptography.Any post-quantum behavior depends on the OpenSSL or LibreSSL version it binds to, which the docs do not state. Confirm with the linked OpenSSL build.
rustls-post-quantum 0.2.4MLKEM768 and X25519MLKEM768 statics on the aws-lc-rs provider. ML-DSA variants exist behind the experimental aws-lc-rs-unstable feature.The ML-KEM exchanges moved into rustls before 0.23.22, so the ML-KEM statics are not needed for current rustls. ML-DSA is experimental and not a public web PKI option.
RustCrypto ml-kem (docs show 0.3.4)Pure Rust implementation of FIPS 203 with ML-KEM-512, ML-KEM-768 and ML-KEM-1024.Not a rustls key exchange provider. The README states the crate has never been independently audited.
RustCrypto ml-dsaPure Rust implementation of FIPS 204 with ML-DSA-44, ML-DSA-65 and ML-DSA-87.Not wired into rustls certificate handling. The README states the crate has never been independently audited.
RustCrypto slh-dsaPure Rust implementation of SLH-DSA based on FIPS 205.Not wired into rustls. The README states the crate has never been independently audited.

Which parts of a Rust build the upgrade touches

Rust has no single built-in cryptography stack, so a post-quantum upgrade touches several separate parts: TLS, the crypto provider, the OpenSSL bindings, FIPS builds and pure-Rust signature crates. Each one changes differently, so plan and test them one at a time.

Key exchange path in rustls

Rustls negotiates key exchange through its crypto provider. On the aws-lc-rs provider, the hybrid X25519MLKEM768 group is now preferred, and standalone MLKEM768 is available but not enabled by default. For the upgrade, confirm which group a client or server actually negotiates, since the defaults page warns that some users may see unexpected connection failures with X25519MLKEM768 and asks for those to be reported.

Rustls defaults

Signature and certificate path

Rustls certificate and handshake verification still depends on ECDSA, Ed25519 and RSA, which are classical public-key algorithms. Rustls 0.23.44 added ML-DSA certificate support on aws-lc-rs, but states that ML-DSA certificates are not supported in the public web PKI. Treat post-quantum signatures as a private-PKI or testing topic, and check your certificate chain before assuming any change.

Rustls releases

Crypto provider selection

A rustls process has at most one implicit default provider, set with CryptoProvider::install_default(), or a provider can be passed explicitly through builder_with_provider(). The README says that from version 0.24, users must supply a crypto provider explicitly. Decide early which provider your code uses, because rustls-ring does not support post-quantum algorithms and its default provider is deprecated.

CryptoProvider docs

The openssl crate and vendored OpenSSL

The openssl crate binds to a system OpenSSL, LibreSSL or, with the vendored feature, a statically linked copy of OpenSSL built through the openssl-src crate. Its documentation does not mention post-quantum cryptography, so an upgrade here depends on the OpenSSL version you link. Check the version inside each binary, because a vendored copy will not pick up later system OpenSSL updates.

openssl crate docs

The FIPS build path

Rustls FIPS use requires the fips crate feature and installing default_fips_provider() as the process default. Its FIPS use is covered by FIPS 140-3 certificate #4816, and later aws-lc-rs releases may fall under later certificates or be pending certification. Confirm which certificate applies to the exact aws-lc-rs and AWS-LC-FIPS version in your build before relying on it.

Rustls FIPS guide

Pure-Rust RustCrypto crates

The ml-kem, ml-dsa and slh-dsa crates from RustCrypto are pure-Rust implementations of FIPS 203, 204 and 205. Their READMEs state that they have never been independently audited and say to use them at your own risk. Include them in your review scope and ask for an independent audit before using them for production keys.

ml-kem README

How the upgrade differs by provider, FIPS need and certificate type

Rustls ships with the aws-lc-rs provider enabled by default through the aws_lc_rs feature, and the rustls-aws-lc-rs provider is the first-party option the rustls README describes as having the complete feature set, including post-quantum algorithms. Per the rustls 0.23.48 release notes, the aws-lc-rs provider now prefers X25519MLKEM768 key exchange regardless of crate features, so a build that keeps this default may negotiate a hybrid post-quantum group without code changes.

  • Build change: Keep the default feature set, or pin the aws_lc_rs feature explicitly. The rustls README says that from version 0.24 users must supply a crypto provider explicitly, so plan for that call in the code.
  • Key exchange: X25519MLKEM768 is the first preference for aws-lc-rs. Standalone MLKEM768 is available but not enabled by default.
  • What can break: The rustls defaults page warns that some users may see unexpected connection failures with X25519MLKEM768 and asks for them to be reported. Test against the peers you actually connect to.
  • Certificates: Certificate verification still depends on ECDSA, Ed25519 or RSA. The default provider change covers key exchange, not the certificate chain.
  • Source to check: The rustls releases page and the rustls defaults page for the exact version you ship.

Confirm the rustls and aws-lc-rs versions in your lock file, then run connection tests against each peer type before you rely on the default ordering.

Where the hybrid key exchange sits in a rustls TLS 1.3 handshake

The diagram starts with a client building a TLS 1.3 ClientHello. Rustls sends a key share for the first entry in the provider's kx_groups list, which the aws-lc-rs provider sets to the hybrid group X25519MLKEM768. The server picks a group from the offer, and the handshake proceeds with that group's shared secret. The certificate and its signature still use ECDSA, Ed25519 or RSA, because rustls's post-quantum support covers key exchange only. When checking a deployment, confirm which provider is installed, that the aws-lc-rs feature is enabled, and which group the server actually selected.

The hybrid group is the first key share offered; the signature is unchanged.

Steps to plan and verify a Rust post-quantum upgrade

This sequence moves a Rust service from an unknown cryptographic footprint to a verified, explicitly configured TLS setup. Each step ends with a check you can record, so the result is evidence you can show a security review rather than an assumption about defaults.

  1. Inventory crates and providers per service

    For each service, list every crate in the dependency tree that touches cryptography: rustls, aws-lc-rs, ring, the openssl crate, and any RustCrypto crates such as ml-kem, ml-dsa or slh-dsa. Run cargo tree for the locked build of each service and record the exact versions, because the provider in use determines whether post-quantum key exchange is available at all. The step is done when every service has a written list of crates and providers, reviewed by the service owner.

  2. Pin rustls to 0.23.48 or later

    Set rustls to version 0.23.48 or later in each service's Cargo.toml and regenerate the lockfile, since the release notes for that version state that the aws-lc-rs provider prefers X25519MLKEM768 regardless of crate features. Set the provider explicitly in code with builder_with_provider() or install a default provider at startup, instead of relying on implicit selection. The check is that cargo tree shows the expected rustls version and that the running service reports the provider you configured.

  3. Confirm the negotiated key exchange with real clients

    Connect representative clients to a test deployment and confirm that X25519MLKEM768 is the negotiated group. Include the clients your users actually run, such as browsers, mobile apps, SDKs and internal services, because the rustls defaults documentation says some users see unexpected connection failures with this hybrid exchange. Record which clients negotiate it, which fall back to classical groups, and any handshake errors, then check your error logs for the same pattern. The step is done when you have a dated list of tested clients and their results, with any failures reported upstream or tracked internally.

  4. Hold ML-DSA certificates until public web PKI support exists

    Do not switch server certificates to ML-DSA on the basis of the rustls-post-quantum crate or its experimental aws-lc-rs-unstable feature. The rustls 0.23.44 release notes say ML-DSA certificates are not supported in the public web PKI, and the rustls-post-quantum docs describe the ML-DSA variants as experimental. Confirm with your certificate authority and your clients whether they accept ML-DSA certificates before any decision. The check is a written record from the CA and the client owners stating what they accept today.

  5. Separate any FIPS build and confirm its certificate status

    If a service must run in a FIPS-validated configuration, enable the fips feature and install default_fips_provider() as the process default, then confirm the status at run time through ClientConfig::fips() or ServerConfig::fips(). The rustls FIPS guide names FIPS 140-3 certificate #4816 for its use and notes that later aws-lc-rs releases may be covered by later certificates or may be pending. Build FIPS and non-FIPS artifacts separately, because aws-lc-rs does not allow the non-fips and fips features to be combined. The check is a written statement from the vendor or your validation lead naming the certificate that covers the exact version you deploy.

  6. Plan an audit of RustCrypto crates

    Where a service uses the RustCrypto ml-kem, ml-dsa or slh-dsa crates, plan an independent review before production use, since each of their READMEs states the implementation has never been independently audited. Record the exact versions, the algorithms used (for example ML-KEM-768), and the owners responsible for the review. The step is done when the review is scheduled with a named reviewer and the decision on whether to use these crates in production is recorded by the risk owner.

What the sources do not show and what to ask the maintainers

The sources listed on this page leave several points open for the Rust cryptography crates, from post-quantum support in OpenSSL bindings to audit status. Each card names one gap and the question to put to the maintainers or to confirm in the crate's own documentation before you plan an upgrade.

Post-quantum support in the openssl crate

The openssl crate binds to OpenSSL and LibreSSL, and its documentation, as fetched on 2026-12-03, does not mention post-quantum cryptography. The sources do not say whether the crate or the OpenSSL it binds will gain post-quantum algorithms. Ask the maintainers whether post-quantum key exchange or signatures are planned for the openssl crate, and which OpenSSL version would carry them, and confirm the answer against the crate's release notes before you plan builds that depend on it.

openssl crate docs

ML-DSA certificates in the public web PKI

Rustls 0.23.44 enabled ML-DSA certificate support in the aws-lc-rs provider by default, and its release notes state that ML-DSA certificates are not supported in the public web PKI. The sources do not say whether or when public certificate authorities and browsers will accept them. Ask the maintainers what they will require before ML-DSA certificates can be issued and trusted on the public web, and track that answer separately from the library's own support, since a certificate you cannot get publicly trusted does not help a public-facing service.

Rustls releases

Default status of standalone MLKEM768

The rustls defaults page says standalone MLKEM768 is available but not enabled by default out of conservatism, and that X25519MLKEM768 is the hybrid default with the aws-lc-rs provider. The sources do not state when, or whether, standalone MLKEM768 will become a default. Ask the maintainers what conditions would lead them to enable standalone MLKEM768 by default, and confirm the current default in your rustls version before you rely on a particular key exchange in a service.

Rustls defaults

FIPS certificate coverage for later releases

The rustls FIPS guide says its FIPS use is covered by certificate #4816, and that later aws-lc-rs releases may be covered by later certificates or may be pending certification. The sources do not say which aws-lc-rs versions are covered today. Ask the maintainers which exact aws-lc-rs and AWS-LC-FIPS versions carry an active certificate, and when a certificate will cover a release you plan to deploy, and check the certificate status with the issuing module before you claim FIPS coverage in an assessment.

Rustls FIPS guide

Independent audit status of RustCrypto crates

The READMEs for the RustCrypto ml-kem, ml-dsa and slh-dsa crates each state that the implementation has never been independently audited, and the ml-kem README tells users to use it at their own risk. Ask the maintainers whether an independent audit is planned, and whether any audit has been commissioned or completed for these crates, and record the answer in your vendor-risk file. Until an audit exists, treat these crates as unaudited when you document them.

ml-kem README

What can go wrong during the upgrade and what to watch for

The most visible risk in a Rust upgrade to post-quantum key exchange is connection failure. Rustls ships X25519MLKEM768 as the preferred key exchange in the aws-lc-rs provider, and the rustls defaults page warns that some users may see unexpected connection failures with it and asks them to report these to the project. Hybrid key exchange sends a larger key share in the TLS 1.3 ClientHello than classical ECDHE does. Some peers, load balancers and middleboxes handle that larger message poorly, and may reject it, truncate it or fail the handshake. Before rollout, test handshakes against each external endpoint your services call and each internet-facing listener you terminate, and confirm whether any intermediary on the path inspects or rewrites TLS. Keep a rollback path that removes the hybrid group from the provider's key exchange list without a code change elsewhere.

Provider selection is the second risk. Rustls selects cryptography through a CryptoProvider, and a process has at most one implicit default provider set with CryptoProvider::install_default(). Rustls documents that the rustls-ring provider does not support post-quantum algorithms, and version 0.23.48 deprecates rustls::crypto::ring::default_provider() for that reason. A service that builds its configuration with ring, or that inherits ring through a dependency, will not negotiate X25519MLKEM768 even after the crate is updated. The custom-provider feature disables the implicit built-in providers, so confirm for each binary which provider is actually in use at run time, not only which features are listed in Cargo.toml. Note that rustls 0.24 requires an explicit provider, so builds that depend on the implicit default will need changes at that point.

Two further points need checking before any ML-DSA signature is used. The rustls-post-quantum crate offers an aws-lc-rs-unstable feature with three experimental ML-DSA variants, and its docs describe these as unstable. Rustls 0.23.44 enabled ML-DSA certificate support in aws-lc-rs, but states that ML-DSA certificates are not supported in the public web PKI. Treat any build that enables these as experimental, and do not place them in production trust paths without a documented decision. Separately, the openssl crate's vendored feature compiles and statically links its own copy of OpenSSL, and the crate documentation as fetched on 2026-12-03 does not describe post-quantum support. A vendored build therefore carries its own OpenSSL version and update cycle, which must be inventoried and patched separately from the system library. Confirm the vendored version, and whether the binding exposes any post-quantum key exchange, before counting it as supported.

Questions engineers and vendor-risk reviewers ask about Rust post-quantum upgrades

Is Rust quantum safe?

Rust itself is not a single cryptography product, so the answer depends on which crates your application uses. The sources checked for this page show that rustls with the aws-lc-rs provider supports the hybrid key exchange X25519MLKEM768, and that standalone MLKEM768 is available but not enabled by default. Rustls with the ring provider does not support post-quantum algorithms. These are statements about supported algorithms, not about compliance, validation or certification. Nothing checked here establishes that a given deployment is quantum safe, because certificates, signatures and the peers your system talks to also matter. Confirm the exact crate versions and providers in your own dependency tree.

Which rustls version is needed for post-quantum key exchange?

The rustls 0.23.48 release notes state that the aws-lc-rs provider now prefers X25519MLKEM768 key exchange regardless of crate features, with X25519MLKEM768 remaining the first preference. Earlier 0.23.x releases should be checked against the release notes before you assume the same default. The 0.23.44 release notes describe ML-DSA certificate support in the aws-lc-rs provider and say ML-DSA certificates are not supported in the public web PKI. The prefer-post-quantum feature remains for compatibility but now only enables aws_lc_rs. Confirm the version you run with cargo tree and record it in your inventory.

Does a Rust post-quantum upgrade cost extra?

The sources checked here give no prices or effort figures, so none are stated on this page. The main cost drivers are the number of services and crates that link TLS, the amount of code that constructs rustls configurations explicitly, and whether your builds depend on the ring provider, which the 0.23.48 notes deprecate. Costs fall into engineering time to update dependencies and configuration, testing against peers that may fail on X25519MLKEM768, and any FIPS validation work. Ask your team or any outside provider to quote against a written list of crates, services and test cases, and ask which costs are one-time and which recur with each upgrade.

What breaks when you move Rust services to post-quantum key exchange?

The rustls defaults page warns that some users may see unexpected connection failures with X25519MLKEM768 and asks for reports. Peers that do not handle the larger hybrid key share may fail the handshake, so test against each client and server your services talk to. Code that pins the ring provider or calls rustls::crypto::ring::default_provider() will need changes, since that function is deprecated in 0.23.48. Code that assumes the first key share is a classical group may also need review, because the first kx_groups entry determines the key share sent in the TLS 1.3 ClientHello. Signatures and certificates remain classical RSA, ECDSA or Ed25519 unless you change them separately.

What should we ask the Rust crate maintainers before an upgrade?

Ask which provider and version are required for each post-quantum algorithm you plan to use, and whether any default changes in the release you will deploy. Ask whether ML-DSA certificates can be used in your environment, since the 0.23.44 notes say they are not supported in the public web PKI. For the RustCrypto ml-kem, ml-dsa and slh-dsa crates, ask what audit status applies, because their READMEs state they have never been independently audited and should be used at your own risk. Ask whether the FIPS-validated path through aws-lc-rs covers the algorithms you need, and which certificate number and version applies. Record the answers with dates.

Can our team upgrade Rust post-quantum support alone, or do we need outside help?

Teams with strong Rust and TLS experience can often do the core work in house, but the sources checked here do not say how much effort any given upgrade requires. DeployOpen plans, implements, tests and documents self-hosted systems in your infrastructure, and can prepare a fixed-scope engagement covering a crate inventory, provider changes, peer compatibility testing and evidence for your review. Scope, deliverables and timelines are agreed in writing before work starts. DeployOpen does not issue audit reports or certifications, so independent auditors would still need to assess any compliance claim. Pricing follows from the written scope.

How DeployOpen works on this

DeployOpen plans and tests Rust post-quantum upgrades inside the client's own infrastructure, starting from the TLS, provider and crypto crate choices in each service. We scope the written changes, build and test them against the real builds, and hand over documented results with the evidence a security or compliance review needs.

How we scope

  • We inventory which services use rustls, the openssl crate or RustCrypto crates, and which CryptoProvider each one selects.
  • We confirm the Rust toolchain, crate versions and build features each service needs before any change is proposed.
  • The written scope names the services, crates, providers and environments covered, and it is agreed before work starts.

How we build

  • We set the rustls provider explicitly in each application, so the post-quantum key exchange choice is visible in code and configuration.
  • We test X25519MLKEM768 and any standalone ML-KEM or ML-DSA setting in staging, watching for connection failures before production.
  • We check the FIPS feature path where a service needs it, recording the aws-lc-rs and FIPS certificate status the release notes state.

How we hand over

  • Deliverables include a dependency and provider map, the configuration changes made, and the test results from each environment.
  • We record which claims are supported by the vendor or project documentation and which the client must confirm in its own build.
  • We flag unaudited RustCrypto crates and any ML-DSA use outside the experimental feature, so the client can decide on them.

How we support

  • Ongoing support is available as a retainer, covering crate upgrades and rustls release changes after the handover.
  • We retest after each dependency update, since provider defaults and preferred key exchange groups have changed between releases.
  • We keep the evidence current so a security or vendor-risk review can be answered from the records we maintain.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.