Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Docker 10 min read How-to mediumAdept

How to Generate an SBOM for Container Workflows

Generating SBOMs at build time, rather than scanning finished images, captures resolved transitive dependencies, statically linked components and multi-stage build contents that heuristic post-build scanners miss. An actionable SBOM is complete, records resolved rather than declared versions, is regenerated with every build, is cryptographically bound to the image digest, and validates against the SPDX or CycloneDX schema. In CI, generate from the final stage via BuildKit attestations and attach the SBOM as an OCI attestation. Validate component counts and digest binding before pushing, and pin generator tools to commit SHAs because they run with elevated build access. SPDX is the default for container images, while CycloneDX suits security-focused workflows.

Assumes: Docker multi-stage buildsCI/CD pipelinescontainer registries

Related posts

  • What is an SBOM (and Why Can’t You Ship Without One)?

    Docker mediumAdept

    A software bill of materials is a machine-readable inventory of every resolved component in an artifact, covering name, version, supplier, license, purl identifiers, dependency relationships and checksums, usually expressed in SPDX or CycloneDX. For container images, the SBOM is best generated at build time with BuildKit (`docker buildx build --attest type=sbom`). That captures OS packages and transitive dependencies that manifest-based SBOMs miss, and attaches the SBOM as an in-toto attestation alongside SLSA provenance in the OCI registry. Stored there, SBOMs feed continuous CVE matching and CI policy gates, and regulations such as EO 14028 and the EU CRA are making them a procurement requirement. A maturity model and an incremental adoption path start with a single image.

  • 5 Software Supply Chain Security Best Practices for Development Teams

    Docker mediumAdept

    Software supply chain security for container workloads breaks down into five areas: trusted content, build security, pre-deployment verification, access and policy controls, and continuous monitoring. Concrete practices include pinning images by SHA256 digest and CI actions by commit SHA, producing signed SLSA provenance in in-toto format, generating SBOMs at every build and pairing them with VEX, scoping pipeline credentials per job, and baselining container runtime behavior. The recommended path is incremental, starting with minimal base images and dependency integrity. The guide closes by promoting Docker Hardened Images and Docker Scout.

  • Generating Software Bills of Materials (SBOMs) with SPDX at Microsoft

    Engineering@Microsoft mediumAdept

    Microsoft is converting its proprietary build manifests into SPDX 2.2.1 JSON SBOMs, the ISO/IEC 5962:2021 standard, for every product it builds, to comply with the 2021 U.S. cybersecurity executive order. The NTIA minimum fields map onto SPDX fields, and Microsoft makes supplier, version, checksum and relationship fields mandatory. A cross-platform generator, injected into CI/CD across roughly 500,000 builds a day, detects OSS dependencies across many ecosystems, records SHA256 and SHA1 hashes, and signs the SBOM. A signing service binds the SBOM hash to build-session claims (commit, build ID, repo) for provenance, and release-time validation blocks deployment on any hash or signature mismatch.

  • Microsoft open sources its software bill of materials (SBOM) generation tool

    Engineering@Microsoft easyNovice

    Microsoft has open sourced its build-time SBOM generator, a cross-platform (Windows, Linux, Mac) tool that emits SPDX documents and auto-detects dependencies from npm, NuGet, PyPI, Maven, Go, Rust crates, RubyGems, container Linux packages and more via the Component Detection library. Generated SBOMs contain four SPDX sections: document creation info, files with SHA-1/SHA-256 hashes, packages with versions, suppliers, hashes and purl identifiers, and relationships between elements. SBOMs can reference other SBOM documents through externalDocumentRefs with checksums, so layered builds can capture a full dependency tree across predecessor builds.

  • Making the Most of Your Docker Hardened Images Enterprise Trial – Part 2

    Docker mediumAdept

    Docker Hardened Images ship 16 signed in-toto attestations (SLSA provenance, CycloneDX/SPDX SBOMs, FIPS, STIG, Scout scans, OpenVEX), and you can check vendor claims yourself with `docker scout attestation get` and `jq`. Run against a FIPS Node.js image, the checks trace the build to a specific GitHub commit and Actions run, confirm OpenSSL FIPS Provider CMVP #4985, and show 91/91 applicable STIG checks passing. The SBOM shows 32 packages versus 321 in the official image, with no critical, high or medium CVEs after VEX filtering, and supports license audits that flag GPL and NOASSERTION entries for review. CIS compliance is backed only by an image label, not an attestation.

The quest for software engineering knowledge.

Look:
Layout: