comparison ssl_verify_client.t @ 952:e9064d691790

Tests: converted tests to run in parallel.
author Andrey Zelenkov <zelenkov@nginx.com>
date Tue, 21 Jun 2016 16:39:13 +0300
parents f9ab0aa6e14e
children 882267679006
comparison
equal deleted inserted replaced
951:9361c7eddfc1 952:e9064d691790
48 ssl_verify_client optional_no_ca; 48 ssl_verify_client optional_no_ca;
49 49
50 add_header X-Verify $ssl_client_verify; 50 add_header X-Verify $ssl_client_verify;
51 51
52 server { 52 server {
53 listen 127.0.0.1:8443 ssl; 53 listen 127.0.0.1:%%PORT_0%% ssl;
54 server_name localhost; 54 server_name localhost;
55 55
56 ssl_client_certificate client.crt; 56 ssl_client_certificate client.crt;
57 57
58 location / { } 58 location / { }
59 } 59 }
60 60
61 server { 61 server {
62 listen 127.0.0.1:8443 ssl; 62 listen 127.0.0.1:%%PORT_0%% ssl;
63 server_name example.com; 63 server_name example.com;
64 64
65 location / { } 65 location / { }
66 } 66 }
67 } 67 }
117 local $SIG{PIPE} = sub { die "sigpipe\n" }; 117 local $SIG{PIPE} = sub { die "sigpipe\n" };
118 alarm(2); 118 alarm(2);
119 $s = IO::Socket::SSL->new( 119 $s = IO::Socket::SSL->new(
120 Proto => 'tcp', 120 Proto => 'tcp',
121 PeerAddr => '127.0.0.1', 121 PeerAddr => '127.0.0.1',
122 PeerPort => 8443, 122 PeerPort => port(0),
123 SSL_verify_mode => IO::Socket::SSL::SSL_VERIFY_NONE(), 123 SSL_verify_mode => IO::Socket::SSL::SSL_VERIFY_NONE(),
124 SSL_hostname => $sni, 124 SSL_hostname => $sni,
125 SSL_cert_file => "$d/client.crt", 125 SSL_cert_file => "$d/client.crt",
126 SSL_key_file => "$d/client.key", 126 SSL_key_file => "$d/client.key",
127 SSL_error_trap => sub { die $_[1] } 127 SSL_error_trap => sub { die $_[1] }