Skip to content

Commit bf432a0

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Regenerate client from commit fcf2546 of spec repo (#3008)
Co-authored-by: ci.datadog-api-spec <packages@datadoghq.com>
1 parent 4342459 commit bf432a0

11 files changed

Lines changed: 140 additions & 38 deletions

.generator/schemas/v2/openapi.yaml

Lines changed: 58 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29976,6 +29976,13 @@ components:
2997629976
Library:
2997729977
description: Vulnerability library.
2997829978
properties:
29979+
additional_names:
29980+
description: Related library or package names (such as child packages or
29981+
affected binary paths).
29982+
items:
29983+
example: linux-tools-common
29984+
type: string
29985+
type: array
2997929986
name:
2998029987
description: Vulnerability library name.
2998129988
example: linux-aws-5.15
@@ -57353,6 +57360,12 @@ components:
5735357360
type: array
5735457361
risks:
5735557362
$ref: '#/components/schemas/VulnerabilityRisks'
57363+
running_kernel:
57364+
description: "True if the vulnerability affects a package in the host\u2019s
57365+
running kernel, false if it affects a non-running kernel, and omit if
57366+
it is not kernel-related."
57367+
example: true
57368+
type: boolean
5735657369
status:
5735757370
$ref: '#/components/schemas/VulnerabilityStatus'
5735857371
title:
@@ -57413,10 +57426,15 @@ components:
5741357426
- RubyGems
5741457427
- Go
5741557428
- Packagist
57416-
- Ddeb
57429+
- Deb
5741757430
- Rpm
5741857431
- Apk
5741957432
- Windows
57433+
- Generic
57434+
- MacOs
57435+
- Oci
57436+
- BottleRocket
57437+
- None
5742057438
type: string
5742157439
x-enum-varnames:
5742257440
- PYPI
@@ -57426,10 +57444,15 @@ components:
5742657444
- RUBY_GEMS
5742757445
- GO
5742857446
- PACKAGIST
57429-
- D_DEB
57447+
- DEB
5743057448
- RPM
5743157449
- APK
5743257450
- WINDOWS
57451+
- GENERIC
57452+
- MAC_OS
57453+
- OCI
57454+
- BOTTLE_ROCKET
57455+
- NONE
5743357456
VulnerabilityRelationships:
5743457457
description: Related entities object.
5743557458
properties:
@@ -57530,12 +57553,14 @@ components:
5753057553
- IAST
5753157554
- SCA
5753257555
- Infra
57556+
- SAST
5753357557
example: SCA
5753457558
type: string
5753557559
x-enum-varnames:
5753657560
- IAST
5753757561
- SCA
5753857562
- INFRA
57563+
- SAST
5753957564
VulnerabilityType:
5754057565
description: The vulnerability type.
5754157566
enum:
@@ -80296,6 +80321,10 @@ paths:
8029680321
summary: List assets SBOMs
8029780322
tags:
8029880323
- Security Monitoring
80324+
x-permission:
80325+
operator: OR
80326+
permissions:
80327+
- appsec_vm_read
8029980328
x-unstable: '**Note**: This endpoint is a private preview.
8030080329

8030180330
If you are interested in accessing this API, [fill out this form](https://forms.gle/kMYC1sDr6WDUBDsx9).'
@@ -80367,6 +80396,10 @@ paths:
8036780396
summary: Get SBOM
8036880397
tags:
8036980398
- Security Monitoring
80399+
x-permission:
80400+
operator: OR
80401+
permissions:
80402+
- appsec_vm_read
8037080403
x-unstable: '**Note**: This endpoint is a private preview.
8037180404

8037280405
If you are interested in accessing this API, [fill out this form](https://forms.gle/kMYC1sDr6WDUBDsx9).'
@@ -80481,6 +80514,10 @@ paths:
8048180514
summary: List scanned assets metadata
8048280515
tags:
8048380516
- Security Monitoring
80517+
x-permission:
80518+
operator: OR
80519+
permissions:
80520+
- appsec_vm_read
8048480521
x-unstable: '**Note**: This endpoint is a private preview.
8048580522

8048680523
If you are interested in accessing this API, [fill out this form](https://forms.gle/kMYC1sDr6WDUBDsx9).'
@@ -80909,6 +80946,14 @@ paths:
8090980946
required: false
8091080947
schema:
8091180948
type: string
80949+
- description: Filter for whether the vulnerability affects a running kernel
80950+
(for vulnerabilities related to a `Host` asset).
80951+
example: true
80952+
in: query
80953+
name: filter[running_kernel]
80954+
required: false
80955+
schema:
80956+
type: boolean
8091280957
- description: Filter by asset name. This field supports the usage of wildcards
8091380958
(*).
8091480959
example: datadog-agent
@@ -81052,6 +81097,10 @@ paths:
8105281097
summary: List vulnerabilities
8105381098
tags:
8105481099
- Security Monitoring
81100+
x-permission:
81101+
operator: OR
81102+
permissions:
81103+
- appsec_vm_read
8105581104
x-unstable: '**Note**: This endpoint is a private preview.
8105681105

8105781106
If you are interested in accessing this API, [fill out this form](https://forms.gle/kMYC1sDr6WDUBDsx9).'
@@ -81410,6 +81459,10 @@ paths:
8141081459
summary: List vulnerable assets
8141181460
tags:
8141281461
- Security Monitoring
81462+
x-permission:
81463+
operator: OR
81464+
permissions:
81465+
- appsec_vm_read
8141381466
x-unstable: '**Note**: This endpoint is a private preview.
8141481467

8141581468
If you are interested in accessing this API, [fill out this form](https://forms.gle/kMYC1sDr6WDUBDsx9).'
@@ -84547,8 +84600,8 @@ paths:
8454784600
x-unstable: '**Note**: This endpoint may be subject to changes.'
8454884601
/api/v2/static-analysis/secrets/rules:
8454984602
get:
84550-
description: Returns list of Secrets rules with ID, Pattern, Description, Priority,
84551-
and SDS ID
84603+
description: Returns a list of Secrets rules with ID, Pattern, Description,
84604+
Priority, and SDS ID.
8455284605
operationId: GetSecretsRules
8455384606
responses:
8455484607
'200':
@@ -84564,7 +84617,7 @@ paths:
8456484617
appKeyAuth: []
8456584618
- AuthZ:
8456684619
- code_analysis_read
84567-
summary: Returns list of Secrets rules
84620+
summary: Returns a list of Secrets rules
8456884621
tags:
8456984622
- Security Monitoring
8457084623
x-unstable: '**Note**: This endpoint may be subject to changes.'

examples/v2/security-monitoring/GetSecretsRules.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
"""
2-
Returns list of Secrets rules returns "OK" response
2+
Returns a list of Secrets rules returns "OK" response
33
"""
44

55
from datadog_api_client import ApiClient, Configuration

src/datadog_api_client/v2/api/security_monitoring_api.py

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1773,6 +1773,11 @@ def __init__(self, api_client=None):
17731773
"attribute": "filter[origin]",
17741774
"location": "query",
17751775
},
1776+
"filter_running_kernel": {
1777+
"openapi_types": (bool,),
1778+
"attribute": "filter[running_kernel]",
1779+
"location": "query",
1780+
},
17761781
"filter_asset_name": {
17771782
"openapi_types": (str,),
17781783
"attribute": "filter[asset.name]",
@@ -2925,9 +2930,9 @@ def get_sbom(
29252930
def get_secrets_rules(
29262931
self,
29272932
) -> SecretRuleArray:
2928-
"""Returns list of Secrets rules.
2933+
"""Returns a list of Secrets rules.
29292934
2930-
Returns list of Secrets rules with ID, Pattern, Description, Priority, and SDS ID
2935+
Returns a list of Secrets rules with ID, Pattern, Description, Priority, and SDS ID.
29312936
29322937
:rtype: SecretRuleArray
29332938
"""
@@ -3943,6 +3948,7 @@ def list_vulnerabilities(
39433948
filter_fix_available: Union[bool, UnsetType] = unset,
39443949
filter_repo_digests: Union[str, UnsetType] = unset,
39453950
filter_origin: Union[str, UnsetType] = unset,
3951+
filter_running_kernel: Union[bool, UnsetType] = unset,
39463952
filter_asset_name: Union[str, UnsetType] = unset,
39473953
filter_asset_type: Union[AssetType, UnsetType] = unset,
39483954
filter_asset_version_first: Union[str, UnsetType] = unset,
@@ -4105,6 +4111,8 @@ def list_vulnerabilities(
41054111
:type filter_repo_digests: str, optional
41064112
:param filter_origin: Filter by origin.
41074113
:type filter_origin: str, optional
4114+
:param filter_running_kernel: Filter for whether the vulnerability affects a running kernel (for vulnerabilities related to a ``Host`` asset).
4115+
:type filter_running_kernel: bool, optional
41084116
:param filter_asset_name: Filter by asset name. This field supports the usage of wildcards (*).
41094117
:type filter_asset_name: str, optional
41104118
:param filter_asset_type: Filter by asset type.
@@ -4219,6 +4227,9 @@ def list_vulnerabilities(
42194227
if filter_origin is not unset:
42204228
kwargs["filter_origin"] = filter_origin
42214229

4230+
if filter_running_kernel is not unset:
4231+
kwargs["filter_running_kernel"] = filter_running_kernel
4232+
42224233
if filter_asset_name is not unset:
42234234
kwargs["filter_asset_name"] = filter_asset_name
42244235

src/datadog_api_client/v2/model/library.py

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Copyright 2019-Present Datadog, Inc.
44
from __future__ import annotations
55

6-
from typing import Union
6+
from typing import List, Union
77

88
from datadog_api_client.model_utils import (
99
ModelNormal,
@@ -17,25 +17,38 @@ class Library(ModelNormal):
1717
@cached_property
1818
def openapi_types(_):
1919
return {
20+
"additional_names": ([str],),
2021
"name": (str,),
2122
"version": (str,),
2223
}
2324

2425
attribute_map = {
26+
"additional_names": "additional_names",
2527
"name": "name",
2628
"version": "version",
2729
}
2830

29-
def __init__(self_, name: str, version: Union[str, UnsetType] = unset, **kwargs):
31+
def __init__(
32+
self_,
33+
name: str,
34+
additional_names: Union[List[str], UnsetType] = unset,
35+
version: Union[str, UnsetType] = unset,
36+
**kwargs,
37+
):
3038
"""
3139
Vulnerability library.
3240
41+
:param additional_names: Related library or package names (such as child packages or affected binary paths).
42+
:type additional_names: [str], optional
43+
3344
:param name: Vulnerability library name.
3445
:type name: str
3546
3647
:param version: Vulnerability library version.
3748
:type version: str, optional
3849
"""
50+
if additional_names is not unset:
51+
kwargs["additional_names"] = additional_names
3952
if version is not unset:
4053
kwargs["version"] = version
4154
super().__init__(kwargs)

src/datadog_api_client/v2/model/vulnerability_attributes.py

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ def openapi_types(_):
6161
"remediations": ([Remediation],),
6262
"repo_digests": ([str],),
6363
"risks": (VulnerabilityRisks,),
64+
"running_kernel": (bool,),
6465
"status": (VulnerabilityStatus,),
6566
"title": (str,),
6667
"tool": (VulnerabilityTool,),
@@ -86,6 +87,7 @@ def openapi_types(_):
8687
"remediations": "remediations",
8788
"repo_digests": "repo_digests",
8889
"risks": "risks",
90+
"running_kernel": "running_kernel",
8991
"status": "status",
9092
"title": "title",
9193
"tool": "tool",
@@ -116,6 +118,7 @@ def __init__(
116118
ecosystem: Union[VulnerabilityEcosystem, UnsetType] = unset,
117119
library: Union[Library, UnsetType] = unset,
118120
repo_digests: Union[List[str], UnsetType] = unset,
121+
running_kernel: Union[bool, UnsetType] = unset,
119122
**kwargs,
120123
):
121124
"""
@@ -175,6 +178,9 @@ def __init__(
175178
:param risks: Vulnerability risks.
176179
:type risks: VulnerabilityRisks
177180
181+
:param running_kernel: True if the vulnerability affects a package in the host’s running kernel, false if it affects a non-running kernel, and omit if it is not kernel-related.
182+
:type running_kernel: bool, optional
183+
178184
:param status: The vulnerability status.
179185
:type status: VulnerabilityStatus
180186
@@ -201,6 +207,8 @@ def __init__(
201207
kwargs["library"] = library
202208
if repo_digests is not unset:
203209
kwargs["repo_digests"] = repo_digests
210+
if running_kernel is not unset:
211+
kwargs["running_kernel"] = running_kernel
204212
super().__init__(kwargs)
205213

206214
self_.cve_list = cve_list

src/datadog_api_client/v2/model/vulnerability_ecosystem.py

Lines changed: 19 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class VulnerabilityEcosystem(ModelSimple):
1616
"""
1717
The related vulnerability asset ecosystem.
1818
19-
:param value: Must be one of ["PyPI", "Maven", "NuGet", "Npm", "RubyGems", "Go", "Packagist", "Ddeb", "Rpm", "Apk", "Windows"].
19+
:param value: Must be one of ["PyPI", "Maven", "NuGet", "Npm", "RubyGems", "Go", "Packagist", "Deb", "Rpm", "Apk", "Windows", "Generic", "MacOs", "Oci", "BottleRocket", "None"].
2020
:type value: str
2121
"""
2222

@@ -28,10 +28,15 @@ class VulnerabilityEcosystem(ModelSimple):
2828
"RubyGems",
2929
"Go",
3030
"Packagist",
31-
"Ddeb",
31+
"Deb",
3232
"Rpm",
3333
"Apk",
3434
"Windows",
35+
"Generic",
36+
"MacOs",
37+
"Oci",
38+
"BottleRocket",
39+
"None",
3540
}
3641
PYPI: ClassVar["VulnerabilityEcosystem"]
3742
MAVEN: ClassVar["VulnerabilityEcosystem"]
@@ -40,10 +45,15 @@ class VulnerabilityEcosystem(ModelSimple):
4045
RUBY_GEMS: ClassVar["VulnerabilityEcosystem"]
4146
GO: ClassVar["VulnerabilityEcosystem"]
4247
PACKAGIST: ClassVar["VulnerabilityEcosystem"]
43-
D_DEB: ClassVar["VulnerabilityEcosystem"]
48+
DEB: ClassVar["VulnerabilityEcosystem"]
4449
RPM: ClassVar["VulnerabilityEcosystem"]
4550
APK: ClassVar["VulnerabilityEcosystem"]
4651
WINDOWS: ClassVar["VulnerabilityEcosystem"]
52+
GENERIC: ClassVar["VulnerabilityEcosystem"]
53+
MAC_OS: ClassVar["VulnerabilityEcosystem"]
54+
OCI: ClassVar["VulnerabilityEcosystem"]
55+
BOTTLE_ROCKET: ClassVar["VulnerabilityEcosystem"]
56+
NONE: ClassVar["VulnerabilityEcosystem"]
4757

4858
@cached_property
4959
def openapi_types(_):
@@ -59,7 +69,12 @@ def openapi_types(_):
5969
VulnerabilityEcosystem.RUBY_GEMS = VulnerabilityEcosystem("RubyGems")
6070
VulnerabilityEcosystem.GO = VulnerabilityEcosystem("Go")
6171
VulnerabilityEcosystem.PACKAGIST = VulnerabilityEcosystem("Packagist")
62-
VulnerabilityEcosystem.D_DEB = VulnerabilityEcosystem("Ddeb")
72+
VulnerabilityEcosystem.DEB = VulnerabilityEcosystem("Deb")
6373
VulnerabilityEcosystem.RPM = VulnerabilityEcosystem("Rpm")
6474
VulnerabilityEcosystem.APK = VulnerabilityEcosystem("Apk")
6575
VulnerabilityEcosystem.WINDOWS = VulnerabilityEcosystem("Windows")
76+
VulnerabilityEcosystem.GENERIC = VulnerabilityEcosystem("Generic")
77+
VulnerabilityEcosystem.MAC_OS = VulnerabilityEcosystem("MacOs")
78+
VulnerabilityEcosystem.OCI = VulnerabilityEcosystem("Oci")
79+
VulnerabilityEcosystem.BOTTLE_ROCKET = VulnerabilityEcosystem("BottleRocket")
80+
VulnerabilityEcosystem.NONE = VulnerabilityEcosystem("None")

src/datadog_api_client/v2/model/vulnerability_tool.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,20 @@ class VulnerabilityTool(ModelSimple):
1616
"""
1717
The vulnerability tool.
1818
19-
:param value: Must be one of ["IAST", "SCA", "Infra"].
19+
:param value: Must be one of ["IAST", "SCA", "Infra", "SAST"].
2020
:type value: str
2121
"""
2222

2323
allowed_values = {
2424
"IAST",
2525
"SCA",
2626
"Infra",
27+
"SAST",
2728
}
2829
IAST: ClassVar["VulnerabilityTool"]
2930
SCA: ClassVar["VulnerabilityTool"]
3031
INFRA: ClassVar["VulnerabilityTool"]
32+
SAST: ClassVar["VulnerabilityTool"]
3133

3234
@cached_property
3335
def openapi_types(_):
@@ -39,3 +41,4 @@ def openapi_types(_):
3941
VulnerabilityTool.IAST = VulnerabilityTool("IAST")
4042
VulnerabilityTool.SCA = VulnerabilityTool("SCA")
4143
VulnerabilityTool.INFRA = VulnerabilityTool("Infra")
44+
VulnerabilityTool.SAST = VulnerabilityTool("SAST")

0 commit comments

Comments
 (0)