Java and OpenJDK post-quantum compatibility with clients and peers

In JDK 27, the TLS 1.3 implementation negotiates the hybrid X25519MLKEM768 group by default whenever the peer also supports it. Older clients, peers and middleboxes can fail, so test before rollout.

On this page

Does Java and OpenJDK negotiate post-quantum key exchange with existing peers?

In JDK 27, TLS 1.3 negotiates the hybrid group X25519MLKEM768 by default whenever the peer also supports it. The sources listed on this page do not say how other JDK releases behave, so operators should not assume the same default applies to any release before 27 without checking that release's own documentation. The JSSE guide and the Inside Java post are the sources for this statement, and the Oracle and OpenJDK pages cited here were read as of December 2026.

This matters most to operators who run Java services that talk to older clients, partner systems or network appliances. Because the client offers both a hybrid key share and a classical x25519 key share, a peer that does not understand the hybrid group should still fall back to classical key exchange, but the sources do not describe how every partner stack will handle that offer. Confirm with each partner or appliance vendor whether it accepts a ClientHello that carries an ML-KEM key share.

Some peers will reject the handshake for reasons unrelated to the key exchange itself. The JSSE guide warns that some TLS implementations do not handle unknown extensions well, and that some servers cap handshake messages at 2^14 bytes, which can break a handshake when jdk.tls.client.enableCAExtension is true and the client trusts many CAs. The guide also says jsse.enableFFDHE and jsse.enableSNIExtension can be set to false for very old implementations that cannot handle extensions. Test these cases in a staging environment before rollout.

To control which groups are offered, use jdk.tls.namedGroups or SSLParameters.setNamedGroups. Setting either to exclude the hybrid group returns the connection to classical groups, which is a supported way to isolate a problem peer. Record which groups each service offers, because that list is the first thing a peer-compatibility review will ask for.

Which hybrid groups and TLS versions apply in JDK 27

This table lists each hybrid group, default behavior, TLS version scope and classical groups still enabled in JDK 27, with the source and date for each row. Use it to confirm which settings your clients and peers will negotiate before you test. The main takeaway is that the default hybrid group is X25519MLKEM768, that the other two hybrids must be enabled explicitly, and that hybrid key exchange is documented only for TLS 1.3.

ItemWhat JDK 27 providesSource and date
Default hybrid groupX25519MLKEM768 is the most preferred named group, so a connection negotiates it whenever the peer also supports itJDK 27 JSSE Guide; Quality Heads-up, 2026-05-17
Additional hybrid group 1SecP256r1MLKEM768, which must be enabled explicitly through jdk.tls.namedGroups or SSLParameters.setNamedGroupsQuality Heads-up, 2026-05-17; JDK 27 JSSE Guide
Additional hybrid group 2SecP384r1MLKEM1024, which must be enabled explicitly through jdk.tls.namedGroups or SSLParameters.setNamedGroupsQuality Heads-up, 2026-05-17; JDK 27 JSSE Guide
TLS version scopeHybrid key exchange is described only under the JDK's TLS 1.3 implementationJDK 27 JSSE Guide
Client key sharesA client sends a hybrid X25519MLKEM768 key share and a classical x25519 key share by defaultJDK 27 Hybrid KEX Post, 2026-02-17; Quality Heads-up, 2026-05-17
Classical groups still listedsecp256r1, secp384r1, secp521r1, x25519, x448 and ffdhe2048 to ffdhe8192 remain in the Named Groups tableJDK 27 Standard Names
TLS signature schemesThe 16 documented schemes are ECDSA, EdDSA and RSA variants, and none is ML-DSAJDK 27 Standard Names
Group customizationSet jdk.tls.namedGroups as a quoted, preference-ordered list, or call SSLParameters.setNamedGroups in code; if the property is undefined or empty, implementation defaults applyJDK 27 JSSE Guide; JDK 27 Hybrid KEX Post, 2026-02-17

Which parts of the handshake change with hybrid key exchange

Hybrid key exchange changes the first messages of a TLS handshake, so the risk sits in what a client offers and what a peer must parse. The cards below cover the key shares Java sends by default, the extension and size behavior that older peers may reject, and the classical signature schemes that remain in JDK 27.

Default key shares sent by clients

By default a JDK 27 client sends two key shares in its ClientHello: a hybrid X25519MLKEM768 share and a classical x25519 share. A peer that supports the hybrid group negotiates it, and a peer that does not can fall back to x25519. Applications that change the enabled groups with jdk.tls.namedGroups or SSLParameters.setNamedGroups should confirm which shares are actually offered. Check the offer with a packet capture against each peer type you run.

