1
0
mirror of https://github.com/moparisthebest/wget synced 2024-07-03 16:38:41 -04:00

Fix OpenSSL compile-time check for TLSv1.1 and TLSv1.2

Reported-by: Velemas Vosak <velemas@gmail.com>
This commit is contained in:
Tim Rühsen 2014-11-10 15:34:46 +01:00
parent a0c30fc72b
commit 2457715e7d
2 changed files with 14 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2014-11-10 Tim Ruehsen <tim.ruehsen@gmx.de>
* openssl.c: Fix compile-time check for TLSv1.1 and TLSv1.2
Reported-by: Velemas Vosak <velemas@gmail.com>
2014-11-06 Tim Ruehsen <tim.ruehsen@gmx.de> 2014-11-06 Tim Ruehsen <tim.ruehsen@gmx.de>
* init.c, main.c, options.h: added new option --crl-file * init.c, main.c, options.h: added new option --crl-file

View File

@ -220,13 +220,20 @@ ssl_init (void)
case secure_protocol_tlsv1: case secure_protocol_tlsv1:
meth = TLSv1_client_method (); meth = TLSv1_client_method ();
break; break;
#if OPENSSL_VERSION_NUMBER >= 0x01001000 #if OPENSSL_VERSION_NUMBER >= 0x10001000
case secure_protocol_tlsv1_1: case secure_protocol_tlsv1_1:
meth = TLSv1_1_client_method (); meth = TLSv1_1_client_method ();
break; break;
case secure_protocol_tlsv1_2: case secure_protocol_tlsv1_2:
meth = TLSv1_2_client_method (); meth = TLSv1_2_client_method ();
break; break;
#else
case secure_protocol_tlsv1_1:
logprintf (LOG_NOTQUIET, _("Your OpenSSL version is too old to support TLSv1.1\n"));
goto error;
case secure_protocol_tlsv1_2:
logprintf (LOG_NOTQUIET, _("Your OpenSSL version is too old to support TLSv1.2\n"));
goto error;
#endif #endif
default: default:
abort (); abort ();