From 35db51bec68bcbca7b7dbce4883042d196cf1c4f Mon Sep 17 00:00:00 2001 From: Muzaffar Auhammud Date: Wed, 11 Jul 2018 15:49:08 +0400 Subject: [PATCH] Implement support for TLSv1.3 in OpenSSL >= 1.1.1 --- src/httperf.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/httperf.c b/src/httperf.c index eda1b09..4e42331 100755 --- a/src/httperf.c +++ b/src/httperf.c @@ -1088,6 +1088,14 @@ main(int argc, char **argv) SSL_CTX_set_options(ssl_ctx, SSL_OP_NO_SSLv2 | SSL_OP_NO_SSLv3 | SSL_OP_NO_TLSv1 | SSL_OP_NO_TLSv1_1); break; #endif +#if (OPENSSL_VERSION_NUMBER >= 0x10101000L) + /* 7/TLSv1.3 */ + ssl_ctx = SSL_CTX_new (TLS_client_method ()); + SSL_CTX_set_min_proto_version(ssl_ctx, TLS1_3_VERSION); + SSL_CTX_set_max_proto_version(ssl_ctx, TLS1_3_VERSION); + break; +#endif + } if (!ssl_ctx) {