To use SSL sockets in versions of jConnect earlier than 15.7 SP 100, you had to
create an implementation of SybSocketFactory interface and use it by
setting the SYBSOCKET_FACTORY connection property.
In version 15.7 SP100, jConnect has built-in support to connect to Adaptive Server using
SSL sockets. The new connection property
ENABLE_SSL when set to:
- false – (the default) jConnect will not use SSL sockets.
- true – jConnect uses SSL sockets and the target Adaptive Server must be
enabled for SSL socket connections.
Note: Sybase recommends that you set the login timeout using
DriverManager.setLoginTimeout property to allow the
connection to timeout when attempting SSL connection on a non SSL enabled Adaptive
Server.
The SSL socket feature depends on the following standard Java properties:
- javax.net.ssl.keyStore
- javax.net.ssl.keyStorePassword
- javax.net.ssl.trustStore
- javax.net.ssl.trustStorePassword
- javax.net.ssl.trustStore
- javax.net.ssl.trustStoreType
See the Java J2SE 6 Documentation for more information on Java standard
properties.