Repository navigation
Pq fs 2026 part4 lab prep fixes and x25519 - #11980
Open
kaleb-himes wants to merge 10 commits into
Open
kaleb-himes wants to merge 10 commits into
kaleb-himes wants to merge 10 commits into
Conversation
|
kaleb-himes
force-pushed
the
PQ-FS-2026-Part4-LabPrep-fixes-and-x25519
branch
from
November 3, 2026 23:34
ac631d2 to
94d2e79
Compare
kaleb-himes
force-pushed
the
PQ-FS-2026-Part4-LabPrep-fixes-and-x25519
branch
from
November 4, 2026 12:06
8e73300 to
a09ae09
Compare
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
The FIPS v7 boundary and hybrid-combiner changes require specialist validation against licensed wrapper sources absent from this snapshot and actual Zephyr linker and integrity-test behavior.
No open issues 🎉
1 resolved since last review
Review effort: Balanced
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
X25519 and X448 are opt-in and built past wolfcrypt_last.c, outside the v7 module boundary, in autotools and in Zephyr. They aren’t module algorithms. Combined with ML-KEM in the TLS 1.3 hybrid groups, the shared secrets go through the module’s HKDF, which is an approved key combiner (SP 800-227 §4.6.2; FIPS 140-3 IG D.S, Scenario 2, “Approved Key Combiner”: HKDF qualifies through SP 800-56C). FIPS builds don’t offer plain X25519/X448 by default.
The module now joins the hybrid shared secrets. The new wc_Tls13_HybridSharedSecret() in kdf.c puts the ML-KEM and ECDH secrets in the order draft-ietf-tls-ecdhe-mlkem-03 §4.3 fixes for each group. In FIPS builds it allows only SecP256r1MLKEM768, X25519MLKEM768 and SecP384r1MLKEM1024 (§7 code points), with their fixed order and sizes. This meets IG D.S Scenario 2 items 4 (pre-defined hybrid sets) and 5 (the module controls the shared-secret ordering), which the KEM-Hybrid claim requires. tls.c calls it only when kdf.h defines WOLFSSL_HAVE_TLS13_HYBRID_SECRET, so FIPS v5/v6 builds with their frozen kdf.h keep today’s code.
ML-KEM: a key whose key-pair test can’t finish is freed, so an untested key can’t be used (ISO/IEC 19790:2012 §7.10.3.3: every generated key pair gets a consistency test).
ML-DSA: WOLFSSL_MLDSA_SIGN_CHECK_Y/_W0 are refused in FIPS builds. Their extra rejections change the signature FIPS 204 Algorithm 7 produces.
Fixes zd#
Testing
Item 4 control: SecP256r1MLKEM512 and X448MLKEM768, built with --enable-experimental --enable-extra-pqc-hybrids, are refused with -173.
Item 5 control: with tls.c’s order for SecP256r1MLKEM768 flipped, the module refuses it (-173).
Checklist