-
Notifications
You must be signed in to change notification settings - Fork 547
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
cosign cli doesn't recognize .../cryptoKeyVersions/$KEY_VERSION
#2094
Comments
I see in the error output it's prefixed with |
Hi @haydentherapper , The key ref in the |
To summarize working v.s. not-working key ref for signing & verification
|
cc @cdris |
@chuangw6 what version of cosign are you using? I think sigstore/sigstore@21bce79 fixes this, and was added to cosign in v0.10.0 The |
Before: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// After: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. Addresses sigstore#2094; I'm not sure if this fixes it, but it'll give us more information. Signed-off-by: Zachary Newman <z@znewman.net>
I think this is a bad error message; see #2220 |
Before: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// After: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. Addresses sigstore#2094; I'm not sure if this fixes it, but it'll give us more information. Signed-off-by: Zachary Newman <z@znewman.net>
Before: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: loading URL: unrecognized scheme: gcpkms:// After: $ KEY_REF=gcpkms://projects/test/locations/global/keyRings/test/cryptoKeys/mykey/cryptoKeyVersions/1 $ cosign verify-blob --key $KEY_REF --signature /dev/null /dev/null Error: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. main.go:62: error during command execution: verifying blob [/dev/null]: loading public key: new gcp kms client: google: could not find default credentials. See https://developers.google.com/accounts/docs/application-default-credentials for more information. Addresses #2094; I'm not sure if this fixes it, but it'll give us more information. Signed-off-by: Zachary Newman <z@znewman.net> Signed-off-by: Zachary Newman <z@znewman.net>
I'm closing this, as I believe between #2220 (better error message) and sigstore/sigstore#359 the issue is resolved. Please reopen if you're seeing this again. |
I want to use cosign cli to verify a signature that was generated using
sigstore
pkg with a gcp kms refgcpkms://projects/$PROJECT/locations/$LOCATION/keyRings/$KEYRING/cryptoKeys/$KEY/cryptoKeyVersions/$KEY_VERSION
.However, I got an error.
If I changed the
KEY_REF
from.../cryptoKeyVersions/1
to.../versions/1
, the cli verification works. If the version part/cryptoKeyVersions/1
is completely removed from theKEY_REF
, the cli verification also works.I am wondering if the verification with
../cryptoKeyVersions/$KEY_VERSION
is intentionally not supported by cosign cli or it is a bug.Thanks!
The text was updated successfully, but these errors were encountered: