-
Notifications
You must be signed in to change notification settings - Fork 596
Cosign support for SLSA Source Track #4210
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
Comments
Alright, so here are some options on the Option 1: try to take advantage of as many existing flags as possible
The only flag added here is actually Option 2: be more like sigstore-go
sigstore-go says that you, the user, are responsible for assembling the attestation and it will handle the rest. Instead of cosign being opinionated about the subject, predicate type, and requiring a blob, just pass the attestation you want signed and we'll sign it. This would be a departure from cosign's existing API, but it would be pretty easy to special case when the Here's what things would look like on the
Similar to signing, we've gotten rid of the required blob in favor of providing a hash. |
Back in February, @codysoyland made #4032 which is very similar to option 2 for |
I talked about my preferences in #4019 (comment), which is aligned to how we've created the sigstore-go API. I'd much rather smaller tools that we compose, with each smaller tool implementing the spec. If there isn't a tool to compose an unsigned SLSA source track statement yet, then we should create one, but let it be maintained as part of the SLSA community. Cosign can take in the unsigned statement and return a bundle with the signed Requiring
I also like that this makes no assumptions on what hash algorithm is supported, though this would require specifying a subject as well I believe. |
Oh also, option 2 is what Tom proposed in #4019. |
Uh oh!
There was an error while loading. Please reload this page.
Description
The draft of the SLSA Source Track includes an example in-toto statement. What are the gaps required to cover for cosign to be able to sign and verify these statements?
For signing, the
attest-blob
subcommand is close to what we want. It lets you specify the path to the predicate contents with--predicate
and the predicate type with--type
, but we don't have a way of setting the subject to match the example. And of course we'd use--new-bundle-format=true --bundle
to get a protobuf bundle that the Sigstore clients have standardized on.If we use
attest-blob
for signing, we should probably useverify-blob-attestation
for verification. We'd use--bundle
to supply the bundle from signing, but we also need some way to supply the hash we're expecting was used for signing (and again, likely it'd be SHA1 instead of SHA256). Here we have an advantage in thatverify-blob-attestation
will always usesigstore-go
(which we already know can verify these in-toto statements) if a protobuf bundle is being used, but we need a way to supply the hash (and hash algorithm) to send tosigstore-go
.In this description of the problem, I am purposefully not suggesting solutions. But people should feel free to propose solutions in the issue discussion!
The text was updated successfully, but these errors were encountered: