Debian Codegraph @

googleapis/rpc/context/audit_context.pb.go

raw
1 // Copyright 2026 Google LLC
2 //
3 // Licensed under the Apache License, Version 2.0 (the "License");
4 // you may not use this file except in compliance with the License.
5 // You may obtain a copy of the License at
6 //
7 // http://www.apache.org/licenses/LICENSE-2.0
8 //
9 // Unless required by applicable law or agreed to in writing, software
10 // distributed under the License is distributed on an "AS IS" BASIS,
11 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 // See the License for the specific language governing permissions and
13 // limitations under the License.
14
15 // Code generated by protoc-gen-go. DO NOT EDIT.
16 // versions:
17 // protoc-gen-go v1.26.0
18 // protoc v4.24.4
19 // source: google/rpc/context/audit_context.proto
20
21 package context
22
23 import (
24 reflect "reflect"
25 sync "sync"
26
27 protoreflect "google.golang.org/protobuf/reflect/protoreflect"
28 protoimpl "google.golang.org/protobuf/runtime/protoimpl"
29 structpb "google.golang.org/protobuf/types/known/structpb"
30 )
31
32 const (
33 // Verify that this generated code is sufficiently up-to-date.
34 _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
35 // Verify that runtime/protoimpl is sufficiently up-to-date.
36 _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
37 )
38
39 // `AuditContext` provides information that is needed for audit logging.
40 type AuditContext struct {
41 state protoimpl.MessageState
42 sizeCache protoimpl.SizeCache
43 unknownFields protoimpl.UnknownFields
44
45 // Serialized audit log.
46 AuditLog []byte `protobuf:"bytes,1,opt,name=audit_log,json=auditLog,proto3" json:"audit_log,omitempty"`
47 // An API request message that is scrubbed based on the method annotation.
48 // This field should only be filled if audit_log field is present.
49 // Service Control will use this to assemble a complete log for Cloud Audit
50 // Logs and Google internal audit logs.
51 ScrubbedRequest *structpb.Struct `protobuf:"bytes,2,opt,name=scrubbed_request,json=scrubbedRequest,proto3" json:"scrubbed_request,omitempty"`
52 // An API response message that is scrubbed based on the method annotation.
53 // This field should only be filled if audit_log field is present.
54 // Service Control will use this to assemble a complete log for Cloud Audit
55 // Logs and Google internal audit logs.
56 ScrubbedResponse *structpb.Struct `protobuf:"bytes,3,opt,name=scrubbed_response,json=scrubbedResponse,proto3" json:"scrubbed_response,omitempty"`
57 // Number of scrubbed response items.
58 ScrubbedResponseItemCount int32 `protobuf:"varint,4,opt,name=scrubbed_response_item_count,json=scrubbedResponseItemCount,proto3" json:"scrubbed_response_item_count,omitempty"`
59 // Audit resource name which is scrubbed.
60 TargetResource string `protobuf:"bytes,5,opt,name=target_resource,json=targetResource,proto3" json:"target_resource,omitempty"`
61 }
62
63 func (x *AuditContext) Reset() {
64 *x = AuditContext{}
65 if protoimpl.UnsafeEnabled {
66 mi := &file_google_rpc_context_audit_context_proto_msgTypes[0]
67 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
68 ms.StoreMessageInfo(mi)
69 }
70 }
71
72 func (x *AuditContext) String() string {
73 return protoimpl.X.MessageStringOf(x)
74 }
75
76 func (*AuditContext) ProtoMessage() {}
77
78 func (x *AuditContext) ProtoReflect() protoreflect.Message {
79 mi := &file_google_rpc_context_audit_context_proto_msgTypes[0]
80 if protoimpl.UnsafeEnabled && x != nil {
81 ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
82 if ms.LoadMessageInfo() == nil {
83 ms.StoreMessageInfo(mi)
84 }
85 return ms
86 }
87 return mi.MessageOf(x)
88 }
89
90 // Deprecated: Use AuditContext.ProtoReflect.Descriptor instead.
91 func (*AuditContext) Descriptor() ([]byte, []int) {
92 return file_google_rpc_context_audit_context_proto_rawDescGZIP(), []int{0}
93 }
94
95 func (x *AuditContext) GetAuditLog() []byte {
96 if x != nil {
97 return x.AuditLog
98 }
99 return nil
100 }
101
102 func (x *AuditContext) GetScrubbedRequest() *structpb.Struct {
103 if x != nil {
104 return x.ScrubbedRequest
105 }
106 return nil
107 }
108
109 func (x *AuditContext) GetScrubbedResponse() *structpb.Struct {
110 if x != nil {
111 return x.ScrubbedResponse
112 }
113 return nil
114 }
115
116 func (x *AuditContext) GetScrubbedResponseItemCount() int32 {
117 if x != nil {
118 return x.ScrubbedResponseItemCount
119 }
120 return 0
121 }
122
123 func (x *AuditContext) GetTargetResource() string {
124 if x != nil {
125 return x.TargetResource
126 }
127 return ""
128 }
129
130 var File_google_rpc_context_audit_context_proto protoreflect.FileDescriptor
131
132 var file_google_rpc_context_audit_context_proto_rawDesc = []byte{
133 0x0a, 0x26, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x6f, 0x6e,
134 0x74, 0x65, 0x78, 0x74, 0x2f, 0x61, 0x75, 0x64, 0x69, 0x74, 0x5f, 0x63, 0x6f, 0x6e, 0x74, 0x65,
135 0x78, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x12, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
136 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x1a, 0x1c, 0x67, 0x6f,
137 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x73, 0x74,
138 0x72, 0x75, 0x63, 0x74, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x9f, 0x02, 0x0a, 0x0c, 0x41,
139 0x75, 0x64, 0x69, 0x74, 0x43, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x12, 0x1b, 0x0a, 0x09, 0x61,
140 0x75, 0x64, 0x69, 0x74, 0x5f, 0x6c, 0x6f, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08,
141 0x61, 0x75, 0x64, 0x69, 0x74, 0x4c, 0x6f, 0x67, 0x12, 0x42, 0x0a, 0x10, 0x73, 0x63, 0x72, 0x75,
142 0x62, 0x62, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x18, 0x02, 0x20, 0x01,
143 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74,
144 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74, 0x52, 0x0f, 0x73, 0x63, 0x72,
145 0x75, 0x62, 0x62, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x44, 0x0a, 0x11,
146 0x73, 0x63, 0x72, 0x75, 0x62, 0x62, 0x65, 0x64, 0x5f, 0x72, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73,
147 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65,
148 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x53, 0x74, 0x72, 0x75, 0x63, 0x74,
149 0x52, 0x10, 0x73, 0x63, 0x72, 0x75, 0x62, 0x62, 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e,
150 0x73, 0x65, 0x12, 0x3f, 0x0a, 0x1c, 0x73, 0x63, 0x72, 0x75, 0x62, 0x62, 0x65, 0x64, 0x5f, 0x72,
151 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x5f, 0x69, 0x74, 0x65, 0x6d, 0x5f, 0x63, 0x6f, 0x75,
152 0x6e, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x19, 0x73, 0x63, 0x72, 0x75, 0x62, 0x62,
153 0x65, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x49, 0x74, 0x65, 0x6d, 0x43, 0x6f,
154 0x75, 0x6e, 0x74, 0x12, 0x27, 0x0a, 0x0f, 0x74, 0x61, 0x72, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x65,
155 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0e, 0x74, 0x61,
156 0x72, 0x67, 0x65, 0x74, 0x52, 0x65, 0x73, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x42, 0x68, 0x0a, 0x16,
157 0x63, 0x6f, 0x6d, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x72, 0x70, 0x63, 0x2e, 0x63,
158 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x42, 0x11, 0x41, 0x75, 0x64, 0x69, 0x74, 0x43, 0x6f, 0x6e,
159 0x74, 0x65, 0x78, 0x74, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x39, 0x67, 0x6f, 0x6f,
160 0x67, 0x6c, 0x65, 0x2e, 0x67, 0x6f, 0x6c, 0x61, 0x6e, 0x67, 0x2e, 0x6f, 0x72, 0x67, 0x2f, 0x67,
161 0x65, 0x6e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x61, 0x70,
162 0x69, 0x73, 0x2f, 0x72, 0x70, 0x63, 0x2f, 0x63, 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x3b, 0x63,
163 0x6f, 0x6e, 0x74, 0x65, 0x78, 0x74, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
164 }
165
166 var (
167 file_google_rpc_context_audit_context_proto_rawDescOnce sync.Once
168 file_google_rpc_context_audit_context_proto_rawDescData = file_google_rpc_context_audit_context_proto_rawDesc
169 )
170
171 func file_google_rpc_context_audit_context_proto_rawDescGZIP() []byte {
172 file_google_rpc_context_audit_context_proto_rawDescOnce.Do(func() {
173 file_google_rpc_context_audit_context_proto_rawDescData = protoimpl.X.CompressGZIP(file_google_rpc_context_audit_context_proto_rawDescData)
174 })
175 return file_google_rpc_context_audit_context_proto_rawDescData
176 }
177
178 var file_google_rpc_context_audit_context_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
179 var file_google_rpc_context_audit_context_proto_goTypes = []interface{}{
180 (*AuditContext)(nil), // 0: google.rpc.context.AuditContext
181 (*structpb.Struct)(nil), // 1: google.protobuf.Struct
182 }
183 var file_google_rpc_context_audit_context_proto_depIdxs = []int32{
184 1, // 0: google.rpc.context.AuditContext.scrubbed_request:type_name -> google.protobuf.Struct
185 1, // 1: google.rpc.context.AuditContext.scrubbed_response:type_name -> google.protobuf.Struct
186 2, // [2:2] is the sub-list for method output_type
187 2, // [2:2] is the sub-list for method input_type
188 2, // [2:2] is the sub-list for extension type_name
189 2, // [2:2] is the sub-list for extension extendee
190 0, // [0:2] is the sub-list for field type_name
191 }
192
193 func init() { file_google_rpc_context_audit_context_proto_init() }
194 func file_google_rpc_context_audit_context_proto_init() {
195 if File_google_rpc_context_audit_context_proto != nil {
196 return
197 }
198 if !protoimpl.UnsafeEnabled {
199 file_google_rpc_context_audit_context_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
200 switch v := v.(*AuditContext); i {
201 case 0:
202 return &v.state
203 case 1:
204 return &v.sizeCache
205 case 2:
206 return &v.unknownFields
207 default:
208 return nil
209 }
210 }
211 }
212 type x struct{}
213 out := protoimpl.TypeBuilder{
214 File: protoimpl.DescBuilder{
215 GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
216 RawDescriptor: file_google_rpc_context_audit_context_proto_rawDesc,
217 NumEnums: 0,
218 NumMessages: 1,
219 NumExtensions: 0,
220 NumServices: 0,
221 },
222 GoTypes: file_google_rpc_context_audit_context_proto_goTypes,
223 DependencyIndexes: file_google_rpc_context_audit_context_proto_depIdxs,
224 MessageInfos: file_google_rpc_context_audit_context_proto_msgTypes,
225 }.Build()
226 File_google_rpc_context_audit_context_proto = out.File
227 file_google_rpc_context_audit_context_proto_rawDesc = nil
228 file_google_rpc_context_audit_context_proto_goTypes = nil
229 file_google_rpc_context_audit_context_proto_depIdxs = nil
230 }