Fix nits in pod files.
[openssl.git] / doc / apps / s_time.pod
1 =pod
2
3 =head1 NAME
4
5 s_time - SSL/TLS performance timing program
6
7 =head1 SYNOPSIS
8
9 B<openssl> B<s_time>
10 [B<-help>]
11 [B<-connect host:port>]
12 [B<-www page>]
13 [B<-cert filename>]
14 [B<-key filename>]
15 [B<-CApath directory>]
16 [B<-CAfile filename>]
17 [B<-no-CAfile>]
18 [B<-no-CApath>]
19 [B<-reuse>]
20 [B<-new>]
21 [B<-verify depth>]
22 [B<-nbio>]
23 [B<-time seconds>]
24 [B<-ssl3>]
25 [B<-bugs>]
26 [B<-cipher cipherlist>]
27
28 =head1 DESCRIPTION
29
30 The B<s_time> command implements a generic SSL/TLS client which connects to a
31 remote host using SSL/TLS. It can request a page from the server and includes
32 the time to transfer the payload data in its timing measurements. It measures
33 the number of connections within a given timeframe, the amount of data
34 transferred (if any), and calculates the average time spent for one connection.
35
36 =head1 OPTIONS
37
38 =over 4
39
40 =item B<-help>
41
42 Print out a usage message.
43
44 =item B<-connect host:port>
45
46 This specifies the host and optional port to connect to.
47
48 =item B<-www page>
49
50 This specifies the page to GET from the server. A value of '/' gets the
51 index.htm[l] page. If this parameter is not specified, then B<s_time> will only
52 perform the handshake to establish SSL connections but not transfer any
53 payload data.
54
55 =item B<-cert certname>
56
57 The certificate to use, if one is requested by the server. The default is
58 not to use a certificate. The file is in PEM format.
59
60 =item B<-key keyfile>
61
62 The private key to use. If not specified then the certificate file will
63 be used. The file is in PEM format.
64
65 =item B<-verify depth>
66
67 The verify depth to use. This specifies the maximum length of the
68 server certificate chain and turns on server certificate verification.
69 Currently the verify operation continues after errors so all the problems
70 with a certificate chain can be seen. As a side effect the connection
71 will never fail due to a server certificate verify failure.
72
73 =item B<-CApath directory>
74
75 The directory to use for server certificate verification. This directory
76 must be in "hash format", see B<verify> for more information. These are
77 also used when building the client certificate chain.
78
79 =item B<-CAfile file>
80
81 A file containing trusted certificates to use during server authentication
82 and to use when attempting to build the client certificate chain.
83
84 =item B<-no-CAfile>
85
86 Do not load the trusted CA certificates from the default file location
87
88 =item B<-no-CApath>
89
90 Do not load the trusted CA certificates from the default directory location
91
92 =item B<-new>
93
94 performs the timing test using a new session ID for each connection.
95 If neither B<-new> nor B<-reuse> are specified, they are both on by default
96 and executed in sequence.
97
98 =item B<-reuse>
99
100 performs the timing test using the same session ID; this can be used as a test
101 that session caching is working. If neither B<-new> nor B<-reuse> are
102 specified, they are both on by default and executed in sequence.
103
104 =item B<-nbio>
105
106 turns on non-blocking I/O.
107
108 =item B<-ssl3>
109
110 these options disable the use of certain SSL or TLS protocols. By default
111 the initial handshake uses a method which should be compatible with all
112 servers and permit them to use SSL v3 or TLS as appropriate.
113 The timing program is not as rich in options to turn protocols on and off as
114 the L<s_client(1)> program and may not connect to all servers.
115
116 Unfortunately there are a lot of ancient and broken servers in use which
117 cannot handle this technique and will fail to connect. Some servers only
118 work if TLS is turned off with the B<-ssl3> option.
119
120 =item B<-bugs>
121
122 there are several known bug in SSL and TLS implementations. Adding this
123 option enables various workarounds.
124
125 =item B<-cipher cipherlist>
126
127 this allows the cipher list sent by the client to be modified. Although
128 the server determines which cipher suite is used it should take the first
129 supported cipher in the list sent by the client.
130 See the L<ciphers(1)> command for more information.
131
132 =item B<-time length>
133
134 specifies how long (in seconds) B<s_time> should establish connections and
135 optionally transfer payload data from a server. Server and client performance
136 and the link speed determine how many connections B<s_time> can establish.
137
138 =back
139
140 =head1 NOTES
141
142 B<s_time> can be used to measure the performance of an SSL connection.
143 To connect to an SSL HTTP server and get the default page the command
144
145  openssl s_time -connect servername:443 -www / -CApath yourdir -CAfile yourfile.pem -cipher commoncipher [-ssl3]
146
147 would typically be used (https uses port 443). 'commoncipher' is a cipher to
148 which both client and server can agree, see the L<ciphers(1)> command
149 for details.
150
151 If the handshake fails then there are several possible causes, if it is
152 nothing obvious like no client certificate then the B<-bugs> and
153 B<-ssl3> options can be tried
154 in case it is a buggy server. In particular you should play with these
155 options B<before> submitting a bug report to an OpenSSL mailing list.
156
157 A frequent problem when attempting to get client certificates working
158 is that a web client complains it has no certificates or gives an empty
159 list to choose from. This is normally because the server is not sending
160 the clients certificate authority in its "acceptable CA list" when it
161 requests a certificate. By using L<s_client(1)> the CA list can be
162 viewed and checked. However some servers only request client authentication
163 after a specific URL is requested. To obtain the list in this case it
164 is necessary to use the B<-prexit> option of L<s_client(1)> and
165 send an HTTP request for an appropriate page.
166
167 If a certificate is specified on the command line using the B<-cert>
168 option it will not be used unless the server specifically requests
169 a client certificate. Therefor merely including a client certificate
170 on the command line is no guarantee that the certificate works.
171
172 =head1 BUGS
173
174 Because this program does not have all the options of the
175 L<s_client(1)> program to turn protocols on and off, you may not be
176 able to measure the performance of all protocols with all servers.
177
178 The B<-verify> option should really exit if the server verification
179 fails.
180
181 =head1 SEE ALSO
182
183 L<s_client(1)>, L<s_server(1)>, L<ciphers(1)>
184
185 =cut
186
187 =head1 COPYRIGHT
188
189 Copyright 2004-2016 The OpenSSL Project Authors. All Rights Reserved.
190
191 Licensed under the OpenSSL license (the "License").  You may not use
192 this file except in compliance with the License.  You can obtain a copy
193 in the file LICENSE in the source distribution or at
194 L<https://www.openssl.org/source/license.html>.
195
196 =cut