Class PostgresqlSslConfig.ServerAndClientVerification.Builder (1.82.0)

public static final class PostgresqlSslConfig.ServerAndClientVerification.Builder extends GeneratedMessage.Builder<PostgresqlSslConfig.ServerAndClientVerification.Builder> implements PostgresqlSslConfig.ServerAndClientVerificationOrBuilder

Message represents the option where Datastream will enforce the encryption and authenticate the server identity as well as the client identity. ca_certificate, client_certificate and client_key must be set if user selects this option.

Protobuf type google.cloud.datastream.v1.PostgresqlSslConfig.ServerAndClientVerification

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public PostgresqlSslConfig.ServerAndClientVerification build()
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification

buildPartial()

public PostgresqlSslConfig.ServerAndClientVerification buildPartial()
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification

clear()

public PostgresqlSslConfig.ServerAndClientVerification.Builder clear()
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder
Overrides

clearCaCertificate()

public PostgresqlSslConfig.ServerAndClientVerification.Builder clearCaCertificate()

Required. Input only. PEM-encoded server root CA certificate.

string ca_certificate = 3 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

clearClientCertificate()

public PostgresqlSslConfig.ServerAndClientVerification.Builder clearClientCertificate()

Required. Input only. PEM-encoded certificate used by the source database to authenticate the client identity (i.e., the Datastream's identity). This certificate is signed by either a root certificate trusted by the server or one or more intermediate certificates (which is stored with the leaf certificate) to link the this certificate to the trusted root certificate.

string client_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

clearClientKey()

public PostgresqlSslConfig.ServerAndClientVerification.Builder clearClientKey()

Optional. Input only. PEM-encoded private key associated with the client certificate. This value will be used during the SSL/TLS handshake, allowing the PostgreSQL server to authenticate the client's identity, i.e. identity of the Datastream.

string client_key = 2 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

clearServerCertificateHostname()

public PostgresqlSslConfig.ServerAndClientVerification.Builder clearServerCertificateHostname()

Optional. The hostname mentioned in the Subject or SAN extension of the server certificate. If this field is not provided, the hostname in the server certificate is not validated.

string server_certificate_hostname = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

getCaCertificate()

public String getCaCertificate()

Required. Input only. PEM-encoded server root CA certificate.

string ca_certificate = 3 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The caCertificate.

getCaCertificateBytes()

public ByteString getCaCertificateBytes()

Required. Input only. PEM-encoded server root CA certificate.

string ca_certificate = 3 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for caCertificate.

getClientCertificate()

public String getClientCertificate()

Required. Input only. PEM-encoded certificate used by the source database to authenticate the client identity (i.e., the Datastream's identity). This certificate is signed by either a root certificate trusted by the server or one or more intermediate certificates (which is stored with the leaf certificate) to link the this certificate to the trusted root certificate.

string client_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The clientCertificate.

getClientCertificateBytes()

public ByteString getClientCertificateBytes()

Required. Input only. PEM-encoded certificate used by the source database to authenticate the client identity (i.e., the Datastream's identity). This certificate is signed by either a root certificate trusted by the server or one or more intermediate certificates (which is stored with the leaf certificate) to link the this certificate to the trusted root certificate.

string client_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for clientCertificate.

getClientKey()

public String getClientKey()

Optional. Input only. PEM-encoded private key associated with the client certificate. This value will be used during the SSL/TLS handshake, allowing the PostgreSQL server to authenticate the client's identity, i.e. identity of the Datastream.

string client_key = 2 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The clientKey.

getClientKeyBytes()

public ByteString getClientKeyBytes()

Optional. Input only. PEM-encoded private key associated with the client certificate. This value will be used during the SSL/TLS handshake, allowing the PostgreSQL server to authenticate the client's identity, i.e. identity of the Datastream.

string client_key = 2 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for clientKey.

getDefaultInstanceForType()

public PostgresqlSslConfig.ServerAndClientVerification getDefaultInstanceForType()
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getServerCertificateHostname()

public String getServerCertificateHostname()

Optional. The hostname mentioned in the Subject or SAN extension of the server certificate. If this field is not provided, the hostname in the server certificate is not validated.

string server_certificate_hostname = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The serverCertificateHostname.

getServerCertificateHostnameBytes()

public ByteString getServerCertificateHostnameBytes()

Optional. The hostname mentioned in the Subject or SAN extension of the server certificate. If this field is not provided, the hostname in the server certificate is not validated.

string server_certificate_hostname = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for serverCertificateHostname.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(PostgresqlSslConfig.ServerAndClientVerification other)

public PostgresqlSslConfig.ServerAndClientVerification.Builder mergeFrom(PostgresqlSslConfig.ServerAndClientVerification other)
Parameter
Name Description
other PostgresqlSslConfig.ServerAndClientVerification
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public PostgresqlSslConfig.ServerAndClientVerification.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public PostgresqlSslConfig.ServerAndClientVerification.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder
Overrides

setCaCertificate(String value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setCaCertificate(String value)

Required. Input only. PEM-encoded server root CA certificate.

string ca_certificate = 3 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The caCertificate to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setCaCertificateBytes(ByteString value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setCaCertificateBytes(ByteString value)

Required. Input only. PEM-encoded server root CA certificate.

string ca_certificate = 3 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for caCertificate to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setClientCertificate(String value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setClientCertificate(String value)

Required. Input only. PEM-encoded certificate used by the source database to authenticate the client identity (i.e., the Datastream's identity). This certificate is signed by either a root certificate trusted by the server or one or more intermediate certificates (which is stored with the leaf certificate) to link the this certificate to the trusted root certificate.

string client_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The clientCertificate to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setClientCertificateBytes(ByteString value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setClientCertificateBytes(ByteString value)

Required. Input only. PEM-encoded certificate used by the source database to authenticate the client identity (i.e., the Datastream's identity). This certificate is signed by either a root certificate trusted by the server or one or more intermediate certificates (which is stored with the leaf certificate) to link the this certificate to the trusted root certificate.

string client_certificate = 1 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for clientCertificate to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setClientKey(String value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setClientKey(String value)

Optional. Input only. PEM-encoded private key associated with the client certificate. This value will be used during the SSL/TLS handshake, allowing the PostgreSQL server to authenticate the client's identity, i.e. identity of the Datastream.

string client_key = 2 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The clientKey to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setClientKeyBytes(ByteString value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setClientKeyBytes(ByteString value)

Optional. Input only. PEM-encoded private key associated with the client certificate. This value will be used during the SSL/TLS handshake, allowing the PostgreSQL server to authenticate the client's identity, i.e. identity of the Datastream.

string client_key = 2 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for clientKey to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setServerCertificateHostname(String value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setServerCertificateHostname(String value)

Optional. The hostname mentioned in the Subject or SAN extension of the server certificate. If this field is not provided, the hostname in the server certificate is not validated.

string server_certificate_hostname = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The serverCertificateHostname to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.

setServerCertificateHostnameBytes(ByteString value)

public PostgresqlSslConfig.ServerAndClientVerification.Builder setServerCertificateHostnameBytes(ByteString value)

Optional. The hostname mentioned in the Subject or SAN extension of the server certificate. If this field is not provided, the hostname in the server certificate is not validated.

string server_certificate_hostname = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for serverCertificateHostname to set.

Returns
Type Description
PostgresqlSslConfig.ServerAndClientVerification.Builder

This builder for chaining.