Inside Java hybrid post

Unknown extensions and older stacks

The JDK 27 JSSE guide warns that some TLS implementations do not handle unknown extensions properly, so new extensions introduced with hybrid key exchange can cause unexpected interoperability failures. Older or embedded peers are the likely cases. The guide states that jsse.enableFFDHE and jsse.enableSNIExtension can be set to false for very old implementations that cannot handle extensions. Treat those settings as a test-only fallback and confirm each change with the peer's vendor.

JDK 27 JSSE guide

Handshake size limit and CA extension

The JDK 27 JSSE guide says some server implementations do not allow handshake messages larger than 2^14 bytes. Hybrid key shares add size to the ClientHello, and if jdk.tls.client.enableCAExtension is true while the client trusts more CAs than the server accepts, the combined handshake can exceed that limit. Check the handshake size against each server you connect to, and compare the number of trusted CAs in the client truststore with what those servers accept.

Classical signature schemes in JDK 27

The JDK 27 standard names table lists 16 TLS signature schemes, covering ECDSA, EdDSA, RSA PKCS#1 and RSA-PSS, and none of them is ML-DSA. Hybrid key exchange therefore protects the session key, but certificate authentication in the handshake remains classical. Peers that need post-quantum authentication cannot get it from JSSE in JDK 27 alone. Ask each vendor whether ML-DSA or other post-quantum signatures are on its roadmap before you plan certificate changes.

JDK 27 standard names

Named groups peers may not accept

JDK 27 supports three hybrid groups beyond the default: SecP256r1MLKEM768 and SecP384r1MLKEM1024 alongside X25519MLKEM768. Hybrid groups other than the default must be enabled explicitly, so a peer that lacks them will not negotiate them. Limit jdk.tls.namedGroups to the groups your peers actually support, and keep a classical group in the list so connections to older peers still complete.

Quality heads-up

How the outcome differs for clients, servers and legacy peers

When a JDK 27 client connects to a peer that also supports a hybrid named group, the JDK's TLS 1.3 implementation negotiates that group by default. The JDK 27 JSSE guide says the most preferred named group is the hybrid X25519MLKEM768, so a connection to a supporting peer uses it without application changes. The client still offers a classical x25519 key share alongside the hybrid one, so the handshake keeps a classical fallback path.

  • Default preference: X25519MLKEM768 is the most preferred group in JDK 27, according to the JSSE guide.
  • Two key shares: The client sends a hybrid key share and a classical x25519 key share, per the OpenJDK quality heads-up of 2026-05-17.
  • Other hybrids are opt-in: SecP256r1MLKEM768 and SecP384r1MLKEM1024 must be enabled explicitly through jdk.tls.namedGroups or SSLParameters.setNamedGroups.
  • TLS 1.3 only: Hybrid key exchange is described only under the JDK's TLS 1.3 implementation, so connections that negotiate TLS 1.2 do not use it.
  • Peer-side support: The outcome depends on the peer's own configuration, which the sources in this topic do not describe in detail.

Before relying on this case, confirm with a packet capture or a test handshake that the negotiated group matches what your peer should select.

Where the hybrid group is negotiated in a TLS 1.3 handshake

The diagram follows a JDK 27 client through a TLS 1.3 handshake with a peer. The client sends two key shares by default, a hybrid X25519MLKEM768 share and a classical x25519 share, so the peer can pick the hybrid group if it supports one. If the peer does not, the handshake falls back to a classical group. Two points can fail the connection: an unknown or unsupported extension that the peer does not handle, and a handshake message that grows past what some servers accept, which can happen when jdk.tls.client.enableCAExtension is true and the client trusts many CAs. Test both paths against each peer before rollout.

Client key shares and the peer's group selection in a JDK 27 TLS 1.3 handshake.

What to test first before rollout

Work through the sequence in order so that you know which peers and middleboxes can negotiate hybrid key exchange with the JDK, which need a restricted group list, and which fall back to classical groups. The output is a dated, per-peer record you can hand to the operators who own each connection.

  1. Inventory peers and middleboxes that terminate TLS

    List every client, server and peer your Java services connect to or accept connections from, along with any load balancer, TLS inspection proxy or gateway that sits between them and terminates or re-establishes the TLS session. Record each party's owner, the TLS version it is known to use and whether it is internal or external. The step is done when every JDK-facing connection has a named owner and a row in the inventory, and each middlebox that re-terminates TLS is listed as its own hop. The sources on this page do not say which products or versions in your environment support hybrid groups, so leave that column for the next steps to fill in.

  2. Build a JDK 27 early access test environment

    Install a JDK 27 early access build in a non-production environment that matches your application's runtime configuration. The Inside Java post of 2026-02-17 invites testing with early access builds and asks for feedback to the security-dev mailing list, so note the exact build you use. Confirm the build reports the expected version and that its SunJSSE provider lists the hybrid groups. The step is done when a test client and test server built on that JDK complete a TLS 1.3 handshake with each other.

  3. Test each peer against the early access build

    Run a handshake from the JDK 27 test client to each peer in your inventory, and from each peer to a JDK 27 test server where that is possible. Capture the negotiated named group and whether a hybrid group was selected, using the JSSE debug output or your own logging of the session parameters. Record handshake failures and the alert or error text. The JDK 27 JSSE guide notes that some TLS implementations do not handle unknown extensions properly, so treat unexpected failures as a finding to investigate rather than as a pass. The step is done when every peer has a recorded result: hybrid negotiated, classical negotiated, or failed.

  4. Check handshake size limits on constrained servers

    For any server that the JDK 27 JSSE guide describes as unable to accept handshake messages larger than 2^14 bytes, test whether the enlarged hybrid client hello is accepted. The guide says interoperability problems can arise if jdk.tls.client.enableCAExtension is true and the client trusts more CAs than the server limit allows, so test with that property both on and off. The step is done when each size-sensitive peer has a recorded result for both settings. The sources on this page do not give a size threshold for the hybrid client hello itself, so confirm the exact size with the vendor or by capturing traffic.

  5. Set jdk.tls.namedGroups where peers need a restricted list

    For any peer that fails or behaves unexpectedly with the default groups, set jdk.tls.namedGroups to a quoted, comma-separated list in preference order, such as the example in the JDK 27 JSSE guide. Use a list that includes only the groups that peer handles, and keep a classical group in the list so the handshake can complete. Alternatively, call SSLParameters.setNamedGroups in code for a specific connection. The step is done when each restricted peer has a documented group list, the reason for it, and a passing handshake using that list. Remember that hybrid groups other than the default must be enabled explicitly.

  6. Confirm fallback to classical groups

    Test each peer in a configuration where the hybrid groups are removed from the list, and confirm the handshake completes with a classical group such as x25519 or secp256r1. Separately, test that the JDK falls back correctly when a peer offers no hybrid group at all. The Quality Outreach heads-up of 2026-05-17 says clients offer both a hybrid key share and a classical key share, which you can use to check what the peer actually selects. The step is done when every peer shows a successful classical handshake and a recorded fallback path, and any peer that refuses the classical fallback is escalated to its owner.

  7. Record results and close the test cycle

    Write one dated record per peer and per middlebox, with the JDK 27 early access build identifier, the groups tested, the negotiated group, any jdk.tls.namedGroups or SSLParameters setting applied, the handshake outcome and the owner's sign-off. Keep the record with your cryptographic inventory and mark any entry that depends on a vendor statement you have not verified. The step is done when every inventory row has a result and an owner has reviewed the entries that failed or fell back. Use this record to decide which connections are ready for rollout and which need a vendor answer first.

Questions engineers and vendor-risk reviewers ask about Java hybrid TLS

Does the Java hybrid key exchange group make a Java service quantum safe?

No. The sources only show that the JDK 27 TLS 1.3 implementation can negotiate hybrid key exchange groups that combine ML-KEM with classical ECDHE, so key exchange is partly protected against future quantum attack. The sources do not say that the service is quantum safe. TLS signatures and certificates in JDK 27 remain classical: the documented TLS signature schemes are all ECDSA, EdDSA or RSA variants, with no ML-DSA. Confirm with the JDK vendor or your distribution which parts of your service use hybrid groups, which still use classical public keys, and whether your certificate chain and peers are covered. Treat the result as a partial improvement to key exchange, not a finished migration.

Which JDK version do I need for hybrid TLS key exchange?

The sources document the hybrid groups in the JDK 27 JSSE guide and the JDK 27 standard names specification. An early access JDK 27 build is the version the project pointed to for trying the feature in its February 2026 post, and the May 2026 quality heads-up says JDK 27 enables X25519MLKEM768 alongside the existing classical groups. The sources do not say which earlier releases or LTS updates include this support. Standalone ML-KEM and ML-DSA are documented from JDK 24, but that does not mean the TLS hybrid groups are available there. Confirm the first release and update that ships TLS hybrid groups with your JDK distributor before you plan a rollout.

Does Java hybrid TLS cost extra to run?

