Mercurial > hg > nginx-tests
comparison ssl_sni_reneg.t @ 1535:144c6ce732e4
Tests: removed TODO and try_run() checks for legacy versions.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Mon, 02 Dec 2019 14:56:37 +0300 |
parents | dbce8fb5f5f8 |
children | fd440d324700 |
comparison
equal
deleted
inserted
replaced
1534:96fb3513345b | 1535:144c6ce732e4 |
---|---|
102 | 102 |
103 $t->plan(8); | 103 $t->plan(8); |
104 | 104 |
105 ############################################################################### | 105 ############################################################################### |
106 | 106 |
107 my ($ossl) = $t->{_configure_args} =~ /OpenSSL ([\d\.]+)/; | |
108 | |
109 my ($s, $ssl) = get_ssl_socket(8080); | 107 my ($s, $ssl) = get_ssl_socket(8080); |
110 ok($s, 'connection'); | 108 ok($s, 'connection'); |
111 | 109 |
112 SKIP: { | 110 SKIP: { |
113 skip 'connection failed', 3 unless $s; | 111 skip 'connection failed', 3 unless $s; |
119 ok(Net::SSLeay::renegotiate($ssl), 'renegotiation'); | 117 ok(Net::SSLeay::renegotiate($ssl), 'renegotiation'); |
120 ok(Net::SSLeay::set_tlsext_host_name($ssl, 'localhost'), 'SNI'); | 118 ok(Net::SSLeay::set_tlsext_host_name($ssl, 'localhost'), 'SNI'); |
121 | 119 |
122 Net::SSLeay::write($ssl, 'Host: localhost' . CRLF . CRLF); | 120 Net::SSLeay::write($ssl, 'Host: localhost' . CRLF . CRLF); |
123 | 121 |
124 TODO: { | |
125 local $TODO = 'not yet' if $ossl ge '1.1.1' and $^O eq 'linux' | |
126 and !$t->has_version('1.15.2'); | |
127 | |
128 ok(!Net::SSLeay::read($ssl), 'response'); | 122 ok(!Net::SSLeay::read($ssl), 'response'); |
129 | 123 |
130 } | 124 } |
131 | 125 |
132 } | |
133 | |
134 # virtual servers | 126 # virtual servers |
135 # in [1.15.4..1.15.5) SSL_OP_NO_RENEGOTIATION is cleared in servername callback | |
136 | 127 |
137 ($s, $ssl) = get_ssl_socket(8081); | 128 ($s, $ssl) = get_ssl_socket(8081); |
138 ok($s, 'connection 2'); | 129 ok($s, 'connection 2'); |
139 | 130 |
140 SKIP: { | 131 SKIP: { |
147 ok(Net::SSLeay::renegotiate($ssl), 'renegotiation'); | 138 ok(Net::SSLeay::renegotiate($ssl), 'renegotiation'); |
148 ok(Net::SSLeay::set_tlsext_host_name($ssl, 'localhost'), 'SNI'); | 139 ok(Net::SSLeay::set_tlsext_host_name($ssl, 'localhost'), 'SNI'); |
149 | 140 |
150 Net::SSLeay::write($ssl, 'Host: localhost' . CRLF . CRLF); | 141 Net::SSLeay::write($ssl, 'Host: localhost' . CRLF . CRLF); |
151 | 142 |
152 TODO: { | |
153 local $TODO = 'not yet' if $ossl ge '1.1.1' and $^O eq 'linux' | |
154 and !$t->has_version('1.15.2'); | |
155 | |
156 ok(!Net::SSLeay::read($ssl), 'virtual servers'); | 143 ok(!Net::SSLeay::read($ssl), 'virtual servers'); |
157 | |
158 } | |
159 | 144 |
160 } | 145 } |
161 | 146 |
162 ############################################################################### | 147 ############################################################################### |
163 | 148 |