MSBA-360 · Lesson 9 of 12 · 18 min

Software bill of materials

▶ Video coming soon A video version of this lesson is on the way.

Two weeks before the ninth session, Skerry's largest wholesale customer, a chain of outdoor stores in Europe that sells Skerry's own-brand gear and uses its ordering portal, sent a supplier questionnaire. One question read: "Provide a software bill of materials for each software component you supply, in SPDX or CycloneDX format, and describe how you keep it current." Lorcan forwarded it to Freya with one line: "Can we?" The session was spent answering him.

What an SBOM is

A software bill of materials, or SBOM, is a list of the components that make up a piece of software, like the list of ingredients on food packaging. For each component it records at least a name, a supplier, a version, a unique identifier and its relationship to other components; most SBOMs also record the license and a hash that identifies the exact file. An SBOM lets someone who receives software answer questions without access to its source code: does this product contain the vulnerable logging library from last week's advisory? Which open source licenses does it carry?

SBOMs became mainstream after a series of supply chain incidents and after governments started asking for them. A United States executive order in 2021 directed federal agencies to require SBOMs from software suppliers, and the National Telecommunications and Information Administration published the minimum elements an SBOM should contain. The European Union's Cyber Resilience Act, which entered into force in December 2024, requires manufacturers of products with digital elements to identify and document their components, including by drawing up an SBOM, with its reporting obligations applying from September 2026 and its main obligations from December 2027. Requirements for specific sectors and customers keep growing, which is why questions like the European customer's are now routine.

Typical fields recorded for each component in an SBOM.
ElementExample for one component
Component nameexpress
Version4.21.2
SupplierThe package's publisher in its registry
Unique identifierA package URL such as pkg:npm/express@4.21.2
RelationshipDependency of the checkout service
LicenseMIT
Author of the SBOM and timestampGitHub dependency graph export, generated on November 19, 2026

Two formats

Two formats dominate. SPDX, the Software Package Data Exchange, started at the Linux Foundation as a way to record license information and is published as the international standard ISO/IEC 5962. CycloneDX, from the OWASP community, was designed for security use and is published as the Ecma standard ECMA-424. Both can be written as JSON, both identify packages with package URLs, and tools can convert between them. Most customers, like Skerry's, accept either.

Two columns comparing SPDX and CycloneDX. SPDX: origin Linux Foundation, international standard ISO/IEC 5962, strong on licenses, exported by GitHub's dependency graph. CycloneDX: origin OWASP, Ecma standard ECMA-424, strong on security data such as vulnerabilities and services, produced by many build tools. A note in the middle: both use package URLs and JSON, and tools convert between them.
The two common SBOM formats.

Exporting an SBOM from GitHub

GitHub can produce an SBOM directly from a repository's dependency graph. On the Dependency graph page under Insights, the Export SBOM button downloads a file in SPDX JSON format listing every dependency the graph knows about, with versions, package URLs and licenses where known. The same export is available through the REST API, which is how teams automate it. Anyone with read access to the repository can export, because the SBOM contains only what the dependency graph already shows.

Exporting an SBOM through the REST API with the GitHub CLI and counting its packages.
# Export the SPDX SBOM for a repository's dependency graph
gh api /repos/skerry/commerce-checkout-service/dependency-graph/sbom \
  --jq '.sbom' > checkout-sbom.spdx.json

# Count the packages it lists
jq '.packages | length' checkout-sbom.spdx.json

Because the export comes from the dependency graph, it inherits the graph's strengths and limits from lesson 5. It describes the repository's declared and resolved dependencies on the default branch. It does not describe a container image's base layer, system libraries installed during a build, or vendored code without a manifest. For a library or a service whose dependencies are all package-managed, that is usually the right picture. For a container image or an installer, a build-time SBOM is better.

Repository SBOMs and build SBOMs

Wilhelmus drew the distinction on the whiteboard. A repository SBOM describes what the source code says it depends on. A build SBOM describes what actually went into a specific built artifact: the exact packages resolved during that build, plus anything the build pulled in from elsewhere, such as the operating system packages in a container image. The two are usually close, but not identical, and when a customer asks for an SBOM for software you supply, they mean the second.

