Class: Falcon::KubernetesContainerCompliance

Inherits:
Object
  • Object
show all
Defined in:
lib/crimson-falcon/api/kubernetes_container_compliance.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(api_client = ApiClient.default) ⇒ KubernetesContainerCompliance

Returns a new instance of KubernetesContainerCompliance.



35
36
37
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 35

def initialize(api_client = ApiClient.default)
  @api_client = api_client
end

Instance Attribute Details

#api_clientObject

Returns the value of attribute api_client.



33
34
35
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 33

def api_client
  @api_client
end

Instance Method Details

#aggregate_assessments_grouped_by_clusters_v2(opts = {}) ⇒ DomainAPIAggregateResponseGroupByClustersV2

Returns cluster details along with aggregated assessment results organized by cluster, including pass/fail assessment counts for various asset types.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The zero-based position of the first record to return.

  • :limit (Integer)

    The maximum number of records to return. (1-500) Default is 20.

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



44
45
46
47
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 44

def aggregate_assessments_grouped_by_clusters_v2(opts = {})
  data, _status_code, _headers = aggregate_assessments_grouped_by_clusters_v2_with_http_info(opts)
  data
end

#aggregate_assessments_grouped_by_clusters_v2_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseGroupByClustersV2, Integer, Hash)>

Returns cluster details along with aggregated assessment results organized by cluster, including pass/fail assessment counts for various asset types.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The zero-based position of the first record to return.

  • :limit (Integer)

    The maximum number of records to return. (1-500) Default is 20.

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 55

def aggregate_assessments_grouped_by_clusters_v2_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_assessments_grouped_by_clusters_v2 ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/clusters/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseGroupByClustersV2'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_assessments_grouped_by_clusters_v2",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_assessments_grouped_by_clusters_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_assessments_grouped_by_rules_v2(opts = {}) ⇒ DomainAPIAggregateResponseGroupByRulesV1

Returns rule details along with aggregated assessment results organized by compliance rule, including pass/fail assessment counts.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The zero-based position of the first record to return.

  • :limit (Integer)

    The maximum number of records to return. (1-500) Default is 20.

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status

Returns:



108
109
110
111
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 108

def aggregate_assessments_grouped_by_rules_v2(opts = {})
  data, _status_code, _headers = aggregate_assessments_grouped_by_rules_v2_with_http_info(opts)
  data
end

#aggregate_assessments_grouped_by_rules_v2_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseGroupByRulesV1, Integer, Hash)>

Returns rule details along with aggregated assessment results organized by compliance rule, including pass/fail assessment counts.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :offset (Integer)

    The zero-based position of the first record to return.

  • :limit (Integer)

    The maximum number of records to return. (1-500) Default is 20.

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status

Returns:



119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 119

