Skip to content

ci: publish the attestation bundle with each release - #91

Merged
groupsky merged 1 commit into
mainfrom
ci/attestation-bundle
Oct 16, 2026
Merged

groupsky merged 1 commit into
mainfrom
ci/attestation-bundle

Conversation

@groupsky

Copy link
Copy Markdown
Contributor

Each release now also has nodkey_<version>.sigstore.json: the build provenance attestation of both tarballs, as one Sigstore bundle. With this file, gh attestation verify --bundle needs no GitHub login. Without it, gh needs a login even for this public repository (cli/cli#11803). A broker host should have no GitHub login. The installer and nodkey update (#88) will use this file.

Changes

  • .github/workflows/release.yml, publish job:
    • The attest step has an id. A new step copies its bundle-path file to dist/nodkey_<version>.sigstore.json.
    • A new step checks both tarballs with this bundle and no login, with the same command as the docs. If the check fails, the release stays a draft.
    • The upload step adds the bundle to the files, before the release is published.
    • "Check the files and the tag" now also checks that the tag is v<version>. The version names the bundle file, and nobody can change a published release.
    • No new permission and no new action. Values reach the shell only through env:.
  • docs/releasing.md:
    • It lists the files of a release.
    • "Verify a download" uses VERSION and ARCH variables, shows a curl download with no login, and shows the --bundle check. It also says to use gh 2.93.0 or newer. No command line ends in a # comment: interactive zsh does not treat it as a comment by default.
    • A new step 3 checks the version. The attestation proves which workflow built the file, but not which version it is. Step 3 checks that the file's own name is in the attestation. This works on any machine. Then nodkey version on the machine the binary is for.
  • DESIGN.md section 18 has one sentence on the bundle file.

Review

The security review found nothing high or medium. These points are fixed:

  • gh release download needs a login only in gh older than 2.96.0. The docs said it always does.
  • Step 3, the version check, is new. Tested with no login: the 0.1.0 tarball passes it; the same file named nodkey_9.9.9_linux_amd64.tar.gz fails it.
  • The publish job checks that TAG matches VERSION.
  • The check step prints gh --version in the log.
  • The commands in the docs use one style.

The reviewer tested the check with gh 2.96.0 and no login. Both 0.1.0 tarballs passed. These all failed: an empty file, {}, a cut bundle, two bundles in one file, a release attestation, the wrong file and a missing bundle.

The last box of #87 (a real release has the file, and the check passes with no login) gets ticked after the next release, so this pull request does not close the issue.

Part of #87.

@groupsky
groupsky merged commit f6e47bb into main Oct 16, 2026
7 checks passed
@groupsky
groupsky deleted the ci/attestation-bundle branch October 16, 2026 22:17
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.

1 participant