Skip to content

release: generate and verify SBOMs for shipped artifacts - #3

Draft
ryjen wants to merge 6 commits into
mainfrom
ci/release-artifact-sboms
Draft

ryjen wants to merge 6 commits into
mainfrom
ci/release-artifact-sboms

Conversation

@ryjen

@ryjen ryjen commented Oct 20, 2026 •

Copy link
Copy Markdown
Owner

Purpose

Add release-asset supply-chain evidence without expanding upstream Tailcat shutdown fix tailscale#151 or its fork PR #1.

The current release workflow builds archives, Debian/RPM packages, standalone binaries and a multiarch OCI image, but it has no documented or verified artifact-derived SBOM publication gate. Source dependency inventories alone do not describe exactly what is shipped.

Implementation

  • Configure GoReleaser v2.18.3's native sboms pipeline for binary, archive and package artifacts in CycloneDX JSON.
  • Install Syft v1.54.1 from a SHA-256-verified upstream release archive before GoReleaser; a missing or invalid tool stops the release.
  • Set dockers_v2.sbom: true explicitly for buildx OCI image SBOM attestations.
  • Add a non-publishing snapshot CI workflow for changes to the release configuration, generating binaries/archives/packages and checking that each archive/package has a nonempty CycloneDX SBOM. --snapshot --skip=docker prevents registry publishing in CI.
  • Document checksum limitations and how to inspect published OCI digests.

Verification

  • Pinned Syft archive SHA-256: c069905b391cc4c20a5ba65ad5c10be2a7ba074f8ea6ad203e24d14e303dad47.
  • Pinned GoReleaser version: v2.18.3; checksum-verified local GoReleaser check passed.
  • No tags, GitHub releases or container images were published from this branch.
  • Exact-head non-publishing snapshot CI passed, verifying all 11 archive/package CycloneDX inventories. The GoReleaser artifact manifest also recorded five compiled-binary SBOMs (16 total inventories). Test CI passed all eight jobs. Nix also passed. All three workflows are green on exact head 08cf3c0ec.

Remaining release-stage checks

  • Release is not qualified until per-platform OCI image SBOM attestations have been examined on the actual published digest and the release assets have been verified against checksums. Snapshot mode cannot prove GHCR upload permissions, registry attestations or cryptographic signing/provenance.
  • This is an independent draft PR against fork main, not a modification of fix PR #1.

References: GoReleaser native SBOMs and Docker v2 SBOMs.

Full artifact checksum qualification (October 19, 2026)

  • Latest head: 11f7213dc. The first strict-check run exposed duplicate checksum entries introduced by the redundant checksum.extra_files glob. Inspection of GoReleaser v2.18.3 showed that uploadable SBOMs already belong to the default checksum artifact set. Removed the extra glob while preserving the exact-count and hash-verification gate.
  • Release SBOM snapshot: passed, verifying 11 archive/package files, all five standalone-binary inventories, and 16 CycloneDX documents each present exactly once in checksums.txt. sha256sum --check checksums.txt passed against generated files.
  • Test workflow: all eight jobs passed. Nix: passed.
  • This establishes non-publishing artifact identity coverage for generated release files, not cryptographic signing or live GHCR/OCI attestation verification. No release tag or image was published. Keep this as a draft until publication-stage verification is authorized.

Offline multi-platform OCI attestation qualification

  • Commit 0bbcdf7ea adds a standard-library Go verifier in tool/ocisbom/ plus a non-publishing Buildx OCI export test.
  • Uses the same GoReleaser-built linux/amd64 and linux/arm64 binaries and release Dockerfile; constructs a two-platform OCI layout with SBOM attestations but never pushes an image or creates a release.
  • The verifier checks indexed platform manifests, referenced attestation manifest subjects, SPDX predicate, digest-bound in-toto statement subjects, and nonempty package inventories. Unit tests prove it rejects forged subjects; go test and go vet passed locally.
  • Exact-head release SBOM snapshot, Test, Nix requalify this extension.
  • Limit: This validates a local OCI export; real GHCR publish behavior remains unverified. No upstream package/image publication is authorized by this PR.

Offline OCI qualification — exact head 60bd9a1

  • Release SBOM snapshot run 39374383927 passed. It validated all 16 CycloneDX release-asset inventories and their unique checksum entries, plus two platform-specific OCI/SPDX SBOM attestations in a non-published OCI layout.
  • The image manifest subjects verified: linux/amd64 = sha256:1d5eb2e5ce775dfe5889561059c5eb3d18865865126514230f19e85b4244abbb; linux/arm64 = sha256:76830f58025794e4023ffc5e3962fb5d67db7ef7ad537a460abb1066c3f624e1. Offline OCI index digest: sha256:04456a17472667873b272e0c36047c39203e8c06802b5ee2c8a788c875537ffc (not a published registry digest).
  • BuildKit emitted empty statement-level subject arrays, but its attestation manifest subject was checked against the exact image-manifest digest. The verifier now requires that manifest binding, and validates statement-level subjects if present. Five local unit cases passed, including forged and missing-subject rejection, with Go vet also passing.
  • The snapshot intentionally did not push a container image or create a release. Live GHCR OCI attestation persistence and producer authenticity are still open release-stage checks; this PR remains draft.
  • Test run and Nix run qualify the same head.

@ryjen ryjen left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Independent release supply-chain review at exact commit 08cf3c0ec13ce39e5e908f81c0279fe5c8478c52.

Validated / positive evidence

  • Uses GoReleaser's native v2.18.3 sboms for all compiled binaries (5), archives (5), and Debian/RPM packages (6); no new runtime dependency or custom packaging framework. All 16 SBOM records appeared in the non-publishing snapshot. The validation step checked the 11 archive and package SBOM files as CycloneDX documents with nonempty components.
  • Syft v1.54.1 was downloaded from the tagged upstream release with its SHA-256 archive digest fixed to c069905b391cc4c20a5ba65ad5c10be2a7ba074f8ea6ad203e24d14e303dad47; GoReleaser v2.18.3 was pinned and local config validation passed.
  • dockers_v2.sbom: true explicitly requests OCI SBOM attestations from buildx when images are published. Snapshot CI skips Docker to prevent registry side effects, as documented.
  • The existing release workflow remains tag-triggered, retains draft GitHub releases, and did not run or publish any real release during this review.

Open qualification (not covered by snapshot CI)

  1. Medium / release gate: After an authorized real release, verify that each published GHCR platform manifest has an SBOM attestation tied to its immutable digest, and that the base-image contents are reflected accurately. The snapshot intentionally cannot establish this.
  2. Medium / release gate: Verify the uploaded GitHub release assets and their corresponding SBOMs by their SHA-256 digests and that the published checksums and attestations refer to the same immutable artifact set. Ordinary checksums are not signed build provenance.
  3. Low: The non-publishing snapshot gate asserts 11 archive/package inventories; it does not independently inspect the 5 binary SBOM files or the checksum manifest, although GoReleaser did list those five SBOMs as outputs. Consider expanding assertions if this becomes a recurring release control.

Verdict: Configuration and artifact SBOM generation validated, suitable to keep as a separate draft PR. Do not claim complete published-image or signed release provenance without a release-stage validation. This branch is unrelated to the shutdown fix in PR #1.

@ryjen ryjen left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Final independent release-SBOM security review at exact head 11f7213dc4e4d04a2432ff927ac2c1d4f924f044.

Evidence

  • Release SBOM snapshot completed successfully, building actual release binaries, archives, Debian/RPM packages with GoReleaser v2.18.3 and checksum-verified Syft v1.54.1. Verified 11 archives/packages, 5 standalone binary inventories and 16 nonempty CycloneDX SBOMs, with exactly one checksum entry per SBOM. sha256sum --check checksums.txt passed on the locally generated outputs. Snapshot did not publish anything.
  • Test: all 8 jobs passed, including Linux/macOS/Windows, WASM browser, BSD and release cross-builds.
  • Nix passed.
  • Inspected the exact GoReleaser v2.18.3 source: internal/pipe/checksums/checksums.go uses artifact.ReleaseUploadableTypes(), which includes SBOM in internal/artifact/artifact.go. The redundant checksum.extra_files pattern introduced in 86a50b3 duplicated checksum entries; removed in 11f7213. Final snapshot verifies unique SBOM entries and matching checksums. No production code affected.

Still required / non-release blockers

  • Medium, release qualification: inspect the OCI index and per-platform (linux/amd64, linux/arm64) SBOM attestation descriptors and their immutable subject digests after a permitted registry publication. A --skip=docker snapshot cannot prove this.
  • Medium, provenance: checksums alone do not authenticate their producer; signing/SLSA provenance and release-asset verification against an authorized published release remain separate.
  • The release workflow still references the upstream ghcr.io/tailscale/tailcat repository and is tag-triggered, so no test tag or image was published on the fork. Do not use a real upstream image tag for qualification without authorization.

Verdict: Artifact inventories and local checksum integrity qualify for review, with all three exact-head CI workflows green. PR #3 should remain draft until release-stage OCI verification; upstream Tailcat tailscale#151 bug-fix PR #1 is unaffected.

@ryjen ryjen left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

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

Independent security review — exact head 60bd9a1eb9b809a91258b9fd78f6e31c2edc53ad.

All exact-head CI passed:

  • Release SBOM snapshot: generated and validated all 16 artifact-derived CycloneDX SBOMs (5 binaries, 5 archives, 6 Debian/RPM packages), ensured each appears exactly once in checksums.txt, and verified the checksum manifest.
  • Same snapshot also built both OCI platforms using the actual release Dockerfile, exported a non-published OCI layout and checked the in-toto SPDX SBOM manifests. The indexed linux/amd64 image manifest is sha256:1d5eb2e5ce775dfe5889561059c5eb3d18865865126514230f19e85b4244abbb; linux/arm64 is sha256:76830f58025794e4023ffc5e3962fb5d67db7ef7ad537a460abb1066c3f624e1.
  • Test: all 8 jobs passed. Nix: passed.
  • OCI verifier is standard-library Go, with five test cases and vet locally passed. It requires that OCI index attestation references and the OCI attestation manifest subject both identify the exact platform image-manifest digest. It rejects missing/forged bindings. BuildKit's embedded SPDX statements sometimes have empty subject arrays, so they are accepted only with this mandatory manifest-level cryptographic binding; nonempty statement subjects are checked against image manifest/config/layer digests.

Outstanding release-stage controls:

  1. Verify a published OCI digest on GHCR, platform attestation persistence, and final release asset/checksum integrity under authorized release credentials. The offline OCI index hash is not a GHCR digest.
  2. Release attestations/checksums are not producer signatures; signed provenance remains a distinct requirement.
  3. The OCI BuildKit SBOM scanner currently resolves a stable-1 generator tag during the snapshot. Pinning that scanner image by digest would improve generator reproducibility, if upstream maintainers want the additional control.

Verdict: The non-publishing binary/archive/package and OCI SBOM controls are independently validated with all exact-head workflows green. Safe for maintainer review as a separate draft PR; not a claim of published-release qualification. No version tag or upstream container image was pushed.

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.

Close can hang and leak the WireGuard engine and DERP connection: bump tailscale.com past the netstack close fix, and close the backend regardless

1 participant