Commit Graph
784 Commits
Author SHA1 Message Date
David GarskeandGitHub 56e92ea0dc Merge pull request #10947 from night1rider/benchmark-msvc-arm64
benchmark: build the AArch64 cycle counter under MSVC/ARM64
2026-07-31 14:23:26 -07:00
Sean ParkinsonandGitHub c78f35725b Merge pull request #10343 from MarkAtwood/feat/sbom-bomsh
feat: SBOM generation and OmniBOR build provenance (CRA compliance)
2026-07-27 21:28:22 +10:00
night1rider 59c79512e3 benchmark: build and run the wolfCrypt benchmark in Windows ARM64 CI 2026-07-24 16:42:44 -06:00
JacobBarthelmehandGitHub acff4d62a1 Merge pull request #10883 from night1rider/Extend-ECIES
Add AES-GCM DEM, CryptoCb support, and devId threading to ECIES
2026-07-24 14:02:32 -06:00
night1rider c00e7260be Add AES-GCM DEM, CryptoCb support, and devId threading to ECIES
Add AES-GCM (128/256) as an ECIES DEM next to the AES-CBC/CTR+HMAC modes. Only the encryption key comes from the KDF; the mac salt is bound as GCM AAD and the 16-byte tag replaces the HMAC. The GCM DEM honors all three IV build modes, and default fixed-nonce GCM is gated behind the new WOLFSSL_ECIES_STATIC_GCM_NONCE opt-in. Adds ECIES CryptoCb encrypt/decrypt, the WOLF_CRYPTO_CB ctx getters, devId/heap threading into the DEM primitives, and test/benchmark/CI coverage.
2026-07-24 10:19:40 -06:00
Mark Atwood be9963f392 sbom: drop liboqs dependency support (removed from wolfSSL)
wolfSSL removed liboqs: Falcon is now provided natively by wolfCrypt, and
--with-liboqs is a deprecated no-op (configure.ac). A build therefore no
longer links liboqs, so recording it as an SBOM dependency is dead code and
the SBOM integration CI (which asserted a liboqs dep package) failed.

Remove the liboqs dependency throughout:
- scripts/gen-sbom: drop DEP_META['liboqs'] and the --dep-liboqs flag.
- Makefile.am / configure.ac: drop --dep-liboqs "$(ENABLED_LIBOQS)" and the
  now-unused AC_SUBST([ENABLED_LIBOQS]).
- .github/workflows/sbom.yml: drop the liboqs install / --with-liboqs steps
  and the liboqs dep assertion; keep the native-Falcon build so the
  HAVE_FALCON build-property capture is still exercised.
- scripts/test_gen_sbom.py: drop the liboqs-specific tests, guard against
  the key reappearing, and use openssl as the example dep elsewhere.
