Skip to content

Conversation

@bifurcation
Copy link
Contributor

@bifurcation bifurcation commented Nov 12, 2025

First draft, using a libOQS in a submodule.

This PR adds support for the ML-KEM KEM for HPKE, which requires SHAKE256 for DeriveKeyPair. Support for the underlying primitives is not uniform, so the approaches are different per-library:

  • OpenSSL 1.1 - We include a vendor copy of liboqs as a git submodule (under third-party), and use its ML-KEM implementation
  • OpenSSL 3 - This library supports both ML-KEM and SHAKE256, so we just use it
  • BoringSSL - BoringSSL supports ML-KEM, but not SHAKE256, and there's no obvious polyfill, so we disable ML-KEM support when using BoringSSL.

@bifurcation bifurcation marked this pull request as ready for review November 14, 2025 19:11
Copy link
Contributor

@suhasHere suhasHere left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me.

@bifurcation
Copy link
Contributor Author

bifurcation commented Nov 18, 2025

vcpkg does have a port file for liboqs, but it's on an old version that doesn't support deterministic ML-KEM key generation. I have submitted a PR on vcpkg to update the port. I think we should hold this PR until that lands and we can use libOQS from the environment (e.g., via vcpkg) instead of building it ourselves.

@bifurcation bifurcation merged commit 6a0b31e into main Nov 20, 2025
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants