File: policy.pb.go

package info (click to toggle)
docker.io 27.5.1%2Bdfsg4-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 67,384 kB
  • sloc: sh: 5,847; makefile: 1,146; ansic: 664; python: 162; asm: 133
file content (615 lines) | stat: -rw-r--r-- 23,758 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.35.1
// 	protoc        v3.11.4
// source: github.com/moby/buildkit/sourcepolicy/pb/policy.proto

package moby_buildkit_v1_sourcepolicy

import (
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	reflect "reflect"
	sync "sync"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

// PolicyAction defines the action to take when a source is matched
type PolicyAction int32

const (
	PolicyAction_ALLOW   PolicyAction = 0
	PolicyAction_DENY    PolicyAction = 1
	PolicyAction_CONVERT PolicyAction = 2
)

// Enum value maps for PolicyAction.
var (
	PolicyAction_name = map[int32]string{
		0: "ALLOW",
		1: "DENY",
		2: "CONVERT",
	}
	PolicyAction_value = map[string]int32{
		"ALLOW":   0,
		"DENY":    1,
		"CONVERT": 2,
	}
)

func (x PolicyAction) Enum() *PolicyAction {
	p := new(PolicyAction)
	*p = x
	return p
}

func (x PolicyAction) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (PolicyAction) Descriptor() protoreflect.EnumDescriptor {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[0].Descriptor()
}

func (PolicyAction) Type() protoreflect.EnumType {
	return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[0]
}

func (x PolicyAction) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use PolicyAction.Descriptor instead.
func (PolicyAction) EnumDescriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{0}
}

// AttrMatch defines the condition to match a source attribute
type AttrMatch int32

const (
	AttrMatch_EQUAL    AttrMatch = 0
	AttrMatch_NOTEQUAL AttrMatch = 1
	AttrMatch_MATCHES  AttrMatch = 2
)

// Enum value maps for AttrMatch.
var (
	AttrMatch_name = map[int32]string{
		0: "EQUAL",
		1: "NOTEQUAL",
		2: "MATCHES",
	}
	AttrMatch_value = map[string]int32{
		"EQUAL":    0,
		"NOTEQUAL": 1,
		"MATCHES":  2,
	}
)

func (x AttrMatch) Enum() *AttrMatch {
	p := new(AttrMatch)
	*p = x
	return p
}

func (x AttrMatch) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (AttrMatch) Descriptor() protoreflect.EnumDescriptor {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[1].Descriptor()
}

func (AttrMatch) Type() protoreflect.EnumType {
	return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[1]
}

func (x AttrMatch) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use AttrMatch.Descriptor instead.
func (AttrMatch) EnumDescriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{1}
}

// Match type is used to determine how a rule source is matched
type MatchType int32

const (
	// WILDCARD is the default matching type.
	// It may first attempt to due an exact match but will follow up with a wildcard match
	// For something more powerful, use REGEX
	MatchType_WILDCARD MatchType = 0
	// EXACT treats the source identifier as a litteral string match
	MatchType_EXACT MatchType = 1
	// REGEX treats the source identifier as a regular expression
	// With regex matching you can also use match groups to replace values in the destination identifier
	MatchType_REGEX MatchType = 2
)

// Enum value maps for MatchType.
var (
	MatchType_name = map[int32]string{
		0: "WILDCARD",
		1: "EXACT",
		2: "REGEX",
	}
	MatchType_value = map[string]int32{
		"WILDCARD": 0,
		"EXACT":    1,
		"REGEX":    2,
	}
)

func (x MatchType) Enum() *MatchType {
	p := new(MatchType)
	*p = x
	return p
}

func (x MatchType) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (MatchType) Descriptor() protoreflect.EnumDescriptor {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[2].Descriptor()
}

func (MatchType) Type() protoreflect.EnumType {
	return &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes[2]
}

func (x MatchType) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use MatchType.Descriptor instead.
func (MatchType) EnumDescriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{2}
}

// Rule defines the action(s) to take when a source is matched
type Rule struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Action   PolicyAction `protobuf:"varint,1,opt,name=action,proto3,enum=moby.buildkit.v1.sourcepolicy.PolicyAction" json:"action,omitempty"`
	Selector *Selector    `protobuf:"bytes,2,opt,name=selector,proto3" json:"selector,omitempty"`
	Updates  *Update      `protobuf:"bytes,3,opt,name=updates,proto3" json:"updates,omitempty"`
}

func (x *Rule) Reset() {
	*x = Rule{}
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *Rule) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*Rule) ProtoMessage() {}

