Skip to content

sbom: drop nested wolfcrypt CPE - #894

Open
sameehj wants to merge 2 commits into
wolfSSL:masterfrom
sameehj:fix/sbom-drop-nested-wolfcrypt-cpe
Open

sameehj wants to merge 2 commits into
wolfSSL:masterfrom
sameehj:fix/sbom-drop-nested-wolfcrypt-cpe

Conversation

@sameehj

@sameehj sameehj commented Sep 15, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Re-vendor wolfGlass at 3b708da (wolfGlass wolfBoot TPM support #27).
  • Nested wolfcrypt keeps supplier, version, and PURL (#wolfcrypt). No wolfcrypt CPE.
  • Matching stays on cpe:2.3:a:wolfssl:wolfssl:<version>.

Test plan

  • make sbom TARGET=sim — nested wolfcrypt has PURL, no cpe
  • wolfssl component still has cpe:2.3:a:wolfssl:wolfssl:<version>
  • wolfGlass drift check against 3b708da

Re-vendor wolfGlass at 3b708da. wolfcrypt stays a nested component
(name, version, PURL). Matching uses the wolfssl CPE only.

Co-authored-by: Cursor <cursoragent@cursor.com>

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.

🟡 Changes recommended

The identifier behavior lacks a regression assertion and leaves contradictory matching guidance in vendored comments.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Updates SBOM generation to treat nested wolfcrypt as provenance-only while retaining wolfSSL CPE matching.

Changes:

  • Removes wolfcrypt CPEs from CycloneDX and SPDX output.
  • Requires wolfcrypt PURLs in validation and updates documentation.
  • Re-vendors wolfGlass at 3b708da and bumps generator version to 1.9.
File summaries
File Description
tools/sbom/validate_sbom.py Accepts wolfcrypt with PURL but no CPE.
tools/sbom/gen-sbom Omits nested wolfcrypt CPEs.
tools/sbom/build/sbom.mk Updates Make integration documentation.
tools/sbom/build/sbom.cmake Updates CMake integration documentation.
tools/sbom/.wolfglass-rev Updates wolfGlass revision pin.
Makefile Documents wolfSSL CPE matching.
docs/SBOM.md Documents identifier semantics.
Review details

Suppressed comments (1)

tools/sbom/gen-sbom:1086

  • The new conditional is the behavior this PR changes, but the SBOM workflow only performs structural validation and never asserts the identifier set. A future vendor sync could re-add the nested wolfcrypt CPE (or drop the parent wolfssl CPE) while the current checks remain green; add a focused generated-SBOM assertion for both documents.
        # wolfcrypt has no CPE: matching rides on the parent wolfssl CPE.
        if meta.get('cpe'):
            comp['cpe'] = meta['cpe'](version)
  • Files reviewed: 7/7 changed files
  • Comments generated: 2
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Makefile
Comment on lines +986 to +987
# Coat: wolfssl (matching CPE) + nested wolfcrypt (PURL / provenance).
# Sources remain in the merkle hash; the wolfssl CPE is what NVD matches.
Comment thread tools/sbom/gen-sbom
Comment on lines +383 to +388
# wolfCrypt is co-shipped in the wolfSSL tree. Embedders compile those
# sources into the image. Record it as a nested component so the SBOM
# shows provenance (supplier, version, PURL). Do not emit a wolfcrypt
# CPE: NVD files crypto CVEs against cpe:2.3:a:wolfssl:wolfssl, not
# wolfcrypt (zero CVEs on that product today). A second CPE on the same
# sources is a future double-match risk once a CNA starts filing there.
Makefile no longer says a scan matches wolfssl:wolfcrypt. Re-vendor
wolfGlass at 48796ea so the generator contract exempts nested wolfcrypt.

Co-authored-by: Cursor <cursoragent@cursor.com>
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.

2 participants