The sources do not give any price or licensing terms for the hybrid groups, and they do not say whether any part of the feature is limited to a paid edition. The feature is part of the standard JDK TLS implementation as described in the JDK 27 guide. The cost you will actually pay comes from testing, updating your JDK build and runtime, reviewing peers that may not support the groups, and changing configuration in your own environment. Those costs are one-time for the first rollout and recur with each JDK update. Ask your JDK distributor whether support contracts change for JDK 27 and whether any feature requires a commercial license. Ask DeployOpen for a fixed-scope quote based on your estate, since DeployOpen does not publish a price list.

What breaks in Java TLS when middleboxes or older peers see hybrid key shares?

The JDK 27 guide warns that some TLS implementations do not handle unknown extensions properly, so new extensions can cause unexpected interoperability problems. The client also sends two key shares by default, X25519MLKEM768 and x25519, so a peer or middlebox that parses the key share strictly may fail the handshake. The guide also says some servers cap handshake messages at 2^14 bytes, and interoperability issues can appear when jdk.tls.client.enableCAExtension is true and the client trusts more CAs than the server limit allows. For very old implementations that cannot handle extensions, the guide says jsse.enableFFDHE and jsse.enableSNIExtension can be set to false. The sources do not say which middlebox products fail, so test your own path. Start with a handshake capture on a staging listener and a client on the same network path.

How do I restrict hybrid groups with jdk.tls.namedGroups or SSLParameters.setNamedGroups?

Set jdk.tls.namedGroups to a comma-separated, quoted list of enabled groups in preference order, for example "X25519MLKEM768,secp521r1,secp256r1,ffdhe2048". If the property is undefined or empty, the implementation default groups and preferences apply. In code, call SSLParameters.setNamedGroups(String[]) and read the active list with getNamedGroups(). The two approaches are alternatives, and the Inside Java posts name both as ways to customize the enabled hybrid groups. The JDK 27 guide also shows that hybrid groups other than the default, such as SecP256r1MLKEM768, must be enabled explicitly. To keep only classical groups, list them without any hybrid name. Verify the resulting list with the logs or by reading getNamedGroups() at runtime, and test each peer you serve.

Can my team test Java hybrid TLS ourselves, or do we need outside help?

Your team can test it. The sources point to JDK 27 early access builds for trying the feature and to the security-dev mailing list for feedback, and the JDK 27 guide gives the property and API names you need for configuration. A practical first test is a staging server and client on a JDK 27 build, with a handshake capture, a list of the peers and middleboxes that must still work, and a check of the negotiated group with each named-group setting. Outside help is useful when the estate is large, when many peers and middleboxes must be reviewed, or when you need an independent record of the results for an assessment. DeployOpen can plan, configure and document this testing in your own infrastructure as a fixed-scope engagement, with scope and deliverables agreed in writing before work starts. DeployOpen does not issue audit reports, and DeployOpen is not a partner or certified provider of Oracle or any JDK vendor.

Do Java and OpenJDK hybrid groups protect certificates and signatures too?

The sources show that the hybrid groups protect key exchange only. The JDK 27 standard names specification lists 16 TLS signature schemes, covering ECDSA, EdDSA and RSA PKCS#1 and RSA-PSS variants, and none of them is ML-DSA. So a hybrid key exchange does not make your server certificate or the signatures in the handshake post-quantum. Certificates, keystores and jarsigner signatures need separate review. The keytool and jarsigner pages document ML-DSA key handling, but the sources do not say that the TLS stack can use ML-DSA certificates. Confirm with the JDK project or your distributor before you assume any certificate change is supported.

What the sources do not cover for older releases and peers

The sources listed on this page describe hybrid key exchange in JDK 27 and the Bouncy Castle 1.81 release. They do not settle how older JDK releases behave, how specific middleboxes handle the handshake, or whether ML-DSA can be used in TLS signatures. Each gap below names what to ask the vendor or project before you rely on a configuration.

Behaviour before JDK 27

The sources on this page document the hybrid groups X25519MLKEM768, SecP256r1MLKEM768 and SecP384r1MLKEM1024 for JDK 27. They do not say whether any earlier release, including current LTS lines, enables these groups or accepts them in the same way. Ask Oracle or your JDK supplier which releases and update levels provide the hybrid groups, and whether a patch level is needed. Until that is confirmed, do not assume a JDK 17 or JDK 21 estate negotiates hybrid key exchange.

JDK 27 JSSE guide

Middlebox interoperability results

