Skip to content

Instantly share code, notes, and snippets.

@AviSoomirtee
Last active March 23, 2019 09:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AviSoomirtee/22c1b698c796177d836323ef506665a5 to your computer and use it in GitHub Desktop.
Save AviSoomirtee/22c1b698c796177d836323ef506665a5 to your computer and use it in GitHub Desktop.
adding post handshake authentication in wget with tls 1.3
diff --git a/src/openssl.c b/src/openssl.c
index a6fec5b..15e7510 100644
--- a/src/openssl.c
+++ b/src/openssl.c
@@ -295,6 +295,12 @@ ssl_init (void)
if (ssl_options)
SSL_CTX_set_options (ssl_ctx, ssl_options);
+#if ((OPENSSL_VERSION_NUMBER >= 0x10101000L) && \
+ !defined(LIBRESSL_VERSION_NUMBER) && \
+ !defined(OPENSSL_IS_BORINGSSL))
+ SSL_CTX_set_post_handshake_auth (ssl_ctx, 1);
+#endif
+
#if !defined(LIBRESSL_VERSION_NUMBER) && (OPENSSL_VERSION_NUMBER >= 0x10100000L)
if (ssl_proto_version)
SSL_CTX_set_min_proto_version(ssl_ctx, ssl_proto_version);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment