google-cloud-privilegedaccessmanager 0.1.2__tar.gz → 0.1.4__tar.gz
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.
- {google_cloud_privilegedaccessmanager-0.1.2/google_cloud_privilegedaccessmanager.egg-info → google_cloud_privilegedaccessmanager-0.1.4}/PKG-INFO +1 -1
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager/gapic_version.py +1 -1
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/gapic_version.py +1 -1
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/async_client.py +22 -28
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/client.py +25 -65
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/grpc.py +8 -8
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/grpc_asyncio.py +8 -8
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/rest.py +12 -20
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/types/privilegedaccessmanager.py +9 -14
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4/google_cloud_privilegedaccessmanager.egg-info}/PKG-INFO +1 -1
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/tests/unit/gapic/privilegedaccessmanager_v1/test_privileged_access_manager.py +0 -88
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/LICENSE +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/MANIFEST.in +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/README.rst +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager/py.typed +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/gapic_metadata.json +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/py.typed +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/pagers.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/base.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/services/privileged_access_manager/transports/rest_base.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google/cloud/privilegedaccessmanager_v1/types/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google_cloud_privilegedaccessmanager.egg-info/SOURCES.txt +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google_cloud_privilegedaccessmanager.egg-info/dependency_links.txt +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google_cloud_privilegedaccessmanager.egg-info/not-zip-safe +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google_cloud_privilegedaccessmanager.egg-info/requires.txt +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/google_cloud_privilegedaccessmanager.egg-info/top_level.txt +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/setup.cfg +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/setup.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/tests/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/tests/unit/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/tests/unit/gapic/__init__.py +0 -0
- {google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/tests/unit/gapic/privilegedaccessmanager_v1/__init__.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: google-cloud-privilegedaccessmanager
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.4
|
|
4
4
|
Summary: Google Cloud Privilegedaccessmanager API client library
|
|
5
5
|
Home-page: https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-privilegedaccessmanager
|
|
6
6
|
Author: Google LLC
|
|
@@ -311,10 +311,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
311
311
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
312
312
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
313
313
|
) -> privilegedaccessmanager.CheckOnboardingStatusResponse:
|
|
314
|
-
r"""CheckOnboardingStatus reports the onboarding status
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
the resource.
|
|
314
|
+
r"""``CheckOnboardingStatus`` reports the onboarding status for a
|
|
315
|
+
project/folder/organization. Any findings reported by this API
|
|
316
|
+
need to be fixed before PAM can be used on the resource.
|
|
318
317
|
|
|
319
318
|
.. code-block:: python
|
|
320
319
|
|
|
@@ -886,9 +885,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
886
885
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
887
886
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
888
887
|
) -> operation_async.AsyncOperation:
|
|
889
|
-
r"""Deletes a single entitlement. This method can only be
|
|
890
|
-
|
|
891
|
-
(ACTIVE
|
|
888
|
+
r"""Deletes a single entitlement. This method can only be called
|
|
889
|
+
when there are no in-progress
|
|
890
|
+
(``ACTIVE``/``ACTIVATING``/``REVOKING``) grants under the
|
|
892
891
|
entitlement.
|
|
893
892
|
|
|
894
893
|
.. code-block:: python
|
|
@@ -1438,10 +1437,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1438
1437
|
|
|
1439
1438
|
Returns:
|
|
1440
1439
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
they are eligible for.
|
|
1440
|
+
A grant represents a request from a
|
|
1441
|
+
user for obtaining the access specified
|
|
1442
|
+
in an entitlement they are eligible for.
|
|
1445
1443
|
|
|
1446
1444
|
"""
|
|
1447
1445
|
# Create or coerce a protobuf request object.
|
|
@@ -1502,7 +1500,8 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1502
1500
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
1503
1501
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
1504
1502
|
) -> privilegedaccessmanager.Grant:
|
|
1505
|
-
r"""Creates a new grant in a given
|
|
1503
|
+
r"""Creates a new grant in a given
|
|
1504
|
+
project/folder/organization and location.
|
|
1506
1505
|
|
|
1507
1506
|
.. code-block:: python
|
|
1508
1507
|
|
|
@@ -1554,10 +1553,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1554
1553
|
|
|
1555
1554
|
Returns:
|
|
1556
1555
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
they are eligible for.
|
|
1556
|
+
A grant represents a request from a
|
|
1557
|
+
user for obtaining the access specified
|
|
1558
|
+
in an entitlement they are eligible for.
|
|
1561
1559
|
|
|
1562
1560
|
"""
|
|
1563
1561
|
# Create or coerce a protobuf request object.
|
|
@@ -1659,10 +1657,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1659
1657
|
|
|
1660
1658
|
Returns:
|
|
1661
1659
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1662
|
-
|
|
1663
|
-
|
|
1664
|
-
|
|
1665
|
-
they are eligible for.
|
|
1660
|
+
A grant represents a request from a
|
|
1661
|
+
user for obtaining the access specified
|
|
1662
|
+
in an entitlement they are eligible for.
|
|
1666
1663
|
|
|
1667
1664
|
"""
|
|
1668
1665
|
# Create or coerce a protobuf request object.
|
|
@@ -1746,10 +1743,9 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1746
1743
|
|
|
1747
1744
|
Returns:
|
|
1748
1745
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1749
|
-
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
they are eligible for.
|
|
1746
|
+
A grant represents a request from a
|
|
1747
|
+
user for obtaining the access specified
|
|
1748
|
+
in an entitlement they are eligible for.
|
|
1753
1749
|
|
|
1754
1750
|
"""
|
|
1755
1751
|
# Create or coerce a protobuf request object.
|
|
@@ -1841,10 +1837,8 @@ class PrivilegedAccessManagerAsyncClient:
|
|
|
1841
1837
|
google.api_core.operation_async.AsyncOperation:
|
|
1842
1838
|
An object representing a long-running operation.
|
|
1843
1839
|
|
|
1844
|
-
The result type for the operation will be :class:`google.cloud.privilegedaccessmanager_v1.types.Grant`
|
|
1845
|
-
|
|
1846
|
-
for obtaining the access specified in an entitlement
|
|
1847
|
-
they are eligible for.
|
|
1840
|
+
The result type for the operation will be :class:`google.cloud.privilegedaccessmanager_v1.types.Grant` A grant represents a request from a user for obtaining the access specified
|
|
1841
|
+
in an entitlement they are eligible for.
|
|
1848
1842
|
|
|
1849
1843
|
"""
|
|
1850
1844
|
# Create or coerce a protobuf request object.
|
|
@@ -522,36 +522,6 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
522
522
|
raise ValueError("Universe Domain cannot be an empty string.")
|
|
523
523
|
return universe_domain
|
|
524
524
|
|
|
525
|
-
@staticmethod
|
|
526
|
-
def _compare_universes(
|
|
527
|
-
client_universe: str, credentials: ga_credentials.Credentials
|
|
528
|
-
) -> bool:
|
|
529
|
-
"""Returns True iff the universe domains used by the client and credentials match.
|
|
530
|
-
|
|
531
|
-
Args:
|
|
532
|
-
client_universe (str): The universe domain configured via the client options.
|
|
533
|
-
credentials (ga_credentials.Credentials): The credentials being used in the client.
|
|
534
|
-
|
|
535
|
-
Returns:
|
|
536
|
-
bool: True iff client_universe matches the universe in credentials.
|
|
537
|
-
|
|
538
|
-
Raises:
|
|
539
|
-
ValueError: when client_universe does not match the universe in credentials.
|
|
540
|
-
"""
|
|
541
|
-
|
|
542
|
-
default_universe = PrivilegedAccessManagerClient._DEFAULT_UNIVERSE
|
|
543
|
-
credentials_universe = getattr(credentials, "universe_domain", default_universe)
|
|
544
|
-
|
|
545
|
-
if client_universe != credentials_universe:
|
|
546
|
-
raise ValueError(
|
|
547
|
-
"The configured universe domain "
|
|
548
|
-
f"({client_universe}) does not match the universe domain "
|
|
549
|
-
f"found in the credentials ({credentials_universe}). "
|
|
550
|
-
"If you haven't configured the universe domain explicitly, "
|
|
551
|
-
f"`{default_universe}` is the default."
|
|
552
|
-
)
|
|
553
|
-
return True
|
|
554
|
-
|
|
555
525
|
def _validate_universe_domain(self):
|
|
556
526
|
"""Validates client's and credentials' universe domains are consistent.
|
|
557
527
|
|
|
@@ -561,13 +531,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
561
531
|
Raises:
|
|
562
532
|
ValueError: If the configured universe domain is not valid.
|
|
563
533
|
"""
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
self.universe_domain, self.transport._credentials
|
|
568
|
-
)
|
|
569
|
-
)
|
|
570
|
-
return self._is_universe_domain_valid
|
|
534
|
+
|
|
535
|
+
# NOTE (b/349488459): universe validation is disabled until further notice.
|
|
536
|
+
return True
|
|
571
537
|
|
|
572
538
|
@property
|
|
573
539
|
def api_endpoint(self):
|
|
@@ -755,10 +721,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
755
721
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
756
722
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
757
723
|
) -> privilegedaccessmanager.CheckOnboardingStatusResponse:
|
|
758
|
-
r"""CheckOnboardingStatus reports the onboarding status
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
the resource.
|
|
724
|
+
r"""``CheckOnboardingStatus`` reports the onboarding status for a
|
|
725
|
+
project/folder/organization. Any findings reported by this API
|
|
726
|
+
need to be fixed before PAM can be used on the resource.
|
|
762
727
|
|
|
763
728
|
.. code-block:: python
|
|
764
729
|
|
|
@@ -1317,9 +1282,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
1317
1282
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
1318
1283
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
1319
1284
|
) -> operation.Operation:
|
|
1320
|
-
r"""Deletes a single entitlement. This method can only be
|
|
1321
|
-
|
|
1322
|
-
(ACTIVE
|
|
1285
|
+
r"""Deletes a single entitlement. This method can only be called
|
|
1286
|
+
when there are no in-progress
|
|
1287
|
+
(``ACTIVE``/``ACTIVATING``/``REVOKING``) grants under the
|
|
1323
1288
|
entitlement.
|
|
1324
1289
|
|
|
1325
1290
|
.. code-block:: python
|
|
@@ -1858,10 +1823,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
1858
1823
|
|
|
1859
1824
|
Returns:
|
|
1860
1825
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
they are eligible for.
|
|
1826
|
+
A grant represents a request from a
|
|
1827
|
+
user for obtaining the access specified
|
|
1828
|
+
in an entitlement they are eligible for.
|
|
1865
1829
|
|
|
1866
1830
|
"""
|
|
1867
1831
|
# Create or coerce a protobuf request object.
|
|
@@ -1919,7 +1883,8 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
1919
1883
|
timeout: Union[float, object] = gapic_v1.method.DEFAULT,
|
|
1920
1884
|
metadata: Sequence[Tuple[str, str]] = (),
|
|
1921
1885
|
) -> privilegedaccessmanager.Grant:
|
|
1922
|
-
r"""Creates a new grant in a given
|
|
1886
|
+
r"""Creates a new grant in a given
|
|
1887
|
+
project/folder/organization and location.
|
|
1923
1888
|
|
|
1924
1889
|
.. code-block:: python
|
|
1925
1890
|
|
|
@@ -1971,10 +1936,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
1971
1936
|
|
|
1972
1937
|
Returns:
|
|
1973
1938
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
they are eligible for.
|
|
1939
|
+
A grant represents a request from a
|
|
1940
|
+
user for obtaining the access specified
|
|
1941
|
+
in an entitlement they are eligible for.
|
|
1978
1942
|
|
|
1979
1943
|
"""
|
|
1980
1944
|
# Create or coerce a protobuf request object.
|
|
@@ -2073,10 +2037,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
2073
2037
|
|
|
2074
2038
|
Returns:
|
|
2075
2039
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
2076
|
-
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
they are eligible for.
|
|
2040
|
+
A grant represents a request from a
|
|
2041
|
+
user for obtaining the access specified
|
|
2042
|
+
in an entitlement they are eligible for.
|
|
2080
2043
|
|
|
2081
2044
|
"""
|
|
2082
2045
|
# Create or coerce a protobuf request object.
|
|
@@ -2158,10 +2121,9 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
2158
2121
|
|
|
2159
2122
|
Returns:
|
|
2160
2123
|
google.cloud.privilegedaccessmanager_v1.types.Grant:
|
|
2161
|
-
|
|
2162
|
-
|
|
2163
|
-
|
|
2164
|
-
they are eligible for.
|
|
2124
|
+
A grant represents a request from a
|
|
2125
|
+
user for obtaining the access specified
|
|
2126
|
+
in an entitlement they are eligible for.
|
|
2165
2127
|
|
|
2166
2128
|
"""
|
|
2167
2129
|
# Create or coerce a protobuf request object.
|
|
@@ -2251,10 +2213,8 @@ class PrivilegedAccessManagerClient(metaclass=PrivilegedAccessManagerClientMeta)
|
|
|
2251
2213
|
google.api_core.operation.Operation:
|
|
2252
2214
|
An object representing a long-running operation.
|
|
2253
2215
|
|
|
2254
|
-
The result type for the operation will be :class:`google.cloud.privilegedaccessmanager_v1.types.Grant`
|
|
2255
|
-
|
|
2256
|
-
for obtaining the access specified in an entitlement
|
|
2257
|
-
they are eligible for.
|
|
2216
|
+
The result type for the operation will be :class:`google.cloud.privilegedaccessmanager_v1.types.Grant` A grant represents a request from a user for obtaining the access specified
|
|
2217
|
+
in an entitlement they are eligible for.
|
|
2258
2218
|
|
|
2259
2219
|
"""
|
|
2260
2220
|
# Create or coerce a protobuf request object.
|
|
@@ -282,10 +282,9 @@ class PrivilegedAccessManagerGrpcTransport(PrivilegedAccessManagerTransport):
|
|
|
282
282
|
]:
|
|
283
283
|
r"""Return a callable for the check onboarding status method over gRPC.
|
|
284
284
|
|
|
285
|
-
CheckOnboardingStatus reports the onboarding status
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
the resource.
|
|
285
|
+
``CheckOnboardingStatus`` reports the onboarding status for a
|
|
286
|
+
project/folder/organization. Any findings reported by this API
|
|
287
|
+
need to be fixed before PAM can be used on the resource.
|
|
289
288
|
|
|
290
289
|
Returns:
|
|
291
290
|
Callable[[~.CheckOnboardingStatusRequest],
|
|
@@ -431,9 +430,9 @@ class PrivilegedAccessManagerGrpcTransport(PrivilegedAccessManagerTransport):
|
|
|
431
430
|
]:
|
|
432
431
|
r"""Return a callable for the delete entitlement method over gRPC.
|
|
433
432
|
|
|
434
|
-
Deletes a single entitlement. This method can only be
|
|
435
|
-
|
|
436
|
-
(ACTIVE
|
|
433
|
+
Deletes a single entitlement. This method can only be called
|
|
434
|
+
when there are no in-progress
|
|
435
|
+
(``ACTIVE``/``ACTIVATING``/``REVOKING``) grants under the
|
|
437
436
|
entitlement.
|
|
438
437
|
|
|
439
438
|
Returns:
|
|
@@ -597,7 +596,8 @@ class PrivilegedAccessManagerGrpcTransport(PrivilegedAccessManagerTransport):
|
|
|
597
596
|
]:
|
|
598
597
|
r"""Return a callable for the create grant method over gRPC.
|
|
599
598
|
|
|
600
|
-
Creates a new grant in a given
|
|
599
|
+
Creates a new grant in a given
|
|
600
|
+
project/folder/organization and location.
|
|
601
601
|
|
|
602
602
|
Returns:
|
|
603
603
|
Callable[[~.CreateGrantRequest],
|
|
@@ -292,10 +292,9 @@ class PrivilegedAccessManagerGrpcAsyncIOTransport(PrivilegedAccessManagerTranspo
|
|
|
292
292
|
]:
|
|
293
293
|
r"""Return a callable for the check onboarding status method over gRPC.
|
|
294
294
|
|
|
295
|
-
CheckOnboardingStatus reports the onboarding status
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
the resource.
|
|
295
|
+
``CheckOnboardingStatus`` reports the onboarding status for a
|
|
296
|
+
project/folder/organization. Any findings reported by this API
|
|
297
|
+
need to be fixed before PAM can be used on the resource.
|
|
299
298
|
|
|
300
299
|
Returns:
|
|
301
300
|
Callable[[~.CheckOnboardingStatusRequest],
|
|
@@ -443,9 +442,9 @@ class PrivilegedAccessManagerGrpcAsyncIOTransport(PrivilegedAccessManagerTranspo
|
|
|
443
442
|
]:
|
|
444
443
|
r"""Return a callable for the delete entitlement method over gRPC.
|
|
445
444
|
|
|
446
|
-
Deletes a single entitlement. This method can only be
|
|
447
|
-
|
|
448
|
-
(ACTIVE
|
|
445
|
+
Deletes a single entitlement. This method can only be called
|
|
446
|
+
when there are no in-progress
|
|
447
|
+
(``ACTIVE``/``ACTIVATING``/``REVOKING``) grants under the
|
|
449
448
|
entitlement.
|
|
450
449
|
|
|
451
450
|
Returns:
|
|
@@ -612,7 +611,8 @@ class PrivilegedAccessManagerGrpcAsyncIOTransport(PrivilegedAccessManagerTranspo
|
|
|
612
611
|
]:
|
|
613
612
|
r"""Return a callable for the create grant method over gRPC.
|
|
614
613
|
|
|
615
|
-
Creates a new grant in a given
|
|
614
|
+
Creates a new grant in a given
|
|
615
|
+
project/folder/organization and location.
|
|
616
616
|
|
|
617
617
|
Returns:
|
|
618
618
|
Callable[[~.CreateGrantRequest],
|
|
@@ -860,11 +860,9 @@ class PrivilegedAccessManagerRestTransport(_BasePrivilegedAccessManagerRestTrans
|
|
|
860
860
|
|
|
861
861
|
Returns:
|
|
862
862
|
~.privilegedaccessmanager.Grant:
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
access specified in an entitlement they are eligible
|
|
867
|
-
for.
|
|
863
|
+
A grant represents a request from a
|
|
864
|
+
user for obtaining the access specified
|
|
865
|
+
in an entitlement they are eligible for.
|
|
868
866
|
|
|
869
867
|
"""
|
|
870
868
|
|
|
@@ -1151,11 +1149,9 @@ class PrivilegedAccessManagerRestTransport(_BasePrivilegedAccessManagerRestTrans
|
|
|
1151
1149
|
|
|
1152
1150
|
Returns:
|
|
1153
1151
|
~.privilegedaccessmanager.Grant:
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
access specified in an entitlement they are eligible
|
|
1158
|
-
for.
|
|
1152
|
+
A grant represents a request from a
|
|
1153
|
+
user for obtaining the access specified
|
|
1154
|
+
in an entitlement they are eligible for.
|
|
1159
1155
|
|
|
1160
1156
|
"""
|
|
1161
1157
|
|
|
@@ -1345,11 +1341,9 @@ class PrivilegedAccessManagerRestTransport(_BasePrivilegedAccessManagerRestTrans
|
|
|
1345
1341
|
|
|
1346
1342
|
Returns:
|
|
1347
1343
|
~.privilegedaccessmanager.Grant:
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
access specified in an entitlement they are eligible
|
|
1352
|
-
for.
|
|
1344
|
+
A grant represents a request from a
|
|
1345
|
+
user for obtaining the access specified
|
|
1346
|
+
in an entitlement they are eligible for.
|
|
1353
1347
|
|
|
1354
1348
|
"""
|
|
1355
1349
|
|
|
@@ -1540,11 +1534,9 @@ class PrivilegedAccessManagerRestTransport(_BasePrivilegedAccessManagerRestTrans
|
|
|
1540
1534
|
|
|
1541
1535
|
Returns:
|
|
1542
1536
|
~.privilegedaccessmanager.Grant:
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
access specified in an entitlement they are eligible
|
|
1547
|
-
for.
|
|
1537
|
+
A grant represents a request from a
|
|
1538
|
+
user for obtaining the access specified
|
|
1539
|
+
in an entitlement they are eligible for.
|
|
1548
1540
|
|
|
1549
1541
|
"""
|
|
1550
1542
|
|
|
@@ -277,7 +277,7 @@ class Entitlement(proto.Message):
|
|
|
277
277
|
)
|
|
278
278
|
|
|
279
279
|
class AdditionalNotificationTargets(proto.Message):
|
|
280
|
-
r"""AdditionalNotificationTargets includes email addresses to be
|
|
280
|
+
r"""``AdditionalNotificationTargets`` includes email addresses to be
|
|
281
281
|
notified.
|
|
282
282
|
|
|
283
283
|
Attributes:
|
|
@@ -355,8 +355,7 @@ class Entitlement(proto.Message):
|
|
|
355
355
|
|
|
356
356
|
|
|
357
357
|
class AccessControlEntry(proto.Message):
|
|
358
|
-
r"""AccessControlEntry is used to control who can do some
|
|
359
|
-
operation.
|
|
358
|
+
r"""``AccessControlEntry`` is used to control who can do some operation.
|
|
360
359
|
|
|
361
360
|
Attributes:
|
|
362
361
|
principals (MutableSequence[str]):
|
|
@@ -486,7 +485,7 @@ class PrivilegedAccess(proto.Message):
|
|
|
486
485
|
"""
|
|
487
486
|
|
|
488
487
|
class GcpIamAccess(proto.Message):
|
|
489
|
-
r"""GcpIamAccess represents IAM based access control on a Google
|
|
488
|
+
r"""``GcpIamAccess`` represents IAM based access control on a Google
|
|
490
489
|
Cloud resource. Refer to https://cloud.google.com/iam/docs to
|
|
491
490
|
understand more about IAM.
|
|
492
491
|
|
|
@@ -501,7 +500,7 @@ class PrivilegedAccess(proto.Message):
|
|
|
501
500
|
"""
|
|
502
501
|
|
|
503
502
|
class RoleBinding(proto.Message):
|
|
504
|
-
r"""IAM
|
|
503
|
+
r"""IAM role bindings that are created after a successful grant.
|
|
505
504
|
|
|
506
505
|
Attributes:
|
|
507
506
|
role (str):
|
|
@@ -772,7 +771,7 @@ class CreateEntitlementRequest(proto.Message):
|
|
|
772
771
|
so, ignores the second request and returns the
|
|
773
772
|
previous operation's response. This prevents
|
|
774
773
|
clients from accidentally creating duplicate
|
|
775
|
-
|
|
774
|
+
entitlements.
|
|
776
775
|
|
|
777
776
|
The request ID must be a valid UUID with the
|
|
778
777
|
exception that zero UUID is not supported
|
|
@@ -817,9 +816,7 @@ class DeleteEntitlementRequest(proto.Message):
|
|
|
817
816
|
you make the request again with the same request
|
|
818
817
|
ID, the server can check if original operation
|
|
819
818
|
with the same request ID was received, and if
|
|
820
|
-
so, ignores the second request.
|
|
821
|
-
clients from accidentally creating duplicate
|
|
822
|
-
commitments.
|
|
819
|
+
so, ignores the second request.
|
|
823
820
|
|
|
824
821
|
The request ID must be a valid UUID with the
|
|
825
822
|
exception that zero UUID is not supported
|
|
@@ -879,10 +876,8 @@ class UpdateEntitlementRequest(proto.Message):
|
|
|
879
876
|
|
|
880
877
|
|
|
881
878
|
class Grant(proto.Message):
|
|
882
|
-
r"""
|
|
883
|
-
|
|
884
|
-
obtaining the access specified in an entitlement they are eligible
|
|
885
|
-
for.
|
|
879
|
+
r"""A grant represents a request from a user for obtaining the
|
|
880
|
+
access specified in an entitlement they are eligible for.
|
|
886
881
|
|
|
887
882
|
Attributes:
|
|
888
883
|
name (str):
|
|
@@ -1643,7 +1638,7 @@ class CreateGrantRequest(proto.Message):
|
|
|
1643
1638
|
with the same request ID was received, and if
|
|
1644
1639
|
so, ignores the second request. This prevents
|
|
1645
1640
|
clients from accidentally creating duplicate
|
|
1646
|
-
|
|
1641
|
+
grants.
|
|
1647
1642
|
|
|
1648
1643
|
The request ID must be a valid UUID with the
|
|
1649
1644
|
exception that zero UUID is not supported
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: google-cloud-privilegedaccessmanager
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.4
|
|
4
4
|
Summary: Google Cloud Privilegedaccessmanager API client library
|
|
5
5
|
Home-page: https://github.com/googleapis/google-cloud-python/tree/main/packages/google-cloud-privilegedaccessmanager
|
|
6
6
|
Author: Google LLC
|
|
@@ -351,94 +351,6 @@ def test__get_universe_domain():
|
|
|
351
351
|
assert str(excinfo.value) == "Universe Domain cannot be an empty string."
|
|
352
352
|
|
|
353
353
|
|
|
354
|
-
@pytest.mark.parametrize(
|
|
355
|
-
"client_class,transport_class,transport_name",
|
|
356
|
-
[
|
|
357
|
-
(
|
|
358
|
-
PrivilegedAccessManagerClient,
|
|
359
|
-
transports.PrivilegedAccessManagerGrpcTransport,
|
|
360
|
-
"grpc",
|
|
361
|
-
),
|
|
362
|
-
(
|
|
363
|
-
PrivilegedAccessManagerClient,
|
|
364
|
-
transports.PrivilegedAccessManagerRestTransport,
|
|
365
|
-
"rest",
|
|
366
|
-
),
|
|
367
|
-
],
|
|
368
|
-
)
|
|
369
|
-
def test__validate_universe_domain(client_class, transport_class, transport_name):
|
|
370
|
-
client = client_class(
|
|
371
|
-
transport=transport_class(credentials=ga_credentials.AnonymousCredentials())
|
|
372
|
-
)
|
|
373
|
-
assert client._validate_universe_domain() == True
|
|
374
|
-
|
|
375
|
-
# Test the case when universe is already validated.
|
|
376
|
-
assert client._validate_universe_domain() == True
|
|
377
|
-
|
|
378
|
-
if transport_name == "grpc":
|
|
379
|
-
# Test the case where credentials are provided by the
|
|
380
|
-
# `local_channel_credentials`. The default universes in both match.
|
|
381
|
-
channel = grpc.secure_channel(
|
|
382
|
-
"http://localhost/", grpc.local_channel_credentials()
|
|
383
|
-
)
|
|
384
|
-
client = client_class(transport=transport_class(channel=channel))
|
|
385
|
-
assert client._validate_universe_domain() == True
|
|
386
|
-
|
|
387
|
-
# Test the case where credentials do not exist: e.g. a transport is provided
|
|
388
|
-
# with no credentials. Validation should still succeed because there is no
|
|
389
|
-
# mismatch with non-existent credentials.
|
|
390
|
-
channel = grpc.secure_channel(
|
|
391
|
-
"http://localhost/", grpc.local_channel_credentials()
|
|
392
|
-
)
|
|
393
|
-
transport = transport_class(channel=channel)
|
|
394
|
-
transport._credentials = None
|
|
395
|
-
client = client_class(transport=transport)
|
|
396
|
-
assert client._validate_universe_domain() == True
|
|
397
|
-
|
|
398
|
-
# TODO: This is needed to cater for older versions of google-auth
|
|
399
|
-
# Make this test unconditional once the minimum supported version of
|
|
400
|
-
# google-auth becomes 2.23.0 or higher.
|
|
401
|
-
google_auth_major, google_auth_minor = [
|
|
402
|
-
int(part) for part in google.auth.__version__.split(".")[0:2]
|
|
403
|
-
]
|
|
404
|
-
if google_auth_major > 2 or (google_auth_major == 2 and google_auth_minor >= 23):
|
|
405
|
-
credentials = ga_credentials.AnonymousCredentials()
|
|
406
|
-
credentials._universe_domain = "foo.com"
|
|
407
|
-
# Test the case when there is a universe mismatch from the credentials.
|
|
408
|
-
client = client_class(transport=transport_class(credentials=credentials))
|
|
409
|
-
with pytest.raises(ValueError) as excinfo:
|
|
410
|
-
client._validate_universe_domain()
|
|
411
|
-
assert (
|
|
412
|
-
str(excinfo.value)
|
|
413
|
-
== "The configured universe domain (googleapis.com) does not match the universe domain found in the credentials (foo.com). If you haven't configured the universe domain explicitly, `googleapis.com` is the default."
|
|
414
|
-
)
|
|
415
|
-
|
|
416
|
-
# Test the case when there is a universe mismatch from the client.
|
|
417
|
-
#
|
|
418
|
-
# TODO: Make this test unconditional once the minimum supported version of
|
|
419
|
-
# google-api-core becomes 2.15.0 or higher.
|
|
420
|
-
api_core_major, api_core_minor = [
|
|
421
|
-
int(part) for part in api_core_version.__version__.split(".")[0:2]
|
|
422
|
-
]
|
|
423
|
-
if api_core_major > 2 or (api_core_major == 2 and api_core_minor >= 15):
|
|
424
|
-
client = client_class(
|
|
425
|
-
client_options={"universe_domain": "bar.com"},
|
|
426
|
-
transport=transport_class(
|
|
427
|
-
credentials=ga_credentials.AnonymousCredentials(),
|
|
428
|
-
),
|
|
429
|
-
)
|
|
430
|
-
with pytest.raises(ValueError) as excinfo:
|
|
431
|
-
client._validate_universe_domain()
|
|
432
|
-
assert (
|
|
433
|
-
str(excinfo.value)
|
|
434
|
-
== "The configured universe domain (bar.com) does not match the universe domain found in the credentials (googleapis.com). If you haven't configured the universe domain explicitly, `googleapis.com` is the default."
|
|
435
|
-
)
|
|
436
|
-
|
|
437
|
-
# Test that ValueError is raised if universe_domain is provided via client options and credentials is None
|
|
438
|
-
with pytest.raises(ValueError):
|
|
439
|
-
client._compare_universes("foo.bar", None)
|
|
440
|
-
|
|
441
|
-
|
|
442
354
|
@pytest.mark.parametrize(
|
|
443
355
|
"client_class,transport_name",
|
|
444
356
|
[
|
{google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/LICENSE
RENAMED
|
File without changes
|
|
File without changes
|
{google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/README.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/setup.cfg
RENAMED
|
File without changes
|
{google_cloud_privilegedaccessmanager-0.1.2 → google_cloud_privilegedaccessmanager-0.1.4}/setup.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|