ValidateServerCertificate
- Last Updated: February 19, 2024
- 1 minute read
- DataDirect Connectors
- JDBC
- Microsoft SQL Server 6.0
- Documentation
Purpose
Determines whether the driver validates the
certificate that is sent by the database server when SSL encryption is enabled (EncryptionMethod=SSL). When using SSL server
authentication, any certificate that is sent by the server must be issued by a trusted
Certificate Authority (CA).
Allowing the driver to trust any certificate that is returned from the server even if the issuer is not a trusted CA is useful in test environments because it eliminates the need to specify truststore information on each client in the test environment.
Valid values
true | false
Behavior
If set to true, the driver validates the certificate that is sent by the
database server. Any certificate from the server must be issued by a trusted CA in the
truststore file. If the HostNameInCertificate property is specified, the driver also
validates the certificate using a host name. The HostNameInCertificate property is optional
and provides additional security against man-in-the-middle (MITM) attacks by ensuring that
the server the driver is connecting to is the server that was requested.
If set to false, the driver does not validate the certificate that is sent
by the database server. The driver ignores any truststore information that is specified by
the TrustStore and TrustStorePassword properties or Java system properties.
Notes
- This property is ignored when EncryptionMethod=Strict. The driver always validates the server certificate when using strict connection encryption.
- Truststore information is specified using the TrustStore and TrustStorePassword properties or by using Java system properties.
Data source method
public Boolean
getValidateServerCertificate()
public void
setValidateServerCertificate(Boolean)
Default
true
Data type
Boolean