Package org.jboss.modcluster.mcmp.impl
Class JSSESocketFactory
java.lang.Object
javax.net.SocketFactory
org.jboss.modcluster.mcmp.impl.JSSESocketFactory
SSL server socket factory. It _requires_ a valid RSA key and JSSE.
- Author:
- Harish Prabandham, Costin Manolache, Stefan Freyr Stefansson, EKR -- renamed to JSSESocketFactory, Jan Luehe, Bill Barker
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateSocket(String host, int port) createSocket(String host, int port, InetAddress localAddress, int localPort) createSocket(InetAddress host, int port) createSocket(InetAddress address, int port, InetAddress localAddress, int localPort) protected Collection<? extends CRL>Load the collection of CRLs.protected KeyManager[]Gets the initialized key managers.protected CertPathParametersgetParameters(String algorithm, String crlf, KeyStore trustStore) Return the initialization parameters for the TrustManager.protected TrustManager[]Gets the initialized trust managers.protected KeyStoreGets the SSL server's truststore.Methods inherited from class javax.net.SocketFactory
getDefault
-
Constructor Details
-
JSSESocketFactory
-
-
Method Details
-
createSocket
- Overrides:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
- Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
public Socket createSocket(InetAddress address, int port, InetAddress localAddress, int localPort) throws IOException - Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
public Socket createSocket(String host, int port, InetAddress localAddress, int localPort) throws IOException - Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
createSocket
- Specified by:
createSocketin classSocketFactory- Throws:
IOException
-
getTrustStore
protected KeyStore getTrustStore() throws IOException, KeyStoreException, NoSuchProviderException, NoSuchAlgorithmException, CertificateExceptionGets the SSL server's truststore. -
getKeyManagers
Gets the initialized key managers.- Throws:
GeneralSecurityExceptionIOException
-
getTrustManagers
Gets the initialized trust managers.- Throws:
GeneralSecurityExceptionIOException
-
getParameters
protected CertPathParameters getParameters(String algorithm, String crlf, KeyStore trustStore) throws GeneralSecurityException, IOException Return the initialization parameters for the TrustManager. Currently, only the defaultPKIXis supported.- Parameters:
algorithm- The algorithm to get parameters for.crlf- The path to the CRL file.trustStore- The configured TrustStore.- Returns:
- The parameters including the CRLs and TrustStore.
- Throws:
GeneralSecurityExceptionIOException
-
getCRLs
protected Collection<? extends CRL> getCRLs(String crlf) throws FileNotFoundException, GeneralSecurityException Load the collection of CRLs.
-