mirror of
https://github.com/brunoos/luasec.git
synced 2024-11-07 22:18:27 +01:00
Keep 'sslv23' for compability, but deprected. (it will be removed in the next version)
This commit is contained in:
parent
8be458ff8a
commit
6a7a6f7f67
@ -35,6 +35,9 @@ typedef const SSL_METHOD LSEC_SSL_METHOD;
|
||||
typedef SSL_METHOD LSEC_SSL_METHOD;
|
||||
#endif
|
||||
|
||||
#if OPENSSL_VERSION_NUMBER>=0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
|
||||
#define SSLv23_method() TLS_method()
|
||||
#endif
|
||||
|
||||
/*-- Compat - Lua 5.1 --------------------------------------------------------*/
|
||||
|
||||
@ -93,10 +96,8 @@ static int set_option_flag(const char *opt, unsigned long *flag)
|
||||
*/
|
||||
static LSEC_SSL_METHOD* str2method(const char *method)
|
||||
{
|
||||
#if OPENSSL_VERSION_NUMBER>=0x10100000L && !defined(LIBRESSL_VERSION_NUMBER)
|
||||
#define SSLv23_method TLS_method
|
||||
#endif
|
||||
if (!strcmp(method, "any")) return SSLv23_method();
|
||||
if (!strcmp(method, "any")) return SSLv23_method();
|
||||
if (!strcmp(method, "sslv23")) return SSLv23_method(); // deprecated
|
||||
#ifndef OPENSSL_NO_SSL3
|
||||
if (!strcmp(method, "sslv3")) return SSLv3_method();
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user