-
Couldn't load subscription status.
- Fork 646
Pass insecure registry flags through to referrers #4489
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
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4489 +/- ##
==========================================
- Coverage 40.10% 36.72% -3.38%
==========================================
Files 155 220 +65
Lines 10044 12125 +2081
==========================================
+ Hits 4028 4453 +425
- Misses 5530 6984 +1454
- Partials 486 688 +202 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
4b44e41 to
58c3a2f
Compare
|
I'm not sure if this is working right, or if I'm doing something wrong while testing this. I'm working off the instructions on https://github.com/tstromberg/sigstore-the-local-way?tab=readme-ov-file#11-starting-a-local-registry. I think But if I set up a DNS alias in ... then verification fails, both on Again, I might be doing something wrong here! |
Yep, cosign treats localhost and *.local as special because of google/go-containerregistry#125
I think |
I don't think this is it, because I'm running off an up-to-date But just to be sure, I checked again and got the same behavior. |
Also updates the registry tests to use TUF so that they can be re-used for both the legacy format and protobuf bundle format. Signed-off-by: Colleen Murphy <[email protected]>
58c3a2f to
8a0638e
Compare
|
@steiza you were right, and I fixed the tests to catch that issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One minor comment, but I'm also in favor of landing this as-is, since it is definitely an improvement!
| return err | ||
| } | ||
| if c.RegistryOptions.AllowHTTPRegistry || c.RegistryOptions.AllowInsecure { | ||
| ociremoteOpts = append(ociremoteOpts, ociremote.WithNameOptions(name.Insecure)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor: so our RegistryOptions.AllowHTTPRegistry maps to name.Insecure which both mean "it's okay if the registry uses plain HTTP without TLS.
But my interpretation of RegistryOptions.AllowInsecure is that the registry is using TLS, but with a self-signed certificate (or at least a certificate that doesn't verify with the machine's certificate store).
🤷 Are there people actually using that configuration? Or is everyone just using an HTTP registry? I guess we'll find out! I didn't see a "use TLS but allow certificates that don't verify with the machine's certificate store" on https://pkg.go.dev/github.com/google/[email protected]/pkg/name.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, it didn't seem like go-containerregistry makes a distinction between them.
Fixes #4466
Summary
Release Note
Documentation