-
Notifications
You must be signed in to change notification settings - Fork 565
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
Allow pinning trust for verifying keyless signatures #556
Comments
+1 I like the idea of moving the certificate subject into the JSON, i want to add a delegation name into the JSON when we verify against sigstore delegations Also consider making it an n-values flag where... any one of? the emails can be used to verify? I'm not sure. that might make things confusing in case someone intends it to be all of them. |
We'll want to come up with a solution to ensure that either a) email domains are uniquely linked to identity providers or b) somehow namespace these IDs to identity providers when a given email is shared across multiple |
Sorry! We came up with a lightweight improvement here: https://sigstore.slack.com/archives/C01PZKDL4DP/p1629399218104900?thread_ts=1629399218.104900&cid=C01PZKDL4DP |
The tldr is to add an -email flag to verify, and one exit 0 if that email is present and verified. If the flag isn't passed, exit 1 but continue displaying all signatures. |
@dekkagaijin interesting point! While a question separate from the specific issue here, I think that is an important discussion for keyless signatures: Technically, GitHub cannot guarantee for |
if that is of interest, we could open a separate issue... |
Unless I am missing something, this makes me nervous to be honest. We are reducing the trust model down to some text (email) which will be set in a CI job. An attacker need then just compromise the script / yaml file etc in a GH action (or whichever CI is used) and the headlines say 'sigstore hacked'. Just to add, the current implementation was only temporary, this will be superseded by TUF policy. I think it makes better sense to direct users to implementing that, as that way they sign over the policy and the artifact and no trust pin to an email is needed. |
I think there's some confusion here. I'll try to summarize the confusing slack thread here a little later today. |
For now what I'm thinking is that we'll add support for asserting an expected subject (email) and then add in support for also asserting the identity provider behind that subject once supported by fulcio: sigstore/fulcio#44 I don't know if we'll ever want to support arbitrary ID providers, but the threat of ambiguous authority over an email is called out in that thread as well: sigstore/fulcio#44 (comment) |
Description
Trust pinning should be implemented for Keyless signatures by adding an optional
-email
parameter to thecosign verify
. This email can then be used as a trust anchor to validate the keyless signature and returned error code is 0 if theCertificate subject
contains the email or 1 if not.In case the optional
-email
is not specified, Cosign should always return 1 as the intent of cosign cannot be fulfilled (secure by default)Context
When verifying with Cosign, one provides a key and the signature data is validated against that key and the valid digest returned:
For keyless signatures, we break with this flow and one just asks to verify an image upon which one gets both trust root and digest returned and now as a user I decide whether I like the email handle I see.
It would be better to pin the trust to a trust anchor (and also move the certificate subject to the json):
The text was updated successfully, but these errors were encountered: