google-cloud-chronicle-v1 0.a → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (74) hide show
  1. checksums.yaml +4 -4
  2. data/.yardopts +12 -0
  3. data/AUTHENTICATION.md +122 -0
  4. data/README.md +154 -8
  5. data/lib/google/cloud/chronicle/v1/data_access_control_pb.rb +67 -0
  6. data/lib/google/cloud/chronicle/v1/data_access_control_service/client.rb +1414 -0
  7. data/lib/google/cloud/chronicle/v1/data_access_control_service/credentials.rb +47 -0
  8. data/lib/google/cloud/chronicle/v1/data_access_control_service/paths.rb +94 -0
  9. data/lib/google/cloud/chronicle/v1/data_access_control_service/rest/client.rb +1318 -0
  10. data/lib/google/cloud/chronicle/v1/data_access_control_service/rest/service_stub.rb +695 -0
  11. data/lib/google/cloud/chronicle/v1/data_access_control_service/rest.rb +53 -0
  12. data/lib/google/cloud/chronicle/v1/data_access_control_service.rb +56 -0
  13. data/lib/google/cloud/chronicle/v1/data_access_control_services_pb.rb +76 -0
  14. data/lib/google/cloud/chronicle/v1/entity_pb.rb +62 -0
  15. data/lib/google/cloud/chronicle/v1/entity_service/client.rb +891 -0
  16. data/lib/google/cloud/chronicle/v1/entity_service/credentials.rb +47 -0
  17. data/lib/google/cloud/chronicle/v1/entity_service/paths.rb +73 -0
  18. data/lib/google/cloud/chronicle/v1/entity_service/rest/client.rb +830 -0
  19. data/lib/google/cloud/chronicle/v1/entity_service/rest/service_stub.rb +388 -0
  20. data/lib/google/cloud/chronicle/v1/entity_service/rest.rb +52 -0
  21. data/lib/google/cloud/chronicle/v1/entity_service.rb +55 -0
  22. data/lib/google/cloud/chronicle/v1/entity_services_pb.rb +54 -0
  23. data/lib/google/cloud/chronicle/v1/instance_pb.rb +48 -0
  24. data/lib/google/cloud/chronicle/v1/instance_service/client.rb +464 -0
  25. data/lib/google/cloud/chronicle/v1/instance_service/credentials.rb +47 -0
  26. data/lib/google/cloud/chronicle/v1/instance_service/paths.rb +52 -0
  27. data/lib/google/cloud/chronicle/v1/instance_service/rest/client.rb +431 -0
  28. data/lib/google/cloud/chronicle/v1/instance_service/rest/service_stub.rb +142 -0
  29. data/lib/google/cloud/chronicle/v1/instance_service/rest.rb +52 -0
  30. data/lib/google/cloud/chronicle/v1/instance_service.rb +55 -0
  31. data/lib/google/cloud/chronicle/v1/instance_services_pb.rb +45 -0
  32. data/lib/google/cloud/chronicle/v1/reference_list_pb.rb +61 -0
  33. data/lib/google/cloud/chronicle/v1/reference_list_service/client.rb +792 -0
  34. data/lib/google/cloud/chronicle/v1/reference_list_service/credentials.rb +47 -0
  35. data/lib/google/cloud/chronicle/v1/reference_list_service/paths.rb +73 -0
  36. data/lib/google/cloud/chronicle/v1/reference_list_service/rest/client.rb +738 -0
  37. data/lib/google/cloud/chronicle/v1/reference_list_service/rest/service_stub.rb +327 -0
  38. data/lib/google/cloud/chronicle/v1/reference_list_service/rest.rb +52 -0
  39. data/lib/google/cloud/chronicle/v1/reference_list_service.rb +55 -0
  40. data/lib/google/cloud/chronicle/v1/reference_list_services_pb.rb +51 -0
  41. data/lib/google/cloud/chronicle/v1/rest.rb +41 -0
  42. data/lib/google/cloud/chronicle/v1/rule_pb.rb +85 -0
  43. data/lib/google/cloud/chronicle/v1/rule_service/client.rb +1674 -0
  44. data/lib/google/cloud/chronicle/v1/rule_service/credentials.rb +47 -0
  45. data/lib/google/cloud/chronicle/v1/rule_service/operations.rb +813 -0
  46. data/lib/google/cloud/chronicle/v1/rule_service/paths.rb +159 -0
  47. data/lib/google/cloud/chronicle/v1/rule_service/rest/client.rb +1564 -0
  48. data/lib/google/cloud/chronicle/v1/rule_service/rest/operations.rb +914 -0
  49. data/lib/google/cloud/chronicle/v1/rule_service/rest/service_stub.rb +817 -0
  50. data/lib/google/cloud/chronicle/v1/rule_service/rest.rb +53 -0
  51. data/lib/google/cloud/chronicle/v1/rule_service.rb +56 -0
  52. data/lib/google/cloud/chronicle/v1/rule_services_pb.rb +70 -0
  53. data/lib/google/cloud/chronicle/v1/version.rb +7 -2
  54. data/lib/google/cloud/chronicle/v1.rb +49 -0
  55. data/lib/google-cloud-chronicle-v1.rb +21 -0
  56. data/proto_docs/README.md +4 -0
  57. data/proto_docs/google/api/client.rb +473 -0
  58. data/proto_docs/google/api/field_behavior.rb +85 -0
  59. data/proto_docs/google/api/launch_stage.rb +71 -0
  60. data/proto_docs/google/api/resource.rb +227 -0
  61. data/proto_docs/google/cloud/chronicle/v1/data_access_control.rb +364 -0
  62. data/proto_docs/google/cloud/chronicle/v1/entity.rb +210 -0
  63. data/proto_docs/google/cloud/chronicle/v1/instance.rb +47 -0
  64. data/proto_docs/google/cloud/chronicle/v1/reference_list.rb +232 -0
  65. data/proto_docs/google/cloud/chronicle/v1/rule.rb +701 -0
  66. data/proto_docs/google/longrunning/operations.rb +173 -0
  67. data/proto_docs/google/protobuf/any.rb +145 -0
  68. data/proto_docs/google/protobuf/duration.rb +98 -0
  69. data/proto_docs/google/protobuf/empty.rb +34 -0
  70. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  71. data/proto_docs/google/protobuf/timestamp.rb +127 -0
  72. data/proto_docs/google/rpc/status.rb +48 -0
  73. data/proto_docs/google/type/interval.rb +45 -0
  74. metadata +110 -10
@@ -0,0 +1,701 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2025 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module Chronicle
23
+ module V1
24
+ # The Rule resource represents a user-created rule.
25
+ # NEXT TAG: 21
26
+ # @!attribute [rw] name
27
+ # @return [::String]
28
+ # Identifier. Full resource name for the rule.
29
+ # Format:
30
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
31
+ # @!attribute [r] revision_id
32
+ # @return [::String]
33
+ # Output only. The revision ID of the rule.
34
+ # A new revision is created whenever the rule text is changed in any way.
35
+ # Format: `v_{10 digits}_{9 digits}`
36
+ # Populated in REVISION_METADATA_ONLY view and FULL view.
37
+ # @!attribute [r] display_name
38
+ # @return [::String]
39
+ # Output only. Display name of the rule.
40
+ # Populated in BASIC view and FULL view.
41
+ # @!attribute [rw] text
42
+ # @return [::String]
43
+ # The YARA-L content of the rule.
44
+ # Populated in FULL view.
45
+ # @!attribute [r] author
46
+ # @return [::String]
47
+ # Output only. The author of the rule. Extracted from the meta section of
48
+ # text. Populated in BASIC view and FULL view.
49
+ # @!attribute [r] severity
50
+ # @return [::Google::Cloud::Chronicle::V1::Severity]
51
+ # Output only. The severity of the rule as specified in the meta section of
52
+ # text. Populated in BASIC view and FULL view.
53
+ # @!attribute [r] metadata
54
+ # @return [::Google::Protobuf::Map{::String => ::String}]
55
+ # Output only. Additional metadata specified in the meta section of text.
56
+ # Populated in FULL view.
57
+ # @!attribute [r] create_time
58
+ # @return [::Google::Protobuf::Timestamp]
59
+ # Output only. The timestamp of when the rule was created.
60
+ # Populated in FULL view.
61
+ # @!attribute [r] revision_create_time
62
+ # @return [::Google::Protobuf::Timestamp]
63
+ # Output only. The timestamp of when the rule revision was created.
64
+ # Populated in FULL, REVISION_METADATA_ONLY views.
65
+ # @!attribute [r] compilation_state
66
+ # @return [::Google::Cloud::Chronicle::V1::Rule::CompilationState]
67
+ # Output only. The current compilation state of the rule.
68
+ # Populated in FULL view.
69
+ # @!attribute [r] type
70
+ # @return [::Google::Cloud::Chronicle::V1::RuleType]
71
+ # Output only. User-facing type of the rule. Extracted from the events
72
+ # section of rule text. Populated in BASIC view and FULL view.
73
+ # @!attribute [r] reference_lists
74
+ # @return [::Array<::String>]
75
+ # Output only. Resource names of the reference lists used in this rule.
76
+ # Populated in FULL view.
77
+ # @!attribute [r] allowed_run_frequencies
78
+ # @return [::Array<::Google::Cloud::Chronicle::V1::RunFrequency>]
79
+ # Output only. The run frequencies that are allowed for the rule.
80
+ # Populated in BASIC view and FULL view.
81
+ # @!attribute [rw] etag
82
+ # @return [::String]
83
+ # The etag for this rule.
84
+ # If this is provided on update, the request will succeed if and only if it
85
+ # matches the server-computed value, and will fail with an ABORTED error
86
+ # otherwise.
87
+ # Populated in BASIC view and FULL view.
88
+ # @!attribute [rw] scope
89
+ # @return [::String]
90
+ # Resource name of the DataAccessScope bound to this rule.
91
+ # Populated in BASIC view and FULL view.
92
+ # If reference lists are used in the rule, validations will be performed
93
+ # against this scope to ensure that the reference lists are compatible with
94
+ # both the user's and the rule's scopes.
95
+ # The scope should be in the format:
96
+ # `projects/{project}/locations/{location}/instances/{instance}/dataAccessScopes/{scope}`.
97
+ # @!attribute [r] compilation_diagnostics
98
+ # @return [::Array<::Google::Cloud::Chronicle::V1::CompilationDiagnostic>]
99
+ # Output only. A list of a rule's corresponding compilation diagnostic
100
+ # messages such as compilation errors and compilation warnings. Populated in
101
+ # FULL view.
102
+ # @!attribute [r] near_real_time_live_rule_eligible
103
+ # @return [::Boolean]
104
+ # Output only. Indicate the rule can run in near real time live rule.
105
+ # If this is true, the rule uses the near real time live rule when the run
106
+ # frequency is set to LIVE.
107
+ # @!attribute [r] inputs_used
108
+ # @return [::Google::Cloud::Chronicle::V1::InputsUsed]
109
+ # Output only. The set of inputs used in the rule. For example, if the rule
110
+ # uses $e.principal.hostname, then the uses_udm field will be true.
111
+ class Rule
112
+ include ::Google::Protobuf::MessageExts
113
+ extend ::Google::Protobuf::MessageExts::ClassMethods
114
+
115
+ # @!attribute [rw] key
116
+ # @return [::String]
117
+ # @!attribute [rw] value
118
+ # @return [::String]
119
+ class MetadataEntry
120
+ include ::Google::Protobuf::MessageExts
121
+ extend ::Google::Protobuf::MessageExts::ClassMethods
122
+ end
123
+
124
+ # The current compilation state of the rule.
125
+ module CompilationState
126
+ # The compilation state is unspecified/unknown.
127
+ COMPILATION_STATE_UNSPECIFIED = 0
128
+
129
+ # The Rule can successfully compile.
130
+ SUCCEEDED = 1
131
+
132
+ # The Rule cannot successfully compile.
133
+ # This is possible if a backwards-incompatible change was made to the
134
+ # compiler.
135
+ FAILED = 2
136
+ end
137
+ end
138
+
139
+ # The RuleDeployment resource represents the deployment state of a Rule.
140
+ # @!attribute [rw] name
141
+ # @return [::String]
142
+ # Required. The resource name of the rule deployment.
143
+ # Note that RuleDeployment is a child of the overall Rule, not any individual
144
+ # revision, so the resource ID segment for the Rule resource must not
145
+ # reference a specific revision.
146
+ # Format:
147
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/deployment`
148
+ # @!attribute [rw] enabled
149
+ # @return [::Boolean]
150
+ # Whether the rule is currently deployed continuously against incoming data.
151
+ # @!attribute [rw] alerting
152
+ # @return [::Boolean]
153
+ # Whether detections resulting from this deployment should be considered
154
+ # alerts.
155
+ # @!attribute [rw] archived
156
+ # @return [::Boolean]
157
+ # The archive state of the rule deployment.
158
+ # Cannot be set to true unless enabled is set to false.
159
+ # If set to true, alerting will automatically be set to false.
160
+ # If currently set to true, enabled, alerting, and run_frequency cannot be
161
+ # updated.
162
+ # @!attribute [r] archive_time
163
+ # @return [::Google::Protobuf::Timestamp]
164
+ # Output only. The timestamp when the rule deployment archive state was last
165
+ # set to true. If the rule deployment's current archive state is not set to
166
+ # true, the field will be empty.
167
+ # @!attribute [rw] run_frequency
168
+ # @return [::Google::Cloud::Chronicle::V1::RunFrequency]
169
+ # The run frequency of the rule deployment.
170
+ # @!attribute [r] execution_state
171
+ # @return [::Google::Cloud::Chronicle::V1::RuleDeployment::ExecutionState]
172
+ # Output only. The execution state of the rule deployment.
173
+ # @!attribute [r] producer_rules
174
+ # @return [::Array<::String>]
175
+ # Output only. The names of the associated/chained producer rules. Rules are
176
+ # considered producers for this rule if this rule explicitly filters on their
177
+ # ruleid. Format:
178
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
179
+ # @!attribute [r] consumer_rules
180
+ # @return [::Array<::String>]
181
+ # Output only. The names of the associated/chained consumer rules. Rules are
182
+ # considered consumers of this rule if their rule text explicitly filters on
183
+ # this rule's ruleid. Format:
184
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
185
+ # @!attribute [r] last_alert_status_change_time
186
+ # @return [::Google::Protobuf::Timestamp]
187
+ # Output only. The timestamp when the rule deployment alert state was lastly
188
+ # changed. This is filled regardless of the current alert state. E.g. if the
189
+ # current alert status is false, this timestamp will be the timestamp when
190
+ # the alert status was changed to false.
191
+ class RuleDeployment
192
+ include ::Google::Protobuf::MessageExts
193
+ extend ::Google::Protobuf::MessageExts::ClassMethods
194
+
195
+ # The possible execution states the rule deployment can be in.
196
+ module ExecutionState
197
+ # Unspecified or unknown execution state.
198
+ EXECUTION_STATE_UNSPECIFIED = 0
199
+
200
+ # Default execution state.
201
+ DEFAULT = 1
202
+
203
+ # Rules in limited state may not have their executions guaranteed.
204
+ LIMITED = 2
205
+
206
+ # Paused rules are not executed at all.
207
+ PAUSED = 3
208
+ end
209
+ end
210
+
211
+ # Retrohunt is an execution of a Rule over a time range in the past.
212
+ # @!attribute [rw] name
213
+ # @return [::String]
214
+ # The resource name of the retrohunt.
215
+ # Retrohunt is the child of a rule revision. \\{rule} in the format below is
216
+ # structured as \\{rule_id@revision_id}.
217
+ # Format:
218
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/retrohunts/{retrohunt}`
219
+ # @!attribute [rw] process_interval
220
+ # @return [::Google::Type::Interval]
221
+ # Required. The start and end time of the event time range this retrohunt
222
+ # processes.
223
+ # @!attribute [r] execution_interval
224
+ # @return [::Google::Type::Interval]
225
+ # Output only. The start and end time of the retrohunt execution. If the
226
+ # retrohunt is not yet finished, the end time of the interval will not be
227
+ # populated.
228
+ # @!attribute [r] state
229
+ # @return [::Google::Cloud::Chronicle::V1::Retrohunt::State]
230
+ # Output only. The state of the retrohunt.
231
+ # @!attribute [r] progress_percentage
232
+ # @return [::Float]
233
+ # Output only. Percent progress of the retrohunt towards completion, from
234
+ # 0.00 to 100.00.
235
+ class Retrohunt
236
+ include ::Google::Protobuf::MessageExts
237
+ extend ::Google::Protobuf::MessageExts::ClassMethods
238
+
239
+ # The possible states a retrohunt can be in.
240
+ module State
241
+ # Unspecified or unknown retrohunt state.
242
+ STATE_UNSPECIFIED = 0
243
+
244
+ # Running state.
245
+ RUNNING = 1
246
+
247
+ # Done state.
248
+ DONE = 2
249
+
250
+ # Cancelled state.
251
+ CANCELLED = 3
252
+
253
+ # Failed state.
254
+ FAILED = 4
255
+ end
256
+ end
257
+
258
+ # Request message for CreateRule method.
259
+ # @!attribute [rw] parent
260
+ # @return [::String]
261
+ # Required. The parent resource where this rule will be created.
262
+ # Format: `projects/{project}/locations/{location}/instances/{instance}`
263
+ # @!attribute [rw] rule
264
+ # @return [::Google::Cloud::Chronicle::V1::Rule]
265
+ # Required. The rule to create.
266
+ class CreateRuleRequest
267
+ include ::Google::Protobuf::MessageExts
268
+ extend ::Google::Protobuf::MessageExts::ClassMethods
269
+ end
270
+
271
+ # Request message for GetRule method.
272
+ # @!attribute [rw] name
273
+ # @return [::String]
274
+ # Required. The name of the rule to retrieve.
275
+ # Format:
276
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
277
+ # @!attribute [rw] view
278
+ # @return [::Google::Cloud::Chronicle::V1::RuleView]
279
+ # The view field indicates the scope of fields to populate for the Rule being
280
+ # returned. If unspecified, defaults to FULL.
281
+ class GetRuleRequest
282
+ include ::Google::Protobuf::MessageExts
283
+ extend ::Google::Protobuf::MessageExts::ClassMethods
284
+ end
285
+
286
+ # Request message for ListRules method.
287
+ # @!attribute [rw] parent
288
+ # @return [::String]
289
+ # Required. The parent, which owns this collection of rules.
290
+ # Format:
291
+ # `projects/{project}/locations/{location}/instances/{instance}`
292
+ # @!attribute [rw] page_size
293
+ # @return [::Integer]
294
+ # The maximum number of rules to return. The service may return fewer than
295
+ # this value. If unspecified, at most 100 rules will be returned. The
296
+ # maximum value is 1000; values above 1000 will be coerced to 1000.
297
+ # @!attribute [rw] page_token
298
+ # @return [::String]
299
+ # A page token, received from a previous `ListRules` call.
300
+ # Provide this to retrieve the subsequent page.
301
+ #
302
+ # When paginating, all other parameters provided to `ListRules`
303
+ # must match the call that provided the page token.
304
+ # @!attribute [rw] view
305
+ # @return [::Google::Cloud::Chronicle::V1::RuleView]
306
+ # view indicates the scope of fields to populate for the Rule being returned.
307
+ # If unspecified, defaults to BASIC.
308
+ # @!attribute [rw] filter
309
+ # @return [::String]
310
+ # Only the following filters are allowed:
311
+ # "reference_lists:\\{reference_list_name}"
312
+ # "data_tables:\\{data_table_name}"
313
+ # "display_name:\\{display_name}"
314
+ class ListRulesRequest
315
+ include ::Google::Protobuf::MessageExts
316
+ extend ::Google::Protobuf::MessageExts::ClassMethods
317
+ end
318
+
319
+ # Response message for ListRules method.
320
+ # @!attribute [rw] rules
321
+ # @return [::Array<::Google::Cloud::Chronicle::V1::Rule>]
322
+ # The rules from the specified instance.
323
+ # @!attribute [rw] next_page_token
324
+ # @return [::String]
325
+ # A token, which can be sent as `page_token` to retrieve the next page.
326
+ # If this field is omitted, there are no subsequent pages.
327
+ class ListRulesResponse
328
+ include ::Google::Protobuf::MessageExts
329
+ extend ::Google::Protobuf::MessageExts::ClassMethods
330
+ end
331
+
332
+ # Request message for UpdateRule method.
333
+ # @!attribute [rw] rule
334
+ # @return [::Google::Cloud::Chronicle::V1::Rule]
335
+ # Required. The rule to update.
336
+ #
337
+ # The rule's `name` field is used to identify the rule to update.
338
+ # Format:
339
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
340
+ # @!attribute [rw] update_mask
341
+ # @return [::Google::Protobuf::FieldMask]
342
+ # The list of fields to update. If not included, all fields with a non-empty
343
+ # value will be overwritten.
344
+ class UpdateRuleRequest
345
+ include ::Google::Protobuf::MessageExts
346
+ extend ::Google::Protobuf::MessageExts::ClassMethods
347
+ end
348
+
349
+ # Request message for the DeleteRule method.
350
+ # @!attribute [rw] name
351
+ # @return [::String]
352
+ # Required. The name of the rule to delete. A rule revision timestamp cannot
353
+ # be specified as part of the name, as deleting specific revisions is not
354
+ # supported.
355
+ # Format:
356
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
357
+ # @!attribute [rw] force
358
+ # @return [::Boolean]
359
+ # Optional. If set to true, any retrohunts and any detections associated with
360
+ # the rule will also be deleted. If set to false, the call will only succeed
361
+ # if the rule has no associated retrohunts, including completed retrohunts,
362
+ # and no associated detections. Regardless of this field's value, the rule
363
+ # deployment associated with this rule will also be deleted.
364
+ class DeleteRuleRequest
365
+ include ::Google::Protobuf::MessageExts
366
+ extend ::Google::Protobuf::MessageExts::ClassMethods
367
+ end
368
+
369
+ # Request message for ListRuleRevisions method.
370
+ # @!attribute [rw] name
371
+ # @return [::String]
372
+ # Required. The name of the rule to list revisions for.
373
+ # Format:
374
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
375
+ # @!attribute [rw] page_size
376
+ # @return [::Integer]
377
+ # The maximum number of revisions to return per page. The service may return
378
+ # fewer than this value. If unspecified, at most 100 revisions will be
379
+ # returned. The maximum value is 1000; values above 1000 will be coerced to
380
+ # 1000.
381
+ # @!attribute [rw] page_token
382
+ # @return [::String]
383
+ # The page token, received from a previous `ListRuleRevisions` call.
384
+ # Provide this to retrieve the subsequent page.
385
+ #
386
+ # When paginating, all other parameters provided to `ListRuleRevisions`
387
+ # must match the call that provided the page token.
388
+ # @!attribute [rw] view
389
+ # @return [::Google::Cloud::Chronicle::V1::RuleView]
390
+ # The view field indicates the scope of fields to populate for the revision
391
+ # being returned. If unspecified, defaults to BASIC.
392
+ class ListRuleRevisionsRequest
393
+ include ::Google::Protobuf::MessageExts
394
+ extend ::Google::Protobuf::MessageExts::ClassMethods
395
+ end
396
+
397
+ # Response message for ListRuleRevisions method.
398
+ # @!attribute [rw] rules
399
+ # @return [::Array<::Google::Cloud::Chronicle::V1::Rule>]
400
+ # The revisions of the rule.
401
+ # @!attribute [rw] next_page_token
402
+ # @return [::String]
403
+ # A token that can be sent as `page_token` to retrieve the next page.
404
+ # If this field is omitted, there are no subsequent pages.
405
+ class ListRuleRevisionsResponse
406
+ include ::Google::Protobuf::MessageExts
407
+ extend ::Google::Protobuf::MessageExts::ClassMethods
408
+ end
409
+
410
+ # Request message for CreateRetrohunt method.
411
+ # @!attribute [rw] parent
412
+ # @return [::String]
413
+ # Required. The parent of retrohunt, which is a rule.
414
+ # Format:
415
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
416
+ # @!attribute [rw] retrohunt
417
+ # @return [::Google::Cloud::Chronicle::V1::Retrohunt]
418
+ # Required. The retrohunt to create.
419
+ class CreateRetrohuntRequest
420
+ include ::Google::Protobuf::MessageExts
421
+ extend ::Google::Protobuf::MessageExts::ClassMethods
422
+ end
423
+
424
+ # Request message for GetRetrohunt method.
425
+ # @!attribute [rw] name
426
+ # @return [::String]
427
+ # Required. The name of the retrohunt to retrieve.
428
+ # Format:
429
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/retrohunts/{retrohunt}`
430
+ class GetRetrohuntRequest
431
+ include ::Google::Protobuf::MessageExts
432
+ extend ::Google::Protobuf::MessageExts::ClassMethods
433
+ end
434
+
435
+ # Request message for ListRetrohunts method.
436
+ # @!attribute [rw] parent
437
+ # @return [::String]
438
+ # Required. The rule that the retrohunts belong to.
439
+ # Format:
440
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}`
441
+ # @!attribute [rw] page_size
442
+ # @return [::Integer]
443
+ # The maximum number of retrohunt to return. The service may return fewer
444
+ # than this value. If unspecified, at most 100 retrohunts will be returned.
445
+ # The maximum value is 1000; values above 1000 will be coerced to
446
+ # 1000.
447
+ # @!attribute [rw] page_token
448
+ # @return [::String]
449
+ # A page token, received from a previous `ListRetrohunts` call.
450
+ # Provide this to retrieve the subsequent page.
451
+ #
452
+ # When paginating, all other parameters provided to `ListRetrohunts` must
453
+ # match the call that provided the page token.
454
+ # @!attribute [rw] filter
455
+ # @return [::String]
456
+ # A filter that can be used to retrieve specific rule deployments.
457
+ # The following fields are filterable:
458
+ # state
459
+ class ListRetrohuntsRequest
460
+ include ::Google::Protobuf::MessageExts
461
+ extend ::Google::Protobuf::MessageExts::ClassMethods
462
+ end
463
+
464
+ # Response message for ListRetrohunts method.
465
+ # @!attribute [rw] retrohunts
466
+ # @return [::Array<::Google::Cloud::Chronicle::V1::Retrohunt>]
467
+ # The retrohunts from the specified rule.
468
+ # @!attribute [rw] next_page_token
469
+ # @return [::String]
470
+ # A token, which can be sent as `page_token` to retrieve the next page.
471
+ # If this field is omitted, there are no subsequent pages.
472
+ class ListRetrohuntsResponse
473
+ include ::Google::Protobuf::MessageExts
474
+ extend ::Google::Protobuf::MessageExts::ClassMethods
475
+ end
476
+
477
+ # Request message for GetRuleDeployment.
478
+ # @!attribute [rw] name
479
+ # @return [::String]
480
+ # Required. The name of the rule deployment to retrieve.
481
+ # Format:
482
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/deployment`
483
+ class GetRuleDeploymentRequest
484
+ include ::Google::Protobuf::MessageExts
485
+ extend ::Google::Protobuf::MessageExts::ClassMethods
486
+ end
487
+
488
+ # Request message for ListRuleDeployments.
489
+ # @!attribute [rw] parent
490
+ # @return [::String]
491
+ # Required. The collection of all parents which own all rule deployments. The
492
+ # "-" wildcard token must be used as the rule identifier in the resource
493
+ # path. Format:
494
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/-`
495
+ # @!attribute [rw] page_size
496
+ # @return [::Integer]
497
+ # The maximum number of rule deployments to return. The service may return
498
+ # fewer than this value. If unspecified, at most 100 rule deployments will be
499
+ # returned. The maximum value is 1000; values above 1000 will be coerced to
500
+ # 1000.
501
+ # @!attribute [rw] page_token
502
+ # @return [::String]
503
+ # A page token, received from a previous `ListRuleDeployments` call.
504
+ # Provide this to retrieve the subsequent page.
505
+ #
506
+ # When paginating, all other parameters provided to `ListRuleDeployments`
507
+ # must match the call that provided the page token.
508
+ # @!attribute [rw] filter
509
+ # @return [::String]
510
+ # A filter that can be used to retrieve specific rule deployments.
511
+ # The following fields are filterable:
512
+ # archived, name
513
+ class ListRuleDeploymentsRequest
514
+ include ::Google::Protobuf::MessageExts
515
+ extend ::Google::Protobuf::MessageExts::ClassMethods
516
+ end
517
+
518
+ # Response message for ListRuleDeployments.
519
+ # @!attribute [rw] rule_deployments
520
+ # @return [::Array<::Google::Cloud::Chronicle::V1::RuleDeployment>]
521
+ # The rule deployments from all rules.
522
+ # @!attribute [rw] next_page_token
523
+ # @return [::String]
524
+ # A token, which can be sent as `page_token` to retrieve the next page.
525
+ # If this field is omitted, there are no subsequent pages.
526
+ class ListRuleDeploymentsResponse
527
+ include ::Google::Protobuf::MessageExts
528
+ extend ::Google::Protobuf::MessageExts::ClassMethods
529
+ end
530
+
531
+ # Request message for UpdateRuleDeployment.
532
+ # @!attribute [rw] rule_deployment
533
+ # @return [::Google::Cloud::Chronicle::V1::RuleDeployment]
534
+ # Required. The rule deployment to update.
535
+ #
536
+ # The rule deployment's `name` field is used to identify the rule deployment
537
+ # to update. Format:
538
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/deployment`
539
+ # @!attribute [rw] update_mask
540
+ # @return [::Google::Protobuf::FieldMask]
541
+ # Required. The list of fields to update.
542
+ class UpdateRuleDeploymentRequest
543
+ include ::Google::Protobuf::MessageExts
544
+ extend ::Google::Protobuf::MessageExts::ClassMethods
545
+ end
546
+
547
+ # CompilationPosition represents the location of a compilation diagnostic in
548
+ # rule text.
549
+ # @!attribute [r] start_line
550
+ # @return [::Integer]
551
+ # Output only. Start line number, beginning at 1.
552
+ # @!attribute [r] start_column
553
+ # @return [::Integer]
554
+ # Output only. Start column number, beginning at 1.
555
+ # @!attribute [r] end_line
556
+ # @return [::Integer]
557
+ # Output only. End line number, beginning at 1.
558
+ # @!attribute [r] end_column
559
+ # @return [::Integer]
560
+ # Output only. End column number, beginning at 1.
561
+ class CompilationPosition
562
+ include ::Google::Protobuf::MessageExts
563
+ extend ::Google::Protobuf::MessageExts::ClassMethods
564
+ end
565
+
566
+ # CompilationDiagnostic represents a compilation diagnostic generated
567
+ # during a rule's compilation, such as a compilation error or a compilation
568
+ # warning.
569
+ # @!attribute [r] message
570
+ # @return [::String]
571
+ # Output only. The diagnostic message.
572
+ # @!attribute [r] position
573
+ # @return [::Google::Cloud::Chronicle::V1::CompilationPosition]
574
+ # Output only. The approximate position in the rule text associated with the
575
+ # compilation diagnostic.
576
+ # Compilation Position may be empty.
577
+ # @!attribute [r] severity
578
+ # @return [::Google::Cloud::Chronicle::V1::CompilationDiagnostic::Severity]
579
+ # Output only. The severity of a rule's compilation diagnostic.
580
+ # @!attribute [r] uri
581
+ # @return [::String]
582
+ # Output only. Link to documentation that describes a diagnostic in more
583
+ # detail.
584
+ class CompilationDiagnostic
585
+ include ::Google::Protobuf::MessageExts
586
+ extend ::Google::Protobuf::MessageExts::ClassMethods
587
+
588
+ # The severity level of the compilation diagnostic.
589
+ module Severity
590
+ # An unspecified severity level.
591
+ SEVERITY_UNSPECIFIED = 0
592
+
593
+ # A compilation warning.
594
+ WARNING = 1
595
+
596
+ # A compilation error.
597
+ ERROR = 2
598
+ end
599
+ end
600
+
601
+ # Severity represents the severity level of the rule.
602
+ # @!attribute [rw] display_name
603
+ # @return [::String]
604
+ # The display name of the severity level. Extracted from the meta section of
605
+ # the rule text.
606
+ class Severity
607
+ include ::Google::Protobuf::MessageExts
608
+ extend ::Google::Protobuf::MessageExts::ClassMethods
609
+ end
610
+
611
+ # Operation Metadata for Retrohunts.
612
+ # @!attribute [rw] retrohunt
613
+ # @return [::String]
614
+ # The name of the retrohunt.
615
+ # Format:
616
+ # `projects/{project}/locations/{location}/instances/{instance}/rules/{rule}/retrohunts/{retrohunt}`
617
+ # @!attribute [rw] execution_interval
618
+ # @return [::Google::Type::Interval]
619
+ # The start and end time of the retrohunt execution. If the retrohunt is not
620
+ # yet finished, the end time of the interval will not be filled.
621
+ # @!attribute [rw] progress_percentage
622
+ # @return [::Float]
623
+ # Percent progress of the retrohunt towards completion, from 0.00 to 100.00.
624
+ class RetrohuntMetadata
625
+ include ::Google::Protobuf::MessageExts
626
+ extend ::Google::Protobuf::MessageExts::ClassMethods
627
+ end
628
+
629
+ # InputsUsed is a convenience field that tells us which sources
630
+ # of events (if any) were used in the rule.
631
+ # NEXT TAG: 4
632
+ # @!attribute [rw] uses_udm
633
+ # @return [::Boolean]
634
+ # Optional. Whether the rule queries UDM events.
635
+ # @!attribute [rw] uses_entity
636
+ # @return [::Boolean]
637
+ # Optional. Whether the rule queries entity events.
638
+ # @!attribute [rw] uses_detection
639
+ # @return [::Boolean]
640
+ # Optional. Whether the rule queries detections.
641
+ class InputsUsed
642
+ include ::Google::Protobuf::MessageExts
643
+ extend ::Google::Protobuf::MessageExts::ClassMethods
644
+ end
645
+
646
+ # RunFrequency indicates the run frequency at which a YARA-L 2 rule will run if
647
+ # enabled.
648
+ module RunFrequency
649
+ # The run frequency is unspecified/unknown.
650
+ RUN_FREQUENCY_UNSPECIFIED = 0
651
+
652
+ # Executes in real time.
653
+ LIVE = 1
654
+
655
+ # Executes once per hour.
656
+ HOURLY = 2
657
+
658
+ # Executes once per day.
659
+ DAILY = 3
660
+ end
661
+
662
+ # RuleType indicates the YARA-L rule type of user-created and Google Cloud
663
+ # Threat Intelligence (GCTI) authored rules.
664
+ module RuleType
665
+ # The rule type is unspecified/unknown.
666
+ RULE_TYPE_UNSPECIFIED = 0
667
+
668
+ # Rule checks for the existence of a single event.
669
+ SINGLE_EVENT = 1
670
+
671
+ # Rule checks for correlation between multiple events
672
+ MULTI_EVENT = 2
673
+ end
674
+
675
+ # RuleView indicates the scope of fields to populate when returning the Rule
676
+ # resource.
677
+ module RuleView
678
+ # The default/unset value.
679
+ # The API will default to the BASIC view for ListRules/ListRuleRevisions.
680
+ # The API will default to the FULL view for GetRule.
681
+ RULE_VIEW_UNSPECIFIED = 0
682
+
683
+ # Include basic metadata about the rule, but not the full contents.
684
+ # Returned fields include: revision_id, revision_create_time, display_name,
685
+ # author, severity, type, allowed_run_frequency,
686
+ # near_real_time_live_rule_eligible, etag, and scope.
687
+ # This is the default value for ListRules and ListRuleRevisions.
688
+ BASIC = 1
689
+
690
+ # Include all fields.
691
+ # This is the default value for GetRule.
692
+ FULL = 2
693
+
694
+ # Include basic metadata about the rule's revision only.
695
+ # Returned fields include: revision_id and revision_create_time.
696
+ REVISION_METADATA_ONLY = 3
697
+ end
698
+ end
699
+ end
700
+ end
701
+ end