The JSSE guide warns that some TLS implementations mishandle unknown extensions, and that some servers cap handshake messages at 2^14 bytes, which can break connections when a client trusts many CAs. The sources do not report tested results for specific load balancers, inspection proxies or firewalls. Ask each middlebox vendor whether its TLS stack accepts the larger key shares that hybrid groups send, and test with a representative path before rollout.

JDK 27 JSSE guide

ML-DSA in TLS signatures

ML-DSA is listed as a standalone Signature algorithm for parameter sets 44, 65 and 87 in JDK 24 and JDK 27. The JDK 27 Named Groups and TLS signature scheme tables list no ML-DSA scheme, so the documented TLS signature schemes remain classical. The sources do not say when, or whether, ML-DSA will be added to TLS signature schemes. Ask Oracle or the OpenJDK project for a committed timeline and whether the change is planned for an LTS line.

JDK 27 standard names

Peers outside the Java stack

The Bouncy Castle 1.81 announcement says its BCJSSE hybrid cipher suites interoperate with OpenSSL and BoringSSL environments configured for these suites. The sources do not test the JDK's SunJSSE hybrids against those peers, or against other libraries. Ask each peer's maintainer which hybrid groups it offers by default, and run a handshake test with the group list you intend to enable before assuming the connection will negotiate.

BC 1.81 release

What can go wrong with hybrid key exchange in Java services

Hybrid key exchange can fail in Java services in ways that look like ordinary TLS errors, so the first thing to check is whether a peer will complete a handshake that carries new extensions. The OpenJDK JSSE reference guide for JDK 27 warns that some TLS implementations do not handle unknown extensions properly, so interoperability problems can appear when the JDK introduces new ones. The same guide says that very old implementations that cannot handle extensions may need jsse.enableSNIExtension or jsse.enableFFDHE set to false. Test each outbound and inbound peer with a handshake before changing defaults, and treat a failure as a signal to find the specific extension rather than a reason to disable hybrid groups everywhere.

A second risk is handshake size. The JDK 27 guide says some server implementations do not allow handshake messages to exceed 2^14 bytes, and that interoperability issues may arise if jdk.tls.client.enableCAExtension is true and the client trusts more certificate authorities than the server limit allows. Because a hybrid key share adds data to the ClientHello, a truststore that already sits near the limit may fail only after the upgrade. Confirm the size of the trusted CA list for each client, and check whether the peer's TLS stack documents a message size limit before you enable the feature on that path.

Two settings deserve an audit before rollout. The guide says jdk.tls.client.cipherSuites and jdk.tls.server.cipherSuites override the default enabled cipher suites and can configure weak suites, so a legacy value copied from an old configuration file can quietly weaken the connection. Hybrid groups are also only negotiated when the peer offers one. The guide says the default preference is X25519MLKEM768, but a peer that offers only classical groups will get a classical handshake, not an error. Check the negotiated group in logs or with a test client so you can see which connections really use hybrid key exchange, and confirm that a classical fallback is acceptable to your policy.

How DeployOpen helps plan and test Java post-quantum rollouts

DeployOpen approaches Java and OpenJDK compatibility as a test-first exercise. JDK 27 enables the hybrid X25519MLKEM768 group by default, so a client negotiates it whenever the peer supports it, and older clients, peers and middleboxes are where unexpected handshake failures tend to surface. We scope and test those connections before any setting is changed in production.

How we scope

  • We list every TLS endpoint, client and peer that a Java service talks to, including partners and middleboxes outside your control.
  • We identify which peers can handle the JDK 27 hybrid key share and which may need the classical x25519 fallback.
  • Engagements are fixed-scope, and the written scope states exactly which Java and OpenJDK versions and endpoints it covers.

How we build

  • We build a test harness that runs the JDK 27 client and server against representative peers, and records the negotiated named group.
  • We check the jdk.tls.namedGroups and SSLParameters.setNamedGroups settings, and confirm that the enabled groups match the peers in scope.
  • We test known interoperability risks, such as unknown-extension handling and the 2^14-byte handshake limit on certificate chains.

How we hand over

  • We deliver a compatibility matrix showing each peer, the JDK version tested, the group negotiated and the observed result.
  • We document the configuration used, including any jdk.tls.namedGroups value and any fallback settings, so your team can reproduce the results.
  • We record the open items to confirm with each vendor or peer owner before the change goes to production.

How we support

  • Ongoing support is available as a retainer, covering retesting after JDK upgrades and changes to peers or middleboxes.
  • We can rerun the compatibility matrix when a new JDK build or early access release changes the default group behavior.
  • We can help your team decide how to phase the change, for example by limiting hybrid groups to peers already confirmed.

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.