-
-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
Problem setting option CURLOPT_SSLVERSION to a range #2225
Comments
I've submitted #2227 to address the issue you reported. Can you test it please? The way those MAX values are used needs to be better documented to explain that only one MAX and one regular value can be OR'd together (if I understand it right). Otherwise in my opinion it can lead to user error. /cc @jkralik |
That change works for me. Thank you. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I am trying to use curl_easy_setopt to specify TLS 1.1 or higher. If I do the following (from the documentation):
result = curl_easy_setopt( curl, CURLOPT_SSLVERSION, CURL_SSLVERSION_TLSv1_1 | CURL_SSLVERSION_MAX_DEFAULT );
I always get CURLE_BAD_FUNCTION_ARGUMENT. Even if I try any of the other max values.
Looking at setopt, I see the validation is using:
if((arg < CURL_SSLVERSION_DEFAULT) || (arg > CURL_SSLVERSION_TLSv1_3))
The problem with that is, the max values are shifted 16bits, so they are always greater than CURL_SSLVERSION_TLSv1_3.
curl/libcurl version
curl 7.57.0 (i386-pc-win32) libcurl/7.57.0 OpenSSL/1.0.2n WinIDN
Release-Date: 2017-11-29
Protocols: dict file ftp ftps gopher http https imap imaps ldap pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
Features: AsynchDNS IDN IPv6 Largefile SSPI Kerberos SPNEGO NTLM SSL HTTPS-proxy
operating system
Windows 10 Pro x64 version 1709
The text was updated successfully, but these errors were encountered: