# HG changeset patch # User Maxim Dounin # Date 1679590221 -10800 # Node ID 6705a3760f480f90ad51ac29ea4b42e2c80230cc # Parent 818e6d8c43b53dfc20934214d6bee986f9aca5f2 Tests: fixed stream_proxy_ssl.t with LibreSSL and TLSv1.3. LibreSSL does not support session reuse with TLSv1.3. diff --git a/stream_proxy_ssl.t b/stream_proxy_ssl.t --- a/stream_proxy_ssl.t +++ b/stream_proxy_ssl.t @@ -78,6 +78,8 @@ http { ssl_certificate_key localhost.key; ssl_certificate localhost.crt; + + add_header X-Protocol $ssl_protocol; } } @@ -111,9 +113,16 @@ is(stream('127.0.0.1:' . port(8081))->re is(stream('127.0.0.1:' . port(8081))->read(), '.', 'ssl 2'); is(stream('127.0.0.1:' . port(8082))->read(), '.', 'ssl session new'); + +TODO: { +local $TODO = 'no TLSv1.3 sessions in LibreSSL' + if $t->has_module('LibreSSL') && test_tls13(); + is(stream('127.0.0.1:' . port(8082))->read(), 'r', 'ssl session reused'); is(stream('127.0.0.1:' . port(8082))->read(), 'r', 'ssl session reused 2'); +} + my $s = http('', start => 1); sleep 3; @@ -121,3 +130,9 @@ sleep 3; like(http_get('/', socket => $s), qr/200 OK/, 'proxy connect timeout'); ############################################################################### + +sub test_tls13 { + http_get('/') =~ /TLSv1.3/; +} + +###############################################################################