public class LdapSocketFactory
extends javax.net.SocketFactory
Modifier and Type | Field and Description |
---|---|
private static javax.net.ssl.SSLSocketFactory |
factory
Actual implementation of the factory
|
Constructor and Description |
---|
LdapSocketFactory() |
Modifier and Type | Method and Description |
---|---|
java.net.Socket |
createSocket(java.net.InetAddress arg0,
int arg1) |
java.net.Socket |
createSocket(java.net.InetAddress arg0,
int arg1,
java.net.InetAddress arg2,
int arg3) |
java.net.Socket |
createSocket(java.lang.String arg0,
int arg1) |
java.net.Socket |
createSocket(java.lang.String arg0,
int arg1,
java.net.InetAddress arg2,
int arg3) |
static javax.net.SocketFactory |
getDefault()
Return an instance of the LdapSocketFactory for use by client.
|
(package private) static void |
initSocketFactory(java.lang.String keyFile,
java.lang.String keyPass,
java.lang.String trustFile,
java.lang.String trustPass,
java.lang.String subjectAlias,
java.lang.String aliasPass)
Construct an instance of socket factory which will used keys from the
provided password encrypted file.
|
private static javax.net.ssl.SSLSocketFactory factory
static void initSocketFactory(java.lang.String keyFile, java.lang.String keyPass, java.lang.String trustFile, java.lang.String trustPass, java.lang.String subjectAlias, java.lang.String aliasPass) throws ConfigurationException
The approach of handling stores and certificates is taken from
TransportSecurity
class.
keyFile
- File name for the keystore.keyPass
- Password for keystore.trustFile
- File name for truststore.trustPass
- Password for truststore.subjectAlias
- Alias of the certificate to use.aliasPass
- Password for the certificate.ConfigurationException
- In case of problems accessing required data.public static javax.net.SocketFactory getDefault()
public java.net.Socket createSocket(java.lang.String arg0, int arg1) throws java.io.IOException, java.net.UnknownHostException
createSocket
in class javax.net.SocketFactory
java.io.IOException
java.net.UnknownHostException
public java.net.Socket createSocket(java.net.InetAddress arg0, int arg1) throws java.io.IOException
createSocket
in class javax.net.SocketFactory
java.io.IOException
public java.net.Socket createSocket(java.lang.String arg0, int arg1, java.net.InetAddress arg2, int arg3) throws java.io.IOException, java.net.UnknownHostException
createSocket
in class javax.net.SocketFactory
java.io.IOException
java.net.UnknownHostException
public java.net.Socket createSocket(java.net.InetAddress arg0, int arg1, java.net.InetAddress arg2, int arg3) throws java.io.IOException
createSocket
in class javax.net.SocketFactory
java.io.IOException