fleetlint Policy for a fleet of repositories
v0.11 (latest)
Getting started

release/provenance/gem

Releases attest build provenance

Implements release/provenance for the gem artifact: it runs when the release publishes one (see artifacts).

Severitywarning
Tiers1
Artifactgem
Scoperoot
Kindoutcome
Sourcelibrary v0.8.0
Selected byfleetlint-recommended@v0.8.0

Requirement

Gems are pushed by rubygems/release-gem with trusted publishing, which attaches Sigstore attestations.

Why

Provenance ties the artifact to the exact source and workflow that built it, which a signature alone does not.

Capability applies when

release.exists || repo.artifacts.size() > 0

Fix

Release with rubygems/release-gem from a job with id-token: write.

Agent instruction (from release/provenance): Use the registry’s own provenance where it has one: npm publish --provenance, pypa/gh-action-pypi-publish or rubygems/release-gem with trusted publishing, from a job with id-token: write. Otherwise add a step uses: actions/attest-build-provenance with subject-path covering the built files (or subject-name and subject-digest for an image or a chart in a registry, with push-to-registry: true); grant id-token: write and attestations: write to that job only. On GitLab set the variable RUNNER_GENERATE_ARTIFACTS_METADATA to “true” on the release job. On Gitea write a SLSA v1 predicate and run cosign attest-blob --type slsaprovenance1.

A finding that names no file points at the first workflow that publishes the artifact, or .github/workflows/release.yml when there is none.

Sources


Generated by fleetlint docs from catalog v0.8.0.