def aggregate_assessments_grouped_by_rules_v2_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_assessments_grouped_by_rules_v2 ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/rules/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'offset'] = opts[:'offset'] if !opts[:'offset'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseGroupByRulesV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_assessments_grouped_by_rules_v2",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_assessments_grouped_by_rules_v2\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_compliance_by_asset_type(opts = {}) ⇒ DomainAPIAggregateResponseComplianceByAssetTypeV1

Provides aggregated compliance assessment metrics and rule status information, organized by asset type.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



170
171
172
173
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 170

def aggregate_compliance_by_asset_type(opts = {})
  data, _status_code, _headers = aggregate_compliance_by_asset_type_with_http_info(opts)
  data
end

#aggregate_compliance_by_asset_type_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseComplianceByAssetTypeV1, Integer, Hash)>

Provides aggregated compliance assessment metrics and rule status information, organized by asset type.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 179

def aggregate_compliance_by_asset_type_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_compliance_by_asset_type ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/compliance-by-asset-type/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseComplianceByAssetTypeV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_compliance_by_asset_type",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_compliance_by_asset_type\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_compliance_by_cluster_type(opts = {}) ⇒ DomainAPIAggregateResponseComplianceByClusterTypeV1

Provides aggregated compliance assessment metrics and rule status information, organized by Kubernetes cluster type.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



228
229
230
231
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 228

def aggregate_compliance_by_cluster_type(opts = {})
  data, _status_code, _headers = aggregate_compliance_by_cluster_type_with_http_info(opts)
  data
end

#aggregate_compliance_by_cluster_type_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseComplianceByClusterTypeV1, Integer, Hash)>

Provides aggregated compliance assessment metrics and rule status information, organized by Kubernetes cluster type.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 237

def aggregate_compliance_by_cluster_type_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_compliance_by_cluster_type ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/compliance-by-cluster-type/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseComplianceByClusterTypeV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_compliance_by_cluster_type",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_compliance_by_cluster_type\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_compliance_by_framework(opts = {}) ⇒ DomainAPIAggregateResponseComplianceByFrameworkV1

Provides aggregated compliance assessment metrics and rule status information, organized by compliance framework.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



286
287
288
289
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 286

def aggregate_compliance_by_framework(opts = {})
  data, _status_code, _headers = aggregate_compliance_by_framework_with_http_info(opts)
  data
end

#aggregate_compliance_by_framework_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseComplianceByFrameworkV1, Integer, Hash)>

Provides aggregated compliance assessment metrics and rule status information, organized by compliance framework.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

Returns:



295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 295

def aggregate_compliance_by_framework_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_compliance_by_framework ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/compliance-by-framework/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseComplianceByFrameworkV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_compliance_by_framework",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_compliance_by_framework\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_failed_rules_by_clusters_v3(opts = {}) ⇒ DomainAPIAggregateResponseFailedRulesByClustersTypeV2

Retrieves the most non-compliant clusters, ranked in descending order based on the number of failed compliance rules across severity levels (critical, high, medium, and low).

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

  • :limit (Integer)

    The maximum number of records to return. (1-100) Default is 10.

Returns:



345
346
347
348
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 345

def aggregate_failed_rules_by_clusters_v3(opts = {})
  data, _status_code, _headers = aggregate_failed_rules_by_clusters_v3_with_http_info(opts)
  data
end

#aggregate_failed_rules_by_clusters_v3_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseFailedRulesByClustersTypeV2, Integer, Hash)>

Retrieves the most non-compliant clusters, ranked in descending order based on the number of failed compliance rules across severity levels (critical, high, medium, and low).

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

  • :limit (Integer)

    The maximum number of records to return. (1-100) Default is 10.

Returns:



355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 355

def aggregate_failed_rules_by_clusters_v3_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_failed_rules_by_clusters_v3 ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/failed-rules-by-clusters/v3'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseFailedRulesByClustersTypeV2'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_failed_rules_by_clusters_v3",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_failed_rules_by_clusters_v3\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#aggregate_top_failed_images(opts = {}) ⇒ DomainAPIAggregateResponseTopFailedImagesV1

Retrieves the most non-compliant container images, ranked in descending order based on the number of failed assessments across severity levels (critical, high, medium, and low).

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

  • :limit (Integer)

    The maximum number of records to return. (1-100) Default is 10.

Returns:



406
407
408
409
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 406

def aggregate_top_failed_images(opts = {})
  data, _status_code, _headers = aggregate_top_failed_images_with_http_info(opts)
  data
end

#aggregate_top_failed_images_with_http_info(opts = {}) ⇒ Array<(DomainAPIAggregateResponseTopFailedImagesV1, Integer, Hash)>

Retrieves the most non-compliant container images, ranked in descending order based on the number of failed assessments across severity levels (critical, high, medium, and low).

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.severity

  • :limit (Integer)

    The maximum number of records to return. (1-100) Default is 10.

Returns:



416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 416

def aggregate_top_failed_images_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.aggregate_top_failed_images ...'
  end
  # resource path
  local_var_path = '/container-compliance/aggregates/top-failed-images/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIAggregateResponseTopFailedImagesV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.aggregate_top_failed_images",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#aggregate_top_failed_images\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#combined_images_findings(opts = {}) ⇒ DomainAPIResponseImagesFindingsV1

Returns detailed compliance assessment results for container images, providing the information needed to identify compliance violations.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, cloud_info.namespace, compliance_finding.asset_uid, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status, image_digest, image_id, image_registry, image_repository, image_tag

  • :after (String)

    A pagination token used with the &#x60;limit&#x60; parameter to manage pagination of results. On your first request, don&#39;t provide an &#x60;after&#x60; token. On subsequent requests, provide the &#x60;after&#x60; token from the previous response to continue from that place in the results.

  • :limit (Integer)

    The maximum number of images for which assessments are to be returned: 1-100. Default is 100. Use with the after parameter to manage pagination of results.

Returns:



468
469
470
471
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 468

def combined_images_findings(opts = {})
  data, _status_code, _headers = combined_images_findings_with_http_info(opts)
  data
end

#combined_images_findings_with_http_info(opts = {}) ⇒ Array<(DomainAPIResponseImagesFindingsV1, Integer, Hash)>

Returns detailed compliance assessment results for container images, providing the information needed to identify compliance violations.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, cloud_info.namespace, compliance_finding.asset_uid, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status, image_digest, image_id, image_registry, image_repository, image_tag

  • :after (String)

    A pagination token used with the &#x60;limit&#x60; parameter to manage pagination of results. On your first request, don&#39;t provide an &#x60;after&#x60; token. On subsequent requests, provide the &#x60;after&#x60; token from the previous response to continue from that place in the results.

  • :limit (Integer)

    The maximum number of images for which assessments are to be returned: 1-100. Default is 100. Use with the after parameter to manage pagination of results.

Returns:



479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 479

def combined_images_findings_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.combined_images_findings ...'
  end
  # resource path
  local_var_path = '/container-compliance/combined/findings-by-images/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'after'] = opts[:'after'] if !opts[:'after'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIResponseImagesFindingsV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.combined_images_findings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#combined_images_findings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#combined_nodes_findings(opts = {}) ⇒ DomainAPIResponseNodesFindingsV1

Returns detailed compliance assessment results for kubernetes nodes, providing the information needed to identify compliance violations.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.asset_uid, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status, aid, node_id, node_name, node_type

  • :after (String)

    A pagination token used with the &#x60;limit&#x60; parameter to manage pagination of results. On your first request, don&#39;t provide an &#x60;after&#x60; token. On subsequent requests, provide the &#x60;after&#x60; token from the previous response to continue from that place in the results.

  • :limit (Integer)

    The maximum number of nodes for which assessments are to be returned: 1-100. Default is 100. Use with the after parameter to manage pagination of results.

Returns:



532
533
534
535
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 532

def combined_nodes_findings(opts = {})
  data, _status_code, _headers = combined_nodes_findings_with_http_info(opts)
  data
end

#combined_nodes_findings_with_http_info(opts = {}) ⇒ Array<(DomainAPIResponseNodesFindingsV1, Integer, Hash)>

Returns detailed compliance assessment results for kubernetes nodes, providing the information needed to identify compliance violations.

Parameters:

  • opts (Hash) (defaults to: {})

    the optional parameters

Options Hash (opts):

  • :filter (String)

    FQL filter expression used to limit the results. Filter fields include: cid, cloud_info.cloud_account_id, cloud_info.cloud_provider, cloud_info.cloud_region, cloud_info.cluster_id, cloud_info.cluster_name, cloud_info.cluster_type, compliance_finding.asset_type, compliance_finding.asset_uid, compliance_finding.framework_name, compliance_finding.framework_name_version, compliance_finding.framework_version, compliance_finding.id, compliance_finding.severity, compliance_finding.status, aid, node_id, node_name, node_type

  • :after (String)

    A pagination token used with the &#x60;limit&#x60; parameter to manage pagination of results. On your first request, don&#39;t provide an &#x60;after&#x60; token. On subsequent requests, provide the &#x60;after&#x60; token from the previous response to continue from that place in the results.

  • :limit (Integer)

    The maximum number of nodes for which assessments are to be returned: 1-100. Default is 100. Use with the after parameter to manage pagination of results.

Returns:



543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 543

def combined_nodes_findings_with_http_info(opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.combined_nodes_findings ...'
  end
  # resource path
  local_var_path = '/container-compliance/combined/findings-by-nodes/v2'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'filter'] = opts[:'filter'] if !opts[:'filter'].nil?
  query_params[:'after'] = opts[:'after'] if !opts[:'after'].nil?
  query_params[:'limit'] = opts[:'limit'] if !opts[:'limit'].nil?

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainAPIResponseNodesFindingsV1'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.combined_nodes_findings",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#combined_nodes_findings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end

#get_rules_metadata_by_id(ids, opts = {}) ⇒ DomainRuleMetadataResponse

Retrieve detailed compliance rule information including descriptions, remediation steps, and audit procedures by specifying rule identifiers.

Parameters:

  • ids (Array<String>)

    comma separated list of rule ids

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:



594
595
596
597
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 594

def (ids, opts = {})
  data, _status_code, _headers = (ids, opts)
  data
end

#get_rules_metadata_by_id_with_http_info(ids, opts = {}) ⇒ Array<(DomainRuleMetadataResponse, Integer, Hash)>

Retrieve detailed compliance rule information including descriptions, remediation steps, and audit procedures by specifying rule identifiers.

Parameters:

  • ids (Array<String>)

    comma separated list of rule ids

  • opts (Hash) (defaults to: {})

    the optional parameters

Returns:

  • (Array<(DomainRuleMetadataResponse, Integer, Hash)>)

    DomainRuleMetadataResponse data, response status code and response headers



603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
# File 'lib/crimson-falcon/api/kubernetes_container_compliance.rb', line 603

def (ids, opts = {})
  if @api_client.config.debugging
    @api_client.config.logger.debug 'Calling API: KubernetesContainerCompliance.get_rules_metadata_by_id ...'
  end
  # verify the required parameter 'ids' is set
  if @api_client.config.client_side_validation && ids.nil?
    fail ArgumentError, "Missing the required parameter 'ids' when calling KubernetesContainerCompliance.get_rules_metadata_by_id"
  end
  # resource path
  local_var_path = '/container-compliance/combined/rule-details-by-rule-ids/v1'

  # query parameters
  query_params = opts[:query_params] || {}
  query_params[:'ids'] = @api_client.build_collection_param(ids, :multi)

  # header parameters
  header_params = opts[:header_params] || {}
  # HTTP header 'Accept' (if needed)
  header_params['Accept'] = @api_client.select_header_accept(['application/json'])

  # form parameters
  form_params = opts[:form_params] || {}

  # http body (model)
  post_body = opts[:debug_body]

  # return_type
  return_type = opts[:debug_return_type] || 'DomainRuleMetadataResponse'

  # auth_names
  auth_names = opts[:debug_auth_names] || ['oauth2']

  new_options = opts.merge(
    :operation => :"KubernetesContainerCompliance.get_rules_metadata_by_id",
    :header_params => header_params,
    :query_params => query_params,
    :form_params => form_params,
    :body => post_body,
    :auth_names => auth_names,
    :return_type => return_type
  )

  data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
  if @api_client.config.debugging
    @api_client.config.logger.debug "API called: KubernetesContainerCompliance#get_rules_metadata_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
  end
  return data, status_code, headers
end