summaryrefslogtreecommitdiffstats
path: root/demos
diff options
context:
space:
mode:
authorHugo Landau <hlandau@openssl.org>2023-10-16 14:58:36 +0100
committerHugo Landau <hlandau@openssl.org>2023-10-19 08:28:59 +0100
commitf92d4a07ccdcce9c446db26e8ad01e880f007f39 (patch)
tree69111d8d65bde496d3e8acca5f0610a06b45266a /demos
parent17b8f405a212a01f9258eb7edcfb687a90cc8d28 (diff)
Add SNI
Reviewed-by: Matt Caswell <matt@openssl.org> Reviewed-by: Tim Hudson <tjh@openssl.org> (Merged from https://github.com/openssl/openssl/pull/22369)
Diffstat (limited to 'demos')
-rw-r--r--demos/http3/ossl-nghttp3.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/demos/http3/ossl-nghttp3.c b/demos/http3/ossl-nghttp3.c
index 20d814c90e..2b2259f34f 100644
--- a/demos/http3/ossl-nghttp3.c
+++ b/demos/http3/ossl-nghttp3.c
@@ -421,6 +421,10 @@ OSSL_DEMO_H3_CONN *OSSL_DEMO_H3_CONN_new_for_addr(SSL_CTX *ctx, const char *addr
if (SSL_set1_host(qconn, bare_hostname) <= 0)
goto err;
+ /* Configure SNI */
+ if (!SSL_set_tlsext_host_name(qconn, bare_hostname))
+ goto err;
+
conn = OSSL_DEMO_H3_CONN_new_for_conn(qconn_bio, callbacks,
settings, user_data);
if (conn == NULL)