Skip to content

Commit 83c851e

Browse files
feat: [google-cloud-securitycenter] added cloud provider field to list findings response (#12829)
- [ ] Regenerate this pull request now. BEGIN_COMMIT_OVERRIDE feat: added cloud provider field to list findings response feat: added http configuration rule to ResourceValueConfig and ValuedResource API methods feat: added toxic combination field to finding docs: Updated comments for ResourceValueConfig feat: Add toxic_combination and group_memberships fields to finding END_COMMIT_OVERRIDE PiperOrigin-RevId: 647117058 Source-Link: googleapis/googleapis@efae79d Source-Link: googleapis/googleapis-gen@daa5c0c Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXNlY3VyaXR5Y2VudGVyLy5Pd2xCb3QueWFtbCIsImgiOiJkYWE1YzBjNjE1NDQ2MTYzNzI5ODNlMjZkMzlmOTZhNjFjM2Q5NmZhIn0= BEGIN_NESTED_COMMIT feat: [google-cloud-securitycenter] Add toxic_combination and group_memberships fields to finding PiperOrigin-RevId: 646222944 Source-Link: googleapis/googleapis@2651ef8 Source-Link: googleapis/googleapis-gen@a1a4cee Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXNlY3VyaXR5Y2VudGVyLy5Pd2xCb3QueWFtbCIsImgiOiJhMWE0Y2VlODk3YTQzM2M3OTY4MTQzYTA4NDc3NWIyNGRjNzMyMTA2In0= END_NESTED_COMMIT BEGIN_NESTED_COMMIT feat: [google-cloud-securitycenter] Add toxic_combination and group_memberships fields to finding PiperOrigin-RevId: 646198386 Source-Link: googleapis/googleapis@326be36 Source-Link: googleapis/googleapis-gen@bea3b1c Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNsb3VkLXNlY3VyaXR5Y2VudGVyLy5Pd2xCb3QueWFtbCIsImgiOiJiZWEzYjFjMTBjOTU4MmI5NTNlNWYxOWRiYzM1MDg3YWQ5ZGQ3MzcyIn0= END_NESTED_COMMIT --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: Victor Chudnovsky <vchudnov@google.com>
1 parent bbd627b commit 83c851e

File tree

30 files changed

+1598
-91
lines changed

30 files changed

+1598
-91
lines changed

packages/google-cloud-securitycenter/README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Python Client for Google Cloud Security Command Center
1515
.. |versions| image:: https://img.shields.io/pypi/pyversions/google-cloud-securitycenter.svg
1616
:target: https://pypi.org/project/google-cloud-securitycenter/
1717
.. _Google Cloud Security Command Center: https://cloud.google.com/security-command-center
18-
.. _Client Library Documentation: https://cloud.google.com/python/docs/reference/securitycenter/latest
18+
.. _Client Library Documentation: https://cloud.google.com/python/docs/reference/securitycenter/latest/summary_overview
1919
.. _Product Documentation: https://cloud.google.com/security-command-center
2020

2121
Quick Start

packages/google-cloud-securitycenter/docs/index.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,3 +48,8 @@ For a list of all ``google-cloud-securitycenter`` releases:
4848
:maxdepth: 2
4949

5050
CHANGELOG
51+
52+
.. toctree::
53+
:hidden:
54+
55+
summary_overview.md
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
[
2+
This is a templated file. Adding content to this file may result in it being
3+
reverted. Instead, if you want to place additional content, create an
4+
"overview_content.md" file in `docs/` directory. The Sphinx tool will
5+
pick up on the content and merge the content.
6+
]: #
7+
8+
# Google Cloud Security Command Center API
9+
10+
Overview of the APIs available for Google Cloud Security Command Center API.
11+
12+
## All entries
13+
14+
Classes, methods and properties & attributes for
15+
Google Cloud Security Command Center API.
16+
17+
[classes](https://cloud.google.com/python/docs/reference/securitycenter/latest/summary_class.html)
18+
19+
[methods](https://cloud.google.com/python/docs/reference/securitycenter/latest/summary_method.html)
20+
21+
[properties and
22+
attributes](https://cloud.google.com/python/docs/reference/securitycenter/latest/summary_property.html)

packages/google-cloud-securitycenter/google/cloud/securitycenter/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
from google.cloud.securitycenter_v1.types.file import File
6363
from google.cloud.securitycenter_v1.types.finding import Finding
6464
from google.cloud.securitycenter_v1.types.folder import Folder
65+
from google.cloud.securitycenter_v1.types.group_membership import GroupMembership
6566
from google.cloud.securitycenter_v1.types.iam_binding import IamBinding
6667
from google.cloud.securitycenter_v1.types.indicator import Indicator
6768
from google.cloud.securitycenter_v1.types.kernel_rootkit import KernelRootkit
@@ -152,6 +153,7 @@
152153
UpdateSourceRequest,
153154
)
154155
from google.cloud.securitycenter_v1.types.source import Source
156+
from google.cloud.securitycenter_v1.types.toxic_combination import ToxicCombination
155157
from google.cloud.securitycenter_v1.types.vulnerability import (
156158
Cve,
157159
Cvssv3,
@@ -191,6 +193,7 @@
191193
"File",
192194
"Finding",
193195
"Folder",
196+
"GroupMembership",
194197
"IamBinding",
195198
"Indicator",
196199
"KernelRootkit",
@@ -271,6 +274,7 @@
271274
"UpdateSecurityMarksRequest",
272275
"UpdateSourceRequest",
273276
"Source",
277+
"ToxicCombination",
274278
"Cve",
275279
"Cvssv3",
276280
"Package",

packages/google-cloud-securitycenter/google/cloud/securitycenter_v1/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
from .types.file import File
4747
from .types.finding import Finding
4848
from .types.folder import Folder
49+
from .types.group_membership import GroupMembership
4950
from .types.iam_binding import IamBinding
5051
from .types.indicator import Indicator
5152
from .types.kernel_rootkit import KernelRootkit
@@ -128,6 +129,7 @@
128129
UpdateSourceRequest,
129130
)
130131
from .types.source import Source
132+
from .types.toxic_combination import ToxicCombination
131133
from .types.vulnerability import (
132134
Cve,
133135
Cvssv3,
@@ -191,6 +193,7 @@
191193
"GroupAssetsResponse",
192194
"GroupFindingsRequest",
193195
"GroupFindingsResponse",
196+
"GroupMembership",
194197
"GroupResult",
195198
"IamBinding",
196199
"Indicator",
@@ -243,6 +246,7 @@
243246
"SimulateSecurityHealthAnalyticsCustomModuleRequest",
244247
"SimulateSecurityHealthAnalyticsCustomModuleResponse",
245248
"Source",
249+
"ToxicCombination",
246250
"UpdateBigQueryExportRequest",
247251
"UpdateExternalSystemRequest",
248252
"UpdateFindingRequest",

packages/google-cloud-securitycenter/google/cloud/securitycenter_v1/services/security_center/async_client.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575
security_health_analytics_custom_config,
7676
)
7777
from google.cloud.securitycenter_v1.types import (
78+
group_membership,
7879
iam_binding,
7980
indicator,
8081
kernel_rootkit,
@@ -87,6 +88,7 @@
8788
security_posture,
8889
securitycenter_service,
8990
)
91+
from google.cloud.securitycenter_v1.types import toxic_combination, vulnerability
9092
from google.cloud.securitycenter_v1.types import external_system as gcs_external_system
9193
from google.cloud.securitycenter_v1.types import (
9294
notification_config as gcs_notification_config,
@@ -111,7 +113,6 @@
111113
from google.cloud.securitycenter_v1.types import security_marks
112114
from google.cloud.securitycenter_v1.types import source
113115
from google.cloud.securitycenter_v1.types import source as gcs_source
114-
from google.cloud.securitycenter_v1.types import vulnerability
115116

116117
from .client import SecurityCenterClient
117118
from .transports.base import DEFAULT_CLIENT_INFO, SecurityCenterTransport

packages/google-cloud-securitycenter/google/cloud/securitycenter_v1/services/security_center/client.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,7 @@
7979
security_health_analytics_custom_config,
8080
)
8181
from google.cloud.securitycenter_v1.types import (
82+
group_membership,
8283
iam_binding,
8384
indicator,
8485
kernel_rootkit,
@@ -91,6 +92,7 @@
9192
security_posture,
9293
securitycenter_service,
9394
)
95+
from google.cloud.securitycenter_v1.types import toxic_combination, vulnerability
9496
from google.cloud.securitycenter_v1.types import external_system as gcs_external_system
9597
from google.cloud.securitycenter_v1.types import (
9698
notification_config as gcs_notification_config,
@@ -115,7 +117,6 @@
115117
from google.cloud.securitycenter_v1.types import security_marks
116118
from google.cloud.securitycenter_v1.types import source
117119
from google.cloud.securitycenter_v1.types import source as gcs_source
118-
from google.cloud.securitycenter_v1.types import vulnerability
119120

120121
from .transports.base import DEFAULT_CLIENT_INFO, SecurityCenterTransport
121122
from .transports.grpc import SecurityCenterGrpcTransport

packages/google-cloud-securitycenter/google/cloud/securitycenter_v1/types/__init__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@
4040
from .file import File
4141
from .finding import Finding
4242
from .folder import Folder
43+
from .group_membership import GroupMembership
4344
from .iam_binding import IamBinding
4445
from .indicator import Indicator
4546
from .kernel_rootkit import KernelRootkit
@@ -120,6 +121,7 @@
120121
UpdateSourceRequest,
121122
)
122123
from .source import Source
124+
from .toxic_combination import ToxicCombination
123125
from .vulnerability import (
124126
Cve,
125127
Cvssv3,
@@ -157,6 +159,7 @@
157159
"File",
158160
"Finding",
159161
"Folder",
162+
"GroupMembership",
160163
"IamBinding",
161164
"Indicator",
162165
"KernelRootkit",
@@ -237,6 +240,7 @@
237240
"UpdateSecurityMarksRequest",
238241
"UpdateSourceRequest",
239242
"Source",
243+
"ToxicCombination",
240244
"Cve",
241245
"Cvssv3",
242246
"Package",

packages/google-cloud-securitycenter/google/cloud/securitycenter_v1/types/finding.py

Lines changed: 42 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,12 @@
2727
contact_details,
2828
container,
2929
)
30-
from google.cloud.securitycenter_v1.types import external_system, file, iam_binding
30+
from google.cloud.securitycenter_v1.types import (
31+
external_system,
32+
file,
33+
group_membership,
34+
iam_binding,
35+
)
3136
from google.cloud.securitycenter_v1.types import (
3237
backup_disaster_recovery as gcs_backup_disaster_recovery,
3338
)
@@ -44,6 +49,9 @@
4449
from google.cloud.securitycenter_v1.types import (
4550
security_posture as gcs_security_posture,
4651
)
52+
from google.cloud.securitycenter_v1.types import (
53+
toxic_combination as gcs_toxic_combination,
54+
)
4755
from google.cloud.securitycenter_v1.types import vulnerability as gcs_vulnerability
4856
from google.cloud.securitycenter_v1.types import access as gcs_access
4957
from google.cloud.securitycenter_v1.types import application as gcs_application
@@ -268,6 +276,20 @@ class Finding(proto.Message):
268276
Fields related to Cloud Armor findings.
269277
notebook (google.cloud.securitycenter_v1.types.Notebook):
270278
Notebook associated with the finding.
279+
toxic_combination (google.cloud.securitycenter_v1.types.ToxicCombination):
280+
Contains details about a group of security
281+
issues that, when the issues occur together,
282+
represent a greater risk than when the issues
283+
occur independently. A group of such issues is
284+
referred to as a toxic combination.
285+
This field cannot be updated. Its value is
286+
ignored in all update requests.
287+
group_memberships (MutableSequence[google.cloud.securitycenter_v1.types.GroupMembership]):
288+
Contains details about groups of which this
289+
finding is a member. A group is a collection of
290+
findings that are related in some way. This
291+
field cannot be updated. Its value is ignored in
292+
all update requests.
271293
"""
272294

273295
class State(proto.Enum):
@@ -419,6 +441,12 @@ class FindingClass(proto.Enum):
419441
POSTURE_VIOLATION (6):
420442
Describes a potential security risk due to a
421443
change in the security posture.
444+
TOXIC_COMBINATION (7):
445+
Describes a group of security issues that,
446+
when the issues occur together, represent a
447+
greater risk than when the issues occur
448+
independently. A group of such issues is
449+
referred to as a toxic combination.
422450
"""
423451
FINDING_CLASS_UNSPECIFIED = 0
424452
THREAT = 1
@@ -427,6 +455,7 @@ class FindingClass(proto.Enum):
427455
OBSERVATION = 4
428456
SCC_ERROR = 5
429457
POSTURE_VIOLATION = 6
458+
TOXIC_COMBINATION = 7
430459

431460
name: str = proto.Field(
432461
proto.STRING,
@@ -656,6 +685,18 @@ class FindingClass(proto.Enum):
656685
number=63,
657686
message=gcs_notebook.Notebook,
658687
)
688+
toxic_combination: gcs_toxic_combination.ToxicCombination = proto.Field(
689+
proto.MESSAGE,
690+
number=64,
691+
message=gcs_toxic_combination.ToxicCombination,
692+
)
693+
group_memberships: MutableSequence[
694+
group_membership.GroupMembership
695+
] = proto.RepeatedField(
696+
proto.MESSAGE,
697+
number=65,
698+
message=group_membership.GroupMembership,
699+
)
659700

660701

661702
__all__ = tuple(sorted(__protobuf__.manifest))
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# -*- coding: utf-8 -*-
2+
# Copyright 2024 Google LLC
3+
#
4+
# Licensed under the Apache License, Version 2.0 (the "License");
5+
# you may not use this file except in compliance with the License.
6+
# You may obtain a copy of the License at
7+
#
8+
# http://www.apache.org/licenses/LICENSE-2.0
9+
#
10+
# Unless required by applicable law or agreed to in writing, software
11+
# distributed under the License is distributed on an "AS IS" BASIS,
12+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
# See the License for the specific language governing permissions and
14+
# limitations under the License.
15+
#
16+
from __future__ import annotations
17+
18+
from typing import MutableMapping, MutableSequence
19+
20+
import proto # type: ignore
21+
22+
__protobuf__ = proto.module(
23+
package="google.cloud.securitycenter.v1",
24+
manifest={
25+
"GroupMembership",
26+
},
27+
)
28+
29+
30+
class GroupMembership(proto.Message):
31+
r"""Contains details about groups of which this finding is a
32+
member. A group is a collection of findings that are related in
33+
some way.
34+
35+
Attributes:
36+
group_type (google.cloud.securitycenter_v1.types.GroupMembership.GroupType):
37+
Type of group.
38+
group_id (str):
39+
ID of the group.
40+
"""
41+
42+
class GroupType(proto.Enum):
43+
r"""Possible types of groups.
44+
45+
Values:
46+
GROUP_TYPE_UNSPECIFIED (0):
47+
Default value.
48+
GROUP_TYPE_TOXIC_COMBINATION (1):
49+
Group represents a toxic combination.
50+
"""
51+
GROUP_TYPE_UNSPECIFIED = 0
52+
GROUP_TYPE_TOXIC_COMBINATION = 1
53+
54+
group_type: GroupType = proto.Field(
55+
proto.ENUM,
56+
number=1,
57+
enum=GroupType,
58+
)
59+
group_id: str = proto.Field(
60+
proto.STRING,
61+
number=2,
62+
)
63+
64+
65+
__all__ = tuple(sorted(__protobuf__.manifest))

0 commit comments

Comments
 (0)