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

Negotiate highest available SSL/TLS version #230

Merged
merged 1 commit into from
Mar 9, 2016

Conversation

eworm-de
Copy link
Contributor

@eworm-de eworm-de commented Mar 9, 2016

When encrypting the connection with STARTTLS the only method
allowed was TLSv1. Change this to allow TLSv1.2 (or whatever the
strongest method is).

Additionally tls_data_new() and ssl_data_new() did the same (with
exception to the nailed method in tls_data_new()), so drop one
of them.

fixes #226

When encrypting the connection with STARTTLS the only method
allowed was TLSv1. Change this to allow TLSv1.2 (or whatever the
strongest method is).

Additionally tls_data_new() and ssl_data_new() did the same (with
exception to the nailed method in tls_data_new()), so drop one
of them.
#if (OPENSSL_VERSION_NUMBER >= 0x10100000L)
TLS_client_method(),
#else
/* Despite their name the SSLv23_*method() functions have nothing to do
Copy link
Owner

Choose a reason for hiding this comment

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

Is it also the behavior with OpenSSL < 1.1?
It would be great :)

@eworm-de
Copy link
Contributor Author

eworm-de commented Mar 9, 2016

OpenSSL >= 1.1.0 (which has not been released yet) has TLS_client_method(), OpenSSL < 1.1.0 (current stable and every legacy version) has SSLv23_client_method().

Both do the same, negotiate highest available SSL/TLS version. That is in order:

TLSv1.2
TLSv1.1
TLSv1.0
SSLv3
SSLv2

dinhvh added a commit that referenced this pull request Mar 9, 2016
Negotiate highest available SSL/TLS version
@dinhvh dinhvh merged commit f1b7dfb into dinhvh:master Mar 9, 2016
@dinhvh
Copy link
Owner

dinhvh commented Mar 9, 2016

Thanks a lot!

@eworm-de eworm-de deleted the openssl-method branch March 9, 2016 23:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fallback to TLSv1
2 participants