Build SBOMs are generated in the build pipeline by tools that inspect the built artifact, such as an image scanner that reads the packages inside a container layer. Many such tools are available as GitHub Actions and can write either format. The SBOM is then stored alongside the artifact, for example as a release asset or in the container registry, and can be bound to the artifact with an SBOM attestation, which lesson 10 explains.

Repository SBOMs and build SBOMs answer different questions.
Repository SBOMBuild SBOM
SourceDependency graph exportA tool that inspects the built artifact
DescribesDeclared and resolved dependencies of the codeWhat is inside one specific artifact
Format from GitHubSPDX JSONSPDX or CycloneDX, depending on the tool
Best forLibraries, inventory, license reviewContainers, installers, customer requests
Ties to a versionThe default branch at export timeOne artifact digest

Worked problem

Answering the customer

The European customer wants an SBOM for the ordering portal, which Skerry deploys as a container image, and wants to know how it is kept current. What does Freya send?

Show solution
  1. A repository SBOM from the portal's dependency graph would miss the operating system packages in the image, so it is not enough on its own.
  2. Wilhelmus adds a build step that generates a CycloneDX SBOM from the built image and stores it with each release.
  3. The release workflow also creates an SBOM attestation binding that SBOM to the image digest, so the customer can verify which image it describes.
  4. Freya's answer explains that a new SBOM is generated for every release, that it is signed and tied to the image, and that Dependabot and the image scanner alert on vulnerabilities between releases.

Using an SBOM you receive

SBOMs flow in both directions. Skerry also bought software: a warehouse management package, the point-of-sale terminals' operating system and several software development kits from payment providers. Freya's team started asking those suppliers for SBOMs and loading them into an inventory, so that when an advisory was published they could check bought software as well as their own code. An SBOM is most useful when it is searchable alongside every other SBOM you hold.

Received SBOMs raise a practical problem: they list vulnerable components that may not matter. A product can contain a vulnerable library whose vulnerable function it never calls. The Vulnerability Exploitability eXchange, or VEX, is a companion document in which a supplier states, for a specific vulnerability, whether the product is affected, not affected, fixed or under investigation. Skerry asked its suppliers for VEX statements with their SBOMs where available, which cut the list of apparent problems in the warehouse package from 61 to 7.

Keeping SBOMs current

An SBOM is a snapshot. The day after it is generated, a dependency may be upgraded or a new advisory may be published. Keeping SBOMs useful means regenerating them whenever the software changes and storing them where people can find them. Skerry's rule became: every release produces a build SBOM, stored with the release; every repository's SPDX export is collected weekly into the security team's inventory through the API; and SBOMs older than the latest release are kept for as long as that release might still be running somewhere.

What an SBOM does not tell you

An SBOM says what is in the software. It does not say whether a component is vulnerable; that comes from matching it against advisories. It does not say whether the software was built from the source code it claims, or by whom; that is the job of provenance and attestations. And it does not say whether the software is secure. Freya ended the session with that reminder for Lorcan: "Yes, we can send them SBOMs. The SBOM is the list. Our process is what makes the list worth trusting."

Licenses and notices

SBOMs also serve the legal team. Because each component records its license, the SBOM is the starting point for the open source notices that many licenses require a distributor to include, such as the copyright and license text shown in an application's about screen. Skerry's legal team used the build SBOMs for the store terminals' software to generate the notices file that ships with every terminal release, replacing a spreadsheet that had last been updated in 2022.

Generating build SBOMs in a workflow

Wilhelmus added build SBOM generation to the shared image build workflow so that every team got it without writing anything. After the image was built and pushed, a step ran an image scanning tool that inspected every layer, wrote a CycloneDX document listing every package it found, including operating system packages, and uploaded it as a workflow artifact and as a release asset. A second step attested the SBOM to the image digest, as lesson 10 describes. Because the step lived in the reusable workflow, adding it to one place added it to 312 services.

The first run produced a useful surprise. The build SBOM for the ordering portal listed 214 operating system packages from the container's base image that appeared nowhere in the repository SBOM, including an old version of a compression library with a known vulnerability. Moving to a smaller, regularly updated base image removed most of them. Without the build SBOM, nobody would have known they were there.