- doc/SBOM.md: drop the --dep-liboqs / liboqs dependency references.
2026-07-23 22:32:50 -07:00
Sameeh JubranandMark Atwood d08282ff9a sbom: use docdir, portable version parse, and widen CI filter
Use Automake's $(docdir) for sbomdir so a --docdir override is honoured,
match tab/space in the wolfSSL version parse ([[:space:]]), document the
GNU-make requirement and the intentional install/uninstall-sbom
asymmetry, and widen the SBOM workflow pull_request filter to '**' so PRs
onto release/** base branches also run.

Signed-off-by: Sameeh Jubran <sameeh@wolfssl.com>
2026-07-23 21:51:26 -07:00
Sameeh JubranandMark Atwood 5ab0ad9fab sbom: address advisory/SBOM review findings
- gen-advisory: honour explicit per-version status when defaultStatus is
  "affected", so unaffected/fixed releases are no longer marked vulnerable
- gen-advisory: fail loudly when a CVE record has no non-empty English
  description (CSAF/CycloneDX note text is required, minLength 1)
- gen-advisory: note that --cve-id fetches from the CVE Services API
- bomsh_verify: scope the object-store shape check to sha1, matching the
  sha1 gitoid hashing (drop the unreachable sha256-length branch)
- Makefile.am: fail `make bomsh` early when python3/pyspdxtools are absent;
  quote $(ENABLED_LIBZ)/$(ENABLED_LIBOQS); consolidate clean-local so the
  omnibor/ and advisories/out/ build dirs are removed on clean
- tests: cover the defaultStatus fix, the _bucket_for unknown-state
  hard-fail, and a csaf_validate.mjs runner self-test wired into CI

Signed-off-by: Sameeh Jubran <sameeh@wolfssl.com>
2026-07-23 21:51:26 -07:00
Sameeh JubranandMark Atwood 4ec80d309a feat: SBOM generation and OmniBOR build provenance (CRA compliance)
Add tooling to produce Software Bills of Materials and build provenance
for wolfSSL, supporting EU Cyber Resilience Act (CRA) obligations.

SBOM generation:
- New `make sbom` target producing SPDX 2.3 output with NTIA minimum
  elements, urn:uuid document namespaces, and SPDX LicenseRef compliance.
- Reproducible library discovery across autotools and CMake builds, with
  liboqs recorded as a linked artefact.
- Standalone `scripts/gen-sbom` for embedded / RTOS / custom-builder
  flows that do not use the main build system, plus --srcs-file,
  --no-artifact-hash, and hash-source options.

Build provenance (OmniBOR / bomsh):
- End-to-end bomsh tracing of the built binaries with ArtifactID
  insertion, snapshotting the traced library before libtool relink and
  hashing the bomsh-traced binary.
- `scripts/bomsh_verify.py` to validate provenance against the traced
  gitoid.

Security advisories:
- `scripts/gen-advisory` generating CSAF 2.0 and CycloneDX VEX, with a
  `make` target, VEX overlay schema/example, and CWE name data.

Docs, tests, and CI:
- doc/SBOM.md and doc/CRA.md, plus README/INSTALL updates.
- Unit and regression tests for gen-sbom and gen-advisory.
- New sbom.yml and advisory.yml workflows: SPDX validation via
  pyspdxtools, CSAF validation, bomsh provenance verification, SBOM
  artifact archiving, macOS coverage, and actions pinned to SHAs.

Signed-off-by: Sameeh Jubran <sameeh@wolfssl.com>
2026-07-23 21:51:26 -07:00
Sean ParkinsonandGitHub e23054ca9e Merge pull request #10931 from julek-wolfssl/socat-ci-hang-fix
socat CI: prevent rare shard hang in inverted OPENSSL tests
2026-07-24 10:45:20 +10:00
Sean ParkinsonandGitHub 00c9405c24 Merge pull request #10969 from Frauschi/ci_flakyness_fixes
CI: reduce flakiness in the libssh2, trackmemory, and socat jobs
2026-07-24 10:41:54 +10:00
Sean ParkinsonandGitHub f7571db708 Merge pull request #10896 from julek-wolfssl/julek-dev/openvpn-set0-crls
X509_STORE_CTX_set0_crls: implement for OpenVPN
2026-07-24 10:18:40 +10:00
Sean ParkinsonandGitHub e6c3bb4403 Merge pull request #10827 from danielinux/falcon-native
Falcon: native implementation replacing liboqs, with crypto callbacks and ARM acceleration. Deprecate liboqs support.
2026-07-23 21:17:10 +10:00
Brett NicholasandGitHub e6d86b4bbb Merge pull request #10832 from padelsbach/curve25519-cryptocb-only
Add crypto callback only mode for curve25519
2026-07-22 17:35:55 -06:00
David GarskeandGitHub 983e1090d7 Merge pull request #10922 from aidangarske/fenrir-asn-strict
Enforce RFC 5280 extension MUSTs under WOLFSSL_NO_ASN_STRICT and validate DTLS 1.3 legacy_session_id echo
2026-07-22 14:12:33 -07:00
Tobias Frauenschläger adb0da74a9 Tolerate timing-flaky non-TLS socat tests via expect_fail
A few socat core tests intermittently fail the interop job with diff or
timeout mismatches. They exercise socat's own system()/socket/exec-pty
plumbing, not the wolfSSL backend, and race under the deliberate CPU
oversubscription of the parallel shard scheduling. With parallel-make-check
running fail-fast, one such flake in any shard aborts the whole job.

Add the observed offenders to the per-version socat test.sh --expect-fail
list: 23 (DUALSYSTEMFDSFLUSH) on 1.8.0.3, and 205 (TCP4ENDCLOSE) and 227
(EXECPTYKILL) on 1.8.0.0. test.sh keys its exit status only on unexpected
failures, so a listed test that later passes is reported as "OK unexpected"
and does not fail the job. Numbers come from each version's own test output,
so they match that version's numbering.
2026-07-22 16:51:31 +02:00
Tobias Frauenschläger c5518f2c18 Correct stale make-check timing weights in trackmemory CI
parallel-make-check.py schedules configs longest-first by their "minutes"
weight, but five of the seven trackmemory configs were weighted well below
their real runtime, which the run summary flags every time ("ran X min but
minutes says Y (>50% off)"). The underweighted configs include the two
wolfEntropy jitter configs, whose runtime already varies severalfold with
runner contention. Scheduling them last, on stale short weights, is what
lets a contended run drift into the 40-minute timeout.

Update the five flagged weights to the durations reported by the run
summary and re-sort the list descending so the slowest, most variable
configs start in the first scheduling wave and get the full time budget.
Config coverage is unchanged.
2026-07-22 15:26:36 +02:00
Tobias Frauenschläger ae1ea4079b Retry flaky libssh2 Docker tests with make recheck
The libssh2 integration tests start a fresh OpenSSH-server container per
test with "docker run -d -p 22" and then immediately open the SSH
connection. Docker maps the port as soon as the container starts, so the
TCP connect succeeds before sshd inside the container is ready to send its
banner, and the handshake fails with "Failed getting banner" (-43). This
shows up as an intermittent failure of a single test, most often
test_read, on unrelated pull requests.

Fall back to "make recheck" when "make check" fails. The automake parallel
test harness re-runs only the tests that did not pass, so a transient
container-readiness race no longer fails the job while a genuine failure
still does.
2026-07-22 15:07:46 +02:00
Juliusz Sosinowicz ccc8068b05 X509_STORE_CTX_set0_crls: implement for OpenVPN
OpenVPN master keeps CRLs in its own stack and passes them to each
verification with X509_STORE_CTX_set0_crls from its cert verify
callback. CRLs are no longer loaded into the store.

- Add wolfSSL_X509_STORE_CTX_set0_crls. The ctx borrows the stack.
- Check the ctx CRLs in X509StoreVerifyCert. They can revoke a cert the
  CertManager accepted and can satisfy the CRL requirement when the
  CertManager has no CRL loaded. The check runs after the date override
  handling so that a revocation is not masked by an overridden date
  error. A stale CRL in the stack does not fail the check when another
  CRL vouches for the cert.
- Add CheckCertCRLFromCm to check a cert against a caller-owned CRL
  using the cm of the store for CRL signature verification. The CRL
  object is not modified and the cached verification result of the
  entries is not used because it is only valid for the owning cm.
- Pass the good result of the cert verify callback to the following
  verify callbacks in DoVerifyCallback. In OpenSSL the cert verify
  callback replaces chain verification so the verify callbacks only see
  its result. OpenVPN needs this to run its per-cert verification.
- Re-add OpenVPN master to CI testing.
2026-07-22 13:31:03 +02:00
Juliusz Sosinowicz b0c0ceed3d socat.yml: assert retry=2 pattern before patching test.sh
Fail the shard loudly if socat's test.sh no longer contains the
fork,retry=2 pattern, instead of letting sed silently no-op and
reintroduce the hang while the run still looks green.
2026-07-22 13:30:12 +02:00
Juliusz Sosinowicz 2ed0369ecc socat.yml: tighten comment 2026-07-22 13:30:12 +02:00
Juliusz Sosinowicz 95b9dd653a socat.yml: prevent rare shard hang in inverted OPENSSL tests
The inverted testserversec OPENSSL tests (OPENSSLCERTCLIENT, the
commonname test and the fips test) run a foreground one-shot SSL
listener with no port-wait; their background connector exits after 2s
(retry=2, 1s apart). On a loaded runner the listener can bind after the
connector is already gone and then blocks in accept() forever, stalling
the shard until the job-level 15-minute timeout kills the run with no
diagnosable output. Seen once on a run whose re-run passed; reproduced
deterministically by delaying the listener past the retry budget.

- Widen the connector budget to retry=30. Retries only happen while the
  listener is not yet up and testserversec kills the connector as soon
  as the client returns, so passing runs are unaffected.
- Bound each shard with timeout(1) at 10 minutes (normal shard time is
  ~2 min) so any future hang fails fast and the shard output names the
  test that was running.
2026-07-22 13:30:12 +02:00
Daniele Lacamera 1a867244ed Falcon: CI-test every selectable backend, not just the default
The Falcon workflow only built --enable-falcon (default integer fpr). Add a
falcon_backends matrix that builds and runs testwolfcrypt for asm, double, avx2,
small-mem and avx2+small-mem on ubuntu-latest, and neon on the free ubuntu-24.04-arm
runner -- the SIMD/asm backends are the highest-risk code and now execute in CI.
verify-only is a build/link-only leg (its self-test needs signing). An AVX2 leg
guards on /proc/cpuinfo since backend dispatch is compile-time.
2026-07-22 09:52:27 +02:00
Daniele Lacamera 9e21ed4799 Falcon: fix liboqs interop workflow wiping the liboqs install
The falcon_interop job restored/untarred liboqs into the workspace and only
then ran actions/checkout, whose "git clean -ffdx" deleted the untracked
oqs-install/ directory. The interop harness build then failed with
"oqs/oqs.h: No such file or directory".

Move the wolfSSL checkout ahead of the cache-restore / artifact-download /
untar steps so the liboqs install lands after the clean and survives.

The harness itself is fine: built locally against liboqs it passes all eight
interop cells (liboqs<->native, both directions, levels 1 and 5).
2026-07-22 09:52:26 +02:00
Daniele Lacamera f2d79b554e Falcon: fix codespell and source-text CI checks
- codespell.yml: add "fpr"/"FPR" to ignore_words_list. "fpr" is the Falcon
  reference's canonical name for the floating-point primitive seam and
  appears hundreds of times across the sources; it is not a typo.
- wc_falcon.c: rename local "clen" -> "compLen" (codespell flagged clen)
  and replace a non-ASCII em-dash in a comment with "--" (check-source-text
  8-bit byte violation).
- wc_falcon_bigint.c: fix typos "morever" -> "moreover", "Mutiply" ->
  "Multiply".
- wc_falcon_codec.c: reword "are statics in" -> "are static functions in"
  (codespell flagged "statics").
2026-07-22 09:52:26 +02:00
Daniele Lacamera effc05a171 Falcon: remove FN-DSA / FIPS 206 references from code comments and text
Scrub the temporary "FN-DSA" name and the "FIPS 206" designation from all
in-tree comments, build text, and message strings, leaving the algorithm
named only as "Falcon". The eventual standardized name is not announced.

The differential known-answer test message ("wolfSSL FN-DSA differential
KAT") is a signed input, so the Falcon-512/1024 public keys and signatures
in wolfcrypt/test/test.c (and the mirrored Falcon-512 vector in
IDE/m33mu-falcon-verify/kat.h) were regenerated with liboqs over the new
message "wolfSSL Falcon differential KAT", preserving the differential
property (liboqs-produced signatures verified by the native verifier).

Verified: testwolfcrypt Falcon test passes; the m33mu verify-only harness
passes (BKPT 0x7f) with the regenerated vector.
2026-07-22 09:52:26 +02:00
Daniele Lacamera 509b29bc9c Remove liboqs dependency
Falcon was the last algorithm backed by liboqs; now that wolfCrypt has a
native Falcon implementation, liboqs is no longer needed. Remove the
integration entirely so liboqs does not appear as a build or SBOM dependency:

  - configure: drop --with-liboqs (and the -loqs link), the BUILD_LIBOQS
    conditional and the summary line.
  - CMake: drop WOLFSSL_OQS, the duplicate liboqs-backed WOLFSSL_FALCON
    option, the OQS cross-validation / find_package(OQS) block, the
    FindOQS.cmake module, BUILD_OQS_HELPER, and HAVE_LIBOQS from options.h.in.
  - Remove the wolfcrypt/src/port/liboqs port layer (liboqs.c/.h) and its
    wolfSSL_liboqsInit/Close calls in wc_port.c.
  - settings.h: drop HAVE_LIBOQS from the asym key import/export aggregates
    (HAVE_FALCON already covers them) and from the experimental gate; add
    HAVE_FALCON to the experimental gate so the unstandardized Falcon requires
    WOLFSSL_EXPERIMENTAL_SETTINGS in every build system.
  - Drop liboqs.c from the VS/Zephyr/INTIME project files, remove the liboqs
    install from Docker, and update INSTALL/tls.c text (Falcon is native now).

No functional change to non-Falcon builds; the library links no liboqs.
2026-07-22 09:52:26 +02:00
Daniele Lacamera 20a838aac3 Falcon: native wolfCrypt implementation (no liboqs)
Add a complete native Falcon post-quantum lattice signature implementation to
wolfCrypt, replacing the liboqs wrapper. Full key generation, signing and
verification for Falcon-512 (level 1) and Falcon-1024 (level 5).

  - Public API wc_falcon_* / falcon_key in falcon.c wraps the native core
    (falcon_native_* in wc_falcon.c) plus wc_falcon_{fpr,fft,poly,sampler,
    codec,keygen,sign,bigint}.c. No liboqs dependency.
  - Portable, constant-time integer-emulated floating-point (fpr) backend is
    the default; opt-in per-architecture acceleration:
      --enable-falcon-double  inline native double
      --enable-falcon-asm     x86-64 SSE2 out-of-line fpr asm
      --enable-falcon-avx2    x86-64 AVX2 (4-wide) FFT
  - Division-free (Barrett) integer NTT on the verify path, so no hardware
    divide is required on Cortex-M / embedded targets.
  - Verify uses a cached twiddle-factor NTT; signing uses the FFT / ffLDL tree
    and discrete Gaussian sampler over the abstract fpr seam.
  - test.c falcon_test (KAT verify + native keygen/sign/verify roundtrip);
    scripts/falcon-interop.c and a CI workflow cross-check native<->liboqs in
    both directions.
2026-07-22 09:52:26 +02:00
Marco Oliverio 57d42ccb61 se050: implement dynamic hw/sw offload 2026-07-22 08:06:35 +02:00
JacobBarthelmehandGitHub c1ee61c8d1 Merge pull request #10888 from SparkiDev/kmac_cshake
KMAC and cSHAKE: Add new algorithms
2026-07-17 16:49:25 -06:00
John Safranek 6f087a502e OCSP: opt-in SSRF screening of AIA responder
- Add wolfIO_OcspDestAllowed(); block internal-range responder hosts
- Call it in EmbedOcspLookup before connect (CWE-918)
- Gate on WOLFSSL_OCSP_SCREEN_RESPONDER (off by default)
- Add unit tests and CI for both resolver paths
2026-07-17 13:11:16 -07:00
Paul Adelsbach c4f9b5e9e8 Add crypto callback only mode for curve25519 2026-07-17 09:55:18 -07:00
philljjandGitHub dc1c77e079 Merge pull request #10830 from padelsbach/ed25519-cryptocb-only
Add crypto callback only mode for ed25519
2026-07-17 11:42:31 -05:00
JacobBarthelmehandGitHub 3984c8b1dd Merge pull request #10870 from SparkiDev/frodokem_1
FrodoKEM: Initial implementation
2026-07-17 10:14:47 -06:00
Sean Parkinson 607d7cfdb3 FrodoKEM: Initial implementation
Supports Fast C code, small C code, small stack and assembly for x86_64, Aarch64, Aarch32, Thumb2.
2026-07-17 22:38:55 +10:00
Tobias Frauenschläger 961d5c8a74 CMake: wire WOLFSSL_HAVE_XMSS and add XMSS verify-only/small sub-options
CMake accepted -DWOLFSSL_XMSS=1 but never emitted WOLFSSL_HAVE_XMSS, so
wc_xmss.c compiled empty and options.h advertised no XMSS support. Add the
missing definition block (mirroring LMS) plus WOLFSSL_XMSSVERIFYONLY and
WOLFSSL_XMSSSMALL sub-options for parity with autotools --enable-xmss=
verify-only,small, and expose all three in the generated options.h.

Also enable WOLFSSL_XMSS in the cmake.yml CI build, which tested LMS but
not XMSS -- the blind spot that let this regression through.
2026-07-17 08:37:35 +02:00
aidan garske dd46074153 6707 - Add least-privilege permissions block to PR-triggered workflows 2026-07-16 09:39:57 -07:00
Sean Parkinson 3606633b22 RISC-V 64-bit: rework assembly code.
Assembly code generated from scripts.
Have separate assembly files and new inline code.
2026-07-16 09:39:09 +10:00
aidan garske 3bab30ff5c 6824 - Verify echoed legacy_session_id matches the value sent in DTLS 1.3 2026-07-15 16:33:55 -07:00
aidan garske a0cc010217 6823 - Apply dirName constraints to SANs under WOLFSSL_NO_ASN_STRICT 2026-07-15 16:33:55 -07:00
Paul Adelsbach a6383a3ee8 Fix build issue with ed25519 cb-only and no curve25519 2026-07-14 09:08:12 -07:00
Paul Adelsbach c3750d28be Add make_pub and check_key hooks for ed25519 cryptocb only 2026-07-14 09:08:12 -07:00
Paul Adelsbach 5e784db069 Add crypto callback only mode for ed25519 2026-07-14 09:08:12 -07:00
Sean Parkinson 136e8da738 KMAC and cSHAKE: Add new algorithms
Add KMAC and cSHAKE as defined in SP 800-185.
Fixed the SHA-3 assembly usage on AMD chips to use the faster BMI version.
2026-07-13 17:48:56 +10:00
David GarskeandGitHub 1c34cc9cf5 Merge pull request #10568 from sebastian-carpenter/tls-ech-ext-public
Enhancement: Public extension manager for ECH
2026-07-10 15:39:24 -07:00
David GarskeandGitHub 0913436957 Merge pull request #10559 from MarkAtwood/security-policy-canonical-pointer
docs: consolidate security policy to canonical website URL
2026-07-10 09:43:02 -07:00
sebastian-carpenter f7ccf4c1de testing improvements (from #10542):
- *_wire_sni test is now more efficient
- openssl-ech workflow now does interop with ECH rejection

extra improvements:
- tested TLSX_EchSwapExtensions
- added ctx level SNI to padding calculation
- Improvement of SNI handling for ECH
- Changed EchSwapExtensions to append instead of prepend
- Reworked ECH testing
2026-07-10 10:09:46 -06:00
David GarskeandGitHub 772bae44b4 Merge pull request #10821 from wolfSSL/feature/x509-no-malloc-verify
Add true zero-allocation X.509 certificate verification under WOLFSSL_NO_MALLOC
2026-07-10 07:56:03 -07:00
ZackeryandGitHub 69bf010918 Merge pull request #10677 from dgarske/realtek_huk
Add RealTek AmebaPro2 (RTL8735B) HUK crypto-callback port
2026-07-09 18:09:37 -06:00
Mark Atwood 66fe117538 docs: keep in-repo security policy, fix contacts
Address review feedback (dgarske):

- Restore SECURITY-POLICY.md instead of deleting it. The full policy
  (severity rubric, scope, coordinated disclosure, credit) stays in-repo;
  the canonical website URL is now presented as a mirror of it, not a
  replacement, so other repos can still reference one copy.
- SECURITY.md: prefer support@wolfssl.com, offer secure@wolfssl.com with
  the PGP key as an option, and drop the phone number.
- Restore the mandatory report-template requirement and the "keep the
  vulnerability private until a fix is released" guidance, resolving the
  contradiction between the intro and the template section.
2026-07-09 12:39:30 -07:00