Add attestation file as a release artifact

Open
#1,653 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
48/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
github-actions, go
Domain
release, security

Research direction

The issue does not name a workflow or release configuration file. Start by locating the repository's release workflow and how it currently produces and attaches release artifacts; the body’s example shows the intended artifact name and verification flow. Done when releases include a downloadable attestation bundle usable with the shown gh attestation verify command without a GitHub login.

Written by the indexing model from the issue text.

Description

enhancement needs triage

Please add attestation file as a release artifact to enable verification without a requirement for GH login. Backround discussion @ https://github.com/cli/cli/issues/11803

This attestation file artifact is not to be confused with the Release attestation (json) file that GH automagically adds to your releases. The latter is not usable for attestation verification, or at least not without a login.

Example of how it works once implemented:

$ wget https://github.com/pypdfium2-team/pypdfium2/releases/download/5.9.0/pypdfium2-5.9.0.tar.gz
$ wget https://github.com/pypdfium2-team/pypdfium2/releases/download/5.9.0/pypdfium2-attestation.json
$ gh attestation trusted-root > trusted_root.jsonl   # This `gh attestation` flag does not require a GH login
$ gh attestation verify pypdfium2-5.9.0.tar.gz -R pypdfium2-team/pypdfium2 --bundle pypdfium2-attestation.json --custom-trusted-root trusted_root.jsonl
Loaded digest sha256:db1274bd27844db6fda17ef1dbcd0026c47d357437058d838e98060c0da9e92e for file://pypdfium2-5.9.0.tar.gz
Loaded 1 attestations from pypdfium2-attestation.json

The following policy criteria will be enforced:
- Predicate type must match:................ https://slsa.dev/provenance/v1
- Source Repository Owner URI must match:... https://github.com/pypdfium2-team
- Source Repository URI must match:......... https://github.com/pypdfium2-team/pypdfium2
- Subject Alternative Name must match regex: (?i)^https://github.com/pypdfium2-team/pypdfium2/
- OIDC Issuer must match:................... https://token.actions.githubusercontent.com

✓ Verification succeeded!

The following 1 attestation matched the policy criteria

- Attestation #1
  - Build repo:..... pypdfium2-team/pypdfium2
  - Build workflow:. .github/workflows/main.yaml@refs/heads/main
  - Signer repo:.... pypdfium2-team/pypdfium2
  - Signer workflow: .github/workflows/main.yaml@refs/heads/main
Dominant language
Go
Stars
4.3k
Forks
320
Avg merge
1d 21h
Merged PRs (30d)
10

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from smallstep/cli

All issues in smallstep/cli

Similar issues

More Go issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.