Configuring SSL Connections

Note:

In this documentation, "SSL" indicates both TLS (Transport Layer Security) and SSL (Secure Sockets Layer). The connector supports industry-standard versions of TLS/SSL.

If you are connecting to a MongoDB server that has SSL enabled, you can configure the connector to connect to an SSL-enabled socket. When connecting to a server over SSL, the connector supports one-way authentication (the connector verifies the identity of the server).

Configuring One-Way SSL Authentication

You can configure one-way SSL authentication so that the connector verifies the identity of the MongoDB server. Before configuring the connector, you must create a TrustStore that contains a signed, trusted SSL certificate for verifying the identity of the server.

You provide the configuration information to the connector in the connection URL. For more information about the syntax of the connection URL, see Building the Connection URL.

To configure one-way SSL verification:

  1. Set the SSL property to true.
  2. Configure the connector to access your TrustStore:
    1. Set the sslTrustStore property to the full path of the TrustStore.
    2. Set the sslTrustStorePwd property to your password for accessing the TrustStore.

For example:

jdbc:mongodb://jsmith:pass12345@localhost:18000/TeamRoster?
SSL=true&sslTrustStore=C:\\Documents\\MongoDB_certs.jks&
sslTrustStorePwd=simba123