diff options
author | Dmitry Belyavskiy <beldmit@gmail.com> | 2017-02-21 14:22:55 +0300 |
---|---|---|
committer | Rich Salz <rsalz@openssl.org> | 2017-02-21 13:50:00 -0500 |
commit | a7c04f2b540cce99055326a3ab932032bdf48cf5 (patch) | |
tree | 09800f489155c1ea78e9bd0e70f602b54b81efa6 /apps/s_time.c | |
parent | ecca16632a73bb80ee27cdec8a97f6def0a4714d (diff) | |
download | openssl-a7c04f2b540cce99055326a3ab932032bdf48cf5.zip openssl-a7c04f2b540cce99055326a3ab932032bdf48cf5.tar.gz openssl-a7c04f2b540cce99055326a3ab932032bdf48cf5.tar.bz2 |
Provided support for the -nameopt flag in s_client, s_server and s_time
commands.
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/2695)
Diffstat (limited to 'apps/s_time.c')
-rw-r--r-- | apps/s_time.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/apps/s_time.c b/apps/s_time.c index 315f69d..998ef72 100644 --- a/apps/s_time.c +++ b/apps/s_time.c @@ -53,7 +53,7 @@ static const char fmt_http_get_cmd[] = "GET %s HTTP/1.0\r\n\r\n"; typedef enum OPTION_choice { OPT_ERR = -1, OPT_EOF = 0, OPT_HELP, - OPT_CONNECT, OPT_CIPHER, OPT_CERT, OPT_KEY, OPT_CAPATH, + OPT_CONNECT, OPT_CIPHER, OPT_CERT, OPT_NAMEOPT, OPT_KEY, OPT_CAPATH, OPT_CAFILE, OPT_NOCAPATH, OPT_NOCAFILE, OPT_NEW, OPT_REUSE, OPT_BUGS, OPT_VERIFY, OPT_TIME, OPT_SSL3, OPT_WWW @@ -65,6 +65,7 @@ const OPTIONS s_time_options[] = { "Where to connect as post:port (default is " SSL_CONNECT_NAME ")"}, {"cipher", OPT_CIPHER, 's', "Cipher to use, see 'openssl ciphers'"}, {"cert", OPT_CERT, '<', "Cert file to use, PEM format assumed"}, + {"nameopt", OPT_NAMEOPT, 's', "Various certificate name options"}, {"key", OPT_KEY, '<', "File with key, PEM; default is -cert file"}, {"CApath", OPT_CAPATH, '/', "PEM format directory of CA's"}, {"cafile", OPT_CAFILE, '<', "PEM format file of CA's"}, @@ -141,6 +142,10 @@ int s_time_main(int argc, char **argv) case OPT_CERT: certfile = opt_arg(); break; + case OPT_NAMEOPT: + if (!set_nameopt(opt_arg())) + goto end; + break; case OPT_KEY: keyfile = opt_arg(); break; |