fleetlint Policy for a fleet of repositories
v0.10
Getting started

release/provenance

Releases attest build provenance

A capability keyed by published artifact: each kind the release publishes is checked by its own implementation, and every one must pass. Implemented for android-app, apple-app, crate, gem, helm-chart, image, maven, npm, nuget, oci-artifact, pub, pypi, release-files.

Severitywarning
Tiers1
Stacksany
Scoperoot
Kindcapability
Sourcelibrary v0.7.0
Selected byfleetlint-recommended@v0.7.0

Requirement

Every artifact a release publishes carries a provenance attestation that ties it to the source commit and the workflow that built it: the registry’s own provenance where the artifact goes to one (npm, PyPI, RubyGems), otherwise an attestation on the artifact (GitHub artifact attestations, the SLSA generator, cosign attest for an image, cosign attest-blob for a file, BuildKit, GitLab artifact metadata). Each artifact kind’s implementation says what counts for it.

Why

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

Applies when

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

Fix

Add actions/attest-build-provenance (GitHub), RUNNER_GENERATE_ARTIFACTS_METADATA: "true" (GitLab) or cosign attest-blob --predicate (Gitea) to the release pipeline for files, cosign attest or BuildKit provenance for an image; a package published to npm, PyPI or RubyGems gets it from trusted publishing.

Agent instruction: Add a step uses: actions/attest-build-provenance with subject-path covering the release files (or subject-name and subject-digest for an image, 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.

Sources


Generated by fleetlint docs from catalog v0.7.0.