public class SSLHandlerFactory extends Object
| Constructor and Description |
|---|
SSLHandlerFactory(SSLConfig sslConfig) |
| Modifier and Type | Method and Description |
|---|---|
SSLEngine |
addCommonConfigs(SSLEngine engine)
Add common configs for both client and server ssl engines.
|
io.netty.handler.ssl.ReferenceCountedOpenSslContext |
buildClientReferenceCountedOpenSslContext()
This used to create the open ssl context when ocsp stapling is enabled for client.
|
SSLEngine |
buildClientSSLEngine(String host,
int port)
Build ssl engine for client side.
|
SSLEngine |
buildServerSSLEngine(SSLContext sslContext)
Build the server ssl engine using the ssl context.
|
io.netty.handler.ssl.SslContext |
createHttp2TLSContextForClient(boolean enableOcsp) |
io.netty.handler.ssl.SslContext |
createHttp2TLSContextForServer(SSLConfig sslConfig)
This method will provide netty ssl context which supports HTTP2 over TLS using
Application Layer Protocol Negotiation (ALPN)
|
io.netty.handler.ssl.SslContext |
createHttpTLSContextForClient()
This method will provide netty ssl context which supports HTTP over TLS using certificates and keys.
|
io.netty.handler.ssl.SslContext |
createHttpTLSContextForServer()
This method will provide netty ssl context which supports HTTP over TLS using.
|
SSLContext |
createSSLContextFromKeystores(boolean isServer)
This is uset to create the sslContext from keystores.
|
io.netty.handler.ssl.ReferenceCountedOpenSslContext |
getServerReferenceCountedOpenSslContext(boolean enableOcsp)
This used to create the open ssl context when ocsp stapling is enabled for server.
|
void |
setHostNameVerfication(SSLEngine sslEngine) |
void |
setSNIServerNames(SSLEngine sslEngine,
String peerHost) |
public SSLHandlerFactory(SSLConfig sslConfig)
public SSLContext createSSLContextFromKeystores(boolean isServer)
isServer - identifies whether the server or the client has called this method.public SSLEngine buildServerSSLEngine(SSLContext sslContext)
sslContext - sslContext.public io.netty.handler.ssl.ReferenceCountedOpenSslContext getServerReferenceCountedOpenSslContext(boolean enableOcsp)
throws SSLException
enableOcsp - true/false for enabling ocsp stapling.SSLException - if any error occurs while creating the ReferenceCountedOpenSslContext.public io.netty.handler.ssl.ReferenceCountedOpenSslContext buildClientReferenceCountedOpenSslContext()
throws SSLException
SSLException - if any error occurs while creating the ReferenceCountedOpenSslContext.public SSLEngine buildClientSSLEngine(String host, int port)
host - peer hostport - peer portpublic SSLEngine addCommonConfigs(SSLEngine engine)
engine - client/server ssl engine.public io.netty.handler.ssl.SslContext createHttp2TLSContextForServer(SSLConfig sslConfig) throws SSLException
sslConfig - ssl configurationsSslContextSSLException - if any error occurred during building SSL context.public io.netty.handler.ssl.SslContext createHttpTLSContextForServer()
throws SSLException
SslContextSSLException - if any error occurred during building SSL context.public io.netty.handler.ssl.SslContext createHttpTLSContextForClient()
throws SSLException
SslContextSSLException - if any error occurred during building SSL context.public io.netty.handler.ssl.SslContext createHttp2TLSContextForClient(boolean enableOcsp)
throws SSLException
SSLExceptionpublic void setHostNameVerfication(SSLEngine sslEngine)
Copyright © 2021 WSO2. All rights reserved.