Skip to content

feat(release): add build provenance attestations after goreleaser#138

Open
mvanhorn wants to merge 1 commit intoInfisical:mainfrom
mvanhorn:feat/108-attest-build-provenance
Open

feat(release): add build provenance attestations after goreleaser#138
mvanhorn wants to merge 1 commit intoInfisical:mainfrom
mvanhorn:feat/108-attest-build-provenance

Conversation

@mvanhorn
Copy link
Copy Markdown

Summary

Adds an actions/attest-build-provenance step after GoReleaser so release archives ship with SLSA build provenance, verifiable with gh attestation verify (no extra tooling).

Refs #108 (item 8). Per the maintainer's reply on that issue: "it'd be great if you could raise separate PRs for 8, 9, and 10."

Why this matters

Release archives currently ship signed checksums via cosign blob signing. That covers integrity but not the question "where did this binary actually come from?" — the same one the Trivy (March 2026) and tj-actions (March 2025) asset-swap incidents made expensive to answer. SLSA build provenance binds each artifact to the GitHub Actions run that produced it (workflow file, commit SHA, runner identity), and gh ships verification as a first-class subcommand. Per #108:

actions/attest-build-provenance after GoReleaser — enables gh attestation verify agent-vault_*.tar.gz --repo Infisical/agent-vault for users with zero extra tool install.

Changes

.github/workflows/release.yml:

  • Adds attestations: write to the job permissions block (alongside the existing id-token: write already used for cosign keyless).
  • Adds a Generate build provenance attestations step pinned to actions/attest-build-provenance@a2bbfa25375fe432b6a289bc6b6cd05ecd0c4c32 (v4.1.0), matching the repo's full-SHA pinning convention.
  • Subject paths cover the GoReleaser-emitted dist/*.tar.gz archives and dist/checksums.txt.

README.md:

  • Adds a ### Verifying downloaded release binaries subsection under Installation with the one-liner gh attestation verify agent-vault_*.tar.gz --repo Infisical/agent-vault.

Testing

  • python3 YAML parse confirms structure: permissions.attestations: write and the new step at position 10/10 with the v4.1.0 SHA.
  • go build ./... clean — Go module dependencies resolve.

End-to-end verification can only be exercised against a real tag push (the workflow is on: push: tags: v*). Suggest cutting an RC tag (e.g. v0.13.1-rc1) on a feature branch to verify the attestation publishes correctly before the next prod release.

Order with #9 and #10

This is item 8 of #108. Item 9 (docker_signs) is independent — happy to send next. Item 10 (install.sh cosign + checksum verify) was flagged by the original reporter as best ordered after this lands so it can prefer gh attestation verify when gh is available.

Fixes #108

This contribution was developed with AI assistance.

Refs Infisical#108 (item 8). Generates SLSA build provenance attestations for
release archives and checksums.txt. Users can verify with:

  gh attestation verify agent-vault_*.tar.gz --repo Infisical/agent-vault
Copy link
Copy Markdown

@claude claude Bot left a comment

Choose a reason for hiding this comment

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

Claude Code Review

This pull request is from a fork — automated review is disabled. A repository maintainer can comment @claude review to run a one-time review.

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.

Supply-chain hardening shortlist. Would any of these PRs be welcome?

1 participant