MCPcopy Create free account
hub / github.com/conforma/cli / VerifyImageAttestations

Method VerifyImageAttestations

internal/utils/oci/client.go:123–132  ·  view source on GitHub ↗
(ref name.Reference, opts *cosign.CheckOpts)

Source from the content-addressed store, hash-verified

121}
122
123func (c *defaultClient) VerifyImageAttestations(ref name.Reference, opts *cosign.CheckOpts) ([]oci.Signature, bool, error) {
124 if trace.IsEnabled() {
125 region := trace.StartRegion(c.ctx, "ec:validate-image-attestations")
126 defer region.End()
127 trace.Logf(c.ctx, "", "image=%q", ref)
128 }
129
130 opts.RegistryClientOpts = append(opts.RegistryClientOpts, ociremote.WithRemoteOptions(c.opts...))
131 return cosign.VerifyImageAttestations(c.ctx, ref, opts)
132}
133
134func (c *defaultClient) FetchAttestationLayers(ref name.Reference) ([]oci.Signature, error) {
135 if trace.IsEnabled() {

Callers

nothing calls this directly

Calls 2

LogfMethod · 0.65

Tested by

no test coverage detected