func (x *Rule) ProtoReflect() protoreflect.Message {
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[0]
	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 Rule.ProtoReflect.Descriptor instead.
func (*Rule) Descriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{0}
}

func (x *Rule) GetAction() PolicyAction {
	if x != nil {
		return x.Action
	}
	return PolicyAction_ALLOW
}

func (x *Rule) GetSelector() *Selector {
	if x != nil {
		return x.Selector
	}
	return nil
}

func (x *Rule) GetUpdates() *Update {
	if x != nil {
		return x.Updates
	}
	return nil
}

// Update contains updates to the matched build step after rule is applied
type Update struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Identifier string            `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"`
	Attrs      map[string]string `protobuf:"bytes,2,rep,name=attrs,proto3" json:"attrs,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
}

func (x *Update) Reset() {
	*x = Update{}
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *Update) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*Update) ProtoMessage() {}

func (x *Update) ProtoReflect() protoreflect.Message {
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[1]
	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 Update.ProtoReflect.Descriptor instead.
func (*Update) Descriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{1}
}

func (x *Update) GetIdentifier() string {
	if x != nil {
		return x.Identifier
	}
	return ""
}

func (x *Update) GetAttrs() map[string]string {
	if x != nil {
		return x.Attrs
	}
	return nil
}

// Selector identifies a source to match a policy to
type Selector struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"`
	// MatchType is the type of match to perform on the source identifier
	MatchType   MatchType         `protobuf:"varint,2,opt,name=match_type,json=matchType,proto3,enum=moby.buildkit.v1.sourcepolicy.MatchType" json:"match_type,omitempty"`
	Constraints []*AttrConstraint `protobuf:"bytes,3,rep,name=constraints,proto3" json:"constraints,omitempty"`
}

func (x *Selector) Reset() {
	*x = Selector{}
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *Selector) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*Selector) ProtoMessage() {}

func (x *Selector) ProtoReflect() protoreflect.Message {
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[2]
	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 Selector.ProtoReflect.Descriptor instead.
func (*Selector) Descriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{2}
}

func (x *Selector) GetIdentifier() string {
	if x != nil {
		return x.Identifier
	}
	return ""
}

func (x *Selector) GetMatchType() MatchType {
	if x != nil {
		return x.MatchType
	}
	return MatchType_WILDCARD
}

func (x *Selector) GetConstraints() []*AttrConstraint {
	if x != nil {
		return x.Constraints
	}
	return nil
}

// AttrConstraint defines a constraint on a source attribute
type AttrConstraint struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Key       string    `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value     string    `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	Condition AttrMatch `protobuf:"varint,3,opt,name=condition,proto3,enum=moby.buildkit.v1.sourcepolicy.AttrMatch" json:"condition,omitempty"`
}

func (x *AttrConstraint) Reset() {
	*x = AttrConstraint{}
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[3]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *AttrConstraint) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*AttrConstraint) ProtoMessage() {}

func (x *AttrConstraint) ProtoReflect() protoreflect.Message {
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[3]
	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 AttrConstraint.ProtoReflect.Descriptor instead.
func (*AttrConstraint) Descriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{3}
}

func (x *AttrConstraint) GetKey() string {
	if x != nil {
		return x.Key
	}
	return ""
}

func (x *AttrConstraint) GetValue() string {
	if x != nil {
		return x.Value
	}
	return ""
}

func (x *AttrConstraint) GetCondition() AttrMatch {
	if x != nil {
		return x.Condition
	}
	return AttrMatch_EQUAL
}

// Policy is the list of rules the policy engine will perform
type Policy struct {
	state         protoimpl.MessageState
	sizeCache     protoimpl.SizeCache
	unknownFields protoimpl.UnknownFields

	Version int64   `protobuf:"varint,1,opt,name=version,proto3" json:"version,omitempty"` // Currently 1
	Rules   []*Rule `protobuf:"bytes,2,rep,name=rules,proto3" json:"rules,omitempty"`
}

func (x *Policy) Reset() {
	*x = Policy{}
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[4]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *Policy) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*Policy) ProtoMessage() {}

