Dev.to Security 🔐 Cybersecurity 👁 0 📖 5 min read

My AI-assisted SBOM scanner said "0 vulnerabilities". A test with a known answer caught it

I'm building ShieldBOM, an SBOM scanner for embedded software. I build it with Claude (an LLM). Before this, I worked in embedded development, and then I helped teams adopt SCA tools. ShieldBOM is my personal open-source

I'm building ShieldBOM, an SBOM scanner for embedded software. I build it with Claude (an LLM). Before this, I worked in embedded development, and then I helped teams adopt SCA tools. ShieldBOM is my personal open-source project, so please keep in mind that I'm the author. Claude wrote this post, and I checked the facts.

My scanner said "0 vulnerabilities" for a version of OpenSSL that has known CVEs. There was no warning. Claude wrote most of the code, and another AI agent reviewed it. Nobody noticed. There was no error, and "0" looked like a normal answer. I found the problem only when I ran an input with a known answer.

With AI, a script that checks OSV or NVD takes only a few minutes to write. Scripts like this often have the same problems. In this post, I share a 5-minute test and three places where these problems come from.

A 5-minute test

OpenSSL 3.0.8 has several known CVEs. For example, CVE-2023-2650 affects 3.0.0 to 3.0.8. Make an SBOM with only this one component, and run your scanner or script on it.

{
  "bomFormat": "CycloneDX",
  "specVersion": "1.5",
  "version": 1,
  "components": [
    {
      "type": "library",
      "name": "openssl",
      "version": "3.0.8",
      "purl": "pkg:generic/[email protected]"
    }
  ]
}

I use pkg:generic because C/C++ libraries often look like this in real SBOMs. There is no package manager like npm or PyPI, so there is no better purl type to use.

  • You see OpenSSL CVEs: your tool can check this case.
  • You see 0 results: your tool probably cannot check C/C++ components written like this.
  • You see a warning that the check failed: at least you know what you cannot see.

The worst case is 0 results with no warning.

Problem 1: OSV returns nothing for some purl types

You can query OSV.dev with a purl. But OSV works per ecosystem, like npm, PyPI, or Debian. pkg:generic does not belong to any ecosystem. When I sent pkg:generic/[email protected], OSV returned an empty result (checked in November 2026).

Conan users have the same problem. On November 25, 2026, I sent pkg:conan purls to OSV. Each version below has known CVEs.

purl Results from OSV
pkg:conan/[email protected] 0
pkg:conan/[email protected] 0
pkg:conan/[email protected] 0
pkg:conan/[email protected] 0
pkg:conan/[email protected] 0
pkg:conan/[email protected] 0
(for comparison) pkg:deb/debian/[email protected]?arch=source 147
(for comparison) pkg:deb/debian/zlib@1:1.2.11.dfsg-2?arch=source 8

With a Debian purl, the same libraries return CVEs. Conan is not in OSV's list of ecosystems (as of that day). So 0 does not mean "no vulnerabilities".

OSV does not return an error for an unsupported purl type. On the same day, I also sent pkg:nosuchtype/[email protected], a type that does not exist. OSV returned HTTP 200 with an empty result. So you cannot tell "no vulnerabilities" from "not supported" by looking at the response. If you ask an AI for "a script that checks vulnerabilities with OSV", the script will likely count this as 0. My scanner did.

Problem 2: NVD has gaps with both CPE and keyword search

NVD is usually queried by CPE. But embedded SBOMs often have no CPE. Without a CPE, you have to search by product name.

Keyword search finds CVEs for other products. My scanner has a sample SBOM with FreeRTOS, lwIP, cJSON, and more. 21 findings matched by name only. I read all 21:

  • Correct: 6
  • About a different product or a different version: 12
  • Not clear from the description: 3

Many of the wrong ones were CVEs for other software that includes its own copy of cJSON or lwIP. Embedded C libraries are often copied into other projects. A keyword search also finds the CVEs of those copies.

A CPE search has the opposite problem. It does not return CVEs that NVD has not analyzed yet, because those CVEs have no product or version data. NVD's analysis is behind new CVEs (still true in November 2026), so new CVEs are the easiest to miss. Keyword search gives false positives. CPE search misses some CVEs. Neither one alone is enough.

Problem 3: C library versions are not semver

After I fixed problems 1 and 2, I ran the 5-minute test again. This time I got 259 findings. They included Heartbleed, which affects 1.0.1 to 1.0.1f and 1.0.2-beta1. It has nothing to do with 3.0.8. Heartbleed is in CISA KEV, a list of vulnerabilities that are known to be exploited. Because of this, the EU CRA report (a readiness check, not a conformity assessment) showed FAIL for "known exploitable vulnerabilities".

The cause was version comparison. OpenSSL adds letters to its versions, like 1.0.1g or 1.0.2zh. NVD uses the same format for affected ranges, for example "from 1.0.1, before 1.0.1g". My scanner tried to read these versions as semver. It failed, and it dropped the limit it could not read, without a warning. Without "before 1.0.1g", the range becomes "1.0.1 and later". That includes 3.0.8.

C libraries also use other formats, like four numbers (1.2.3.4) or dates. If a semver library cannot read a version, the result depends on your code. If you drop the limit, the range gets bigger and you get false positives. If you treat it as "not affected", the range gets smaller and you miss findings. Both happen with no warning.

If you write it with AI, set up these first

After I found each cause, the AI fixed it in a few minutes. Finding the problem took much longer. All the unit tests passed. I wrote the test data with the AI. It was not taken from real APIs.

  • Keep SBOMs with known answers. Use components with known CVEs, like the 5-minute test, Conan purls, and versions with letters. Run them when you write, fix, or replace a scanner.
  • Keep "0 results" and "could not check" as different results. Network errors, unsupported purl types, and versions you cannot read should all be "could not check". If you use OSV, compare the purl type with OSV's list of ecosystems (ecosystems.txt). Purl types and ecosystem names are not one-to-one. For example, pkg:deb can be Debian or Ubuntu. You need your own mapping.
  • Test with the real API, not mocks. Send real queries to see how an API answers (an error or an empty result). Do not depend on the AI's knowledge or your own memory.

Try it

ShieldBOM shows components it could not check as "could not check". It sends purl types that OSV does not support (like pkg:generic and pkg:conan) to NVD. It marks CVEs matched by name only, and OpenSSL-style versions it could not compare, as "unconfirmed". It does not support four-number or date versions yet. It is Apache-2.0, and you can install it from crates.io.

cargo install shieldbom
# save the JSON above as test.cdx.json
shieldbom scan test.cdx.json

If you try the 5-minute test with your scanner, or if ShieldBOM gets your embedded SBOM wrong, please tell me in the issues: https://github.com/kazu11max17/shieldbom/issues. For other scanners, you don't need to name the tool. The result is enough.

Vulnerability data: OSV.dev, NVD, CISA KEV. This product uses data from the NVD API but is not endorsed or certified by the NVD. No affiliation with or endorsement by CISA or OSV is implied.

📰 Read the original article on Dev.to Security

Originally published by Dev.to Security. Aggregated on AIWithGhost for educational purposes — full credit and traffic to the original publisher.