Fix intermittent s_server issues with ECDHE
authorJohn Foley <foleyj@cisco.com>
Tue, 7 Apr 2015 22:05:05 +0000 (23:05 +0100)
committerMatt Caswell <matt@openssl.org>
Tue, 7 Apr 2015 22:37:46 +0000 (23:37 +0100)
Resolve a problem when using s_server with ECDHE cipher
suites in OpenSSL_1_0_1-stable.  Due to an uninitialized variable,
SSL_CTX_set_tmp_ecdh() is not always invoked within s_server. This bug
appears to have been introduced by
059907771b89549cbd07a81df1a5bdf51e062066.

Reviewed-by: Tim Hudson <tjh@openssl.org>
apps/s_server.c

index 1220f49d6f6481ec7cb2695b1e9e49cfde07737b..35b4061e89ce1b3fad0c506aea447333849d792c 100644 (file)
@@ -998,7 +998,7 @@ int MAIN(int argc, char *argv[])
     int off = 0;
     int no_tmp_rsa = 0, no_dhe = 0, nocert = 0;
 #ifndef OPENSSL_NO_ECDH
-    int no_ecdhe;
+    int no_ecdhe = 0;
 #endif
     int state = 0;
     const SSL_METHOD *meth = NULL;