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

remove Verify in favor of explicit VerifyImage{Signatures, Attestations} #1026

Merged
merged 1 commit into from
Nov 11, 2021

Conversation

dekkagaijin
Copy link
Member

This is a first pass to begin disentangling and refactoring our verification flow to make it more usable, plugable, and extensible. Behavior should remain unchanged.

Starts addressing #844 and #931

[cosign/pkg]: `cosign.Verify` has been removed in favor of explicit `cosign.VerifyImageSignatures` and `cosign.VerifyImageAttestations`

pkg/cosign/verify.go Outdated Show resolved Hide resolved
pkg/cosign/verify.go Outdated Show resolved Hide resolved
pkg/cosign/verify.go Outdated Show resolved Hide resolved
pkg/cosign/verify.go Show resolved Hide resolved
pkg/cosign/verify.go Outdated Show resolved Hide resolved
pkg/cosign/verify.go Outdated Show resolved Hide resolved
// Find the uuid then the entry.
uuid, _, err := FindTlogEntry(rekorClient, b64sig, payload, pemBytes)
if err != nil {
if err := verifyBase64Signature(ctx, verifier, b64sig, payload); err != nil {
Copy link
Member

Choose a reason for hiding this comment

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

Rather than passing b64sig, which we know to be "" call this verifyAttestation, push the newReverseDSSEVerifier wrapper into this call, and have this take the signature.

Copy link
Member

@mattmoor mattmoor left a comment

Choose a reason for hiding this comment

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

Keep 'em coming

@dekkagaijin dekkagaijin merged commit 5a33731 into sigstore:main Nov 11, 2021
@dekkagaijin dekkagaijin deleted the verify branch November 11, 2021 18:36
@github-actions github-actions bot added this to the v1.4.0 milestone Nov 11, 2021
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.

2 participants