Source release v3.5.0
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
#include "http_socket.h"
|
||||
|
||||
#include <cstring>
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
#include <netdb.h>
|
||||
@@ -36,13 +37,14 @@ bool Tokenize(const std::string& source, const std::string& delim,
|
||||
}
|
||||
|
||||
SSL_CTX* InitSslContext() {
|
||||
const SSL_METHOD* method;
|
||||
SSL_CTX* ctx;
|
||||
|
||||
OpenSSL_add_all_algorithms();
|
||||
SSL_load_error_strings();
|
||||
method = TLSv1_2_client_method();
|
||||
ctx = SSL_CTX_new(method);
|
||||
#if (OPENSSL_VERSION_NUMBER < 0x10100000L)
|
||||
const SSL_METHOD* method = TLSv1_2_client_method();
|
||||
#else
|
||||
const SSL_METHOD* method = TLS_client_method();
|
||||
#endif
|
||||
SSL_CTX* ctx = SSL_CTX_new(method);
|
||||
if (!ctx) LOGE("failed to create SSL context");
|
||||
int ret = SSL_CTX_set_cipher_list(
|
||||
ctx, "ALL:!RC4-MD5:!RC4-SHA:!ECDHE-ECDSA-RC4-SHA:!ECDHE-RSA-RC4-SHA");
|
||||
|
||||
Reference in New Issue
Block a user