netty5/handler/src/main/java/io/netty/handler/ssl
Norman Maurer f2eb106f1e Ensure we only add OpenSslEngine to the OpenSslEngineMap when handshake is started
Motivation:

We need to ensure we only add the OpenSslEngine to the OpenSslEngineMap when the handshake is started as otherwise we may produce a memory leak when the OpenSslEngine is created but not actually used. This can for example happen if we encounter a connection refused from the remote peer. In this case we will never remove the OpenSslEngine from the OpenSslEngineMap and so it will never be collected (as we hold a reference). This has as affect that the finalizer will never be run as well.

Modifications:

- Lazy add the OpenSslEngine to the OpenSslEngineMap to elimate possible leak.
- Call OpenSslEngine.shutdown() when SslHandler is removed from the ChannelPipeline to free memory asap in all cases.

Result:

No more memory leak with OpenSslEngine if connection is refused.
2016-01-05 11:26:24 +01:00
..
util Unused paramters introduced by https://github.com/netty/netty/pull/4257 2015-09-24 17:38:53 -07:00
ApplicationProtocolAccessor.java Replace SpdyOrHttpChooser and Http2OrHttpChooser with ApplicationProtocolNegotiationHandler 2015-06-05 12:01:18 +09:00
ApplicationProtocolConfig.java Add support for ALPN when using openssl + NPN client mode and support for CipherSuiteFilter 2015-04-10 18:34:09 +02:00
ApplicationProtocolNames.java Replace SpdyOrHttpChooser and Http2OrHttpChooser with ApplicationProtocolNegotiationHandler 2015-06-05 12:01:18 +09:00
ApplicationProtocolNegotiationHandler.java ApplicationProtocolNegotiationHandler failure behavior 2015-11-07 09:33:33 -08:00
ApplicationProtocolNegotiator.java ALPN should allow handshake failure if no compatible protocols found 2014-10-30 19:39:31 -04:00
ApplicationProtocolUtil.java Replace SpdyOrHttpChooser and Http2OrHttpChooser with ApplicationProtocolNegotiationHandler 2015-06-05 12:01:18 +09:00
CipherSuiteConverter.java SonarQube issues OpenSslEngine 2015-02-03 20:04:41 +01:00
CipherSuiteFilter.java Code clean-up 2014-10-31 13:01:10 +09:00
ClientAuth.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
IdentityCipherSuiteFilter.java HTTP/2 Cipher Suite Support 2014-09-11 10:19:48 -04:00
JdkAlpnApplicationProtocolNegotiator.java ALPN should allow handshake failure if no compatible protocols found 2014-10-30 19:39:31 -04:00
JdkAlpnSslEngine.java Consistent use of SSLHandshakeException for ALPN 2015-05-26 16:11:25 -07:00
JdkApplicationProtocolNegotiator.java Code clean-up 2014-10-31 13:01:10 +09:00
JdkBaseApplicationProtocolNegotiator.java Ensure server preference order in ALPN 2015-03-17 07:30:17 +01:00
JdkDefaultApplicationProtocolNegotiator.java ALPN should allow handshake failure if no compatible protocols found 2014-10-30 19:39:31 -04:00
JdkNpnApplicationProtocolNegotiator.java Eclipse SPDY docs moved 2015-08-13 09:45:22 -07:00
JdkNpnSslEngine.java The "null" ClassLoader is the bootstrap ClassLoader 2015-04-16 17:28:49 +02:00
JdkSslClientContext.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
JdkSslContext.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
JdkSslEngine.java ALPN should allow handshake failure if no compatible protocols found 2014-10-30 19:39:31 -04:00
JdkSslServerContext.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
JdkSslSession.java Improve the API design of Http2OrHttpChooser and SpdyOrHttpChooser 2015-06-05 12:00:44 +09:00
NotSslRecordException.java Add more constructors to NotSslRecordException 2012-07-10 22:26:52 +09:00
OpenSsl.java Allow to get version of available OpenSSL library 2015-04-18 20:56:37 +02:00
OpenSslApplicationProtocolNegotiator.java Add support for ALPN when using openssl + NPN client mode and support for CipherSuiteFilter 2015-04-10 18:34:09 +02:00
OpenSslClientContext.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
OpenSslContext.java Ensure we only add OpenSslEngine to the OpenSslEngineMap when handshake is started 2016-01-05 11:26:24 +01:00
OpenSslDefaultApplicationProtocolNegotiator.java Add support for ALPN when using openssl + NPN client mode and support for CipherSuiteFilter 2015-04-10 18:34:09 +02:00
OpenSslEngine.java Ensure we only add OpenSslEngine to the OpenSslEngineMap when handshake is started 2016-01-05 11:26:24 +01:00
OpenSslEngineMap.java Add supported for X509ExtendedTrustManager when using OpenSslEngine 2015-03-30 09:05:28 +02:00
OpenSslJavaxX509Certificate.java Ensure OpenSslSession informations can be retrieved even after shutdown 2015-07-07 09:50:03 +02:00
OpenSslNpnApplicationProtocolNegotiator.java Add support for ALPN when using openssl + NPN client mode and support for CipherSuiteFilter 2015-04-10 18:34:09 +02:00
OpenSslServerContext.java Throw exception if KeyManagerFactory is used with OpenSslServerContext 2015-12-17 08:02:07 +01:00
OpenSslServerSessionContext.java Allow to set the context for which sessions can be used. 2014-12-26 15:04:02 +01:00
OpenSslSessionContext.java Expose new way of setting session keys 2015-09-25 20:58:17 +02:00
OpenSslSessionStats.java Add an OpenSslEngine and the universal API for enabling SSL 2014-05-18 02:33:26 +09:00
OpenSslSessionTicketKey.java Expose new way of setting session keys 2015-09-25 20:58:17 +02:00
OpenSslX509Certificate.java Use TrustManager for certificate verification 2014-12-22 20:27:06 +01:00
package-info.java Remove apiviz tags - we are focusing on user guide instead and putting diagrams there 2013-02-14 12:09:16 -08:00
PemReader.java Fix buffer leaks during PEM to KeyStore conversion 2014-05-18 04:26:16 +09:00
SniHandler.java Overall clean-up of the initial SniHandler/DomainNameMapping work 2014-12-04 18:19:50 +09:00
SslConstants.java Added support for SSL Server Name Indication. 2014-12-03 11:07:44 +01:00
SslContext.java Remove unused method in SslContext 2015-12-10 08:59:08 +01:00
SslContextBuilder.java Adding client auth to SslContextBuilder 2015-09-18 12:17:34 -07:00
SslHandler.java Ensure we only add OpenSslEngine to the OpenSslEngineMap when handshake is started 2016-01-05 11:26:24 +01:00
SslHandshakeCompletionEvent.java Replace SpdyOrHttpChooser and Http2OrHttpChooser with ApplicationProtocolNegotiationHandler 2015-06-05 12:01:18 +09:00
SslParametersUtils.java [#3784] Support hostname verification when using OpenSSLEngine 2015-05-18 08:17:13 +02:00
SslProvider.java Add an OpenSslEngine and the universal API for enabling SSL 2014-05-18 02:33:26 +09:00
SupportedCipherSuiteFilter.java Code clean-up 2014-10-31 13:01:10 +09:00