Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

introduce Provenance Attestation #3548

Merged
merged 1 commit into from
May 28, 2024
Merged

Conversation

cpanato
Copy link
Contributor

@cpanato cpanato commented May 27, 2024

Overview

Add Provenance Attestation using GitHub Action and sigstore (https://github.blog/2024-05-02-introducing-artifact-attestations-now-in-public-beta/)

What this PR does / why we need it

This adds the provenance attestation and push the attestation to the same registry as the image.

  • per a limitation for the action it only pushes to ghcr.io and not to docker.io

Rehearsal:
job: https://github.com/cpanato/dex/actions/runs/9252829376/job/25451249054

attestation: https://github.com/cpanato/dex/attestations/921641 and attestation image: ghcr.io/cpanato/dex@sha256:8e5d24d7a0f0fe95bbdf6722e1c724075d5d4c15cfa8d0ef4959f25103e12bac

to verify

$ gh attestation verify oci://ghcr.io/cpanato/dex@sha256:8e5d24d7a0f0fe95bbdf6722e1c724075d5d4c15cfa8d0ef4959f25103e12bac --owner cpanato
Loaded digest sha256:8e5d24d7a0f0fe95bbdf6722e1c724075d5d4c15cfa8d0ef4959f25103e12bac for oci://ghcr.io/cpanato/dex@sha256:8e5d24d7a0f0fe95bbdf6722e1c724075d5d4c15cfa8d0ef4959f25103e12bac
Loaded 1 attestation from GitHub API
✓ Verification succeeded!

sha256:8e5d24d7a0f0fe95bbdf6722e1c724075d5d4c15cfa8d0ef4959f25103e12bac was attested by:
REPO         PREDICATE_TYPE                  WORKFLOW
cpanato/dex  https://slsa.dev/provenance/v1  .github/workflows/artifacts.yaml@refs/tags/v9.9.1

xref: #2865

Special notes for your reviewer

cc @justaugustus @sagikazarmark

@cpanato cpanato force-pushed the attestation branch 2 times, most recently from b2224b6 to fcbe1c3 Compare May 27, 2024 10:49
Copy link
Member

@sagikazarmark sagikazarmark left a comment

Choose a reason for hiding this comment

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

Thanks @cpanato ! One tiny nit, otherwise 🙏

.github/workflows/artifacts.yaml Outdated Show resolved Hide resolved
.github/workflows/artifacts.yaml Outdated Show resolved Hide resolved
Signed-off-by: cpanato <ctadeu@gmail.com>
@sagikazarmark sagikazarmark added the release-note/ignore Ignore this change when generating release notes label May 28, 2024
@sagikazarmark
Copy link
Member

Thanks @cpanato !

@sagikazarmark sagikazarmark merged commit 6b21e6a into dexidp:master May 28, 2024
9 of 10 checks passed
@cpanato cpanato deleted the attestation branch May 28, 2024 12:23
@justaugustus
Copy link
Member

Very nice; thanks @cpanato!

@cpanato
Copy link
Contributor Author

cpanato commented May 28, 2024

@sagikazarmark @justaugustus you can check the attestation for the main branch here: https://github.com/dexidp/dex/attestations/929115

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release-note/ignore Ignore this change when generating release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants