Navigation Menu

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ensure OpenSslSession informations can be retrieved even after shutdown #3934

Closed
wants to merge 1 commit into from

Conversation

normanmaurer
Copy link
Member

Motivation:

If a user tries to access various informations on the OpenSslSession after the SSLEngine was closed it will not work if these were not accessed before as we lazy init most of them.

Modifications:

Directly populate the whole OpenSslSession once the handshake is complete and before the user is notified about it.

Result:

OpenSslSession informations are avaible until it is GC'ed.

Motivation:

If a user tries to access various informations on the OpenSslSession after the SSLEngine was closed it will not work if these were not accessed before as we lazy init most of them.

Modifications:

Directly populate the whole OpenSslSession once the handshake is complete and before the user is notified about it.

Result:

OpenSslSession informations are avaible until it is GC'ed.
@normanmaurer
Copy link
Member Author

@trustin please check

@normanmaurer normanmaurer self-assigned this Jul 3, 2015
@normanmaurer normanmaurer added this to the 4.0.30.Final milestone Jul 3, 2015
import java.security.SignatureException;
import java.util.Date;

final class OpenSslJavaxX509Certificate extends X509Certificate {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe it's enough to name this class as OpenSslX509Certificate?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@trustin we already have OpenSslX509Certificate for java.security.X509Certificate impl :/

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hah, nevermind, then. :-)

@trustin
Copy link
Member

trustin commented Jul 7, 2015

LGTM :-)

@normanmaurer
Copy link
Member Author

Cherry-picked into 4.0 (95b7de3), 4.1 (0f95b85) and master (ac1bb12)

@normanmaurer normanmaurer deleted the not_lazy_ssl_session branch July 7, 2015 08:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants