From 957896b4a09656e2bdde440f684f5f5fc707aba5 Mon Sep 17 00:00:00 2001 From: Christian Schaible Date: Thu, 18 Jul 2024 14:33:11 +0200 Subject: [PATCH] Use google audit schema --- gen/go/audit/v1/audit_event.pb.go | 3008 +++++++++++++---- gen/go/audit/v1/audit_event.pb.validate.go | 3383 ++++++++++++++++---- proto/audit/v1/audit_event.proto | 679 +++- 3 files changed, 5788 insertions(+), 1282 deletions(-) diff --git a/gen/go/audit/v1/audit_event.pb.go b/gen/go/audit/v1/audit_event.pb.go index d8c345e..d060ca4 100644 --- a/gen/go/audit/v1/audit_event.pb.go +++ b/gen/go/audit/v1/audit_event.pb.go @@ -10,9 +10,9 @@ import ( _ "buf.build/gen/go/bufbuild/protovalidate/protocolbuffers/go/buf/validate" protoreflect "google.golang.org/protobuf/reflect/protoreflect" protoimpl "google.golang.org/protobuf/runtime/protoimpl" + anypb "google.golang.org/protobuf/types/known/anypb" structpb "google.golang.org/protobuf/types/known/structpb" timestamppb "google.golang.org/protobuf/types/known/timestamppb" - wrapperspb "google.golang.org/protobuf/types/known/wrapperspb" reflect "reflect" sync "sync" ) @@ -24,351 +24,141 @@ const ( _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) ) -type EventTrigger int32 +// The severity of the event described in a log entry, expressed as one of the +// standard severity levels listed below. For your reference, the levels are +// assigned the listed numeric values. The effect of using numeric values other +// than those listed is undefined. +// Copied from +// https://github.com/googleapis/googleapis/blob/master/google/logging/type/log_severity.proto +type LogSeverity int32 const ( - EventTrigger_EVENT_TRIGGER_UNSPECIFIED EventTrigger = 0 - // Event from messaging system - EventTrigger_EVENT_TRIGGER_EVENT EventTrigger = 1 - // Time based scheduler - EventTrigger_EVENT_TRIGGER_SCHEDULER EventTrigger = 2 - // Network request (REST, gRPC, etc.) - EventTrigger_EVENT_TRIGGER_REQUEST EventTrigger = 3 + // (0) The log entry has no assigned severity level. + LogSeverity_DEFAULT LogSeverity = 0 + // (100) Debug or trace information. + LogSeverity_DEBUG LogSeverity = 100 + // (200) Routine information, such as ongoing status or performance. + LogSeverity_INFO LogSeverity = 200 + // (300) Normal but significant events, such as start up, shut down, or + // a configuration change. + LogSeverity_NOTICE LogSeverity = 300 + // (400) Warning events might cause problems. + LogSeverity_WARNING LogSeverity = 400 + // (500) Error events are likely to cause problems. + LogSeverity_ERROR LogSeverity = 500 + // (600) Critical events cause more severe problems or outages. + LogSeverity_CRITICAL LogSeverity = 600 + // (700) A person must take an action immediately. + LogSeverity_ALERT LogSeverity = 700 + // (800) One or more systems are unusable. + LogSeverity_EMERGENCY LogSeverity = 800 ) -// Enum value maps for EventTrigger. +// Enum value maps for LogSeverity. var ( - EventTrigger_name = map[int32]string{ - 0: "EVENT_TRIGGER_UNSPECIFIED", - 1: "EVENT_TRIGGER_EVENT", - 2: "EVENT_TRIGGER_SCHEDULER", - 3: "EVENT_TRIGGER_REQUEST", + LogSeverity_name = map[int32]string{ + 0: "DEFAULT", + 100: "DEBUG", + 200: "INFO", + 300: "NOTICE", + 400: "WARNING", + 500: "ERROR", + 600: "CRITICAL", + 700: "ALERT", + 800: "EMERGENCY", } - EventTrigger_value = map[string]int32{ - "EVENT_TRIGGER_UNSPECIFIED": 0, - "EVENT_TRIGGER_EVENT": 1, - "EVENT_TRIGGER_SCHEDULER": 2, - "EVENT_TRIGGER_REQUEST": 3, + LogSeverity_value = map[string]int32{ + "DEFAULT": 0, + "DEBUG": 100, + "INFO": 200, + "NOTICE": 300, + "WARNING": 400, + "ERROR": 500, + "CRITICAL": 600, + "ALERT": 700, + "EMERGENCY": 800, } ) -func (x EventTrigger) Enum() *EventTrigger { - p := new(EventTrigger) +func (x LogSeverity) Enum() *LogSeverity { + p := new(LogSeverity) *p = x return p } -func (x EventTrigger) String() string { +func (x LogSeverity) String() string { return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) } -func (EventTrigger) Descriptor() protoreflect.EnumDescriptor { +func (LogSeverity) Descriptor() protoreflect.EnumDescriptor { return file_audit_v1_audit_event_proto_enumTypes[0].Descriptor() } -func (EventTrigger) Type() protoreflect.EnumType { +func (LogSeverity) Type() protoreflect.EnumType { return &file_audit_v1_audit_event_proto_enumTypes[0] } -func (x EventTrigger) Number() protoreflect.EnumNumber { +func (x LogSeverity) Number() protoreflect.EnumNumber { return protoreflect.EnumNumber(x) } -// Deprecated: Use EventTrigger.Descriptor instead. -func (EventTrigger) EnumDescriptor() ([]byte, []int) { +// Deprecated: Use LogSeverity.Descriptor instead. +func (LogSeverity) EnumDescriptor() ([]byte, []int) { return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{0} } -type Region int32 - -const ( - Region_REGION_UNSPECIFIED Region = 0 - Region_REGION_EU01 Region = 1 -) - -// Enum value maps for Region. -var ( - Region_name = map[int32]string{ - 0: "REGION_UNSPECIFIED", - 1: "REGION_EU01", - } - Region_value = map[string]int32{ - "REGION_UNSPECIFIED": 0, - "REGION_EU01": 1, - } -) - -func (x Region) Enum() *Region { - p := new(Region) - *p = x - return p -} - -func (x Region) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (Region) Descriptor() protoreflect.EnumDescriptor { - return file_audit_v1_audit_event_proto_enumTypes[1].Descriptor() -} - -func (Region) Type() protoreflect.EnumType { - return &file_audit_v1_audit_event_proto_enumTypes[1] -} - -func (x Region) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use Region.Descriptor instead. -func (Region) EnumDescriptor() ([]byte, []int) { - return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{1} -} - -type Principal struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - // A UUID or another kind of identifier - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - Email *string `protobuf:"bytes,2,opt,name=email,proto3,oneof" json:"email,omitempty"` -} - -func (x *Principal) Reset() { - *x = Principal{} - if protoimpl.UnsafeEnabled { - mi := &file_audit_v1_audit_event_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *Principal) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Principal) ProtoMessage() {} - -func (x *Principal) ProtoReflect() protoreflect.Message { - mi := &file_audit_v1_audit_event_proto_msgTypes[0] - 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 Principal.ProtoReflect.Descriptor instead. -func (*Principal) Descriptor() ([]byte, []int) { - return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{0} -} - -func (x *Principal) GetId() string { - if x != nil { - return x.Id - } - return "" -} - -func (x *Principal) GetEmail() string { - if x != nil && x.Email != nil { - return *x.Email - } - return "" -} - -type RequestDetails struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Endpoint string `protobuf:"bytes,1,opt,name=endpoint,proto3" json:"endpoint,omitempty"` - // Accepts ipv4 and ipv6 - SourceIpAddress string `protobuf:"bytes,2,opt,name=source_ip_address,json=sourceIpAddress,proto3" json:"source_ip_address,omitempty"` - UserAgent *string `protobuf:"bytes,3,opt,name=user_agent,json=userAgent,proto3,oneof" json:"user_agent,omitempty"` - Parameters *structpb.Struct `protobuf:"bytes,4,opt,name=parameters,proto3,oneof" json:"parameters,omitempty"` - Body *structpb.Struct `protobuf:"bytes,5,opt,name=body,proto3,oneof" json:"body,omitempty"` - Headers []*RequestHeader `protobuf:"bytes,6,rep,name=headers,proto3" json:"headers,omitempty"` -} - -func (x *RequestDetails) Reset() { - *x = RequestDetails{} - if protoimpl.UnsafeEnabled { - mi := &file_audit_v1_audit_event_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RequestDetails) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RequestDetails) ProtoMessage() {} - -func (x *RequestDetails) ProtoReflect() protoreflect.Message { - mi := &file_audit_v1_audit_event_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 RequestDetails.ProtoReflect.Descriptor instead. -func (*RequestDetails) Descriptor() ([]byte, []int) { - return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{1} -} - -func (x *RequestDetails) GetEndpoint() string { - if x != nil { - return x.Endpoint - } - return "" -} - -func (x *RequestDetails) GetSourceIpAddress() string { - if x != nil { - return x.SourceIpAddress - } - return "" -} - -func (x *RequestDetails) GetUserAgent() string { - if x != nil && x.UserAgent != nil { - return *x.UserAgent - } - return "" -} - -func (x *RequestDetails) GetParameters() *structpb.Struct { - if x != nil { - return x.Parameters - } - return nil -} - -func (x *RequestDetails) GetBody() *structpb.Struct { - if x != nil { - return x.Body - } - return nil -} - -func (x *RequestDetails) GetHeaders() []*RequestHeader { - if x != nil { - return x.Headers - } - return nil -} - -// Key-value pair for request headers. Key and value are mandatory. -type RequestHeader struct { - state protoimpl.MessageState - sizeCache protoimpl.SizeCache - unknownFields protoimpl.UnknownFields - - Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` - Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` -} - -func (x *RequestHeader) Reset() { - *x = RequestHeader{} - if protoimpl.UnsafeEnabled { - mi := &file_audit_v1_audit_event_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) - } -} - -func (x *RequestHeader) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*RequestHeader) ProtoMessage() {} - -func (x *RequestHeader) ProtoReflect() protoreflect.Message { - mi := &file_audit_v1_audit_event_proto_msgTypes[2] - 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 RequestHeader.ProtoReflect.Descriptor instead. -func (*RequestHeader) Descriptor() ([]byte, []int) { - return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{2} -} - -func (x *RequestHeader) GetKey() string { - if x != nil { - return x.Key - } - return "" -} - -func (x *RequestHeader) GetValue() string { - if x != nil { - return x.Value - } - return "" -} - +// The data within all Cloud Audit Logs log entry events. +// Equivalent to Google's LogEntryData. type AuditEvent struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - // Name of the source system - EventSource string `protobuf:"bytes,1,opt,name=event_source,json=eventSource,proto3" json:"event_source,omitempty"` - Region Region `protobuf:"varint,2,opt,name=region,proto3,enum=audit.v1.Region" json:"region,omitempty"` - // Sequence number of event sent by the service to identify missing events. - SequenceNumber *wrapperspb.Int64Value `protobuf:"bytes,3,opt,name=sequence_number,json=sequenceNumber,proto3" json:"sequence_number,omitempty"` - // Functional event name with pattern _, e.g. ORGANIZATION_CREATED - // Important for filtering and translation / verbalization of event types - // in the UI or data sinks. - EventName string `protobuf:"bytes,4,opt,name=event_name,json=eventName,proto3" json:"event_name,omitempty"` - // The time when the event happened. Must not be a value in the future. - EventTimeStamp *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=event_time_stamp,json=eventTimeStamp,proto3" json:"event_time_stamp,omitempty"` - EventTrigger EventTrigger `protobuf:"varint,6,opt,name=event_trigger,json=eventTrigger,proto3,enum=audit.v1.EventTrigger" json:"event_trigger,omitempty"` - // Request details - mandatory if event_trigger is set to "EVENT_REQUEST" - Request *RequestDetails `protobuf:"bytes,7,opt,name=request,proto3,oneof" json:"request,omitempty"` - Initiator *Principal `protobuf:"bytes,8,opt,name=initiator,proto3" json:"initiator,omitempty"` - // List of service account delegation principals. - // -> Chain from service account to the actual user who initiated the action. - Principals []*Principal `protobuf:"bytes,9,rep,name=principals,proto3" json:"principals,omitempty"` - // Identifier the audit log event refers to + // The resource name of the log to which this log entry belongs. + LogName string `protobuf:"bytes,12,opt,name=log_name,json=logName,proto3" json:"log_name,omitempty"` + // The monitored resource that produced this log entry. // - // Types that are assignable to ResourceContainerReference: + // Example: a log entry that reports a database error would be associated with + // the monitored resource designating the particular database that reported + // the error. + Resource *MonitoredResource `protobuf:"bytes,8,opt,name=resource,proto3" json:"resource,omitempty"` + // The log entry payload, which is always an AuditLog for Cloud Audit Log + // events. + ProtoPayload *AuditLog `protobuf:"bytes,2,opt,name=proto_payload,json=protoPayload,proto3" json:"proto_payload,omitempty"` + // A unique identifier for the log entry. + InsertId string `protobuf:"bytes,4,opt,name=insert_id,json=insertId,proto3" json:"insert_id,omitempty"` + // A set of user-defined (key, value) data that provides additional + // information about the log entry. + Labels map[string]string `protobuf:"bytes,11,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + // Information about an operation associated with the log entry, if + // applicable. + Operation *LogEntryOperation `protobuf:"bytes,15,opt,name=operation,proto3" json:"operation,omitempty"` + // The time the event described by the log entry occurred. + Timestamp *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + // The time the log entry was received by Logging. + ReceiveTimestamp *timestamppb.Timestamp `protobuf:"bytes,24,opt,name=receive_timestamp,json=receiveTimestamp,proto3" json:"receive_timestamp,omitempty"` + // The severity of the log entry. + Severity LogSeverity `protobuf:"varint,10,opt,name=severity,proto3,enum=audit.v1.LogSeverity" json:"severity,omitempty"` + // Resource name of the trace associated with the log entry, if any. If it + // contains a relative resource name, the name is assumed to be relative to + // `//tracing.googleapis.com`. Example: + // `projects/my-projectid/traces/06796866738c859f2f19b7cfb3214824` + Trace string `protobuf:"bytes,22,opt,name=trace,proto3" json:"trace,omitempty"` + // The span ID within the trace associated with the log entry, if any. // - // *AuditEvent_ObjectName - // *AuditEvent_ObjectIdentifier - ResourceContainerReference isAuditEvent_ResourceContainerReference `protobuf_oneof:"resource_container_reference"` - // The identifier of the actual resource (e.g. a VM) - ResourceId *string `protobuf:"bytes,12,opt,name=resource_id,json=resourceId,proto3,oneof" json:"resource_id,omitempty"` - ResourceName *string `protobuf:"bytes,13,opt,name=resource_name,json=resourceName,proto3,oneof" json:"resource_name,omitempty"` - CorrelationId *string `protobuf:"bytes,14,opt,name=correlation_id,json=correlationId,proto3,oneof" json:"correlation_id,omitempty"` - // Result of the operation to publish with the event - Result *structpb.Struct `protobuf:"bytes,15,opt,name=result,proto3,oneof" json:"result,omitempty"` - // Additional information to publish with the event - Details *structpb.Struct `protobuf:"bytes,16,opt,name=details,proto3,oneof" json:"details,omitempty"` + // For Trace spans, this is the same format that the Trace API v2 uses: a + // 16-character hexadecimal encoding of an 8-byte array, such as + // `000000000000004a`. + SpanId string `protobuf:"bytes,27,opt,name=span_id,json=spanId,proto3" json:"span_id,omitempty"` + // Information indicating this LogEntry is part of a sequence of multiple logs + // split from a single LogEntry. + Split *LogSplit `protobuf:"bytes,35,opt,name=split,proto3" json:"split,omitempty"` } func (x *AuditEvent) Reset() { *x = AuditEvent{} if protoimpl.UnsafeEnabled { - mi := &file_audit_v1_audit_event_proto_msgTypes[3] + mi := &file_audit_v1_audit_event_proto_msgTypes[0] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -381,7 +171,7 @@ func (x *AuditEvent) String() string { func (*AuditEvent) ProtoMessage() {} func (x *AuditEvent) ProtoReflect() protoreflect.Message { - mi := &file_audit_v1_audit_event_proto_msgTypes[3] + mi := &file_audit_v1_audit_event_proto_msgTypes[0] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -394,146 +184,1781 @@ func (x *AuditEvent) ProtoReflect() protoreflect.Message { // Deprecated: Use AuditEvent.ProtoReflect.Descriptor instead. func (*AuditEvent) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{0} +} + +func (x *AuditEvent) GetLogName() string { + if x != nil { + return x.LogName + } + return "" +} + +func (x *AuditEvent) GetResource() *MonitoredResource { + if x != nil { + return x.Resource + } + return nil +} + +func (x *AuditEvent) GetProtoPayload() *AuditLog { + if x != nil { + return x.ProtoPayload + } + return nil +} + +func (x *AuditEvent) GetInsertId() string { + if x != nil { + return x.InsertId + } + return "" +} + +func (x *AuditEvent) GetLabels() map[string]string { + if x != nil { + return x.Labels + } + return nil +} + +func (x *AuditEvent) GetOperation() *LogEntryOperation { + if x != nil { + return x.Operation + } + return nil +} + +func (x *AuditEvent) GetTimestamp() *timestamppb.Timestamp { + if x != nil { + return x.Timestamp + } + return nil +} + +func (x *AuditEvent) GetReceiveTimestamp() *timestamppb.Timestamp { + if x != nil { + return x.ReceiveTimestamp + } + return nil +} + +func (x *AuditEvent) GetSeverity() LogSeverity { + if x != nil { + return x.Severity + } + return LogSeverity_DEFAULT +} + +func (x *AuditEvent) GetTrace() string { + if x != nil { + return x.Trace + } + return "" +} + +func (x *AuditEvent) GetSpanId() string { + if x != nil { + return x.SpanId + } + return "" +} + +func (x *AuditEvent) GetSplit() *LogSplit { + if x != nil { + return x.Split + } + return nil +} + +// An object representing a resource that can be used for monitoring, logging, +// billing, or other purposes. +type MonitoredResource struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Required. The monitored resource type. For example, the type of a + // Compute Engine VM instance is `gce_instance`. + Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"` + // Values for all of the labels listed in the associated monitored + // resource descriptor. For example, Compute Engine VM instances use the + // labels `"project_id"`, `"instance_id"`, and `"zone"`. + Labels map[string]string `protobuf:"bytes,2,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (x *MonitoredResource) Reset() { + *x = MonitoredResource{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[1] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MonitoredResource) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MonitoredResource) ProtoMessage() {} + +func (x *MonitoredResource) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_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 MonitoredResource.ProtoReflect.Descriptor instead. +func (*MonitoredResource) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{1} +} + +func (x *MonitoredResource) GetType() string { + if x != nil { + return x.Type + } + return "" +} + +func (x *MonitoredResource) GetLabels() map[string]string { + if x != nil { + return x.Labels + } + return nil +} + +// Additional information about a potentially long-running operation with which +// a log entry is associated. +type LogEntryOperation struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // An arbitrary operation identifier. Log entries with the same + // identifier are assumed to be part of the same operation. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // An arbitrary producer identifier. The combination of `id` and + // `producer` must be globally unique. Examples for `producer`: + // `"MyDivision.MyBigCompany.com"`, `"github.com/MyProject/MyApplication"`. + Producer string `protobuf:"bytes,2,opt,name=producer,proto3" json:"producer,omitempty"` + // True if this is the first log entry in the operation. + First bool `protobuf:"varint,3,opt,name=first,proto3" json:"first,omitempty"` + // True if this is the last log entry in the operation. + Last bool `protobuf:"varint,4,opt,name=last,proto3" json:"last,omitempty"` +} + +func (x *LogEntryOperation) Reset() { + *x = LogEntryOperation{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *LogEntryOperation) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*LogEntryOperation) ProtoMessage() {} + +func (x *LogEntryOperation) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[2] + 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 LogEntryOperation.ProtoReflect.Descriptor instead. +func (*LogEntryOperation) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{2} +} + +func (x *LogEntryOperation) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +func (x *LogEntryOperation) GetProducer() string { + if x != nil { + return x.Producer + } + return "" +} + +func (x *LogEntryOperation) GetFirst() bool { + if x != nil { + return x.First + } + return false +} + +func (x *LogEntryOperation) GetLast() bool { + if x != nil { + return x.Last + } + return false +} + +// Common audit log format for Google Cloud Platform API operations. +// Copied from +// https://github.com/googleapis/googleapis/blob/master/google/cloud/audit/audit_log.proto, +// but changing service_data from Any to Struct. +type AuditLog struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The name of the API service performing the operation. For example, + // `"datastore.googleapis.com"`. + ServiceName string `protobuf:"bytes,7,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"` + // The name of the service method or operation. + // For API calls, this should be the name of the API method. + // For example, + // + // "google.datastore.v1.Datastore.RunQuery" + // "google.logging.v1.LoggingService.DeleteLog" + MethodName string `protobuf:"bytes,8,opt,name=method_name,json=methodName,proto3" json:"method_name,omitempty"` + // The resource or collection that is the target of the operation. + // The name is a scheme-less URI, not including the API service name. + // For example: + // + // "shelves/SHELF_ID/books" + // "shelves/SHELF_ID/books/BOOK_ID" + ResourceName string `protobuf:"bytes,11,opt,name=resource_name,json=resourceName,proto3" json:"resource_name,omitempty"` + // The resource location information. + ResourceLocation *ResourceLocation `protobuf:"bytes,20,opt,name=resource_location,json=resourceLocation,proto3" json:"resource_location,omitempty"` + // The resource's original state before mutation. Present only for + // operations which have successfully modified the targeted resource(s). + // In general, this field should contain all changed fields, except those + // that are already been included in `request`, `response`, `metadata` or + // `service_data` fields. + // When the JSON object represented here has a proto equivalent, + // the proto name will be indicated in the `@type` property. + ResourceOriginalState *structpb.Struct `protobuf:"bytes,19,opt,name=resource_original_state,json=resourceOriginalState,proto3" json:"resource_original_state,omitempty"` + // The number of items returned from a List or Query API method, + // if applicable. + NumResponseItems int64 `protobuf:"varint,12,opt,name=num_response_items,json=numResponseItems,proto3" json:"num_response_items,omitempty"` + // The status of the overall operation. + Status *RpcStatus `protobuf:"bytes,2,opt,name=status,proto3" json:"status,omitempty"` + // Authentication information. + AuthenticationInfo *AuthenticationInfo `protobuf:"bytes,3,opt,name=authentication_info,json=authenticationInfo,proto3" json:"authentication_info,omitempty"` + // Authorization information. If there are multiple + // resources or permissions involved, then there is + // one AuthorizationInfo element for each {resource, permission} tuple. + AuthorizationInfo []*AuthorizationInfo `protobuf:"bytes,9,rep,name=authorization_info,json=authorizationInfo,proto3" json:"authorization_info,omitempty"` + // Metadata about the operation. + RequestMetadata *RequestMetadata `protobuf:"bytes,4,opt,name=request_metadata,json=requestMetadata,proto3" json:"request_metadata,omitempty"` + // The operation request. This may not include all request parameters, + // such as those that are too large, privacy-sensitive, or duplicated + // elsewhere in the log record. + // It should never include user-generated data, such as file contents. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + Request *structpb.Struct `protobuf:"bytes,16,opt,name=request,proto3" json:"request,omitempty"` + // The operation response. This may not include all response elements, + // such as those that are too large, privacy-sensitive, or duplicated + // elsewhere in the log record. + // It should never include user-generated data, such as file contents. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + Response *structpb.Struct `protobuf:"bytes,17,opt,name=response,proto3" json:"response,omitempty"` + // Other service-specific data about the request, response, and other + // information associated with the current audited event. + Metadata *structpb.Struct `protobuf:"bytes,18,opt,name=metadata,proto3" json:"metadata,omitempty"` + // Deprecated: Use `metadata` field instead. + // Other service-specific data about the request, response, and other + // activities. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + ServiceData *structpb.Struct `protobuf:"bytes,15,opt,name=service_data,json=serviceData,proto3" json:"service_data,omitempty"` +} + +func (x *AuditLog) Reset() { + *x = AuditLog{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[3] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AuditLog) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AuditLog) ProtoMessage() {} + +func (x *AuditLog) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[3] + 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 AuditLog.ProtoReflect.Descriptor instead. +func (*AuditLog) Descriptor() ([]byte, []int) { return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{3} } -func (x *AuditEvent) GetEventSource() string { +func (x *AuditLog) GetServiceName() string { if x != nil { - return x.EventSource + return x.ServiceName } return "" } -func (x *AuditEvent) GetRegion() Region { +func (x *AuditLog) GetMethodName() string { if x != nil { - return x.Region - } - return Region_REGION_UNSPECIFIED -} - -func (x *AuditEvent) GetSequenceNumber() *wrapperspb.Int64Value { - if x != nil { - return x.SequenceNumber - } - return nil -} - -func (x *AuditEvent) GetEventName() string { - if x != nil { - return x.EventName + return x.MethodName } return "" } -func (x *AuditEvent) GetEventTimeStamp() *timestamppb.Timestamp { +func (x *AuditLog) GetResourceName() string { if x != nil { - return x.EventTimeStamp + return x.ResourceName + } + return "" +} + +func (x *AuditLog) GetResourceLocation() *ResourceLocation { + if x != nil { + return x.ResourceLocation } return nil } -func (x *AuditEvent) GetEventTrigger() EventTrigger { +func (x *AuditLog) GetResourceOriginalState() *structpb.Struct { if x != nil { - return x.EventTrigger + return x.ResourceOriginalState } - return EventTrigger_EVENT_TRIGGER_UNSPECIFIED + return nil } -func (x *AuditEvent) GetRequest() *RequestDetails { +func (x *AuditLog) GetNumResponseItems() int64 { + if x != nil { + return x.NumResponseItems + } + return 0 +} + +func (x *AuditLog) GetStatus() *RpcStatus { + if x != nil { + return x.Status + } + return nil +} + +func (x *AuditLog) GetAuthenticationInfo() *AuthenticationInfo { + if x != nil { + return x.AuthenticationInfo + } + return nil +} + +func (x *AuditLog) GetAuthorizationInfo() []*AuthorizationInfo { + if x != nil { + return x.AuthorizationInfo + } + return nil +} + +func (x *AuditLog) GetRequestMetadata() *RequestMetadata { + if x != nil { + return x.RequestMetadata + } + return nil +} + +func (x *AuditLog) GetRequest() *structpb.Struct { if x != nil { return x.Request } return nil } -func (x *AuditEvent) GetInitiator() *Principal { +func (x *AuditLog) GetResponse() *structpb.Struct { if x != nil { - return x.Initiator + return x.Response } return nil } -func (x *AuditEvent) GetPrincipals() []*Principal { +func (x *AuditLog) GetMetadata() *structpb.Struct { if x != nil { - return x.Principals + return x.Metadata } return nil } -func (m *AuditEvent) GetResourceContainerReference() isAuditEvent_ResourceContainerReference { - if m != nil { - return m.ResourceContainerReference +func (x *AuditLog) GetServiceData() *structpb.Struct { + if x != nil { + return x.ServiceData } return nil } -func (x *AuditEvent) GetObjectName() ObjectName { - if x, ok := x.GetResourceContainerReference().(*AuditEvent_ObjectName); ok { - return x.ObjectName - } - return ObjectName_OBJECT_NAME_UNSPECIFIED +// Authentication information for the operation. +type AuthenticationInfo struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The email address of the authenticated user (or service account on behalf + // of third party principal) making the request. For third party identity + // callers, the `principal_subject` field is populated instead of this field. + // For privacy reasons, the principal email address is sometimes redacted. + // For more information, see [Caller identities in audit + // logs](https://cloud.google.com/logging/docs/audit#user-id). + PrincipalEmail string `protobuf:"bytes,1,opt,name=principal_email,json=principalEmail,proto3" json:"principal_email,omitempty"` + // The authority selector specified by the requestor, if any. + // It is not guaranteed that the principal was allowed to use this authority. + AuthoritySelector string `protobuf:"bytes,2,opt,name=authority_selector,json=authoritySelector,proto3" json:"authority_selector,omitempty"` + // The third party identification (if any) of the authenticated user making + // the request. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + ThirdPartyPrincipal *structpb.Struct `protobuf:"bytes,4,opt,name=third_party_principal,json=thirdPartyPrincipal,proto3" json:"third_party_principal,omitempty"` + // The name of the service account key used to create or exchange + // credentials for authenticating the service account making the request. + // This is a scheme-less URI full resource name. For example: + // + // "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}" + ServiceAccountKeyName string `protobuf:"bytes,5,opt,name=service_account_key_name,json=serviceAccountKeyName,proto3" json:"service_account_key_name,omitempty"` + // Identity delegation history of an authenticated service account that makes + // the request. It contains information on the real authorities that try to + // access GCP resources by delegating on a service account. When multiple + // authorities present, they are guaranteed to be sorted based on the original + // ordering of the identity delegation events. + ServiceAccountDelegationInfo []*ServiceAccountDelegationInfo `protobuf:"bytes,6,rep,name=service_account_delegation_info,json=serviceAccountDelegationInfo,proto3" json:"service_account_delegation_info,omitempty"` + // String representation of identity of requesting party. + // Populated for both first and third party identities. + PrincipalSubject string `protobuf:"bytes,8,opt,name=principal_subject,json=principalSubject,proto3" json:"principal_subject,omitempty"` } -func (x *AuditEvent) GetObjectIdentifier() *ObjectIdentifier { - if x, ok := x.GetResourceContainerReference().(*AuditEvent_ObjectIdentifier); ok { - return x.ObjectIdentifier +func (x *AuthenticationInfo) Reset() { + *x = AuthenticationInfo{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) } - return nil } -func (x *AuditEvent) GetResourceId() string { - if x != nil && x.ResourceId != nil { - return *x.ResourceId +func (x *AuthenticationInfo) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AuthenticationInfo) ProtoMessage() {} + +func (x *AuthenticationInfo) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[4] + 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 AuthenticationInfo.ProtoReflect.Descriptor instead. +func (*AuthenticationInfo) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{4} +} + +func (x *AuthenticationInfo) GetPrincipalEmail() string { + if x != nil { + return x.PrincipalEmail } return "" } -func (x *AuditEvent) GetResourceName() string { - if x != nil && x.ResourceName != nil { - return *x.ResourceName - } - return "" -} - -func (x *AuditEvent) GetCorrelationId() string { - if x != nil && x.CorrelationId != nil { - return *x.CorrelationId - } - return "" -} - -func (x *AuditEvent) GetResult() *structpb.Struct { +func (x *AuthenticationInfo) GetAuthoritySelector() string { if x != nil { - return x.Result + return x.AuthoritySelector + } + return "" +} + +func (x *AuthenticationInfo) GetThirdPartyPrincipal() *structpb.Struct { + if x != nil { + return x.ThirdPartyPrincipal } return nil } -func (x *AuditEvent) GetDetails() *structpb.Struct { +func (x *AuthenticationInfo) GetServiceAccountKeyName() string { + if x != nil { + return x.ServiceAccountKeyName + } + return "" +} + +func (x *AuthenticationInfo) GetServiceAccountDelegationInfo() []*ServiceAccountDelegationInfo { + if x != nil { + return x.ServiceAccountDelegationInfo + } + return nil +} + +func (x *AuthenticationInfo) GetPrincipalSubject() string { + if x != nil { + return x.PrincipalSubject + } + return "" +} + +// Authorization information for the operation. +type AuthorizationInfo struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The resource being accessed, as a REST-style string. For example: + // + // bigquery.googleapis.com/projects/PROJECTID/datasets/DATASETID + Resource string `protobuf:"bytes,1,opt,name=resource,proto3" json:"resource,omitempty"` + // The required IAM permission. + Permission string `protobuf:"bytes,2,opt,name=permission,proto3" json:"permission,omitempty"` + // Whether or not authorization for `resource` and `permission` + // was granted. + Granted bool `protobuf:"varint,3,opt,name=granted,proto3" json:"granted,omitempty"` + // Resource attributes used in IAM condition evaluation. This field contains + // resource attributes like resource type and resource name. + // + // To get the whole view of the attributes used in IAM + // condition evaluation, the user must also look into + // `AuditLogData.request_metadata.request_attributes`. + ResourceAttributes *AttributeContext_Resource `protobuf:"bytes,5,opt,name=resource_attributes,json=resourceAttributes,proto3" json:"resource_attributes,omitempty"` +} + +func (x *AuthorizationInfo) Reset() { + *x = AuthorizationInfo{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AuthorizationInfo) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AuthorizationInfo) ProtoMessage() {} + +func (x *AuthorizationInfo) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[5] + 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 AuthorizationInfo.ProtoReflect.Descriptor instead. +func (*AuthorizationInfo) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{5} +} + +func (x *AuthorizationInfo) GetResource() string { + if x != nil { + return x.Resource + } + return "" +} + +func (x *AuthorizationInfo) GetPermission() string { + if x != nil { + return x.Permission + } + return "" +} + +func (x *AuthorizationInfo) GetGranted() bool { + if x != nil { + return x.Granted + } + return false +} + +func (x *AuthorizationInfo) GetResourceAttributes() *AttributeContext_Resource { + if x != nil { + return x.ResourceAttributes + } + return nil +} + +// This message defines the standard attribute vocabulary for Google APIs. +// +// An attribute is a piece of metadata that describes an activity on a network +// service. For example, the size of an HTTP request, or the status code of +// an HTTP response. +// +// Each attribute has a type and a name, which is logically defined as +// a proto message field in `AttributeContext`. The field type becomes the +// attribute type, and the field path becomes the attribute name. For example, +// the attribute `source.ip` maps to field `AttributeContext.source.ip`. +// +// This message definition is guaranteed not to have any wire breaking change. +// So you can use it directly for passing attributes across different systems. +// +// NOTE: Different system may generate different subset of attributes. Please +// verify the system specification before relying on an attribute generated +// a system. +type AttributeContext struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *AttributeContext) Reset() { + *x = AttributeContext{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext) ProtoMessage() {} + +func (x *AttributeContext) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[6] + 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 AttributeContext.ProtoReflect.Descriptor instead. +func (*AttributeContext) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6} +} + +// Metadata about the request. +type RequestMetadata struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The IP address of the caller. + // For caller from internet, this will be public IPv4 or IPv6 address. + // For caller from a Compute Engine VM with external IP address, this + // will be the VM's external IP address. For caller from a Compute + // Engine VM without external IP address, if the VM is in the same + // organization (or project) as the accessed resource, `caller_ip` will + // be the VM's internal IPv4 address, otherwise the `caller_ip` will be + // redacted to "gce-internal-ip". + // See https://cloud.google.com/compute/docs/vpc/ for more information. + CallerIp string `protobuf:"bytes,1,opt,name=caller_ip,json=callerIp,proto3" json:"caller_ip,omitempty"` + // The user agent of the caller. + // This information is not authenticated and should be treated accordingly. + // For example: + // + // - `google-api-python-client/1.4.0`: + // The request was made by the Google API client for Python. + // - `Cloud SDK Command Line Tool apitools-client/1.0 gcloud/0.9.62`: + // The request was made by the Google Cloud SDK CLI (gcloud). + // - `AppEngine-Google; (+http://code.google.com/appengine; appid: + // + // s~my-project`: + // + // The request was made from the `my-project` App Engine app. + CallerSuppliedUserAgent string `protobuf:"bytes,2,opt,name=caller_supplied_user_agent,json=callerSuppliedUserAgent,proto3" json:"caller_supplied_user_agent,omitempty"` + // The network of the caller. + // Set only if the network host project is part of the same GCP organization + // (or project) as the accessed resource. + // See https://cloud.google.com/compute/docs/vpc/ for more information. + // This is a scheme-less URI full resource name. For example: + // + // "//compute.googleapis.com/projects/PROJECT_ID/global/networks/NETWORK_ID" + CallerNetwork string `protobuf:"bytes,3,opt,name=caller_network,json=callerNetwork,proto3" json:"caller_network,omitempty"` + // Request attributes used in IAM condition evaluation. This field contains + // request attributes like request time and access levels associated with + // the request. + // + // To get the whole view of the attributes used in IAM + // condition evaluation, the user must also look into + // `AuditLog.authentication_info.resource_attributes`. + RequestAttributes *AttributeContext_Request `protobuf:"bytes,7,opt,name=request_attributes,json=requestAttributes,proto3" json:"request_attributes,omitempty"` + // The destination of a network activity, such as accepting a TCP connection. + // In a multi hop network activity, the destination represents the receiver of + // the last hop. Only two fields are used in this message, Peer.port and + // Peer.ip. These fields are optionally populated by those services utilizing + // the IAM condition feature. + DestinationAttributes *AttributeContext_Peer `protobuf:"bytes,8,opt,name=destination_attributes,json=destinationAttributes,proto3" json:"destination_attributes,omitempty"` +} + +func (x *RequestMetadata) Reset() { + *x = RequestMetadata{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RequestMetadata) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RequestMetadata) ProtoMessage() {} + +func (x *RequestMetadata) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[7] + 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 RequestMetadata.ProtoReflect.Descriptor instead. +func (*RequestMetadata) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{7} +} + +func (x *RequestMetadata) GetCallerIp() string { + if x != nil { + return x.CallerIp + } + return "" +} + +func (x *RequestMetadata) GetCallerSuppliedUserAgent() string { + if x != nil { + return x.CallerSuppliedUserAgent + } + return "" +} + +func (x *RequestMetadata) GetCallerNetwork() string { + if x != nil { + return x.CallerNetwork + } + return "" +} + +func (x *RequestMetadata) GetRequestAttributes() *AttributeContext_Request { + if x != nil { + return x.RequestAttributes + } + return nil +} + +func (x *RequestMetadata) GetDestinationAttributes() *AttributeContext_Peer { + if x != nil { + return x.DestinationAttributes + } + return nil +} + +// Location information about a resource. +type ResourceLocation struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The locations of a resource after the execution of the operation. + // Requests to create or delete a location based resource must populate + // the 'current_locations' field and not the 'original_locations' field. + // For example: + // + // "europe-west1-a" + // "us-east1" + // "nam3" + CurrentLocations []string `protobuf:"bytes,1,rep,name=current_locations,json=currentLocations,proto3" json:"current_locations,omitempty"` + // The locations of a resource prior to the execution of the operation. + // Requests that mutate the resource's location must populate both the + // 'original_locations' as well as the 'current_locations' fields. + // For example: + // + // "europe-west1-a" + // "us-east1" + // "nam3" + OriginalLocations []string `protobuf:"bytes,2,rep,name=original_locations,json=originalLocations,proto3" json:"original_locations,omitempty"` +} + +func (x *ResourceLocation) Reset() { + *x = ResourceLocation{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[8] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ResourceLocation) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ResourceLocation) ProtoMessage() {} + +func (x *ResourceLocation) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[8] + 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 ResourceLocation.ProtoReflect.Descriptor instead. +func (*ResourceLocation) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{8} +} + +func (x *ResourceLocation) GetCurrentLocations() []string { + if x != nil { + return x.CurrentLocations + } + return nil +} + +func (x *ResourceLocation) GetOriginalLocations() []string { + if x != nil { + return x.OriginalLocations + } + return nil +} + +// The `Status` type defines a logical error model that is suitable for +// different programming environments, including REST APIs and RPC APIs. It is +// used by [gRPC](https://github.com/grpc). Each `Status` message contains +// three pieces of data: error code, error message, and error details. +// +// You can find out more about this error model and how to work with it in the +// [API Design Guide](https://cloud.google.com/apis/design/errors). +type RpcStatus struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code]. + Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` + // A developer-facing error message, which should be in English. Any + // user-facing error message should be localized and sent in the + // [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client. + Message string `protobuf:"bytes,2,opt,name=message,proto3" json:"message,omitempty"` + // A list of messages that carry the error details. There is a common set of + // message types for APIs to use. + Details []*anypb.Any `protobuf:"bytes,3,rep,name=details,proto3" json:"details,omitempty"` +} + +func (x *RpcStatus) Reset() { + *x = RpcStatus{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *RpcStatus) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*RpcStatus) ProtoMessage() {} + +func (x *RpcStatus) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[9] + 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 RpcStatus.ProtoReflect.Descriptor instead. +func (*RpcStatus) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{9} +} + +func (x *RpcStatus) GetCode() int32 { + if x != nil { + return x.Code + } + return 0 +} + +func (x *RpcStatus) GetMessage() string { + if x != nil { + return x.Message + } + return "" +} + +func (x *RpcStatus) GetDetails() []*anypb.Any { if x != nil { return x.Details } return nil } -type isAuditEvent_ResourceContainerReference interface { - isAuditEvent_ResourceContainerReference() +// Identity delegation history of an authenticated service account. +type ServiceAccountDelegationInfo struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Entity that creates credentials for service account and assumes its + // identity for authentication. + // + // Types that are assignable to Authority: + // + // *ServiceAccountDelegationInfo_FirstPartyPrincipal_ + // *ServiceAccountDelegationInfo_ThirdPartyPrincipal_ + Authority isServiceAccountDelegationInfo_Authority `protobuf_oneof:"Authority"` } -type AuditEvent_ObjectName struct { - // If it is a technical event not related to an organization, folder or project - // Will NOT be routed to the end-user, only for internal analysis -> - // Clarify what do in the router - ObjectName ObjectName `protobuf:"varint,10,opt,name=object_name,json=objectName,proto3,enum=audit.v1.ObjectName,oneof"` +func (x *ServiceAccountDelegationInfo) Reset() { + *x = ServiceAccountDelegationInfo{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } } -type AuditEvent_ObjectIdentifier struct { - ObjectIdentifier *ObjectIdentifier `protobuf:"bytes,11,opt,name=object_identifier,json=objectIdentifier,proto3,oneof"` +func (x *ServiceAccountDelegationInfo) String() string { + return protoimpl.X.MessageStringOf(x) } -func (*AuditEvent_ObjectName) isAuditEvent_ResourceContainerReference() {} +func (*ServiceAccountDelegationInfo) ProtoMessage() {} -func (*AuditEvent_ObjectIdentifier) isAuditEvent_ResourceContainerReference() {} +func (x *ServiceAccountDelegationInfo) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[10] + 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 ServiceAccountDelegationInfo.ProtoReflect.Descriptor instead. +func (*ServiceAccountDelegationInfo) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{10} +} + +func (m *ServiceAccountDelegationInfo) GetAuthority() isServiceAccountDelegationInfo_Authority { + if m != nil { + return m.Authority + } + return nil +} + +func (x *ServiceAccountDelegationInfo) GetFirstPartyPrincipal() *ServiceAccountDelegationInfo_FirstPartyPrincipal { + if x, ok := x.GetAuthority().(*ServiceAccountDelegationInfo_FirstPartyPrincipal_); ok { + return x.FirstPartyPrincipal + } + return nil +} + +func (x *ServiceAccountDelegationInfo) GetThirdPartyPrincipal() *ServiceAccountDelegationInfo_ThirdPartyPrincipal { + if x, ok := x.GetAuthority().(*ServiceAccountDelegationInfo_ThirdPartyPrincipal_); ok { + return x.ThirdPartyPrincipal + } + return nil +} + +type isServiceAccountDelegationInfo_Authority interface { + isServiceAccountDelegationInfo_Authority() +} + +type ServiceAccountDelegationInfo_FirstPartyPrincipal_ struct { + // First party (Google) identity as the real authority. + FirstPartyPrincipal *ServiceAccountDelegationInfo_FirstPartyPrincipal `protobuf:"bytes,1,opt,name=first_party_principal,json=firstPartyPrincipal,proto3,oneof"` +} + +type ServiceAccountDelegationInfo_ThirdPartyPrincipal_ struct { + // Third party identity as the real authority. + ThirdPartyPrincipal *ServiceAccountDelegationInfo_ThirdPartyPrincipal `protobuf:"bytes,2,opt,name=third_party_principal,json=thirdPartyPrincipal,proto3,oneof"` +} + +func (*ServiceAccountDelegationInfo_FirstPartyPrincipal_) isServiceAccountDelegationInfo_Authority() { +} + +func (*ServiceAccountDelegationInfo_ThirdPartyPrincipal_) isServiceAccountDelegationInfo_Authority() { +} + +// Additional information used to correlate multiple LogEntries. Used when a +// single LogEntry would exceed the Google Cloud Logging size limit and is split +// across multiple entries. +type LogSplit struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // A globally unique identifier for all LogEntries in a sequence of split + // logs. All LogEntries with the same |LogSplit.uid| are assumed to be part of + // the same sequence of split logs. + Uid string `protobuf:"bytes,1,opt,name=uid,proto3" json:"uid,omitempty"` + // The index of this LogEntry in the sequence of split logs. LogEntries are + // given |index| values 0, 1, ..., n-1 for a sequence of n entries. + Index int32 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"` + // The total number of logs that the original LogEntry was split into. + TotalSplits int32 `protobuf:"varint,3,opt,name=total_splits,json=totalSplits,proto3" json:"total_splits,omitempty"` +} + +func (x *LogSplit) Reset() { + *x = LogSplit{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[11] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *LogSplit) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*LogSplit) ProtoMessage() {} + +func (x *LogSplit) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[11] + 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 LogSplit.ProtoReflect.Descriptor instead. +func (*LogSplit) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{11} +} + +func (x *LogSplit) GetUid() string { + if x != nil { + return x.Uid + } + return "" +} + +func (x *LogSplit) GetIndex() int32 { + if x != nil { + return x.Index + } + return 0 +} + +func (x *LogSplit) GetTotalSplits() int32 { + if x != nil { + return x.TotalSplits + } + return 0 +} + +// This message defines attributes for a node that handles a network request. +// The node can be either a service or an application that sends, forwards, +// or receives the request. Service peers should fill in +// `principal` and `labels` as appropriate. +type AttributeContext_Peer struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The IP address of the peer. + Ip string `protobuf:"bytes,1,opt,name=ip,proto3" json:"ip,omitempty"` + // The network port of the peer. + Port int64 `protobuf:"varint,2,opt,name=port,proto3" json:"port,omitempty"` + // The labels associated with the peer. + Labels map[string]string `protobuf:"bytes,6,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + // The identity of this peer. Similar to `Request.auth.principal`, but + // relative to the peer instead of the request. For example, the + // idenity associated with a load balancer that forwared the request. + Principal string `protobuf:"bytes,7,opt,name=principal,proto3" json:"principal,omitempty"` + // The CLDR country/region code associated with the above IP address. + // If the IP address is private, the `region_code` should reflect the + // physical location where this peer is running. + RegionCode string `protobuf:"bytes,8,opt,name=region_code,json=regionCode,proto3" json:"region_code,omitempty"` +} + +func (x *AttributeContext_Peer) Reset() { + *x = AttributeContext_Peer{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[14] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext_Peer) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext_Peer) ProtoMessage() {} + +func (x *AttributeContext_Peer) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[14] + 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 AttributeContext_Peer.ProtoReflect.Descriptor instead. +func (*AttributeContext_Peer) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6, 0} +} + +func (x *AttributeContext_Peer) GetIp() string { + if x != nil { + return x.Ip + } + return "" +} + +func (x *AttributeContext_Peer) GetPort() int64 { + if x != nil { + return x.Port + } + return 0 +} + +func (x *AttributeContext_Peer) GetLabels() map[string]string { + if x != nil { + return x.Labels + } + return nil +} + +func (x *AttributeContext_Peer) GetPrincipal() string { + if x != nil { + return x.Principal + } + return "" +} + +func (x *AttributeContext_Peer) GetRegionCode() string { + if x != nil { + return x.RegionCode + } + return "" +} + +// This message defines request authentication attributes. Terminology is +// based on the JSON Web Token (JWT) standard, but the terms also +// correlate to concepts in other standards. +type AttributeContext_Auth struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The authenticated principal. Reflects the issuer (`iss`) and subject + // (`sub`) claims within a JWT. The issuer and subject should be `/` + // delimited, with `/` percent-encoded within the subject fragment. For + // Google accounts, the principal format is: + // "https://accounts.google.com/{id}" + Principal string `protobuf:"bytes,1,opt,name=principal,proto3" json:"principal,omitempty"` + // The intended audience(s) for this authentication information. Reflects + // the audience (`aud`) claim within a JWT. The audience + // value(s) depends on the `issuer`, but typically include one or more of + // the following pieces of information: + // + // - The services intended to receive the credential such as + // ["pubsub.googleapis.com", "storage.googleapis.com"] + // - A set of service-based scopes. For example, + // ["https://www.googleapis.com/auth/cloud-platform"] + // - The client id of an app, such as the Firebase project id for JWTs + // from Firebase Auth. + // + // Consult the documentation for the credential issuer to determine the + // information provided. + Audiences []string `protobuf:"bytes,2,rep,name=audiences,proto3" json:"audiences,omitempty"` + // The authorized presenter of the credential. Reflects the optional + // Authorized Presenter (`azp`) claim within a JWT or the + // OAuth client id. For example, a Google Cloud Platform client id looks + // as follows: "123456789012.apps.googleusercontent.com". + Presenter string `protobuf:"bytes,3,opt,name=presenter,proto3" json:"presenter,omitempty"` + // Structured claims presented with the credential. JWTs include + // `{key: value}` pairs for standard and private claims. The following + // is a subset of the standard required and optional claims that would + // typically be presented for a Google-based JWT: + // + // {'iss': 'accounts.google.com', + // 'sub': '113289723416554971153', + // 'aud': ['123456789012', 'pubsub.googleapis.com'], + // 'azp': '123456789012.apps.googleusercontent.com', + // 'email': 'jsmith@example.com', + // 'iat': 1353601026, + // 'exp': 1353604926} + // + // SAML assertions are similarly specified, but with an identity provider + // dependent structure. + Claims *structpb.Struct `protobuf:"bytes,4,opt,name=claims,proto3" json:"claims,omitempty"` + // A list of access level resource names that allow resources to be + // accessed by authenticated requester. It is part of Secure GCP processing + // for the incoming request. An access level string has the format: + // "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" + // + // Example: + // "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL" + AccessLevels []string `protobuf:"bytes,5,rep,name=access_levels,json=accessLevels,proto3" json:"access_levels,omitempty"` +} + +func (x *AttributeContext_Auth) Reset() { + *x = AttributeContext_Auth{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[15] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext_Auth) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext_Auth) ProtoMessage() {} + +func (x *AttributeContext_Auth) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[15] + 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 AttributeContext_Auth.ProtoReflect.Descriptor instead. +func (*AttributeContext_Auth) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6, 1} +} + +func (x *AttributeContext_Auth) GetPrincipal() string { + if x != nil { + return x.Principal + } + return "" +} + +func (x *AttributeContext_Auth) GetAudiences() []string { + if x != nil { + return x.Audiences + } + return nil +} + +func (x *AttributeContext_Auth) GetPresenter() string { + if x != nil { + return x.Presenter + } + return "" +} + +func (x *AttributeContext_Auth) GetClaims() *structpb.Struct { + if x != nil { + return x.Claims + } + return nil +} + +func (x *AttributeContext_Auth) GetAccessLevels() []string { + if x != nil { + return x.AccessLevels + } + return nil +} + +// This message defines attributes for an HTTP request. If the actual +// request is not an HTTP request, the runtime system should try to map +// the actual request to an equivalent HTTP request. +type AttributeContext_Request struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The unique ID for a request, which can be propagated to downstream + // systems. The ID should have low probability of collision + // within a single day for a specific service. + Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` + // The HTTP request method, such as `GET`, `POST`. + Method string `protobuf:"bytes,2,opt,name=method,proto3" json:"method,omitempty"` + // The HTTP request headers. If multiple headers share the same key, they + // must be merged according to the HTTP spec. All header keys must be + // lowercased, because HTTP header keys are case-insensitive. + Headers map[string]string `protobuf:"bytes,3,rep,name=headers,proto3" json:"headers,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + // The HTTP URL path. + Path string `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"` + // The HTTP request `Host` header value. + Host string `protobuf:"bytes,5,opt,name=host,proto3" json:"host,omitempty"` + // The HTTP URL scheme, such as `http` and `https`. + Scheme string `protobuf:"bytes,6,opt,name=scheme,proto3" json:"scheme,omitempty"` + // The HTTP URL query in the format of `name1=value1&name2=value2`, as it + // appears in the first line of the HTTP request. No decoding is performed. + Query string `protobuf:"bytes,7,opt,name=query,proto3" json:"query,omitempty"` + // The timestamp when the `destination` service receives the first byte of + // the request. + Time *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=time,proto3" json:"time,omitempty"` + // The HTTP request size in bytes. If unknown, it must be -1. + Size int64 `protobuf:"varint,10,opt,name=size,proto3" json:"size,omitempty"` + // The network protocol used with the request, such as "http/1.1", + // "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic". See + // https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids + // for details. + Protocol string `protobuf:"bytes,11,opt,name=protocol,proto3" json:"protocol,omitempty"` + // A special parameter for request reason. It is used by security systems + // to associate auditing information with a request. + Reason string `protobuf:"bytes,12,opt,name=reason,proto3" json:"reason,omitempty"` + // The request authentication. May be absent for unauthenticated requests. + // Derived from the HTTP request `Authorization` header or equivalent. + Auth *AttributeContext_Auth `protobuf:"bytes,13,opt,name=auth,proto3" json:"auth,omitempty"` +} + +func (x *AttributeContext_Request) Reset() { + *x = AttributeContext_Request{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[16] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext_Request) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext_Request) ProtoMessage() {} + +func (x *AttributeContext_Request) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[16] + 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 AttributeContext_Request.ProtoReflect.Descriptor instead. +func (*AttributeContext_Request) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6, 2} +} + +func (x *AttributeContext_Request) GetId() string { + if x != nil { + return x.Id + } + return "" +} + +func (x *AttributeContext_Request) GetMethod() string { + if x != nil { + return x.Method + } + return "" +} + +func (x *AttributeContext_Request) GetHeaders() map[string]string { + if x != nil { + return x.Headers + } + return nil +} + +func (x *AttributeContext_Request) GetPath() string { + if x != nil { + return x.Path + } + return "" +} + +func (x *AttributeContext_Request) GetHost() string { + if x != nil { + return x.Host + } + return "" +} + +func (x *AttributeContext_Request) GetScheme() string { + if x != nil { + return x.Scheme + } + return "" +} + +func (x *AttributeContext_Request) GetQuery() string { + if x != nil { + return x.Query + } + return "" +} + +func (x *AttributeContext_Request) GetTime() *timestamppb.Timestamp { + if x != nil { + return x.Time + } + return nil +} + +func (x *AttributeContext_Request) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *AttributeContext_Request) GetProtocol() string { + if x != nil { + return x.Protocol + } + return "" +} + +func (x *AttributeContext_Request) GetReason() string { + if x != nil { + return x.Reason + } + return "" +} + +func (x *AttributeContext_Request) GetAuth() *AttributeContext_Auth { + if x != nil { + return x.Auth + } + return nil +} + +// This message defines attributes for a typical network response. It +// generally models semantics of an HTTP response. +type AttributeContext_Response struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The HTTP response status code, such as `200` and `404`. + Code int64 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` + // The HTTP response size in bytes. If unknown, it must be -1. + Size int64 `protobuf:"varint,2,opt,name=size,proto3" json:"size,omitempty"` + // The HTTP response headers. If multiple headers share the same key, they + // must be merged according to HTTP spec. All header keys must be + // lowercased, because HTTP header keys are case-insensitive. + Headers map[string]string `protobuf:"bytes,3,rep,name=headers,proto3" json:"headers,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` + // The timestamp when the `destination` service generates the first byte of + // the response. + Time *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=time,proto3" json:"time,omitempty"` +} + +func (x *AttributeContext_Response) Reset() { + *x = AttributeContext_Response{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[17] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext_Response) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext_Response) ProtoMessage() {} + +func (x *AttributeContext_Response) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[17] + 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 AttributeContext_Response.ProtoReflect.Descriptor instead. +func (*AttributeContext_Response) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6, 3} +} + +func (x *AttributeContext_Response) GetCode() int64 { + if x != nil { + return x.Code + } + return 0 +} + +func (x *AttributeContext_Response) GetSize() int64 { + if x != nil { + return x.Size + } + return 0 +} + +func (x *AttributeContext_Response) GetHeaders() map[string]string { + if x != nil { + return x.Headers + } + return nil +} + +func (x *AttributeContext_Response) GetTime() *timestamppb.Timestamp { + if x != nil { + return x.Time + } + return nil +} + +// This message defines core attributes for a resource. A resource is an +// addressable (named) entity provided by the destination service. For +// example, a file stored on a network storage service. +type AttributeContext_Resource struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The name of the service that this resource belongs to, such as + // `pubsub.googleapis.com`. The service may be different from the DNS + // hostname that actually serves the request. + Service string `protobuf:"bytes,1,opt,name=service,proto3" json:"service,omitempty"` + // The stable identifier (name) of a resource on the `service`. A resource + // can be logically identified as "//{resource.service}/{resource.name}". + // The differences between a resource name and a URI are: + // + // - Resource name is a logical identifier, independent of network + // protocol and API version. For example, + // `//pubsub.googleapis.com/projects/123/topics/news-feed`. + // - URI often includes protocol and version information, so it can + // be used directly by applications. For example, + // `https://pubsub.googleapis.com/v1/projects/123/topics/news-feed`. + // + // See https://cloud.google.com/apis/design/resource_names for details. + Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"` + // The type of the resource. The syntax is platform-specific because + // different platforms define their resources differently. + // + // For Google APIs, the type format must be "{service}/{kind}". + Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"` + // The labels or tags on the resource, such as AWS resource tags and + // Kubernetes resource labels. + Labels map[string]string `protobuf:"bytes,4,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` +} + +func (x *AttributeContext_Resource) Reset() { + *x = AttributeContext_Resource{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[18] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AttributeContext_Resource) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*AttributeContext_Resource) ProtoMessage() {} + +func (x *AttributeContext_Resource) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[18] + 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 AttributeContext_Resource.ProtoReflect.Descriptor instead. +func (*AttributeContext_Resource) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{6, 4} +} + +func (x *AttributeContext_Resource) GetService() string { + if x != nil { + return x.Service + } + return "" +} + +func (x *AttributeContext_Resource) GetName() string { + if x != nil { + return x.Name + } + return "" +} + +func (x *AttributeContext_Resource) GetType() string { + if x != nil { + return x.Type + } + return "" +} + +func (x *AttributeContext_Resource) GetLabels() map[string]string { + if x != nil { + return x.Labels + } + return nil +} + +// First party identity principal. +type ServiceAccountDelegationInfo_FirstPartyPrincipal struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // The email address of a Google account. + PrincipalEmail string `protobuf:"bytes,1,opt,name=principal_email,json=principalEmail,proto3" json:"principal_email,omitempty"` + // Metadata about the service that uses the service account. + ServiceMetadata *structpb.Struct `protobuf:"bytes,2,opt,name=service_metadata,json=serviceMetadata,proto3" json:"service_metadata,omitempty"` +} + +func (x *ServiceAccountDelegationInfo_FirstPartyPrincipal) Reset() { + *x = ServiceAccountDelegationInfo_FirstPartyPrincipal{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[23] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ServiceAccountDelegationInfo_FirstPartyPrincipal) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ServiceAccountDelegationInfo_FirstPartyPrincipal) ProtoMessage() {} + +func (x *ServiceAccountDelegationInfo_FirstPartyPrincipal) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[23] + 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 ServiceAccountDelegationInfo_FirstPartyPrincipal.ProtoReflect.Descriptor instead. +func (*ServiceAccountDelegationInfo_FirstPartyPrincipal) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{10, 0} +} + +func (x *ServiceAccountDelegationInfo_FirstPartyPrincipal) GetPrincipalEmail() string { + if x != nil { + return x.PrincipalEmail + } + return "" +} + +func (x *ServiceAccountDelegationInfo_FirstPartyPrincipal) GetServiceMetadata() *structpb.Struct { + if x != nil { + return x.ServiceMetadata + } + return nil +} + +// Third party identity principal. +type ServiceAccountDelegationInfo_ThirdPartyPrincipal struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Metadata about third party identity. + ThirdPartyClaims *structpb.Struct `protobuf:"bytes,1,opt,name=third_party_claims,json=thirdPartyClaims,proto3" json:"third_party_claims,omitempty"` +} + +func (x *ServiceAccountDelegationInfo_ThirdPartyPrincipal) Reset() { + *x = ServiceAccountDelegationInfo_ThirdPartyPrincipal{} + if protoimpl.UnsafeEnabled { + mi := &file_audit_v1_audit_event_proto_msgTypes[24] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ServiceAccountDelegationInfo_ThirdPartyPrincipal) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ServiceAccountDelegationInfo_ThirdPartyPrincipal) ProtoMessage() {} + +func (x *ServiceAccountDelegationInfo_ThirdPartyPrincipal) ProtoReflect() protoreflect.Message { + mi := &file_audit_v1_audit_event_proto_msgTypes[24] + 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 ServiceAccountDelegationInfo_ThirdPartyPrincipal.ProtoReflect.Descriptor instead. +func (*ServiceAccountDelegationInfo_ThirdPartyPrincipal) Descriptor() ([]byte, []int) { + return file_audit_v1_audit_event_proto_rawDescGZIP(), []int{10, 1} +} + +func (x *ServiceAccountDelegationInfo_ThirdPartyPrincipal) GetThirdPartyClaims() *structpb.Struct { + if x != nil { + return x.ThirdPartyClaims + } + return nil +} var File_audit_v1_audit_event_proto protoreflect.FileDescriptor @@ -542,145 +1967,329 @@ var file_audit_v1_audit_event_proto_rawDesc = []byte{ 0x5f, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x08, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x1a, 0x1b, 0x62, 0x75, 0x66, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x2f, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x61, 0x74, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x1a, 0x1c, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, - 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x1a, 0x1e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x62, 0x75, 0x66, 0x2f, 0x77, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x73, 0x2e, 0x70, 0x72, 0x6f, - 0x74, 0x6f, 0x1a, 0x15, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x63, 0x6f, 0x6d, - 0x6d, 0x6f, 0x6e, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x54, 0x0a, 0x09, 0x50, 0x72, 0x69, - 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x16, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x02, 0x69, 0x64, 0x12, 0x25, - 0x0a, 0x05, 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xba, - 0x48, 0x07, 0x72, 0x05, 0x18, 0xff, 0x01, 0x60, 0x01, 0x48, 0x00, 0x52, 0x05, 0x65, 0x6d, 0x61, - 0x69, 0x6c, 0x88, 0x01, 0x01, 0x42, 0x08, 0x0a, 0x06, 0x5f, 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x22, - 0xf0, 0x02, 0x0a, 0x0e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x44, 0x65, 0x74, 0x61, 0x69, - 0x6c, 0x73, 0x12, 0x29, 0x0a, 0x08, 0x65, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x09, 0x42, 0x0d, 0xba, 0x48, 0x0a, 0xc8, 0x01, 0x01, 0x72, 0x05, 0x10, 0x01, - 0x18, 0xff, 0x01, 0x52, 0x08, 0x65, 0x6e, 0x64, 0x70, 0x6f, 0x69, 0x6e, 0x74, 0x12, 0x36, 0x0a, - 0x11, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, 0x70, 0x5f, 0x61, 0x64, 0x64, 0x72, 0x65, - 0x73, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xba, 0x48, 0x07, 0xc8, 0x01, 0x01, - 0x72, 0x02, 0x70, 0x01, 0x52, 0x0f, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, 0x70, 0x41, 0x64, - 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x31, 0x0a, 0x0a, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x67, - 0x65, 0x6e, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0d, 0xba, 0x48, 0x0a, 0xc8, 0x01, - 0x01, 0x72, 0x05, 0x10, 0x01, 0x18, 0xff, 0x01, 0x48, 0x00, 0x52, 0x09, 0x75, 0x73, 0x65, 0x72, - 0x41, 0x67, 0x65, 0x6e, 0x74, 0x88, 0x01, 0x01, 0x12, 0x3c, 0x0a, 0x0a, 0x70, 0x61, 0x72, 0x61, - 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, + 0x6f, 0x74, 0x6f, 0x1a, 0x19, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x61, 0x6e, 0x79, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1c, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, + 0x73, 0x74, 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x1f, 0x67, 0x6f, + 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, + 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x15, 0x61, + 0x75, 0x64, 0x69, 0x74, 0x2f, 0x76, 0x31, 0x2f, 0x63, 0x6f, 0x6d, 0x6d, 0x6f, 0x6e, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x22, 0xf5, 0x04, 0x0a, 0x0a, 0x41, 0x75, 0x64, 0x69, 0x74, 0x45, 0x76, + 0x65, 0x6e, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x6c, 0x6f, 0x67, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, + 0x0c, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x6c, 0x6f, 0x67, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x37, + 0x0a, 0x08, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x1b, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x4d, 0x6f, 0x6e, 0x69, + 0x74, 0x6f, 0x72, 0x65, 0x64, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x08, 0x72, + 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x37, 0x0a, 0x0d, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x5f, 0x70, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, + 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x75, 0x64, 0x69, 0x74, 0x4c, + 0x6f, 0x67, 0x52, 0x0c, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x61, 0x79, 0x6c, 0x6f, 0x61, 0x64, + 0x12, 0x1b, 0x0a, 0x09, 0x69, 0x6e, 0x73, 0x65, 0x72, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x08, 0x69, 0x6e, 0x73, 0x65, 0x72, 0x74, 0x49, 0x64, 0x12, 0x38, 0x0a, + 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x18, 0x0b, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, + 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x75, 0x64, 0x69, 0x74, 0x45, 0x76, + 0x65, 0x6e, 0x74, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, + 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x12, 0x39, 0x0a, 0x09, 0x6f, 0x70, 0x65, 0x72, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x61, 0x75, 0x64, + 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x4f, 0x70, + 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x09, 0x6f, 0x70, 0x65, 0x72, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x12, 0x38, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, + 0x09, 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, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x47, 0x0a, 0x11, + 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x18, 0x18, 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, 0x10, 0x72, 0x65, 0x63, 0x65, 0x69, 0x76, 0x65, 0x54, 0x69, 0x6d, 0x65, + 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x31, 0x0a, 0x08, 0x73, 0x65, 0x76, 0x65, 0x72, 0x69, 0x74, + 0x79, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x15, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, + 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x53, 0x65, 0x76, 0x65, 0x72, 0x69, 0x74, 0x79, 0x52, 0x08, + 0x73, 0x65, 0x76, 0x65, 0x72, 0x69, 0x74, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x72, 0x61, 0x63, + 0x65, 0x18, 0x16, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x72, 0x61, 0x63, 0x65, 0x12, 0x17, + 0x0a, 0x07, 0x73, 0x70, 0x61, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x1b, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x06, 0x73, 0x70, 0x61, 0x6e, 0x49, 0x64, 0x12, 0x28, 0x0a, 0x05, 0x73, 0x70, 0x6c, 0x69, 0x74, + 0x18, 0x23, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, + 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x53, 0x70, 0x6c, 0x69, 0x74, 0x52, 0x05, 0x73, 0x70, 0x6c, 0x69, + 0x74, 0x1a, 0x39, 0x0a, 0x0b, 0x4c, 0x61, 0x62, 0x65, 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, 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, 0xa3, 0x01, 0x0a, + 0x11, 0x4d, 0x6f, 0x6e, 0x69, 0x74, 0x6f, 0x72, 0x65, 0x64, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, + 0x63, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x3f, 0x0a, 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x73, + 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, + 0x31, 0x2e, 0x4d, 0x6f, 0x6e, 0x69, 0x74, 0x6f, 0x72, 0x65, 0x64, 0x52, 0x65, 0x73, 0x6f, 0x75, + 0x72, 0x63, 0x65, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, + 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x1a, 0x39, 0x0a, 0x0b, 0x4c, 0x61, 0x62, 0x65, 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, 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, 0x69, 0x0a, 0x11, 0x4c, 0x6f, 0x67, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x4f, 0x70, + 0x65, 0x72, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x64, 0x75, + 0x63, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x64, 0x75, + 0x63, 0x65, 0x72, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x69, 0x72, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x08, 0x52, 0x05, 0x66, 0x69, 0x72, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6c, 0x61, 0x73, + 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x04, 0x6c, 0x61, 0x73, 0x74, 0x22, 0xa2, 0x06, + 0x0a, 0x08, 0x41, 0x75, 0x64, 0x69, 0x74, 0x4c, 0x6f, 0x67, 0x12, 0x21, 0x0a, 0x0c, 0x73, 0x65, + 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, + 0x0b, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x08, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0a, 0x6d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x23, + 0x0a, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, + 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0c, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x4e, + 0x61, 0x6d, 0x65, 0x12, 0x47, 0x0a, 0x11, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, + 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, + 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, + 0x63, 0x65, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x10, 0x72, 0x65, 0x73, 0x6f, + 0x75, 0x72, 0x63, 0x65, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x12, 0x4f, 0x0a, 0x17, + 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, + 0x6c, 0x5f, 0x73, 0x74, 0x61, 0x74, 0x65, 0x18, 0x13, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, + 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, + 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x15, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, + 0x4f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x53, 0x74, 0x61, 0x74, 0x65, 0x12, 0x2c, 0x0a, + 0x12, 0x6e, 0x75, 0x6d, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f, 0x69, 0x74, + 0x65, 0x6d, 0x73, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x03, 0x52, 0x10, 0x6e, 0x75, 0x6d, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x73, 0x12, 0x2b, 0x0a, 0x06, 0x73, + 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x61, 0x75, + 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x70, 0x63, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, + 0x52, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x4d, 0x0a, 0x13, 0x61, 0x75, 0x74, 0x68, + 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x66, 0x6f, 0x18, + 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1c, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, + 0x2e, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x6e, 0x66, 0x6f, 0x52, 0x12, 0x61, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x4a, 0x0a, 0x12, 0x61, 0x75, 0x74, 0x68, 0x6f, + 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x09, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, + 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, + 0x52, 0x11, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, + 0x6e, 0x66, 0x6f, 0x12, 0x44, 0x0a, 0x10, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x6d, + 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x19, 0x2e, + 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x52, 0x0f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x31, 0x0a, 0x07, 0x72, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x18, 0x10, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, + 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, + 0x75, 0x63, 0x74, 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x33, 0x0a, 0x08, + 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, + 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, + 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x08, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x33, 0x0a, 0x08, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x12, 0x20, + 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, + 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x08, 0x6d, 0x65, + 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x12, 0x3a, 0x0a, 0x0c, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, - 0x74, 0x72, 0x75, 0x63, 0x74, 0x48, 0x01, 0x52, 0x0a, 0x70, 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, - 0x65, 0x72, 0x73, 0x88, 0x01, 0x01, 0x12, 0x30, 0x0a, 0x04, 0x62, 0x6f, 0x64, 0x79, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x48, 0x02, 0x52, - 0x04, 0x62, 0x6f, 0x64, 0x79, 0x88, 0x01, 0x01, 0x12, 0x31, 0x0a, 0x07, 0x68, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x61, 0x75, 0x64, 0x69, - 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x48, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x52, 0x07, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, - 0x75, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x67, 0x65, 0x6e, 0x74, 0x42, 0x0d, 0x0a, 0x0b, 0x5f, 0x70, - 0x61, 0x72, 0x61, 0x6d, 0x65, 0x74, 0x65, 0x72, 0x73, 0x42, 0x07, 0x0a, 0x05, 0x5f, 0x62, 0x6f, - 0x64, 0x79, 0x22, 0x4f, 0x0a, 0x0d, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x48, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, - 0x42, 0x0a, 0xba, 0x48, 0x07, 0xc8, 0x01, 0x01, 0x72, 0x02, 0x10, 0x01, 0x52, 0x03, 0x6b, 0x65, - 0x79, 0x12, 0x20, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x42, 0x0a, 0xba, 0x48, 0x07, 0xc8, 0x01, 0x01, 0x72, 0x02, 0x10, 0x01, 0x52, 0x05, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x22, 0xd7, 0x09, 0x0a, 0x0a, 0x41, 0x75, 0x64, 0x69, 0x74, 0x45, 0x76, 0x65, - 0x6e, 0x74, 0x12, 0x2d, 0x0a, 0x0c, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x5f, 0x73, 0x6f, 0x75, 0x72, - 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xba, 0x48, 0x07, 0xc8, 0x01, 0x01, - 0x72, 0x02, 0x10, 0x01, 0x52, 0x0b, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x53, 0x6f, 0x75, 0x72, 0x63, - 0x65, 0x12, 0x30, 0x0a, 0x06, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0e, 0x32, 0x10, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x67, - 0x69, 0x6f, 0x6e, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x06, 0x72, 0x65, 0x67, - 0x69, 0x6f, 0x6e, 0x12, 0x59, 0x0a, 0x0f, 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x5f, - 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x67, - 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x49, - 0x6e, 0x74, 0x36, 0x34, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x42, 0x13, 0xba, 0x48, 0x10, 0xc8, 0x01, - 0x01, 0x22, 0x0b, 0x28, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x01, 0x52, 0x0e, - 0x73, 0x65, 0x71, 0x75, 0x65, 0x6e, 0x63, 0x65, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x38, - 0x0a, 0x0a, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x19, 0xba, 0x48, 0x16, 0xc8, 0x01, 0x01, 0x72, 0x11, 0x32, 0x0f, 0x5e, 0x5b, - 0x41, 0x2d, 0x5a, 0x5d, 0x2b, 0x5f, 0x5b, 0x41, 0x2d, 0x5a, 0x5d, 0x2b, 0x24, 0x52, 0x09, 0x65, - 0x76, 0x65, 0x6e, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x51, 0x0a, 0x10, 0x65, 0x76, 0x65, 0x6e, - 0x74, 0x5f, 0x74, 0x69, 0x6d, 0x65, 0x5f, 0x73, 0x74, 0x61, 0x6d, 0x70, 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, 0x42, 0x0b, - 0xba, 0x48, 0x08, 0xc8, 0x01, 0x01, 0xb2, 0x01, 0x02, 0x38, 0x01, 0x52, 0x0e, 0x65, 0x76, 0x65, - 0x6e, 0x74, 0x54, 0x69, 0x6d, 0x65, 0x53, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x48, 0x0a, 0x0d, 0x65, - 0x76, 0x65, 0x6e, 0x74, 0x5f, 0x74, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x18, 0x06, 0x20, 0x01, - 0x28, 0x0e, 0x32, 0x16, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x45, 0x76, - 0x65, 0x6e, 0x74, 0x54, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x42, 0x0b, 0xba, 0x48, 0x08, 0xc8, - 0x01, 0x01, 0x82, 0x01, 0x02, 0x10, 0x01, 0x52, 0x0c, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x54, 0x72, - 0x69, 0x67, 0x67, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, - 0x31, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, - 0x48, 0x01, 0x52, 0x07, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x88, 0x01, 0x01, 0x12, 0x39, - 0x0a, 0x09, 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x18, 0x08, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x13, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x69, - 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x42, 0x06, 0xba, 0x48, 0x03, 0xc8, 0x01, 0x01, 0x52, 0x09, - 0x69, 0x6e, 0x69, 0x74, 0x69, 0x61, 0x74, 0x6f, 0x72, 0x12, 0x33, 0x0a, 0x0a, 0x70, 0x72, 0x69, - 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x73, 0x18, 0x09, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x13, 0x2e, - 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, - 0x61, 0x6c, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x73, 0x12, 0x37, - 0x0a, 0x0b, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0a, 0x20, - 0x01, 0x28, 0x0e, 0x32, 0x14, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x4f, - 0x62, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x48, 0x00, 0x52, 0x0a, 0x6f, 0x62, 0x6a, - 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x49, 0x0a, 0x11, 0x6f, 0x62, 0x6a, 0x65, 0x63, - 0x74, 0x5f, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x18, 0x0b, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x4f, 0x62, - 0x6a, 0x65, 0x63, 0x74, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, 0x65, 0x72, 0x48, 0x00, - 0x52, 0x10, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x66, 0x69, - 0x65, 0x72, 0x12, 0x30, 0x0a, 0x0b, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, - 0x64, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xba, 0x48, 0x07, 0x72, 0x05, 0x10, 0x01, - 0x18, 0xff, 0x01, 0x48, 0x02, 0x52, 0x0a, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x49, - 0x64, 0x88, 0x01, 0x01, 0x12, 0x34, 0x0a, 0x0d, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, - 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x42, 0x0a, 0xba, 0x48, 0x07, - 0x72, 0x05, 0x10, 0x01, 0x18, 0xff, 0x01, 0x48, 0x03, 0x52, 0x0c, 0x72, 0x65, 0x73, 0x6f, 0x75, - 0x72, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x88, 0x01, 0x01, 0x12, 0x36, 0x0a, 0x0e, 0x63, 0x6f, - 0x72, 0x72, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x18, 0x0e, 0x20, 0x01, - 0x28, 0x09, 0x42, 0x0a, 0xba, 0x48, 0x07, 0x72, 0x05, 0x10, 0x01, 0x18, 0xff, 0x01, 0x48, 0x04, - 0x52, 0x0d, 0x63, 0x6f, 0x72, 0x72, 0x65, 0x6c, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x64, 0x88, - 0x01, 0x01, 0x12, 0x34, 0x0a, 0x06, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x18, 0x0f, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, - 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x48, 0x05, 0x52, 0x06, 0x72, - 0x65, 0x73, 0x75, 0x6c, 0x74, 0x88, 0x01, 0x01, 0x12, 0x36, 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61, - 0x69, 0x6c, 0x73, 0x18, 0x10, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x44, 0x61, + 0x74, 0x61, 0x22, 0x8e, 0x03, 0x0a, 0x12, 0x41, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x27, 0x0a, 0x0f, 0x70, 0x72, 0x69, + 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x5f, 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0e, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x45, 0x6d, 0x61, + 0x69, 0x6c, 0x12, 0x2d, 0x0a, 0x12, 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x5f, + 0x73, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x11, + 0x61, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x53, 0x65, 0x6c, 0x65, 0x63, 0x74, 0x6f, + 0x72, 0x12, 0x4b, 0x0a, 0x15, 0x74, 0x68, 0x69, 0x72, 0x64, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x79, + 0x5f, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, + 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x13, 0x74, 0x68, 0x69, 0x72, 0x64, + 0x50, 0x61, 0x72, 0x74, 0x79, 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x37, + 0x0a, 0x18, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, + 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x15, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, + 0x4b, 0x65, 0x79, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x6d, 0x0a, 0x1f, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x5f, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x67, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x6e, 0x66, 0x6f, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x26, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x72, 0x76, + 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x52, 0x1c, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x69, + 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x2b, 0x0a, 0x11, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, + 0x70, 0x61, 0x6c, 0x5f, 0x73, 0x75, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x08, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x10, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x53, 0x75, 0x62, 0x6a, + 0x65, 0x63, 0x74, 0x22, 0xbf, 0x01, 0x0a, 0x11, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x7a, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x1a, 0x0a, 0x08, 0x72, 0x65, 0x73, + 0x6f, 0x75, 0x72, 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x72, 0x65, 0x73, + 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x1e, 0x0a, 0x0a, 0x70, 0x65, 0x72, 0x6d, 0x69, 0x73, 0x73, + 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x65, 0x72, 0x6d, 0x69, + 0x73, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, + 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x67, 0x72, 0x61, 0x6e, 0x74, 0x65, 0x64, 0x12, + 0x54, 0x0a, 0x13, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x61, 0x74, 0x74, 0x72, + 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x23, 0x2e, 0x61, + 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, + 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, + 0x65, 0x52, 0x12, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0xb5, 0x0a, 0x0a, 0x10, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x1a, 0xe9, 0x01, 0x0a, 0x04, 0x50, + 0x65, 0x65, 0x72, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x02, 0x69, 0x70, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, + 0x03, 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x43, 0x0a, 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, + 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2b, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, + 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, + 0x65, 0x78, 0x74, 0x2e, 0x50, 0x65, 0x65, 0x72, 0x2e, 0x4c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x45, + 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x6c, 0x61, 0x62, 0x65, 0x6c, 0x73, 0x12, 0x1c, 0x0a, 0x09, + 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x09, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, + 0x67, 0x69, 0x6f, 0x6e, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0a, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x43, 0x6f, 0x64, 0x65, 0x1a, 0x39, 0x0a, 0x0b, 0x4c, + 0x61, 0x62, 0x65, 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, 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, 0xb6, 0x01, 0x0a, 0x04, 0x41, 0x75, 0x74, 0x68, 0x12, + 0x1c, 0x0a, 0x09, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x09, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x1c, 0x0a, + 0x09, 0x61, 0x75, 0x64, 0x69, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, + 0x52, 0x09, 0x61, 0x75, 0x64, 0x69, 0x65, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x1c, 0x0a, 0x09, 0x70, + 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, + 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x65, 0x72, 0x12, 0x2f, 0x0a, 0x06, 0x63, 0x6c, 0x61, + 0x69, 0x6d, 0x73, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, - 0x63, 0x74, 0x48, 0x06, 0x52, 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x88, 0x01, 0x01, - 0x3a, 0x7c, 0xba, 0x48, 0x79, 0x1a, 0x77, 0x0a, 0x0f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, - 0x2e, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x12, 0x1b, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x20, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x20, 0x6d, 0x75, 0x73, 0x74, 0x20, 0x62, - 0x65, 0x20, 0x73, 0x65, 0x74, 0x1a, 0x47, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, - 0x74, 0x5f, 0x74, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x20, 0x3d, 0x3d, 0x20, 0x33, 0x20, 0x26, - 0x26, 0x20, 0x68, 0x61, 0x73, 0x28, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x72, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x29, 0x20, 0x7c, 0x7c, 0x20, 0x74, 0x68, 0x69, 0x73, 0x2e, 0x65, 0x76, 0x65, 0x6e, - 0x74, 0x5f, 0x74, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x20, 0x21, 0x3d, 0x20, 0x33, 0x42, 0x25, - 0x0a, 0x1c, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x61, - 0x69, 0x6e, 0x65, 0x72, 0x5f, 0x72, 0x65, 0x66, 0x65, 0x72, 0x65, 0x6e, 0x63, 0x65, 0x12, 0x05, - 0xba, 0x48, 0x02, 0x08, 0x01, 0x42, 0x0a, 0x0a, 0x08, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x42, 0x0e, 0x0a, 0x0c, 0x5f, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x69, - 0x64, 0x42, 0x10, 0x0a, 0x0e, 0x5f, 0x72, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x5f, 0x6e, - 0x61, 0x6d, 0x65, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x63, 0x6f, 0x72, 0x72, 0x65, 0x6c, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x5f, 0x69, 0x64, 0x42, 0x09, 0x0a, 0x07, 0x5f, 0x72, 0x65, 0x73, 0x75, 0x6c, - 0x74, 0x42, 0x0a, 0x0a, 0x08, 0x5f, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x2a, 0x7e, 0x0a, - 0x0c, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x54, 0x72, 0x69, 0x67, 0x67, 0x65, 0x72, 0x12, 0x1d, 0x0a, - 0x19, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x5f, 0x54, 0x52, 0x49, 0x47, 0x47, 0x45, 0x52, 0x5f, 0x55, - 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x17, 0x0a, 0x13, - 0x45, 0x56, 0x45, 0x4e, 0x54, 0x5f, 0x54, 0x52, 0x49, 0x47, 0x47, 0x45, 0x52, 0x5f, 0x45, 0x56, - 0x45, 0x4e, 0x54, 0x10, 0x01, 0x12, 0x1b, 0x0a, 0x17, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x5f, 0x54, - 0x52, 0x49, 0x47, 0x47, 0x45, 0x52, 0x5f, 0x53, 0x43, 0x48, 0x45, 0x44, 0x55, 0x4c, 0x45, 0x52, - 0x10, 0x02, 0x12, 0x19, 0x0a, 0x15, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x5f, 0x54, 0x52, 0x49, 0x47, - 0x47, 0x45, 0x52, 0x5f, 0x52, 0x45, 0x51, 0x55, 0x45, 0x53, 0x54, 0x10, 0x03, 0x2a, 0x31, 0x0a, - 0x06, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x12, 0x16, 0x0a, 0x12, 0x52, 0x45, 0x47, 0x49, 0x4f, - 0x4e, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, - 0x0f, 0x0a, 0x0b, 0x52, 0x45, 0x47, 0x49, 0x4f, 0x4e, 0x5f, 0x45, 0x55, 0x30, 0x31, 0x10, 0x01, - 0x42, 0x81, 0x01, 0x0a, 0x1c, 0x63, 0x6f, 0x6d, 0x2e, 0x73, 0x63, 0x68, 0x77, 0x61, 0x72, 0x7a, - 0x2e, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x69, 0x74, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, - 0x31, 0x42, 0x0f, 0x41, 0x75, 0x64, 0x69, 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x50, 0x72, 0x6f, - 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0f, 0x2e, 0x2f, 0x61, 0x75, 0x64, 0x69, 0x74, 0x3b, 0x61, 0x75, - 0x64, 0x69, 0x74, 0x56, 0x31, 0xa2, 0x02, 0x03, 0x41, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x41, 0x75, - 0x64, 0x69, 0x74, 0x2e, 0x56, 0x31, 0xca, 0x02, 0x08, 0x41, 0x75, 0x64, 0x69, 0x74, 0x5c, 0x56, - 0x31, 0xe2, 0x02, 0x14, 0x41, 0x75, 0x64, 0x69, 0x74, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, - 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0xea, 0x02, 0x09, 0x41, 0x75, 0x64, 0x69, 0x74, - 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x74, 0x52, 0x06, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x61, 0x63, + 0x63, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x73, 0x18, 0x05, 0x20, 0x03, 0x28, + 0x09, 0x52, 0x0c, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x73, 0x1a, + 0xbb, 0x03, 0x0a, 0x07, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, + 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x16, 0x0a, 0x06, 0x6d, + 0x65, 0x74, 0x68, 0x6f, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6d, 0x65, 0x74, + 0x68, 0x6f, 0x64, 0x12, 0x49, 0x0a, 0x07, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x03, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, + 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, + 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, + 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x12, 0x12, + 0x0a, 0x04, 0x70, 0x61, 0x74, 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x61, + 0x74, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x6f, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, + 0x52, 0x04, 0x68, 0x6f, 0x73, 0x74, 0x12, 0x16, 0x0a, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x65, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x73, 0x63, 0x68, 0x65, 0x6d, 0x65, 0x12, 0x14, + 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x12, 0x2e, 0x0a, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x09, 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, + 0x74, 0x69, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x0a, 0x20, 0x01, + 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x63, 0x6f, 0x6c, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x74, + 0x6f, 0x63, 0x6f, 0x6c, 0x12, 0x16, 0x0a, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x18, 0x0c, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x33, 0x0a, 0x04, + 0x61, 0x75, 0x74, 0x68, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x61, 0x75, 0x64, + 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, + 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x41, 0x75, 0x74, 0x68, 0x52, 0x04, 0x61, 0x75, 0x74, + 0x68, 0x1a, 0x3a, 0x0a, 0x0c, 0x48, 0x65, 0x61, 0x64, 0x65, 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, 0x1a, 0xea, 0x01, + 0x0a, 0x08, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, + 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x12, + 0x0a, 0x04, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x52, 0x04, 0x73, 0x69, + 0x7a, 0x65, 0x12, 0x4a, 0x0a, 0x07, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x18, 0x03, 0x20, + 0x03, 0x28, 0x0b, 0x32, 0x30, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, + 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x2e, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, + 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x07, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x73, 0x12, 0x2e, + 0x0a, 0x04, 0x74, 0x69, 0x6d, 0x65, 0x18, 0x04, 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, 0x74, 0x69, 0x6d, 0x65, 0x1a, 0x3a, + 0x0a, 0x0c, 0x48, 0x65, 0x61, 0x64, 0x65, 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, 0x1a, 0xd0, 0x01, 0x0a, 0x08, 0x52, + 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, + 0x65, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x47, 0x0a, 0x06, 0x6c, 0x61, 0x62, + 0x65, 0x6c, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x61, 0x75, 0x64, 0x69, + 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6f, + 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x2e, 0x4c, + 0x61, 0x62, 0x65, 0x6c, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, 0x06, 0x6c, 0x61, 0x62, 0x65, + 0x6c, 0x73, 0x1a, 0x39, 0x0a, 0x0b, 0x4c, 0x61, 0x62, 0x65, 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, 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, 0xbd, 0x02, + 0x0a, 0x0f, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0x12, 0x1b, 0x0a, 0x09, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x5f, 0x69, 0x70, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x49, 0x70, 0x12, 0x3b, + 0x0a, 0x1a, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x5f, 0x73, 0x75, 0x70, 0x70, 0x6c, 0x69, 0x65, + 0x64, 0x5f, 0x75, 0x73, 0x65, 0x72, 0x5f, 0x61, 0x67, 0x65, 0x6e, 0x74, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x17, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x53, 0x75, 0x70, 0x70, 0x6c, 0x69, + 0x65, 0x64, 0x55, 0x73, 0x65, 0x72, 0x41, 0x67, 0x65, 0x6e, 0x74, 0x12, 0x25, 0x0a, 0x0e, 0x63, + 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x5f, 0x6e, 0x65, 0x74, 0x77, 0x6f, 0x72, 0x6b, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x09, 0x52, 0x0d, 0x63, 0x61, 0x6c, 0x6c, 0x65, 0x72, 0x4e, 0x65, 0x74, 0x77, 0x6f, + 0x72, 0x6b, 0x12, 0x51, 0x0a, 0x12, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x61, 0x74, + 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x22, + 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, + 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x2e, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x52, 0x11, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x41, 0x74, 0x74, 0x72, 0x69, + 0x62, 0x75, 0x74, 0x65, 0x73, 0x12, 0x56, 0x0a, 0x16, 0x64, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x61, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x18, + 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, + 0x2e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, + 0x74, 0x2e, 0x50, 0x65, 0x65, 0x72, 0x52, 0x15, 0x64, 0x65, 0x73, 0x74, 0x69, 0x6e, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x41, 0x74, 0x74, 0x72, 0x69, 0x62, 0x75, 0x74, 0x65, 0x73, 0x22, 0x6e, 0x0a, + 0x10, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, + 0x6e, 0x12, 0x2b, 0x0a, 0x11, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x6c, 0x6f, 0x63, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x09, 0x52, 0x10, 0x63, 0x75, + 0x72, 0x72, 0x65, 0x6e, 0x74, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12, 0x2d, + 0x0a, 0x12, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x61, 0x6c, 0x5f, 0x6c, 0x6f, 0x63, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x11, 0x6f, 0x72, 0x69, 0x67, + 0x69, 0x6e, 0x61, 0x6c, 0x4c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x22, 0x69, 0x0a, + 0x09, 0x52, 0x70, 0x63, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x63, 0x6f, + 0x64, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x04, 0x63, 0x6f, 0x64, 0x65, 0x12, 0x18, + 0x0a, 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x07, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x2e, 0x0a, 0x07, 0x64, 0x65, 0x74, 0x61, + 0x69, 0x6c, 0x73, 0x18, 0x03, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x14, 0x2e, 0x67, 0x6f, 0x6f, 0x67, + 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x41, 0x6e, 0x79, 0x52, + 0x07, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x73, 0x22, 0xf2, 0x03, 0x0a, 0x1c, 0x53, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x44, 0x65, 0x6c, 0x65, 0x67, + 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, 0x12, 0x70, 0x0a, 0x15, 0x66, 0x69, 0x72, + 0x73, 0x74, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, + 0x61, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x3a, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, + 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, + 0x6e, 0x74, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, 0x66, 0x6f, + 0x2e, 0x46, 0x69, 0x72, 0x73, 0x74, 0x50, 0x61, 0x72, 0x74, 0x79, 0x50, 0x72, 0x69, 0x6e, 0x63, + 0x69, 0x70, 0x61, 0x6c, 0x48, 0x00, 0x52, 0x13, 0x66, 0x69, 0x72, 0x73, 0x74, 0x50, 0x61, 0x72, + 0x74, 0x79, 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x70, 0x0a, 0x15, 0x74, + 0x68, 0x69, 0x72, 0x64, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x79, 0x5f, 0x70, 0x72, 0x69, 0x6e, 0x63, + 0x69, 0x70, 0x61, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x3a, 0x2e, 0x61, 0x75, 0x64, + 0x69, 0x74, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x41, 0x63, 0x63, + 0x6f, 0x75, 0x6e, 0x74, 0x44, 0x65, 0x6c, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x49, 0x6e, + 0x66, 0x6f, 0x2e, 0x54, 0x68, 0x69, 0x72, 0x64, 0x50, 0x61, 0x72, 0x74, 0x79, 0x50, 0x72, 0x69, + 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x48, 0x00, 0x52, 0x13, 0x74, 0x68, 0x69, 0x72, 0x64, 0x50, + 0x61, 0x72, 0x74, 0x79, 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x1a, 0x82, 0x01, + 0x0a, 0x13, 0x46, 0x69, 0x72, 0x73, 0x74, 0x50, 0x61, 0x72, 0x74, 0x79, 0x50, 0x72, 0x69, 0x6e, + 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x27, 0x0a, 0x0f, 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, + 0x61, 0x6c, 0x5f, 0x65, 0x6d, 0x61, 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, + 0x70, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x45, 0x6d, 0x61, 0x69, 0x6c, 0x12, 0x42, + 0x0a, 0x10, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, + 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, + 0x74, 0x52, 0x0f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, + 0x74, 0x61, 0x1a, 0x5c, 0x0a, 0x13, 0x54, 0x68, 0x69, 0x72, 0x64, 0x50, 0x61, 0x72, 0x74, 0x79, + 0x50, 0x72, 0x69, 0x6e, 0x63, 0x69, 0x70, 0x61, 0x6c, 0x12, 0x45, 0x0a, 0x12, 0x74, 0x68, 0x69, + 0x72, 0x64, 0x5f, 0x70, 0x61, 0x72, 0x74, 0x79, 0x5f, 0x63, 0x6c, 0x61, 0x69, 0x6d, 0x73, 0x18, + 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x10, + 0x74, 0x68, 0x69, 0x72, 0x64, 0x50, 0x61, 0x72, 0x74, 0x79, 0x43, 0x6c, 0x61, 0x69, 0x6d, 0x73, + 0x42, 0x0b, 0x0a, 0x09, 0x41, 0x75, 0x74, 0x68, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x22, 0x55, 0x0a, + 0x08, 0x4c, 0x6f, 0x67, 0x53, 0x70, 0x6c, 0x69, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x75, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x75, 0x69, 0x64, 0x12, 0x14, 0x0a, 0x05, 0x69, + 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x05, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, + 0x78, 0x12, 0x21, 0x0a, 0x0c, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x73, 0x70, 0x6c, 0x69, 0x74, + 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x53, 0x70, + 0x6c, 0x69, 0x74, 0x73, 0x2a, 0x82, 0x01, 0x0a, 0x0b, 0x4c, 0x6f, 0x67, 0x53, 0x65, 0x76, 0x65, + 0x72, 0x69, 0x74, 0x79, 0x12, 0x0b, 0x0a, 0x07, 0x44, 0x45, 0x46, 0x41, 0x55, 0x4c, 0x54, 0x10, + 0x00, 0x12, 0x09, 0x0a, 0x05, 0x44, 0x45, 0x42, 0x55, 0x47, 0x10, 0x64, 0x12, 0x09, 0x0a, 0x04, + 0x49, 0x4e, 0x46, 0x4f, 0x10, 0xc8, 0x01, 0x12, 0x0b, 0x0a, 0x06, 0x4e, 0x4f, 0x54, 0x49, 0x43, + 0x45, 0x10, 0xac, 0x02, 0x12, 0x0c, 0x0a, 0x07, 0x57, 0x41, 0x52, 0x4e, 0x49, 0x4e, 0x47, 0x10, + 0x90, 0x03, 0x12, 0x0a, 0x0a, 0x05, 0x45, 0x52, 0x52, 0x4f, 0x52, 0x10, 0xf4, 0x03, 0x12, 0x0d, + 0x0a, 0x08, 0x43, 0x52, 0x49, 0x54, 0x49, 0x43, 0x41, 0x4c, 0x10, 0xd8, 0x04, 0x12, 0x0a, 0x0a, + 0x05, 0x41, 0x4c, 0x45, 0x52, 0x54, 0x10, 0xbc, 0x05, 0x12, 0x0e, 0x0a, 0x09, 0x45, 0x4d, 0x45, + 0x52, 0x47, 0x45, 0x4e, 0x43, 0x59, 0x10, 0xa0, 0x06, 0x42, 0x81, 0x01, 0x0a, 0x1c, 0x63, 0x6f, + 0x6d, 0x2e, 0x73, 0x63, 0x68, 0x77, 0x61, 0x72, 0x7a, 0x2e, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x69, + 0x74, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x76, 0x31, 0x42, 0x0f, 0x41, 0x75, 0x64, 0x69, + 0x74, 0x45, 0x76, 0x65, 0x6e, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x0f, 0x2e, + 0x2f, 0x61, 0x75, 0x64, 0x69, 0x74, 0x3b, 0x61, 0x75, 0x64, 0x69, 0x74, 0x56, 0x31, 0xa2, 0x02, + 0x03, 0x41, 0x58, 0x58, 0xaa, 0x02, 0x08, 0x41, 0x75, 0x64, 0x69, 0x74, 0x2e, 0x56, 0x31, 0xca, + 0x02, 0x08, 0x41, 0x75, 0x64, 0x69, 0x74, 0x5c, 0x56, 0x31, 0xe2, 0x02, 0x14, 0x41, 0x75, 0x64, + 0x69, 0x74, 0x5c, 0x56, 0x31, 0x5c, 0x47, 0x50, 0x42, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, + 0x61, 0xea, 0x02, 0x09, 0x41, 0x75, 0x64, 0x69, 0x74, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, + 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -695,41 +2304,82 @@ func file_audit_v1_audit_event_proto_rawDescGZIP() []byte { return file_audit_v1_audit_event_proto_rawDescData } -var file_audit_v1_audit_event_proto_enumTypes = make([]protoimpl.EnumInfo, 2) -var file_audit_v1_audit_event_proto_msgTypes = make([]protoimpl.MessageInfo, 4) +var file_audit_v1_audit_event_proto_enumTypes = make([]protoimpl.EnumInfo, 1) +var file_audit_v1_audit_event_proto_msgTypes = make([]protoimpl.MessageInfo, 25) var file_audit_v1_audit_event_proto_goTypes = []interface{}{ - (EventTrigger)(0), // 0: audit.v1.EventTrigger - (Region)(0), // 1: audit.v1.Region - (*Principal)(nil), // 2: audit.v1.Principal - (*RequestDetails)(nil), // 3: audit.v1.RequestDetails - (*RequestHeader)(nil), // 4: audit.v1.RequestHeader - (*AuditEvent)(nil), // 5: audit.v1.AuditEvent - (*structpb.Struct)(nil), // 6: google.protobuf.Struct - (*wrapperspb.Int64Value)(nil), // 7: google.protobuf.Int64Value - (*timestamppb.Timestamp)(nil), // 8: google.protobuf.Timestamp - (ObjectName)(0), // 9: audit.v1.ObjectName - (*ObjectIdentifier)(nil), // 10: audit.v1.ObjectIdentifier + (LogSeverity)(0), // 0: audit.v1.LogSeverity + (*AuditEvent)(nil), // 1: audit.v1.AuditEvent + (*MonitoredResource)(nil), // 2: audit.v1.MonitoredResource + (*LogEntryOperation)(nil), // 3: audit.v1.LogEntryOperation + (*AuditLog)(nil), // 4: audit.v1.AuditLog + (*AuthenticationInfo)(nil), // 5: audit.v1.AuthenticationInfo + (*AuthorizationInfo)(nil), // 6: audit.v1.AuthorizationInfo + (*AttributeContext)(nil), // 7: audit.v1.AttributeContext + (*RequestMetadata)(nil), // 8: audit.v1.RequestMetadata + (*ResourceLocation)(nil), // 9: audit.v1.ResourceLocation + (*RpcStatus)(nil), // 10: audit.v1.RpcStatus + (*ServiceAccountDelegationInfo)(nil), // 11: audit.v1.ServiceAccountDelegationInfo + (*LogSplit)(nil), // 12: audit.v1.LogSplit + nil, // 13: audit.v1.AuditEvent.LabelsEntry + nil, // 14: audit.v1.MonitoredResource.LabelsEntry + (*AttributeContext_Peer)(nil), // 15: audit.v1.AttributeContext.Peer + (*AttributeContext_Auth)(nil), // 16: audit.v1.AttributeContext.Auth + (*AttributeContext_Request)(nil), // 17: audit.v1.AttributeContext.Request + (*AttributeContext_Response)(nil), // 18: audit.v1.AttributeContext.Response + (*AttributeContext_Resource)(nil), // 19: audit.v1.AttributeContext.Resource + nil, // 20: audit.v1.AttributeContext.Peer.LabelsEntry + nil, // 21: audit.v1.AttributeContext.Request.HeadersEntry + nil, // 22: audit.v1.AttributeContext.Response.HeadersEntry + nil, // 23: audit.v1.AttributeContext.Resource.LabelsEntry + (*ServiceAccountDelegationInfo_FirstPartyPrincipal)(nil), // 24: audit.v1.ServiceAccountDelegationInfo.FirstPartyPrincipal + (*ServiceAccountDelegationInfo_ThirdPartyPrincipal)(nil), // 25: audit.v1.ServiceAccountDelegationInfo.ThirdPartyPrincipal + (*timestamppb.Timestamp)(nil), // 26: google.protobuf.Timestamp + (*structpb.Struct)(nil), // 27: google.protobuf.Struct + (*anypb.Any)(nil), // 28: google.protobuf.Any } var file_audit_v1_audit_event_proto_depIdxs = []int32{ - 6, // 0: audit.v1.RequestDetails.parameters:type_name -> google.protobuf.Struct - 6, // 1: audit.v1.RequestDetails.body:type_name -> google.protobuf.Struct - 4, // 2: audit.v1.RequestDetails.headers:type_name -> audit.v1.RequestHeader - 1, // 3: audit.v1.AuditEvent.region:type_name -> audit.v1.Region - 7, // 4: audit.v1.AuditEvent.sequence_number:type_name -> google.protobuf.Int64Value - 8, // 5: audit.v1.AuditEvent.event_time_stamp:type_name -> google.protobuf.Timestamp - 0, // 6: audit.v1.AuditEvent.event_trigger:type_name -> audit.v1.EventTrigger - 3, // 7: audit.v1.AuditEvent.request:type_name -> audit.v1.RequestDetails - 2, // 8: audit.v1.AuditEvent.initiator:type_name -> audit.v1.Principal - 2, // 9: audit.v1.AuditEvent.principals:type_name -> audit.v1.Principal - 9, // 10: audit.v1.AuditEvent.object_name:type_name -> audit.v1.ObjectName - 10, // 11: audit.v1.AuditEvent.object_identifier:type_name -> audit.v1.ObjectIdentifier - 6, // 12: audit.v1.AuditEvent.result:type_name -> google.protobuf.Struct - 6, // 13: audit.v1.AuditEvent.details:type_name -> google.protobuf.Struct - 14, // [14:14] is the sub-list for method output_type - 14, // [14:14] is the sub-list for method input_type - 14, // [14:14] is the sub-list for extension type_name - 14, // [14:14] is the sub-list for extension extendee - 0, // [0:14] is the sub-list for field type_name + 2, // 0: audit.v1.AuditEvent.resource:type_name -> audit.v1.MonitoredResource + 4, // 1: audit.v1.AuditEvent.proto_payload:type_name -> audit.v1.AuditLog + 13, // 2: audit.v1.AuditEvent.labels:type_name -> audit.v1.AuditEvent.LabelsEntry + 3, // 3: audit.v1.AuditEvent.operation:type_name -> audit.v1.LogEntryOperation + 26, // 4: audit.v1.AuditEvent.timestamp:type_name -> google.protobuf.Timestamp + 26, // 5: audit.v1.AuditEvent.receive_timestamp:type_name -> google.protobuf.Timestamp + 0, // 6: audit.v1.AuditEvent.severity:type_name -> audit.v1.LogSeverity + 12, // 7: audit.v1.AuditEvent.split:type_name -> audit.v1.LogSplit + 14, // 8: audit.v1.MonitoredResource.labels:type_name -> audit.v1.MonitoredResource.LabelsEntry + 9, // 9: audit.v1.AuditLog.resource_location:type_name -> audit.v1.ResourceLocation + 27, // 10: audit.v1.AuditLog.resource_original_state:type_name -> google.protobuf.Struct + 10, // 11: audit.v1.AuditLog.status:type_name -> audit.v1.RpcStatus + 5, // 12: audit.v1.AuditLog.authentication_info:type_name -> audit.v1.AuthenticationInfo + 6, // 13: audit.v1.AuditLog.authorization_info:type_name -> audit.v1.AuthorizationInfo + 8, // 14: audit.v1.AuditLog.request_metadata:type_name -> audit.v1.RequestMetadata + 27, // 15: audit.v1.AuditLog.request:type_name -> google.protobuf.Struct + 27, // 16: audit.v1.AuditLog.response:type_name -> google.protobuf.Struct + 27, // 17: audit.v1.AuditLog.metadata:type_name -> google.protobuf.Struct + 27, // 18: audit.v1.AuditLog.service_data:type_name -> google.protobuf.Struct + 27, // 19: audit.v1.AuthenticationInfo.third_party_principal:type_name -> google.protobuf.Struct + 11, // 20: audit.v1.AuthenticationInfo.service_account_delegation_info:type_name -> audit.v1.ServiceAccountDelegationInfo + 19, // 21: audit.v1.AuthorizationInfo.resource_attributes:type_name -> audit.v1.AttributeContext.Resource + 17, // 22: audit.v1.RequestMetadata.request_attributes:type_name -> audit.v1.AttributeContext.Request + 15, // 23: audit.v1.RequestMetadata.destination_attributes:type_name -> audit.v1.AttributeContext.Peer + 28, // 24: audit.v1.RpcStatus.details:type_name -> google.protobuf.Any + 24, // 25: audit.v1.ServiceAccountDelegationInfo.first_party_principal:type_name -> audit.v1.ServiceAccountDelegationInfo.FirstPartyPrincipal + 25, // 26: audit.v1.ServiceAccountDelegationInfo.third_party_principal:type_name -> audit.v1.ServiceAccountDelegationInfo.ThirdPartyPrincipal + 20, // 27: audit.v1.AttributeContext.Peer.labels:type_name -> audit.v1.AttributeContext.Peer.LabelsEntry + 27, // 28: audit.v1.AttributeContext.Auth.claims:type_name -> google.protobuf.Struct + 21, // 29: audit.v1.AttributeContext.Request.headers:type_name -> audit.v1.AttributeContext.Request.HeadersEntry + 26, // 30: audit.v1.AttributeContext.Request.time:type_name -> google.protobuf.Timestamp + 16, // 31: audit.v1.AttributeContext.Request.auth:type_name -> audit.v1.AttributeContext.Auth + 22, // 32: audit.v1.AttributeContext.Response.headers:type_name -> audit.v1.AttributeContext.Response.HeadersEntry + 26, // 33: audit.v1.AttributeContext.Response.time:type_name -> google.protobuf.Timestamp + 23, // 34: audit.v1.AttributeContext.Resource.labels:type_name -> audit.v1.AttributeContext.Resource.LabelsEntry + 27, // 35: audit.v1.ServiceAccountDelegationInfo.FirstPartyPrincipal.service_metadata:type_name -> google.protobuf.Struct + 27, // 36: audit.v1.ServiceAccountDelegationInfo.ThirdPartyPrincipal.third_party_claims:type_name -> google.protobuf.Struct + 37, // [37:37] is the sub-list for method output_type + 37, // [37:37] is the sub-list for method input_type + 37, // [37:37] is the sub-list for extension type_name + 37, // [37:37] is the sub-list for extension extendee + 0, // [0:37] is the sub-list for field type_name } func init() { file_audit_v1_audit_event_proto_init() } @@ -740,42 +2390,6 @@ func file_audit_v1_audit_event_proto_init() { file_audit_v1_common_proto_init() if !protoimpl.UnsafeEnabled { file_audit_v1_audit_event_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*Principal); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_audit_v1_audit_event_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RequestDetails); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_audit_v1_audit_event_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RequestHeader); i { - case 0: - return &v.state - case 1: - return &v.sizeCache - case 2: - return &v.unknownFields - default: - return nil - } - } - file_audit_v1_audit_event_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*AuditEvent); i { case 0: return &v.state @@ -787,20 +2401,234 @@ func file_audit_v1_audit_event_proto_init() { return nil } } + file_audit_v1_audit_event_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MonitoredResource); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*LogEntryOperation); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[3].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AuditLog); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AuthenticationInfo); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AuthorizationInfo); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RequestMetadata); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ResourceLocation); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*RpcStatus); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ServiceAccountDelegationInfo); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*LogSplit); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext_Peer); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext_Auth); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext_Request); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext_Response); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AttributeContext_Resource); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ServiceAccountDelegationInfo_FirstPartyPrincipal); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_audit_v1_audit_event_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ServiceAccountDelegationInfo_ThirdPartyPrincipal); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } - file_audit_v1_audit_event_proto_msgTypes[0].OneofWrappers = []interface{}{} - file_audit_v1_audit_event_proto_msgTypes[1].OneofWrappers = []interface{}{} - file_audit_v1_audit_event_proto_msgTypes[3].OneofWrappers = []interface{}{ - (*AuditEvent_ObjectName)(nil), - (*AuditEvent_ObjectIdentifier)(nil), + file_audit_v1_audit_event_proto_msgTypes[10].OneofWrappers = []interface{}{ + (*ServiceAccountDelegationInfo_FirstPartyPrincipal_)(nil), + (*ServiceAccountDelegationInfo_ThirdPartyPrincipal_)(nil), } type x struct{} out := protoimpl.TypeBuilder{ File: protoimpl.DescBuilder{ GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_audit_v1_audit_event_proto_rawDesc, - NumEnums: 2, - NumMessages: 4, + NumEnums: 1, + NumMessages: 25, NumExtensions: 0, NumServices: 0, }, diff --git a/gen/go/audit/v1/audit_event.pb.validate.go b/gen/go/audit/v1/audit_event.pb.validate.go index f5e0884..f9cebe0 100644 --- a/gen/go/audit/v1/audit_event.pb.validate.go +++ b/gen/go/audit/v1/audit_event.pb.validate.go @@ -35,423 +35,6 @@ var ( _ = sort.Sort ) -// Validate checks the field values on Principal with the rules defined in the -// proto definition for this message. If any rules are violated, the first -// error encountered is returned, or nil if there are no violations. -func (m *Principal) Validate() error { - return m.validate(false) -} - -// ValidateAll checks the field values on Principal with the rules defined in -// the proto definition for this message. If any rules are violated, the -// result is a list of violation errors wrapped in PrincipalMultiError, or nil -// if none found. -func (m *Principal) ValidateAll() error { - return m.validate(true) -} - -func (m *Principal) validate(all bool) error { - if m == nil { - return nil - } - - var errors []error - - // no validation rules for Id - - if m.Email != nil { - // no validation rules for Email - } - - if len(errors) > 0 { - return PrincipalMultiError(errors) - } - - return nil -} - -// PrincipalMultiError is an error wrapping multiple validation errors returned -// by Principal.ValidateAll() if the designated constraints aren't met. -type PrincipalMultiError []error - -// Error returns a concatenation of all the error messages it wraps. -func (m PrincipalMultiError) Error() string { - var msgs []string - for _, err := range m { - msgs = append(msgs, err.Error()) - } - return strings.Join(msgs, "; ") -} - -// AllErrors returns a list of validation violation errors. -func (m PrincipalMultiError) AllErrors() []error { return m } - -// PrincipalValidationError is the validation error returned by -// Principal.Validate if the designated constraints aren't met. -type PrincipalValidationError struct { - field string - reason string - cause error - key bool -} - -// Field function returns field value. -func (e PrincipalValidationError) Field() string { return e.field } - -// Reason function returns reason value. -func (e PrincipalValidationError) Reason() string { return e.reason } - -// Cause function returns cause value. -func (e PrincipalValidationError) Cause() error { return e.cause } - -// Key function returns key value. -func (e PrincipalValidationError) Key() bool { return e.key } - -// ErrorName returns error name. -func (e PrincipalValidationError) ErrorName() string { return "PrincipalValidationError" } - -// Error satisfies the builtin error interface -func (e PrincipalValidationError) Error() string { - cause := "" - if e.cause != nil { - cause = fmt.Sprintf(" | caused by: %v", e.cause) - } - - key := "" - if e.key { - key = "key for " - } - - return fmt.Sprintf( - "invalid %sPrincipal.%s: %s%s", - key, - e.field, - e.reason, - cause) -} - -var _ error = PrincipalValidationError{} - -var _ interface { - Field() string - Reason() string - Key() bool - Cause() error - ErrorName() string -} = PrincipalValidationError{} - -// Validate checks the field values on RequestDetails with the rules defined in -// the proto definition for this message. If any rules are violated, the first -// error encountered is returned, or nil if there are no violations. -func (m *RequestDetails) Validate() error { - return m.validate(false) -} - -// ValidateAll checks the field values on RequestDetails with the rules defined -// in the proto definition for this message. If any rules are violated, the -// result is a list of violation errors wrapped in RequestDetailsMultiError, -// or nil if none found. -func (m *RequestDetails) ValidateAll() error { - return m.validate(true) -} - -func (m *RequestDetails) validate(all bool) error { - if m == nil { - return nil - } - - var errors []error - - // no validation rules for Endpoint - - // no validation rules for SourceIpAddress - - for idx, item := range m.GetHeaders() { - _, _ = idx, item - - if all { - switch v := interface{}(item).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: fmt.Sprintf("Headers[%v]", idx), - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: fmt.Sprintf("Headers[%v]", idx), - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(item).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return RequestDetailsValidationError{ - field: fmt.Sprintf("Headers[%v]", idx), - reason: "embedded message failed validation", - cause: err, - } - } - } - - } - - if m.UserAgent != nil { - // no validation rules for UserAgent - } - - if m.Parameters != nil { - - if all { - switch v := interface{}(m.GetParameters()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: "Parameters", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: "Parameters", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetParameters()).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return RequestDetailsValidationError{ - field: "Parameters", - reason: "embedded message failed validation", - cause: err, - } - } - } - - } - - if m.Body != nil { - - if all { - switch v := interface{}(m.GetBody()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: "Body", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, RequestDetailsValidationError{ - field: "Body", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetBody()).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return RequestDetailsValidationError{ - field: "Body", - reason: "embedded message failed validation", - cause: err, - } - } - } - - } - - if len(errors) > 0 { - return RequestDetailsMultiError(errors) - } - - return nil -} - -// RequestDetailsMultiError is an error wrapping multiple validation errors -// returned by RequestDetails.ValidateAll() if the designated constraints -// aren't met. -type RequestDetailsMultiError []error - -// Error returns a concatenation of all the error messages it wraps. -func (m RequestDetailsMultiError) Error() string { - var msgs []string - for _, err := range m { - msgs = append(msgs, err.Error()) - } - return strings.Join(msgs, "; ") -} - -// AllErrors returns a list of validation violation errors. -func (m RequestDetailsMultiError) AllErrors() []error { return m } - -// RequestDetailsValidationError is the validation error returned by -// RequestDetails.Validate if the designated constraints aren't met. -type RequestDetailsValidationError struct { - field string - reason string - cause error - key bool -} - -// Field function returns field value. -func (e RequestDetailsValidationError) Field() string { return e.field } - -// Reason function returns reason value. -func (e RequestDetailsValidationError) Reason() string { return e.reason } - -// Cause function returns cause value. -func (e RequestDetailsValidationError) Cause() error { return e.cause } - -// Key function returns key value. -func (e RequestDetailsValidationError) Key() bool { return e.key } - -// ErrorName returns error name. -func (e RequestDetailsValidationError) ErrorName() string { return "RequestDetailsValidationError" } - -// Error satisfies the builtin error interface -func (e RequestDetailsValidationError) Error() string { - cause := "" - if e.cause != nil { - cause = fmt.Sprintf(" | caused by: %v", e.cause) - } - - key := "" - if e.key { - key = "key for " - } - - return fmt.Sprintf( - "invalid %sRequestDetails.%s: %s%s", - key, - e.field, - e.reason, - cause) -} - -var _ error = RequestDetailsValidationError{} - -var _ interface { - Field() string - Reason() string - Key() bool - Cause() error - ErrorName() string -} = RequestDetailsValidationError{} - -// Validate checks the field values on RequestHeader with the rules defined in -// the proto definition for this message. If any rules are violated, the first -// error encountered is returned, or nil if there are no violations. -func (m *RequestHeader) Validate() error { - return m.validate(false) -} - -// ValidateAll checks the field values on RequestHeader with the rules defined -// in the proto definition for this message. If any rules are violated, the -// result is a list of violation errors wrapped in RequestHeaderMultiError, or -// nil if none found. -func (m *RequestHeader) ValidateAll() error { - return m.validate(true) -} - -func (m *RequestHeader) validate(all bool) error { - if m == nil { - return nil - } - - var errors []error - - // no validation rules for Key - - // no validation rules for Value - - if len(errors) > 0 { - return RequestHeaderMultiError(errors) - } - - return nil -} - -// RequestHeaderMultiError is an error wrapping multiple validation errors -// returned by RequestHeader.ValidateAll() if the designated constraints -// aren't met. -type RequestHeaderMultiError []error - -// Error returns a concatenation of all the error messages it wraps. -func (m RequestHeaderMultiError) Error() string { - var msgs []string - for _, err := range m { - msgs = append(msgs, err.Error()) - } - return strings.Join(msgs, "; ") -} - -// AllErrors returns a list of validation violation errors. -func (m RequestHeaderMultiError) AllErrors() []error { return m } - -// RequestHeaderValidationError is the validation error returned by -// RequestHeader.Validate if the designated constraints aren't met. -type RequestHeaderValidationError struct { - field string - reason string - cause error - key bool -} - -// Field function returns field value. -func (e RequestHeaderValidationError) Field() string { return e.field } - -// Reason function returns reason value. -func (e RequestHeaderValidationError) Reason() string { return e.reason } - -// Cause function returns cause value. -func (e RequestHeaderValidationError) Cause() error { return e.cause } - -// Key function returns key value. -func (e RequestHeaderValidationError) Key() bool { return e.key } - -// ErrorName returns error name. -func (e RequestHeaderValidationError) ErrorName() string { return "RequestHeaderValidationError" } - -// Error satisfies the builtin error interface -func (e RequestHeaderValidationError) Error() string { - cause := "" - if e.cause != nil { - cause = fmt.Sprintf(" | caused by: %v", e.cause) - } - - key := "" - if e.key { - key = "key for " - } - - return fmt.Sprintf( - "invalid %sRequestHeader.%s: %s%s", - key, - e.field, - e.reason, - cause) -} - -var _ error = RequestHeaderValidationError{} - -var _ interface { - Field() string - Reason() string - Key() bool - Cause() error - ErrorName() string -} = RequestHeaderValidationError{} - // Validate checks the field values on AuditEvent with the rules defined in the // proto definition for this message. If any rules are violated, the first // error encountered is returned, or nil if there are no violations. @@ -474,16 +57,14 @@ func (m *AuditEvent) validate(all bool) error { var errors []error - // no validation rules for EventSource - - // no validation rules for Region + // no validation rules for LogName if all { - switch v := interface{}(m.GetSequenceNumber()).(type) { + switch v := interface{}(m.GetResource()).(type) { case interface{ ValidateAll() error }: if err := v.ValidateAll(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "SequenceNumber", + field: "Resource", reason: "embedded message failed validation", cause: err, }) @@ -491,30 +72,28 @@ func (m *AuditEvent) validate(all bool) error { case interface{ Validate() error }: if err := v.Validate(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "SequenceNumber", + field: "Resource", reason: "embedded message failed validation", cause: err, }) } } - } else if v, ok := interface{}(m.GetSequenceNumber()).(interface{ Validate() error }); ok { + } else if v, ok := interface{}(m.GetResource()).(interface{ Validate() error }); ok { if err := v.Validate(); err != nil { return AuditEventValidationError{ - field: "SequenceNumber", + field: "Resource", reason: "embedded message failed validation", cause: err, } } } - // no validation rules for EventName - if all { - switch v := interface{}(m.GetEventTimeStamp()).(type) { + switch v := interface{}(m.GetProtoPayload()).(type) { case interface{ ValidateAll() error }: if err := v.ValidateAll(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "EventTimeStamp", + field: "ProtoPayload", reason: "embedded message failed validation", cause: err, }) @@ -522,30 +101,32 @@ func (m *AuditEvent) validate(all bool) error { case interface{ Validate() error }: if err := v.Validate(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "EventTimeStamp", + field: "ProtoPayload", reason: "embedded message failed validation", cause: err, }) } } - } else if v, ok := interface{}(m.GetEventTimeStamp()).(interface{ Validate() error }); ok { + } else if v, ok := interface{}(m.GetProtoPayload()).(interface{ Validate() error }); ok { if err := v.Validate(); err != nil { return AuditEventValidationError{ - field: "EventTimeStamp", + field: "ProtoPayload", reason: "embedded message failed validation", cause: err, } } } - // no validation rules for EventTrigger + // no validation rules for InsertId + + // no validation rules for Labels if all { - switch v := interface{}(m.GetInitiator()).(type) { + switch v := interface{}(m.GetOperation()).(type) { case interface{ ValidateAll() error }: if err := v.ValidateAll(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "Initiator", + field: "Operation", reason: "embedded message failed validation", cause: err, }) @@ -553,223 +134,113 @@ func (m *AuditEvent) validate(all bool) error { case interface{ Validate() error }: if err := v.Validate(); err != nil { errors = append(errors, AuditEventValidationError{ - field: "Initiator", + field: "Operation", reason: "embedded message failed validation", cause: err, }) } } - } else if v, ok := interface{}(m.GetInitiator()).(interface{ Validate() error }); ok { + } else if v, ok := interface{}(m.GetOperation()).(interface{ Validate() error }); ok { if err := v.Validate(); err != nil { return AuditEventValidationError{ - field: "Initiator", + field: "Operation", reason: "embedded message failed validation", cause: err, } } } - for idx, item := range m.GetPrincipals() { - _, _ = idx, item - - if all { - switch v := interface{}(item).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: fmt.Sprintf("Principals[%v]", idx), - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: fmt.Sprintf("Principals[%v]", idx), - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(item).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return AuditEventValidationError{ - field: fmt.Sprintf("Principals[%v]", idx), + if all { + switch v := interface{}(m.GetTimestamp()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditEventValidationError{ + field: "Timestamp", reason: "embedded message failed validation", cause: err, - } + }) } - } - - } - - switch v := m.ResourceContainerReference.(type) { - case *AuditEvent_ObjectName: - if v == nil { - err := AuditEventValidationError{ - field: "ResourceContainerReference", - reason: "oneof value cannot be a typed-nil", - } - if !all { - return err - } - errors = append(errors, err) - } - // no validation rules for ObjectName - case *AuditEvent_ObjectIdentifier: - if v == nil { - err := AuditEventValidationError{ - field: "ResourceContainerReference", - reason: "oneof value cannot be a typed-nil", - } - if !all { - return err - } - errors = append(errors, err) - } - - if all { - switch v := interface{}(m.GetObjectIdentifier()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "ObjectIdentifier", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "ObjectIdentifier", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetObjectIdentifier()).(interface{ Validate() error }); ok { + case interface{ Validate() error }: if err := v.Validate(); err != nil { - return AuditEventValidationError{ - field: "ObjectIdentifier", + errors = append(errors, AuditEventValidationError{ + field: "Timestamp", reason: "embedded message failed validation", cause: err, - } + }) + } + } + } else if v, ok := interface{}(m.GetTimestamp()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditEventValidationError{ + field: "Timestamp", + reason: "embedded message failed validation", + cause: err, } } - - default: - _ = v // ensures v is used } - if m.Request != nil { - - if all { - switch v := interface{}(m.GetRequest()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Request", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Request", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetRequest()).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return AuditEventValidationError{ - field: "Request", + if all { + switch v := interface{}(m.GetReceiveTimestamp()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditEventValidationError{ + field: "ReceiveTimestamp", reason: "embedded message failed validation", cause: err, - } + }) } - } - - } - - if m.ResourceId != nil { - // no validation rules for ResourceId - } - - if m.ResourceName != nil { - // no validation rules for ResourceName - } - - if m.CorrelationId != nil { - // no validation rules for CorrelationId - } - - if m.Result != nil { - - if all { - switch v := interface{}(m.GetResult()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Result", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Result", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetResult()).(interface{ Validate() error }); ok { + case interface{ Validate() error }: if err := v.Validate(); err != nil { - return AuditEventValidationError{ - field: "Result", + errors = append(errors, AuditEventValidationError{ + field: "ReceiveTimestamp", reason: "embedded message failed validation", cause: err, - } + }) + } + } + } else if v, ok := interface{}(m.GetReceiveTimestamp()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditEventValidationError{ + field: "ReceiveTimestamp", + reason: "embedded message failed validation", + cause: err, } } - } - if m.Details != nil { + // no validation rules for Severity - if all { - switch v := interface{}(m.GetDetails()).(type) { - case interface{ ValidateAll() error }: - if err := v.ValidateAll(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Details", - reason: "embedded message failed validation", - cause: err, - }) - } - case interface{ Validate() error }: - if err := v.Validate(); err != nil { - errors = append(errors, AuditEventValidationError{ - field: "Details", - reason: "embedded message failed validation", - cause: err, - }) - } - } - } else if v, ok := interface{}(m.GetDetails()).(interface{ Validate() error }); ok { - if err := v.Validate(); err != nil { - return AuditEventValidationError{ - field: "Details", + // no validation rules for Trace + + // no validation rules for SpanId + + if all { + switch v := interface{}(m.GetSplit()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditEventValidationError{ + field: "Split", reason: "embedded message failed validation", cause: err, - } + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditEventValidationError{ + field: "Split", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetSplit()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditEventValidationError{ + field: "Split", + reason: "embedded message failed validation", + cause: err, } } - } if len(errors) > 0 { @@ -848,3 +319,2687 @@ var _ interface { Cause() error ErrorName() string } = AuditEventValidationError{} + +// Validate checks the field values on MonitoredResource with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *MonitoredResource) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on MonitoredResource with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// MonitoredResourceMultiError, or nil if none found. +func (m *MonitoredResource) ValidateAll() error { + return m.validate(true) +} + +func (m *MonitoredResource) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Type + + // no validation rules for Labels + + if len(errors) > 0 { + return MonitoredResourceMultiError(errors) + } + + return nil +} + +// MonitoredResourceMultiError is an error wrapping multiple validation errors +// returned by MonitoredResource.ValidateAll() if the designated constraints +// aren't met. +type MonitoredResourceMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m MonitoredResourceMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m MonitoredResourceMultiError) AllErrors() []error { return m } + +// MonitoredResourceValidationError is the validation error returned by +// MonitoredResource.Validate if the designated constraints aren't met. +type MonitoredResourceValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e MonitoredResourceValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e MonitoredResourceValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e MonitoredResourceValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e MonitoredResourceValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e MonitoredResourceValidationError) ErrorName() string { + return "MonitoredResourceValidationError" +} + +// Error satisfies the builtin error interface +func (e MonitoredResourceValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sMonitoredResource.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = MonitoredResourceValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = MonitoredResourceValidationError{} + +// Validate checks the field values on LogEntryOperation with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *LogEntryOperation) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on LogEntryOperation with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// LogEntryOperationMultiError, or nil if none found. +func (m *LogEntryOperation) ValidateAll() error { + return m.validate(true) +} + +func (m *LogEntryOperation) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Id + + // no validation rules for Producer + + // no validation rules for First + + // no validation rules for Last + + if len(errors) > 0 { + return LogEntryOperationMultiError(errors) + } + + return nil +} + +// LogEntryOperationMultiError is an error wrapping multiple validation errors +// returned by LogEntryOperation.ValidateAll() if the designated constraints +// aren't met. +type LogEntryOperationMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m LogEntryOperationMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m LogEntryOperationMultiError) AllErrors() []error { return m } + +// LogEntryOperationValidationError is the validation error returned by +// LogEntryOperation.Validate if the designated constraints aren't met. +type LogEntryOperationValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e LogEntryOperationValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e LogEntryOperationValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e LogEntryOperationValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e LogEntryOperationValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e LogEntryOperationValidationError) ErrorName() string { + return "LogEntryOperationValidationError" +} + +// Error satisfies the builtin error interface +func (e LogEntryOperationValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sLogEntryOperation.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = LogEntryOperationValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = LogEntryOperationValidationError{} + +// Validate checks the field values on AuditLog with the rules defined in the +// proto definition for this message. If any rules are violated, the first +// error encountered is returned, or nil if there are no violations. +func (m *AuditLog) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AuditLog with the rules defined in +// the proto definition for this message. If any rules are violated, the +// result is a list of violation errors wrapped in AuditLogMultiError, or nil +// if none found. +func (m *AuditLog) ValidateAll() error { + return m.validate(true) +} + +func (m *AuditLog) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for ServiceName + + // no validation rules for MethodName + + // no validation rules for ResourceName + + if all { + switch v := interface{}(m.GetResourceLocation()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ResourceLocation", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ResourceLocation", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetResourceLocation()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "ResourceLocation", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetResourceOriginalState()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ResourceOriginalState", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ResourceOriginalState", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetResourceOriginalState()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "ResourceOriginalState", + reason: "embedded message failed validation", + cause: err, + } + } + } + + // no validation rules for NumResponseItems + + if all { + switch v := interface{}(m.GetStatus()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Status", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Status", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetStatus()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "Status", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetAuthenticationInfo()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "AuthenticationInfo", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "AuthenticationInfo", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetAuthenticationInfo()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "AuthenticationInfo", + reason: "embedded message failed validation", + cause: err, + } + } + } + + for idx, item := range m.GetAuthorizationInfo() { + _, _ = idx, item + + if all { + switch v := interface{}(item).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: fmt.Sprintf("AuthorizationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: fmt.Sprintf("AuthorizationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(item).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: fmt.Sprintf("AuthorizationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + } + } + } + + } + + if all { + switch v := interface{}(m.GetRequestMetadata()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "RequestMetadata", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "RequestMetadata", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetRequestMetadata()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "RequestMetadata", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetRequest()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Request", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Request", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetRequest()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "Request", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetResponse()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Response", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Response", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetResponse()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "Response", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetMetadata()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Metadata", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "Metadata", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetMetadata()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "Metadata", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetServiceData()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ServiceData", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuditLogValidationError{ + field: "ServiceData", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetServiceData()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuditLogValidationError{ + field: "ServiceData", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return AuditLogMultiError(errors) + } + + return nil +} + +// AuditLogMultiError is an error wrapping multiple validation errors returned +// by AuditLog.ValidateAll() if the designated constraints aren't met. +type AuditLogMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AuditLogMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AuditLogMultiError) AllErrors() []error { return m } + +// AuditLogValidationError is the validation error returned by +// AuditLog.Validate if the designated constraints aren't met. +type AuditLogValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AuditLogValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AuditLogValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AuditLogValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AuditLogValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AuditLogValidationError) ErrorName() string { return "AuditLogValidationError" } + +// Error satisfies the builtin error interface +func (e AuditLogValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAuditLog.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AuditLogValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AuditLogValidationError{} + +// Validate checks the field values on AuthenticationInfo with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AuthenticationInfo) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AuthenticationInfo with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AuthenticationInfoMultiError, or nil if none found. +func (m *AuthenticationInfo) ValidateAll() error { + return m.validate(true) +} + +func (m *AuthenticationInfo) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for PrincipalEmail + + // no validation rules for AuthoritySelector + + if all { + switch v := interface{}(m.GetThirdPartyPrincipal()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuthenticationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuthenticationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetThirdPartyPrincipal()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuthenticationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + } + } + } + + // no validation rules for ServiceAccountKeyName + + for idx, item := range m.GetServiceAccountDelegationInfo() { + _, _ = idx, item + + if all { + switch v := interface{}(item).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuthenticationInfoValidationError{ + field: fmt.Sprintf("ServiceAccountDelegationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuthenticationInfoValidationError{ + field: fmt.Sprintf("ServiceAccountDelegationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(item).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuthenticationInfoValidationError{ + field: fmt.Sprintf("ServiceAccountDelegationInfo[%v]", idx), + reason: "embedded message failed validation", + cause: err, + } + } + } + + } + + // no validation rules for PrincipalSubject + + if len(errors) > 0 { + return AuthenticationInfoMultiError(errors) + } + + return nil +} + +// AuthenticationInfoMultiError is an error wrapping multiple validation errors +// returned by AuthenticationInfo.ValidateAll() if the designated constraints +// aren't met. +type AuthenticationInfoMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AuthenticationInfoMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AuthenticationInfoMultiError) AllErrors() []error { return m } + +// AuthenticationInfoValidationError is the validation error returned by +// AuthenticationInfo.Validate if the designated constraints aren't met. +type AuthenticationInfoValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AuthenticationInfoValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AuthenticationInfoValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AuthenticationInfoValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AuthenticationInfoValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AuthenticationInfoValidationError) ErrorName() string { + return "AuthenticationInfoValidationError" +} + +// Error satisfies the builtin error interface +func (e AuthenticationInfoValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAuthenticationInfo.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AuthenticationInfoValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AuthenticationInfoValidationError{} + +// Validate checks the field values on AuthorizationInfo with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *AuthorizationInfo) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AuthorizationInfo with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AuthorizationInfoMultiError, or nil if none found. +func (m *AuthorizationInfo) ValidateAll() error { + return m.validate(true) +} + +func (m *AuthorizationInfo) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Resource + + // no validation rules for Permission + + // no validation rules for Granted + + if all { + switch v := interface{}(m.GetResourceAttributes()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AuthorizationInfoValidationError{ + field: "ResourceAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AuthorizationInfoValidationError{ + field: "ResourceAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetResourceAttributes()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AuthorizationInfoValidationError{ + field: "ResourceAttributes", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return AuthorizationInfoMultiError(errors) + } + + return nil +} + +// AuthorizationInfoMultiError is an error wrapping multiple validation errors +// returned by AuthorizationInfo.ValidateAll() if the designated constraints +// aren't met. +type AuthorizationInfoMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AuthorizationInfoMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AuthorizationInfoMultiError) AllErrors() []error { return m } + +// AuthorizationInfoValidationError is the validation error returned by +// AuthorizationInfo.Validate if the designated constraints aren't met. +type AuthorizationInfoValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AuthorizationInfoValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AuthorizationInfoValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AuthorizationInfoValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AuthorizationInfoValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AuthorizationInfoValidationError) ErrorName() string { + return "AuthorizationInfoValidationError" +} + +// Error satisfies the builtin error interface +func (e AuthorizationInfoValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAuthorizationInfo.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AuthorizationInfoValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AuthorizationInfoValidationError{} + +// Validate checks the field values on AttributeContext with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContextMultiError, or nil if none found. +func (m *AttributeContext) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + if len(errors) > 0 { + return AttributeContextMultiError(errors) + } + + return nil +} + +// AttributeContextMultiError is an error wrapping multiple validation errors +// returned by AttributeContext.ValidateAll() if the designated constraints +// aren't met. +type AttributeContextMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContextMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContextMultiError) AllErrors() []error { return m } + +// AttributeContextValidationError is the validation error returned by +// AttributeContext.Validate if the designated constraints aren't met. +type AttributeContextValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContextValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContextValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContextValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContextValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContextValidationError) ErrorName() string { return "AttributeContextValidationError" } + +// Error satisfies the builtin error interface +func (e AttributeContextValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContextValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContextValidationError{} + +// Validate checks the field values on RequestMetadata with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *RequestMetadata) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on RequestMetadata with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// RequestMetadataMultiError, or nil if none found. +func (m *RequestMetadata) ValidateAll() error { + return m.validate(true) +} + +func (m *RequestMetadata) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for CallerIp + + // no validation rules for CallerSuppliedUserAgent + + // no validation rules for CallerNetwork + + if all { + switch v := interface{}(m.GetRequestAttributes()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, RequestMetadataValidationError{ + field: "RequestAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, RequestMetadataValidationError{ + field: "RequestAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetRequestAttributes()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return RequestMetadataValidationError{ + field: "RequestAttributes", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if all { + switch v := interface{}(m.GetDestinationAttributes()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, RequestMetadataValidationError{ + field: "DestinationAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, RequestMetadataValidationError{ + field: "DestinationAttributes", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetDestinationAttributes()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return RequestMetadataValidationError{ + field: "DestinationAttributes", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return RequestMetadataMultiError(errors) + } + + return nil +} + +// RequestMetadataMultiError is an error wrapping multiple validation errors +// returned by RequestMetadata.ValidateAll() if the designated constraints +// aren't met. +type RequestMetadataMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m RequestMetadataMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m RequestMetadataMultiError) AllErrors() []error { return m } + +// RequestMetadataValidationError is the validation error returned by +// RequestMetadata.Validate if the designated constraints aren't met. +type RequestMetadataValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e RequestMetadataValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e RequestMetadataValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e RequestMetadataValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e RequestMetadataValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e RequestMetadataValidationError) ErrorName() string { return "RequestMetadataValidationError" } + +// Error satisfies the builtin error interface +func (e RequestMetadataValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sRequestMetadata.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = RequestMetadataValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = RequestMetadataValidationError{} + +// Validate checks the field values on ResourceLocation with the rules defined +// in the proto definition for this message. If any rules are violated, the +// first error encountered is returned, or nil if there are no violations. +func (m *ResourceLocation) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on ResourceLocation with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// ResourceLocationMultiError, or nil if none found. +func (m *ResourceLocation) ValidateAll() error { + return m.validate(true) +} + +func (m *ResourceLocation) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + if len(errors) > 0 { + return ResourceLocationMultiError(errors) + } + + return nil +} + +// ResourceLocationMultiError is an error wrapping multiple validation errors +// returned by ResourceLocation.ValidateAll() if the designated constraints +// aren't met. +type ResourceLocationMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m ResourceLocationMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m ResourceLocationMultiError) AllErrors() []error { return m } + +// ResourceLocationValidationError is the validation error returned by +// ResourceLocation.Validate if the designated constraints aren't met. +type ResourceLocationValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e ResourceLocationValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e ResourceLocationValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e ResourceLocationValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e ResourceLocationValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e ResourceLocationValidationError) ErrorName() string { return "ResourceLocationValidationError" } + +// Error satisfies the builtin error interface +func (e ResourceLocationValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sResourceLocation.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = ResourceLocationValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = ResourceLocationValidationError{} + +// Validate checks the field values on RpcStatus with the rules defined in the +// proto definition for this message. If any rules are violated, the first +// error encountered is returned, or nil if there are no violations. +func (m *RpcStatus) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on RpcStatus with the rules defined in +// the proto definition for this message. If any rules are violated, the +// result is a list of violation errors wrapped in RpcStatusMultiError, or nil +// if none found. +func (m *RpcStatus) ValidateAll() error { + return m.validate(true) +} + +func (m *RpcStatus) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Code + + // no validation rules for Message + + for idx, item := range m.GetDetails() { + _, _ = idx, item + + if all { + switch v := interface{}(item).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, RpcStatusValidationError{ + field: fmt.Sprintf("Details[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, RpcStatusValidationError{ + field: fmt.Sprintf("Details[%v]", idx), + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(item).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return RpcStatusValidationError{ + field: fmt.Sprintf("Details[%v]", idx), + reason: "embedded message failed validation", + cause: err, + } + } + } + + } + + if len(errors) > 0 { + return RpcStatusMultiError(errors) + } + + return nil +} + +// RpcStatusMultiError is an error wrapping multiple validation errors returned +// by RpcStatus.ValidateAll() if the designated constraints aren't met. +type RpcStatusMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m RpcStatusMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m RpcStatusMultiError) AllErrors() []error { return m } + +// RpcStatusValidationError is the validation error returned by +// RpcStatus.Validate if the designated constraints aren't met. +type RpcStatusValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e RpcStatusValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e RpcStatusValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e RpcStatusValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e RpcStatusValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e RpcStatusValidationError) ErrorName() string { return "RpcStatusValidationError" } + +// Error satisfies the builtin error interface +func (e RpcStatusValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sRpcStatus.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = RpcStatusValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = RpcStatusValidationError{} + +// Validate checks the field values on ServiceAccountDelegationInfo with the +// rules defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *ServiceAccountDelegationInfo) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on ServiceAccountDelegationInfo with the +// rules defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// ServiceAccountDelegationInfoMultiError, or nil if none found. +func (m *ServiceAccountDelegationInfo) ValidateAll() error { + return m.validate(true) +} + +func (m *ServiceAccountDelegationInfo) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + switch v := m.Authority.(type) { + case *ServiceAccountDelegationInfo_FirstPartyPrincipal_: + if v == nil { + err := ServiceAccountDelegationInfoValidationError{ + field: "Authority", + reason: "oneof value cannot be a typed-nil", + } + if !all { + return err + } + errors = append(errors, err) + } + + if all { + switch v := interface{}(m.GetFirstPartyPrincipal()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, ServiceAccountDelegationInfoValidationError{ + field: "FirstPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, ServiceAccountDelegationInfoValidationError{ + field: "FirstPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetFirstPartyPrincipal()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return ServiceAccountDelegationInfoValidationError{ + field: "FirstPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + } + } + } + + case *ServiceAccountDelegationInfo_ThirdPartyPrincipal_: + if v == nil { + err := ServiceAccountDelegationInfoValidationError{ + field: "Authority", + reason: "oneof value cannot be a typed-nil", + } + if !all { + return err + } + errors = append(errors, err) + } + + if all { + switch v := interface{}(m.GetThirdPartyPrincipal()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, ServiceAccountDelegationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, ServiceAccountDelegationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetThirdPartyPrincipal()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return ServiceAccountDelegationInfoValidationError{ + field: "ThirdPartyPrincipal", + reason: "embedded message failed validation", + cause: err, + } + } + } + + default: + _ = v // ensures v is used + } + + if len(errors) > 0 { + return ServiceAccountDelegationInfoMultiError(errors) + } + + return nil +} + +// ServiceAccountDelegationInfoMultiError is an error wrapping multiple +// validation errors returned by ServiceAccountDelegationInfo.ValidateAll() if +// the designated constraints aren't met. +type ServiceAccountDelegationInfoMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m ServiceAccountDelegationInfoMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m ServiceAccountDelegationInfoMultiError) AllErrors() []error { return m } + +// ServiceAccountDelegationInfoValidationError is the validation error returned +// by ServiceAccountDelegationInfo.Validate if the designated constraints +// aren't met. +type ServiceAccountDelegationInfoValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e ServiceAccountDelegationInfoValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e ServiceAccountDelegationInfoValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e ServiceAccountDelegationInfoValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e ServiceAccountDelegationInfoValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e ServiceAccountDelegationInfoValidationError) ErrorName() string { + return "ServiceAccountDelegationInfoValidationError" +} + +// Error satisfies the builtin error interface +func (e ServiceAccountDelegationInfoValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sServiceAccountDelegationInfo.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = ServiceAccountDelegationInfoValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = ServiceAccountDelegationInfoValidationError{} + +// Validate checks the field values on LogSplit with the rules defined in the +// proto definition for this message. If any rules are violated, the first +// error encountered is returned, or nil if there are no violations. +func (m *LogSplit) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on LogSplit with the rules defined in +// the proto definition for this message. If any rules are violated, the +// result is a list of violation errors wrapped in LogSplitMultiError, or nil +// if none found. +func (m *LogSplit) ValidateAll() error { + return m.validate(true) +} + +func (m *LogSplit) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Uid + + // no validation rules for Index + + // no validation rules for TotalSplits + + if len(errors) > 0 { + return LogSplitMultiError(errors) + } + + return nil +} + +// LogSplitMultiError is an error wrapping multiple validation errors returned +// by LogSplit.ValidateAll() if the designated constraints aren't met. +type LogSplitMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m LogSplitMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m LogSplitMultiError) AllErrors() []error { return m } + +// LogSplitValidationError is the validation error returned by +// LogSplit.Validate if the designated constraints aren't met. +type LogSplitValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e LogSplitValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e LogSplitValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e LogSplitValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e LogSplitValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e LogSplitValidationError) ErrorName() string { return "LogSplitValidationError" } + +// Error satisfies the builtin error interface +func (e LogSplitValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sLogSplit.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = LogSplitValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = LogSplitValidationError{} + +// Validate checks the field values on AttributeContext_Peer with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext_Peer) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext_Peer with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContext_PeerMultiError, or nil if none found. +func (m *AttributeContext_Peer) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext_Peer) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Ip + + // no validation rules for Port + + // no validation rules for Labels + + // no validation rules for Principal + + // no validation rules for RegionCode + + if len(errors) > 0 { + return AttributeContext_PeerMultiError(errors) + } + + return nil +} + +// AttributeContext_PeerMultiError is an error wrapping multiple validation +// errors returned by AttributeContext_Peer.ValidateAll() if the designated +// constraints aren't met. +type AttributeContext_PeerMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContext_PeerMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContext_PeerMultiError) AllErrors() []error { return m } + +// AttributeContext_PeerValidationError is the validation error returned by +// AttributeContext_Peer.Validate if the designated constraints aren't met. +type AttributeContext_PeerValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContext_PeerValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContext_PeerValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContext_PeerValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContext_PeerValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContext_PeerValidationError) ErrorName() string { + return "AttributeContext_PeerValidationError" +} + +// Error satisfies the builtin error interface +func (e AttributeContext_PeerValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext_Peer.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContext_PeerValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContext_PeerValidationError{} + +// Validate checks the field values on AttributeContext_Auth with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext_Auth) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext_Auth with the rules +// defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContext_AuthMultiError, or nil if none found. +func (m *AttributeContext_Auth) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext_Auth) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Principal + + // no validation rules for Presenter + + if all { + switch v := interface{}(m.GetClaims()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AttributeContext_AuthValidationError{ + field: "Claims", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AttributeContext_AuthValidationError{ + field: "Claims", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetClaims()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AttributeContext_AuthValidationError{ + field: "Claims", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return AttributeContext_AuthMultiError(errors) + } + + return nil +} + +// AttributeContext_AuthMultiError is an error wrapping multiple validation +// errors returned by AttributeContext_Auth.ValidateAll() if the designated +// constraints aren't met. +type AttributeContext_AuthMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContext_AuthMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContext_AuthMultiError) AllErrors() []error { return m } + +// AttributeContext_AuthValidationError is the validation error returned by +// AttributeContext_Auth.Validate if the designated constraints aren't met. +type AttributeContext_AuthValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContext_AuthValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContext_AuthValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContext_AuthValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContext_AuthValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContext_AuthValidationError) ErrorName() string { + return "AttributeContext_AuthValidationError" +} + +// Error satisfies the builtin error interface +func (e AttributeContext_AuthValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext_Auth.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContext_AuthValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContext_AuthValidationError{} + +// Validate checks the field values on AttributeContext_Request with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext_Request) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext_Request with the +// rules defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContext_RequestMultiError, or nil if none found. +func (m *AttributeContext_Request) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext_Request) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Id + + // no validation rules for Method + + // no validation rules for Headers + + // no validation rules for Path + + // no validation rules for Host + + // no validation rules for Scheme + + // no validation rules for Query + + if all { + switch v := interface{}(m.GetTime()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AttributeContext_RequestValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AttributeContext_RequestValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetTime()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AttributeContext_RequestValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + } + } + } + + // no validation rules for Size + + // no validation rules for Protocol + + // no validation rules for Reason + + if all { + switch v := interface{}(m.GetAuth()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AttributeContext_RequestValidationError{ + field: "Auth", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AttributeContext_RequestValidationError{ + field: "Auth", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetAuth()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AttributeContext_RequestValidationError{ + field: "Auth", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return AttributeContext_RequestMultiError(errors) + } + + return nil +} + +// AttributeContext_RequestMultiError is an error wrapping multiple validation +// errors returned by AttributeContext_Request.ValidateAll() if the designated +// constraints aren't met. +type AttributeContext_RequestMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContext_RequestMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContext_RequestMultiError) AllErrors() []error { return m } + +// AttributeContext_RequestValidationError is the validation error returned by +// AttributeContext_Request.Validate if the designated constraints aren't met. +type AttributeContext_RequestValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContext_RequestValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContext_RequestValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContext_RequestValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContext_RequestValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContext_RequestValidationError) ErrorName() string { + return "AttributeContext_RequestValidationError" +} + +// Error satisfies the builtin error interface +func (e AttributeContext_RequestValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext_Request.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContext_RequestValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContext_RequestValidationError{} + +// Validate checks the field values on AttributeContext_Response with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext_Response) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext_Response with the +// rules defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContext_ResponseMultiError, or nil if none found. +func (m *AttributeContext_Response) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext_Response) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Code + + // no validation rules for Size + + // no validation rules for Headers + + if all { + switch v := interface{}(m.GetTime()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, AttributeContext_ResponseValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, AttributeContext_ResponseValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetTime()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return AttributeContext_ResponseValidationError{ + field: "Time", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return AttributeContext_ResponseMultiError(errors) + } + + return nil +} + +// AttributeContext_ResponseMultiError is an error wrapping multiple validation +// errors returned by AttributeContext_Response.ValidateAll() if the +// designated constraints aren't met. +type AttributeContext_ResponseMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContext_ResponseMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContext_ResponseMultiError) AllErrors() []error { return m } + +// AttributeContext_ResponseValidationError is the validation error returned by +// AttributeContext_Response.Validate if the designated constraints aren't met. +type AttributeContext_ResponseValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContext_ResponseValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContext_ResponseValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContext_ResponseValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContext_ResponseValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContext_ResponseValidationError) ErrorName() string { + return "AttributeContext_ResponseValidationError" +} + +// Error satisfies the builtin error interface +func (e AttributeContext_ResponseValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext_Response.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContext_ResponseValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContext_ResponseValidationError{} + +// Validate checks the field values on AttributeContext_Resource with the rules +// defined in the proto definition for this message. If any rules are +// violated, the first error encountered is returned, or nil if there are no violations. +func (m *AttributeContext_Resource) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on AttributeContext_Resource with the +// rules defined in the proto definition for this message. If any rules are +// violated, the result is a list of violation errors wrapped in +// AttributeContext_ResourceMultiError, or nil if none found. +func (m *AttributeContext_Resource) ValidateAll() error { + return m.validate(true) +} + +func (m *AttributeContext_Resource) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for Service + + // no validation rules for Name + + // no validation rules for Type + + // no validation rules for Labels + + if len(errors) > 0 { + return AttributeContext_ResourceMultiError(errors) + } + + return nil +} + +// AttributeContext_ResourceMultiError is an error wrapping multiple validation +// errors returned by AttributeContext_Resource.ValidateAll() if the +// designated constraints aren't met. +type AttributeContext_ResourceMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m AttributeContext_ResourceMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m AttributeContext_ResourceMultiError) AllErrors() []error { return m } + +// AttributeContext_ResourceValidationError is the validation error returned by +// AttributeContext_Resource.Validate if the designated constraints aren't met. +type AttributeContext_ResourceValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e AttributeContext_ResourceValidationError) Field() string { return e.field } + +// Reason function returns reason value. +func (e AttributeContext_ResourceValidationError) Reason() string { return e.reason } + +// Cause function returns cause value. +func (e AttributeContext_ResourceValidationError) Cause() error { return e.cause } + +// Key function returns key value. +func (e AttributeContext_ResourceValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e AttributeContext_ResourceValidationError) ErrorName() string { + return "AttributeContext_ResourceValidationError" +} + +// Error satisfies the builtin error interface +func (e AttributeContext_ResourceValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sAttributeContext_Resource.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = AttributeContext_ResourceValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = AttributeContext_ResourceValidationError{} + +// Validate checks the field values on +// ServiceAccountDelegationInfo_FirstPartyPrincipal with the rules defined in +// the proto definition for this message. If any rules are violated, the first +// error encountered is returned, or nil if there are no violations. +func (m *ServiceAccountDelegationInfo_FirstPartyPrincipal) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on +// ServiceAccountDelegationInfo_FirstPartyPrincipal with the rules defined in +// the proto definition for this message. If any rules are violated, the +// result is a list of violation errors wrapped in +// ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError, or nil if none found. +func (m *ServiceAccountDelegationInfo_FirstPartyPrincipal) ValidateAll() error { + return m.validate(true) +} + +func (m *ServiceAccountDelegationInfo_FirstPartyPrincipal) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + // no validation rules for PrincipalEmail + + if all { + switch v := interface{}(m.GetServiceMetadata()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError{ + field: "ServiceMetadata", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError{ + field: "ServiceMetadata", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetServiceMetadata()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError{ + field: "ServiceMetadata", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError(errors) + } + + return nil +} + +// ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError is an error +// wrapping multiple validation errors returned by +// ServiceAccountDelegationInfo_FirstPartyPrincipal.ValidateAll() if the +// designated constraints aren't met. +type ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m ServiceAccountDelegationInfo_FirstPartyPrincipalMultiError) AllErrors() []error { return m } + +// ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError is the +// validation error returned by +// ServiceAccountDelegationInfo_FirstPartyPrincipal.Validate if the designated +// constraints aren't met. +type ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) Field() string { + return e.field +} + +// Reason function returns reason value. +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) Reason() string { + return e.reason +} + +// Cause function returns cause value. +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) Cause() error { + return e.cause +} + +// Key function returns key value. +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) ErrorName() string { + return "ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError" +} + +// Error satisfies the builtin error interface +func (e ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sServiceAccountDelegationInfo_FirstPartyPrincipal.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = ServiceAccountDelegationInfo_FirstPartyPrincipalValidationError{} + +// Validate checks the field values on +// ServiceAccountDelegationInfo_ThirdPartyPrincipal with the rules defined in +// the proto definition for this message. If any rules are violated, the first +// error encountered is returned, or nil if there are no violations. +func (m *ServiceAccountDelegationInfo_ThirdPartyPrincipal) Validate() error { + return m.validate(false) +} + +// ValidateAll checks the field values on +// ServiceAccountDelegationInfo_ThirdPartyPrincipal with the rules defined in +// the proto definition for this message. If any rules are violated, the +// result is a list of violation errors wrapped in +// ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError, or nil if none found. +func (m *ServiceAccountDelegationInfo_ThirdPartyPrincipal) ValidateAll() error { + return m.validate(true) +} + +func (m *ServiceAccountDelegationInfo_ThirdPartyPrincipal) validate(all bool) error { + if m == nil { + return nil + } + + var errors []error + + if all { + switch v := interface{}(m.GetThirdPartyClaims()).(type) { + case interface{ ValidateAll() error }: + if err := v.ValidateAll(); err != nil { + errors = append(errors, ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError{ + field: "ThirdPartyClaims", + reason: "embedded message failed validation", + cause: err, + }) + } + case interface{ Validate() error }: + if err := v.Validate(); err != nil { + errors = append(errors, ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError{ + field: "ThirdPartyClaims", + reason: "embedded message failed validation", + cause: err, + }) + } + } + } else if v, ok := interface{}(m.GetThirdPartyClaims()).(interface{ Validate() error }); ok { + if err := v.Validate(); err != nil { + return ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError{ + field: "ThirdPartyClaims", + reason: "embedded message failed validation", + cause: err, + } + } + } + + if len(errors) > 0 { + return ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError(errors) + } + + return nil +} + +// ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError is an error +// wrapping multiple validation errors returned by +// ServiceAccountDelegationInfo_ThirdPartyPrincipal.ValidateAll() if the +// designated constraints aren't met. +type ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError []error + +// Error returns a concatenation of all the error messages it wraps. +func (m ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError) Error() string { + var msgs []string + for _, err := range m { + msgs = append(msgs, err.Error()) + } + return strings.Join(msgs, "; ") +} + +// AllErrors returns a list of validation violation errors. +func (m ServiceAccountDelegationInfo_ThirdPartyPrincipalMultiError) AllErrors() []error { return m } + +// ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError is the +// validation error returned by +// ServiceAccountDelegationInfo_ThirdPartyPrincipal.Validate if the designated +// constraints aren't met. +type ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError struct { + field string + reason string + cause error + key bool +} + +// Field function returns field value. +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) Field() string { + return e.field +} + +// Reason function returns reason value. +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) Reason() string { + return e.reason +} + +// Cause function returns cause value. +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) Cause() error { + return e.cause +} + +// Key function returns key value. +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) Key() bool { return e.key } + +// ErrorName returns error name. +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) ErrorName() string { + return "ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError" +} + +// Error satisfies the builtin error interface +func (e ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError) Error() string { + cause := "" + if e.cause != nil { + cause = fmt.Sprintf(" | caused by: %v", e.cause) + } + + key := "" + if e.key { + key = "key for " + } + + return fmt.Sprintf( + "invalid %sServiceAccountDelegationInfo_ThirdPartyPrincipal.%s: %s%s", + key, + e.field, + e.reason, + cause) +} + +var _ error = ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError{} + +var _ interface { + Field() string + Reason() string + Key() bool + Cause() error + ErrorName() string +} = ServiceAccountDelegationInfo_ThirdPartyPrincipalValidationError{} diff --git a/proto/audit/v1/audit_event.proto b/proto/audit/v1/audit_event.proto index b29bad8..69cb8ee 100644 --- a/proto/audit/v1/audit_event.proto +++ b/proto/audit/v1/audit_event.proto @@ -1,9 +1,9 @@ syntax = "proto3"; import "buf/validate/validate.proto"; +import "google/protobuf/any.proto"; import "google/protobuf/struct.proto"; import "google/protobuf/timestamp.proto"; -import "google/protobuf/wrappers.proto"; import "audit/v1/common.proto"; @@ -13,98 +13,621 @@ option go_package = "./audit;auditV1"; option java_multiple_files = true; option java_package = "com.schwarz.stackit.audit.v1"; -enum EventTrigger { - EVENT_TRIGGER_UNSPECIFIED = 0; - // Event from messaging system - EVENT_TRIGGER_EVENT = 1; - // Time based scheduler - EVENT_TRIGGER_SCHEDULER = 2; - // Network request (REST, gRPC, etc.) - EVENT_TRIGGER_REQUEST = 3; -} - -enum Region { - REGION_UNSPECIFIED = 0; - REGION_EU01 = 1; -} - -message Principal { - // A UUID or another kind of identifier - string id = 1 [(buf.validate.field).required = true]; - optional string email = 2 [(buf.validate.field).string.email = true, (buf.validate.field).string.max_len = 255]; -} - -message RequestDetails { - string endpoint = 1 [(buf.validate.field).required = true, (buf.validate.field).string.min_len = 1, (buf.validate.field).string.max_len = 255]; - // Accepts ipv4 and ipv6 - string source_ip_address = 2 [(buf.validate.field).required = true, (buf.validate.field).string.ip = true]; - optional string user_agent = 3 [(buf.validate.field).required = true, (buf.validate.field).string.min_len = 1, (buf.validate.field).string.max_len = 255]; - optional google.protobuf.Struct parameters = 4; - optional google.protobuf.Struct body = 5; - repeated RequestHeader headers = 6; -} - -// Key-value pair for request headers. Key and value are mandatory. -message RequestHeader { - string key = 1 [(buf.validate.field).required = true, (buf.validate.field).string.min_len = 1]; - string value = 2 [(buf.validate.field).required = true, (buf.validate.field).string.min_len = 1]; -} - +// The data within all Cloud Audit Logs log entry events. +// Equivalent to Google's LogEntryData. message AuditEvent { - // Validate that "request" details are set if the event trigger is set to "EVENT_REQUEST" - option (buf.validate.message).cel = { - id: "request.details" - message: "request details must be set" - expression: "this.event_trigger == 3 && has(this.request) || this.event_trigger != 3" - }; + // The resource name of the log to which this log entry belongs. + string log_name = 12; - // Name of the source system - string event_source = 1 [(buf.validate.field).required = true, (buf.validate.field).string.min_len = 1]; + // The monitored resource that produced this log entry. + // + // Example: a log entry that reports a database error would be associated with + // the monitored resource designating the particular database that reported + // the error. + MonitoredResource resource = 8; - Region region = 2 [(buf.validate.field).required = true]; + // The log entry payload, which is always an AuditLog for Cloud Audit Log + // events. + AuditLog proto_payload = 2; - // Sequence number of event sent by the service to identify missing events. - google.protobuf.Int64Value sequence_number = 3 [(buf.validate.field).required = true, (buf.validate.field).int64.gte = -1]; + // A unique identifier for the log entry. + string insert_id = 4; - // Functional event name with pattern _, e.g. ORGANIZATION_CREATED - // Important for filtering and translation / verbalization of event types - // in the UI or data sinks. - string event_name = 4 [(buf.validate.field).required = true, (buf.validate.field).string.pattern = "^[A-Z]+_[A-Z]+$"]; + // A set of user-defined (key, value) data that provides additional + // information about the log entry. + map labels = 11; - // The time when the event happened. Must not be a value in the future. - google.protobuf.Timestamp event_time_stamp = 5 [(buf.validate.field).required = true, (buf.validate.field).timestamp.lt_now = true]; + // Information about an operation associated with the log entry, if + // applicable. + LogEntryOperation operation = 15; - EventTrigger event_trigger = 6 [(buf.validate.field).required = true, (buf.validate.field).enum.defined_only = true]; + // The time the event described by the log entry occurred. + google.protobuf.Timestamp timestamp = 9; - // Request details - mandatory if event_trigger is set to "EVENT_REQUEST" - optional RequestDetails request = 7; + // The time the log entry was received by Logging. + google.protobuf.Timestamp receive_timestamp = 24; - Principal initiator = 8 [(buf.validate.field).required = true]; + // The severity of the log entry. + LogSeverity severity = 10; - // List of service account delegation principals. - // -> Chain from service account to the actual user who initiated the action. - repeated Principal principals = 9; + // Resource name of the trace associated with the log entry, if any. If it + // contains a relative resource name, the name is assumed to be relative to + // `//tracing.googleapis.com`. Example: + // `projects/my-projectid/traces/06796866738c859f2f19b7cfb3214824` + string trace = 22; - // Identifier the audit log event refers to - oneof resource_container_reference { - option (buf.validate.oneof).required = true; - // If it is a technical event not related to an organization, folder or project - // Will NOT be routed to the end-user, only for internal analysis -> - // Clarify what do in the router - ObjectName object_name = 10; - ObjectIdentifier object_identifier = 11; + // The span ID within the trace associated with the log entry, if any. + // + // For Trace spans, this is the same format that the Trace API v2 uses: a + // 16-character hexadecimal encoding of an 8-byte array, such as + // `000000000000004a`. + string span_id = 27; + + // Information indicating this LogEntry is part of a sequence of multiple logs + // split from a single LogEntry. + LogSplit split = 35; +} + +// An object representing a resource that can be used for monitoring, logging, +// billing, or other purposes. +message MonitoredResource { + // Required. The monitored resource type. For example, the type of a + // Compute Engine VM instance is `gce_instance`. + string type = 1; + + // Values for all of the labels listed in the associated monitored + // resource descriptor. For example, Compute Engine VM instances use the + // labels `"project_id"`, `"instance_id"`, and `"zone"`. + map labels = 2; +} + +// Additional information about a potentially long-running operation with which +// a log entry is associated. +message LogEntryOperation { + // An arbitrary operation identifier. Log entries with the same + // identifier are assumed to be part of the same operation. + string id = 1; + + // An arbitrary producer identifier. The combination of `id` and + // `producer` must be globally unique. Examples for `producer`: + // `"MyDivision.MyBigCompany.com"`, `"github.com/MyProject/MyApplication"`. + string producer = 2; + + // True if this is the first log entry in the operation. + bool first = 3; + + // True if this is the last log entry in the operation. + bool last = 4; +} + +// The severity of the event described in a log entry, expressed as one of the +// standard severity levels listed below. For your reference, the levels are +// assigned the listed numeric values. The effect of using numeric values other +// than those listed is undefined. +// Copied from +// https://github.com/googleapis/googleapis/blob/master/google/logging/type/log_severity.proto +enum LogSeverity { + // (0) The log entry has no assigned severity level. + DEFAULT = 0; + + // (100) Debug or trace information. + DEBUG = 100; + + // (200) Routine information, such as ongoing status or performance. + INFO = 200; + + // (300) Normal but significant events, such as start up, shut down, or + // a configuration change. + NOTICE = 300; + + // (400) Warning events might cause problems. + WARNING = 400; + + // (500) Error events are likely to cause problems. + ERROR = 500; + + // (600) Critical events cause more severe problems or outages. + CRITICAL = 600; + + // (700) A person must take an action immediately. + ALERT = 700; + + // (800) One or more systems are unusable. + EMERGENCY = 800; +} + +// Common audit log format for Google Cloud Platform API operations. +// Copied from +// https://github.com/googleapis/googleapis/blob/master/google/cloud/audit/audit_log.proto, +// but changing service_data from Any to Struct. +message AuditLog { + // The name of the API service performing the operation. For example, + // `"datastore.googleapis.com"`. + string service_name = 7; + + // The name of the service method or operation. + // For API calls, this should be the name of the API method. + // For example, + // + // "google.datastore.v1.Datastore.RunQuery" + // "google.logging.v1.LoggingService.DeleteLog" + string method_name = 8; + + // The resource or collection that is the target of the operation. + // The name is a scheme-less URI, not including the API service name. + // For example: + // + // "shelves/SHELF_ID/books" + // "shelves/SHELF_ID/books/BOOK_ID" + string resource_name = 11; + + // The resource location information. + ResourceLocation resource_location = 20; + + // The resource's original state before mutation. Present only for + // operations which have successfully modified the targeted resource(s). + // In general, this field should contain all changed fields, except those + // that are already been included in `request`, `response`, `metadata` or + // `service_data` fields. + // When the JSON object represented here has a proto equivalent, + // the proto name will be indicated in the `@type` property. + google.protobuf.Struct resource_original_state = 19; + + // The number of items returned from a List or Query API method, + // if applicable. + int64 num_response_items = 12; + + // The status of the overall operation. + RpcStatus status = 2; + + // Authentication information. + AuthenticationInfo authentication_info = 3; + + // Authorization information. If there are multiple + // resources or permissions involved, then there is + // one AuthorizationInfo element for each {resource, permission} tuple. + repeated AuthorizationInfo authorization_info = 9; + + // Metadata about the operation. + RequestMetadata request_metadata = 4; + + // The operation request. This may not include all request parameters, + // such as those that are too large, privacy-sensitive, or duplicated + // elsewhere in the log record. + // It should never include user-generated data, such as file contents. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + google.protobuf.Struct request = 16; + + // The operation response. This may not include all response elements, + // such as those that are too large, privacy-sensitive, or duplicated + // elsewhere in the log record. + // It should never include user-generated data, such as file contents. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + google.protobuf.Struct response = 17; + + // Other service-specific data about the request, response, and other + // information associated with the current audited event. + google.protobuf.Struct metadata = 18; + + // Deprecated: Use `metadata` field instead. + // Other service-specific data about the request, response, and other + // activities. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + google.protobuf.Struct service_data = 15; +} + +// Authentication information for the operation. +message AuthenticationInfo { + // The email address of the authenticated user (or service account on behalf + // of third party principal) making the request. For third party identity + // callers, the `principal_subject` field is populated instead of this field. + // For privacy reasons, the principal email address is sometimes redacted. + // For more information, see [Caller identities in audit + // logs](https://cloud.google.com/logging/docs/audit#user-id). + string principal_email = 1; + + // The authority selector specified by the requestor, if any. + // It is not guaranteed that the principal was allowed to use this authority. + string authority_selector = 2; + + // The third party identification (if any) of the authenticated user making + // the request. + // When the JSON object represented here has a proto equivalent, the proto + // name will be indicated in the `@type` property. + google.protobuf.Struct third_party_principal = 4; + + // The name of the service account key used to create or exchange + // credentials for authenticating the service account making the request. + // This is a scheme-less URI full resource name. For example: + // + // "//iam.googleapis.com/projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}/keys/{key}" + string service_account_key_name = 5; + + // Identity delegation history of an authenticated service account that makes + // the request. It contains information on the real authorities that try to + // access GCP resources by delegating on a service account. When multiple + // authorities present, they are guaranteed to be sorted based on the original + // ordering of the identity delegation events. + repeated ServiceAccountDelegationInfo service_account_delegation_info = 6; + + // String representation of identity of requesting party. + // Populated for both first and third party identities. + string principal_subject = 8; +} + +// Authorization information for the operation. +message AuthorizationInfo { + // The resource being accessed, as a REST-style string. For example: + // + // bigquery.googleapis.com/projects/PROJECTID/datasets/DATASETID + string resource = 1; + + // The required IAM permission. + string permission = 2; + + // Whether or not authorization for `resource` and `permission` + // was granted. + bool granted = 3; + + // Resource attributes used in IAM condition evaluation. This field contains + // resource attributes like resource type and resource name. + // + // To get the whole view of the attributes used in IAM + // condition evaluation, the user must also look into + // `AuditLogData.request_metadata.request_attributes`. + AttributeContext.Resource resource_attributes = 5; +} + +// This message defines the standard attribute vocabulary for Google APIs. +// +// An attribute is a piece of metadata that describes an activity on a network +// service. For example, the size of an HTTP request, or the status code of +// an HTTP response. +// +// Each attribute has a type and a name, which is logically defined as +// a proto message field in `AttributeContext`. The field type becomes the +// attribute type, and the field path becomes the attribute name. For example, +// the attribute `source.ip` maps to field `AttributeContext.source.ip`. +// +// This message definition is guaranteed not to have any wire breaking change. +// So you can use it directly for passing attributes across different systems. +// +// NOTE: Different system may generate different subset of attributes. Please +// verify the system specification before relying on an attribute generated +// a system. +message AttributeContext { + // This message defines attributes for a node that handles a network request. + // The node can be either a service or an application that sends, forwards, + // or receives the request. Service peers should fill in + // `principal` and `labels` as appropriate. + message Peer { + // The IP address of the peer. + string ip = 1; + + // The network port of the peer. + int64 port = 2; + + // The labels associated with the peer. + map labels = 6; + + // The identity of this peer. Similar to `Request.auth.principal`, but + // relative to the peer instead of the request. For example, the + // idenity associated with a load balancer that forwared the request. + string principal = 7; + + // The CLDR country/region code associated with the above IP address. + // If the IP address is private, the `region_code` should reflect the + // physical location where this peer is running. + string region_code = 8; } - // The identifier of the actual resource (e.g. a VM) - optional string resource_id = 12 [(buf.validate.field).string.min_len = 1, (buf.validate.field).string.max_len = 255]; + // This message defines request authentication attributes. Terminology is + // based on the JSON Web Token (JWT) standard, but the terms also + // correlate to concepts in other standards. + message Auth { + // The authenticated principal. Reflects the issuer (`iss`) and subject + // (`sub`) claims within a JWT. The issuer and subject should be `/` + // delimited, with `/` percent-encoded within the subject fragment. For + // Google accounts, the principal format is: + // "https://accounts.google.com/{id}" + string principal = 1; - optional string resource_name = 13 [(buf.validate.field).string.min_len = 1, (buf.validate.field).string.max_len = 255]; + // The intended audience(s) for this authentication information. Reflects + // the audience (`aud`) claim within a JWT. The audience + // value(s) depends on the `issuer`, but typically include one or more of + // the following pieces of information: + // + // * The services intended to receive the credential such as + // ["pubsub.googleapis.com", "storage.googleapis.com"] + // * A set of service-based scopes. For example, + // ["https://www.googleapis.com/auth/cloud-platform"] + // * The client id of an app, such as the Firebase project id for JWTs + // from Firebase Auth. + // + // Consult the documentation for the credential issuer to determine the + // information provided. + repeated string audiences = 2; - optional string correlation_id = 14 [(buf.validate.field).string.min_len = 1, (buf.validate.field).string.max_len = 255]; + // The authorized presenter of the credential. Reflects the optional + // Authorized Presenter (`azp`) claim within a JWT or the + // OAuth client id. For example, a Google Cloud Platform client id looks + // as follows: "123456789012.apps.googleusercontent.com". + string presenter = 3; - // Result of the operation to publish with the event - optional google.protobuf.Struct result = 15; + // Structured claims presented with the credential. JWTs include + // `{key: value}` pairs for standard and private claims. The following + // is a subset of the standard required and optional claims that would + // typically be presented for a Google-based JWT: + // + // {'iss': 'accounts.google.com', + // 'sub': '113289723416554971153', + // 'aud': ['123456789012', 'pubsub.googleapis.com'], + // 'azp': '123456789012.apps.googleusercontent.com', + // 'email': 'jsmith@example.com', + // 'iat': 1353601026, + // 'exp': 1353604926} + // + // SAML assertions are similarly specified, but with an identity provider + // dependent structure. + google.protobuf.Struct claims = 4; - // Additional information to publish with the event - optional google.protobuf.Struct details = 16; + // A list of access level resource names that allow resources to be + // accessed by authenticated requester. It is part of Secure GCP processing + // for the incoming request. An access level string has the format: + // "//{api_service_name}/accessPolicies/{policy_id}/accessLevels/{short_name}" + // + // Example: + // "//accesscontextmanager.googleapis.com/accessPolicies/MY_POLICY_ID/accessLevels/MY_LEVEL" + repeated string access_levels = 5; + } + + // This message defines attributes for an HTTP request. If the actual + // request is not an HTTP request, the runtime system should try to map + // the actual request to an equivalent HTTP request. + message Request { + // The unique ID for a request, which can be propagated to downstream + // systems. The ID should have low probability of collision + // within a single day for a specific service. + string id = 1; + + // The HTTP request method, such as `GET`, `POST`. + string method = 2; + + // The HTTP request headers. If multiple headers share the same key, they + // must be merged according to the HTTP spec. All header keys must be + // lowercased, because HTTP header keys are case-insensitive. + map headers = 3; + + // The HTTP URL path. + string path = 4; + + // The HTTP request `Host` header value. + string host = 5; + + // The HTTP URL scheme, such as `http` and `https`. + string scheme = 6; + + // The HTTP URL query in the format of `name1=value1&name2=value2`, as it + // appears in the first line of the HTTP request. No decoding is performed. + string query = 7; + + // The timestamp when the `destination` service receives the first byte of + // the request. + google.protobuf.Timestamp time = 9; + + // The HTTP request size in bytes. If unknown, it must be -1. + int64 size = 10; + + // The network protocol used with the request, such as "http/1.1", + // "spdy/3", "h2", "h2c", "webrtc", "tcp", "udp", "quic". See + // https://www.iana.org/assignments/tls-extensiontype-values/tls-extensiontype-values.xhtml#alpn-protocol-ids + // for details. + string protocol = 11; + + // A special parameter for request reason. It is used by security systems + // to associate auditing information with a request. + string reason = 12; + + // The request authentication. May be absent for unauthenticated requests. + // Derived from the HTTP request `Authorization` header or equivalent. + Auth auth = 13; + } + + // This message defines attributes for a typical network response. It + // generally models semantics of an HTTP response. + message Response { + // The HTTP response status code, such as `200` and `404`. + int64 code = 1; + + // The HTTP response size in bytes. If unknown, it must be -1. + int64 size = 2; + + // The HTTP response headers. If multiple headers share the same key, they + // must be merged according to HTTP spec. All header keys must be + // lowercased, because HTTP header keys are case-insensitive. + map headers = 3; + + // The timestamp when the `destination` service generates the first byte of + // the response. + google.protobuf.Timestamp time = 4; + } + + // This message defines core attributes for a resource. A resource is an + // addressable (named) entity provided by the destination service. For + // example, a file stored on a network storage service. + message Resource { + // The name of the service that this resource belongs to, such as + // `pubsub.googleapis.com`. The service may be different from the DNS + // hostname that actually serves the request. + string service = 1; + + // The stable identifier (name) of a resource on the `service`. A resource + // can be logically identified as "//{resource.service}/{resource.name}". + // The differences between a resource name and a URI are: + // + // * Resource name is a logical identifier, independent of network + // protocol and API version. For example, + // `//pubsub.googleapis.com/projects/123/topics/news-feed`. + // * URI often includes protocol and version information, so it can + // be used directly by applications. For example, + // `https://pubsub.googleapis.com/v1/projects/123/topics/news-feed`. + // + // See https://cloud.google.com/apis/design/resource_names for details. + string name = 2; + + // The type of the resource. The syntax is platform-specific because + // different platforms define their resources differently. + // + // For Google APIs, the type format must be "{service}/{kind}". + string type = 3; + + // The labels or tags on the resource, such as AWS resource tags and + // Kubernetes resource labels. + map labels = 4; + } +} + +// Metadata about the request. +message RequestMetadata { + // The IP address of the caller. + // For caller from internet, this will be public IPv4 or IPv6 address. + // For caller from a Compute Engine VM with external IP address, this + // will be the VM's external IP address. For caller from a Compute + // Engine VM without external IP address, if the VM is in the same + // organization (or project) as the accessed resource, `caller_ip` will + // be the VM's internal IPv4 address, otherwise the `caller_ip` will be + // redacted to "gce-internal-ip". + // See https://cloud.google.com/compute/docs/vpc/ for more information. + string caller_ip = 1; + + // The user agent of the caller. + // This information is not authenticated and should be treated accordingly. + // For example: + // + // + `google-api-python-client/1.4.0`: + // The request was made by the Google API client for Python. + // + `Cloud SDK Command Line Tool apitools-client/1.0 gcloud/0.9.62`: + // The request was made by the Google Cloud SDK CLI (gcloud). + // + `AppEngine-Google; (+http://code.google.com/appengine; appid: + // s~my-project`: + // The request was made from the `my-project` App Engine app. + string caller_supplied_user_agent = 2; + + // The network of the caller. + // Set only if the network host project is part of the same GCP organization + // (or project) as the accessed resource. + // See https://cloud.google.com/compute/docs/vpc/ for more information. + // This is a scheme-less URI full resource name. For example: + // + // "//compute.googleapis.com/projects/PROJECT_ID/global/networks/NETWORK_ID" + string caller_network = 3; + + // Request attributes used in IAM condition evaluation. This field contains + // request attributes like request time and access levels associated with + // the request. + // + // + // To get the whole view of the attributes used in IAM + // condition evaluation, the user must also look into + // `AuditLog.authentication_info.resource_attributes`. + AttributeContext.Request request_attributes = 7; + + // The destination of a network activity, such as accepting a TCP connection. + // In a multi hop network activity, the destination represents the receiver of + // the last hop. Only two fields are used in this message, Peer.port and + // Peer.ip. These fields are optionally populated by those services utilizing + // the IAM condition feature. + AttributeContext.Peer destination_attributes = 8; +} + +// Location information about a resource. +message ResourceLocation { + // The locations of a resource after the execution of the operation. + // Requests to create or delete a location based resource must populate + // the 'current_locations' field and not the 'original_locations' field. + // For example: + // + // "europe-west1-a" + // "us-east1" + // "nam3" + repeated string current_locations = 1; + + // The locations of a resource prior to the execution of the operation. + // Requests that mutate the resource's location must populate both the + // 'original_locations' as well as the 'current_locations' fields. + // For example: + // + // "europe-west1-a" + // "us-east1" + // "nam3" + repeated string original_locations = 2; +} + +// The `Status` type defines a logical error model that is suitable for +// different programming environments, including REST APIs and RPC APIs. It is +// used by [gRPC](https://github.com/grpc). Each `Status` message contains +// three pieces of data: error code, error message, and error details. +// +// You can find out more about this error model and how to work with it in the +// [API Design Guide](https://cloud.google.com/apis/design/errors). +message RpcStatus { + // The status code, which should be an enum value of [google.rpc.Code][google.rpc.Code]. + int32 code = 1; + + // A developer-facing error message, which should be in English. Any + // user-facing error message should be localized and sent in the + // [google.rpc.Status.details][google.rpc.Status.details] field, or localized by the client. + string message = 2; + + // A list of messages that carry the error details. There is a common set of + // message types for APIs to use. + repeated google.protobuf.Any details = 3; +} + +// Identity delegation history of an authenticated service account. +message ServiceAccountDelegationInfo { + // First party identity principal. + message FirstPartyPrincipal { + // The email address of a Google account. + string principal_email = 1; + + // Metadata about the service that uses the service account. + google.protobuf.Struct service_metadata = 2; + } + + // Third party identity principal. + message ThirdPartyPrincipal { + // Metadata about third party identity. + google.protobuf.Struct third_party_claims = 1; + } + + // Entity that creates credentials for service account and assumes its + // identity for authentication. + oneof Authority { + // First party (Google) identity as the real authority. + FirstPartyPrincipal first_party_principal = 1; + + // Third party identity as the real authority. + ThirdPartyPrincipal third_party_principal = 2; + } +} + +// Additional information used to correlate multiple LogEntries. Used when a +// single LogEntry would exceed the Google Cloud Logging size limit and is split +// across multiple entries. +message LogSplit { + // A globally unique identifier for all LogEntries in a sequence of split + // logs. All LogEntries with the same |LogSplit.uid| are assumed to be part of + // the same sequence of split logs. + string uid = 1; + + // The index of this LogEntry in the sequence of split logs. LogEntries are + // given |index| values 0, 1, ..., n-1 for a sequence of n entries. + int32 index = 2; + + // The total number of logs that the original LogEntry was split into. + int32 total_splits = 3; } \ No newline at end of file