func (x *Policy) ProtoReflect() protoreflect.Message {
	mi := &file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes[4]
	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 Policy.ProtoReflect.Descriptor instead.
func (*Policy) Descriptor() ([]byte, []int) {
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP(), []int{4}
}

func (x *Policy) GetVersion() int64 {
	if x != nil {
		return x.Version
	}
	return 0
}

func (x *Policy) GetRules() []*Rule {
	if x != nil {
		return x.Rules
	}
	return nil
}

var File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto protoreflect.FileDescriptor

var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc = []byte{
	0x0a, 0x35, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x6f, 0x62,
	0x79, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2f, 0x73, 0x6f, 0x75, 0x72, 0x63,
	0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2f, 0x70, 0x62, 0x2f, 0x70, 0x6f, 0x6c, 0x69, 0x63,
	0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1d, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75,
	0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
	0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x22, 0xd1, 0x01, 0x0a, 0x04, 0x52, 0x75, 0x6c, 0x65, 0x12,
	0x43, 0x0a, 0x06, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0e, 0x32,
	0x2b, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e,
	0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e,
	0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x06, 0x61, 0x63,
	0x74, 0x69, 0x6f, 0x6e, 0x12, 0x43, 0x0a, 0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72,
	0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75,
	0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65,
	0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x52,
	0x08, 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x12, 0x3f, 0x0a, 0x07, 0x75, 0x70, 0x64,
	0x61, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x6d, 0x6f, 0x62,
	0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f,
	0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,
	0x65, 0x52, 0x07, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x73, 0x22, 0xaa, 0x01, 0x0a, 0x06, 0x55,
	0x70, 0x64, 0x61, 0x74, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66,
	0x69, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74,
	0x69, 0x66, 0x69, 0x65, 0x72, 0x12, 0x46, 0x0a, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x18, 0x02,
	0x20, 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c,
	0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f,
	0x6c, 0x69, 0x63, 0x79, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x2e, 0x41, 0x74, 0x74, 0x72,
	0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x05, 0x61, 0x74, 0x74, 0x72, 0x73, 0x1a, 0x38, 0x0a,
	0x0a, 0x41, 0x74, 0x74, 0x72, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b,
	0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a,
	0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x76, 0x61,
	0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x22, 0xc4, 0x01, 0x0a, 0x08, 0x53, 0x65, 0x6c, 0x65,
	0x63, 0x74, 0x6f, 0x72, 0x12, 0x1e, 0x0a, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69,
	0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69,
	0x66, 0x69, 0x65, 0x72, 0x12, 0x47, 0x0a, 0x0a, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x5f, 0x74, 0x79,
	0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e,
	0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72,
	0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79,
	0x70, 0x65, 0x52, 0x09, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79, 0x70, 0x65, 0x12, 0x4f, 0x0a,
	0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x18, 0x03, 0x20, 0x03,
	0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b,
	0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69,
	0x63, 0x79, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e,
	0x74, 0x52, 0x0b, 0x63, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e, 0x74, 0x73, 0x22, 0x80,
	0x01, 0x0a, 0x0e, 0x41, 0x74, 0x74, 0x72, 0x43, 0x6f, 0x6e, 0x73, 0x74, 0x72, 0x61, 0x69, 0x6e,
	0x74, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03,
	0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01,
	0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x46, 0x0a, 0x09, 0x63, 0x6f, 0x6e,
	0x64, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x28, 0x2e, 0x6d,
	0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e,
	0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2e, 0x41, 0x74, 0x74,
	0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x52, 0x09, 0x63, 0x6f, 0x6e, 0x64, 0x69, 0x74, 0x69, 0x6f,
	0x6e, 0x22, 0x5d, 0x0a, 0x06, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x12, 0x18, 0x0a, 0x07, 0x76,
	0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x07, 0x76, 0x65,
	0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x39, 0x0a, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73, 0x18, 0x02,
	0x20, 0x03, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x6d, 0x6f, 0x62, 0x79, 0x2e, 0x62, 0x75, 0x69, 0x6c,
	0x64, 0x6b, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f,
	0x6c, 0x69, 0x63, 0x79, 0x2e, 0x52, 0x75, 0x6c, 0x65, 0x52, 0x05, 0x72, 0x75, 0x6c, 0x65, 0x73,
	0x2a, 0x30, 0x0a, 0x0c, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x63, 0x74, 0x69, 0x6f, 0x6e,
	0x12, 0x09, 0x0a, 0x05, 0x41, 0x4c, 0x4c, 0x4f, 0x57, 0x10, 0x00, 0x12, 0x08, 0x0a, 0x04, 0x44,
	0x45, 0x4e, 0x59, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x43, 0x4f, 0x4e, 0x56, 0x45, 0x52, 0x54,
	0x10, 0x02, 0x2a, 0x31, 0x0a, 0x09, 0x41, 0x74, 0x74, 0x72, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x12,
	0x09, 0x0a, 0x05, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10, 0x00, 0x12, 0x0c, 0x0a, 0x08, 0x4e, 0x4f,
	0x54, 0x45, 0x51, 0x55, 0x41, 0x4c, 0x10, 0x01, 0x12, 0x0b, 0x0a, 0x07, 0x4d, 0x41, 0x54, 0x43,
	0x48, 0x45, 0x53, 0x10, 0x02, 0x2a, 0x2f, 0x0a, 0x09, 0x4d, 0x61, 0x74, 0x63, 0x68, 0x54, 0x79,
	0x70, 0x65, 0x12, 0x0c, 0x0a, 0x08, 0x57, 0x49, 0x4c, 0x44, 0x43, 0x41, 0x52, 0x44, 0x10, 0x00,
	0x12, 0x09, 0x0a, 0x05, 0x45, 0x58, 0x41, 0x43, 0x54, 0x10, 0x01, 0x12, 0x09, 0x0a, 0x05, 0x52,
	0x45, 0x47, 0x45, 0x58, 0x10, 0x02, 0x42, 0x48, 0x5a, 0x46, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62,
	0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x6d, 0x6f, 0x62, 0x79, 0x2f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b,
	0x69, 0x74, 0x2f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x2f,
	0x70, 0x62, 0x3b, 0x6d, 0x6f, 0x62, 0x79, 0x5f, 0x62, 0x75, 0x69, 0x6c, 0x64, 0x6b, 0x69, 0x74,
	0x5f, 0x76, 0x31, 0x5f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x79,
	0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}

var (
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescOnce sync.Once
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData = file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc
)

func file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescGZIP() []byte {
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescOnce.Do(func() {
		file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData = protoimpl.X.CompressGZIP(file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData)
	})
	return file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDescData
}

var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes = []any{
	(PolicyAction)(0),      // 0: moby.buildkit.v1.sourcepolicy.PolicyAction
	(AttrMatch)(0),         // 1: moby.buildkit.v1.sourcepolicy.AttrMatch
	(MatchType)(0),         // 2: moby.buildkit.v1.sourcepolicy.MatchType
	(*Rule)(nil),           // 3: moby.buildkit.v1.sourcepolicy.Rule
	(*Update)(nil),         // 4: moby.buildkit.v1.sourcepolicy.Update
	(*Selector)(nil),       // 5: moby.buildkit.v1.sourcepolicy.Selector
	(*AttrConstraint)(nil), // 6: moby.buildkit.v1.sourcepolicy.AttrConstraint
	(*Policy)(nil),         // 7: moby.buildkit.v1.sourcepolicy.Policy
	nil,                    // 8: moby.buildkit.v1.sourcepolicy.Update.AttrsEntry
}
var file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs = []int32{
	0, // 0: moby.buildkit.v1.sourcepolicy.Rule.action:type_name -> moby.buildkit.v1.sourcepolicy.PolicyAction
	5, // 1: moby.buildkit.v1.sourcepolicy.Rule.selector:type_name -> moby.buildkit.v1.sourcepolicy.Selector
	4, // 2: moby.buildkit.v1.sourcepolicy.Rule.updates:type_name -> moby.buildkit.v1.sourcepolicy.Update
	8, // 3: moby.buildkit.v1.sourcepolicy.Update.attrs:type_name -> moby.buildkit.v1.sourcepolicy.Update.AttrsEntry
	2, // 4: moby.buildkit.v1.sourcepolicy.Selector.match_type:type_name -> moby.buildkit.v1.sourcepolicy.MatchType
	6, // 5: moby.buildkit.v1.sourcepolicy.Selector.constraints:type_name -> moby.buildkit.v1.sourcepolicy.AttrConstraint
	1, // 6: moby.buildkit.v1.sourcepolicy.AttrConstraint.condition:type_name -> moby.buildkit.v1.sourcepolicy.AttrMatch
	3, // 7: moby.buildkit.v1.sourcepolicy.Policy.rules:type_name -> moby.buildkit.v1.sourcepolicy.Rule
	8, // [8:8] is the sub-list for method output_type
	8, // [8:8] is the sub-list for method input_type
	8, // [8:8] is the sub-list for extension type_name
	8, // [8:8] is the sub-list for extension extendee
	0, // [0:8] is the sub-list for field type_name
}

func init() { file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_init() }
func file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_init() {
	if File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc,
			NumEnums:      3,
			NumMessages:   6,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes,
		DependencyIndexes: file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs,
		EnumInfos:         file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_enumTypes,
		MessageInfos:      file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_msgTypes,
	}.Build()
	File_github_com_moby_buildkit_sourcepolicy_pb_policy_proto = out.File
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_rawDesc = nil
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_goTypes = nil
	file_github_com_moby_buildkit_sourcepolicy_pb_policy_proto_depIdxs = nil
}