diff --git a/app/controlplane/api/gen/frontend/attestation/v1/crafting_state.ts b/app/controlplane/api/gen/frontend/attestation/v1/crafting_state.ts index af357bd63..c8de72c81 100644 --- a/app/controlplane/api/gen/frontend/attestation/v1/crafting_state.ts +++ b/app/controlplane/api/gen/frontend/attestation/v1/crafting_state.ts @@ -9,6 +9,7 @@ import { CraftingSchema_Runner_RunnerType, craftingSchema_Runner_RunnerTypeFromJSON, craftingSchema_Runner_RunnerTypeToJSON, + PolicyAttachment, } from "../../workflowcontract/v1/crafting_schema"; export const protobufPackage = "attestation.v1"; @@ -26,6 +27,8 @@ export interface Attestation { runnerType: CraftingSchema_Runner_RunnerType; /** Head Commit of the environment where the attestation was executed (optional) */ head?: Commit; + /** Policies that this attestation was validated against */ + policies: Policy[]; } export interface Attestation_MaterialsEntry { @@ -97,6 +100,23 @@ export interface Attestation_EnvVarsEntry { value: string; } +/** A policy executed against an attestation */ +export interface Policy { + /** The policy name from the policy spec */ + name: string; + /** The attachment as in the contract, with arguments and any other metadata */ + attachment?: PolicyAttachment; + /** The policy script body (rego) */ + body: string; + /** The policy violations, if any */ + violations: Policy_Violation[]; +} + +export interface Policy_Violation { + subject: string; + message: string; +} + export interface Commit { hash: string; authorEmail: string; @@ -141,6 +161,7 @@ function createBaseAttestation(): Attestation { runnerUrl: "", runnerType: 0, head: undefined, + policies: [], }; } @@ -173,6 +194,9 @@ export const Attestation = { if (message.head !== undefined) { Commit.encode(message.head, writer.uint32(74).fork()).ldelim(); } + for (const v of message.policies) { + Policy.encode(v!, writer.uint32(82).fork()).ldelim(); + } return writer; }, @@ -255,6 +279,13 @@ export const Attestation = { message.head = Commit.decode(reader, reader.uint32()); continue; + case 10: + if (tag !== 82) { + break; + } + + message.policies.push(Policy.decode(reader, reader.uint32())); + continue; } if ((tag & 7) === 4 || tag === 0) { break; @@ -290,6 +321,7 @@ export const Attestation = { runnerUrl: isSet(object.runnerUrl) ? String(object.runnerUrl) : "", runnerType: isSet(object.runnerType) ? craftingSchema_Runner_RunnerTypeFromJSON(object.runnerType) : 0, head: isSet(object.head) ? Commit.fromJSON(object.head) : undefined, + policies: Array.isArray(object?.policies) ? object.policies.map((e: any) => Policy.fromJSON(e)) : [], }; }, @@ -320,6 +352,11 @@ export const Attestation = { message.runnerUrl !== undefined && (obj.runnerUrl = message.runnerUrl); message.runnerType !== undefined && (obj.runnerType = craftingSchema_Runner_RunnerTypeToJSON(message.runnerType)); message.head !== undefined && (obj.head = message.head ? Commit.toJSON(message.head) : undefined); + if (message.policies) { + obj.policies = message.policies.map((e) => e ? Policy.toJSON(e) : undefined); + } else { + obj.policies = []; + } return obj; }, @@ -361,6 +398,7 @@ export const Attestation = { message.runnerUrl = object.runnerUrl ?? ""; message.runnerType = object.runnerType ?? 0; message.head = (object.head !== undefined && object.head !== null) ? Commit.fromPartial(object.head) : undefined; + message.policies = object.policies?.map((e) => Policy.fromPartial(e)) || []; return message; }, }; @@ -1133,6 +1171,183 @@ export const Attestation_EnvVarsEntry = { }, }; +function createBasePolicy(): Policy { + return { name: "", attachment: undefined, body: "", violations: [] }; +} + +export const Policy = { + encode(message: Policy, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { + if (message.name !== "") { + writer.uint32(10).string(message.name); + } + if (message.attachment !== undefined) { + PolicyAttachment.encode(message.attachment, writer.uint32(18).fork()).ldelim(); + } + if (message.body !== "") { + writer.uint32(26).string(message.body); + } + for (const v of message.violations) { + Policy_Violation.encode(v!, writer.uint32(34).fork()).ldelim(); + } + return writer; + }, + + decode(input: _m0.Reader | Uint8Array, length?: number): Policy { + const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); + let end = length === undefined ? reader.len : reader.pos + length; + const message = createBasePolicy(); + while (reader.pos < end) { + const tag = reader.uint32(); + switch (tag >>> 3) { + case 1: + if (tag !== 10) { + break; + } + + message.name = reader.string(); + continue; + case 2: + if (tag !== 18) { + break; + } + + message.attachment = PolicyAttachment.decode(reader, reader.uint32()); + continue; + case 3: + if (tag !== 26) { + break; + } + + message.body = reader.string(); + continue; + case 4: + if (tag !== 34) { + break; + } + + message.violations.push(Policy_Violation.decode(reader, reader.uint32())); + continue; + } + if ((tag & 7) === 4 || tag === 0) { + break; + } + reader.skipType(tag & 7); + } + return message; + }, + + fromJSON(object: any): Policy { + return { + name: isSet(object.name) ? String(object.name) : "", + attachment: isSet(object.attachment) ? PolicyAttachment.fromJSON(object.attachment) : undefined, + body: isSet(object.body) ? String(object.body) : "", + violations: Array.isArray(object?.violations) + ? object.violations.map((e: any) => Policy_Violation.fromJSON(e)) + : [], + }; + }, + + toJSON(message: Policy): unknown { + const obj: any = {}; + message.name !== undefined && (obj.name = message.name); + message.attachment !== undefined && + (obj.attachment = message.attachment ? PolicyAttachment.toJSON(message.attachment) : undefined); + message.body !== undefined && (obj.body = message.body); + if (message.violations) { + obj.violations = message.violations.map((e) => e ? Policy_Violation.toJSON(e) : undefined); + } else { + obj.violations = []; + } + return obj; + }, + + create, I>>(base?: I): Policy { + return Policy.fromPartial(base ?? {}); + }, + + fromPartial, I>>(object: I): Policy { + const message = createBasePolicy(); + message.name = object.name ?? ""; + message.attachment = (object.attachment !== undefined && object.attachment !== null) + ? PolicyAttachment.fromPartial(object.attachment) + : undefined; + message.body = object.body ?? ""; + message.violations = object.violations?.map((e) => Policy_Violation.fromPartial(e)) || []; + return message; + }, +}; + +function createBasePolicy_Violation(): Policy_Violation { + return { subject: "", message: "" }; +} + +export const Policy_Violation = { + encode(message: Policy_Violation, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer { + if (message.subject !== "") { + writer.uint32(10).string(message.subject); + } + if (message.message !== "") { + writer.uint32(18).string(message.message); + } + return writer; + }, + + decode(input: _m0.Reader | Uint8Array, length?: number): Policy_Violation { + const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input); + let end = length === undefined ? reader.len : reader.pos + length; + const message = createBasePolicy_Violation(); + while (reader.pos < end) { + const tag = reader.uint32(); + switch (tag >>> 3) { + case 1: + if (tag !== 10) { + break; + } + + message.subject = reader.string(); + continue; + case 2: + if (tag !== 18) { + break; + } + + message.message = reader.string(); + continue; + } + if ((tag & 7) === 4 || tag === 0) { + break; + } + reader.skipType(tag & 7); + } + return message; + }, + + fromJSON(object: any): Policy_Violation { + return { + subject: isSet(object.subject) ? String(object.subject) : "", + message: isSet(object.message) ? String(object.message) : "", + }; + }, + + toJSON(message: Policy_Violation): unknown { + const obj: any = {}; + message.subject !== undefined && (obj.subject = message.subject); + message.message !== undefined && (obj.message = message.message); + return obj; + }, + + create, I>>(base?: I): Policy_Violation { + return Policy_Violation.fromPartial(base ?? {}); + }, + + fromPartial, I>>(object: I): Policy_Violation { + const message = createBasePolicy_Violation(); + message.subject = object.subject ?? ""; + message.message = object.message ?? ""; + return message; + }, +}; + function createBaseCommit(): Commit { return { hash: "", authorEmail: "", authorName: "", message: "", date: undefined, remotes: [] }; } diff --git a/internal/attestation/crafter/api/attestation/v1/crafting_state.pb.go b/internal/attestation/crafter/api/attestation/v1/crafting_state.pb.go index e0bbc9268..0b1f3a1f5 100644 --- a/internal/attestation/crafter/api/attestation/v1/crafting_state.pb.go +++ b/internal/attestation/crafter/api/attestation/v1/crafting_state.pb.go @@ -55,6 +55,8 @@ type Attestation struct { RunnerType v1.CraftingSchema_Runner_RunnerType `protobuf:"varint,8,opt,name=runner_type,json=runnerType,proto3,enum=workflowcontract.v1.CraftingSchema_Runner_RunnerType" json:"runner_type,omitempty"` // Head Commit of the environment where the attestation was executed (optional) Head *Commit `protobuf:"bytes,9,opt,name=head,proto3" json:"head,omitempty"` + // Policies that this attestation was validated against + Policies []*Policy `protobuf:"bytes,10,rep,name=policies,proto3" json:"policies,omitempty"` } func (x *Attestation) Reset() { @@ -152,6 +154,89 @@ func (x *Attestation) GetHead() *Commit { return nil } +func (x *Attestation) GetPolicies() []*Policy { + if x != nil { + return x.Policies + } + return nil +} + +// A policy executed against an attestation +type Policy struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The policy name from the policy spec + Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` + // The attachment as in the contract, with arguments and any other metadata + Attachment *v1.PolicyAttachment `protobuf:"bytes,2,opt,name=attachment,proto3" json:"attachment,omitempty"` + // The policy script body (rego) + Body string `protobuf:"bytes,3,opt,name=body,proto3" json:"body,omitempty"` + // The policy violations, if any + Violations []*Policy_Violation `protobuf:"bytes,4,rep,name=violations,proto3" json:"violations,omitempty"` +} + +func (x *Policy) Reset() { + *x = Policy{} + if protoimpl.UnsafeEnabled { + mi := &file_attestation_v1_crafting_state_proto_msgTypes[1] + 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_attestation_v1_crafting_state_proto_msgTypes[1] + if protoimpl.UnsafeEnabled && 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_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{1} +} + +func (x *Policy) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +func (x *Policy) GetAttachment() *v1.PolicyAttachment { + if x != nil { + return x.Attachment + } + return nil +} + +func (x *Policy) GetBody() string { + if x != nil { + return x.Body + } + return "" +} + +func (x *Policy) GetViolations() []*Policy_Violation { + if x != nil { + return x.Violations + } + return nil +} + type Commit struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -168,7 +253,7 @@ type Commit struct { func (x *Commit) Reset() { *x = Commit{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[1] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[2] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -181,7 +266,7 @@ func (x *Commit) String() string { func (*Commit) ProtoMessage() {} func (x *Commit) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[1] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[2] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -194,7 +279,7 @@ func (x *Commit) ProtoReflect() protoreflect.Message { // Deprecated: Use Commit.ProtoReflect.Descriptor instead. func (*Commit) Descriptor() ([]byte, []int) { - return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{1} + return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{2} } func (x *Commit) GetHash() string { @@ -253,7 +338,7 @@ type CraftingState struct { func (x *CraftingState) Reset() { *x = CraftingState{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[2] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[3] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -266,7 +351,7 @@ func (x *CraftingState) String() string { func (*CraftingState) ProtoMessage() {} func (x *CraftingState) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[2] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[3] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -279,7 +364,7 @@ func (x *CraftingState) ProtoReflect() protoreflect.Message { // Deprecated: Use CraftingState.ProtoReflect.Descriptor instead. func (*CraftingState) Descriptor() ([]byte, []int) { - return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{2} + return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{3} } func (x *CraftingState) GetInputSchema() *v1.CraftingSchema { @@ -321,7 +406,7 @@ type WorkflowMetadata struct { func (x *WorkflowMetadata) Reset() { *x = WorkflowMetadata{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[3] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[4] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -334,7 +419,7 @@ func (x *WorkflowMetadata) String() string { func (*WorkflowMetadata) ProtoMessage() {} func (x *WorkflowMetadata) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[3] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[4] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -347,7 +432,7 @@ func (x *WorkflowMetadata) ProtoReflect() protoreflect.Message { // Deprecated: Use WorkflowMetadata.ProtoReflect.Descriptor instead. func (*WorkflowMetadata) Descriptor() ([]byte, []int) { - return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{3} + return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{4} } func (x *WorkflowMetadata) GetName() string { @@ -424,7 +509,7 @@ type Attestation_Material struct { func (x *Attestation_Material) Reset() { *x = Attestation_Material{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[6] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[7] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -437,7 +522,7 @@ func (x *Attestation_Material) String() string { func (*Attestation_Material) ProtoMessage() {} func (x *Attestation_Material) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[6] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[7] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -550,7 +635,7 @@ type Attestation_Material_KeyVal struct { func (x *Attestation_Material_KeyVal) Reset() { *x = Attestation_Material_KeyVal{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[9] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -563,7 +648,7 @@ func (x *Attestation_Material_KeyVal) String() string { func (*Attestation_Material_KeyVal) ProtoMessage() {} func (x *Attestation_Material_KeyVal) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[9] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -609,7 +694,7 @@ type Attestation_Material_ContainerImage struct { func (x *Attestation_Material_ContainerImage) Reset() { *x = Attestation_Material_ContainerImage{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[10] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -622,7 +707,7 @@ func (x *Attestation_Material_ContainerImage) String() string { func (*Attestation_Material_ContainerImage) ProtoMessage() {} func (x *Attestation_Material_ContainerImage) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[10] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -694,7 +779,7 @@ type Attestation_Material_Artifact struct { func (x *Attestation_Material_Artifact) Reset() { *x = Attestation_Material_Artifact{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[11] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -707,7 +792,7 @@ func (x *Attestation_Material_Artifact) String() string { func (*Attestation_Material_Artifact) ProtoMessage() {} func (x *Attestation_Material_Artifact) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[11] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -758,6 +843,61 @@ func (x *Attestation_Material_Artifact) GetContent() []byte { return nil } +type Policy_Violation struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Subject string `protobuf:"bytes,1,opt,name=subject,proto3" json:"subject,omitempty"` + Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` +} + +func (x *Policy_Violation) Reset() { + *x = Policy_Violation{} + if protoimpl.UnsafeEnabled { + mi := &file_attestation_v1_crafting_state_proto_msgTypes[13] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *Policy_Violation) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*Policy_Violation) ProtoMessage() {} + +func (x *Policy_Violation) ProtoReflect() protoreflect.Message { + mi := &file_attestation_v1_crafting_state_proto_msgTypes[13] + if protoimpl.UnsafeEnabled && 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_Violation.ProtoReflect.Descriptor instead. +func (*Policy_Violation) Descriptor() ([]byte, []int) { + return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{1, 0} +} + +func (x *Policy_Violation) GetSubject() string { + if x != nil { + return x.Subject + } + return "" +} + +func (x *Policy_Violation) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + type Commit_Remote struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -770,7 +910,7 @@ type Commit_Remote struct { func (x *Commit_Remote) Reset() { *x = Commit_Remote{} if protoimpl.UnsafeEnabled { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[12] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -783,7 +923,7 @@ func (x *Commit_Remote) String() string { func (*Commit_Remote) ProtoMessage() {} func (x *Commit_Remote) ProtoReflect() protoreflect.Message { - mi := &file_attestation_v1_crafting_state_proto_msgTypes[12] + mi := &file_attestation_v1_crafting_state_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -796,7 +936,7 @@ func (x *Commit_Remote) ProtoReflect() protoreflect.Message { // Deprecated: Use Commit_Remote.ProtoReflect.Descriptor instead. func (*Commit_Remote) Descriptor() ([]byte, []int) { - return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{1, 0} + return file_attestation_v1_crafting_state_proto_rawDescGZIP(), []int{2, 0} } func (x *Commit_Remote) GetName() string { @@ -825,8 +965,8 @@ var file_attestation_v1_crafting_state_proto_rawDesc = []byte{ 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x29, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x63, 0x72, 0x61, 0x66, 0x74, 0x69, 0x6e, - 0x67, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xd0, - 0x0e, 0x0a, 0x0b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, + 0x67, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x84, + 0x0f, 0x0a, 0x0b, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x49, 0x0a, 0x0e, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x6c, 0x69, 0x7a, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, @@ -864,140 +1004,170 @@ var file_attestation_v1_crafting_state_proto_rawDesc = []byte{ 0x54, 0x79, 0x70, 0x65, 0x52, 0x0a, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x54, 0x79, 0x70, 0x65, 0x12, 0x2a, 0x0a, 0x04, 0x68, 0x65, 0x61, 0x64, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, - 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x04, 0x68, 0x65, 0x61, 0x64, 0x1a, 0x62, 0x0a, 0x0e, - 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x12, 0x10, + 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x52, 0x04, 0x68, 0x65, 0x61, 0x64, 0x12, 0x32, 0x0a, 0x08, + 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x69, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x16, + 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, + 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x52, 0x08, 0x70, 0x6f, 0x6c, 0x69, 0x63, 0x69, 0x65, 0x73, + 0x1a, 0x62, 0x0a, 0x0e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 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, 0x3a, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, + 0x3a, 0x02, 0x38, 0x01, 0x1a, 0x3e, 0x0a, 0x10, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 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, 0x1a, 0x82, 0x08, 0x0a, 0x08, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, + 0x6c, 0x12, 0x45, 0x0a, 0x06, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x2b, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, + 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, + 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c, 0x48, 0x00, + 0x52, 0x06, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x12, 0x5e, 0x0a, 0x0f, 0x63, 0x6f, 0x6e, 0x74, + 0x61, 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x33, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, + 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, + 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, + 0x72, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x48, 0x00, 0x52, 0x0e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, + 0x6e, 0x65, 0x72, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x4b, 0x0a, 0x08, 0x61, 0x72, 0x74, 0x69, + 0x66, 0x61, 0x63, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x61, 0x74, 0x74, + 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, + 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, + 0x2e, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, 0x48, 0x00, 0x52, 0x08, 0x61, 0x72, 0x74, + 0x69, 0x66, 0x61, 0x63, 0x74, 0x12, 0x35, 0x0a, 0x08, 0x61, 0x64, 0x64, 0x65, 0x64, 0x5f, 0x61, + 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, + 0x61, 0x6d, 0x70, 0x52, 0x07, 0x61, 0x64, 0x64, 0x65, 0x64, 0x41, 0x74, 0x12, 0x5e, 0x0a, 0x0d, + 0x6d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x0e, 0x32, 0x39, 0x2e, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x63, 0x6f, + 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x61, 0x66, 0x74, 0x69, + 0x6e, 0x67, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, + 0x6c, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0c, + 0x6d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x0a, 0x0f, + 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x61, 0x73, 0x18, + 0x07, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x65, 0x64, 0x54, + 0x6f, 0x43, 0x61, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x5f, 0x63, + 0x61, 0x73, 0x18, 0x08, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, + 0x43, 0x61, 0x73, 0x12, 0x65, 0x0a, 0x0b, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x73, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x35, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, + 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x41, + 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x42, + 0x0c, 0xba, 0x48, 0x09, 0x9a, 0x01, 0x06, 0x2a, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0b, 0x61, + 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3e, 0x0a, 0x10, 0x41, 0x6e, + 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 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, 0x3a, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x24, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, - 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, - 0x65, 0x72, 0x69, 0x61, 0x6c, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, - 0x1a, 0x3e, 0x0a, 0x10, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 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, - 0x1a, 0x82, 0x08, 0x0a, 0x08, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x12, 0x45, 0x0a, - 0x06, 0x73, 0x74, 0x72, 0x69, 0x6e, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2b, 0x2e, - 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, - 0x69, 0x61, 0x6c, 0x2e, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c, 0x48, 0x00, 0x52, 0x06, 0x73, 0x74, - 0x72, 0x69, 0x6e, 0x67, 0x12, 0x5e, 0x0a, 0x0f, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, - 0x72, 0x5f, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x33, 0x2e, - 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, - 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, - 0x69, 0x61, 0x6c, 0x2e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x6d, 0x61, - 0x67, 0x65, 0x48, 0x00, 0x52, 0x0e, 0x63, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, - 0x6d, 0x61, 0x67, 0x65, 0x12, 0x4b, 0x0a, 0x08, 0x61, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2d, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x41, 0x72, 0x74, - 0x69, 0x66, 0x61, 0x63, 0x74, 0x48, 0x00, 0x52, 0x08, 0x61, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, - 0x74, 0x12, 0x35, 0x0a, 0x08, 0x61, 0x64, 0x64, 0x65, 0x64, 0x5f, 0x61, 0x74, 0x18, 0x05, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, - 0x07, 0x61, 0x64, 0x64, 0x65, 0x64, 0x41, 0x74, 0x12, 0x5e, 0x0a, 0x0d, 0x6d, 0x61, 0x74, 0x65, - 0x72, 0x69, 0x61, 0x6c, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0e, 0x32, - 0x39, 0x2e, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, - 0x63, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x61, 0x66, 0x74, 0x69, 0x6e, 0x67, 0x53, 0x63, - 0x68, 0x65, 0x6d, 0x61, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x4d, 0x61, - 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x52, 0x0c, 0x6d, 0x61, 0x74, 0x65, - 0x72, 0x69, 0x61, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x26, 0x0a, 0x0f, 0x75, 0x70, 0x6c, 0x6f, - 0x61, 0x64, 0x65, 0x64, 0x5f, 0x74, 0x6f, 0x5f, 0x63, 0x61, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x0d, 0x75, 0x70, 0x6c, 0x6f, 0x61, 0x64, 0x65, 0x64, 0x54, 0x6f, 0x43, 0x61, 0x73, - 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x5f, 0x63, 0x61, 0x73, 0x18, 0x08, - 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x65, 0x43, 0x61, 0x73, 0x12, - 0x65, 0x0a, 0x0b, 0x61, 0x6e, 0x6e, 0x6f, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x09, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x35, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x2e, 0x4d, 0x61, 0x74, 0x65, 0x72, 0x69, 0x61, 0x6c, 0x2e, 0x41, 0x6e, 0x6e, 0x6f, 0x74, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x42, 0x0c, 0xba, 0x48, 0x09, - 0x9a, 0x01, 0x06, 0x2a, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0b, 0x61, 0x6e, 0x6e, 0x6f, 0x74, - 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x3e, 0x0a, 0x10, 0x41, 0x6e, 0x6e, 0x6f, 0x74, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 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, 0x1a, 0x40, 0x0a, 0x06, 0x4b, 0x65, 0x79, 0x56, 0x61, 0x6c, - 0x12, 0x17, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, - 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1d, 0x0a, 0x05, 0x76, 0x61, 0x6c, - 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, - 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x98, 0x01, 0x0a, 0x0e, 0x43, 0x6f, 0x6e, - 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x12, 0x17, 0x0a, 0x02, 0x69, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, - 0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x12, 0x1f, 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x06, 0x64, 0x69, 0x67, 0x65, - 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x73, 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x53, 0x75, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x61, 0x67, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, - 0x74, 0x61, 0x67, 0x1a, 0x9a, 0x01, 0x0a, 0x08, 0x41, 0x72, 0x74, 0x69, 0x66, 0x61, 0x63, 0x74, - 0x12, 0x17, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, - 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, - 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, - 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x73, 0x75, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x53, - 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, - 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x6e, 0x74, - 0x42, 0x03, 0x0a, 0x01, 0x6d, 0x1a, 0x3a, 0x0a, 0x0c, 0x45, 0x6e, 0x76, 0x56, 0x61, 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, 0xc9, 0x02, 0x0a, 0x06, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x12, 0x1b, 0x0a, 0x04, - 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, - 0x02, 0x10, 0x01, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x2a, 0x0a, 0x0c, 0x61, 0x75, 0x74, - 0x68, 0x6f, 0x72, 0x5f, 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, - 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0b, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, - 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x12, 0x28, 0x0a, 0x0b, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, - 0x02, 0x10, 0x01, 0x52, 0x0a, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, - 0x21, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, - 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, - 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x04, 0x64, 0x61, - 0x74, 0x65, 0x12, 0x37, 0x0a, 0x07, 0x72, 0x65, 0x6d, 0x6f, 0x74, 0x65, 0x73, 0x18, 0x06, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, 0x69, 0x74, 0x2e, 0x52, 0x65, 0x6d, 0x6f, - 0x74, 0x65, 0x52, 0x07, 0x72, 0x65, 0x6d, 0x6f, 0x74, 0x65, 0x73, 0x1a, 0x40, 0x0a, 0x06, 0x52, - 0x65, 0x6d, 0x6f, 0x74, 0x65, 0x12, 0x1b, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, - 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x03, 0x75, 0x72, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, - 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x03, 0x75, 0x72, 0x6c, 0x22, 0xaf, 0x01, - 0x0a, 0x0d, 0x43, 0x72, 0x61, 0x66, 0x74, 0x69, 0x6e, 0x67, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, - 0x46, 0x0a, 0x0c, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x5f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, - 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x61, 0x66, - 0x74, 0x69, 0x6e, 0x67, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x0b, 0x69, 0x6e, 0x70, 0x75, - 0x74, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x3d, 0x0a, 0x0b, 0x61, 0x74, 0x74, 0x65, 0x73, - 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x61, - 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, - 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0b, 0x61, 0x74, 0x74, 0x65, 0x73, - 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x17, 0x0a, 0x07, 0x64, 0x72, 0x79, 0x5f, 0x72, 0x75, - 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, 0x64, 0x72, 0x79, 0x52, 0x75, 0x6e, 0x22, - 0x8e, 0x02, 0x0a, 0x10, 0x57, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x4d, 0x65, 0x74, 0x61, - 0x64, 0x61, 0x74, 0x61, 0x12, 0x1b, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, 0x6d, - 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x74, - 0x65, 0x61, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x12, - 0x28, 0x0a, 0x0b, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x5f, 0x69, 0x64, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0a, 0x77, - 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x49, 0x64, 0x12, 0x26, 0x0a, 0x0f, 0x77, 0x6f, 0x72, - 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x5f, 0x72, 0x75, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0d, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x52, 0x75, 0x6e, 0x49, - 0x64, 0x12, 0x30, 0x0a, 0x0f, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x5f, 0x72, 0x65, 0x76, 0x69, - 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, - 0x02, 0x10, 0x01, 0x52, 0x0e, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x52, 0x65, 0x76, 0x69, 0x73, - 0x69, 0x6f, 0x6e, 0x12, 0x2b, 0x0a, 0x0c, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x7a, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, - 0x10, 0x01, 0x52, 0x0c, 0x6f, 0x72, 0x67, 0x61, 0x6e, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x42, 0x54, 0x5a, 0x52, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, - 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x6f, 0x6f, 0x70, 0x2d, 0x64, 0x65, 0x76, 0x2f, 0x63, 0x68, 0x61, - 0x69, 0x6e, 0x6c, 0x6f, 0x6f, 0x70, 0x2f, 0x69, 0x6e, 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, - 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x63, 0x72, 0x61, 0x66, - 0x74, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 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, 0x1a, 0x40, 0x0a, 0x06, 0x4b, 0x65, + 0x79, 0x56, 0x61, 0x6c, 0x12, 0x17, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1d, 0x0a, + 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, + 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x1a, 0x98, 0x01, 0x0a, + 0x0e, 0x43, 0x6f, 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x65, 0x72, 0x49, 0x6d, 0x61, 0x67, 0x65, 0x12, + 0x17, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, + 0x72, 0x02, 0x10, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x06, + 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x73, 0x75, 0x62, + 0x6a, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x53, 0x75, + 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x61, 0x67, 0x18, 0x05, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x03, 0x74, 0x61, 0x67, 0x1a, 0x9a, 0x01, 0x0a, 0x08, 0x41, 0x72, 0x74, 0x69, + 0x66, 0x61, 0x63, 0x74, 0x12, 0x17, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1b, 0x0a, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, + 0x72, 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x06, 0x64, 0x69, + 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, + 0x02, 0x10, 0x01, 0x52, 0x06, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x69, + 0x73, 0x5f, 0x73, 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x09, 0x69, 0x73, 0x53, 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x18, 0x0a, 0x07, 0x63, 0x6f, + 0x6e, 0x74, 0x65, 0x6e, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x63, 0x6f, 0x6e, + 0x74, 0x65, 0x6e, 0x74, 0x42, 0x03, 0x0a, 0x01, 0x6d, 0x1a, 0x3a, 0x0a, 0x0c, 0x45, 0x6e, 0x76, + 0x56, 0x61, 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, 0xa0, 0x03, 0x0a, 0x06, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, + 0x12, 0x97, 0x01, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, + 0x82, 0x01, 0xba, 0x48, 0x7f, 0xba, 0x01, 0x7c, 0x0a, 0x0d, 0x6e, 0x61, 0x6d, 0x65, 0x2e, 0x64, + 0x6e, 0x73, 0x2d, 0x31, 0x31, 0x32, 0x33, 0x12, 0x3a, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x63, 0x6f, + 0x6e, 0x74, 0x61, 0x69, 0x6e, 0x20, 0x6f, 0x6e, 0x6c, 0x79, 0x20, 0x6c, 0x6f, 0x77, 0x65, 0x72, + 0x63, 0x61, 0x73, 0x65, 0x20, 0x6c, 0x65, 0x74, 0x74, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x6e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x73, 0x2c, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x68, 0x79, 0x70, 0x68, 0x65, + 0x6e, 0x73, 0x2e, 0x1a, 0x2f, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x6d, 0x61, 0x74, 0x63, 0x68, 0x65, + 0x73, 0x28, 0x27, 0x5e, 0x5b, 0x61, 0x2d, 0x7a, 0x30, 0x2d, 0x39, 0x5d, 0x28, 0x5b, 0x2d, 0x61, + 0x2d, 0x7a, 0x30, 0x2d, 0x39, 0x5d, 0x2a, 0x5b, 0x61, 0x2d, 0x7a, 0x30, 0x2d, 0x39, 0x5d, 0x29, + 0x3f, 0x24, 0x27, 0x29, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x4d, 0x0a, 0x0a, 0x61, 0x74, + 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, + 0x2e, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, + 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x6f, 0x6c, 0x69, 0x63, 0x79, 0x41, 0x74, 0x74, 0x61, 0x63, + 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x0a, 0x61, + 0x74, 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x1a, 0x0a, 0x04, 0x62, 0x6f, 0x64, + 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, + 0x04, 0x62, 0x6f, 0x64, 0x79, 0x12, 0x40, 0x0a, 0x0a, 0x76, 0x69, 0x6f, 0x6c, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x61, 0x74, 0x74, 0x65, + 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x6f, 0x6c, 0x69, 0x63, + 0x79, 0x2e, 0x56, 0x69, 0x6f, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x0a, 0x76, 0x69, 0x6f, + 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x4f, 0x0a, 0x09, 0x56, 0x69, 0x6f, 0x6c, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x20, 0x0a, 0x07, 0x73, 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x07, 0x73, + 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x20, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, + 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x22, 0xc9, 0x02, 0x0a, 0x06, 0x43, 0x6f, 0x6d, + 0x6d, 0x69, 0x74, 0x12, 0x1b, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, + 0x12, 0x2a, 0x0a, 0x0c, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x5f, 0x65, 0x6d, 0x61, 0x69, 0x6c, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, + 0x0b, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x12, 0x28, 0x0a, 0x0b, + 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0a, 0x61, 0x75, 0x74, 0x68, + 0x6f, 0x72, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, + 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, + 0x52, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x04, 0x64, 0x61, 0x74, + 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, + 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, + 0x61, 0x6d, 0x70, 0x52, 0x04, 0x64, 0x61, 0x74, 0x65, 0x12, 0x37, 0x0a, 0x07, 0x72, 0x65, 0x6d, + 0x6f, 0x74, 0x65, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x61, 0x74, 0x74, + 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x6f, 0x6d, 0x6d, + 0x69, 0x74, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x74, 0x65, 0x52, 0x07, 0x72, 0x65, 0x6d, 0x6f, 0x74, + 0x65, 0x73, 0x1a, 0x40, 0x0a, 0x06, 0x52, 0x65, 0x6d, 0x6f, 0x74, 0x65, 0x12, 0x1b, 0x0a, 0x04, + 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, + 0x02, 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x03, 0x75, 0x72, 0x6c, + 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, + 0x03, 0x75, 0x72, 0x6c, 0x22, 0xaf, 0x01, 0x0a, 0x0d, 0x43, 0x72, 0x61, 0x66, 0x74, 0x69, 0x6e, + 0x67, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x46, 0x0a, 0x0c, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x5f, + 0x73, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x77, + 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x2e, + 0x76, 0x31, 0x2e, 0x43, 0x72, 0x61, 0x66, 0x74, 0x69, 0x6e, 0x67, 0x53, 0x63, 0x68, 0x65, 0x6d, + 0x61, 0x52, 0x0b, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x53, 0x63, 0x68, 0x65, 0x6d, 0x61, 0x12, 0x3d, + 0x0a, 0x0b, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, + 0x52, 0x0b, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x17, 0x0a, + 0x07, 0x64, 0x72, 0x79, 0x5f, 0x72, 0x75, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x06, + 0x64, 0x72, 0x79, 0x52, 0x75, 0x6e, 0x22, 0x8e, 0x02, 0x0a, 0x10, 0x57, 0x6f, 0x72, 0x6b, 0x66, + 0x6c, 0x6f, 0x77, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x1b, 0x0a, 0x04, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, + 0x10, 0x01, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, + 0x65, 0x63, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, + 0x63, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x74, 0x65, 0x61, 0x6d, 0x12, 0x28, 0x0a, 0x0b, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, + 0x6f, 0x77, 0x5f, 0x69, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, + 0x72, 0x02, 0x10, 0x01, 0x52, 0x0a, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x49, 0x64, + 0x12, 0x26, 0x0a, 0x0f, 0x77, 0x6f, 0x72, 0x6b, 0x66, 0x6c, 0x6f, 0x77, 0x5f, 0x72, 0x75, 0x6e, + 0x5f, 0x69, 0x64, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x77, 0x6f, 0x72, 0x6b, 0x66, + 0x6c, 0x6f, 0x77, 0x52, 0x75, 0x6e, 0x49, 0x64, 0x12, 0x30, 0x0a, 0x0f, 0x73, 0x63, 0x68, 0x65, + 0x6d, 0x61, 0x5f, 0x72, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x07, 0x20, 0x01, 0x28, + 0x09, 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0e, 0x73, 0x63, 0x68, 0x65, + 0x6d, 0x61, 0x52, 0x65, 0x76, 0x69, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x2b, 0x0a, 0x0c, 0x6f, 0x72, + 0x67, 0x61, 0x6e, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, + 0x42, 0x07, 0xba, 0x48, 0x04, 0x72, 0x02, 0x10, 0x01, 0x52, 0x0c, 0x6f, 0x72, 0x67, 0x61, 0x6e, + 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x42, 0x54, 0x5a, 0x52, 0x67, 0x69, 0x74, 0x68, 0x75, + 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x6f, 0x6f, 0x70, 0x2d, + 0x64, 0x65, 0x76, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x6f, 0x6f, 0x70, 0x2f, 0x69, 0x6e, + 0x74, 0x65, 0x72, 0x6e, 0x61, 0x6c, 0x2f, 0x61, 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x2f, 0x63, 0x72, 0x61, 0x66, 0x74, 0x65, 0x72, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x61, + 0x74, 0x74, 0x65, 0x73, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1012,51 +1182,57 @@ func file_attestation_v1_crafting_state_proto_rawDescGZIP() []byte { return file_attestation_v1_crafting_state_proto_rawDescData } -var file_attestation_v1_crafting_state_proto_msgTypes = make([]protoimpl.MessageInfo, 13) +var file_attestation_v1_crafting_state_proto_msgTypes = make([]protoimpl.MessageInfo, 15) var file_attestation_v1_crafting_state_proto_goTypes = []interface{}{ (*Attestation)(nil), // 0: attestation.v1.Attestation - (*Commit)(nil), // 1: attestation.v1.Commit - (*CraftingState)(nil), // 2: attestation.v1.CraftingState - (*WorkflowMetadata)(nil), // 3: attestation.v1.WorkflowMetadata - nil, // 4: attestation.v1.Attestation.MaterialsEntry - nil, // 5: attestation.v1.Attestation.AnnotationsEntry - (*Attestation_Material)(nil), // 6: attestation.v1.Attestation.Material - nil, // 7: attestation.v1.Attestation.EnvVarsEntry - nil, // 8: attestation.v1.Attestation.Material.AnnotationsEntry - (*Attestation_Material_KeyVal)(nil), // 9: attestation.v1.Attestation.Material.KeyVal - (*Attestation_Material_ContainerImage)(nil), // 10: attestation.v1.Attestation.Material.ContainerImage - (*Attestation_Material_Artifact)(nil), // 11: attestation.v1.Attestation.Material.Artifact - (*Commit_Remote)(nil), // 12: attestation.v1.Commit.Remote - (*timestamppb.Timestamp)(nil), // 13: google.protobuf.Timestamp - (v1.CraftingSchema_Runner_RunnerType)(0), // 14: workflowcontract.v1.CraftingSchema.Runner.RunnerType - (*v1.CraftingSchema)(nil), // 15: workflowcontract.v1.CraftingSchema - (v1.CraftingSchema_Material_MaterialType)(0), // 16: workflowcontract.v1.CraftingSchema.Material.MaterialType + (*Policy)(nil), // 1: attestation.v1.Policy + (*Commit)(nil), // 2: attestation.v1.Commit + (*CraftingState)(nil), // 3: attestation.v1.CraftingState + (*WorkflowMetadata)(nil), // 4: attestation.v1.WorkflowMetadata + nil, // 5: attestation.v1.Attestation.MaterialsEntry + nil, // 6: attestation.v1.Attestation.AnnotationsEntry + (*Attestation_Material)(nil), // 7: attestation.v1.Attestation.Material + nil, // 8: attestation.v1.Attestation.EnvVarsEntry + nil, // 9: attestation.v1.Attestation.Material.AnnotationsEntry + (*Attestation_Material_KeyVal)(nil), // 10: attestation.v1.Attestation.Material.KeyVal + (*Attestation_Material_ContainerImage)(nil), // 11: attestation.v1.Attestation.Material.ContainerImage + (*Attestation_Material_Artifact)(nil), // 12: attestation.v1.Attestation.Material.Artifact + (*Policy_Violation)(nil), // 13: attestation.v1.Policy.Violation + (*Commit_Remote)(nil), // 14: attestation.v1.Commit.Remote + (*timestamppb.Timestamp)(nil), // 15: google.protobuf.Timestamp + (v1.CraftingSchema_Runner_RunnerType)(0), // 16: workflowcontract.v1.CraftingSchema.Runner.RunnerType + (*v1.PolicyAttachment)(nil), // 17: workflowcontract.v1.PolicyAttachment + (*v1.CraftingSchema)(nil), // 18: workflowcontract.v1.CraftingSchema + (v1.CraftingSchema_Material_MaterialType)(0), // 19: workflowcontract.v1.CraftingSchema.Material.MaterialType } var file_attestation_v1_crafting_state_proto_depIdxs = []int32{ - 13, // 0: attestation.v1.Attestation.initialized_at:type_name -> google.protobuf.Timestamp - 13, // 1: attestation.v1.Attestation.finished_at:type_name -> google.protobuf.Timestamp - 3, // 2: attestation.v1.Attestation.workflow:type_name -> attestation.v1.WorkflowMetadata - 4, // 3: attestation.v1.Attestation.materials:type_name -> attestation.v1.Attestation.MaterialsEntry - 5, // 4: attestation.v1.Attestation.annotations:type_name -> attestation.v1.Attestation.AnnotationsEntry - 7, // 5: attestation.v1.Attestation.env_vars:type_name -> attestation.v1.Attestation.EnvVarsEntry - 14, // 6: attestation.v1.Attestation.runner_type:type_name -> workflowcontract.v1.CraftingSchema.Runner.RunnerType - 1, // 7: attestation.v1.Attestation.head:type_name -> attestation.v1.Commit - 13, // 8: attestation.v1.Commit.date:type_name -> google.protobuf.Timestamp - 12, // 9: attestation.v1.Commit.remotes:type_name -> attestation.v1.Commit.Remote - 15, // 10: attestation.v1.CraftingState.input_schema:type_name -> workflowcontract.v1.CraftingSchema - 0, // 11: attestation.v1.CraftingState.attestation:type_name -> attestation.v1.Attestation - 6, // 12: attestation.v1.Attestation.MaterialsEntry.value:type_name -> attestation.v1.Attestation.Material - 9, // 13: attestation.v1.Attestation.Material.string:type_name -> attestation.v1.Attestation.Material.KeyVal - 10, // 14: attestation.v1.Attestation.Material.container_image:type_name -> attestation.v1.Attestation.Material.ContainerImage - 11, // 15: attestation.v1.Attestation.Material.artifact:type_name -> attestation.v1.Attestation.Material.Artifact - 13, // 16: attestation.v1.Attestation.Material.added_at:type_name -> google.protobuf.Timestamp - 16, // 17: attestation.v1.Attestation.Material.material_type:type_name -> workflowcontract.v1.CraftingSchema.Material.MaterialType - 8, // 18: attestation.v1.Attestation.Material.annotations:type_name -> attestation.v1.Attestation.Material.AnnotationsEntry - 19, // [19:19] is the sub-list for method output_type - 19, // [19:19] is the sub-list for method input_type - 19, // [19:19] is the sub-list for extension type_name - 19, // [19:19] is the sub-list for extension extendee - 0, // [0:19] is the sub-list for field type_name + 15, // 0: attestation.v1.Attestation.initialized_at:type_name -> google.protobuf.Timestamp + 15, // 1: attestation.v1.Attestation.finished_at:type_name -> google.protobuf.Timestamp + 4, // 2: attestation.v1.Attestation.workflow:type_name -> attestation.v1.WorkflowMetadata + 5, // 3: attestation.v1.Attestation.materials:type_name -> attestation.v1.Attestation.MaterialsEntry + 6, // 4: attestation.v1.Attestation.annotations:type_name -> attestation.v1.Attestation.AnnotationsEntry + 8, // 5: attestation.v1.Attestation.env_vars:type_name -> attestation.v1.Attestation.EnvVarsEntry + 16, // 6: attestation.v1.Attestation.runner_type:type_name -> workflowcontract.v1.CraftingSchema.Runner.RunnerType + 2, // 7: attestation.v1.Attestation.head:type_name -> attestation.v1.Commit + 1, // 8: attestation.v1.Attestation.policies:type_name -> attestation.v1.Policy + 17, // 9: attestation.v1.Policy.attachment:type_name -> workflowcontract.v1.PolicyAttachment + 13, // 10: attestation.v1.Policy.violations:type_name -> attestation.v1.Policy.Violation + 15, // 11: attestation.v1.Commit.date:type_name -> google.protobuf.Timestamp + 14, // 12: attestation.v1.Commit.remotes:type_name -> attestation.v1.Commit.Remote + 18, // 13: attestation.v1.CraftingState.input_schema:type_name -> workflowcontract.v1.CraftingSchema + 0, // 14: attestation.v1.CraftingState.attestation:type_name -> attestation.v1.Attestation + 7, // 15: attestation.v1.Attestation.MaterialsEntry.value:type_name -> attestation.v1.Attestation.Material + 10, // 16: attestation.v1.Attestation.Material.string:type_name -> attestation.v1.Attestation.Material.KeyVal + 11, // 17: attestation.v1.Attestation.Material.container_image:type_name -> attestation.v1.Attestation.Material.ContainerImage + 12, // 18: attestation.v1.Attestation.Material.artifact:type_name -> attestation.v1.Attestation.Material.Artifact + 15, // 19: attestation.v1.Attestation.Material.added_at:type_name -> google.protobuf.Timestamp + 19, // 20: attestation.v1.Attestation.Material.material_type:type_name -> workflowcontract.v1.CraftingSchema.Material.MaterialType + 9, // 21: attestation.v1.Attestation.Material.annotations:type_name -> attestation.v1.Attestation.Material.AnnotationsEntry + 22, // [22:22] is the sub-list for method output_type + 22, // [22:22] is the sub-list for method input_type + 22, // [22:22] is the sub-list for extension type_name + 22, // [22:22] is the sub-list for extension extendee + 0, // [0:22] is the sub-list for field type_name } func init() { file_attestation_v1_crafting_state_proto_init() } @@ -1078,7 +1254,7 @@ func file_attestation_v1_crafting_state_proto_init() { } } file_attestation_v1_crafting_state_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Commit); i { + switch v := v.(*Policy); i { case 0: return &v.state case 1: @@ -1090,7 +1266,7 @@ func file_attestation_v1_crafting_state_proto_init() { } } file_attestation_v1_crafting_state_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CraftingState); i { + switch v := v.(*Commit); i { case 0: return &v.state case 1: @@ -1102,6 +1278,18 @@ func file_attestation_v1_crafting_state_proto_init() { } } file_attestation_v1_crafting_state_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*CraftingState); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_attestation_v1_crafting_state_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*WorkflowMetadata); i { case 0: return &v.state @@ -1113,7 +1301,7 @@ func file_attestation_v1_crafting_state_proto_init() { return nil } } - file_attestation_v1_crafting_state_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + file_attestation_v1_crafting_state_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Attestation_Material); i { case 0: return &v.state @@ -1125,7 +1313,7 @@ func file_attestation_v1_crafting_state_proto_init() { return nil } } - file_attestation_v1_crafting_state_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + file_attestation_v1_crafting_state_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Attestation_Material_KeyVal); i { case 0: return &v.state @@ -1137,7 +1325,7 @@ func file_attestation_v1_crafting_state_proto_init() { return nil } } - file_attestation_v1_crafting_state_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + file_attestation_v1_crafting_state_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Attestation_Material_ContainerImage); i { case 0: return &v.state @@ -1149,7 +1337,7 @@ func file_attestation_v1_crafting_state_proto_init() { return nil } } - file_attestation_v1_crafting_state_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + file_attestation_v1_crafting_state_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Attestation_Material_Artifact); i { case 0: return &v.state @@ -1161,7 +1349,19 @@ func file_attestation_v1_crafting_state_proto_init() { return nil } } - file_attestation_v1_crafting_state_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { + file_attestation_v1_crafting_state_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*Policy_Violation); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_attestation_v1_crafting_state_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*Commit_Remote); i { case 0: return &v.state @@ -1174,7 +1374,7 @@ func file_attestation_v1_crafting_state_proto_init() { } } } - file_attestation_v1_crafting_state_proto_msgTypes[6].OneofWrappers = []interface{}{ + file_attestation_v1_crafting_state_proto_msgTypes[7].OneofWrappers = []interface{}{ (*Attestation_Material_String_)(nil), (*Attestation_Material_ContainerImage_)(nil), (*Attestation_Material_Artifact_)(nil), @@ -1185,7 +1385,7 @@ func file_attestation_v1_crafting_state_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_attestation_v1_crafting_state_proto_rawDesc, NumEnums: 0, - NumMessages: 13, + NumMessages: 15, NumExtensions: 0, NumServices: 0, }, diff --git a/internal/attestation/crafter/api/attestation/v1/crafting_state.proto b/internal/attestation/crafter/api/attestation/v1/crafting_state.proto index b7f62566d..a181e4260 100644 --- a/internal/attestation/crafter/api/attestation/v1/crafting_state.proto +++ b/internal/attestation/crafter/api/attestation/v1/crafting_state.proto @@ -88,6 +88,32 @@ message Attestation { // Head Commit of the environment where the attestation was executed (optional) Commit head = 9; + + // Policies that this attestation was validated against + repeated Policy policies = 10; +} + +// A policy executed against an attestation +message Policy { + // The policy name from the policy spec + string name = 1 [(buf.validate.field) = { + cel: { + message: "must contain only lowercase letters, numbers, and hyphens.", + expression: "this.matches('^[a-z0-9]([-a-z0-9]*[a-z0-9])?$')", + id: "name.dns-1123", + }, + }]; + // The attachment as in the contract, with arguments and any other metadata + workflowcontract.v1.PolicyAttachment attachment = 2 [(buf.validate.field).required = true]; + // The policy script body (rego) + string body = 3 [(buf.validate.field).required = true]; + // The policy violations, if any + repeated Violation violations = 4; + + message Violation { + string subject = 1 [(buf.validate.field).required = true]; + string message = 2 [(buf.validate.field).required = true]; + } } message Commit { diff --git a/internal/attestation/crafter/crafter.go b/internal/attestation/crafter/crafter.go index f0632cc17..e1a7ac1b5 100644 --- a/internal/attestation/crafter/crafter.go +++ b/internal/attestation/crafter/crafter.go @@ -153,8 +153,8 @@ func (c *Crafter) AlreadyInitialized(ctx context.Context, stateID string) (bool, return c.stateManager.Initialized(ctx, stateID) } -// Extract raw data in JSON format from different sources, i.e cue or yaml files -func loadJSONBytes(rawData []byte, extension string) ([]byte, error) { +// LoadJSONBytes Extracts raw data in JSON format from different sources, i.e cue or yaml files +func LoadJSONBytes(rawData []byte, extension string) ([]byte, error) { var jsonRawData []byte var err error @@ -187,7 +187,7 @@ func LoadSchema(pathOrURI string) (*schemaapi.CraftingSchema, error) { return nil, err } - jsonSchemaRaw, err := loadJSONBytes(content, filepath.Ext(pathOrURI)) + jsonSchemaRaw, err := LoadJSONBytes(content, filepath.Ext(pathOrURI)) if err != nil { return nil, err } diff --git a/pkg/policies/policies.go b/pkg/policies/policies.go index 4dd1c4094..50aa829a3 100644 --- a/pkg/policies/policies.go +++ b/pkg/policies/policies.go @@ -16,13 +16,191 @@ package policies import ( + "bufio" + "bytes" + "context" + "fmt" + "path/filepath" + + "github.com/bufbuild/protovalidate-go" + "github.com/sigstore/cosign/v2/pkg/blob" + "google.golang.org/protobuf/encoding/protojson" + v1 "github.com/chainloop-dev/chainloop/app/controlplane/api/workflowcontract/v1" + "github.com/chainloop-dev/chainloop/internal/attestation/crafter" + v12 "github.com/chainloop-dev/chainloop/internal/attestation/crafter/api/attestation/v1" + "github.com/chainloop-dev/chainloop/internal/casclient" "github.com/chainloop-dev/chainloop/pkg/policies/engine" "github.com/chainloop-dev/chainloop/pkg/policies/engine/rego" ) -// GetPolicyEngine returns a PolicyEngine implementation to evaluate a given policy. -func GetPolicyEngine(_ *v1.Policy) engine.PolicyEngine { +type PolicyVerifier struct { + state *v12.CraftingState + cas casclient.Downloader +} + +func NewPolicyVerifier(state *v12.CraftingState, client casclient.Downloader) *PolicyVerifier { + // only Rego engine is currently supported + return &PolicyVerifier{state: state, cas: client} +} + +// Verify verifies that the statement is compliant with the policies present in the schema +func (pv *PolicyVerifier) Verify(ctx context.Context) ([]*engine.PolicyViolation, error) { + violations := make([]*engine.PolicyViolation, 0) + policies := pv.state.GetInputSchema().GetPolicies() + for _, policyAtt := range policies { + if policyAtt.Disabled { + // policy is disabled + // TODO: WARN. + continue + } + + // 1. load the policy spec + spec, err := pv.loadSpec(policyAtt) + if err != nil { + return nil, fmt.Errorf("failed to load policy spec: %w", err) + } + + // 2. load the policy script (rego) + script, err := pv.loadPolicyScriptFromSpec(spec) + if err != nil { + return nil, fmt.Errorf("failed to load policy content: %w", err) + } + + // 3. load the affected material (or the whole attestation) + material, err := pv.loadSubject(ctx, policyAtt, spec, pv.state) + if err != nil { + return nil, fmt.Errorf("failed to load policy subject: %w", err) + } + + // 4. verify the policy + ng := getPolicyEngine(spec) + res, err := ng.Verify(ctx, script, material) + if err != nil { + return nil, fmt.Errorf("failed to verify policy: %w", err) + } + violations = append(violations, res...) + + // 5. Store result in the attestation itself (for the renderer to include them in the predicate) + pv.state.Attestation.Policies = append(pv.state.Attestation.Policies, &v12.Policy{ + Name: spec.Metadata.Name, + Attachment: policyAtt, + Body: string(script.Source), + Violations: policyViolationsToAttestationViolations(res), + }) + } + + return violations, nil +} + +func (pv *PolicyVerifier) loadSpec(attachment *v1.PolicyAttachment) (*v1.Policy, error) { + // look for the referenced policy spec (note: loading by `name` is not supported yet) + reference := attachment.GetRef() + // this method understands env, http and https schemes, and defaults to file system. + rawData, err := blob.LoadFileOrURL(reference) + if err != nil { + return nil, fmt.Errorf("loading policy spec: %w", err) + } + jsonContent, err := crafter.LoadJSONBytes(rawData, filepath.Ext(reference)) + if err != nil { + return nil, fmt.Errorf("loading policy spec: %w", err) + } + var policy v1.Policy + if err := protojson.Unmarshal(jsonContent, &policy); err != nil { + return nil, fmt.Errorf("unmarshalling policy spec: %w", err) + } + // Validate just in case + validator, err := protovalidate.New() + if err != nil { + return nil, fmt.Errorf("validating policy spec: %w", err) + } + err = validator.Validate(&policy) + if err != nil { + return nil, fmt.Errorf("validating policy spec: %w", err) + } + + return &policy, nil +} + +// loads a policy referenced from the spec +func (pv *PolicyVerifier) loadPolicyScriptFromSpec(spec *v1.Policy) (*engine.Policy, error) { + var content []byte + var err error + + switch source := spec.GetSpec().GetSource().(type) { + case *v1.PolicySpec_Embedded: + content = []byte(source.Embedded) + case *v1.PolicySpec_Path: + content, err = blob.LoadFileOrURL(source.Path) + if err != nil { + return nil, fmt.Errorf("loading policy content: %w", err) + } + default: + return nil, fmt.Errorf("policy spec is empty") + } + + return &engine.Policy{ + Name: spec.GetMetadata().GetName(), + Source: content, + }, nil +} + +// load the subject of the policy. +func (pv *PolicyVerifier) loadSubject(ctx context.Context, attachment *v1.PolicyAttachment, spec *v1.Policy, state *v12.CraftingState) ([]byte, error) { + // Load the affected material or attestation, and checks if the expected name and type match + name := attachment.GetSelector().GetName() + // if name selector is not set, the subject will become the full crafting state + if name == "" { + return protojson.Marshal(state.GetAttestation()) + } + + // if name is set, we want a specific material + for k, m := range state.GetAttestation().GetMaterials() { + if k == name { + if spec.GetSpec().GetKind() != v1.CraftingSchema_Material_MATERIAL_TYPE_UNSPECIFIED && spec.GetSpec().GetKind() != m.GetMaterialType() { + // If policy wasn't meant to be evaluated against this type of material, raise an error + return nil, fmt.Errorf("invalid material type: %s, policy expected: %s", m.GetMaterialType(), spec.GetSpec().GetKind()) + } + return pv.getMaterialPayload(ctx, m) + } + } + + return nil, fmt.Errorf("no material found with name %s", name) +} + +// Gets the material payload from the CAS +func (pv *PolicyVerifier) getMaterialPayload(ctx context.Context, m *v12.Attestation_Material) ([]byte, error) { + if m.InlineCas { + return m.GetArtifact().GetContent(), nil + } + + // Use the CAS to look for the material + var b bytes.Buffer + w := bufio.NewWriter(&b) + err := pv.cas.Download(ctx, w, m.GetArtifact().GetDigest()) + if err != nil { + return nil, fmt.Errorf("failed to download artifact: %w", err) + } + err = w.Flush() + if err != nil { + return nil, fmt.Errorf("failed to download artifact: %w", err) + } + + return b.Bytes(), nil +} + +// getPolicyEngine returns a PolicyEngine implementation to evaluate a given policy. +func getPolicyEngine(_ *v1.Policy) engine.PolicyEngine { // Currently, only Rego is supported return new(rego.Rego) } + +func policyViolationsToAttestationViolations(violations []*engine.PolicyViolation) (pvs []*v12.Policy_Violation) { + for _, violation := range violations { + pvs = append(pvs, &v12.Policy_Violation{ + Subject: violation.Subject, + Message: violation.Violation, + }) + } + return +} diff --git a/pkg/policies/policies_test.go b/pkg/policies/policies_test.go new file mode 100644 index 000000000..4f9aad354 --- /dev/null +++ b/pkg/policies/policies_test.go @@ -0,0 +1,442 @@ +// +// Copyright 2024 The Chainloop Authors. +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +package policies + +import ( + "context" + "io" + "io/fs" + "os" + "testing" + + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/suite" + "golang.org/x/exp/slices" + + v12 "github.com/chainloop-dev/chainloop/app/controlplane/api/workflowcontract/v1" + v1 "github.com/chainloop-dev/chainloop/internal/attestation/crafter/api/attestation/v1" + "github.com/chainloop-dev/chainloop/internal/casclient/mocks" +) + +func (s *testSuite) TestVerifyAttestations() { + cases := []struct { + name string + state *v1.CraftingState + violations int + wantErr error + }{ + { + name: "happy path, test attestation properties", + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_GITHUB_ACTION, + }, + }, + }, + { + name: "wrong runner", + violations: 1, + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_DAGGER_PIPELINE, + }, + }, + }, + { + name: "missing runner", + violations: 1, + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + }, + }, + }, + { + name: "wrong policy", + wantErr: &fs.PathError{}, + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/wrong_policy.yaml"}}, + }, + }, + }, + }, + { + name: "missing rego policy", + wantErr: &fs.PathError{}, + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/missing_rego.yaml"}}, + }, + }, + }, + }, + { + name: "embedded rego policy", + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow_embedded.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + }, + }, + }, + { + name: "embedded rego policy violations", + state: &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow_embedded.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "wrongname", + }, + }, + }, + violations: 1, + }, + } + + for _, tc := range cases { + s.Run(tc.name, func() { + verifier := NewPolicyVerifier(tc.state, nil) + res, err := verifier.Verify(context.TODO()) + if tc.wantErr != nil { + // #nosec G601 + s.ErrorAs(err, &tc.wantErr) + return + } + s.Require().NoError(err) + if tc.violations > 0 { + s.Len(res, tc.violations) + } + }) + } +} + +func (s *testSuite) TestAttestationResult() { + s.Run("successful attestation", func() { + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_GITHUB_ACTION, + }, + } + + verifier := NewPolicyVerifier(state, nil) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 0) + + att := state.GetAttestation() + s.Len(att.Policies, 1) + + p := att.Policies[0] + s.Len(p.Violations, 0) + s.Equal("testdata/workflow.yaml", p.Attachment.GetRef()) + s.Equal("workflow", p.Name) + s.Contains(p.Body, "package main") + }) + + s.Run("failed attestation", func() { + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_DAGGER_PIPELINE, + }, + } + + verifier := NewPolicyVerifier(state, nil) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 1) + + att := state.GetAttestation() + s.Len(att.Policies, 1) + + p := att.Policies[0] + s.Len(p.Violations, 1) + s.Contains(p.Body, "package main") + v := p.Violations[0] + s.Equal(p.Name, v.Subject) + s.Equal("incorrect runner", v.Message) + }) + + s.Run("multiple successful policies", func() { + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/materials.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_GITHUB_ACTION, + Materials: map[string]*v1.Attestation_Material{ + "vex": { + MaterialType: v12.CraftingSchema_Material_OPENVEX, + }, + }, + }, + } + + verifier := NewPolicyVerifier(state, nil) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 0) + att := state.GetAttestation() + s.Len(att.Policies, 2) + s.Len(att.Policies[0].Violations, 0) + s.Len(att.Policies[1].Violations, 0) + }) + + s.Run("partial success", func() { + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Policies: []*v12.PolicyAttachment{ + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/workflow.yaml"}}, + {Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/materials.yaml"}}, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + RunnerType: v12.CraftingSchema_Runner_DAGGER_PIPELINE, + Materials: map[string]*v1.Attestation_Material{ + "vex": { + MaterialType: v12.CraftingSchema_Material_OPENVEX, + }, + }, + }, + } + + verifier := NewPolicyVerifier(state, nil) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Greater(len(res), 0) + att := state.GetAttestation() + s.Len(att.Policies, 2) + + // Check that only 1 policy failed + index := slices.IndexFunc(att.Policies, func(p *v1.Policy) bool { + return p.Name == "workflow" + }) + p := att.Policies[index] + s.Len(p.Violations, 1) + + index = slices.IndexFunc(att.Policies, func(p *v1.Policy) bool { + return p.Name == "materials" + }) + p = att.Policies[index] + s.Len(p.Violations, 0) + }) +} + +func (s *testSuite) TestInlineMaterial() { + content, err := os.ReadFile("testdata/sbom-spdx.json") + s.Require().NoError(err) + + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Materials: []*v12.CraftingSchema_Material{ + { + Name: "sbom", + Type: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + }, + }, + Policies: []*v12.PolicyAttachment{ + { + Selector: &v12.PolicyAttachment_MaterialSelector{Name: "sbom"}, + Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/sbom_syft.yaml"}, + }, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + Materials: map[string]*v1.Attestation_Material{ + "sbom": { + MaterialType: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + M: &v1.Attestation_Material_Artifact_{Artifact: &v1.Attestation_Material_Artifact{ + Content: content, + }, + }, + InlineCas: true, + }, + }, + }, + } + verifier := NewPolicyVerifier(state, nil) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 0) + + att := state.GetAttestation() + s.Len(att.Policies, 1) + s.Len(att.Policies[0].Violations, 0) +} + +func (s *testSuite) TestDownloadedMaterial() { + content, err := os.ReadFile("testdata/sbom-spdx.json") + s.Require().NoError(err) + + d := mocks.NewDownloader(s.T()) + d.On("Download", context.TODO(), mock.AnythingOfType("*bufio.Writer"), "foobar").Run(func(args mock.Arguments) { + w := args.Get(1).(io.Writer) + _, err := w.Write(content) + s.Require().NoError(err) + }).Return(nil) + + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Materials: []*v12.CraftingSchema_Material{ + { + Name: "sbom", + Type: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + }, + }, + Policies: []*v12.PolicyAttachment{ + { + Selector: &v12.PolicyAttachment_MaterialSelector{Name: "sbom"}, + Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/sbom_syft.yaml"}, + }, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + Materials: map[string]*v1.Attestation_Material{ + "sbom": { + MaterialType: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + M: &v1.Attestation_Material_Artifact_{Artifact: &v1.Attestation_Material_Artifact{ + Digest: "foobar", + }, + }, + UploadedToCas: true, + }, + }, + }, + } + verifier := NewPolicyVerifier(state, d) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 0) +} + +func (s *testSuite) TestInvalidDownloadedMaterial() { + d := mocks.NewDownloader(s.T()) + d.On("Download", context.TODO(), mock.AnythingOfType("*bufio.Writer"), "another").Run(func(args mock.Arguments) { + w := args.Get(1).(io.Writer) + _, err := w.Write([]byte(`{"this": { "is": "not", "a": "sbom"}}`)) + s.Require().NoError(err) + }).Return(nil) + + state := &v1.CraftingState{ + InputSchema: &v12.CraftingSchema{ + Materials: []*v12.CraftingSchema_Material{ + { + Name: "sbom", + Type: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + }, + }, + Policies: []*v12.PolicyAttachment{ + { + Selector: &v12.PolicyAttachment_MaterialSelector{Name: "sbom"}, + Policy: &v12.PolicyAttachment_Ref{Ref: "testdata/sbom_syft.yaml"}, + }, + }, + }, + Attestation: &v1.Attestation{ + Workflow: &v1.WorkflowMetadata{ + Name: "policytest", + }, + Materials: map[string]*v1.Attestation_Material{ + "sbom": { + MaterialType: v12.CraftingSchema_Material_SBOM_SPDX_JSON, + M: &v1.Attestation_Material_Artifact_{Artifact: &v1.Attestation_Material_Artifact{ + Digest: "another", + }, + }, + UploadedToCas: true, + }, + }, + }, + } + verifier := NewPolicyVerifier(state, d) + res, err := verifier.Verify(context.TODO()) + s.Require().NoError(err) + s.Len(res, 1) +} + +type testSuite struct { + suite.Suite +} + +func TestPolicyVerifier(t *testing.T) { + suite.Run(t, new(testSuite)) +} diff --git a/pkg/policies/testdata/materials.rego b/pkg/policies/testdata/materials.rego new file mode 100644 index 000000000..a31b6d1c3 --- /dev/null +++ b/pkg/policies/testdata/materials.rego @@ -0,0 +1,26 @@ +package main + +import future.keywords.in +import future.keywords.contains + +# Verifies there is a VEX material, even if not enforced by contract + +deny[msg] { + not has_vex + + msg := "missing VEX material" +} + +# Collect all material types +kinds contains kind { + some material in input.materials + kind := material.materialType +} + +has_vex { + "CSAF_VEX" in kinds +} + +has_vex { + "OPENVEX" in kinds +} diff --git a/pkg/policies/testdata/materials.yaml b/pkg/policies/testdata/materials.yaml new file mode 100644 index 000000000..15a851a8d --- /dev/null +++ b/pkg/policies/testdata/materials.yaml @@ -0,0 +1,6 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: materials +spec: + path: testdata/materials.rego diff --git a/pkg/policies/testdata/missing_rego.yaml b/pkg/policies/testdata/missing_rego.yaml new file mode 100644 index 000000000..0f326aa1e --- /dev/null +++ b/pkg/policies/testdata/missing_rego.yaml @@ -0,0 +1,6 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: missing-rego +spec: + path: this_is_a_missing.rego diff --git a/pkg/policies/testdata/sbom-spdx.json b/pkg/policies/testdata/sbom-spdx.json new file mode 100644 index 000000000..1f001e97a --- /dev/null +++ b/pkg/policies/testdata/sbom-spdx.json @@ -0,0 +1,1874 @@ +{ + "spdxVersion": "SPDX-2.3", + "dataLicense": "CC0-1.0", + "SPDXID": "SPDXRef-DOCUMENT", + "name": ".", + "documentNamespace": "https://anchore.com/syft/dir/5d82480d-1f44-4351-b216-24880a877ce4", + "creationInfo": { + "licenseListVersion": "3.20", + "creators": [ + "Organization: Anchore, Inc", + "Tool: syft-0.73.0" + ], + "created": "2023-02-25T15:16:03Z" + }, + "packages": [ + { + "name": "@algolia/autocomplete-core", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-core-d4f529d2efd5d873", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-core:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-core:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_core:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_core:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-core@1.7.4" + } + ] + }, + { + "name": "@algolia/autocomplete-core", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-core-a75e9cc60748602d", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-core:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-core:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_core:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_core:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_core:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-core@1.7.4" + } + ] + }, + { + "name": "@algolia/autocomplete-preset-algolia", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-preset-algolia-2efe8108bf5904fb", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset-algolia:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset-algolia:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset_algolia:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset_algolia:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-preset-algolia@1.7.4" + } + ] + }, + { + "name": "@algolia/autocomplete-preset-algolia", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-preset-algolia-719fbc0a971c8423", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset-algolia:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset-algolia:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset_algolia:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset_algolia:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-preset:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_preset:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-preset-algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_preset_algolia:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-preset-algolia@1.7.4" + } + ] + }, + { + "name": "@algolia/autocomplete-shared", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-shared-c04c8898a671ed16", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-shared:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-shared:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_shared:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_shared:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-shared@1.7.4" + } + ] + }, + { + "name": "@algolia/autocomplete-shared", + "SPDXID": "SPDXRef-Package-npm--algolia-autocomplete-shared-349e9c24c2b4f2c5", + "versionInfo": "1.7.4", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-shared:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete-shared:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_shared:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete_shared:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/autocomplete:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete-shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/autocomplete_shared:1.7.4:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/autocomplete-shared@1.7.4" + } + ] + }, + { + "name": "@algolia/cache-browser-local-storage", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-browser-local-storage-7f047bcfa53ed7ee", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local-storage:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local-storage:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local_storage:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local_storage:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-browser-local-storage@4.14.3" + } + ] + }, + { + "name": "@algolia/cache-browser-local-storage", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-browser-local-storage-699118b8ecb40e29", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local-storage:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local-storage:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local_storage:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local_storage:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser-local:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser_local:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-browser:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_browser:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-browser-local-storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_browser_local_storage:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-browser-local-storage@4.14.3" + } + ] + }, + { + "name": "@algolia/cache-common", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-common-b83a20f4252c841a", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-common:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-common:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_common:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_common:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-common@4.14.3" + } + ] + }, + { + "name": "@algolia/cache-common", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-common-8feb5c8eb82329a3", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-common:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-common:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_common:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_common:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-common@4.14.3" + } + ] + }, + { + "name": "@algolia/cache-in-memory", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-in-memory-5b4709d3757a3a6d", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in-memory:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in-memory:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in_memory:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in_memory:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-in-memory@4.14.3" + } + ] + }, + { + "name": "@algolia/cache-in-memory", + "SPDXID": "SPDXRef-Package-npm--algolia-cache-in-memory-a4bf58feef42f315", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in-memory:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in-memory:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in_memory:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in_memory:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache-in:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache_in:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/cache:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache-in-memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/cache_in_memory:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/cache-in-memory@4.14.3" + } + ] + }, + { + "name": "@algolia/client-account", + "SPDXID": "SPDXRef-Package-npm--algolia-client-account-ccad52fb07b66b08", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-account:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-account:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_account:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_account:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-account@4.14.3" + } + ] + }, + { + "name": "@algolia/client-account", + "SPDXID": "SPDXRef-Package-npm--algolia-client-account-dcac7f21f13a1b6", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-account:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-account:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_account:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_account:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_account:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-account@4.14.3" + } + ] + }, + { + "name": "@algolia/client-analytics", + "SPDXID": "SPDXRef-Package-npm--algolia-client-analytics-da8f8d5e4a42283c", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-analytics:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-analytics:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_analytics:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_analytics:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-analytics@4.14.3" + } + ] + }, + { + "name": "@algolia/client-analytics", + "SPDXID": "SPDXRef-Package-npm--algolia-client-analytics-7aa06ac329e132f6", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-analytics:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-analytics:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_analytics:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_analytics:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_analytics:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-analytics@4.14.3" + } + ] + }, + { + "name": "@algolia/client-common", + "SPDXID": "SPDXRef-Package-npm--algolia-client-common-fdab2e146ab09cb0", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-common:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-common:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_common:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_common:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-common@4.14.3" + } + ] + }, + { + "name": "@algolia/client-common", + "SPDXID": "SPDXRef-Package-npm--algolia-client-common-1e82fe4ac5f06142", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-common:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-common:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_common:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_common:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-common@4.14.3" + } + ] + }, + { + "name": "@algolia/client-personalization", + "SPDXID": "SPDXRef-Package-npm--algolia-client-personalization-5860c568f6a2884b", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-personalization:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-personalization:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_personalization:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_personalization:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-personalization@4.14.3" + } + ] + }, + { + "name": "@algolia/client-personalization", + "SPDXID": "SPDXRef-Package-npm--algolia-client-personalization-5230f032c64636a3", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-personalization:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-personalization:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_personalization:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_personalization:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_personalization:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-personalization@4.14.3" + } + ] + }, + { + "name": "@algolia/client-search", + "SPDXID": "SPDXRef-Package-npm--algolia-client-search-dd73cb953fef8932", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-search:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-search:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_search:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_search:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-search@4.14.3" + } + ] + }, + { + "name": "@algolia/client-search", + "SPDXID": "SPDXRef-Package-npm--algolia-client-search-a19e56cf638775e2", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-search:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client-search:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_search:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client_search:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/client:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client-search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/client_search:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/client-search@4.14.3" + } + ] + }, + { + "name": "@algolia/events", + "SPDXID": "SPDXRef-Package-npm--algolia-events-5f312ad698b9cd07", + "versionInfo": "4.0.1", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/events:\\@algolia\\/events:4.0.1:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/events:4.0.1:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/events@4.0.1" + } + ] + }, + { + "name": "@algolia/events", + "SPDXID": "SPDXRef-Package-npm--algolia-events-4f529c22422af8a", + "versionInfo": "4.0.1", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/events:\\@algolia\\/events:4.0.1:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/events:4.0.1:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/events@4.0.1" + } + ] + }, + { + "name": "@algolia/logger-common", + "SPDXID": "SPDXRef-Package-npm--algolia-logger-common-4beb0a564e01e8dd", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-common:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-common:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_common:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_common:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/logger-common@4.14.3" + } + ] + }, + { + "name": "@algolia/logger-common", + "SPDXID": "SPDXRef-Package-npm--algolia-logger-common-b5611c2c52827c17", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-common:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-common:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_common:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_common:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger-common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger_common:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/logger-common@4.14.3" + } + ] + }, + { + "name": "@algolia/logger-console", + "SPDXID": "SPDXRef-Package-npm--algolia-logger-console-7d44d092b7346496", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-console:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-console:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_console:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_console:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/logger-console@4.14.3" + } + ] + }, + { + "name": "@algolia/logger-console", + "SPDXID": "SPDXRef-Package-npm--algolia-logger-console-bd05c3862ee5c855", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-console:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger-console:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_console:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger_console:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/logger:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger-console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/logger_console:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/logger-console@4.14.3" + } + ] + }, + { + "name": "@algolia/requester-browser-xhr", + "SPDXID": "SPDXRef-Package-npm--algolia-requester-browser-xhr-2547173fb30f7bf4", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: package-lock.json", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser-xhr:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser-xhr:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser_xhr:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser_xhr:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/requester-browser-xhr@4.14.3" + } + ] + }, + { + "name": "@algolia/requester-browser-xhr", + "SPDXID": "SPDXRef-Package-npm--algolia-requester-browser-xhr-afdcaeba77bd9241", + "versionInfo": "4.14.3", + "downloadLocation": "NOASSERTION", + "sourceInfo": "acquired package info from installed node module manifest file: yarn.lock", + "licenseConcluded": "MIT", + "licenseDeclared": "MIT", + "copyrightText": "NOASSERTION", + "externalRefs": [ + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser-xhr:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser-xhr:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser_xhr:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser_xhr:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester-browser:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester_browser:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:\\@algolia\\/requester:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/requester-browser-xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "SECURITY", + "referenceType": "cpe23Type", + "referenceLocator": "cpe:2.3:a:*:\\@algolia\\/requester_browser_xhr:4.14.3:*:*:*:*:*:*:*" + }, + { + "referenceCategory": "PACKAGE-MANAGER", + "referenceType": "purl", + "referenceLocator": "pkg:npm/%40algolia/requester-browser-xhr@4.14.3" + } + ] + } + ], + "relationships": [ + { + "spdxElementId": "SPDXRef-DOCUMENT", + "relatedSpdxElement": "SPDXRef-DOCUMENT", + "relationshipType": "DESCRIBES" + } + ] +} diff --git a/pkg/policies/testdata/sbom_syft.rego b/pkg/policies/testdata/sbom_syft.rego new file mode 100644 index 000000000..5bfe098c8 --- /dev/null +++ b/pkg/policies/testdata/sbom_syft.rego @@ -0,0 +1,14 @@ +package main + +import future.keywords.in + +deny[msg] { + not made_with_syft + + msg := "Not made with syft" +} + +made_with_syft { + some creator in input.creationInfo.creators + contains(creator, "syft") +} \ No newline at end of file diff --git a/pkg/policies/testdata/sbom_syft.yaml b/pkg/policies/testdata/sbom_syft.yaml new file mode 100644 index 000000000..4fa4d9a1a --- /dev/null +++ b/pkg/policies/testdata/sbom_syft.yaml @@ -0,0 +1,6 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: made-with-syft +spec: + path: testdata/sbom_syft.rego diff --git a/pkg/policies/testdata/workflow.rego b/pkg/policies/testdata/workflow.rego new file mode 100644 index 000000000..403fa3c4d --- /dev/null +++ b/pkg/policies/testdata/workflow.rego @@ -0,0 +1,22 @@ +package main + +deny[msg] { + not is_workflow + + msg := "incorrect workflow" +} + +deny[msg] { + not is_github + + msg := "incorrect runner" +} + + +is_workflow { + input.workflow.name == "policytest" +} + +is_github { + input.runnerType == "GITHUB_ACTION" +} \ No newline at end of file diff --git a/pkg/policies/testdata/workflow.yaml b/pkg/policies/testdata/workflow.yaml new file mode 100644 index 000000000..60aa90267 --- /dev/null +++ b/pkg/policies/testdata/workflow.yaml @@ -0,0 +1,6 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: workflow +spec: + path: testdata/workflow.rego diff --git a/pkg/policies/testdata/workflow_embedded.yaml b/pkg/policies/testdata/workflow_embedded.yaml new file mode 100644 index 000000000..6e02a4062 --- /dev/null +++ b/pkg/policies/testdata/workflow_embedded.yaml @@ -0,0 +1,15 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: workflow +spec: + embedded: | + package main + deny[msg] { + not is_workflow + msg := "incorrect workflow" + } + + is_workflow { + input.workflow.name == "policytest" + } diff --git a/pkg/policies/testdata/wrong_policy.rego b/pkg/policies/testdata/wrong_policy.rego new file mode 100644 index 000000000..9c4e215bf --- /dev/null +++ b/pkg/policies/testdata/wrong_policy.rego @@ -0,0 +1,7 @@ +package main + +# wrong policy without a "deny" rule + +is_wrong { + true +} diff --git a/pkg/policies/testdata/wrong_policy.yaml b/pkg/policies/testdata/wrong_policy.yaml new file mode 100644 index 000000000..e6d2d9b6c --- /dev/null +++ b/pkg/policies/testdata/wrong_policy.yaml @@ -0,0 +1,6 @@ +apiVersion: workflowcontract.chainloop.dev/v1 +kind: Policy +metadata: + name: wrong_policy +spec: + path: testdata/wrong_policy.rego