Enabling SSL connections with jConnect
Use the ENABLE_SSL connection property to enable an SSL client connection through jConnect.
To connect your client application to the SSL ASE server:
- Add an authorized certificate to the client’s JVM keystore:
- When you setup the SSL ASE server, the certificates and other files are generated at the following location:
- For Linux: $SYBASE/$SYBASE_ASE/certificates/servername.txt
- For Windows: %SYBASE%\%SYBASE_ASE%\certificates\servername.txt
Copy the certificate file (servername.txt) and paste it at the client’s shared location.
ii. After the certificate is copied to the client’s location, import the certificate into the client’s JVM using the keytool utility provided by Java:
- On the client side, execute the command as: %JAVA_HOME%\jre\bin\keytool -import -trustcacerts -file <absolute path of servername.txt> -alias root -keystore %JAVA_HOME%\jre\lib\security\cacerts
- Next, enter the keystore password.
- The keytool command displays the certificate information and asks you to verify the information. Type yes to indicate that you trust the certificate.
The certificate is added to the keystore.
2. In the application/ client program, set the connection property ENABLE_SSL=TRUE and execute the application/client program.
The client application now communicates via the SSL ASE server.