|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.opends.server.tools.SSLConnectionFactory
public class SSLConnectionFactory
This class provides SSL connection related utility functions.
| Constructor Summary | |
|---|---|
SSLConnectionFactory()
Constructor for the SSL connection factory. |
|
| Method Summary | |
|---|---|
java.net.Socket |
createSocket(java.net.Socket s,
java.lang.String hostName,
int portNumber,
boolean autoClose)
Create the SSL socket connection to the specified host layered over an existing socket. |
java.net.Socket |
createSocket(java.lang.String hostName,
int portNumber)
Create the SSL socket connection to the specified host. |
void |
init(boolean trustAll,
java.lang.String keyStorePath,
java.lang.String keyStorePassword,
java.lang.String clientAlias,
java.lang.String trustStorePath,
java.lang.String trustStorePassword)
Initialize the connection factory by creating the key and trust managers for the SSL connection. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SSLConnectionFactory()
| Method Detail |
|---|
public void init(boolean trustAll,
java.lang.String keyStorePath,
java.lang.String keyStorePassword,
java.lang.String clientAlias,
java.lang.String trustStorePath,
java.lang.String trustStorePassword)
throws SSLConnectionException
trustAll - Indicates whether to blindly trust all
certificates.keyStorePath - The path to the key store file.keyStorePassword - The PIN to use to access the key store
contents.clientAlias - The alias to use for the client certificate.trustStorePath - The path to the trust store file.trustStorePassword - The PIN to use to access the trust store
contents.
SSLConnectionException - If a problem occurs while initializing the
connection factory.
public java.net.Socket createSocket(java.lang.String hostName,
int portNumber)
throws SSLConnectionException,
java.io.IOException
hostName - The address of the system to which the connection
should be established.portNumber - The port number to which the connection should be
established.
SSLConnectionException - If a problem occurs while performing SSL
negotiation.
java.io.IOException - If a problem occurs while attempting to communicate
with the server.
public java.net.Socket createSocket(java.net.Socket s,
java.lang.String hostName,
int portNumber,
boolean autoClose)
throws SSLConnectionException,
java.io.IOException
s - The socket to use for the existing connection.hostName - The address of the system to which the connection
should be established.portNumber - The port number to which the connection should be
established.autoClose - Indicates whether the underlying connection should be
automatically closed when the SSL session is ended.
SSLConnectionException - If a problem occurs while performing SSL
negotiation.
java.io.IOException - If a problem occurs while attempting to communicate
with the server.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||