1136 lines
50 KiB
HTML
Executable File
1136 lines
50 KiB
HTML
Executable File
<?xml version="1.0" ?>
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<title>openssl-s_client</title>
|
|
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
|
<link rev="made" href="mailto:root@localhost" />
|
|
</head>
|
|
|
|
<body style="background-color: white">
|
|
|
|
|
|
<!-- INDEX BEGIN -->
|
|
<div name="index">
|
|
<p><a name="__index__"></a></p>
|
|
|
|
<ul>
|
|
|
|
<li><a href="#name">NAME</a></li>
|
|
<li><a href="#synopsis">SYNOPSIS</a></li>
|
|
<li><a href="#description">DESCRIPTION</a></li>
|
|
<li><a href="#options">OPTIONS</a></li>
|
|
<li><a href="#connected_commands">CONNECTED COMMANDS</a></li>
|
|
<li><a href="#notes">NOTES</a></li>
|
|
<li><a href="#bugs">BUGS</a></li>
|
|
<li><a href="#see_also">SEE ALSO</a></li>
|
|
<li><a href="#history">HISTORY</a></li>
|
|
<li><a href="#copyright">COPYRIGHT</a></li>
|
|
</ul>
|
|
|
|
<hr name="index" />
|
|
</div>
|
|
<!-- INDEX END -->
|
|
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="name">NAME</a></h1>
|
|
<p>openssl-s_client - SSL/TLS client program</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="synopsis">SYNOPSIS</a></h1>
|
|
<p><strong>openssl</strong> <strong>s_client</strong>
|
|
[<strong>-help</strong>]
|
|
[<strong>-ssl_config</strong> <em>section</em>]
|
|
[<strong>-connect</strong> <em>host:port</em>]
|
|
[<strong>-host</strong> <em>hostname</em>]
|
|
[<strong>-port</strong> <em>port</em>]
|
|
[<strong>-bind</strong> <em>host:port</em>]
|
|
[<strong>-proxy</strong> <em>host:port</em>]
|
|
[<strong>-proxy_user</strong> <em>userid</em>]
|
|
[<strong>-proxy_pass</strong> <em>arg</em>]
|
|
[<strong>-unix</strong> <em>path</em>]
|
|
[<strong>-4</strong>]
|
|
[<strong>-6</strong>]
|
|
[<strong>-servername</strong> <em>name</em>]
|
|
[<strong>-noservername</strong>]
|
|
[<strong>-verify</strong> <em>depth</em>]
|
|
[<strong>-verify_return_error</strong>]
|
|
[<strong>-verify_quiet</strong>]
|
|
[<strong>-verifyCAfile</strong> <em>filename</em>]
|
|
[<strong>-verifyCApath</strong> <em>dir</em>]
|
|
[<strong>-verifyCAstore</strong> <em>uri</em>]
|
|
[<strong>-cert</strong> <em>filename</em>]
|
|
[<strong>-certform</strong> <strong>DER</strong>|<strong>PEM</strong>]
|
|
[<strong>-CRL</strong> <em>filename</em>]
|
|
[<strong>-CRLform</strong> <strong>DER</strong>|<strong>PEM</strong>]
|
|
[<strong>-crl_download</strong>]
|
|
[<strong>-key</strong> <em>filename</em>]
|
|
[<strong>-keyform</strong> <strong>DER</strong>|<strong>PEM</strong>]
|
|
[<strong>-cert_chain</strong> <em>filename</em>]
|
|
[<strong>-build_chain</strong>]
|
|
[<strong>-pass</strong> <em>arg</em>]
|
|
[<strong>-chainCApath</strong> <em>directory</em>]
|
|
[<strong>-chainCAfile</strong> <em>filename</em>]
|
|
[<strong>-chainCAstore</strong> <em>uri</em>]
|
|
[<strong>-requestCAfile</strong> <em>filename</em>]
|
|
[<strong>-dane_tlsa_domain</strong> <em>domain</em>]
|
|
[<strong>-dane_tlsa_rrdata</strong> <em>rrdata</em>]
|
|
[<strong>-dane_ee_no_namechecks</strong>]
|
|
[<strong>-build_chain</strong>]
|
|
[<strong>-reconnect</strong>]
|
|
[<strong>-showcerts</strong>]
|
|
[<strong>-prexit</strong>]
|
|
[<strong>-debug</strong>]
|
|
[<strong>-trace</strong>]
|
|
[<strong>-nocommands</strong>]
|
|
[<strong>-security_debug</strong>]
|
|
[<strong>-security_debug_verbose</strong>]
|
|
[<strong>-msg</strong>]
|
|
[<strong>-timeout</strong>]
|
|
[<strong>-mtu</strong> <em>size</em>]
|
|
[<strong>-keymatexport</strong> <em>label</em>]
|
|
[<strong>-keymatexportlen</strong> <em>len</em>]
|
|
[<strong>-msgfile</strong> <em>filename</em>]
|
|
[<strong>-nbio_test</strong>]
|
|
[<strong>-state</strong>]
|
|
[<strong>-nbio</strong>]
|
|
[<strong>-crlf</strong>]
|
|
[<strong>-ign_eof</strong>]
|
|
[<strong>-no_ign_eof</strong>]
|
|
[<strong>-psk_identity</strong> <em>identity</em>]
|
|
[<strong>-psk</strong> <em>key</em>]
|
|
[<strong>-psk_session</strong> <em>file</em>]
|
|
[<strong>-quiet</strong>]
|
|
[<strong>-sctp</strong>]
|
|
[<strong>-sctp_label_bug</strong>]
|
|
[<strong>-fallback_scsv</strong>]
|
|
[<strong>-async</strong>]
|
|
[<strong>-maxfraglen</strong> <em>len</em>]
|
|
[<strong>-max_send_frag</strong>]
|
|
[<strong>-split_send_frag</strong>]
|
|
[<strong>-max_pipelines</strong>]
|
|
[<strong>-read_buf</strong>]
|
|
[<strong>-bugs</strong>]
|
|
[<strong>-comp</strong>]
|
|
[<strong>-no_comp</strong>]
|
|
[<strong>-brief</strong>]
|
|
[<strong>-allow_no_dhe_kex</strong>]
|
|
[<strong>-sigalgs</strong> <em>sigalglist</em>]
|
|
[<strong>-curves</strong> <em>curvelist</em>]
|
|
[<strong>-cipher</strong> <em>cipherlist</em>]
|
|
[<strong>-ciphersuites</strong> <em>val</em>]
|
|
[<strong>-serverpref</strong>]
|
|
[<strong>-starttls</strong> <em>protocol</em>]
|
|
[<strong>-name</strong> <em>hostname</em>]
|
|
[<strong>-xmpphost</strong> <em>hostname</em>]
|
|
[<strong>-name</strong> <em>hostname</em>]
|
|
[<strong>-tlsextdebug</strong>]
|
|
[<strong>-no_ticket</strong>]
|
|
[<strong>-sess_out</strong> <em>filename</em>]
|
|
[<strong>-serverinfo</strong> <em>types</em>]
|
|
[<strong>-sess_in</strong> <em>filename</em>]
|
|
[<strong>-serverinfo</strong> <em>types</em>]
|
|
[<strong>-status</strong>]
|
|
[<strong>-alpn</strong> <em>protocols</em>]
|
|
[<strong>-nextprotoneg</strong> <em>protocols</em>]
|
|
[<strong>-ct</strong>]
|
|
[<strong>-noct</strong>]
|
|
[<strong>-ctlogfile</strong>]
|
|
[<strong>-keylogfile</strong> <em>file</em>]
|
|
[<strong>-early_data</strong> <em>file</em>]
|
|
[<strong>-enable_pha</strong>]
|
|
[<strong>-use_srtp</strong> <em>value</em>]
|
|
[<strong>-srpuser</strong> <em>value</em>]
|
|
[<strong>-srppass</strong> <em>value</em>]
|
|
[<strong>-srp_lateuser</strong>]
|
|
[<strong>-srp_moregroups</strong>]
|
|
[<strong>-srp_strength</strong> <em>number</em>]
|
|
[<strong>-nameopt</strong> <em>option</em>]
|
|
[<strong>-no_ssl3</strong>]
|
|
[<strong>-no_tls1</strong>]
|
|
[<strong>-no_tls1_1</strong>]
|
|
[<strong>-no_tls1_2</strong>]
|
|
[<strong>-no_tls1_3</strong>]
|
|
[<strong>-ssl3</strong>]
|
|
[<strong>-tls1</strong>]
|
|
[<strong>-tls1_1</strong>]
|
|
[<strong>-tls1_2</strong>]
|
|
[<strong>-tls1_3</strong>]
|
|
[<strong>-dtls</strong>]
|
|
[<strong>-dtls1</strong>]
|
|
[<strong>-dtls1_2</strong>]
|
|
[<strong>-xkey</strong>] <em>infile</em>
|
|
[<strong>-xcert</strong> <em>file</em>]
|
|
[<strong>-xchain</strong>] <em>file</em>
|
|
[<strong>-xchain_build</strong>] <em>file</em>
|
|
[<strong>-xcertform</strong> <strong>DER</strong>|<strong>PEM</strong>]>
|
|
[<strong>-xkeyform</strong> <strong>DER</strong>|<strong>PEM</strong>]>
|
|
[<strong>-CAfile</strong> <em>file</em>]
|
|
[<strong>-no-CAfile</strong>]
|
|
[<strong>-CApath</strong> <em>dir</em>]
|
|
[<strong>-no-CApath</strong>]
|
|
[<strong>-CAstore</strong> <em>uri</em>]
|
|
[<strong>-no-CAstore</strong>]
|
|
[<strong>-bugs</strong>]
|
|
[<strong>-no_comp</strong>]
|
|
[<strong>-comp</strong>]
|
|
[<strong>-no_ticket</strong>]
|
|
[<strong>-serverpref</strong>]
|
|
[<strong>-legacy_renegotiation</strong>]
|
|
[<strong>-no_renegotiation</strong>]
|
|
[<strong>-no_resumption_on_reneg</strong>]
|
|
[<strong>-legacy_server_connect</strong>]
|
|
[<strong>-no_legacy_server_connect</strong>]
|
|
[<strong>-allow_no_dhe_kex</strong>]
|
|
[<strong>-prioritize_chacha</strong>]
|
|
[<strong>-strict</strong>]
|
|
[<strong>-sigalgs</strong> <em>algs</em>]
|
|
[<strong>-client_sigalgs</strong> <em>algs</em>]
|
|
[<strong>-groups</strong> <em>groups</em>]
|
|
[<strong>-curves</strong> <em>curves</em>]
|
|
[<strong>-named_curve</strong> <em>curve</em>]
|
|
[<strong>-cipher</strong> <em>ciphers</em>]
|
|
[<strong>-ciphersuites</strong> <em>1.3ciphers</em>]
|
|
[<strong>-min_protocol</strong> <em>minprot</em>]
|
|
[<strong>-max_protocol</strong> <em>maxprot</em>]
|
|
[<strong>-record_padding</strong> <em>padding</em>]
|
|
[<strong>-debug_broken_protocol</strong>]
|
|
[<strong>-no_middlebox</strong>]
|
|
[<strong>-rand</strong> <em>files</em>]
|
|
[<strong>-writerand</strong> <em>file</em>]
|
|
[<strong>-engine</strong> <em>id</em>]
|
|
[<strong>-ssl_client_engine</strong> <em>id</em>]
|
|
[<strong>-allow_proxy_certs</strong>]
|
|
[<strong>-attime</strong> <em>timestamp</em>]
|
|
[<strong>-no_check_time</strong>]
|
|
[<strong>-check_ss_sig</strong>]
|
|
[<strong>-crl_check</strong>]
|
|
[<strong>-crl_check_all</strong>]
|
|
[<strong>-explicit_policy</strong>]
|
|
[<strong>-extended_crl</strong>]
|
|
[<strong>-ignore_critical</strong>]
|
|
[<strong>-inhibit_any</strong>]
|
|
[<strong>-inhibit_map</strong>]
|
|
[<strong>-partial_chain</strong>]
|
|
[<strong>-policy</strong> <em>arg</em>]
|
|
[<strong>-policy_check</strong>]
|
|
[<strong>-policy_print</strong>]
|
|
[<strong>-purpose</strong> <em>purpose</em>]
|
|
[<strong>-suiteB_128</strong>]
|
|
[<strong>-suiteB_128_only</strong>]
|
|
[<strong>-suiteB_192</strong>]
|
|
[<strong>-trusted_first</strong>]
|
|
[<strong>-no_alt_chains</strong>]
|
|
[<strong>-use_deltas</strong>]
|
|
[<strong>-auth_level</strong> <em>num</em>]
|
|
[<strong>-verify_depth</strong> <em>num</em>]
|
|
[<strong>-verify_email</strong> <em>email</em>]
|
|
[<strong>-verify_hostname</strong> <em>hostname</em>]
|
|
[<strong>-verify_ip</strong> <em>ip</em>]
|
|
[<strong>-verify_name</strong> <em>name</em>]
|
|
[<strong>-x509_strict</strong>]
|
|
[<strong>-issuer_checks</strong>]</p>
|
|
<p>[<em>host</em>:<em>port</em>]</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="description">DESCRIPTION</a></h1>
|
|
<p>This command implements a generic SSL/TLS client which
|
|
connects to a remote host using SSL/TLS. It is a <em>very</em> useful diagnostic
|
|
tool for SSL servers.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="options">OPTIONS</a></h1>
|
|
<p>In addition to the options below, this command also supports the
|
|
common and client only options documented
|
|
in the "Supported Command Line Commands" section of the <em>SSL_CONF_cmd(3)</em>
|
|
manual page.</p>
|
|
<dl>
|
|
<dt><strong><a name="help" class="item"><strong>-help</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Print out a usage message.</p>
|
|
</dd>
|
|
<dt><strong><a name="ssl_config_section" class="item"><strong>-ssl_config</strong> <em>section</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the specified section of the configuration file to configure the <strong>SSL_CTX</strong> object.</p>
|
|
</dd>
|
|
<dt><strong><a name="connect_host_port" class="item"><strong>-connect</strong> <em>host</em>:<em>port</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This specifies the host and optional port to connect to. It is possible to
|
|
select the host and port using the optional target positional argument instead.
|
|
If neither this nor the target positional argument are specified then an attempt
|
|
is made to connect to the local host on port 4433.</p>
|
|
</dd>
|
|
<dt><strong><a name="host_hostname" class="item"><strong>-host</strong> <em>hostname</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Host to connect to; use <strong>-connect</strong> instead.</p>
|
|
</dd>
|
|
<dt><strong><a name="port_port" class="item"><strong>-port</strong> <em>port</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Connect to the specified port; use <strong>-connect</strong> instead.</p>
|
|
</dd>
|
|
<dt><strong><a name="bind_host_port" class="item"><strong>-bind</strong> <em>host:port</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This specifies the host address and or port to bind as the source for the
|
|
connection. For Unix-domain sockets the port is ignored and the host is
|
|
used as the source socket address.</p>
|
|
</dd>
|
|
<dt><strong><a name="proxy_host_port" class="item"><strong>-proxy</strong> <em>host:port</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>When used with the <strong>-connect</strong> flag, the program uses the host and port
|
|
specified with this flag and issues an HTTP CONNECT command to connect
|
|
to the desired server.</p>
|
|
</dd>
|
|
<dt><strong><a name="proxy_user_userid" class="item"><strong>-proxy_user</strong> <em>userid</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>When used with the <strong>-proxy</strong> flag, the program will attempt to authenticate
|
|
with the specified proxy using basic (base64) authentication.
|
|
NB: Basic authentication is insecure; the credentials are sent to the proxy
|
|
in easily reversible base64 encoding before any TLS/SSL session is established.
|
|
Therefore these credentials are easily recovered by anyone able to sniff/trace
|
|
the network. Use with caution.</p>
|
|
</dd>
|
|
<dt><strong><a name="proxy_pass_arg" class="item"><strong>-proxy_pass</strong> <em>arg</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The proxy password source, used with the <strong>-proxy_user</strong> flag.
|
|
For more information about the format of <strong>arg</strong>
|
|
see <em>openssl(1)/Pass Phrase Options</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="unix_path" class="item"><strong>-unix</strong> <em>path</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Connect over the specified Unix-domain socket.</p>
|
|
</dd>
|
|
<dt><strong><a name="4" class="item"><strong>-4</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use IPv4 only.</p>
|
|
</dd>
|
|
<dt><strong><a name="6" class="item"><strong>-6</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use IPv6 only.</p>
|
|
</dd>
|
|
<dt><strong><a name="servername_name" class="item"><strong>-servername</strong> <em>name</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set the TLS SNI (Server Name Indication) extension in the ClientHello message to
|
|
the given value.
|
|
If <strong>-servername</strong> is not provided, the TLS SNI extension will be populated with
|
|
the name given to <strong>-connect</strong> if it follows a DNS name format. If <strong>-connect</strong> is
|
|
not provided either, the SNI is set to "localhost".
|
|
This is the default since OpenSSL 1.1.1.</p>
|
|
<p>Even though SNI should normally be a DNS name and not an IP address, if
|
|
<strong>-servername</strong> is provided then that name will be sent, regardless of whether
|
|
it is a DNS name or not.</p>
|
|
<p>This option cannot be used in conjunction with <strong>-noservername</strong>.</p>
|
|
</dd>
|
|
<dt><strong><a name="noservername" class="item"><strong>-noservername</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Suppresses sending of the SNI (Server Name Indication) extension in the
|
|
ClientHello message. Cannot be used in conjunction with the <strong>-servername</strong> or
|
|
<-dane_tlsa_domain> options.</p>
|
|
</dd>
|
|
<dt><strong><a name="cert_certname" class="item"><strong>-cert</strong> <em>certname</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The certificate to use, if one is requested by the server. The default is
|
|
not to use a certificate.</p>
|
|
</dd>
|
|
<dt><strong><a name="certform_format" class="item"><strong>-certform</strong> <em>format</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The certificate format to use: DER or PEM. PEM is the default.</p>
|
|
</dd>
|
|
<dt><strong><a name="crl_filename" class="item"><strong>-CRL</strong> <em>filename</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>CRL file to use to check the server's certificate.</p>
|
|
</dd>
|
|
<dt><strong><a name="crlform_der_pem" class="item"><strong>-CRLform</strong> <strong>DER</strong>|<strong>PEM</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The CRL format; the default is <strong>PEM</strong>.
|
|
See <em>openssl(1)/Format Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="crl_download" class="item"><strong>-crl_download</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Download CRL from distribution points in the certificate.</p>
|
|
</dd>
|
|
<dt><strong><a name="key_keyfile" class="item"><strong>-key</strong> <em>keyfile</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The private key to use. If not specified then the certificate file will
|
|
be used.</p>
|
|
</dd>
|
|
<dt><strong><a name="keyform_format" class="item"><strong>-keyform</strong> <em>format</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The key format; the default is <strong>PEM</strong>.
|
|
See <em>openssl(1)/Format Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="cert_chain" class="item"><strong>-cert_chain</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>A file containing trusted certificates to use when attempting to build the
|
|
client/server certificate chain related to the certificate specified via the
|
|
<strong>-cert</strong> option.</p>
|
|
</dd>
|
|
<dt><strong><a name="build_chain" class="item"><strong>-build_chain</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Specify whether the application should build the certificate chain to be
|
|
provided to the server.</p>
|
|
</dd>
|
|
<dt><strong><a name="pass_arg" class="item"><strong>-pass</strong> <em>arg</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>the private key password source. For more information about the format of <em>arg</em>
|
|
see <em>openssl(1)/Pass phrase options</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="verify_depth" class="item"><strong>-verify</strong> <em>depth</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The verify depth to use. This specifies the maximum length of the
|
|
server certificate chain and turns on server certificate verification.
|
|
Currently the verify operation continues after errors so all the problems
|
|
with a certificate chain can be seen. As a side effect the connection
|
|
will never fail due to a server certificate verify failure.</p>
|
|
</dd>
|
|
<dt><strong><a name="verify_return_error" class="item"><strong>-verify_return_error</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Return verification errors instead of continuing. This will typically
|
|
abort the handshake with a fatal error.</p>
|
|
</dd>
|
|
<dt><strong><a name="verify_quiet" class="item"><strong>-verify_quiet</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Limit verify output to only errors.</p>
|
|
</dd>
|
|
<dt><strong><a name="verifycafile_filename" class="item"><strong>-verifyCAfile</strong> <em>filename</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>CA file for verifying the server's certificate, in PEM format.</p>
|
|
</dd>
|
|
<dt><strong><a name="verifycapath_dir" class="item"><strong>-verifyCApath</strong> <em>dir</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the specified directory as a certificate store path to verify
|
|
the server's CA certificate.</p>
|
|
</dd>
|
|
<dt><strong><a name="verifycastore_uri" class="item"><strong>-verifyCAstore</strong> <em>uri</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the specified URI as a store URI to verify the server's certificate.</p>
|
|
</dd>
|
|
<dt><strong><a name="chaincapath_directory" class="item"><strong>-chainCApath</strong> <em>directory</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The directory to use for building the chain provided to the server. This
|
|
directory must be in "hash format", see <em>openssl-verify(1)</em> for more
|
|
information.</p>
|
|
</dd>
|
|
<dt><strong><a name="chaincafile_file" class="item"><strong>-chainCAfile</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>A file containing trusted certificates to use when attempting to build the
|
|
client certificate chain.</p>
|
|
</dd>
|
|
<dt><strong><a name="chaincastore_uri" class="item"><strong>-chainCAstore</strong> <em>uri</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The URI to use when attempting to build the client certificate chain.</p>
|
|
</dd>
|
|
<dt><strong><a name="requestcafile_file" class="item"><strong>-requestCAfile</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>A file containing a list of certificates whose subject names will be sent
|
|
to the server in the <strong>certificate_authorities</strong> extension. Only supported
|
|
for TLS 1.3</p>
|
|
</dd>
|
|
<dt><strong><a name="dane_tlsa_domain_domain" class="item"><strong>-dane_tlsa_domain</strong> <em>domain</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Enable <a href="http://www.ietf.org/rfc/rfc6698.txt" class="rfc">RFC6698</a>/<a href="http://www.ietf.org/rfc/rfc7671.txt" class="rfc">RFC7671</a> DANE TLSA authentication and specify the
|
|
TLSA base domain which becomes the default SNI hint and the primary
|
|
reference identifier for hostname checks. This must be used in
|
|
combination with at least one instance of the <strong>-dane_tlsa_rrdata</strong>
|
|
option below.</p>
|
|
<p>When DANE authentication succeeds, the diagnostic output will include
|
|
the lowest (closest to 0) depth at which a TLSA record authenticated
|
|
a chain certificate. When that TLSA record is a "2 1 0" trust
|
|
anchor public key that signed (rather than matched) the top-most
|
|
certificate of the chain, the result is reported as "TA public key
|
|
verified". Otherwise, either the TLSA record "matched TA certificate"
|
|
at a positive depth or else "matched EE certificate" at depth 0.</p>
|
|
</dd>
|
|
<dt><strong><a name="dane_tlsa_rrdata_rrdata" class="item"><strong>-dane_tlsa_rrdata</strong> <em>rrdata</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use one or more times to specify the RRDATA fields of the DANE TLSA
|
|
RRset associated with the target service. The <em>rrdata</em> value is
|
|
specified in "presentation form", that is four whitespace separated
|
|
fields that specify the usage, selector, matching type and associated
|
|
data, with the last of these encoded in hexadecimal. Optional
|
|
whitespace is ignored in the associated data field. For example:</p>
|
|
<pre>
|
|
$ openssl s_client -brief -starttls smtp \
|
|
-connect smtp.example.com:25 \
|
|
-dane_tlsa_domain smtp.example.com \
|
|
-dane_tlsa_rrdata "2 1 1
|
|
B111DD8A1C2091A89BD4FD60C57F0716CCE50FEEFF8137CDBEE0326E 02CF362B" \
|
|
-dane_tlsa_rrdata "2 1 1
|
|
60B87575447DCBA2A36B7D11AC09FB24A9DB406FEE12D2CC90180517 616E8A18"
|
|
...
|
|
Verification: OK
|
|
Verified peername: smtp.example.com
|
|
DANE TLSA 2 1 1 ...ee12d2cc90180517616e8a18 matched TA certificate at depth 1
|
|
...</pre>
|
|
</dd>
|
|
<dt><strong><a name="dane_ee_no_namechecks" class="item"><strong>-dane_ee_no_namechecks</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This disables server name checks when authenticating via DANE-EE(3) TLSA
|
|
records.
|
|
For some applications, primarily web browsers, it is not safe to disable name
|
|
checks due to "unknown key share" attacks, in which a malicious server can
|
|
convince a client that a connection to a victim server is instead a secure
|
|
connection to the malicious server.
|
|
The malicious server may then be able to violate cross-origin scripting
|
|
restrictions.
|
|
Thus, despite the text of <a href="http://www.ietf.org/rfc/rfc7671.txt" class="rfc">RFC7671</a>, name checks are by default enabled for
|
|
DANE-EE(3) TLSA records, and can be disabled in applications where it is safe
|
|
to do so.
|
|
In particular, SMTP and XMPP clients should set this option as SRV and MX
|
|
records already make it possible for a remote domain to redirect client
|
|
connections to any server of its choice, and in any case SMTP and XMPP clients
|
|
do not execute scripts downloaded from remote servers.</p>
|
|
</dd>
|
|
<dt><strong><a name="reconnect" class="item"><strong>-reconnect</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Reconnects to the same server 5 times using the same session ID, this can
|
|
be used as a test that session caching is working.</p>
|
|
</dd>
|
|
<dt><strong><a name="showcerts" class="item"><strong>-showcerts</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Displays the server certificate list as sent by the server: it only consists of
|
|
certificates the server has sent (in the order the server has sent them). It is
|
|
<strong>not</strong> a verified chain.</p>
|
|
</dd>
|
|
<dt><strong><a name="prexit" class="item"><strong>-prexit</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Print session information when the program exits. This will always attempt
|
|
to print out information even if the connection fails. Normally information
|
|
will only be printed out once if the connection succeeds. This option is useful
|
|
because the cipher in use may be renegotiated or the connection may fail
|
|
because a client certificate is required or is requested only after an
|
|
attempt is made to access a certain URL. Note: the output produced by this
|
|
option is not always accurate because a connection might never have been
|
|
established.</p>
|
|
</dd>
|
|
<dt><strong><a name="state" class="item"><strong>-state</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Prints out the SSL session states.</p>
|
|
</dd>
|
|
<dt><strong><a name="debug" class="item"><strong>-debug</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Print extensive debugging information including a hex dump of all traffic.</p>
|
|
</dd>
|
|
<dt><strong><a name="nocommands" class="item"><strong>-nocommands</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Do not use interactive command letters.</p>
|
|
</dd>
|
|
<dt><strong><a name="security_debug" class="item"><strong>-security_debug</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Enable security debug messages.</p>
|
|
</dd>
|
|
<dt><strong><a name="security_debug_verbose" class="item"><strong>-security_debug_verbose</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Output more security debug output.</p>
|
|
</dd>
|
|
<dt><strong><a name="msg" class="item"><strong>-msg</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Show protocol messages.</p>
|
|
</dd>
|
|
<dt><strong><a name="timeout" class="item"><strong>-timeout</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Enable send/receive timeout on DTLS connections.</p>
|
|
</dd>
|
|
<dt><strong><a name="mtu_size" class="item"><strong>-mtu</strong> <em>size</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set MTU of the link layer to the specified size.</p>
|
|
</dd>
|
|
<dt><strong><a name="keymatexport_label" class="item"><strong>-keymatexport</strong> <em>label</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Export keying material using the specified label.</p>
|
|
</dd>
|
|
<dt><strong><a name="keymatexportlen_len" class="item"><strong>-keymatexportlen</strong> <em>len</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Export the specified number of bytes of keying material; default is 20.</p>
|
|
<p>Show all protocol messages with hex dump.</p>
|
|
</dd>
|
|
<dt><strong><a name="trace" class="item"><strong>-trace</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Show verbose trace output of protocol messages. OpenSSL needs to be compiled
|
|
with <strong>enable-ssl-trace</strong> for this option to work.</p>
|
|
</dd>
|
|
<dt><strong><a name="msgfile_filename" class="item"><strong>-msgfile</strong> <em>filename</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>File to send output of <strong>-msg</strong> or <strong>-trace</strong> to, default standard output.</p>
|
|
</dd>
|
|
<dt><strong><a name="nbio_test" class="item"><strong>-nbio_test</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Tests non-blocking I/O</p>
|
|
</dd>
|
|
<dt><strong><a name="nbio" class="item"><strong>-nbio</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Turns on non-blocking I/O</p>
|
|
</dd>
|
|
<dt><strong><a name="crlf" class="item"><strong>-crlf</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This option translated a line feed from the terminal into CR+LF as required
|
|
by some servers.</p>
|
|
</dd>
|
|
<dt><strong><a name="ign_eof" class="item"><strong>-ign_eof</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Inhibit shutting down the connection when end of file is reached in the
|
|
input.</p>
|
|
</dd>
|
|
<dt><strong><a name="quiet" class="item"><strong>-quiet</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Inhibit printing of session and certificate information. This implicitly
|
|
turns on <strong>-ign_eof</strong> as well.</p>
|
|
</dd>
|
|
<dt><strong><a name="no_ign_eof" class="item"><strong>-no_ign_eof</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Shut down the connection when end of file is reached in the input.
|
|
Can be used to override the implicit <strong>-ign_eof</strong> after <strong>-quiet</strong>.</p>
|
|
</dd>
|
|
<dt><strong><a name="psk_identity_identity" class="item"><strong>-psk_identity</strong> <em>identity</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the PSK identity <em>identity</em> when using a PSK cipher suite.
|
|
The default value is "Client_identity" (without the quotes).</p>
|
|
</dd>
|
|
<dt><strong><a name="psk_key" class="item"><strong>-psk</strong> <em>key</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the PSK key <em>key</em> when using a PSK cipher suite. The key is
|
|
given as a hexadecimal number without leading 0x, for example -psk
|
|
1a2b3c4d.
|
|
This option must be provided in order to use a PSK cipher.</p>
|
|
</dd>
|
|
<dt><strong><a name="psk_session_file" class="item"><strong>-psk_session</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the pem encoded SSL_SESSION data stored in <em>file</em> as the basis of a PSK.
|
|
Note that this will only work if TLSv1.3 is negotiated.</p>
|
|
</dd>
|
|
<dt><strong><a name="sctp" class="item"><strong>-sctp</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use SCTP for the transport protocol instead of UDP in DTLS. Must be used in
|
|
conjunction with <strong>-dtls</strong>, <strong>-dtls1</strong> or <strong>-dtls1_2</strong>. This option is only
|
|
available where OpenSSL has support for SCTP enabled.</p>
|
|
</dd>
|
|
<dt><strong><a name="sctp_label_bug" class="item"><strong>-sctp_label_bug</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use the incorrect behaviour of older OpenSSL implementations when computing
|
|
endpoint-pair shared secrets for DTLS/SCTP. This allows communication with
|
|
older broken implementations but breaks interoperability with correct
|
|
implementations. Must be used in conjunction with <strong>-sctp</strong>. This option is only
|
|
available where OpenSSL has support for SCTP enabled.</p>
|
|
</dd>
|
|
<dt><strong><a name="fallback_scsv" class="item"><strong>-fallback_scsv</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Send TLS_FALLBACK_SCSV in the ClientHello.</p>
|
|
</dd>
|
|
<dt><strong><a name="async" class="item"><strong>-async</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Switch on asynchronous mode. Cryptographic operations will be performed
|
|
asynchronously. This will only have an effect if an asynchronous capable engine
|
|
is also used via the <strong>-engine</strong> option. For test purposes the dummy async engine
|
|
(dasync) can be used (if available).</p>
|
|
</dd>
|
|
<dt><strong><a name="maxfraglen_len" class="item"><strong>-maxfraglen</strong> <em>len</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Enable Maximum Fragment Length Negotiation; allowed values are
|
|
<code>512</code>, <code>1024</code>, <code>2048</code>, and <code>4096</code>.</p>
|
|
</dd>
|
|
<dt><strong><a name="max_send_frag_int" class="item"><strong>-max_send_frag</strong> <em>int</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The maximum size of data fragment to send.
|
|
See <em>SSL_CTX_set_max_send_fragment(3)</em> for further information.</p>
|
|
</dd>
|
|
<dt><strong><a name="split_send_frag_int" class="item"><strong>-split_send_frag</strong> <em>int</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The size used to split data for encrypt pipelines. If more data is written in
|
|
one go than this value then it will be split into multiple pipelines, up to the
|
|
maximum number of pipelines defined by max_pipelines. This only has an effect if
|
|
a suitable cipher suite has been negotiated, an engine that supports pipelining
|
|
has been loaded, and max_pipelines is greater than 1. See
|
|
<em>SSL_CTX_set_split_send_fragment(3)</em> for further information.</p>
|
|
</dd>
|
|
<dt><strong><a name="max_pipelines_int" class="item"><strong>-max_pipelines</strong> <em>int</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The maximum number of encrypt/decrypt pipelines to be used. This will only have
|
|
an effect if an engine has been loaded that supports pipelining (e.g. the dasync
|
|
engine) and a suitable cipher suite has been negotiated. The default value is 1.
|
|
See <em>SSL_CTX_set_max_pipelines(3)</em> for further information.</p>
|
|
</dd>
|
|
<dt><strong><a name="read_buf_int" class="item"><strong>-read_buf</strong> <em>int</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>The default read buffer size to be used for connections. This will only have an
|
|
effect if the buffer size is larger than the size that would otherwise be used
|
|
and pipelining is in use (see <em>SSL_CTX_set_default_read_buffer_len(3)</em> for
|
|
further information).</p>
|
|
</dd>
|
|
<dt><strong><a name="bugs" class="item"><strong>-bugs</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>There are several known bugs in SSL and TLS implementations. Adding this
|
|
option enables various workarounds.</p>
|
|
</dd>
|
|
<dt><strong><a name="comp" class="item"><strong>-comp</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Enables support for SSL/TLS compression.
|
|
This option was introduced in OpenSSL 1.1.0.
|
|
TLS compression is not recommended and is off by default as of
|
|
OpenSSL 1.1.0.</p>
|
|
</dd>
|
|
<dt><strong><a name="no_comp" class="item"><strong>-no_comp</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Disables support for SSL/TLS compression.
|
|
TLS compression is not recommended and is off by default as of
|
|
OpenSSL 1.1.0.</p>
|
|
</dd>
|
|
<dt><strong><a name="brief" class="item"><strong>-brief</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Only provide a brief summary of connection parameters instead of the
|
|
normal verbose output.</p>
|
|
</dd>
|
|
<dt><strong><a name="sigalgs_sigalglist" class="item"><strong>-sigalgs</strong> <em>sigalglist</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Specifies the list of signature algorithms that are sent by the client.
|
|
The server selects one entry in the list based on its preferences.
|
|
For example strings, see <em>SSL_CTX_set1_sigalgs(3)</em></p>
|
|
</dd>
|
|
<dt><strong><a name="curves_curvelist" class="item"><strong>-curves</strong> <em>curvelist</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Specifies the list of supported curves to be sent by the client. The curve is
|
|
ultimately selected by the server. For a list of all curves, use:</p>
|
|
<pre>
|
|
$ openssl ecparam -list_curves</pre>
|
|
</dd>
|
|
<dt><strong><a name="cipher_cipherlist" class="item"><strong>-cipher</strong> <em>cipherlist</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This allows the TLSv1.2 and below cipher list sent by the client to be modified.
|
|
This list will be combined with any TLSv1.3 ciphersuites that have been
|
|
configured. Although the server determines which ciphersuite is used it should
|
|
take the first supported cipher in the list sent by the client. See
|
|
<em>openssl-ciphers(1)</em> for more information.</p>
|
|
</dd>
|
|
<dt><strong><a name="ciphersuites_val" class="item"><strong>-ciphersuites</strong> <em>val</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This allows the TLSv1.3 ciphersuites sent by the client to be modified. This
|
|
list will be combined with any TLSv1.2 and below ciphersuites that have been
|
|
configured. Although the server determines which cipher suite is used it should
|
|
take the first supported cipher in the list sent by the client. See
|
|
<em>openssl-ciphers(1)</em> for more information. The format for this list is a simple
|
|
colon (":") separated list of TLSv1.3 ciphersuite names.</p>
|
|
</dd>
|
|
<dt><strong><a name="starttls_protocol" class="item"><strong>-starttls</strong> <em>protocol</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Send the protocol-specific message(s) to switch to TLS for communication.
|
|
<em>protocol</em> is a keyword for the intended protocol. Currently, the only
|
|
supported keywords are "smtp", "pop3", "imap", "ftp", "xmpp", "xmpp-server",
|
|
"irc", "postgres", "mysql", "lmtp", "nntp", "sieve" and "ldap".</p>
|
|
</dd>
|
|
<dt><strong><a name="xmpphost_hostname" class="item"><strong>-xmpphost</strong> <em>hostname</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This option, when used with "-starttls xmpp" or "-starttls xmpp-server",
|
|
specifies the host for the "to" attribute of the stream element.
|
|
If this option is not specified, then the host specified with "-connect"
|
|
will be used.</p>
|
|
<p>This option is an alias of the <strong>-name</strong> option for "xmpp" and "xmpp-server".</p>
|
|
</dd>
|
|
<dt><strong><a name="name_hostname" class="item"><strong>-name</strong> <em>hostname</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This option is used to specify hostname information for various protocols
|
|
used with <strong>-starttls</strong> option. Currently only "xmpp", "xmpp-server",
|
|
"smtp" and "lmtp" can utilize this <strong>-name</strong> option.</p>
|
|
<p>If this option is used with "-starttls xmpp" or "-starttls xmpp-server",
|
|
if specifies the host for the "to" attribute of the stream element. If this
|
|
option is not specified, then the host specified with "-connect" will be used.</p>
|
|
<p>If this option is used with "-starttls lmtp" or "-starttls smtp", it specifies
|
|
the name to use in the "LMTP LHLO" or "SMTP EHLO" message, respectively. If
|
|
this option is not specified, then "mail.example.com" will be used.</p>
|
|
</dd>
|
|
<dt><strong><a name="tlsextdebug" class="item"><strong>-tlsextdebug</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Print out a hex dump of any TLS extensions received from the server.</p>
|
|
</dd>
|
|
<dt><strong><a name="no_ticket" class="item"><strong>-no_ticket</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Disable <a href="http://www.ietf.org/rfc/rfc4507.txt" class="rfc">RFC4507</a>bis session ticket support.</p>
|
|
</dd>
|
|
<dt><strong><a name="sess_out_filename" class="item"><strong>-sess_out</strong> <em>filename</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Output SSL session to <em>filename</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="sess_in_filename" class="item"><strong>-sess_in</strong> <em>filename</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Load SSL session from <em>filename</em>. The client will attempt to resume a
|
|
connection from this session.</p>
|
|
</dd>
|
|
<dt><strong><a name="serverinfo_types" class="item"><strong>-serverinfo</strong> <em>types</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>A list of comma-separated TLS Extension Types (numbers between 0 and
|
|
65535). Each type will be sent as an empty ClientHello TLS Extension.
|
|
The server's response (if any) will be encoded and displayed as a PEM
|
|
file.</p>
|
|
</dd>
|
|
<dt><strong><a name="status" class="item"><strong>-status</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Sends a certificate status request to the server (OCSP stapling). The server
|
|
response (if any) is printed out.</p>
|
|
</dd>
|
|
<dt><strong><a name="alpn_protocols_nextprotoneg_protocols" class="item"><strong>-alpn</strong> <em>protocols</em>, <strong>-nextprotoneg</strong> <em>protocols</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>These flags enable the Enable the Application-Layer Protocol Negotiation
|
|
or Next Protocol Negotiation (NPN) extension, respectively. ALPN is the
|
|
IETF standard and replaces NPN.
|
|
The <em>protocols</em> list is a comma-separated list of protocol names that
|
|
the client should advertise support for. The list should contain the most
|
|
desirable protocols first. Protocol names are printable ASCII strings,
|
|
for example "http/1.1" or "spdy/3".
|
|
An empty list of protocols is treated specially and will cause the
|
|
client to advertise support for the TLS extension but disconnect just
|
|
after receiving ServerHello with a list of server supported protocols.
|
|
The flag <strong>-nextprotoneg</strong> cannot be specified if <strong>-tls1_3</strong> is used.</p>
|
|
</dd>
|
|
<dt><strong><a name="ct_noct" class="item"><strong>-ct</strong>, <strong>-noct</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Use one of these two options to control whether Certificate Transparency (CT)
|
|
is enabled (<strong>-ct</strong>) or disabled (<strong>-noct</strong>).
|
|
If CT is enabled, signed certificate timestamps (SCTs) will be requested from
|
|
the server and reported at handshake completion.</p>
|
|
<p>Enabling CT also enables OCSP stapling, as this is one possible delivery method
|
|
for SCTs.</p>
|
|
</dd>
|
|
<dt><strong><a name="ctlogfile" class="item"><strong>-ctlogfile</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>A file containing a list of known Certificate Transparency logs. See
|
|
<em>SSL_CTX_set_ctlog_list_file(3)</em> for the expected file format.</p>
|
|
</dd>
|
|
<dt><strong><a name="keylogfile_file" class="item"><strong>-keylogfile</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Appends TLS secrets to the specified keylog file such that external programs
|
|
(like Wireshark) can decrypt TLS connections.</p>
|
|
</dd>
|
|
<dt><strong><a name="early_data_file" class="item"><strong>-early_data</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Reads the contents of the specified file and attempts to send it as early data
|
|
to the server. This will only work with resumed sessions that support early
|
|
data and when the server accepts the early data.</p>
|
|
</dd>
|
|
<dt><strong><a name="enable_pha" class="item"><strong>-enable_pha</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>For TLSv1.3 only, send the Post-Handshake Authentication extension. This will
|
|
happen whether or not a certificate has been provided via <strong>-cert</strong>.</p>
|
|
</dd>
|
|
<dt><strong><a name="use_srtp_value" class="item"><strong>-use_srtp</strong> <em>value</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Offer SRTP key management, where <strong>value</strong> is a colon-separated profile list.</p>
|
|
</dd>
|
|
<dt><strong><a name="srpuser_value" class="item"><strong>-srpuser</strong> <em>value</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set the SRP username to the specified value.</p>
|
|
</dd>
|
|
<dt><strong><a name="srppass_value" class="item"><strong>-srppass</strong> <em>value</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set the SRP password to the specified value.</p>
|
|
</dd>
|
|
<dt><strong><a name="srp_lateuser" class="item"><strong>-srp_lateuser</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>SRP username for the second ClientHello message.</p>
|
|
</dd>
|
|
<dt><strong><a name="srp_moregroups" class="item"><strong>-srp_moregroups</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Tolerate other than the known <strong>g</strong> and <strong>N</strong> values.</p>
|
|
</dd>
|
|
<dt><strong><a name="srp_strength_number" class="item"><strong>-srp_strength</strong> <em>number</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set the minimal acceptable length, in bits, for <strong>N</strong>.</p>
|
|
</dd>
|
|
<dt><strong><a name="no_ssl3_no_tls1_no_tls1_1_no_tls1_2_no_tls1_3_ssl3_tls1_tls1_1_tls1_2_tls1_3" class="item"><strong>-no_ssl3</strong>, <strong>-no_tls1</strong>, <strong>-no_tls1_1</strong>, <strong>-no_tls1_2</strong>, <strong>-no_tls1_3</strong>,
|
|
<strong>-ssl3</strong>, <strong>-tls1</strong>, <strong>-tls1_1</strong>, <strong>-tls1_2</strong>, <strong>-tls1_3</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>See <em>openssl(1)/TLS Version Options</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="dtls_dtls1_dtls1_2" class="item"><strong>-dtls</strong>, <strong>-dtls1</strong>, <strong>-dtls1_2</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>These specify the use of DTLS instead of TLS.
|
|
See <em>openssl(1)/TLS Version Options</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="nameopt_option" class="item"><strong>-nameopt</strong> <em>option</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>This specifies how the subject or issuer names are displayed.
|
|
See <em>openssl(1)/Name Format Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="xkey_infile_xcert_file_xchain_file_xchain_build_file_xcertform_der_pem_xkeyform_der_pem" class="item"><strong>xkey</strong> <em>infile</em>, <strong>-xcert</strong> <em>file</em>, <strong>-xchain</strong> <em>file</em>,
|
|
<strong>-xchain_build</strong> <em>file</em>, <strong>-xcertform</strong> <strong>DER</strong>|<strong>PEM</strong>,
|
|
<strong>-xkeyform</strong> <strong>DER</strong>|<strong>PEM</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set extended certificate verification options.
|
|
See <em>openssl(1)/Extended Verification Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="cafile_file_no_cafile_capath_dir_no_capath_castore_uri_no_castore" class="item"><strong>-CAfile</strong> <em>file</em>, <strong>-no-CAfile</strong>, <strong>-CApath</strong> <em>dir</em>, <strong>-no-CApath</strong>,
|
|
<strong>-CAstore</strong> <em>uri</em>, <strong>-no-CAstore</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>See <em>openssl(1)/Trusted Certificate Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="bugs_comp_no_comp_no_ticket_serverpref_legacy_renegotiation_no_renegotiation_no_resumption_on_reneg_legacy_server_connect_no_legacy_server_connect_allow_no_dhe_kex_prioritize_chacha_strict_sigalgs_algs_client_sigalgs_algs_groups_groups_curves_curves_named_curve_curve_cipher_ciphers_ciphersuites_1_3ciphers_min_protocol_minprot_max_protocol_maxprot_record_padding_padding_debug_broken_protocol_no_middlebox" class="item"><strong>-bugs</strong>, <strong>-comp</strong>, <strong>-no_comp</strong>, <strong>-no_ticket</strong>, <strong>-serverpref</strong>,
|
|
<strong>-legacy_renegotiation</strong>, <strong>-no_renegotiation</strong>, <strong>-no_resumption_on_reneg</strong>,
|
|
<strong>-legacy_server_connect</strong>, <strong>-no_legacy_server_connect</strong>,
|
|
<strong>-allow_no_dhe_kex</strong>, <strong>-prioritize_chacha</strong>, <strong>-strict</strong>, <strong>-sigalgs</strong>
|
|
<em>algs</em>, <strong>-client_sigalgs</strong> <em>algs</em>, <strong>-groups</strong> <em>groups</em>, <strong>-curves</strong>
|
|
<em>curves</em>, <strong>-named_curve</strong> <em>curve</em>, <strong>-cipher</strong> <em>ciphers</em>, <strong>-ciphersuites</strong>
|
|
<em>1.3ciphers</em>, <strong>-min_protocol</strong> <em>minprot</em>, <strong>-max_protocol</strong> <em>maxprot</em>,
|
|
<strong>-record_padding</strong> <em>padding</em>, <strong>-debug_broken_protocol</strong>, <strong>-no_middlebox</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>See <em>SSL_CONF_cmd(3)/SUPPORTED COMMAND LINE COMMANDS</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="rand_files_writerand_file" class="item"><strong>-rand</strong> <em>files</em>, <strong>-writerand</strong> <em>file</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>See <em>openssl(1)/Random State Options</em> for details.</p>
|
|
</dd>
|
|
<dt><strong><a name="engine_id" class="item"><strong>-engine</strong> <em>id</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>See <em>openssl(1)/Engine Options</em>.</p>
|
|
</dd>
|
|
<dt><strong><a name="ssl_client_engine_id" class="item"><strong>-ssl_client_engine</strong> <em>id</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Specify engine to be used for client certificate operations.</p>
|
|
</dd>
|
|
<dt><strong><a name="allow_proxy_certs_attime_no_check_time_check_ss_sig_crl_check_crl_check_all_explicit_policy_extended_crl_ignore_critical_inhibit_any_inhibit_map_no_alt_chains_partial_chain_policy_policy_check_policy_print_purpose_suiteb_128_suiteb_128_only_suiteb_192_trusted_first_use_deltas_auth_level_verify_depth_verify_email_verify_hostname_verify_ip_verify_name_x509_strict_issuer_checks" class="item"><strong>-allow_proxy_certs</strong>, <strong>-attime</strong>, <strong>-no_check_time</strong>,
|
|
<strong>-check_ss_sig</strong>, <strong>-crl_check</strong>, <strong>-crl_check_all</strong>,
|
|
<strong>-explicit_policy</strong>, <strong>-extended_crl</strong>, <strong>-ignore_critical</strong>, <strong>-inhibit_any</strong>,
|
|
<strong>-inhibit_map</strong>, <strong>-no_alt_chains</strong>, <strong>-partial_chain</strong>, <strong>-policy</strong>,
|
|
<strong>-policy_check</strong>, <strong>-policy_print</strong>, <strong>-purpose</strong>, <strong>-suiteB_128</strong>,
|
|
<strong>-suiteB_128_only</strong>, <strong>-suiteB_192</strong>, <strong>-trusted_first</strong>, <strong>-use_deltas</strong>,
|
|
<strong>-auth_level</strong>, <strong>-verify_depth</strong>, <strong>-verify_email</strong>, <strong>-verify_hostname</strong>,
|
|
<strong>-verify_ip</strong>, <strong>-verify_name</strong>, <strong>-x509_strict</strong> <strong>-issuer_checks</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Set various options of certificate chain verification.
|
|
See <em>openssl(1)/Verification Options</em> for details.</p>
|
|
<p>Verification errors are displayed, for debugging, but the command will
|
|
proceed unless the <strong>-verify_return_error</strong> option is used.</p>
|
|
</dd>
|
|
<dt><strong><a name="host_port" class="item"><em>host</em>:<em>port</em></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Rather than providing <strong>-connect</strong>, the target hostname and optional port may
|
|
be provided as a single positional argument after all options. If neither this
|
|
nor <strong>-connect</strong> are provided, falls back to attempting to connect to
|
|
<em>localhost</em> on port <em>4433</em>.</p>
|
|
</dd>
|
|
</dl>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="connected_commands">CONNECTED COMMANDS</a></h1>
|
|
<p>If a connection is established with an SSL server then any data received
|
|
from the server is displayed and any key presses will be sent to the
|
|
server. If end of file is reached then the connection will be closed down. When
|
|
used interactively (which means neither <strong>-quiet</strong> nor <strong>-ign_eof</strong> have been
|
|
given), then certain commands are also recognized which perform special
|
|
operations. These commands are a letter which must appear at the start of a
|
|
line. They are listed below.</p>
|
|
<dl>
|
|
<dt><strong><a name="q" class="item"><strong>Q</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>End the current SSL connection and exit.</p>
|
|
</dd>
|
|
<dt><strong><a name="r" class="item"><strong>R</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Renegotiate the SSL session (TLSv1.2 and below only).</p>
|
|
</dd>
|
|
<dt><strong><a name="k" class="item"><strong>k</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Send a key update message to the server (TLSv1.3 only)</p>
|
|
</dd>
|
|
<dt><strong><a name="k" class="item"><strong>K</strong></a></strong></dt>
|
|
|
|
<dd>
|
|
<p>Send a key update message to the server and request one back (TLSv1.3 only)</p>
|
|
</dd>
|
|
</dl>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="notes">NOTES</a></h1>
|
|
<p>This command can be used to debug SSL servers. To connect to an SSL HTTP
|
|
server the command:</p>
|
|
<pre>
|
|
openssl s_client -connect servername:443</pre>
|
|
<p>would typically be used (https uses port 443). If the connection succeeds
|
|
then an HTTP command can be given such as "GET /" to retrieve a web page.</p>
|
|
<p>If the handshake fails then there are several possible causes, if it is
|
|
nothing obvious like no client certificate then the <strong>-bugs</strong>,
|
|
<strong>-ssl3</strong>, <strong>-tls1</strong>, <strong>-no_ssl3</strong>, <strong>-no_tls1</strong> options can be tried
|
|
in case it is a buggy server. In particular you should play with these
|
|
options <strong>before</strong> submitting a bug report to an OpenSSL mailing list.</p>
|
|
<p>A frequent problem when attempting to get client certificates working
|
|
is that a web client complains it has no certificates or gives an empty
|
|
list to choose from. This is normally because the server is not sending
|
|
the clients certificate authority in its "acceptable CA list" when it
|
|
requests a certificate. By using this command, the CA list can be viewed
|
|
and checked. However some servers only request client authentication
|
|
after a specific URL is requested. To obtain the list in this case it
|
|
is necessary to use the <strong>-prexit</strong> option and send an HTTP request
|
|
for an appropriate page.</p>
|
|
<p>If a certificate is specified on the command line using the <strong>-cert</strong>
|
|
option it will not be used unless the server specifically requests
|
|
a client certificate. Therefor merely including a client certificate
|
|
on the command line is no guarantee that the certificate works.</p>
|
|
<p>If there are problems verifying a server certificate then the
|
|
<strong>-showcerts</strong> option can be used to show all the certificates sent by the
|
|
server.</p>
|
|
<p>This command is a test tool and is designed to continue the
|
|
handshake after any certificate verification errors. As a result it will
|
|
accept any certificate chain (trusted or not) sent by the peer. None test
|
|
applications should <strong>not</strong> do this as it makes them vulnerable to a MITM
|
|
attack. This behaviour can be changed by with the <strong>-verify_return_error</strong>
|
|
option: any verify errors are then returned aborting the handshake.</p>
|
|
<p>The <strong>-bind</strong> option may be useful if the server or a firewall requires
|
|
connections to come from some particular address and or port.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="bugs">BUGS</a></h1>
|
|
<p>Because this program has a lot of options and also because some of the
|
|
techniques used are rather old, the C source for this command is rather
|
|
hard to read and not a model of how things should be done.
|
|
A typical SSL client program would be much simpler.</p>
|
|
<p>The <strong>-prexit</strong> option is a bit of a hack. We should really report
|
|
information whenever a session is renegotiated.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="see_also">SEE ALSO</a></h1>
|
|
<p><em>openssl(1)</em>,
|
|
<em>openssl-sess_id(1)</em>,
|
|
<em>openssl-s_server(1)</em>,
|
|
<em>openssl-ciphers(1)</em>,
|
|
<em>SSL_CONF_cmd(3)</em>,
|
|
<em>SSL_CTX_set_max_send_fragment(3)</em>,
|
|
<em>SSL_CTX_set_split_send_fragment(3)</em>,
|
|
<em>SSL_CTX_set_max_pipelines(3)</em>,
|
|
<em>ossl_store-file(7)</em></p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="history">HISTORY</a></h1>
|
|
<p>The <strong>-no_alt_chains</strong> option was added in OpenSSL 1.1.0.
|
|
The <strong>-name</strong> option was added in OpenSSL 1.1.1.</p>
|
|
<p>
|
|
</p>
|
|
<hr />
|
|
<h1><a name="copyright">COPYRIGHT</a></h1>
|
|
<p>Copyright 2000-2019 The OpenSSL Project Authors. All Rights Reserved.</p>
|
|
<p>Licensed under the Apache License 2.0 (the "License"). You may not use
|
|
this file except in compliance with the License. You can obtain a copy
|
|
in the file LICENSE in the source distribution or at
|
|
<a href="https://www.openssl.org/source/license.html">https://www.openssl.org/source/license.html</a>.</p>
|
|
|
|
</body>
|
|
|
|
</html>
|