SBOM Generation: Enterprise Guide

Hayden Smith 11 min read

Most organizations that start producing Software Bills of Materials (SBOMs) run into the same wall. Writing the document is trivial. What takes work is trusting it across a polyglot monorepo, refreshing it as the dependency tree shifts, and handing it to systems that can do something with the contents.

An SBOM listing components nobody screened for accuracy clears compliance boxes and nothing else. The operational side is where the article dwells, because that is where programs that matter and paperwork that gets filed part ways.

Why the mandates arrived

Executive Order 14028, signed in May 2021, directed federal agencies to collect SBOMs from vendors providing systems to the government. The thinking: buyers should know what runs inside what they bought, so a fresh vulnerability disclosure can be matched against their estate without a scramble.

Log4Shell, disclosed in December 2021, showed exactly the scramble the order anticipated. Countless organizations needed days just to establish whether Log4j lived anywhere in their stack, having never inventoried their transitive Java dependencies. Those holding SBOMs for their Java applications answered that question in hours. Those without spent weeks combing codebases by hand.

Pressure has since spread past the federal sector. The European Union's Cyber Resilience Act and assorted sector frameworks require or encourage SBOM practice. Teams that still lack SBOM generation in their pipeline face a question narrower than whether to adopt it, namely how to adopt it in a way that keeps paying off operationally.

Picking between SPDX and CycloneDX

Two formats own the SBOM space: SPDX (Software Package Data Exchange), run through the Linux Foundation, and CycloneDX, out of OWASP. Both are machine-readable, both can carry the same underlying information. Where they part is fit with your toolchain and your purpose.

SPDX

SPDX grew out of license compliance auditing. Its model revolves around packages, files, and snippets, each with detailed fields for licensing. Under NTIA minimum elements guidance, it is the default format for federal SBOM deliverables.

Security vulnerability data entered the format at SPDX 2.3, though vulnerability handling has never been its strongest ground. If the driving use case is a government contract or license audits over a portfolio, SPDX fits naturally, and its tooling has the deepest support for identifying and cross-referencing licenses.

CycloneDX

CycloneDX started from security. Its schema treats vulnerability data, services, formulas describing build processes, and attestations as first-class citizens. Vulnerability exploitability exchange (VEX) arrived in version 1.4, letting a publisher annotate an SBOM with judgments about whether specific vulnerabilities are actually exploitable in their product. For downstream vulnerability management, that beats a bare list of CVEs by a wide margin.

Choose CycloneDX when the operational goals are tracking vulnerabilities, watching dependencies, and feeding security tooling. Commercial vulnerability platforms generally import CycloneDX more capably than SPDX, a gap that has been closing as SPDX 3.0 matures.

What we suggest in practice

Where compliance demands one format and operations prefer the other, emit both from the same resolved dependency data. Most toolchains producing one can produce the other from identical input, so the extra cost is small. File both next to the build that generated them in the pipeline artifact store.

Tools for repositories that mix languages

Single-language repositories make tool choice easy. Monorepos or service fleets mixing Node.js, Python, Go, and Java raise the difficulty, because the question becomes whether one tool covers every ecosystem well enough or whether per-ecosystem tools plus an aggregation step are needed.

Syft, from Anchore, covers many ecosystems from one binary and suits container image scanning, where package manager configuration is out of your hands and dependencies must be inferred from what is installed. Ecosystem-native tools such as cyclonedx-node-module for npm or cyclonedx-python deliver more accurate transitive resolution, because they plug into the package manager's own resolver.

For enterprise stacks with mixed languages, we lean toward:

  • Ecosystem-native tools wherever full-graph accuracy most affects your security posture, usually npm, PyPI, and Maven
  • A broad tool like Syft for container images and for ecosystems lacking native tool support
  • One SBOM per artifact, merged from the outputs, with provenance metadata recording which tool contributed each component entry

Putting generation inside the build

Generate once and file it, and you get some value. Regenerate on every build and ship the SBOM with the artifact, and the value climbs, because the document now describes the dependency state of the thing that actually deployed rather than a state from some earlier afternoon.

Placement matters as much as frequency. Generation should run right after dependencies install and before any build step transforms the tree, while the full resolved set sits in the workspace, the lock file is accurate, and nothing has been bundled or minified into illegibility.

Read the lock file or the installed tree, never the manifest. As the article on transitive dependency risks explains, a manifest lists direct dependencies only; the lock file holds the full resolved tree, transitive packages included.

Treat the SBOM as a build artifact, shipped beside the container image, compiled binary, or deployment package. Whatever deploys alongside the artifact becomes the authoritative inventory of its dependencies at deployment time.

Staying current across a large portfolio

Dozens or hundreds of repositories cannot be kept accurate by one run of a generation tool. Dependencies move with every npm update, every merged Dependabot PR, every new service that deploys.

What sustains over time:

  • Regenerate whenever a build changes the lock file. The cost is negligible, the step automates cleanly, and the stored SBOM trails the deployed artifact by at most one build.
  • Re-analyze SBOMs on each new vulnerability disclosure that could touch your known dependencies, even with no code change. Advisories evolve daily, so the inventory needs querying against today's data rather than the data that existed on build day.
  • Keep an organization-level inventory mapping every deployed artifact to its current SBOM, the layer that turns "which services run this component?" into a seconds-long query.

From SBOM to vulnerability triage

Security operations get the most from an SBOM during the first hours of a disclosure. The loop runs:

  • A vulnerability drops for a package within a version range
  • Ask the inventory which deployed artifacts carry that package at an affected version
  • For each hit, judge reachability of the vulnerable path, via reachability analysis or existing VEX annotations
  • Order remediation by deployment criticality and reachability

Two conditions make this loop work: a current inventory, which continuous generation supplies, and queryable data, which format and storage decide. JSON CycloneDX SBOMs held in an artifact registry with an API meet the second condition. A PDF does not. Neither does a spreadsheet.

VEX, and saying what does not apply

A VEX statement attaches a judgment to an SBOM entry: package X at version Y carries vulnerability Z, but the vulnerable path is absent or unreachable in this artifact. Downstream vulnerability tools read those statements and drop findings that were assessed as inapplicable.

Used properly, VEX records the conclusion of an investigation rather than skipping it. It keeps an assessed finding from regenerating as noise on every rescan. A team that confirmed a transitive dependency's known flaw does not reach their code annotates the SBOM once, and the management platform stops re-alerting on it.

CycloneDX's VEX support is today's most workable route to this in an enterprise pipeline. Tooling that imports and stores VEX annotations alongside SBOMs lets "assessed, not exploitable here" live with the artifact inventory, where it belongs, instead of only in a closed ticket.

A first slice of coverage

Instrumenting every repository at once and chasing full accuracy across all ecosystems is a costly way to begin. A cheaper opening:

  • Cover the five to ten most critical production services first, with ecosystem-native tools for each service's primary language
  • File the SBOMs somewhere queryable, beside the build artifacts they describe
  • Run a complete vulnerability query against them with current advisory data, record the baseline count, and start triaging by criticality
  • Grow coverage over following quarters, following whatever operational value the first SBOMs show

Visibility and queryability of your software inventory is the whole purpose. Format, tools, and storage architecture are choices that serve it, and programs designed around the purpose tend to survive requirement changes better than programs that pile up documents passing a checkbox while never feeding the workflows that prompted the requirement.

Back to Security Insights