diff options
author | Matt Caswell <matt@openssl.org> | 2017-06-13 15:28:45 +0200 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2017-06-21 15:45:35 +0200 |
commit | 14e353506a8a255c31b5b6b7520e00ed323d5a13 (patch) | |
tree | 4f20dca0ac4ef1efe10486873e52ab9734dd6c4c /apps/s_client.c | |
parent | Add the ability to set a TLSv1.3 PSK via just the key bytes (diff) | |
download | openssl-14e353506a8a255c31b5b6b7520e00ed323d5a13.tar.xz openssl-14e353506a8a255c31b5b6b7520e00ed323d5a13.zip |
Fix no-psk
Broken through previous PSK related commits
Reviewed-by: Rich Salz <rsalz@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/3670)
Diffstat (limited to 'apps/s_client.c')
-rw-r--r-- | apps/s_client.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/apps/s_client.c b/apps/s_client.c index f84ae2b4b3..df33e0a596 100644 --- a/apps/s_client.c +++ b/apps/s_client.c @@ -109,10 +109,10 @@ static void do_ssl_shutdown(SSL *ssl) } while (ret < 0); } -#ifndef OPENSSL_NO_PSK /* Default PSK identity and key */ static char *psk_identity = "Client_identity"; +#ifndef OPENSSL_NO_PSK static unsigned int psk_client_cb(SSL *ssl, const char *hint, char *identity, unsigned int max_identity_len, unsigned char *psk, @@ -570,9 +570,7 @@ typedef enum OPTION_choice { OPT_DEBUG, OPT_TLSEXTDEBUG, OPT_STATUS, OPT_WDEBUG, OPT_MSG, OPT_MSGFILE, OPT_ENGINE, OPT_TRACE, OPT_SECURITY_DEBUG, OPT_SECURITY_DEBUG_VERBOSE, OPT_SHOWCERTS, OPT_NBIO_TEST, OPT_STATE, -#ifndef OPENSSL_NO_PSK OPT_PSK_IDENTITY, OPT_PSK, -#endif OPT_PSK_SESS, #ifndef OPENSSL_NO_SRP OPT_SRPUSER, OPT_SRPPASS, OPT_SRP_STRENGTH, OPT_SRP_LATEUSER, @@ -752,10 +750,8 @@ const OPTIONS s_client_options[] = { {"wdebug", OPT_WDEBUG, '-', "WATT-32 tcp debugging"}, #endif {"nbio", OPT_NBIO, '-', "Use non-blocking IO"}, -#ifndef OPENSSL_NO_PSK {"psk_identity", OPT_PSK_IDENTITY, 's', "PSK identity"}, {"psk", OPT_PSK, 's', "PSK in hex (without 0x)"}, -#endif {"psk_session", OPT_PSK_SESS, '<', "File to read PSK SSL session from"}, #ifndef OPENSSL_NO_SRP {"srpuser", OPT_SRPUSER, 's', "SRP authentication for 'user'"}, @@ -1202,7 +1198,6 @@ int s_client_main(int argc, char **argv) case OPT_STATE: state = 1; break; -#ifndef OPENSSL_NO_PSK case OPT_PSK_IDENTITY: psk_identity = opt_arg(); break; @@ -1214,7 +1209,6 @@ int s_client_main(int argc, char **argv) goto end; } break; -#endif case OPT_PSK_SESS: psksessf = opt_arg(); break; |