Storing and finding SBOMs

An SBOM nobody can find is as useless as none at all. Skerry stored build SBOMs in three places: as a release asset next to the artifact, as an attestation in the container registry, and in a central inventory that the security team could search. The central inventory let them ask, in one query, which released versions of which products contained a given package, which is the question that matters on the day a new advisory is published. When the compression library advisory was updated in November, the inventory answered in seconds: four products, eleven released versions, two still in production.

Sharing SBOMs with customers

Deciding how to share SBOMs with customers raised questions the engineering team could not answer alone. An SBOM reveals a lot about a product: every library and its version, and therefore, to an attacker, which known vulnerabilities to try. Skerry's legal and security teams agreed to share SBOMs with customers under the same confidentiality terms as other technical documentation, through a customer portal rather than in public, and to include VEX statements so that customers did not chase vulnerabilities that did not affect them. The European customer accepted that arrangement.

SBOM quality

Not all SBOMs are equally useful. A good SBOM names each component unambiguously, usually with a package URL; includes versions and hashes; records relationships, so a reader knows which components depend on which; and says who generated it and when. Poor SBOMs list package names without versions or identifiers, which makes them impossible to match against advisories. Open source tools can score an SBOM against the minimum elements. Freya added a check to the release workflow that failed if the build SBOM was missing package URLs for more than a handful of components, which caught a misconfigured scanner in the warehouse tools pipeline.

SBOMs at Tidewater

Priya asked whether a team of six needed any of this. Seraphine's answer was that Tidewater already had a repository SBOM for TrailCheck, one click away on the dependency graph page, and that exporting it once a quarter and keeping it with the release notes would answer most questions a partner or app store was likely to ask. Build SBOMs could wait until Tidewater shipped something more complex than a single app.

Common mistakes

  • MistakeSending a repository SBOM when a customer asks about a container image.

    InsteadGenerate a build SBOM from the image, which includes base layers and system packages.

  • MistakeGenerating an SBOM once and treating it as permanent.

    InsteadRegenerate it for every release and keep each one with the artifact it describes.

  • MistakeReading every vulnerable component in a received SBOM as an active problem.

    InsteadUse VEX statements and reachability to separate affected from not affected.

  • MistakeTreating an SBOM as proof that software is secure.

    InsteadAn SBOM is an inventory; vulnerability matching and provenance answer other questions.

Summary and key terms

  • An SBOM lists the components in software with names, versions, suppliers, identifiers, relationships and usually licenses and hashes.
  • The common formats are SPDX (ISO/IEC 5962) and CycloneDX (ECMA-424); both use JSON and package URLs.
  • GitHub exports an SPDX SBOM from the dependency graph in the interface or through the REST API.
  • Repository SBOMs describe the code's dependencies; build SBOMs describe what is inside a specific artifact.
  • SBOMs must be regenerated with each release and are paired with VEX statements, vulnerability matching and attestations.
SBOM
A software bill of materials: a list of the components that make up software.
SPDX
Software Package Data Exchange, an SBOM format published as ISO/IEC 5962.
CycloneDX
An SBOM format from OWASP, published as ECMA-424.
Package URL
A standard identifier for a package, such as pkg:npm/express@4.21.2.
Build SBOM
An SBOM generated from a built artifact, describing exactly what it contains.
VEX
Vulnerability Exploitability eXchange: a statement of whether a product is affected by a vulnerability.
Cyber Resilience Act
An EU law setting cybersecurity requirements for products with digital elements, including component documentation.

Practice problems

Work each problem on paper first, then reveal the answer to check.

  1. In which format does GitHub export an SBOM from the dependency graph?

    Show answer

    SPDX JSON.

  2. Why is a repository SBOM not enough for a container image?

    Show answer

    It does not include the image's base layers or system packages installed during the build.

  3. What does a VEX statement add to an SBOM?

    Show answer

    Whether the product is actually affected by a specific vulnerability.

Lesson quiz · 5 questions

Score 60% or more to complete this lesson.

Take the quiz