Class ClientTlsPolicy

  • All Implemented Interfaces:
    ClientTlsPolicyOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

    public final class ClientTlsPolicy
    extends com.google.protobuf.GeneratedMessageV3
    implements ClientTlsPolicyOrBuilder
     ClientTlsPolicy is a resource that specifies how a client should authenticate
     connections to backends of a service. This resource itself does not affect
     configuration unless it is attached to a backend service resource.
     
    Protobuf type google.cloud.networksecurity.v1.ClientTlsPolicy
    See Also:
    Serialized Form
    • Method Detail

      • newInstance

        protected Object newInstance​(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
        Overrides:
        newInstance in class com.google.protobuf.GeneratedMessageV3
      • getDescriptor

        public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
      • internalGetMapField

        protected com.google.protobuf.MapField internalGetMapField​(int number)
        Overrides:
        internalGetMapField in class com.google.protobuf.GeneratedMessageV3
      • internalGetFieldAccessorTable

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Specified by:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
      • getName

        public String getName()
         Required. Name of the ClientTlsPolicy resource. It matches the pattern
         `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}`
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getName in interface ClientTlsPolicyOrBuilder
        Returns:
        The name.
      • getNameBytes

        public com.google.protobuf.ByteString getNameBytes()
         Required. Name of the ClientTlsPolicy resource. It matches the pattern
         `projects/*/locations/{location}/clientTlsPolicies/{client_tls_policy}`
         
        string name = 1 [(.google.api.field_behavior) = REQUIRED];
        Specified by:
        getNameBytes in interface ClientTlsPolicyOrBuilder
        Returns:
        The bytes for name.
      • getDescription

        public String getDescription()
         Optional. Free-text description of the resource.
         
        string description = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getDescription in interface ClientTlsPolicyOrBuilder
        Returns:
        The description.
      • getDescriptionBytes

        public com.google.protobuf.ByteString getDescriptionBytes()
         Optional. Free-text description of the resource.
         
        string description = 2 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getDescriptionBytes in interface ClientTlsPolicyOrBuilder
        Returns:
        The bytes for description.
      • hasCreateTime

        public boolean hasCreateTime()
         Output only. The timestamp when the resource was created.
         
        .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasCreateTime in interface ClientTlsPolicyOrBuilder
        Returns:
        Whether the createTime field is set.
      • getCreateTime

        public com.google.protobuf.Timestamp getCreateTime()
         Output only. The timestamp when the resource was created.
         
        .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTime in interface ClientTlsPolicyOrBuilder
        Returns:
        The createTime.
      • getCreateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder()
         Output only. The timestamp when the resource was created.
         
        .google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getCreateTimeOrBuilder in interface ClientTlsPolicyOrBuilder
      • hasUpdateTime

        public boolean hasUpdateTime()
         Output only. The timestamp when the resource was updated.
         
        .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        hasUpdateTime in interface ClientTlsPolicyOrBuilder
        Returns:
        Whether the updateTime field is set.
      • getUpdateTime

        public com.google.protobuf.Timestamp getUpdateTime()
         Output only. The timestamp when the resource was updated.
         
        .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTime in interface ClientTlsPolicyOrBuilder
        Returns:
        The updateTime.
      • getUpdateTimeOrBuilder

        public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder()
         Output only. The timestamp when the resource was updated.
         
        .google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
        Specified by:
        getUpdateTimeOrBuilder in interface ClientTlsPolicyOrBuilder
      • containsLabels

        public boolean containsLabels​(String key)
         Optional. Set of label tags associated with the resource.
         
        map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        containsLabels in interface ClientTlsPolicyOrBuilder
      • getLabelsMap

        public Map<String,​String> getLabelsMap()
         Optional. Set of label tags associated with the resource.
         
        map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsMap in interface ClientTlsPolicyOrBuilder
      • getLabelsOrThrow

        public String getLabelsOrThrow​(String key)
         Optional. Set of label tags associated with the resource.
         
        map<string, string> labels = 5 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getLabelsOrThrow in interface ClientTlsPolicyOrBuilder
      • getSni

        public String getSni()
         Optional. Server Name Indication string to present to the server during TLS
         handshake. E.g: "secure.example.com".
         
        string sni = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getSni in interface ClientTlsPolicyOrBuilder
        Returns:
        The sni.
      • getSniBytes

        public com.google.protobuf.ByteString getSniBytes()
         Optional. Server Name Indication string to present to the server during TLS
         handshake. E.g: "secure.example.com".
         
        string sni = 6 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getSniBytes in interface ClientTlsPolicyOrBuilder
        Returns:
        The bytes for sni.
      • hasClientCertificate

        public boolean hasClientCertificate()
         Optional. Defines a mechanism to provision client identity (public and private keys)
         for peer to peer authentication. The presence of this dictates mTLS.
         
        .google.cloud.networksecurity.v1.CertificateProvider client_certificate = 7 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        hasClientCertificate in interface ClientTlsPolicyOrBuilder
        Returns:
        Whether the clientCertificate field is set.
      • getClientCertificate

        public CertificateProvider getClientCertificate()
         Optional. Defines a mechanism to provision client identity (public and private keys)
         for peer to peer authentication. The presence of this dictates mTLS.
         
        .google.cloud.networksecurity.v1.CertificateProvider client_certificate = 7 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientCertificate in interface ClientTlsPolicyOrBuilder
        Returns:
        The clientCertificate.
      • getClientCertificateOrBuilder

        public CertificateProviderOrBuilder getClientCertificateOrBuilder()
         Optional. Defines a mechanism to provision client identity (public and private keys)
         for peer to peer authentication. The presence of this dictates mTLS.
         
        .google.cloud.networksecurity.v1.CertificateProvider client_certificate = 7 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getClientCertificateOrBuilder in interface ClientTlsPolicyOrBuilder
      • getServerValidationCaList

        public List<ValidationCA> getServerValidationCaList()
         Optional. Defines the mechanism to obtain the Certificate Authority certificate to
         validate the server certificate. If empty, client does not validate the
         server certificate.
         
        repeated .google.cloud.networksecurity.v1.ValidationCA server_validation_ca = 8 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getServerValidationCaList in interface ClientTlsPolicyOrBuilder
      • getServerValidationCaOrBuilderList

        public List<? extends ValidationCAOrBuilder> getServerValidationCaOrBuilderList()
         Optional. Defines the mechanism to obtain the Certificate Authority certificate to
         validate the server certificate. If empty, client does not validate the
         server certificate.
         
        repeated .google.cloud.networksecurity.v1.ValidationCA server_validation_ca = 8 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getServerValidationCaOrBuilderList in interface ClientTlsPolicyOrBuilder
      • getServerValidationCaCount

        public int getServerValidationCaCount()
         Optional. Defines the mechanism to obtain the Certificate Authority certificate to
         validate the server certificate. If empty, client does not validate the
         server certificate.
         
        repeated .google.cloud.networksecurity.v1.ValidationCA server_validation_ca = 8 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getServerValidationCaCount in interface ClientTlsPolicyOrBuilder
      • getServerValidationCa

        public ValidationCA getServerValidationCa​(int index)
         Optional. Defines the mechanism to obtain the Certificate Authority certificate to
         validate the server certificate. If empty, client does not validate the
         server certificate.
         
        repeated .google.cloud.networksecurity.v1.ValidationCA server_validation_ca = 8 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getServerValidationCa in interface ClientTlsPolicyOrBuilder
      • getServerValidationCaOrBuilder

        public ValidationCAOrBuilder getServerValidationCaOrBuilder​(int index)
         Optional. Defines the mechanism to obtain the Certificate Authority certificate to
         validate the server certificate. If empty, client does not validate the
         server certificate.
         
        repeated .google.cloud.networksecurity.v1.ValidationCA server_validation_ca = 8 [(.google.api.field_behavior) = OPTIONAL];
        Specified by:
        getServerValidationCaOrBuilder in interface ClientTlsPolicyOrBuilder
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessageV3
      • writeTo

        public void writeTo​(com.google.protobuf.CodedOutputStream output)
                     throws IOException
        Specified by:
        writeTo in interface com.google.protobuf.MessageLite
        Overrides:
        writeTo in class com.google.protobuf.GeneratedMessageV3
        Throws:
        IOException
      • getSerializedSize

        public int getSerializedSize()
        Specified by:
        getSerializedSize in interface com.google.protobuf.MessageLite
        Overrides:
        getSerializedSize in class com.google.protobuf.GeneratedMessageV3
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface com.google.protobuf.Message
        Overrides:
        equals in class com.google.protobuf.AbstractMessage
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface com.google.protobuf.Message
        Overrides:
        hashCode in class com.google.protobuf.AbstractMessage
      • parseFrom

        public static ClientTlsPolicy parseFrom​(ByteBuffer data)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(ByteBuffer data,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(com.google.protobuf.ByteString data)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(com.google.protobuf.ByteString data,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(byte[] data)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(byte[] data,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws com.google.protobuf.InvalidProtocolBufferException
        Throws:
        com.google.protobuf.InvalidProtocolBufferException
      • parseFrom

        public static ClientTlsPolicy parseFrom​(com.google.protobuf.CodedInputStream input,
                                                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                         throws IOException
        Throws:
        IOException
      • newBuilderForType

        public ClientTlsPolicy.Builder newBuilderForType()
        Specified by:
        newBuilderForType in interface com.google.protobuf.Message
        Specified by:
        newBuilderForType in interface com.google.protobuf.MessageLite
      • toBuilder

        public ClientTlsPolicy.Builder toBuilder()
        Specified by:
        toBuilder in interface com.google.protobuf.Message
        Specified by:
        toBuilder in interface com.google.protobuf.MessageLite
      • newBuilderForType

        protected ClientTlsPolicy.Builder newBuilderForType​(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
        Specified by:
        newBuilderForType in class com.google.protobuf.GeneratedMessageV3
      • parser

        public static com.google.protobuf.Parser<ClientTlsPolicy> parser()
      • getParserForType

        public com.google.protobuf.Parser<ClientTlsPolicy> getParserForType()
        Specified by:
        getParserForType in interface com.google.protobuf.Message
        Specified by:
        getParserForType in interface com.google.protobuf.MessageLite
        Overrides:
        getParserForType in class com.google.protobuf.GeneratedMessageV3
      • getDefaultInstanceForType

        public ClientTlsPolicy getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder