Mercurial > hg > nginx-tests
comparison ssl_sni_reneg.t @ 1387:ad3cb6f451a5
Tests: skip ssl_sni_reneg.t with TLS 1.3.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Thu, 11 Oct 2018 19:24:04 +0300 |
parents | f50c7d90f5c9 |
children | 8c764fd93b5e |
comparison
equal
deleted
inserted
replaced
1386:261f01ee5364 | 1387:ad3cb6f451a5 |
---|---|
37 my $ssl = Net::SSLeay::new($ctx) or die; | 37 my $ssl = Net::SSLeay::new($ctx) or die; |
38 Net::SSLeay::set_tlsext_host_name($ssl, 'example.org') == 1 or die; | 38 Net::SSLeay::set_tlsext_host_name($ssl, 'example.org') == 1 or die; |
39 }; | 39 }; |
40 plan(skip_all => 'Net::SSLeay with OpenSSL SNI support required') if $@; | 40 plan(skip_all => 'Net::SSLeay with OpenSSL SNI support required') if $@; |
41 | 41 |
42 my $t = Test::Nginx->new()->has(qw/http http_ssl/)->has_daemon('openssl') | 42 my $t = Test::Nginx->new()->has(qw/http http_ssl/)->has_daemon('openssl'); |
43 ->plan(8); | |
44 | 43 |
45 $t->write_file_expand('nginx.conf', <<'EOF'); | 44 $t->write_file_expand('nginx.conf', <<'EOF'); |
46 | 45 |
47 %%TEST_GLOBALS%% | 46 %%TEST_GLOBALS%% |
48 | 47 |
92 . ">>$d/openssl.out 2>&1") == 0 | 91 . ">>$d/openssl.out 2>&1") == 0 |
93 or die "Can't create certificate for $name: $!\n"; | 92 or die "Can't create certificate for $name: $!\n"; |
94 } | 93 } |
95 | 94 |
96 $t->run(); | 95 $t->run(); |
96 | |
97 { | |
98 my (undef, $ssl) = get_ssl_socket(8080); | |
99 plan(skip_all => "TLS 1.3 forbids renegotiation") | |
100 if Net::SSLeay::version($ssl) > 0x0303; | |
101 } | |
102 | |
103 $t->plan(8); | |
97 | 104 |
98 ############################################################################### | 105 ############################################################################### |
99 | 106 |
100 my ($s, $ssl) = get_ssl_socket(8080); | 107 my ($s, $ssl) = get_ssl_socket(8080); |
101 ok($s, 'connection'); | 108 ok($s, 'connection'); |