Interface SSLContext
- All Known Implementing Classes:
OpenSSLContext
public interface SSLContext
This interface is needed to override the default SSLContext class to allow SSL implementation pluggability without
having to use JCE. With regular JSSE it will do nothing but delegate to the SSLContext.
-
Method Summary
Modifier and TypeMethodDescriptionCreates a new SSL engine.voiddestroy()Destroys this SSL context and releases any associated resources.Returns the accepted issuers.getCertificateChain(String alias) Returns the certificate chain for the given alias.Returns the server session context.Returns the server socket factory.Returns the supported SSL parameters.voidinit(KeyManager[] kms, TrustManager[] tms, SecureRandom sr) Initializes the SSL context with the given key managers, trust managers, and random number generator.
-
Method Details
-
init
Initializes the SSL context with the given key managers, trust managers, and random number generator.- Parameters:
kms- The key managerstms- The trust managerssr- The secure random number generator- Throws:
KeyManagementException- if initialization fails
-
destroy
void destroy()Destroys this SSL context and releases any associated resources. -
getServerSessionContext
SSLSessionContext getServerSessionContext()Returns the server session context.- Returns:
- The server session context
-
createSSLEngine
-
getServerSocketFactory
SSLServerSocketFactory getServerSocketFactory()Returns the server socket factory.- Returns:
- The server socket factory
-
getSupportedSSLParameters
SSLParameters getSupportedSSLParameters()Returns the supported SSL parameters.- Returns:
- The supported SSL parameters
-
getCertificateChain
Returns the certificate chain for the given alias.- Parameters:
alias- The alias- Returns:
- The certificate chain
-
getAcceptedIssuers
-