Skip to content

Add SBOM and provenance generation - #188

Open
shashial wants to merge 3 commits into
mainfrom
add-SBOM-and-provenance-generation
Open

Add SBOM and provenance generation#188
shashial wants to merge 3 commits into
mainfrom
add-SBOM-and-provenance-generation

Conversation

@shashial

Copy link
Copy Markdown
Contributor

This commit generates a CycloneDX 1.6 SBOM from the mkosi manifest at build time;

Then in the "publish" workflow:

  1. generates combined SHA256SUMS for artefacts incuding SBOM
  2. signs SLSA provenance for all production artifacts plus an SBOM attestation for the .efi
  3. verifies both bundles before upload
  4. publishes manifest, SBOM, checksums and attestation bundles to R2

@shashial
shashial marked this pull request as ready for review August 3, 2026 16:46
@shashial
shashial requested review from a team as code owners August 3, 2026 16:46

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adds supply-chain metadata generation and publishing for Flashbox L1 builds by producing a CycloneDX 1.6 SBOM from the mkosi manifest and signing/verifying provenance + SBOM attestations during the publish workflow.

Changes:

  • Add an mkosi post-output script to generate a deterministic CycloneDX 1.6 SBOM from the mkosi JSON manifest.
  • Extend the build/publish workflow to generate combined SHA256SUMS, create Sigstore (SLSA provenance + SBOM) attestations, verify them, and upload artifacts + bundles to R2 / attach to releases.
  • Update mkosi module configuration to run shared post-output scripts; ignore Python __pycache__ artifacts.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
shared/mkosi.postoutput.d/91-deb-sbom.py New Python post-output script that converts mkosi manifests into a deterministic CycloneDX 1.6 SBOM.
modules/flashbox/flashbox-l1/mkosi.conf Enables mkosi post-output scripts for flashbox-l1 builds.
.gitignore Ignores Python __pycache__/ directories.
.github/workflows/flashbox-l1.yaml Adds permissions needed to mint/verify attestations in the release job.
.github/workflows/_build-and-publish-image.yaml Adds checksum generation, provenance/SBOM attestation creation, verification, and publishing of SBOM + bundles.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

ExtraTrees=modules/flashbox/flashbox-l1/mkosi.extra
PostInstallationScripts=modules/flashbox/flashbox-l1/mkosi.postinst
BuildScripts=modules/flashbox/flashbox-l1/mkosi.build
PostOutputScripts=shared/mkosi.postoutput.d/*

@alexhulbert alexhulbert left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally looks good except the python file looks a bit overengineered, the shared folder has some flashbots-specific stuff (other companies use it shared folder so we need to keep it generic), and ive run into reproducibility issues with python-based post output files in the past.

ill write up a small ~30-40 line jq script when i get back from my vacation on monday and you lmk if that's a suitable alternative to the python one you have here.

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.

3 participants