Skip to content
This repository was archived by the owner on Jul 6, 2023. It is now read-only.

Commit 13e54bf

Browse files
fix: make allow_config_based_issuance bool optional (#80)
PiperOrigin-RevId: 385011540 Source-Link: googleapis/googleapis@077f0c6 Source-Link: https://github.com/googleapis/googleapis-gen/commit/5427a56f87b7f1f69c4e0952de64836225920517 fix: make publish_ca_cert bool optional fix: make publish_crl bool optional fix: make allow_csr_based_issuance bool optional fix: correct response type of DeleteCaPool
1 parent 485cad8 commit 13e54bf

File tree

3 files changed

+42
-36
lines changed

3 files changed

+42
-36
lines changed

google/cloud/security/privateca_v1/services/certificate_authority_service/async_client.py

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1933,15 +1933,19 @@ async def delete_ca_pool(
19331933
google.api_core.operation_async.AsyncOperation:
19341934
An object representing a long-running operation.
19351935
1936-
The result type for the operation will be :class:`google.cloud.security.privateca_v1.types.CaPool` A [CaPool][google.cloud.security.privateca.v1.CaPool] represents a group of
1937-
[CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]
1938-
that form a trust anchor. A
1939-
[CaPool][google.cloud.security.privateca.v1.CaPool]
1940-
can be used to manage issuance policies for one or
1941-
more
1942-
[CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]
1943-
resources and to rotate CA certificates in and out of
1944-
the trust anchor.
1936+
The result type for the operation will be :class:`google.protobuf.empty_pb2.Empty` A generic empty message that you can re-use to avoid defining duplicated
1937+
empty messages in your APIs. A typical example is to
1938+
use it as the request or the response type of an API
1939+
method. For instance:
1940+
1941+
service Foo {
1942+
rpc Bar(google.protobuf.Empty) returns
1943+
(google.protobuf.Empty);
1944+
1945+
}
1946+
1947+
The JSON representation for Empty is empty JSON
1948+
object {}.
19451949
19461950
"""
19471951
# Create or coerce a protobuf request object.
@@ -1982,7 +1986,7 @@ async def delete_ca_pool(
19821986
response = operation_async.from_gapic(
19831987
response,
19841988
self._client._transport.operations_client,
1985-
resources.CaPool,
1989+
empty_pb2.Empty,
19861990
metadata_type=service.OperationMetadata,
19871991
)
19881992

google/cloud/security/privateca_v1/services/certificate_authority_service/client.py

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2201,15 +2201,19 @@ def delete_ca_pool(
22012201
google.api_core.operation.Operation:
22022202
An object representing a long-running operation.
22032203
2204-
The result type for the operation will be :class:`google.cloud.security.privateca_v1.types.CaPool` A [CaPool][google.cloud.security.privateca.v1.CaPool] represents a group of
2205-
[CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]
2206-
that form a trust anchor. A
2207-
[CaPool][google.cloud.security.privateca.v1.CaPool]
2208-
can be used to manage issuance policies for one or
2209-
more
2210-
[CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]
2211-
resources and to rotate CA certificates in and out of
2212-
the trust anchor.
2204+
The result type for the operation will be :class:`google.protobuf.empty_pb2.Empty` A generic empty message that you can re-use to avoid defining duplicated
2205+
empty messages in your APIs. A typical example is to
2206+
use it as the request or the response type of an API
2207+
method. For instance:
2208+
2209+
service Foo {
2210+
rpc Bar(google.protobuf.Empty) returns
2211+
(google.protobuf.Empty);
2212+
2213+
}
2214+
2215+
The JSON representation for Empty is empty JSON
2216+
object {}.
22132217
22142218
"""
22152219
# Create or coerce a protobuf request object.
@@ -2250,7 +2254,7 @@ def delete_ca_pool(
22502254
response = operation.from_gapic(
22512255
response,
22522256
self._transport.operations_client,
2253-
resources.CaPool,
2257+
empty_pb2.Empty,
22542258
metadata_type=service.OperationMetadata,
22552259
)
22562260

google/cloud/security/privateca_v1/types/resources.py

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ class PublishingOptions(proto.Message):
363363
364364
Attributes:
365365
publish_ca_cert (bool):
366-
Required. When true, publishes each
366+
Optional. When true, publishes each
367367
[CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s
368368
CA certificate and includes its URL in the "Authority
369369
Information Access" X.509 extension in all issued
@@ -372,7 +372,7 @@ class PublishingOptions(proto.Message):
372372
and the corresponding X.509 extension will not be written in
373373
issued certificates.
374374
publish_crl (bool):
375-
Required. When true, publishes each
375+
Optional. When true, publishes each
376376
[CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s
377377
CRL and includes its URL in the "CRL Distribution Points"
378378
X.509 extension in all issued
@@ -544,11 +544,11 @@ class IssuanceModes(proto.Message):
544544
545545
Attributes:
546546
allow_csr_based_issuance (bool):
547-
Required. When true, allows callers to create
547+
Optional. When true, allows callers to create
548548
[Certificates][google.cloud.security.privateca.v1.Certificate]
549549
by specifying a CSR.
550550
allow_config_based_issuance (bool):
551-
Required. When true, allows callers to create
551+
Optional. When true, allows callers to create
552552
[Certificates][google.cloud.security.privateca.v1.Certificate]
553553
by specifying a
554554
[CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig].
@@ -1101,14 +1101,16 @@ class SubjectDescription(proto.Message):
11011101
The serial number encoded in lowercase
11021102
hexadecimal.
11031103
lifetime (google.protobuf.duration_pb2.Duration):
1104-
For convenience, the actual lifetime of an issued
1105-
certificate. Corresponds to 'not_after_time' -
1106-
'not_before_time'.
1104+
For convenience, the actual lifetime of an
1105+
issued certificate.
11071106
not_before_time (google.protobuf.timestamp_pb2.Timestamp):
11081107
The time at which the certificate becomes
11091108
valid.
11101109
not_after_time (google.protobuf.timestamp_pb2.Timestamp):
1111-
The time at which the certificate expires.
1110+
The time after which the certificate is expired. Per RFC
1111+
5280, the validity period for a certificate is the period of
1112+
time from not_before_time through not_after_time, inclusive.
1113+
Corresponds to 'not_before_time' + 'lifetime' - 1 second.
11121114
"""
11131115

11141116
subject = proto.Field(proto.MESSAGE, number=1, message="Subject",)
@@ -1184,7 +1186,7 @@ class X509Extension(proto.Message):
11841186
object_id (google.cloud.security.privateca_v1.types.ObjectId):
11851187
Required. The OID for this X.509 extension.
11861188
critical (bool):
1187-
Required. Indicates whether or not this
1189+
Optional. Indicates whether or not this
11881190
extension is critical (i.e., if the client does
11891191
not know how to handle this extension, the
11901192
client should consider this to be an error).
@@ -1383,25 +1385,21 @@ class CertificateIdentityConstraints(proto.Message):
13831385
signed. To see the full allowed syntax and some
13841386
examples, see
13851387
https://cloud.google.com/certificate-authority-
1386-
service/docs/cel-guide
1388+
service/docs/using-cel
13871389
allow_subject_passthrough (bool):
13881390
Required. If this is true, the
13891391
[Subject][google.cloud.security.privateca.v1.Subject] field
13901392
may be copied from a certificate request into the signed
13911393
certificate. Otherwise, the requested
13921394
[Subject][google.cloud.security.privateca.v1.Subject] will
1393-
be discarded. The bool is optional to indicate an unset
1394-
field, which suggests a forgotten value that needs to be set
1395-
by the caller.
1395+
be discarded.
13961396
allow_subject_alt_names_passthrough (bool):
13971397
Required. If this is true, the
13981398
[SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames]
13991399
extension may be copied from a certificate request into the
14001400
signed certificate. Otherwise, the requested
14011401
[SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames]
1402-
will be discarded. The bool is optional to indicate an unset
1403-
field, which suggests a forgotten value that needs to be set
1404-
by the caller.
1402+
will be discarded.
14051403
"""
14061404

14071405
cel_expression = proto.Field(proto.MESSAGE, number=1, message=expr_pb2.Expr,)

0 commit comments

Comments
 (0)