com.ca.commons.security.ssl
Class CustomSSLSocketFactory
java.lang.Object
javax.net.SocketFactory
javax.net.ssl.SSLSocketFactory
com.ca.commons.security.ssl.CustomSSLSocketFactory
- Direct Known Subclasses:
- CustomNoTrustCheckSSLSocketFactory
public class CustomSSLSocketFactory
- extends SSLSocketFactory
|
Method Summary |
Socket |
createSocket()
|
Socket |
createSocket(InetAddress host,
int port)
|
Socket |
createSocket(InetAddress address,
int port,
InetAddress localAddress,
int localPort)
|
Socket |
createSocket(Socket socket,
String host,
int port,
boolean autoClose)
|
Socket |
createSocket(String host,
int port)
|
Socket |
createSocket(String host,
int port,
InetAddress localHost,
int localPort)
|
static SocketFactory |
getDefault()
|
String[] |
getDefaultCipherSuites()
|
String[] |
getDefaultProtocols()
|
String[] |
getSupportedCipherSuites()
|
static String[] |
getSupportedProtocols()
|
static void |
initCAKeyStore(InputStream in,
String type,
char[] pwd)
|
static void |
initClientCertKeyStore(InputStream in,
String type,
char[] pwd)
|
static void |
setTraceCerts(boolean traceCerts)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
public static final Logger logger
CustomSSLSocketFactory
protected CustomSSLSocketFactory(SSLSocketFactory factory)
initCAKeyStore
public static void initCAKeyStore(InputStream in,
String type,
char[] pwd)
throws GeneralSecurityException,
IOException
- Throws:
GeneralSecurityException
IOException
initClientCertKeyStore
public static void initClientCertKeyStore(InputStream in,
String type,
char[] pwd)
throws GeneralSecurityException,
IOException
- Throws:
GeneralSecurityException
IOException
getDefault
public static SocketFactory getDefault()
createSocket
public Socket createSocket()
throws IOException
- Overrides:
createSocket in class SocketFactory
- Throws:
IOException
createSocket
public Socket createSocket(String host,
int port)
throws IOException
- Specified by:
createSocket in class SocketFactory
- Throws:
IOException
createSocket
public Socket createSocket(String host,
int port,
InetAddress localHost,
int localPort)
throws IOException
- Specified by:
createSocket in class SocketFactory
- Throws:
IOException
createSocket
public Socket createSocket(InetAddress host,
int port)
throws IOException
- Specified by:
createSocket in class SocketFactory
- Throws:
IOException
createSocket
public Socket createSocket(InetAddress address,
int port,
InetAddress localAddress,
int localPort)
throws IOException
- Specified by:
createSocket in class SocketFactory
- Throws:
IOException
createSocket
public Socket createSocket(Socket socket,
String host,
int port,
boolean autoClose)
throws IOException
- Specified by:
createSocket in class SSLSocketFactory
- Throws:
IOException
getDefaultCipherSuites
public String[] getDefaultCipherSuites()
- Specified by:
getDefaultCipherSuites in class SSLSocketFactory
getSupportedCipherSuites
public String[] getSupportedCipherSuites()
- Specified by:
getSupportedCipherSuites in class SSLSocketFactory
getDefaultProtocols
public String[] getDefaultProtocols()
getSupportedProtocols
public static String[] getSupportedProtocols()
setTraceCerts
public static void setTraceCerts(boolean traceCerts)
Created 2011-07-14 13:27 EST