Skip to content

Replace V523_NONFIPS_SHAKE path reference to shake.c/h - #11900

Open
rlm2002 wants to merge 1 commit into
wolfSSL:masterfrom
rlm2002:fipsV5customSHAKEPQ
Open

rlm2002 wants to merge 1 commit into
wolfSSL:masterfrom
rlm2002:fipsV5customSHAKEPQ

Conversation

@rlm2002

@rlm2002 rlm2002 commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

Description

PR #11831 added an opt-in V523_NONFIPS_SHAKE to enable SHAKE 128/256 algorithms. The path to the new files was incorrect.

Replace path to fips/v5.2.3-custom-shake-pq/<shake.c/h> to reference wolfcrypt/src/shake.c and wolfssl/wolfcrypt/shake.h. Removes reference to fips/ which is not included in release process.

Also fixes error message for V523_NONFIPS_SHAKE to reference v5.2.3 and correct cert.

Testing

./configure --enable-fips=v5 --enable-mlkem --enable-mldsa CFLAGS=-DV523_NONFIPS_SHAKE
make
./fips-hash.sh  
make
./wolfcrypt/test/testwolfcrypt 

@rlm2002 rlm2002 self-assigned this Oct 26, 2026
Copilot AI balanced review requested due to automatic review settings October 26, 2026 23:21

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

The intended FIPS target needs maintainer confirmation because the diagnostic and eligibility checks specify different versions.

1 open issue
What changed in this PR

Updates the V523_NONFIPS_SHAKE integration introduced in #11831 to use standard wolfSSL paths instead of the internal fips/ directory, which is omitted from releases.

Changes:

  • Updates SHAKE header references across library code, tests, and benchmarks.
  • Adjusts configure checks and Automake build/install paths.
  • Revises the prerequisite diagnostic to name FIPS 5.2.3 and certificate #5548.
File Description
wolfssl/​wolfcrypt/​wc_mlkem.h Updates the SHAKE include while preserving include order.
wolfssl/​wolfcrypt/​wc_mldsa.h Uses the standard SHAKE header path.
wolfssl/​wolfcrypt/​settings.h Revises the FIPS prerequisite diagnostic.
wolfssl/​wolfcrypt/​include.am Updates the SHAKE header installation path.
wolfcrypt/​test/​test.c Updates the self-test SHAKE include.
wolfcrypt/​src/​wc_mldsa.c Updates the ML-DSA SHAKE include.
wolfcrypt/​src/​hash.c Updates the hashing SHAKE include.
wolfcrypt/​src/​asn.c Updates the ASN.1 SHAKE include.
wolfcrypt/​benchmark/​benchmark.c Updates the benchmark SHAKE include.
tests/​api/​test_sha3.c Updates the API-test SHAKE include.
src/​include.am Builds SHAKE from wolfcrypt/src/shake.c.
configure.ac Checks the new overlay paths and updates related guidance.

Review effort: Balanced

Comment thread wolfssl/wolfcrypt/settings.h Outdated
#if defined(V523_NONFIPS_SHAKE) && \
(!defined(HAVE_FIPS) || !FIPS_VERSION3_EQ(5,2,1))
#error "V523_NONFIPS_SHAKE requires FIPS v5 cert4718 (5.2.1)"
#error "V523_NONFIPS_SHAKE requires FIPS v5 cert #5548 (5.2.3)"
references to shake.c/h updated to wolfcrypt/ and wolfssl/wolfcrypt/. The fips directory is not included in FIPS bundles
Use Cert wolfSSL#5548, v5.2.3 in error message
@rlm2002
rlm2002 force-pushed the fipsV5customSHAKEPQ branch from 9598dc9 to 7052b51 Compare October 27, 2026 15:39
@rlm2002 rlm2002 assigned wolfSSL-Bot and unassigned rlm2002 Oct 27, 2026
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