From cc2a26c1468c4e39ad82e108997cdf67eac955df Mon Sep 17 00:00:00 2001 From: Tonis Tiigi Date: Wed, 5 Nov 2025 15:55:57 -0800 Subject: [PATCH] vendor: update buildkit v0.26.0-rc1 Signed-off-by: Tonis Tiigi --- go.mod | 4 +- go.sum | 12 +- .../api/services/control/control.pb.go | 13 +- .../api/services/control/control.proto | 1 + .../services/control/control_vtproto.pb.go | 47 + .../moby/buildkit/client/llb/source.go | 4 +- .../client/llb/sourceresolver/types.go | 27 +- .../github.com/moby/buildkit/client/solve.go | 14 +- .../frontend/dockerui/namedcontext.go | 8 +- .../frontend/gateway/grpcclient/client.go | 70 +- .../frontend/gateway/pb/gateway.pb.go | 842 +++++++--- .../frontend/gateway/pb/gateway.proto | 29 +- .../frontend/gateway/pb/gateway_vtproto.pb.go | 1484 +++++++++++++++++ .../moby/buildkit/util/contentutil/fetcher.go | 16 +- .../auto/sdk/internal/telemetry/id.go | 2 +- .../auto/sdk/internal/telemetry/number.go | 2 +- .../auto/sdk/internal/telemetry/span.go | 70 +- .../auto/sdk/internal/telemetry/status.go | 10 +- .../auto/sdk/internal/telemetry/traces.go | 4 +- .../auto/sdk/internal/telemetry/value.go | 14 +- vendor/go.opentelemetry.io/auto/sdk/span.go | 25 +- vendor/go.opentelemetry.io/auto/sdk/tracer.go | 29 +- vendor/modules.txt | 6 +- 23 files changed, 2377 insertions(+), 356 deletions(-) diff --git a/go.mod b/go.mod index 28bc06109..a610b2795 100644 --- a/go.mod +++ b/go.mod @@ -29,7 +29,7 @@ require ( github.com/hashicorp/hcl/v2 v2.24.0 github.com/in-toto/in-toto-golang v0.9.0 github.com/mitchellh/hashstructure/v2 v2.0.2 - github.com/moby/buildkit v0.25.0-rc1.0.20251105204500-e18be4182830 + github.com/moby/buildkit v0.26.0-rc1 github.com/moby/go-archive v0.1.0 github.com/moby/sys/atomicwriter v0.1.0 github.com/moby/sys/mountinfo v0.7.2 @@ -147,7 +147,7 @@ require ( github.com/tonistiigi/vt100 v0.0.0-20240514184818-90bafcd6abab // indirect github.com/x448/float16 v0.8.4 // indirect github.com/xhit/go-str2duration/v2 v2.1.0 // indirect - go.opentelemetry.io/auto/sdk v1.1.0 // indirect + go.opentelemetry.io/auto/sdk v1.2.1 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.61.0 // indirect go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.61.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlpmetric/otlpmetricgrpc v1.38.0 // indirect diff --git a/go.sum b/go.sum index 419a16006..8b136a95a 100644 --- a/go.sum +++ b/go.sum @@ -252,8 +252,8 @@ github.com/mitchellh/go-wordwrap v1.0.1/go.mod h1:R62XHJLzvMFRBbcrT7m7WgmE1eOyTS github.com/mitchellh/hashstructure/v2 v2.0.2 h1:vGKWl0YJqUNxE8d+h8f6NJLcCJrgbhC4NcD46KavDd4= github.com/mitchellh/hashstructure/v2 v2.0.2/go.mod h1:MG3aRVU/N29oo/V/IhBX8GR/zz4kQkprJgF2EVszyDE= github.com/mitchellh/mapstructure v0.0.0-20150613213606-2caf8efc9366/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/moby/buildkit v0.25.0-rc1.0.20251105204500-e18be4182830 h1:uhSnuca3y3RfEmF5/27ZOA/sFDc9WWApOLM5W/57c4U= -github.com/moby/buildkit v0.25.0-rc1.0.20251105204500-e18be4182830/go.mod h1:IKOZJHc6vcPssXSDjpqamEormeIu/dgzw38NFZCmIp0= +github.com/moby/buildkit v0.26.0-rc1 h1:gAroxWAvEcssyohcbCb82cK7BIbmqugFy9+93AQT1eo= +github.com/moby/buildkit v0.26.0-rc1/go.mod h1:LiT7ohcE83rF/GtmoOBHj75+nUry+ili3FqZtlDkspo= github.com/moby/docker-image-spec v1.3.1 h1:jMKff3w6PgbfSa69GfNg+zN/XLhfXJGnEx3Nl2EsFP0= github.com/moby/docker-image-spec v1.3.1/go.mod h1:eKmb5VW8vQEh/BAr2yvVNvuiJuY6UIocYsFu/DxxRpo= github.com/moby/go-archive v0.1.0 h1:Kk/5rdW/g+H8NHdJW2gsXyZ7UnzvJNOy6VKJqueWdcQ= @@ -336,8 +336,8 @@ github.com/prometheus/procfs v0.16.1 h1:hZ15bTNuirocR6u0JZ6BAHHmwS1p8B4P6MRqxtzM github.com/prometheus/procfs v0.16.1/go.mod h1:teAbpZRB1iIAJYREa1LsoWUXykVXA1KlTmWl8x/U+Is= github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII= -github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o= +github.com/rogpeppe/go-internal v1.14.1 h1:UQB4HGPB6osV0SQTLymcB4TgvyWu6ZyliaW0tI/otEQ= +github.com/rogpeppe/go-internal v1.14.1/go.mod h1:MaRKkUm5W0goXpeCfT7UZI6fk/L7L7so1lCWt35ZSgc= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/santhosh-tekuri/jsonschema/v6 v6.0.1 h1:PKK9DyHxif4LZo+uQSgXNqs0jj5+xZwwfKHgph2lxBw= @@ -409,8 +409,8 @@ github.com/zclconf/go-cty-debug v0.0.0-20240509010212-0d6042c53940 h1:4r45xpDWB6 github.com/zclconf/go-cty-debug v0.0.0-20240509010212-0d6042c53940/go.mod h1:CmBdvvj3nqzfzJ6nTCIwDTPZ56aVGvDrmztiO5g3qrM= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= -go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= -go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= +go.opentelemetry.io/auto/sdk v1.2.1 h1:jXsnJ4Lmnqd11kwkBV2LgLoFMZKizbCi5fNZ/ipaZ64= +go.opentelemetry.io/auto/sdk v1.2.1/go.mod h1:KRTj+aOaElaLi+wW1kO/DZRXwkF4C5xPbEe3ZiIhN7Y= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.61.0 h1:q4XOmH/0opmeuJtPsbFNivyl7bCt7yRBbeEm2sC/XtQ= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.61.0/go.mod h1:snMWehoOh2wsEwnvvwtDyFCxVeDAODenXHtn5vzrKjo= go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.61.0 h1:lREC4C0ilyP4WibDhQ7Gg2ygAQFP8oR07Fst/5cafwI= diff --git a/vendor/github.com/moby/buildkit/api/services/control/control.pb.go b/vendor/github.com/moby/buildkit/api/services/control/control.pb.go index 0277173f9..2703e042a 100644 --- a/vendor/github.com/moby/buildkit/api/services/control/control.pb.go +++ b/vendor/github.com/moby/buildkit/api/services/control/control.pb.go @@ -408,6 +408,7 @@ type SolveRequest struct { SourcePolicy *pb1.Policy `protobuf:"bytes,12,opt,name=SourcePolicy,proto3" json:"SourcePolicy,omitempty"` Exporters []*Exporter `protobuf:"bytes,13,rep,name=Exporters,proto3" json:"Exporters,omitempty"` EnableSessionExporter bool `protobuf:"varint,14,opt,name=EnableSessionExporter,proto3" json:"EnableSessionExporter,omitempty"` + SourcePolicySession string `protobuf:"bytes,15,opt,name=SourcePolicySession,proto3" json:"SourcePolicySession,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } @@ -540,6 +541,13 @@ func (x *SolveRequest) GetEnableSessionExporter() bool { return false } +func (x *SolveRequest) GetSourcePolicySession() string { + if x != nil { + return x.SourcePolicySession + } + return "" +} + type CacheOptions struct { state protoimpl.MessageState `protogen:"open.v1"` // ExportRefDeprecated is deprecated in favor or the new Exports since BuildKit v0.4.0. @@ -2050,7 +2058,7 @@ const file_github_com_moby_buildkit_api_services_control_control_proto_rawDesc = " \x01(\tR\n" + "RecordType\x12\x16\n" + "\x06Shared\x18\v \x01(\bR\x06Shared\x12\x18\n" + - "\aParents\x18\f \x03(\tR\aParents\"\xf4\a\n" + + "\aParents\x18\f \x03(\tR\aParents\"\xa6\b\n" + "\fSolveRequest\x12\x10\n" + "\x03Ref\x18\x01 \x01(\tR\x03Ref\x12.\n" + "\n" + @@ -2068,7 +2076,8 @@ const file_github_com_moby_buildkit_api_services_control_control_proto_rawDesc = "\bInternal\x18\v \x01(\bR\bInternal\x12I\n" + "\fSourcePolicy\x18\f \x01(\v2%.moby.buildkit.v1.sourcepolicy.PolicyR\fSourcePolicy\x128\n" + "\tExporters\x18\r \x03(\v2\x1a.moby.buildkit.v1.ExporterR\tExporters\x124\n" + - "\x15EnableSessionExporter\x18\x0e \x01(\bR\x15EnableSessionExporter\x1aJ\n" + + "\x15EnableSessionExporter\x18\x0e \x01(\bR\x15EnableSessionExporter\x120\n" + + "\x13SourcePolicySession\x18\x0f \x01(\tR\x13SourcePolicySession\x1aJ\n" + "\x1cExporterAttrsDeprecatedEntry\x12\x10\n" + "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\x1a@\n" + diff --git a/vendor/github.com/moby/buildkit/api/services/control/control.proto b/vendor/github.com/moby/buildkit/api/services/control/control.proto index 3e47752ff..128408e84 100644 --- a/vendor/github.com/moby/buildkit/api/services/control/control.proto +++ b/vendor/github.com/moby/buildkit/api/services/control/control.proto @@ -76,6 +76,7 @@ message SolveRequest { moby.buildkit.v1.sourcepolicy.Policy SourcePolicy = 12; repeated Exporter Exporters = 13; bool EnableSessionExporter = 14; + string SourcePolicySession = 15; } message CacheOptions { diff --git a/vendor/github.com/moby/buildkit/api/services/control/control_vtproto.pb.go b/vendor/github.com/moby/buildkit/api/services/control/control_vtproto.pb.go index 1d72ca07e..4faf1b112 100644 --- a/vendor/github.com/moby/buildkit/api/services/control/control_vtproto.pb.go +++ b/vendor/github.com/moby/buildkit/api/services/control/control_vtproto.pb.go @@ -142,6 +142,7 @@ func (m *SolveRequest) CloneVT() *SolveRequest { r.Internal = m.Internal r.SourcePolicy = m.SourcePolicy.CloneVT() r.EnableSessionExporter = m.EnableSessionExporter + r.SourcePolicySession = m.SourcePolicySession if rhs := m.ExporterAttrsDeprecated; rhs != nil { tmpContainer := make(map[string]string, len(rhs)) for k, v := range rhs { @@ -1039,6 +1040,9 @@ func (this *SolveRequest) EqualVT(that *SolveRequest) bool { if this.EnableSessionExporter != that.EnableSessionExporter { return false } + if this.SourcePolicySession != that.SourcePolicySession { + return false + } return string(this.unknownFields) == string(that.unknownFields) } @@ -2245,6 +2249,13 @@ func (m *SolveRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error) { i -= len(m.unknownFields) copy(dAtA[i:], m.unknownFields) } + if len(m.SourcePolicySession) > 0 { + i -= len(m.SourcePolicySession) + copy(dAtA[i:], m.SourcePolicySession) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.SourcePolicySession))) + i-- + dAtA[i] = 0x7a + } if m.EnableSessionExporter { i-- if m.EnableSessionExporter { @@ -4159,6 +4170,10 @@ func (m *SolveRequest) SizeVT() (n int) { if m.EnableSessionExporter { n += 2 } + l = len(m.SourcePolicySession) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } n += len(m.unknownFields) return n } @@ -6279,6 +6294,38 @@ func (m *SolveRequest) UnmarshalVT(dAtA []byte) error { } } m.EnableSessionExporter = bool(v != 0) + case 15: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SourcePolicySession", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SourcePolicySession = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex default: iNdEx = preIndex skippy, err := protohelpers.Skip(dAtA[iNdEx:]) diff --git a/vendor/github.com/moby/buildkit/client/llb/source.go b/vendor/github.com/moby/buildkit/client/llb/source.go index fac14e507..857ff97bb 100644 --- a/vendor/github.com/moby/buildkit/client/llb/source.go +++ b/vendor/github.com/moby/buildkit/client/llb/source.go @@ -146,8 +146,8 @@ func Image(ref string, opts ...ImageOption) State { p = c.Platform } _, _, dt, err := info.metaResolver.ResolveImageConfig(ctx, ref, sourceresolver.Opt{ - Platform: p, ImageOpt: &sourceresolver.ResolveImageOpt{ + Platform: p, ResolveMode: info.resolveMode.String(), }, }) @@ -163,8 +163,8 @@ func Image(ref string, opts ...ImageOption) State { p = c.Platform } ref, dgst, dt, err := info.metaResolver.ResolveImageConfig(context.TODO(), ref, sourceresolver.Opt{ - Platform: p, ImageOpt: &sourceresolver.ResolveImageOpt{ + Platform: p, ResolveMode: info.resolveMode.String(), }, }) diff --git a/vendor/github.com/moby/buildkit/client/llb/sourceresolver/types.go b/vendor/github.com/moby/buildkit/client/llb/sourceresolver/types.go index bcdcf1719..82902c640 100644 --- a/vendor/github.com/moby/buildkit/client/llb/sourceresolver/types.go +++ b/vendor/github.com/moby/buildkit/client/llb/sourceresolver/types.go @@ -24,7 +24,6 @@ type MetaResolver interface { type Opt struct { LogName string SourcePolicies []*spb.Policy - Platform *ocispecs.Platform ImageOpt *ResolveImageOpt OCILayoutOpt *ResolveOCILayoutOpt @@ -40,12 +39,29 @@ type MetaResponse struct { } type ResolveImageOpt struct { - ResolveMode string + Platform *ocispecs.Platform + ResolveMode string + NoConfig bool + AttestationChain bool } type ResolveImageResponse struct { - Digest digest.Digest - Config []byte + Digest digest.Digest + Config []byte + AttestationChain *AttestationChain +} + +type AttestationChain struct { + Root digest.Digest + ImageManifest digest.Digest + AttestationManifest digest.Digest + SignatureManifests []digest.Digest + Blobs map[digest.Digest]Blob +} + +type Blob struct { + Descriptor ocispecs.Descriptor + Data []byte } type ResolveGitOpt struct { @@ -67,7 +83,8 @@ type ResolveHTTPResponse struct { } type ResolveOCILayoutOpt struct { - Store ResolveImageConfigOptStore + Platform *ocispecs.Platform + Store ResolveImageConfigOptStore } type ResolveImageConfigOptStore struct { diff --git a/vendor/github.com/moby/buildkit/client/solve.go b/vendor/github.com/moby/buildkit/client/solve.go index 991a37418..d94662a23 100644 --- a/vendor/github.com/moby/buildkit/client/solve.go +++ b/vendor/github.com/moby/buildkit/client/solve.go @@ -51,6 +51,7 @@ type SolveOpt struct { SessionPreInitialized bool // TODO: refactor to better session syncing Internal bool SourcePolicy *spb.Policy + SourcePolicyProvider session.Attachable Ref string } @@ -219,6 +220,10 @@ func (c *Client) solve(ctx context.Context, def *llb.Definition, runGateway runG s.Allow(filesync.NewFSSyncTarget(syncTargets...)) } + if opt.SourcePolicyProvider != nil { + s.Allow(opt.SourcePolicyProvider) + } + eg.Go(func() error { sd := c.sessionDialer if sd == nil { @@ -275,7 +280,7 @@ func (c *Client) solve(ctx context.Context, def *llb.Definition, runGateway runG }) } - resp, err := c.ControlClient().Solve(ctx, &controlapi.SolveRequest{ + sopt := &controlapi.SolveRequest{ Ref: ref, Definition: pbd, Exporters: exports, @@ -290,7 +295,12 @@ func (c *Client) solve(ctx context.Context, def *llb.Definition, runGateway runG Entitlements: slices.Clone(opt.AllowedEntitlements), Internal: opt.Internal, SourcePolicy: opt.SourcePolicy, - }) + } + if opt.SourcePolicyProvider != nil { + sopt.SourcePolicySession = s.ID() + } + + resp, err := c.ControlClient().Solve(ctx, sopt) if err != nil { return errors.Wrap(err, "failed to solve") } diff --git a/vendor/github.com/moby/buildkit/frontend/dockerui/namedcontext.go b/vendor/github.com/moby/buildkit/frontend/dockerui/namedcontext.go index 2033b3749..27aa51c88 100644 --- a/vendor/github.com/moby/buildkit/frontend/dockerui/namedcontext.go +++ b/vendor/github.com/moby/buildkit/frontend/dockerui/namedcontext.go @@ -94,9 +94,9 @@ func (nc *NamedContext) load(ctx context.Context, count int) (*llb.State, *docke named = reference.TagNameOnly(named) ref, dgst, data, err := nc.bc.client.ResolveImageConfig(ctx, named.String(), sourceresolver.Opt{ - LogName: fmt.Sprintf("[context %s] load metadata for %s", nc.nameWithPlatform, ref), - Platform: opt.Platform, + LogName: fmt.Sprintf("[context %s] load metadata for %s", nc.nameWithPlatform, ref), ImageOpt: &sourceresolver.ResolveImageOpt{ + Platform: opt.Platform, ResolveMode: opt.ResolveMode, }, }) @@ -183,9 +183,9 @@ func (nc *NamedContext) load(ctx context.Context, count int) (*llb.State, *docke } _, dgst, data, err := nc.bc.client.ResolveImageConfig(ctx, dummyRef.String(), sourceresolver.Opt{ - LogName: fmt.Sprintf("[context %s] load metadata for %s", nc.nameWithPlatform, dummyRef.String()), - Platform: opt.Platform, + LogName: fmt.Sprintf("[context %s] load metadata for %s", nc.nameWithPlatform, dummyRef.String()), OCILayoutOpt: &sourceresolver.ResolveOCILayoutOpt{ + Platform: opt.Platform, Store: sourceresolver.ResolveImageConfigOptStore{ SessionID: nc.bc.bopts.SessionID, StoreID: named.Name(), diff --git a/vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go b/vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go index bd77b7929..42e449a47 100644 --- a/vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go +++ b/vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go @@ -5,6 +5,7 @@ import ( "encoding/json" "fmt" "io" + "maps" "net" "os" "strings" @@ -25,6 +26,7 @@ import ( "github.com/moby/buildkit/util/imageutil" "github.com/moby/sys/signal" digest "github.com/opencontainers/go-digest" + ocispecs "github.com/opencontainers/image-spec/specs-go/v1" "github.com/pkg/errors" fstypes "github.com/tonistiigi/fsutil/types" "golang.org/x/sync/errgroup" @@ -497,8 +499,14 @@ func (c *grpcClient) ResolveSourceMetadata(ctx context.Context, op *opspb.Source }, nil } + var platform *ocispecs.Platform + if imgOpt := opt.ImageOpt; imgOpt != nil && imgOpt.Platform != nil { + platform = imgOpt.Platform + } else if ociOpt := opt.OCILayoutOpt; ociOpt != nil && ociOpt.Platform != nil { + platform = ociOpt.Platform + } var p *opspb.Platform - if platform := opt.Platform; platform != nil { + if platform != nil { p = &opspb.Platform{ OS: platform.OS, Architecture: platform.Architecture, @@ -514,6 +522,13 @@ func (c *grpcClient) ResolveSourceMetadata(ctx context.Context, op *opspb.Source LogName: opt.LogName, SourcePolicies: opt.SourcePolicies, } + if opt.ImageOpt != nil { + req.Image = &pb.ResolveSourceImageRequest{ + NoConfig: opt.ImageOpt.NoConfig, + AttestationChain: opt.ImageOpt.AttestationChain, + } + } + if opt.GitOpt != nil { req.Git = &pb.ResolveSourceGitRequest{ ReturnObject: opt.GitOpt.ReturnObject, @@ -529,10 +544,7 @@ func (c *grpcClient) ResolveSourceMetadata(ctx context.Context, op *opspb.Source Op: resp.Source, } if resp.Image != nil { - r.Image = &sourceresolver.ResolveImageResponse{ - Digest: digest.Digest(resp.Image.Digest), - Config: resp.Image.Config, - } + r.Image = imgResponseFromPB(resp.Image) } if resp.Git != nil { r.Git = &sourceresolver.ResolveGitResponse{ @@ -561,6 +573,45 @@ func (c *grpcClient) ResolveSourceMetadata(ctx context.Context, op *opspb.Source return r, nil } +func imgResponseFromPB(resp *pb.ResolveSourceImageResponse) *sourceresolver.ResolveImageResponse { + r := &sourceresolver.ResolveImageResponse{ + Digest: digest.Digest(resp.Digest), + Config: resp.Config, + } + if resp.AttestationChain != nil { + ac := &sourceresolver.AttestationChain{ + Root: digest.Digest(resp.AttestationChain.Root), + ImageManifest: digest.Digest(resp.AttestationChain.ImageManifest), + AttestationManifest: digest.Digest(resp.AttestationChain.AttestationManifest), + SignatureManifests: []digest.Digest{}, + Blobs: map[digest.Digest]sourceresolver.Blob{}, + } + for _, sm := range resp.AttestationChain.SignatureManifests { + ac.SignatureManifests = append(ac.SignatureManifests, digest.Digest(sm)) + } + for k, v := range resp.AttestationChain.Blobs { + ac.Blobs[digest.Digest(k)] = sourceresolver.Blob{ + Descriptor: descriptorFromPB(v.GetDescriptor_()), + Data: v.Data, + } + } + r.AttestationChain = ac + } + return r +} + +func descriptorFromPB(pbDesc *pb.Descriptor) ocispecs.Descriptor { + if pbDesc == nil { + return ocispecs.Descriptor{} + } + return ocispecs.Descriptor{ + MediaType: pbDesc.GetMediaType(), + Size: pbDesc.GetSize(), + Digest: digest.Digest(pbDesc.GetDigest()), + Annotations: maps.Clone(pbDesc.GetAnnotations()), + } +} + func (c *grpcClient) resolveImageConfigViaSourceMetadata(ctx context.Context, ref string, opt sourceresolver.Opt, p *opspb.Platform) (string, digest.Digest, []byte, error) { op := &opspb.SourceOp{ Identifier: "docker-image://" + ref, @@ -596,8 +647,15 @@ func (c *grpcClient) resolveImageConfigViaSourceMetadata(ctx context.Context, re } func (c *grpcClient) ResolveImageConfig(ctx context.Context, ref string, opt sourceresolver.Opt) (string, digest.Digest, []byte, error) { + var platform *ocispecs.Platform + if imgOpt := opt.ImageOpt; imgOpt != nil && imgOpt.Platform != nil { + platform = imgOpt.Platform + } else if ociOpt := opt.OCILayoutOpt; ociOpt != nil && ociOpt.Platform != nil { + platform = ociOpt.Platform + } + var p *opspb.Platform - if platform := opt.Platform; platform != nil { + if platform != nil { p = &opspb.Platform{ OS: platform.OS, Architecture: platform.Architecture, diff --git a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.pb.go b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.pb.go index fb1f7ab1d..4a958a42a 100644 --- a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.pb.go +++ b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.pb.go @@ -909,13 +909,14 @@ func (x *ResolveImageConfigResponse) GetRef() string { } type ResolveSourceMetaRequest struct { - state protoimpl.MessageState `protogen:"open.v1"` - Source *pb.SourceOp `protobuf:"bytes,1,opt,name=Source,proto3" json:"Source,omitempty"` - Platform *pb.Platform `protobuf:"bytes,2,opt,name=Platform,proto3" json:"Platform,omitempty"` - LogName string `protobuf:"bytes,3,opt,name=LogName,proto3" json:"LogName,omitempty"` - ResolveMode string `protobuf:"bytes,4,opt,name=ResolveMode,proto3" json:"ResolveMode,omitempty"` - SourcePolicies []*pb1.Policy `protobuf:"bytes,8,rep,name=SourcePolicies,proto3" json:"SourcePolicies,omitempty"` - Git *ResolveSourceGitRequest `protobuf:"bytes,5,opt,name=Git,proto3" json:"Git,omitempty"` + state protoimpl.MessageState `protogen:"open.v1"` + Source *pb.SourceOp `protobuf:"bytes,1,opt,name=Source,proto3" json:"Source,omitempty"` + Platform *pb.Platform `protobuf:"bytes,2,opt,name=Platform,proto3" json:"Platform,omitempty"` + LogName string `protobuf:"bytes,3,opt,name=LogName,proto3" json:"LogName,omitempty"` + ResolveMode string `protobuf:"bytes,4,opt,name=ResolveMode,proto3" json:"ResolveMode,omitempty"` + Git *ResolveSourceGitRequest `protobuf:"bytes,5,opt,name=Git,proto3" json:"Git,omitempty"` + Image *ResolveSourceImageRequest `protobuf:"bytes,6,opt,name=Image,proto3" json:"Image,omitempty"` + SourcePolicies []*pb1.Policy `protobuf:"bytes,8,rep,name=SourcePolicies,proto3" json:"SourcePolicies,omitempty"` unknownFields protoimpl.UnknownFields sizeCache protoimpl.SizeCache } @@ -978,16 +979,23 @@ func (x *ResolveSourceMetaRequest) GetResolveMode() string { return "" } -func (x *ResolveSourceMetaRequest) GetSourcePolicies() []*pb1.Policy { +func (x *ResolveSourceMetaRequest) GetGit() *ResolveSourceGitRequest { if x != nil { - return x.SourcePolicies + return x.Git } return nil } -func (x *ResolveSourceMetaRequest) GetGit() *ResolveSourceGitRequest { +func (x *ResolveSourceMetaRequest) GetImage() *ResolveSourceImageRequest { if x != nil { - return x.Git + return x.Image + } + return nil +} + +func (x *ResolveSourceMetaRequest) GetSourcePolicies() []*pb1.Policy { + if x != nil { + return x.SourcePolicies } return nil } @@ -1060,17 +1068,146 @@ func (x *ResolveSourceMetaResponse) GetHTTP() *ResolveSourceHTTPResponse { return nil } +type ResolveSourceImageRequest struct { + state protoimpl.MessageState `protogen:"open.v1"` + NoConfig bool `protobuf:"varint,1,opt,name=NoConfig,proto3" json:"NoConfig,omitempty"` + AttestationChain bool `protobuf:"varint,2,opt,name=AttestationChain,proto3" json:"AttestationChain,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *ResolveSourceImageRequest) Reset() { + *x = ResolveSourceImageRequest{} + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *ResolveSourceImageRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ResolveSourceImageRequest) ProtoMessage() {} + +func (x *ResolveSourceImageRequest) ProtoReflect() protoreflect.Message { + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[15] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ResolveSourceImageRequest.ProtoReflect.Descriptor instead. +func (*ResolveSourceImageRequest) Descriptor() ([]byte, []int) { + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{15} +} + +func (x *ResolveSourceImageRequest) GetNoConfig() bool { + if x != nil { + return x.NoConfig + } + return false +} + +func (x *ResolveSourceImageRequest) GetAttestationChain() bool { + if x != nil { + return x.AttestationChain + } + return false +} + +type AttestationChain struct { + state protoimpl.MessageState `protogen:"open.v1"` + Root string `protobuf:"bytes,1,opt,name=Root,proto3" json:"Root,omitempty"` + ImageManifest string `protobuf:"bytes,2,opt,name=ImageManifest,proto3" json:"ImageManifest,omitempty"` + AttestationManifest string `protobuf:"bytes,3,opt,name=AttestationManifest,proto3" json:"AttestationManifest,omitempty"` + SignatureManifests []string `protobuf:"bytes,4,rep,name=SignatureManifests,proto3" json:"SignatureManifests,omitempty"` + Blobs map[string]*Blob `protobuf:"bytes,5,rep,name=Blobs,proto3" json:"Blobs,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *AttestationChain) Reset() { + *x = AttestationChain{} + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *AttestationChain) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttestationChain) ProtoMessage() {} + +func (x *AttestationChain) ProtoReflect() protoreflect.Message { + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[16] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use AttestationChain.ProtoReflect.Descriptor instead. +func (*AttestationChain) Descriptor() ([]byte, []int) { + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{16} +} + +func (x *AttestationChain) GetRoot() string { + if x != nil { + return x.Root + } + return "" +} + +func (x *AttestationChain) GetImageManifest() string { + if x != nil { + return x.ImageManifest + } + return "" +} + +func (x *AttestationChain) GetAttestationManifest() string { + if x != nil { + return x.AttestationManifest + } + return "" +} + +func (x *AttestationChain) GetSignatureManifests() []string { + if x != nil { + return x.SignatureManifests + } + return nil +} + +func (x *AttestationChain) GetBlobs() map[string]*Blob { + if x != nil { + return x.Blobs + } + return nil +} + type ResolveSourceImageResponse struct { - state protoimpl.MessageState `protogen:"open.v1"` - Digest string `protobuf:"bytes,1,opt,name=Digest,proto3" json:"Digest,omitempty"` - Config []byte `protobuf:"bytes,2,opt,name=Config,proto3" json:"Config,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache + state protoimpl.MessageState `protogen:"open.v1"` + Digest string `protobuf:"bytes,1,opt,name=Digest,proto3" json:"Digest,omitempty"` + Config []byte `protobuf:"bytes,2,opt,name=Config,proto3" json:"Config,omitempty"` + AttestationChain *AttestationChain `protobuf:"bytes,3,opt,name=AttestationChain,proto3" json:"AttestationChain,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache } func (x *ResolveSourceImageResponse) Reset() { *x = ResolveSourceImageResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[15] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1082,7 +1219,7 @@ func (x *ResolveSourceImageResponse) String() string { func (*ResolveSourceImageResponse) ProtoMessage() {} func (x *ResolveSourceImageResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[15] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[17] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1095,7 +1232,7 @@ func (x *ResolveSourceImageResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ResolveSourceImageResponse.ProtoReflect.Descriptor instead. func (*ResolveSourceImageResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{15} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{17} } func (x *ResolveSourceImageResponse) GetDigest() string { @@ -1112,6 +1249,13 @@ func (x *ResolveSourceImageResponse) GetConfig() []byte { return nil } +func (x *ResolveSourceImageResponse) GetAttestationChain() *AttestationChain { + if x != nil { + return x.AttestationChain + } + return nil +} + type ResolveSourceGitRequest struct { state protoimpl.MessageState `protogen:"open.v1"` // Return full commit and tag object bytes. @@ -1122,7 +1266,7 @@ type ResolveSourceGitRequest struct { func (x *ResolveSourceGitRequest) Reset() { *x = ResolveSourceGitRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[16] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1134,7 +1278,7 @@ func (x *ResolveSourceGitRequest) String() string { func (*ResolveSourceGitRequest) ProtoMessage() {} func (x *ResolveSourceGitRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[16] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[18] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1147,7 +1291,7 @@ func (x *ResolveSourceGitRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ResolveSourceGitRequest.ProtoReflect.Descriptor instead. func (*ResolveSourceGitRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{16} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{18} } func (x *ResolveSourceGitRequest) GetReturnObject() bool { @@ -1170,7 +1314,7 @@ type ResolveSourceGitResponse struct { func (x *ResolveSourceGitResponse) Reset() { *x = ResolveSourceGitResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[17] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1182,7 +1326,7 @@ func (x *ResolveSourceGitResponse) String() string { func (*ResolveSourceGitResponse) ProtoMessage() {} func (x *ResolveSourceGitResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[17] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[19] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1195,7 +1339,7 @@ func (x *ResolveSourceGitResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ResolveSourceGitResponse.ProtoReflect.Descriptor instead. func (*ResolveSourceGitResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{17} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{19} } func (x *ResolveSourceGitResponse) GetChecksum() string { @@ -1244,7 +1388,7 @@ type ResolveSourceHTTPResponse struct { func (x *ResolveSourceHTTPResponse) Reset() { *x = ResolveSourceHTTPResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[18] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1256,7 +1400,7 @@ func (x *ResolveSourceHTTPResponse) String() string { func (*ResolveSourceHTTPResponse) ProtoMessage() {} func (x *ResolveSourceHTTPResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[18] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[20] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1269,7 +1413,7 @@ func (x *ResolveSourceHTTPResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ResolveSourceHTTPResponse.ProtoReflect.Descriptor instead. func (*ResolveSourceHTTPResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{18} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{20} } func (x *ResolveSourceHTTPResponse) GetChecksum() string { @@ -1317,7 +1461,7 @@ type SolveRequest struct { func (x *SolveRequest) Reset() { *x = SolveRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[19] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1329,7 +1473,7 @@ func (x *SolveRequest) String() string { func (*SolveRequest) ProtoMessage() {} func (x *SolveRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[19] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[21] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1342,7 +1486,7 @@ func (x *SolveRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use SolveRequest.ProtoReflect.Descriptor instead. func (*SolveRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{19} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{21} } func (x *SolveRequest) GetDefinition() *pb.Definition { @@ -1433,7 +1577,7 @@ type CacheOptionsEntry struct { func (x *CacheOptionsEntry) Reset() { *x = CacheOptionsEntry{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[20] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1445,7 +1589,7 @@ func (x *CacheOptionsEntry) String() string { func (*CacheOptionsEntry) ProtoMessage() {} func (x *CacheOptionsEntry) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[20] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[22] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1458,7 +1602,7 @@ func (x *CacheOptionsEntry) ProtoReflect() protoreflect.Message { // Deprecated: Use CacheOptionsEntry.ProtoReflect.Descriptor instead. func (*CacheOptionsEntry) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{20} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{22} } func (x *CacheOptionsEntry) GetType() string { @@ -1487,7 +1631,7 @@ type SolveResponse struct { func (x *SolveResponse) Reset() { *x = SolveResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[21] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1499,7 +1643,7 @@ func (x *SolveResponse) String() string { func (*SolveResponse) ProtoMessage() {} func (x *SolveResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[21] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[23] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1512,7 +1656,7 @@ func (x *SolveResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use SolveResponse.ProtoReflect.Descriptor instead. func (*SolveResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{21} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{23} } func (x *SolveResponse) GetRef() string { @@ -1540,7 +1684,7 @@ type ReadFileRequest struct { func (x *ReadFileRequest) Reset() { *x = ReadFileRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[22] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1552,7 +1696,7 @@ func (x *ReadFileRequest) String() string { func (*ReadFileRequest) ProtoMessage() {} func (x *ReadFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[22] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[24] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1565,7 +1709,7 @@ func (x *ReadFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadFileRequest.ProtoReflect.Descriptor instead. func (*ReadFileRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{22} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{24} } func (x *ReadFileRequest) GetRef() string { @@ -1599,7 +1743,7 @@ type FileRange struct { func (x *FileRange) Reset() { *x = FileRange{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[23] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1611,7 +1755,7 @@ func (x *FileRange) String() string { func (*FileRange) ProtoMessage() {} func (x *FileRange) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[23] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[25] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1624,7 +1768,7 @@ func (x *FileRange) ProtoReflect() protoreflect.Message { // Deprecated: Use FileRange.ProtoReflect.Descriptor instead. func (*FileRange) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{23} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{25} } func (x *FileRange) GetOffset() int64 { @@ -1650,7 +1794,7 @@ type ReadFileResponse struct { func (x *ReadFileResponse) Reset() { *x = ReadFileResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[24] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1662,7 +1806,7 @@ func (x *ReadFileResponse) String() string { func (*ReadFileResponse) ProtoMessage() {} func (x *ReadFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[24] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[26] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1675,7 +1819,7 @@ func (x *ReadFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadFileResponse.ProtoReflect.Descriptor instead. func (*ReadFileResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{24} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{26} } func (x *ReadFileResponse) GetData() []byte { @@ -1696,7 +1840,7 @@ type ReadDirRequest struct { func (x *ReadDirRequest) Reset() { *x = ReadDirRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[25] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1708,7 +1852,7 @@ func (x *ReadDirRequest) String() string { func (*ReadDirRequest) ProtoMessage() {} func (x *ReadDirRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[25] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[27] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1721,7 +1865,7 @@ func (x *ReadDirRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadDirRequest.ProtoReflect.Descriptor instead. func (*ReadDirRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{25} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{27} } func (x *ReadDirRequest) GetRef() string { @@ -1754,7 +1898,7 @@ type ReadDirResponse struct { func (x *ReadDirResponse) Reset() { *x = ReadDirResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[26] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1766,7 +1910,7 @@ func (x *ReadDirResponse) String() string { func (*ReadDirResponse) ProtoMessage() {} func (x *ReadDirResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[26] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[28] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1779,7 +1923,7 @@ func (x *ReadDirResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ReadDirResponse.ProtoReflect.Descriptor instead. func (*ReadDirResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{26} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{28} } func (x *ReadDirResponse) GetEntries() []*types.Stat { @@ -1799,7 +1943,7 @@ type StatFileRequest struct { func (x *StatFileRequest) Reset() { *x = StatFileRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[27] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1811,7 +1955,7 @@ func (x *StatFileRequest) String() string { func (*StatFileRequest) ProtoMessage() {} func (x *StatFileRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[27] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[29] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1824,7 +1968,7 @@ func (x *StatFileRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use StatFileRequest.ProtoReflect.Descriptor instead. func (*StatFileRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{27} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{29} } func (x *StatFileRequest) GetRef() string { @@ -1850,7 +1994,7 @@ type StatFileResponse struct { func (x *StatFileResponse) Reset() { *x = StatFileResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[28] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[30] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1862,7 +2006,7 @@ func (x *StatFileResponse) String() string { func (*StatFileResponse) ProtoMessage() {} func (x *StatFileResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[28] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[30] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1875,7 +2019,7 @@ func (x *StatFileResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use StatFileResponse.ProtoReflect.Descriptor instead. func (*StatFileResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{28} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{30} } func (x *StatFileResponse) GetStat() *types.Stat { @@ -1894,7 +2038,7 @@ type EvaluateRequest struct { func (x *EvaluateRequest) Reset() { *x = EvaluateRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[29] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[31] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1906,7 +2050,7 @@ func (x *EvaluateRequest) String() string { func (*EvaluateRequest) ProtoMessage() {} func (x *EvaluateRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[29] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[31] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1919,7 +2063,7 @@ func (x *EvaluateRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use EvaluateRequest.ProtoReflect.Descriptor instead. func (*EvaluateRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{29} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{31} } func (x *EvaluateRequest) GetRef() string { @@ -1937,7 +2081,7 @@ type EvaluateResponse struct { func (x *EvaluateResponse) Reset() { *x = EvaluateResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[30] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[32] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1949,7 +2093,7 @@ func (x *EvaluateResponse) String() string { func (*EvaluateResponse) ProtoMessage() {} func (x *EvaluateResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[30] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[32] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1962,7 +2106,7 @@ func (x *EvaluateResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use EvaluateResponse.ProtoReflect.Descriptor instead. func (*EvaluateResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{30} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{32} } type PingRequest struct { @@ -1973,7 +2117,7 @@ type PingRequest struct { func (x *PingRequest) Reset() { *x = PingRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[31] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[33] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1985,7 +2129,7 @@ func (x *PingRequest) String() string { func (*PingRequest) ProtoMessage() {} func (x *PingRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[31] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[33] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1998,7 +2142,7 @@ func (x *PingRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use PingRequest.ProtoReflect.Descriptor instead. func (*PingRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{31} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{33} } type PongResponse struct { @@ -2012,7 +2156,7 @@ type PongResponse struct { func (x *PongResponse) Reset() { *x = PongResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[32] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[34] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2024,7 +2168,7 @@ func (x *PongResponse) String() string { func (*PongResponse) ProtoMessage() {} func (x *PongResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[32] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[34] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2037,7 +2181,7 @@ func (x *PongResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use PongResponse.ProtoReflect.Descriptor instead. func (*PongResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{32} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{34} } func (x *PongResponse) GetFrontendAPICaps() []*pb2.APICap { @@ -2076,7 +2220,7 @@ type WarnRequest struct { func (x *WarnRequest) Reset() { *x = WarnRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[33] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[35] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2088,7 +2232,7 @@ func (x *WarnRequest) String() string { func (*WarnRequest) ProtoMessage() {} func (x *WarnRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[33] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[35] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2101,7 +2245,7 @@ func (x *WarnRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use WarnRequest.ProtoReflect.Descriptor instead. func (*WarnRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{33} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{35} } func (x *WarnRequest) GetDigest() string { @@ -2161,7 +2305,7 @@ type WarnResponse struct { func (x *WarnResponse) Reset() { *x = WarnResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[34] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[36] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2173,7 +2317,7 @@ func (x *WarnResponse) String() string { func (*WarnResponse) ProtoMessage() {} func (x *WarnResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[34] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[36] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2186,7 +2330,7 @@ func (x *WarnResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use WarnResponse.ProtoReflect.Descriptor instead. func (*WarnResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{34} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{36} } type NewContainerRequest struct { @@ -2205,7 +2349,7 @@ type NewContainerRequest struct { func (x *NewContainerRequest) Reset() { *x = NewContainerRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[35] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[37] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2217,7 +2361,7 @@ func (x *NewContainerRequest) String() string { func (*NewContainerRequest) ProtoMessage() {} func (x *NewContainerRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[35] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[37] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2230,7 +2374,7 @@ func (x *NewContainerRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use NewContainerRequest.ProtoReflect.Descriptor instead. func (*NewContainerRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{35} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{37} } func (x *NewContainerRequest) GetContainerID() string { @@ -2290,7 +2434,7 @@ type NewContainerResponse struct { func (x *NewContainerResponse) Reset() { *x = NewContainerResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[36] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[38] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2302,7 +2446,7 @@ func (x *NewContainerResponse) String() string { func (*NewContainerResponse) ProtoMessage() {} func (x *NewContainerResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[36] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[38] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2315,7 +2459,7 @@ func (x *NewContainerResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use NewContainerResponse.ProtoReflect.Descriptor instead. func (*NewContainerResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{36} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{38} } type ReleaseContainerRequest struct { @@ -2327,7 +2471,7 @@ type ReleaseContainerRequest struct { func (x *ReleaseContainerRequest) Reset() { *x = ReleaseContainerRequest{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[37] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[39] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2339,7 +2483,7 @@ func (x *ReleaseContainerRequest) String() string { func (*ReleaseContainerRequest) ProtoMessage() {} func (x *ReleaseContainerRequest) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[37] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[39] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2352,7 +2496,7 @@ func (x *ReleaseContainerRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ReleaseContainerRequest.ProtoReflect.Descriptor instead. func (*ReleaseContainerRequest) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{37} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{39} } func (x *ReleaseContainerRequest) GetContainerID() string { @@ -2370,7 +2514,7 @@ type ReleaseContainerResponse struct { func (x *ReleaseContainerResponse) Reset() { *x = ReleaseContainerResponse{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[38] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[40] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2382,7 +2526,7 @@ func (x *ReleaseContainerResponse) String() string { func (*ReleaseContainerResponse) ProtoMessage() {} func (x *ReleaseContainerResponse) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[38] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[40] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2395,7 +2539,7 @@ func (x *ReleaseContainerResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ReleaseContainerResponse.ProtoReflect.Descriptor instead. func (*ReleaseContainerResponse) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{38} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{40} } type ExecMessage struct { @@ -2417,7 +2561,7 @@ type ExecMessage struct { func (x *ExecMessage) Reset() { *x = ExecMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[39] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[41] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2429,7 +2573,7 @@ func (x *ExecMessage) String() string { func (*ExecMessage) ProtoMessage() {} func (x *ExecMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[39] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[41] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2442,7 +2586,7 @@ func (x *ExecMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use ExecMessage.ProtoReflect.Descriptor instead. func (*ExecMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{39} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{41} } func (x *ExecMessage) GetProcessID() string { @@ -2594,7 +2738,7 @@ type InitMessage struct { func (x *InitMessage) Reset() { *x = InitMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[40] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[42] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2606,7 +2750,7 @@ func (x *InitMessage) String() string { func (*InitMessage) ProtoMessage() {} func (x *InitMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[40] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[42] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2619,7 +2763,7 @@ func (x *InitMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use InitMessage.ProtoReflect.Descriptor instead. func (*InitMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{40} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{42} } func (x *InitMessage) GetContainerID() string { @@ -2674,7 +2818,7 @@ type ExitMessage struct { func (x *ExitMessage) Reset() { *x = ExitMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[41] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[43] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2686,7 +2830,7 @@ func (x *ExitMessage) String() string { func (*ExitMessage) ProtoMessage() {} func (x *ExitMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[41] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[43] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2699,7 +2843,7 @@ func (x *ExitMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use ExitMessage.ProtoReflect.Descriptor instead. func (*ExitMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{41} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{43} } func (x *ExitMessage) GetCode() uint32 { @@ -2724,7 +2868,7 @@ type StartedMessage struct { func (x *StartedMessage) Reset() { *x = StartedMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[42] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[44] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2736,7 +2880,7 @@ func (x *StartedMessage) String() string { func (*StartedMessage) ProtoMessage() {} func (x *StartedMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[42] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[44] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2749,7 +2893,7 @@ func (x *StartedMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use StartedMessage.ProtoReflect.Descriptor instead. func (*StartedMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{42} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{44} } type DoneMessage struct { @@ -2760,7 +2904,7 @@ type DoneMessage struct { func (x *DoneMessage) Reset() { *x = DoneMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[43] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[45] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2772,7 +2916,7 @@ func (x *DoneMessage) String() string { func (*DoneMessage) ProtoMessage() {} func (x *DoneMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[43] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[45] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2785,7 +2929,7 @@ func (x *DoneMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use DoneMessage.ProtoReflect.Descriptor instead. func (*DoneMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{43} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{45} } type FdMessage struct { @@ -2799,7 +2943,7 @@ type FdMessage struct { func (x *FdMessage) Reset() { *x = FdMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[44] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[46] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2811,7 +2955,7 @@ func (x *FdMessage) String() string { func (*FdMessage) ProtoMessage() {} func (x *FdMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[44] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[46] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2824,7 +2968,7 @@ func (x *FdMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use FdMessage.ProtoReflect.Descriptor instead. func (*FdMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{44} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{46} } func (x *FdMessage) GetFd() uint32 { @@ -2858,7 +3002,7 @@ type ResizeMessage struct { func (x *ResizeMessage) Reset() { *x = ResizeMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[45] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[47] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2870,7 +3014,7 @@ func (x *ResizeMessage) String() string { func (*ResizeMessage) ProtoMessage() {} func (x *ResizeMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[45] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[47] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2883,7 +3027,7 @@ func (x *ResizeMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use ResizeMessage.ProtoReflect.Descriptor instead. func (*ResizeMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{45} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{47} } func (x *ResizeMessage) GetRows() uint32 { @@ -2911,7 +3055,7 @@ type SignalMessage struct { func (x *SignalMessage) Reset() { *x = SignalMessage{} - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[46] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[48] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -2923,7 +3067,7 @@ func (x *SignalMessage) String() string { func (*SignalMessage) ProtoMessage() {} func (x *SignalMessage) ProtoReflect() protoreflect.Message { - mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[46] + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[48] if x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -2936,7 +3080,7 @@ func (x *SignalMessage) ProtoReflect() protoreflect.Message { // Deprecated: Use SignalMessage.ProtoReflect.Descriptor instead. func (*SignalMessage) Descriptor() ([]byte, []int) { - return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{46} + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{48} } func (x *SignalMessage) GetName() string { @@ -2946,6 +3090,126 @@ func (x *SignalMessage) GetName() string { return "" } +type Blob struct { + state protoimpl.MessageState `protogen:"open.v1"` + Descriptor_ *Descriptor `protobuf:"bytes,1,opt,name=descriptor,proto3" json:"descriptor,omitempty"` + Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *Blob) Reset() { + *x = Blob{} + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[49] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *Blob) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Blob) ProtoMessage() {} + +func (x *Blob) ProtoReflect() protoreflect.Message { + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[49] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Blob.ProtoReflect.Descriptor instead. +func (*Blob) Descriptor() ([]byte, []int) { + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{49} +} + +func (x *Blob) GetDescriptor_() *Descriptor { + if x != nil { + return x.Descriptor_ + } + return nil +} + +func (x *Blob) GetData() []byte { + if x != nil { + return x.Data + } + return nil +} + +type Descriptor struct { + state protoimpl.MessageState `protogen:"open.v1"` + MediaType string `protobuf:"bytes,1,opt,name=media_type,json=mediaType,proto3" json:"media_type,omitempty"` + Digest string `protobuf:"bytes,2,opt,name=digest,proto3" json:"digest,omitempty"` + Size int64 `protobuf:"varint,3,opt,name=size,proto3" json:"size,omitempty"` + Annotations map[string]string `protobuf:"bytes,5,rep,name=annotations,proto3" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` + unknownFields protoimpl.UnknownFields + sizeCache protoimpl.SizeCache +} + +func (x *Descriptor) Reset() { + *x = Descriptor{} + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[50] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) +} + +func (x *Descriptor) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Descriptor) ProtoMessage() {} + +func (x *Descriptor) ProtoReflect() protoreflect.Message { + mi := &file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[50] + if x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use Descriptor.ProtoReflect.Descriptor instead. +func (*Descriptor) Descriptor() ([]byte, []int) { + return file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP(), []int{50} +} + +func (x *Descriptor) GetMediaType() string { + if x != nil { + return x.MediaType + } + return "" +} + +func (x *Descriptor) GetDigest() string { + if x != nil { + return x.Digest + } + return "" +} + +func (x *Descriptor) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *Descriptor) GetAnnotations() map[string]string { + if x != nil { + return x.Annotations + } + return nil +} + var File_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto protoreflect.FileDescriptor const file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDesc = "" + @@ -3017,22 +3281,37 @@ const file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDesc = "\x1aResolveImageConfigResponse\x12\x16\n" + "\x06Digest\x18\x01 \x01(\tR\x06Digest\x12\x16\n" + "\x06Config\x18\x02 \x01(\fR\x06Config\x12\x10\n" + - "\x03Ref\x18\x03 \x01(\tR\x03Ref\"\xbb\x02\n" + + "\x03Ref\x18\x03 \x01(\tR\x03Ref\"\x87\x03\n" + "\x18ResolveSourceMetaRequest\x12$\n" + "\x06Source\x18\x01 \x01(\v2\f.pb.SourceOpR\x06Source\x12(\n" + "\bPlatform\x18\x02 \x01(\v2\f.pb.PlatformR\bPlatform\x12\x18\n" + "\aLogName\x18\x03 \x01(\tR\aLogName\x12 \n" + - "\vResolveMode\x18\x04 \x01(\tR\vResolveMode\x12M\n" + - "\x0eSourcePolicies\x18\b \x03(\v2%.moby.buildkit.v1.sourcepolicy.PolicyR\x0eSourcePolicies\x12D\n" + - "\x03Git\x18\x05 \x01(\v22.moby.buildkit.v1.frontend.ResolveSourceGitRequestR\x03Git\"\x9f\x02\n" + + "\vResolveMode\x18\x04 \x01(\tR\vResolveMode\x12D\n" + + "\x03Git\x18\x05 \x01(\v22.moby.buildkit.v1.frontend.ResolveSourceGitRequestR\x03Git\x12J\n" + + "\x05Image\x18\x06 \x01(\v24.moby.buildkit.v1.frontend.ResolveSourceImageRequestR\x05Image\x12M\n" + + "\x0eSourcePolicies\x18\b \x03(\v2%.moby.buildkit.v1.sourcepolicy.PolicyR\x0eSourcePolicies\"\x9f\x02\n" + "\x19ResolveSourceMetaResponse\x12$\n" + "\x06Source\x18\x01 \x01(\v2\f.pb.SourceOpR\x06Source\x12K\n" + "\x05Image\x18\x02 \x01(\v25.moby.buildkit.v1.frontend.ResolveSourceImageResponseR\x05Image\x12E\n" + "\x03Git\x18\x03 \x01(\v23.moby.buildkit.v1.frontend.ResolveSourceGitResponseR\x03Git\x12H\n" + - "\x04HTTP\x18\x04 \x01(\v24.moby.buildkit.v1.frontend.ResolveSourceHTTPResponseR\x04HTTP\"L\n" + + "\x04HTTP\x18\x04 \x01(\v24.moby.buildkit.v1.frontend.ResolveSourceHTTPResponseR\x04HTTP\"c\n" + + "\x19ResolveSourceImageRequest\x12\x1a\n" + + "\bNoConfig\x18\x01 \x01(\bR\bNoConfig\x12*\n" + + "\x10AttestationChain\x18\x02 \x01(\bR\x10AttestationChain\"\xd7\x02\n" + + "\x10AttestationChain\x12\x12\n" + + "\x04Root\x18\x01 \x01(\tR\x04Root\x12$\n" + + "\rImageManifest\x18\x02 \x01(\tR\rImageManifest\x120\n" + + "\x13AttestationManifest\x18\x03 \x01(\tR\x13AttestationManifest\x12.\n" + + "\x12SignatureManifests\x18\x04 \x03(\tR\x12SignatureManifests\x12L\n" + + "\x05Blobs\x18\x05 \x03(\v26.moby.buildkit.v1.frontend.AttestationChain.BlobsEntryR\x05Blobs\x1aY\n" + + "\n" + + "BlobsEntry\x12\x10\n" + + "\x03key\x18\x01 \x01(\tR\x03key\x125\n" + + "\x05value\x18\x02 \x01(\v2\x1f.moby.buildkit.v1.frontend.BlobR\x05value:\x028\x01\"\xa5\x01\n" + "\x1aResolveSourceImageResponse\x12\x16\n" + "\x06Digest\x18\x01 \x01(\tR\x06Digest\x12\x16\n" + - "\x06Config\x18\x02 \x01(\fR\x06Config\"=\n" + + "\x06Config\x18\x02 \x01(\fR\x06Config\x12W\n" + + "\x10AttestationChain\x18\x03 \x01(\v2+.moby.buildkit.v1.frontend.AttestationChainR\x10AttestationChain\"=\n" + "\x17ResolveSourceGitRequest\x12\"\n" + "\fReturnObject\x18\x01 \x01(\bR\fReturnObject\"\xb2\x01\n" + "\x18ResolveSourceGitResponse\x12\x1a\n" + @@ -3158,7 +3437,22 @@ const file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDesc = "\x04Rows\x18\x01 \x01(\rR\x04Rows\x12\x12\n" + "\x04Cols\x18\x02 \x01(\rR\x04Cols\"#\n" + "\rSignalMessage\x12\x12\n" + - "\x04Name\x18\x01 \x01(\tR\x04Name*)\n" + + "\x04Name\x18\x01 \x01(\tR\x04Name\"a\n" + + "\x04Blob\x12E\n" + + "\n" + + "descriptor\x18\x01 \x01(\v2%.moby.buildkit.v1.frontend.DescriptorR\n" + + "descriptor\x12\x12\n" + + "\x04data\x18\x02 \x01(\fR\x04data\"\xf1\x01\n" + + "\n" + + "Descriptor\x12\x1d\n" + + "\n" + + "media_type\x18\x01 \x01(\tR\tmediaType\x12\x16\n" + + "\x06digest\x18\x02 \x01(\tR\x06digest\x12\x12\n" + + "\x04size\x18\x03 \x01(\x03R\x04size\x12X\n" + + "\vannotations\x18\x05 \x03(\v26.moby.buildkit.v1.frontend.Descriptor.AnnotationsEntryR\vannotations\x1a>\n" + + "\x10AnnotationsEntry\x12\x10\n" + + "\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" + + "\x05value\x18\x02 \x01(\tR\x05value:\x028\x01*)\n" + "\x0fAttestationKind\x12\n" + "\n" + "\x06InToto\x10\x00\x12\n" + @@ -3196,7 +3490,7 @@ func file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDescGZIP } var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes = make([]protoimpl.MessageInfo, 56) +var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes = make([]protoimpl.MessageInfo, 62) var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_goTypes = []any{ (AttestationKind)(0), // 0: moby.buildkit.v1.frontend.AttestationKind (InTotoSubjectKind)(0), // 1: moby.buildkit.v1.frontend.InTotoSubjectKind @@ -3215,163 +3509,175 @@ var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_goTypes = [] (*ResolveImageConfigResponse)(nil), // 14: moby.buildkit.v1.frontend.ResolveImageConfigResponse (*ResolveSourceMetaRequest)(nil), // 15: moby.buildkit.v1.frontend.ResolveSourceMetaRequest (*ResolveSourceMetaResponse)(nil), // 16: moby.buildkit.v1.frontend.ResolveSourceMetaResponse - (*ResolveSourceImageResponse)(nil), // 17: moby.buildkit.v1.frontend.ResolveSourceImageResponse - (*ResolveSourceGitRequest)(nil), // 18: moby.buildkit.v1.frontend.ResolveSourceGitRequest - (*ResolveSourceGitResponse)(nil), // 19: moby.buildkit.v1.frontend.ResolveSourceGitResponse - (*ResolveSourceHTTPResponse)(nil), // 20: moby.buildkit.v1.frontend.ResolveSourceHTTPResponse - (*SolveRequest)(nil), // 21: moby.buildkit.v1.frontend.SolveRequest - (*CacheOptionsEntry)(nil), // 22: moby.buildkit.v1.frontend.CacheOptionsEntry - (*SolveResponse)(nil), // 23: moby.buildkit.v1.frontend.SolveResponse - (*ReadFileRequest)(nil), // 24: moby.buildkit.v1.frontend.ReadFileRequest - (*FileRange)(nil), // 25: moby.buildkit.v1.frontend.FileRange - (*ReadFileResponse)(nil), // 26: moby.buildkit.v1.frontend.ReadFileResponse - (*ReadDirRequest)(nil), // 27: moby.buildkit.v1.frontend.ReadDirRequest - (*ReadDirResponse)(nil), // 28: moby.buildkit.v1.frontend.ReadDirResponse - (*StatFileRequest)(nil), // 29: moby.buildkit.v1.frontend.StatFileRequest - (*StatFileResponse)(nil), // 30: moby.buildkit.v1.frontend.StatFileResponse - (*EvaluateRequest)(nil), // 31: moby.buildkit.v1.frontend.EvaluateRequest - (*EvaluateResponse)(nil), // 32: moby.buildkit.v1.frontend.EvaluateResponse - (*PingRequest)(nil), // 33: moby.buildkit.v1.frontend.PingRequest - (*PongResponse)(nil), // 34: moby.buildkit.v1.frontend.PongResponse - (*WarnRequest)(nil), // 35: moby.buildkit.v1.frontend.WarnRequest - (*WarnResponse)(nil), // 36: moby.buildkit.v1.frontend.WarnResponse - (*NewContainerRequest)(nil), // 37: moby.buildkit.v1.frontend.NewContainerRequest - (*NewContainerResponse)(nil), // 38: moby.buildkit.v1.frontend.NewContainerResponse - (*ReleaseContainerRequest)(nil), // 39: moby.buildkit.v1.frontend.ReleaseContainerRequest - (*ReleaseContainerResponse)(nil), // 40: moby.buildkit.v1.frontend.ReleaseContainerResponse - (*ExecMessage)(nil), // 41: moby.buildkit.v1.frontend.ExecMessage - (*InitMessage)(nil), // 42: moby.buildkit.v1.frontend.InitMessage - (*ExitMessage)(nil), // 43: moby.buildkit.v1.frontend.ExitMessage - (*StartedMessage)(nil), // 44: moby.buildkit.v1.frontend.StartedMessage - (*DoneMessage)(nil), // 45: moby.buildkit.v1.frontend.DoneMessage - (*FdMessage)(nil), // 46: moby.buildkit.v1.frontend.FdMessage - (*ResizeMessage)(nil), // 47: moby.buildkit.v1.frontend.ResizeMessage - (*SignalMessage)(nil), // 48: moby.buildkit.v1.frontend.SignalMessage - nil, // 49: moby.buildkit.v1.frontend.Result.MetadataEntry - nil, // 50: moby.buildkit.v1.frontend.Result.AttestationsEntry - nil, // 51: moby.buildkit.v1.frontend.RefMapDeprecated.RefsEntry - nil, // 52: moby.buildkit.v1.frontend.RefMap.RefsEntry - nil, // 53: moby.buildkit.v1.frontend.Attestation.MetadataEntry - nil, // 54: moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry - nil, // 55: moby.buildkit.v1.frontend.SolveRequest.FrontendOptEntry - nil, // 56: moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry - nil, // 57: moby.buildkit.v1.frontend.CacheOptionsEntry.AttrsEntry - (*pb.Definition)(nil), // 58: pb.Definition - (*status.Status)(nil), // 59: google.rpc.Status - (*pb.Platform)(nil), // 60: pb.Platform - (*pb1.Policy)(nil), // 61: moby.buildkit.v1.sourcepolicy.Policy - (*pb.SourceOp)(nil), // 62: pb.SourceOp - (*timestamp.Timestamp)(nil), // 63: google.protobuf.Timestamp - (*types.Stat)(nil), // 64: fsutil.types.Stat - (*pb2.APICap)(nil), // 65: moby.buildkit.v1.apicaps.APICap - (*types1.WorkerRecord)(nil), // 66: moby.buildkit.v1.types.WorkerRecord - (*pb.SourceInfo)(nil), // 67: pb.SourceInfo - (*pb.Range)(nil), // 68: pb.Range - (*pb.Mount)(nil), // 69: pb.Mount - (pb.NetMode)(0), // 70: pb.NetMode - (*pb.WorkerConstraints)(nil), // 71: pb.WorkerConstraints - (*pb.HostIP)(nil), // 72: pb.HostIP - (*pb.Meta)(nil), // 73: pb.Meta - (pb.SecurityMode)(0), // 74: pb.SecurityMode - (*pb.SecretEnv)(nil), // 75: pb.SecretEnv + (*ResolveSourceImageRequest)(nil), // 17: moby.buildkit.v1.frontend.ResolveSourceImageRequest + (*AttestationChain)(nil), // 18: moby.buildkit.v1.frontend.AttestationChain + (*ResolveSourceImageResponse)(nil), // 19: moby.buildkit.v1.frontend.ResolveSourceImageResponse + (*ResolveSourceGitRequest)(nil), // 20: moby.buildkit.v1.frontend.ResolveSourceGitRequest + (*ResolveSourceGitResponse)(nil), // 21: moby.buildkit.v1.frontend.ResolveSourceGitResponse + (*ResolveSourceHTTPResponse)(nil), // 22: moby.buildkit.v1.frontend.ResolveSourceHTTPResponse + (*SolveRequest)(nil), // 23: moby.buildkit.v1.frontend.SolveRequest + (*CacheOptionsEntry)(nil), // 24: moby.buildkit.v1.frontend.CacheOptionsEntry + (*SolveResponse)(nil), // 25: moby.buildkit.v1.frontend.SolveResponse + (*ReadFileRequest)(nil), // 26: moby.buildkit.v1.frontend.ReadFileRequest + (*FileRange)(nil), // 27: moby.buildkit.v1.frontend.FileRange + (*ReadFileResponse)(nil), // 28: moby.buildkit.v1.frontend.ReadFileResponse + (*ReadDirRequest)(nil), // 29: moby.buildkit.v1.frontend.ReadDirRequest + (*ReadDirResponse)(nil), // 30: moby.buildkit.v1.frontend.ReadDirResponse + (*StatFileRequest)(nil), // 31: moby.buildkit.v1.frontend.StatFileRequest + (*StatFileResponse)(nil), // 32: moby.buildkit.v1.frontend.StatFileResponse + (*EvaluateRequest)(nil), // 33: moby.buildkit.v1.frontend.EvaluateRequest + (*EvaluateResponse)(nil), // 34: moby.buildkit.v1.frontend.EvaluateResponse + (*PingRequest)(nil), // 35: moby.buildkit.v1.frontend.PingRequest + (*PongResponse)(nil), // 36: moby.buildkit.v1.frontend.PongResponse + (*WarnRequest)(nil), // 37: moby.buildkit.v1.frontend.WarnRequest + (*WarnResponse)(nil), // 38: moby.buildkit.v1.frontend.WarnResponse + (*NewContainerRequest)(nil), // 39: moby.buildkit.v1.frontend.NewContainerRequest + (*NewContainerResponse)(nil), // 40: moby.buildkit.v1.frontend.NewContainerResponse + (*ReleaseContainerRequest)(nil), // 41: moby.buildkit.v1.frontend.ReleaseContainerRequest + (*ReleaseContainerResponse)(nil), // 42: moby.buildkit.v1.frontend.ReleaseContainerResponse + (*ExecMessage)(nil), // 43: moby.buildkit.v1.frontend.ExecMessage + (*InitMessage)(nil), // 44: moby.buildkit.v1.frontend.InitMessage + (*ExitMessage)(nil), // 45: moby.buildkit.v1.frontend.ExitMessage + (*StartedMessage)(nil), // 46: moby.buildkit.v1.frontend.StartedMessage + (*DoneMessage)(nil), // 47: moby.buildkit.v1.frontend.DoneMessage + (*FdMessage)(nil), // 48: moby.buildkit.v1.frontend.FdMessage + (*ResizeMessage)(nil), // 49: moby.buildkit.v1.frontend.ResizeMessage + (*SignalMessage)(nil), // 50: moby.buildkit.v1.frontend.SignalMessage + (*Blob)(nil), // 51: moby.buildkit.v1.frontend.Blob + (*Descriptor)(nil), // 52: moby.buildkit.v1.frontend.Descriptor + nil, // 53: moby.buildkit.v1.frontend.Result.MetadataEntry + nil, // 54: moby.buildkit.v1.frontend.Result.AttestationsEntry + nil, // 55: moby.buildkit.v1.frontend.RefMapDeprecated.RefsEntry + nil, // 56: moby.buildkit.v1.frontend.RefMap.RefsEntry + nil, // 57: moby.buildkit.v1.frontend.Attestation.MetadataEntry + nil, // 58: moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry + nil, // 59: moby.buildkit.v1.frontend.AttestationChain.BlobsEntry + nil, // 60: moby.buildkit.v1.frontend.SolveRequest.FrontendOptEntry + nil, // 61: moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry + nil, // 62: moby.buildkit.v1.frontend.CacheOptionsEntry.AttrsEntry + nil, // 63: moby.buildkit.v1.frontend.Descriptor.AnnotationsEntry + (*pb.Definition)(nil), // 64: pb.Definition + (*status.Status)(nil), // 65: google.rpc.Status + (*pb.Platform)(nil), // 66: pb.Platform + (*pb1.Policy)(nil), // 67: moby.buildkit.v1.sourcepolicy.Policy + (*pb.SourceOp)(nil), // 68: pb.SourceOp + (*timestamp.Timestamp)(nil), // 69: google.protobuf.Timestamp + (*types.Stat)(nil), // 70: fsutil.types.Stat + (*pb2.APICap)(nil), // 71: moby.buildkit.v1.apicaps.APICap + (*types1.WorkerRecord)(nil), // 72: moby.buildkit.v1.types.WorkerRecord + (*pb.SourceInfo)(nil), // 73: pb.SourceInfo + (*pb.Range)(nil), // 74: pb.Range + (*pb.Mount)(nil), // 75: pb.Mount + (pb.NetMode)(0), // 76: pb.NetMode + (*pb.WorkerConstraints)(nil), // 77: pb.WorkerConstraints + (*pb.HostIP)(nil), // 78: pb.HostIP + (*pb.Meta)(nil), // 79: pb.Meta + (pb.SecurityMode)(0), // 80: pb.SecurityMode + (*pb.SecretEnv)(nil), // 81: pb.SecretEnv } var file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_depIdxs = []int32{ 3, // 0: moby.buildkit.v1.frontend.Result.refsDeprecated:type_name -> moby.buildkit.v1.frontend.RefMapDeprecated 4, // 1: moby.buildkit.v1.frontend.Result.ref:type_name -> moby.buildkit.v1.frontend.Ref 5, // 2: moby.buildkit.v1.frontend.Result.refs:type_name -> moby.buildkit.v1.frontend.RefMap - 49, // 3: moby.buildkit.v1.frontend.Result.metadata:type_name -> moby.buildkit.v1.frontend.Result.MetadataEntry - 50, // 4: moby.buildkit.v1.frontend.Result.attestations:type_name -> moby.buildkit.v1.frontend.Result.AttestationsEntry - 51, // 5: moby.buildkit.v1.frontend.RefMapDeprecated.refs:type_name -> moby.buildkit.v1.frontend.RefMapDeprecated.RefsEntry - 58, // 6: moby.buildkit.v1.frontend.Ref.def:type_name -> pb.Definition - 52, // 7: moby.buildkit.v1.frontend.RefMap.refs:type_name -> moby.buildkit.v1.frontend.RefMap.RefsEntry + 53, // 3: moby.buildkit.v1.frontend.Result.metadata:type_name -> moby.buildkit.v1.frontend.Result.MetadataEntry + 54, // 4: moby.buildkit.v1.frontend.Result.attestations:type_name -> moby.buildkit.v1.frontend.Result.AttestationsEntry + 55, // 5: moby.buildkit.v1.frontend.RefMapDeprecated.refs:type_name -> moby.buildkit.v1.frontend.RefMapDeprecated.RefsEntry + 64, // 6: moby.buildkit.v1.frontend.Ref.def:type_name -> pb.Definition + 56, // 7: moby.buildkit.v1.frontend.RefMap.refs:type_name -> moby.buildkit.v1.frontend.RefMap.RefsEntry 7, // 8: moby.buildkit.v1.frontend.Attestations.attestation:type_name -> moby.buildkit.v1.frontend.Attestation 0, // 9: moby.buildkit.v1.frontend.Attestation.kind:type_name -> moby.buildkit.v1.frontend.AttestationKind - 53, // 10: moby.buildkit.v1.frontend.Attestation.metadata:type_name -> moby.buildkit.v1.frontend.Attestation.MetadataEntry + 57, // 10: moby.buildkit.v1.frontend.Attestation.metadata:type_name -> moby.buildkit.v1.frontend.Attestation.MetadataEntry 4, // 11: moby.buildkit.v1.frontend.Attestation.ref:type_name -> moby.buildkit.v1.frontend.Ref 8, // 12: moby.buildkit.v1.frontend.Attestation.inTotoSubjects:type_name -> moby.buildkit.v1.frontend.InTotoSubject 1, // 13: moby.buildkit.v1.frontend.InTotoSubject.kind:type_name -> moby.buildkit.v1.frontend.InTotoSubjectKind 2, // 14: moby.buildkit.v1.frontend.ReturnRequest.result:type_name -> moby.buildkit.v1.frontend.Result - 59, // 15: moby.buildkit.v1.frontend.ReturnRequest.error:type_name -> google.rpc.Status - 54, // 16: moby.buildkit.v1.frontend.InputsResponse.Definitions:type_name -> moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry - 60, // 17: moby.buildkit.v1.frontend.ResolveImageConfigRequest.Platform:type_name -> pb.Platform - 61, // 18: moby.buildkit.v1.frontend.ResolveImageConfigRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy - 62, // 19: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Source:type_name -> pb.SourceOp - 60, // 20: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Platform:type_name -> pb.Platform - 61, // 21: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy - 18, // 22: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Git:type_name -> moby.buildkit.v1.frontend.ResolveSourceGitRequest - 62, // 23: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Source:type_name -> pb.SourceOp - 17, // 24: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Image:type_name -> moby.buildkit.v1.frontend.ResolveSourceImageResponse - 19, // 25: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Git:type_name -> moby.buildkit.v1.frontend.ResolveSourceGitResponse - 20, // 26: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.HTTP:type_name -> moby.buildkit.v1.frontend.ResolveSourceHTTPResponse - 63, // 27: moby.buildkit.v1.frontend.ResolveSourceHTTPResponse.LastModified:type_name -> google.protobuf.Timestamp - 58, // 28: moby.buildkit.v1.frontend.SolveRequest.Definition:type_name -> pb.Definition - 55, // 29: moby.buildkit.v1.frontend.SolveRequest.FrontendOpt:type_name -> moby.buildkit.v1.frontend.SolveRequest.FrontendOptEntry - 22, // 30: moby.buildkit.v1.frontend.SolveRequest.CacheImports:type_name -> moby.buildkit.v1.frontend.CacheOptionsEntry - 56, // 31: moby.buildkit.v1.frontend.SolveRequest.FrontendInputs:type_name -> moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry - 61, // 32: moby.buildkit.v1.frontend.SolveRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy - 57, // 33: moby.buildkit.v1.frontend.CacheOptionsEntry.Attrs:type_name -> moby.buildkit.v1.frontend.CacheOptionsEntry.AttrsEntry - 2, // 34: moby.buildkit.v1.frontend.SolveResponse.result:type_name -> moby.buildkit.v1.frontend.Result - 25, // 35: moby.buildkit.v1.frontend.ReadFileRequest.Range:type_name -> moby.buildkit.v1.frontend.FileRange - 64, // 36: moby.buildkit.v1.frontend.ReadDirResponse.entries:type_name -> fsutil.types.Stat - 64, // 37: moby.buildkit.v1.frontend.StatFileResponse.stat:type_name -> fsutil.types.Stat - 65, // 38: moby.buildkit.v1.frontend.PongResponse.FrontendAPICaps:type_name -> moby.buildkit.v1.apicaps.APICap - 65, // 39: moby.buildkit.v1.frontend.PongResponse.LLBCaps:type_name -> moby.buildkit.v1.apicaps.APICap - 66, // 40: moby.buildkit.v1.frontend.PongResponse.Workers:type_name -> moby.buildkit.v1.types.WorkerRecord - 67, // 41: moby.buildkit.v1.frontend.WarnRequest.info:type_name -> pb.SourceInfo - 68, // 42: moby.buildkit.v1.frontend.WarnRequest.ranges:type_name -> pb.Range - 69, // 43: moby.buildkit.v1.frontend.NewContainerRequest.Mounts:type_name -> pb.Mount - 70, // 44: moby.buildkit.v1.frontend.NewContainerRequest.Network:type_name -> pb.NetMode - 60, // 45: moby.buildkit.v1.frontend.NewContainerRequest.platform:type_name -> pb.Platform - 71, // 46: moby.buildkit.v1.frontend.NewContainerRequest.constraints:type_name -> pb.WorkerConstraints - 72, // 47: moby.buildkit.v1.frontend.NewContainerRequest.extraHosts:type_name -> pb.HostIP - 42, // 48: moby.buildkit.v1.frontend.ExecMessage.Init:type_name -> moby.buildkit.v1.frontend.InitMessage - 46, // 49: moby.buildkit.v1.frontend.ExecMessage.File:type_name -> moby.buildkit.v1.frontend.FdMessage - 47, // 50: moby.buildkit.v1.frontend.ExecMessage.Resize:type_name -> moby.buildkit.v1.frontend.ResizeMessage - 44, // 51: moby.buildkit.v1.frontend.ExecMessage.Started:type_name -> moby.buildkit.v1.frontend.StartedMessage - 43, // 52: moby.buildkit.v1.frontend.ExecMessage.Exit:type_name -> moby.buildkit.v1.frontend.ExitMessage - 45, // 53: moby.buildkit.v1.frontend.ExecMessage.Done:type_name -> moby.buildkit.v1.frontend.DoneMessage - 48, // 54: moby.buildkit.v1.frontend.ExecMessage.Signal:type_name -> moby.buildkit.v1.frontend.SignalMessage - 73, // 55: moby.buildkit.v1.frontend.InitMessage.Meta:type_name -> pb.Meta - 74, // 56: moby.buildkit.v1.frontend.InitMessage.Security:type_name -> pb.SecurityMode - 75, // 57: moby.buildkit.v1.frontend.InitMessage.secretenv:type_name -> pb.SecretEnv - 59, // 58: moby.buildkit.v1.frontend.ExitMessage.Error:type_name -> google.rpc.Status - 6, // 59: moby.buildkit.v1.frontend.Result.AttestationsEntry.value:type_name -> moby.buildkit.v1.frontend.Attestations - 4, // 60: moby.buildkit.v1.frontend.RefMap.RefsEntry.value:type_name -> moby.buildkit.v1.frontend.Ref - 58, // 61: moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry.value:type_name -> pb.Definition - 58, // 62: moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry.value:type_name -> pb.Definition - 13, // 63: moby.buildkit.v1.frontend.LLBBridge.ResolveImageConfig:input_type -> moby.buildkit.v1.frontend.ResolveImageConfigRequest - 15, // 64: moby.buildkit.v1.frontend.LLBBridge.ResolveSourceMeta:input_type -> moby.buildkit.v1.frontend.ResolveSourceMetaRequest - 21, // 65: moby.buildkit.v1.frontend.LLBBridge.Solve:input_type -> moby.buildkit.v1.frontend.SolveRequest - 24, // 66: moby.buildkit.v1.frontend.LLBBridge.ReadFile:input_type -> moby.buildkit.v1.frontend.ReadFileRequest - 27, // 67: moby.buildkit.v1.frontend.LLBBridge.ReadDir:input_type -> moby.buildkit.v1.frontend.ReadDirRequest - 29, // 68: moby.buildkit.v1.frontend.LLBBridge.StatFile:input_type -> moby.buildkit.v1.frontend.StatFileRequest - 31, // 69: moby.buildkit.v1.frontend.LLBBridge.Evaluate:input_type -> moby.buildkit.v1.frontend.EvaluateRequest - 33, // 70: moby.buildkit.v1.frontend.LLBBridge.Ping:input_type -> moby.buildkit.v1.frontend.PingRequest - 9, // 71: moby.buildkit.v1.frontend.LLBBridge.Return:input_type -> moby.buildkit.v1.frontend.ReturnRequest - 11, // 72: moby.buildkit.v1.frontend.LLBBridge.Inputs:input_type -> moby.buildkit.v1.frontend.InputsRequest - 37, // 73: moby.buildkit.v1.frontend.LLBBridge.NewContainer:input_type -> moby.buildkit.v1.frontend.NewContainerRequest - 39, // 74: moby.buildkit.v1.frontend.LLBBridge.ReleaseContainer:input_type -> moby.buildkit.v1.frontend.ReleaseContainerRequest - 41, // 75: moby.buildkit.v1.frontend.LLBBridge.ExecProcess:input_type -> moby.buildkit.v1.frontend.ExecMessage - 35, // 76: moby.buildkit.v1.frontend.LLBBridge.Warn:input_type -> moby.buildkit.v1.frontend.WarnRequest - 14, // 77: moby.buildkit.v1.frontend.LLBBridge.ResolveImageConfig:output_type -> moby.buildkit.v1.frontend.ResolveImageConfigResponse - 16, // 78: moby.buildkit.v1.frontend.LLBBridge.ResolveSourceMeta:output_type -> moby.buildkit.v1.frontend.ResolveSourceMetaResponse - 23, // 79: moby.buildkit.v1.frontend.LLBBridge.Solve:output_type -> moby.buildkit.v1.frontend.SolveResponse - 26, // 80: moby.buildkit.v1.frontend.LLBBridge.ReadFile:output_type -> moby.buildkit.v1.frontend.ReadFileResponse - 28, // 81: moby.buildkit.v1.frontend.LLBBridge.ReadDir:output_type -> moby.buildkit.v1.frontend.ReadDirResponse - 30, // 82: moby.buildkit.v1.frontend.LLBBridge.StatFile:output_type -> moby.buildkit.v1.frontend.StatFileResponse - 32, // 83: moby.buildkit.v1.frontend.LLBBridge.Evaluate:output_type -> moby.buildkit.v1.frontend.EvaluateResponse - 34, // 84: moby.buildkit.v1.frontend.LLBBridge.Ping:output_type -> moby.buildkit.v1.frontend.PongResponse - 10, // 85: moby.buildkit.v1.frontend.LLBBridge.Return:output_type -> moby.buildkit.v1.frontend.ReturnResponse - 12, // 86: moby.buildkit.v1.frontend.LLBBridge.Inputs:output_type -> moby.buildkit.v1.frontend.InputsResponse - 38, // 87: moby.buildkit.v1.frontend.LLBBridge.NewContainer:output_type -> moby.buildkit.v1.frontend.NewContainerResponse - 40, // 88: moby.buildkit.v1.frontend.LLBBridge.ReleaseContainer:output_type -> moby.buildkit.v1.frontend.ReleaseContainerResponse - 41, // 89: moby.buildkit.v1.frontend.LLBBridge.ExecProcess:output_type -> moby.buildkit.v1.frontend.ExecMessage - 36, // 90: moby.buildkit.v1.frontend.LLBBridge.Warn:output_type -> moby.buildkit.v1.frontend.WarnResponse - 77, // [77:91] is the sub-list for method output_type - 63, // [63:77] is the sub-list for method input_type - 63, // [63:63] is the sub-list for extension type_name - 63, // [63:63] is the sub-list for extension extendee - 0, // [0:63] is the sub-list for field type_name + 65, // 15: moby.buildkit.v1.frontend.ReturnRequest.error:type_name -> google.rpc.Status + 58, // 16: moby.buildkit.v1.frontend.InputsResponse.Definitions:type_name -> moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry + 66, // 17: moby.buildkit.v1.frontend.ResolveImageConfigRequest.Platform:type_name -> pb.Platform + 67, // 18: moby.buildkit.v1.frontend.ResolveImageConfigRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy + 68, // 19: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Source:type_name -> pb.SourceOp + 66, // 20: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Platform:type_name -> pb.Platform + 20, // 21: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Git:type_name -> moby.buildkit.v1.frontend.ResolveSourceGitRequest + 17, // 22: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.Image:type_name -> moby.buildkit.v1.frontend.ResolveSourceImageRequest + 67, // 23: moby.buildkit.v1.frontend.ResolveSourceMetaRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy + 68, // 24: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Source:type_name -> pb.SourceOp + 19, // 25: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Image:type_name -> moby.buildkit.v1.frontend.ResolveSourceImageResponse + 21, // 26: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.Git:type_name -> moby.buildkit.v1.frontend.ResolveSourceGitResponse + 22, // 27: moby.buildkit.v1.frontend.ResolveSourceMetaResponse.HTTP:type_name -> moby.buildkit.v1.frontend.ResolveSourceHTTPResponse + 59, // 28: moby.buildkit.v1.frontend.AttestationChain.Blobs:type_name -> moby.buildkit.v1.frontend.AttestationChain.BlobsEntry + 18, // 29: moby.buildkit.v1.frontend.ResolveSourceImageResponse.AttestationChain:type_name -> moby.buildkit.v1.frontend.AttestationChain + 69, // 30: moby.buildkit.v1.frontend.ResolveSourceHTTPResponse.LastModified:type_name -> google.protobuf.Timestamp + 64, // 31: moby.buildkit.v1.frontend.SolveRequest.Definition:type_name -> pb.Definition + 60, // 32: moby.buildkit.v1.frontend.SolveRequest.FrontendOpt:type_name -> moby.buildkit.v1.frontend.SolveRequest.FrontendOptEntry + 24, // 33: moby.buildkit.v1.frontend.SolveRequest.CacheImports:type_name -> moby.buildkit.v1.frontend.CacheOptionsEntry + 61, // 34: moby.buildkit.v1.frontend.SolveRequest.FrontendInputs:type_name -> moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry + 67, // 35: moby.buildkit.v1.frontend.SolveRequest.SourcePolicies:type_name -> moby.buildkit.v1.sourcepolicy.Policy + 62, // 36: moby.buildkit.v1.frontend.CacheOptionsEntry.Attrs:type_name -> moby.buildkit.v1.frontend.CacheOptionsEntry.AttrsEntry + 2, // 37: moby.buildkit.v1.frontend.SolveResponse.result:type_name -> moby.buildkit.v1.frontend.Result + 27, // 38: moby.buildkit.v1.frontend.ReadFileRequest.Range:type_name -> moby.buildkit.v1.frontend.FileRange + 70, // 39: moby.buildkit.v1.frontend.ReadDirResponse.entries:type_name -> fsutil.types.Stat + 70, // 40: moby.buildkit.v1.frontend.StatFileResponse.stat:type_name -> fsutil.types.Stat + 71, // 41: moby.buildkit.v1.frontend.PongResponse.FrontendAPICaps:type_name -> moby.buildkit.v1.apicaps.APICap + 71, // 42: moby.buildkit.v1.frontend.PongResponse.LLBCaps:type_name -> moby.buildkit.v1.apicaps.APICap + 72, // 43: moby.buildkit.v1.frontend.PongResponse.Workers:type_name -> moby.buildkit.v1.types.WorkerRecord + 73, // 44: moby.buildkit.v1.frontend.WarnRequest.info:type_name -> pb.SourceInfo + 74, // 45: moby.buildkit.v1.frontend.WarnRequest.ranges:type_name -> pb.Range + 75, // 46: moby.buildkit.v1.frontend.NewContainerRequest.Mounts:type_name -> pb.Mount + 76, // 47: moby.buildkit.v1.frontend.NewContainerRequest.Network:type_name -> pb.NetMode + 66, // 48: moby.buildkit.v1.frontend.NewContainerRequest.platform:type_name -> pb.Platform + 77, // 49: moby.buildkit.v1.frontend.NewContainerRequest.constraints:type_name -> pb.WorkerConstraints + 78, // 50: moby.buildkit.v1.frontend.NewContainerRequest.extraHosts:type_name -> pb.HostIP + 44, // 51: moby.buildkit.v1.frontend.ExecMessage.Init:type_name -> moby.buildkit.v1.frontend.InitMessage + 48, // 52: moby.buildkit.v1.frontend.ExecMessage.File:type_name -> moby.buildkit.v1.frontend.FdMessage + 49, // 53: moby.buildkit.v1.frontend.ExecMessage.Resize:type_name -> moby.buildkit.v1.frontend.ResizeMessage + 46, // 54: moby.buildkit.v1.frontend.ExecMessage.Started:type_name -> moby.buildkit.v1.frontend.StartedMessage + 45, // 55: moby.buildkit.v1.frontend.ExecMessage.Exit:type_name -> moby.buildkit.v1.frontend.ExitMessage + 47, // 56: moby.buildkit.v1.frontend.ExecMessage.Done:type_name -> moby.buildkit.v1.frontend.DoneMessage + 50, // 57: moby.buildkit.v1.frontend.ExecMessage.Signal:type_name -> moby.buildkit.v1.frontend.SignalMessage + 79, // 58: moby.buildkit.v1.frontend.InitMessage.Meta:type_name -> pb.Meta + 80, // 59: moby.buildkit.v1.frontend.InitMessage.Security:type_name -> pb.SecurityMode + 81, // 60: moby.buildkit.v1.frontend.InitMessage.secretenv:type_name -> pb.SecretEnv + 65, // 61: moby.buildkit.v1.frontend.ExitMessage.Error:type_name -> google.rpc.Status + 52, // 62: moby.buildkit.v1.frontend.Blob.descriptor:type_name -> moby.buildkit.v1.frontend.Descriptor + 63, // 63: moby.buildkit.v1.frontend.Descriptor.annotations:type_name -> moby.buildkit.v1.frontend.Descriptor.AnnotationsEntry + 6, // 64: moby.buildkit.v1.frontend.Result.AttestationsEntry.value:type_name -> moby.buildkit.v1.frontend.Attestations + 4, // 65: moby.buildkit.v1.frontend.RefMap.RefsEntry.value:type_name -> moby.buildkit.v1.frontend.Ref + 64, // 66: moby.buildkit.v1.frontend.InputsResponse.DefinitionsEntry.value:type_name -> pb.Definition + 51, // 67: moby.buildkit.v1.frontend.AttestationChain.BlobsEntry.value:type_name -> moby.buildkit.v1.frontend.Blob + 64, // 68: moby.buildkit.v1.frontend.SolveRequest.FrontendInputsEntry.value:type_name -> pb.Definition + 13, // 69: moby.buildkit.v1.frontend.LLBBridge.ResolveImageConfig:input_type -> moby.buildkit.v1.frontend.ResolveImageConfigRequest + 15, // 70: moby.buildkit.v1.frontend.LLBBridge.ResolveSourceMeta:input_type -> moby.buildkit.v1.frontend.ResolveSourceMetaRequest + 23, // 71: moby.buildkit.v1.frontend.LLBBridge.Solve:input_type -> moby.buildkit.v1.frontend.SolveRequest + 26, // 72: moby.buildkit.v1.frontend.LLBBridge.ReadFile:input_type -> moby.buildkit.v1.frontend.ReadFileRequest + 29, // 73: moby.buildkit.v1.frontend.LLBBridge.ReadDir:input_type -> moby.buildkit.v1.frontend.ReadDirRequest + 31, // 74: moby.buildkit.v1.frontend.LLBBridge.StatFile:input_type -> moby.buildkit.v1.frontend.StatFileRequest + 33, // 75: moby.buildkit.v1.frontend.LLBBridge.Evaluate:input_type -> moby.buildkit.v1.frontend.EvaluateRequest + 35, // 76: moby.buildkit.v1.frontend.LLBBridge.Ping:input_type -> moby.buildkit.v1.frontend.PingRequest + 9, // 77: moby.buildkit.v1.frontend.LLBBridge.Return:input_type -> moby.buildkit.v1.frontend.ReturnRequest + 11, // 78: moby.buildkit.v1.frontend.LLBBridge.Inputs:input_type -> moby.buildkit.v1.frontend.InputsRequest + 39, // 79: moby.buildkit.v1.frontend.LLBBridge.NewContainer:input_type -> moby.buildkit.v1.frontend.NewContainerRequest + 41, // 80: moby.buildkit.v1.frontend.LLBBridge.ReleaseContainer:input_type -> moby.buildkit.v1.frontend.ReleaseContainerRequest + 43, // 81: moby.buildkit.v1.frontend.LLBBridge.ExecProcess:input_type -> moby.buildkit.v1.frontend.ExecMessage + 37, // 82: moby.buildkit.v1.frontend.LLBBridge.Warn:input_type -> moby.buildkit.v1.frontend.WarnRequest + 14, // 83: moby.buildkit.v1.frontend.LLBBridge.ResolveImageConfig:output_type -> moby.buildkit.v1.frontend.ResolveImageConfigResponse + 16, // 84: moby.buildkit.v1.frontend.LLBBridge.ResolveSourceMeta:output_type -> moby.buildkit.v1.frontend.ResolveSourceMetaResponse + 25, // 85: moby.buildkit.v1.frontend.LLBBridge.Solve:output_type -> moby.buildkit.v1.frontend.SolveResponse + 28, // 86: moby.buildkit.v1.frontend.LLBBridge.ReadFile:output_type -> moby.buildkit.v1.frontend.ReadFileResponse + 30, // 87: moby.buildkit.v1.frontend.LLBBridge.ReadDir:output_type -> moby.buildkit.v1.frontend.ReadDirResponse + 32, // 88: moby.buildkit.v1.frontend.LLBBridge.StatFile:output_type -> moby.buildkit.v1.frontend.StatFileResponse + 34, // 89: moby.buildkit.v1.frontend.LLBBridge.Evaluate:output_type -> moby.buildkit.v1.frontend.EvaluateResponse + 36, // 90: moby.buildkit.v1.frontend.LLBBridge.Ping:output_type -> moby.buildkit.v1.frontend.PongResponse + 10, // 91: moby.buildkit.v1.frontend.LLBBridge.Return:output_type -> moby.buildkit.v1.frontend.ReturnResponse + 12, // 92: moby.buildkit.v1.frontend.LLBBridge.Inputs:output_type -> moby.buildkit.v1.frontend.InputsResponse + 40, // 93: moby.buildkit.v1.frontend.LLBBridge.NewContainer:output_type -> moby.buildkit.v1.frontend.NewContainerResponse + 42, // 94: moby.buildkit.v1.frontend.LLBBridge.ReleaseContainer:output_type -> moby.buildkit.v1.frontend.ReleaseContainerResponse + 43, // 95: moby.buildkit.v1.frontend.LLBBridge.ExecProcess:output_type -> moby.buildkit.v1.frontend.ExecMessage + 38, // 96: moby.buildkit.v1.frontend.LLBBridge.Warn:output_type -> moby.buildkit.v1.frontend.WarnResponse + 83, // [83:97] is the sub-list for method output_type + 69, // [69:83] is the sub-list for method input_type + 69, // [69:69] is the sub-list for extension type_name + 69, // [69:69] is the sub-list for extension extendee + 0, // [0:69] is the sub-list for field type_name } func init() { file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_init() } @@ -3385,7 +3691,7 @@ func file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_init() { (*Result_Ref)(nil), (*Result_Refs)(nil), } - file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[39].OneofWrappers = []any{ + file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_msgTypes[41].OneofWrappers = []any{ (*ExecMessage_Init)(nil), (*ExecMessage_File)(nil), (*ExecMessage_Resize)(nil), @@ -3400,7 +3706,7 @@ func file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: unsafe.Slice(unsafe.StringData(file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDesc), len(file_github_com_moby_buildkit_frontend_gateway_pb_gateway_proto_rawDesc)), NumEnums: 2, - NumMessages: 56, + NumMessages: 62, NumExtensions: 0, NumServices: 1, }, diff --git a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.proto b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.proto index f9744f2b7..3add95c65 100644 --- a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.proto +++ b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway.proto @@ -135,8 +135,9 @@ message ResolveSourceMetaRequest { pb.Platform Platform = 2; string LogName = 3; string ResolveMode = 4; - repeated moby.buildkit.v1.sourcepolicy.Policy SourcePolicies = 8; ResolveSourceGitRequest Git = 5; + ResolveSourceImageRequest Image = 6; + repeated moby.buildkit.v1.sourcepolicy.Policy SourcePolicies = 8; } message ResolveSourceMetaResponse { @@ -146,9 +147,23 @@ message ResolveSourceMetaResponse { ResolveSourceHTTPResponse HTTP = 4; } +message ResolveSourceImageRequest { + bool NoConfig = 1; + bool AttestationChain = 2; +} + +message AttestationChain { + string Root = 1; + string ImageManifest = 2; + string AttestationManifest = 3; + repeated string SignatureManifests = 4; + map Blobs = 5; +} + message ResolveSourceImageResponse { string Digest = 1; bytes Config = 2; + AttestationChain AttestationChain = 3; } message ResolveSourceGitRequest { @@ -348,3 +363,15 @@ message SignalMessage { // are platform dependent. string Name = 1; } + +message Blob { + Descriptor descriptor = 1; + bytes data = 2; +} + +message Descriptor { + string media_type = 1; + string digest = 2; + int64 size = 3; + map annotations = 5; +} \ No newline at end of file diff --git a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway_vtproto.pb.go b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway_vtproto.pb.go index f8430fa51..585416809 100644 --- a/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway_vtproto.pb.go +++ b/vendor/github.com/moby/buildkit/frontend/gateway/pb/gateway_vtproto.pb.go @@ -386,6 +386,7 @@ func (m *ResolveSourceMetaRequest) CloneVT() *ResolveSourceMetaRequest { r.LogName = m.LogName r.ResolveMode = m.ResolveMode r.Git = m.Git.CloneVT() + r.Image = m.Image.CloneVT() if rhs := m.SourcePolicies; rhs != nil { tmpContainer := make([]*pb1.Policy, len(rhs)) for k, v := range rhs { @@ -424,12 +425,62 @@ func (m *ResolveSourceMetaResponse) CloneMessageVT() proto.Message { return m.CloneVT() } +func (m *ResolveSourceImageRequest) CloneVT() *ResolveSourceImageRequest { + if m == nil { + return (*ResolveSourceImageRequest)(nil) + } + r := new(ResolveSourceImageRequest) + r.NoConfig = m.NoConfig + r.AttestationChain = m.AttestationChain + if len(m.unknownFields) > 0 { + r.unknownFields = make([]byte, len(m.unknownFields)) + copy(r.unknownFields, m.unknownFields) + } + return r +} + +func (m *ResolveSourceImageRequest) CloneMessageVT() proto.Message { + return m.CloneVT() +} + +func (m *AttestationChain) CloneVT() *AttestationChain { + if m == nil { + return (*AttestationChain)(nil) + } + r := new(AttestationChain) + r.Root = m.Root + r.ImageManifest = m.ImageManifest + r.AttestationManifest = m.AttestationManifest + if rhs := m.SignatureManifests; rhs != nil { + tmpContainer := make([]string, len(rhs)) + copy(tmpContainer, rhs) + r.SignatureManifests = tmpContainer + } + if rhs := m.Blobs; rhs != nil { + tmpContainer := make(map[string]*Blob, len(rhs)) + for k, v := range rhs { + tmpContainer[k] = v.CloneVT() + } + r.Blobs = tmpContainer + } + if len(m.unknownFields) > 0 { + r.unknownFields = make([]byte, len(m.unknownFields)) + copy(r.unknownFields, m.unknownFields) + } + return r +} + +func (m *AttestationChain) CloneMessageVT() proto.Message { + return m.CloneVT() +} + func (m *ResolveSourceImageResponse) CloneVT() *ResolveSourceImageResponse { if m == nil { return (*ResolveSourceImageResponse)(nil) } r := new(ResolveSourceImageResponse) r.Digest = m.Digest + r.AttestationChain = m.AttestationChain.CloneVT() if rhs := m.Config; rhs != nil { tmpBytes := make([]byte, len(rhs)) copy(tmpBytes, rhs) @@ -1209,6 +1260,54 @@ func (m *SignalMessage) CloneMessageVT() proto.Message { return m.CloneVT() } +func (m *Blob) CloneVT() *Blob { + if m == nil { + return (*Blob)(nil) + } + r := new(Blob) + r.Descriptor_ = m.Descriptor_.CloneVT() + if rhs := m.Data; rhs != nil { + tmpBytes := make([]byte, len(rhs)) + copy(tmpBytes, rhs) + r.Data = tmpBytes + } + if len(m.unknownFields) > 0 { + r.unknownFields = make([]byte, len(m.unknownFields)) + copy(r.unknownFields, m.unknownFields) + } + return r +} + +func (m *Blob) CloneMessageVT() proto.Message { + return m.CloneVT() +} + +func (m *Descriptor) CloneVT() *Descriptor { + if m == nil { + return (*Descriptor)(nil) + } + r := new(Descriptor) + r.MediaType = m.MediaType + r.Digest = m.Digest + r.Size = m.Size + if rhs := m.Annotations; rhs != nil { + tmpContainer := make(map[string]string, len(rhs)) + for k, v := range rhs { + tmpContainer[k] = v + } + r.Annotations = tmpContainer + } + if len(m.unknownFields) > 0 { + r.unknownFields = make([]byte, len(m.unknownFields)) + copy(r.unknownFields, m.unknownFields) + } + return r +} + +func (m *Descriptor) CloneMessageVT() proto.Message { + return m.CloneVT() +} + func (this *Result) EqualVT(that *Result) bool { if this == that { return true @@ -1760,6 +1859,9 @@ func (this *ResolveSourceMetaRequest) EqualVT(that *ResolveSourceMetaRequest) bo if !this.Git.EqualVT(that.Git) { return false } + if !this.Image.EqualVT(that.Image) { + return false + } if len(this.SourcePolicies) != len(that.SourcePolicies) { return false } @@ -1815,6 +1917,82 @@ func (this *ResolveSourceMetaResponse) EqualMessageVT(thatMsg proto.Message) boo } return this.EqualVT(that) } +func (this *ResolveSourceImageRequest) EqualVT(that *ResolveSourceImageRequest) bool { + if this == that { + return true + } else if this == nil || that == nil { + return false + } + if this.NoConfig != that.NoConfig { + return false + } + if this.AttestationChain != that.AttestationChain { + return false + } + return string(this.unknownFields) == string(that.unknownFields) +} + +func (this *ResolveSourceImageRequest) EqualMessageVT(thatMsg proto.Message) bool { + that, ok := thatMsg.(*ResolveSourceImageRequest) + if !ok { + return false + } + return this.EqualVT(that) +} +func (this *AttestationChain) EqualVT(that *AttestationChain) bool { + if this == that { + return true + } else if this == nil || that == nil { + return false + } + if this.Root != that.Root { + return false + } + if this.ImageManifest != that.ImageManifest { + return false + } + if this.AttestationManifest != that.AttestationManifest { + return false + } + if len(this.SignatureManifests) != len(that.SignatureManifests) { + return false + } + for i, vx := range this.SignatureManifests { + vy := that.SignatureManifests[i] + if vx != vy { + return false + } + } + if len(this.Blobs) != len(that.Blobs) { + return false + } + for i, vx := range this.Blobs { + vy, ok := that.Blobs[i] + if !ok { + return false + } + if p, q := vx, vy; p != q { + if p == nil { + p = &Blob{} + } + if q == nil { + q = &Blob{} + } + if !p.EqualVT(q) { + return false + } + } + } + return string(this.unknownFields) == string(that.unknownFields) +} + +func (this *AttestationChain) EqualMessageVT(thatMsg proto.Message) bool { + that, ok := thatMsg.(*AttestationChain) + if !ok { + return false + } + return this.EqualVT(that) +} func (this *ResolveSourceImageResponse) EqualVT(that *ResolveSourceImageResponse) bool { if this == that { return true @@ -1827,6 +2005,9 @@ func (this *ResolveSourceImageResponse) EqualVT(that *ResolveSourceImageResponse if string(this.Config) != string(that.Config) { return false } + if !this.AttestationChain.EqualVT(that.AttestationChain) { + return false + } return string(this.unknownFields) == string(that.unknownFields) } @@ -2932,6 +3113,65 @@ func (this *SignalMessage) EqualMessageVT(thatMsg proto.Message) bool { } return this.EqualVT(that) } +func (this *Blob) EqualVT(that *Blob) bool { + if this == that { + return true + } else if this == nil || that == nil { + return false + } + if !this.Descriptor_.EqualVT(that.Descriptor_) { + return false + } + if string(this.Data) != string(that.Data) { + return false + } + return string(this.unknownFields) == string(that.unknownFields) +} + +func (this *Blob) EqualMessageVT(thatMsg proto.Message) bool { + that, ok := thatMsg.(*Blob) + if !ok { + return false + } + return this.EqualVT(that) +} +func (this *Descriptor) EqualVT(that *Descriptor) bool { + if this == that { + return true + } else if this == nil || that == nil { + return false + } + if this.MediaType != that.MediaType { + return false + } + if this.Digest != that.Digest { + return false + } + if this.Size != that.Size { + return false + } + if len(this.Annotations) != len(that.Annotations) { + return false + } + for i, vx := range this.Annotations { + vy, ok := that.Annotations[i] + if !ok { + return false + } + if vx != vy { + return false + } + } + return string(this.unknownFields) == string(that.unknownFields) +} + +func (this *Descriptor) EqualMessageVT(thatMsg proto.Message) bool { + that, ok := thatMsg.(*Descriptor) + if !ok { + return false + } + return this.EqualVT(that) +} func (m *Result) MarshalVT() (dAtA []byte, err error) { if m == nil { return nil, nil @@ -3824,6 +4064,16 @@ func (m *ResolveSourceMetaRequest) MarshalToSizedBufferVT(dAtA []byte) (int, err dAtA[i] = 0x42 } } + if m.Image != nil { + size, err := m.Image.MarshalToSizedBufferVT(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = protohelpers.EncodeVarint(dAtA, i, uint64(size)) + i-- + dAtA[i] = 0x32 + } if m.Git != nil { size, err := m.Git.MarshalToSizedBufferVT(dAtA[:i]) if err != nil { @@ -3944,6 +4194,144 @@ func (m *ResolveSourceMetaResponse) MarshalToSizedBufferVT(dAtA []byte) (int, er return len(dAtA) - i, nil } +func (m *ResolveSourceImageRequest) MarshalVT() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVT(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *ResolveSourceImageRequest) MarshalToVT(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVT(dAtA[:size]) +} + +func (m *ResolveSourceImageRequest) MarshalToSizedBufferVT(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if m.AttestationChain { + i-- + if m.AttestationChain { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x10 + } + if m.NoConfig { + i-- + if m.NoConfig { + dAtA[i] = 1 + } else { + dAtA[i] = 0 + } + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *AttestationChain) MarshalVT() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVT(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *AttestationChain) MarshalToVT(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVT(dAtA[:size]) +} + +func (m *AttestationChain) MarshalToSizedBufferVT(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if len(m.Blobs) > 0 { + for k := range m.Blobs { + v := m.Blobs[k] + baseI := i + size, err := v.MarshalToSizedBufferVT(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = protohelpers.EncodeVarint(dAtA, i, uint64(size)) + i-- + dAtA[i] = 0x12 + i -= len(k) + copy(dAtA[i:], k) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(k))) + i-- + dAtA[i] = 0xa + i = protohelpers.EncodeVarint(dAtA, i, uint64(baseI-i)) + i-- + dAtA[i] = 0x2a + } + } + if len(m.SignatureManifests) > 0 { + for iNdEx := len(m.SignatureManifests) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.SignatureManifests[iNdEx]) + copy(dAtA[i:], m.SignatureManifests[iNdEx]) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.SignatureManifests[iNdEx]))) + i-- + dAtA[i] = 0x22 + } + } + if len(m.AttestationManifest) > 0 { + i -= len(m.AttestationManifest) + copy(dAtA[i:], m.AttestationManifest) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.AttestationManifest))) + i-- + dAtA[i] = 0x1a + } + if len(m.ImageManifest) > 0 { + i -= len(m.ImageManifest) + copy(dAtA[i:], m.ImageManifest) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.ImageManifest))) + i-- + dAtA[i] = 0x12 + } + if len(m.Root) > 0 { + i -= len(m.Root) + copy(dAtA[i:], m.Root) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.Root))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *ResolveSourceImageResponse) MarshalVT() (dAtA []byte, err error) { if m == nil { return nil, nil @@ -3974,6 +4362,16 @@ func (m *ResolveSourceImageResponse) MarshalToSizedBufferVT(dAtA []byte) (int, e i -= len(m.unknownFields) copy(dAtA[i:], m.unknownFields) } + if m.AttestationChain != nil { + size, err := m.AttestationChain.MarshalToSizedBufferVT(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = protohelpers.EncodeVarint(dAtA, i, uint64(size)) + i-- + dAtA[i] = 0x1a + } if len(m.Config) > 0 { i -= len(m.Config) copy(dAtA[i:], m.Config) @@ -5854,6 +6252,127 @@ func (m *SignalMessage) MarshalToSizedBufferVT(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *Blob) MarshalVT() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVT(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Blob) MarshalToVT(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVT(dAtA[:size]) +} + +func (m *Blob) MarshalToSizedBufferVT(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if len(m.Data) > 0 { + i -= len(m.Data) + copy(dAtA[i:], m.Data) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.Data))) + i-- + dAtA[i] = 0x12 + } + if m.Descriptor_ != nil { + size, err := m.Descriptor_.MarshalToSizedBufferVT(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = protohelpers.EncodeVarint(dAtA, i, uint64(size)) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *Descriptor) MarshalVT() (dAtA []byte, err error) { + if m == nil { + return nil, nil + } + size := m.SizeVT() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBufferVT(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *Descriptor) MarshalToVT(dAtA []byte) (int, error) { + size := m.SizeVT() + return m.MarshalToSizedBufferVT(dAtA[:size]) +} + +func (m *Descriptor) MarshalToSizedBufferVT(dAtA []byte) (int, error) { + if m == nil { + return 0, nil + } + i := len(dAtA) + _ = i + var l int + _ = l + if m.unknownFields != nil { + i -= len(m.unknownFields) + copy(dAtA[i:], m.unknownFields) + } + if len(m.Annotations) > 0 { + for k := range m.Annotations { + v := m.Annotations[k] + baseI := i + i -= len(v) + copy(dAtA[i:], v) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(v))) + i-- + dAtA[i] = 0x12 + i -= len(k) + copy(dAtA[i:], k) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(k))) + i-- + dAtA[i] = 0xa + i = protohelpers.EncodeVarint(dAtA, i, uint64(baseI-i)) + i-- + dAtA[i] = 0x2a + } + } + if m.Size != 0 { + i = protohelpers.EncodeVarint(dAtA, i, uint64(m.Size)) + i-- + dAtA[i] = 0x18 + } + if len(m.Digest) > 0 { + i -= len(m.Digest) + copy(dAtA[i:], m.Digest) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.Digest))) + i-- + dAtA[i] = 0x12 + } + if len(m.MediaType) > 0 { + i -= len(m.MediaType) + copy(dAtA[i:], m.MediaType) + i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.MediaType))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *Result) SizeVT() (n int) { if m == nil { return 0 @@ -6237,6 +6756,10 @@ func (m *ResolveSourceMetaRequest) SizeVT() (n int) { l = m.Git.SizeVT() n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) } + if m.Image != nil { + l = m.Image.SizeVT() + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } if len(m.SourcePolicies) > 0 { for _, e := range m.SourcePolicies { l = e.SizeVT() @@ -6273,6 +6796,63 @@ func (m *ResolveSourceMetaResponse) SizeVT() (n int) { return n } +func (m *ResolveSourceImageRequest) SizeVT() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.NoConfig { + n += 2 + } + if m.AttestationChain { + n += 2 + } + n += len(m.unknownFields) + return n +} + +func (m *AttestationChain) SizeVT() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Root) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + l = len(m.ImageManifest) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + l = len(m.AttestationManifest) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + if len(m.SignatureManifests) > 0 { + for _, s := range m.SignatureManifests { + l = len(s) + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + } + if len(m.Blobs) > 0 { + for k, v := range m.Blobs { + _ = k + _ = v + l = 0 + if v != nil { + l = v.SizeVT() + } + l += 1 + protohelpers.SizeOfVarint(uint64(l)) + mapEntrySize := 1 + len(k) + protohelpers.SizeOfVarint(uint64(len(k))) + l + n += mapEntrySize + 1 + protohelpers.SizeOfVarint(uint64(mapEntrySize)) + } + } + n += len(m.unknownFields) + return n +} + func (m *ResolveSourceImageResponse) SizeVT() (n int) { if m == nil { return 0 @@ -6287,6 +6867,10 @@ func (m *ResolveSourceImageResponse) SizeVT() (n int) { if l > 0 { n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) } + if m.AttestationChain != nil { + l = m.AttestationChain.SizeVT() + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } n += len(m.unknownFields) return n } @@ -7030,6 +7614,53 @@ func (m *SignalMessage) SizeVT() (n int) { return n } +func (m *Blob) SizeVT() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Descriptor_ != nil { + l = m.Descriptor_.SizeVT() + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + l = len(m.Data) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + n += len(m.unknownFields) + return n +} + +func (m *Descriptor) SizeVT() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.MediaType) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + l = len(m.Digest) + if l > 0 { + n += 1 + l + protohelpers.SizeOfVarint(uint64(l)) + } + if m.Size != 0 { + n += 1 + protohelpers.SizeOfVarint(uint64(m.Size)) + } + if len(m.Annotations) > 0 { + for k, v := range m.Annotations { + _ = k + _ = v + mapEntrySize := 1 + len(k) + protohelpers.SizeOfVarint(uint64(len(k))) + 1 + len(v) + protohelpers.SizeOfVarint(uint64(len(v))) + n += mapEntrySize + 1 + protohelpers.SizeOfVarint(uint64(mapEntrySize)) + } + } + n += len(m.unknownFields) + return n +} + func (m *Result) UnmarshalVT(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -9584,6 +10215,42 @@ func (m *ResolveSourceMetaRequest) UnmarshalVT(dAtA []byte) error { return err } iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Image", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Image == nil { + m.Image = &ResolveSourceImageRequest{} + } + if err := m.Image.UnmarshalVT(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex case 8: if wireType != 2 { return fmt.Errorf("proto: wrong wireType = %d for field SourcePolicies", wireType) @@ -9835,6 +10502,405 @@ func (m *ResolveSourceMetaResponse) UnmarshalVT(dAtA []byte) error { } return nil } +func (m *ResolveSourceImageRequest) UnmarshalVT(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: ResolveSourceImageRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: ResolveSourceImageRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field NoConfig", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.NoConfig = bool(v != 0) + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AttestationChain", wireType) + } + var v int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + v |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + m.AttestationChain = bool(v != 0) + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *AttestationChain) UnmarshalVT(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: AttestationChain: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: AttestationChain: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Root", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Root = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ImageManifest", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ImageManifest = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AttestationManifest", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AttestationManifest = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field SignatureManifests", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.SignatureManifests = append(m.SignatureManifests, string(dAtA[iNdEx:postIndex])) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Blobs", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Blobs == nil { + m.Blobs = make(map[string]*Blob) + } + var mapkey string + var mapvalue *Blob + for iNdEx < postIndex { + entryPreIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + if fieldNum == 1 { + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return protohelpers.ErrInvalidLength + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey < 0 { + return protohelpers.ErrInvalidLength + } + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + } else if fieldNum == 2 { + var mapmsglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + mapmsglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if mapmsglen < 0 { + return protohelpers.ErrInvalidLength + } + postmsgIndex := iNdEx + mapmsglen + if postmsgIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postmsgIndex > l { + return io.ErrUnexpectedEOF + } + mapvalue = &Blob{} + if err := mapvalue.UnmarshalVT(dAtA[iNdEx:postmsgIndex]); err != nil { + return err + } + iNdEx = postmsgIndex + } else { + iNdEx = entryPreIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > postIndex { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + m.Blobs[mapkey] = mapvalue + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *ResolveSourceImageResponse) UnmarshalVT(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -9930,6 +10996,42 @@ func (m *ResolveSourceImageResponse) UnmarshalVT(dAtA []byte) error { m.Config = []byte{} } iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AttestationChain", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.AttestationChain == nil { + m.AttestationChain = &AttestationChain{} + } + if err := m.AttestationChain.UnmarshalVT(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := protohelpers.Skip(dAtA[iNdEx:]) @@ -14318,3 +15420,385 @@ func (m *SignalMessage) UnmarshalVT(dAtA []byte) error { } return nil } +func (m *Blob) UnmarshalVT(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Blob: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Blob: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Descriptor_", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Descriptor_ == nil { + m.Descriptor_ = &Descriptor{} + } + if err := m.Descriptor_.UnmarshalVT(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) + if m.Data == nil { + m.Data = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *Descriptor) UnmarshalVT(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: Descriptor: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: Descriptor: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field MediaType", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.MediaType = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Digest", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Digest = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Size", wireType) + } + m.Size = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Size |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Annotations", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return protohelpers.ErrInvalidLength + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return protohelpers.ErrInvalidLength + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Annotations == nil { + m.Annotations = make(map[string]string) + } + var mapkey string + var mapvalue string + for iNdEx < postIndex { + entryPreIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + if fieldNum == 1 { + var stringLenmapkey uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapkey |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapkey := int(stringLenmapkey) + if intStringLenmapkey < 0 { + return protohelpers.ErrInvalidLength + } + postStringIndexmapkey := iNdEx + intStringLenmapkey + if postStringIndexmapkey < 0 { + return protohelpers.ErrInvalidLength + } + if postStringIndexmapkey > l { + return io.ErrUnexpectedEOF + } + mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) + iNdEx = postStringIndexmapkey + } else if fieldNum == 2 { + var stringLenmapvalue uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return protohelpers.ErrIntOverflow + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLenmapvalue |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLenmapvalue := int(stringLenmapvalue) + if intStringLenmapvalue < 0 { + return protohelpers.ErrInvalidLength + } + postStringIndexmapvalue := iNdEx + intStringLenmapvalue + if postStringIndexmapvalue < 0 { + return protohelpers.ErrInvalidLength + } + if postStringIndexmapvalue > l { + return io.ErrUnexpectedEOF + } + mapvalue = string(dAtA[iNdEx:postStringIndexmapvalue]) + iNdEx = postStringIndexmapvalue + } else { + iNdEx = entryPreIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > postIndex { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + m.Annotations[mapkey] = mapvalue + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := protohelpers.Skip(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return protohelpers.ErrInvalidLength + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...) + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} diff --git a/vendor/github.com/moby/buildkit/util/contentutil/fetcher.go b/vendor/github.com/moby/buildkit/util/contentutil/fetcher.go index 560b9fcfc..bb5f12d50 100644 --- a/vendor/github.com/moby/buildkit/util/contentutil/fetcher.go +++ b/vendor/github.com/moby/buildkit/util/contentutil/fetcher.go @@ -6,11 +6,17 @@ import ( "github.com/containerd/containerd/v2/core/content" "github.com/containerd/containerd/v2/core/remotes" + digest "github.com/opencontainers/go-digest" ocispecs "github.com/opencontainers/image-spec/specs-go/v1" "github.com/pkg/errors" ) -func FromFetcher(f remotes.Fetcher) content.Provider { +type ReferrersProvider interface { + content.Provider + remotes.ReferrersFetcher +} + +func FromFetcher(f remotes.Fetcher) ReferrersProvider { return &fetchedProvider{ f: f, } @@ -29,6 +35,14 @@ func (p *fetchedProvider) ReaderAt(ctx context.Context, desc ocispecs.Descriptor return &readerAt{Reader: rc, Closer: rc, size: desc.Size}, nil } +func (p *fetchedProvider) FetchReferrers(ctx context.Context, dgst digest.Digest, opts ...remotes.FetchReferrersOpt) ([]ocispecs.Descriptor, error) { + refs, ok := p.f.(remotes.ReferrersFetcher) + if !ok { + return nil, errors.Errorf("fetcher does not support referrers") + } + return refs.FetchReferrers(ctx, dgst, opts...) +} + type readerAt struct { io.Reader io.Closer diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go index e854d7e84..2950fdb42 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/id.go @@ -82,7 +82,7 @@ func marshalJSON(id []byte) ([]byte, error) { } // unmarshalJSON inflates trace id from hex string, possibly enclosed in quotes. -func unmarshalJSON(dst []byte, src []byte) error { +func unmarshalJSON(dst, src []byte) error { if l := len(src); l >= 2 && src[0] == '"' && src[l-1] == '"' { src = src[1 : l-1] } diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go index 29e629d66..5bb3b16c7 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/number.go @@ -41,7 +41,7 @@ func (i *protoInt64) UnmarshalJSON(data []byte) error { // strings or integers. type protoUint64 uint64 -// Int64 returns the protoUint64 as a uint64. +// Uint64 returns the protoUint64 as a uint64. func (i *protoUint64) Uint64() uint64 { return uint64(*i) } // UnmarshalJSON decodes both strings and integers. diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go index a13a6b733..67f80b6aa 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/span.go @@ -10,6 +10,7 @@ import ( "errors" "fmt" "io" + "math" "time" ) @@ -151,8 +152,8 @@ func (s Span) MarshalJSON() ([]byte, error) { }{ Alias: Alias(s), ParentSpanID: parentSpanId, - StartTime: uint64(startT), - EndTime: uint64(endT), + StartTime: uint64(startT), // nolint:gosec // >0 checked above. + EndTime: uint64(endT), // nolint:gosec // >0 checked above. }) } @@ -201,11 +202,13 @@ func (s *Span) UnmarshalJSON(data []byte) error { case "startTimeUnixNano", "start_time_unix_nano": var val protoUint64 err = decoder.Decode(&val) - s.StartTime = time.Unix(0, int64(val.Uint64())) + v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked. + s.StartTime = time.Unix(0, v) case "endTimeUnixNano", "end_time_unix_nano": var val protoUint64 err = decoder.Decode(&val) - s.EndTime = time.Unix(0, int64(val.Uint64())) + v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked. + s.EndTime = time.Unix(0, v) case "attributes": err = decoder.Decode(&s.Attrs) case "droppedAttributesCount", "dropped_attributes_count": @@ -248,13 +251,20 @@ func (s *Span) UnmarshalJSON(data []byte) error { type SpanFlags int32 const ( + // SpanFlagsTraceFlagsMask is a mask for trace-flags. + // // Bits 0-7 are used for trace flags. SpanFlagsTraceFlagsMask SpanFlags = 255 - // Bits 8 and 9 are used to indicate that the parent span or link span is remote. - // Bit 8 (`HAS_IS_REMOTE`) indicates whether the value is known. - // Bit 9 (`IS_REMOTE`) indicates whether the span or link is remote. + // SpanFlagsContextHasIsRemoteMask is a mask for HAS_IS_REMOTE status. + // + // Bits 8 and 9 are used to indicate that the parent span or link span is + // remote. Bit 8 (`HAS_IS_REMOTE`) indicates whether the value is known. SpanFlagsContextHasIsRemoteMask SpanFlags = 256 - // SpanFlagsContextHasIsRemoteMask indicates the Span is remote. + // SpanFlagsContextIsRemoteMask is a mask for IS_REMOTE status. + // + // Bits 8 and 9 are used to indicate that the parent span or link span is + // remote. Bit 9 (`IS_REMOTE`) indicates whether the span or link is + // remote. SpanFlagsContextIsRemoteMask SpanFlags = 512 ) @@ -263,26 +273,30 @@ const ( type SpanKind int32 const ( - // Indicates that the span represents an internal operation within an application, - // as opposed to an operation happening at the boundaries. Default value. + // SpanKindInternal indicates that the span represents an internal + // operation within an application, as opposed to an operation happening at + // the boundaries. SpanKindInternal SpanKind = 1 - // Indicates that the span covers server-side handling of an RPC or other - // remote network request. + // SpanKindServer indicates that the span covers server-side handling of an + // RPC or other remote network request. SpanKindServer SpanKind = 2 - // Indicates that the span describes a request to some remote service. + // SpanKindClient indicates that the span describes a request to some + // remote service. SpanKindClient SpanKind = 3 - // Indicates that the span describes a producer sending a message to a broker. - // Unlike CLIENT and SERVER, there is often no direct critical path latency relationship - // between producer and consumer spans. A PRODUCER span ends when the message was accepted - // by the broker while the logical processing of the message might span a much longer time. + // SpanKindProducer indicates that the span describes a producer sending a + // message to a broker. Unlike SpanKindClient and SpanKindServer, there is + // often no direct critical path latency relationship between producer and + // consumer spans. A SpanKindProducer span ends when the message was + // accepted by the broker while the logical processing of the message might + // span a much longer time. SpanKindProducer SpanKind = 4 - // Indicates that the span describes consumer receiving a message from a broker. - // Like the PRODUCER kind, there is often no direct critical path latency relationship - // between producer and consumer spans. + // SpanKindConsumer indicates that the span describes a consumer receiving + // a message from a broker. Like SpanKindProducer, there is often no direct + // critical path latency relationship between producer and consumer spans. SpanKindConsumer SpanKind = 5 ) -// Event is a time-stamped annotation of the span, consisting of user-supplied +// SpanEvent is a time-stamped annotation of the span, consisting of user-supplied // text description and key-value pairs. type SpanEvent struct { // time_unix_nano is the time the event occurred. @@ -312,7 +326,7 @@ func (e SpanEvent) MarshalJSON() ([]byte, error) { Time uint64 `json:"timeUnixNano,omitempty"` }{ Alias: Alias(e), - Time: uint64(t), + Time: uint64(t), //nolint:gosec // >0 checked above }) } @@ -347,7 +361,8 @@ func (se *SpanEvent) UnmarshalJSON(data []byte) error { case "timeUnixNano", "time_unix_nano": var val protoUint64 err = decoder.Decode(&val) - se.Time = time.Unix(0, int64(val.Uint64())) + v := int64(min(val.Uint64(), math.MaxInt64)) //nolint:gosec // Overflow checked. + se.Time = time.Unix(0, v) case "name": err = decoder.Decode(&se.Name) case "attributes": @@ -365,10 +380,11 @@ func (se *SpanEvent) UnmarshalJSON(data []byte) error { return nil } -// A pointer from the current span to another span in the same trace or in a -// different trace. For example, this can be used in batching operations, -// where a single batch handler processes multiple requests from different -// traces or when the handler receives a request from a different project. +// SpanLink is a reference from the current span to another span in the same +// trace or in a different trace. For example, this can be used in batching +// operations, where a single batch handler processes multiple requests from +// different traces or when the handler receives a request from a different +// project. type SpanLink struct { // A unique identifier of a trace that this linked span is part of. The ID is a // 16-byte array. diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go index 1217776ea..a2802764f 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/status.go @@ -3,17 +3,19 @@ package telemetry +// StatusCode is the status of a Span. +// // For the semantics of status codes see // https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/api.md#set-status type StatusCode int32 const ( - // The default status. + // StatusCodeUnset is the default status. StatusCodeUnset StatusCode = 0 - // The Span has been validated by an Application developer or Operator to - // have completed successfully. + // StatusCodeOK is used when the Span has been validated by an Application + // developer or Operator to have completed successfully. StatusCodeOK StatusCode = 1 - // The Span contains an error. + // StatusCodeError is used when the Span contains an error. StatusCodeError StatusCode = 2 ) diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go index 69a348f0f..44197b808 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/traces.go @@ -71,7 +71,7 @@ func (td *Traces) UnmarshalJSON(data []byte) error { return nil } -// A collection of ScopeSpans from a Resource. +// ResourceSpans is a collection of ScopeSpans from a Resource. type ResourceSpans struct { // The resource for the spans in this message. // If this field is not set then no resource info is known. @@ -128,7 +128,7 @@ func (rs *ResourceSpans) UnmarshalJSON(data []byte) error { return nil } -// A collection of Spans produced by an InstrumentationScope. +// ScopeSpans is a collection of Spans produced by an InstrumentationScope. type ScopeSpans struct { // The instrumentation scope information for the spans in this message. // Semantically when InstrumentationScope isn't set, it is equivalent with diff --git a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go index 0dd01b063..022768bb5 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go +++ b/vendor/go.opentelemetry.io/auto/sdk/internal/telemetry/value.go @@ -1,8 +1,6 @@ // Copyright The OpenTelemetry Authors // SPDX-License-Identifier: Apache-2.0 -//go:generate stringer -type=ValueKind -trimprefix=ValueKind - package telemetry import ( @@ -23,7 +21,7 @@ import ( // A zero value is valid and represents an empty value. type Value struct { // Ensure forward compatibility by explicitly making this not comparable. - noCmp [0]func() //nolint: unused // This is indeed used. + noCmp [0]func() //nolint:unused // This is indeed used. // num holds the value for Int64, Float64, and Bool. It holds the length // for String, Bytes, Slice, Map. @@ -92,7 +90,7 @@ func IntValue(v int) Value { return Int64Value(int64(v)) } // Int64Value returns a [Value] for an int64. func Int64Value(v int64) Value { - return Value{num: uint64(v), any: ValueKindInt64} + return Value{num: uint64(v), any: ValueKindInt64} //nolint:gosec // Raw value conv. } // Float64Value returns a [Value] for a float64. @@ -164,7 +162,7 @@ func (v Value) AsInt64() int64 { // this will return garbage. func (v Value) asInt64() int64 { // Assumes v.num was a valid int64 (overflow not checked). - return int64(v.num) // nolint: gosec + return int64(v.num) //nolint:gosec // Bounded. } // AsBool returns the value held by v as a bool. @@ -309,13 +307,13 @@ func (v Value) String() string { return v.asString() case ValueKindInt64: // Assumes v.num was a valid int64 (overflow not checked). - return strconv.FormatInt(int64(v.num), 10) // nolint: gosec + return strconv.FormatInt(int64(v.num), 10) //nolint:gosec // Bounded. case ValueKindFloat64: return strconv.FormatFloat(v.asFloat64(), 'g', -1, 64) case ValueKindBool: return strconv.FormatBool(v.asBool()) case ValueKindBytes: - return fmt.Sprint(v.asBytes()) + return string(v.asBytes()) case ValueKindMap: return fmt.Sprint(v.asMap()) case ValueKindSlice: @@ -343,7 +341,7 @@ func (v *Value) MarshalJSON() ([]byte, error) { case ValueKindInt64: return json.Marshal(struct { Value string `json:"intValue"` - }{strconv.FormatInt(int64(v.num), 10)}) + }{strconv.FormatInt(int64(v.num), 10)}) //nolint:gosec // Raw value conv. case ValueKindFloat64: return json.Marshal(struct { Value float64 `json:"doubleValue"` diff --git a/vendor/go.opentelemetry.io/auto/sdk/span.go b/vendor/go.opentelemetry.io/auto/sdk/span.go index 6ebea12a9..815d271ff 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/span.go +++ b/vendor/go.opentelemetry.io/auto/sdk/span.go @@ -6,6 +6,7 @@ package sdk import ( "encoding/json" "fmt" + "math" "reflect" "runtime" "strings" @@ -16,7 +17,7 @@ import ( "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/codes" - semconv "go.opentelemetry.io/otel/semconv/v1.26.0" + semconv "go.opentelemetry.io/otel/semconv/v1.37.0" "go.opentelemetry.io/otel/trace" "go.opentelemetry.io/otel/trace/noop" @@ -85,7 +86,12 @@ func (s *span) SetAttributes(attrs ...attribute.KeyValue) { limit := maxSpan.Attrs if limit == 0 { // No attributes allowed. - s.span.DroppedAttrs += uint32(len(attrs)) + n := int64(len(attrs)) + if n > 0 { + s.span.DroppedAttrs += uint32( //nolint:gosec // Bounds checked. + min(n, math.MaxUint32), + ) + } return } @@ -121,8 +127,13 @@ func (s *span) SetAttributes(attrs ...attribute.KeyValue) { // convCappedAttrs converts up to limit attrs into a []telemetry.Attr. The // number of dropped attributes is also returned. func convCappedAttrs(limit int, attrs []attribute.KeyValue) ([]telemetry.Attr, uint32) { + n := len(attrs) if limit == 0 { - return nil, uint32(len(attrs)) + var out uint32 + if n > 0 { + out = uint32(min(int64(n), math.MaxUint32)) //nolint:gosec // Bounds checked. + } + return nil, out } if limit < 0 { @@ -130,8 +141,12 @@ func convCappedAttrs(limit int, attrs []attribute.KeyValue) ([]telemetry.Attr, u return convAttrs(attrs), 0 } - limit = min(len(attrs), limit) - return convAttrs(attrs[:limit]), uint32(len(attrs) - limit) + if n < 0 { + n = 0 + } + + limit = min(n, limit) + return convAttrs(attrs[:limit]), uint32(n - limit) //nolint:gosec // Bounds checked. } func convAttrs(attrs []attribute.KeyValue) []telemetry.Attr { diff --git a/vendor/go.opentelemetry.io/auto/sdk/tracer.go b/vendor/go.opentelemetry.io/auto/sdk/tracer.go index cbcfabde3..e09acf022 100644 --- a/vendor/go.opentelemetry.io/auto/sdk/tracer.go +++ b/vendor/go.opentelemetry.io/auto/sdk/tracer.go @@ -5,6 +5,7 @@ package sdk import ( "context" + "math" "time" "go.opentelemetry.io/otel/trace" @@ -21,15 +22,20 @@ type tracer struct { var _ trace.Tracer = tracer{} -func (t tracer) Start(ctx context.Context, name string, opts ...trace.SpanStartOption) (context.Context, trace.Span) { - var psc trace.SpanContext +func (t tracer) Start( + ctx context.Context, + name string, + opts ...trace.SpanStartOption, +) (context.Context, trace.Span) { + var psc, sc trace.SpanContext sampled := true span := new(span) // Ask eBPF for sampling decision and span context info. - t.start(ctx, span, &psc, &sampled, &span.spanContext) + t.start(ctx, span, &psc, &sampled, &sc) span.sampled.Store(sampled) + span.spanContext = sc ctx = trace.ContextWithSpan(ctx, span) @@ -58,7 +64,13 @@ func (t *tracer) start( // start is used for testing. var start = func(context.Context, *span, *trace.SpanContext, *bool, *trace.SpanContext) {} -func (t tracer) traces(name string, cfg trace.SpanConfig, sc, psc trace.SpanContext) (*telemetry.Traces, *telemetry.Span) { +var intToUint32Bound = min(math.MaxInt, math.MaxUint32) + +func (t tracer) traces( + name string, + cfg trace.SpanConfig, + sc, psc trace.SpanContext, +) (*telemetry.Traces, *telemetry.Span) { span := &telemetry.Span{ TraceID: telemetry.TraceID(sc.TraceID()), SpanID: telemetry.SpanID(sc.SpanID()), @@ -73,11 +85,16 @@ func (t tracer) traces(name string, cfg trace.SpanConfig, sc, psc trace.SpanCont links := cfg.Links() if limit := maxSpan.Links; limit == 0 { - span.DroppedLinks = uint32(len(links)) + n := len(links) + if n > 0 { + bounded := max(min(n, intToUint32Bound), 0) + span.DroppedLinks = uint32(bounded) //nolint:gosec // Bounds checked. + } } else { if limit > 0 { n := max(len(links)-limit, 0) - span.DroppedLinks = uint32(n) + bounded := min(n, intToUint32Bound) + span.DroppedLinks = uint32(bounded) //nolint:gosec // Bounds checked. links = links[n:] } span.Links = convLinks(links) diff --git a/vendor/modules.txt b/vendor/modules.txt index 51eadd0f6..4d39463cc 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -443,7 +443,7 @@ github.com/mitchellh/go-wordwrap # github.com/mitchellh/hashstructure/v2 v2.0.2 ## explicit; go 1.14 github.com/mitchellh/hashstructure/v2 -# github.com/moby/buildkit v0.25.0-rc1.0.20251105204500-e18be4182830 +# github.com/moby/buildkit v0.26.0-rc1 ## explicit; go 1.24.3 github.com/moby/buildkit/api/services/control github.com/moby/buildkit/api/types @@ -699,8 +699,8 @@ github.com/zclconf/go-cty/cty/function/stdlib github.com/zclconf/go-cty/cty/gocty github.com/zclconf/go-cty/cty/json github.com/zclconf/go-cty/cty/set -# go.opentelemetry.io/auto/sdk v1.1.0 -## explicit; go 1.22.0 +# go.opentelemetry.io/auto/sdk v1.2.1 +## explicit; go 1.24.0 go.opentelemetry.io/auto/sdk go.opentelemetry.io/auto/sdk/internal/telemetry # go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.61.0