Loading apps/speed.c −10 Changes for apps/speed.c: 0 added lines, 10 removed lines. Original line number Diff line number Diff line Loading @@ -313,7 +313,6 @@ static double ecdh_results[EC_NUM][1]; #if !defined(OPENSSL_NO_DSA) || !defined(OPENSSL_NO_EC) static const char rnd_seed[] = "string to make the random number generator think it has entropy"; static int rnd_fake = 0; #endif #ifdef SIGALRM Loading Loading @@ -2448,7 +2447,6 @@ int speed_main(int argc, char **argv) #ifndef OPENSSL_NO_DSA if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < DSA_NUM; testnum++) { int st = 0; Loading Loading @@ -2512,14 +2510,11 @@ int speed_main(int argc, char **argv) dsa_doit[testnum] = 0; } } if (rnd_fake) RAND_cleanup(); #endif #ifndef OPENSSL_NO_EC if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < EC_NUM; testnum++) { int st = 1; Loading Loading @@ -2601,14 +2596,11 @@ int speed_main(int argc, char **argv) } } } if (rnd_fake) RAND_cleanup(); #endif #ifndef OPENSSL_NO_EC if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < EC_NUM; testnum++) { if (!ecdh_doit[testnum]) Loading Loading @@ -2700,8 +2692,6 @@ int speed_main(int argc, char **argv) ecdh_doit[testnum] = 0; } } if (rnd_fake) RAND_cleanup(); #endif #ifndef NO_FORK show_res: Loading apps/testdsa.h −3 Changes for apps/testdsa.h: 0 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -328,6 +328,3 @@ DSA *get_dsa2048() return NULL; } static const char rnd_seed[] = "string to make the random number generator think it has entropy"; static int rnd_fake = 0; crypto/include/internal/rand.h +11 Changes for crypto/include/internal/rand.h: 11 added lines, 0 removed lines. Original line number Diff line number Diff line /* * Licensed under the OpenSSL licenses, (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * https://www.openssl.org/source/license.html * or in the file LICENSE in the source distribution. */ #include <openssl/rand.h> void rand_cleanup_intern(void); crypto/init.c +5 −5 Changes for crypto/init.c: 5 added lines, 5 removed lines. Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ #include <internal/threads.h> #include <internal/cryptlib_int.h> #include <openssl/err.h> #include <openssl/rand.h> #include <internal/rand.h> #include <openssl/evp.h> #include <internal/evp_int.h> #include <internal/conf.h> Loading Loading @@ -453,7 +453,7 @@ void OPENSSL_cleanup(void) #ifdef OPENSSL_INIT_DEBUG fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: " "RAND_cleanup()\n"); "rand_cleanup_intern()\n"); fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: " "CONF_modules_free()\n"); #ifndef OPENSSL_NO_ENGINE Loading @@ -471,14 +471,14 @@ void OPENSSL_cleanup(void) #endif /* * Note that cleanup order is important: * - RAND_cleanup could call an ENINGE's RAND cleanup function so must be * called before ENGINE_cleanup() * - rand_cleanup_intern could call an ENINGE's RAND cleanup function so * must be called before ENGINE_cleanup() * - ENGINEs use CRYPTO_EX_DATA and therefore, must be cleaned up * before the ex data handlers are wiped in CRYPTO_cleanup_all_ex_data(). * - CONF_modules_free() can end up in ENGINE code so must be called before * ENGINE_cleanup() */ RAND_cleanup(); rand_cleanup_intern(); CONF_modules_free(); #ifndef OPENSSL_NO_ENGINE ENGINE_cleanup(); Loading crypto/rand/rand_lib.c +2 −2 Changes for crypto/rand/rand_lib.c: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ #include <time.h> #include "internal/cryptlib.h" #include <openssl/opensslconf.h> #include <openssl/rand.h> #include "internal/rand.h" #include <openssl/engine.h> Loading Loading @@ -125,7 +125,7 @@ int RAND_set_rand_engine(ENGINE *engine) } #endif void RAND_cleanup(void) void rand_cleanup_intern(void) { const RAND_METHOD *meth = RAND_get_rand_method(); if (meth && meth->cleanup) Loading Loading
apps/speed.c −10 Changes for apps/speed.c: 0 added lines, 10 removed lines. Original line number Diff line number Diff line Loading @@ -313,7 +313,6 @@ static double ecdh_results[EC_NUM][1]; #if !defined(OPENSSL_NO_DSA) || !defined(OPENSSL_NO_EC) static const char rnd_seed[] = "string to make the random number generator think it has entropy"; static int rnd_fake = 0; #endif #ifdef SIGALRM Loading Loading @@ -2448,7 +2447,6 @@ int speed_main(int argc, char **argv) #ifndef OPENSSL_NO_DSA if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < DSA_NUM; testnum++) { int st = 0; Loading Loading @@ -2512,14 +2510,11 @@ int speed_main(int argc, char **argv) dsa_doit[testnum] = 0; } } if (rnd_fake) RAND_cleanup(); #endif #ifndef OPENSSL_NO_EC if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < EC_NUM; testnum++) { int st = 1; Loading Loading @@ -2601,14 +2596,11 @@ int speed_main(int argc, char **argv) } } } if (rnd_fake) RAND_cleanup(); #endif #ifndef OPENSSL_NO_EC if (RAND_status() != 1) { RAND_seed(rnd_seed, sizeof rnd_seed); rnd_fake = 1; } for (testnum = 0; testnum < EC_NUM; testnum++) { if (!ecdh_doit[testnum]) Loading Loading @@ -2700,8 +2692,6 @@ int speed_main(int argc, char **argv) ecdh_doit[testnum] = 0; } } if (rnd_fake) RAND_cleanup(); #endif #ifndef NO_FORK show_res: Loading
apps/testdsa.h −3 Changes for apps/testdsa.h: 0 added lines, 3 removed lines. Original line number Diff line number Diff line Loading @@ -328,6 +328,3 @@ DSA *get_dsa2048() return NULL; } static const char rnd_seed[] = "string to make the random number generator think it has entropy"; static int rnd_fake = 0;
crypto/include/internal/rand.h +11 Changes for crypto/include/internal/rand.h: 11 added lines, 0 removed lines. Original line number Diff line number Diff line /* * Licensed under the OpenSSL licenses, (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * https://www.openssl.org/source/license.html * or in the file LICENSE in the source distribution. */ #include <openssl/rand.h> void rand_cleanup_intern(void);
crypto/init.c +5 −5 Changes for crypto/init.c: 5 added lines, 5 removed lines. Original line number Diff line number Diff line Loading @@ -58,7 +58,7 @@ #include <internal/threads.h> #include <internal/cryptlib_int.h> #include <openssl/err.h> #include <openssl/rand.h> #include <internal/rand.h> #include <openssl/evp.h> #include <internal/evp_int.h> #include <internal/conf.h> Loading Loading @@ -453,7 +453,7 @@ void OPENSSL_cleanup(void) #ifdef OPENSSL_INIT_DEBUG fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: " "RAND_cleanup()\n"); "rand_cleanup_intern()\n"); fprintf(stderr, "OPENSSL_INIT: OPENSSL_cleanup: " "CONF_modules_free()\n"); #ifndef OPENSSL_NO_ENGINE Loading @@ -471,14 +471,14 @@ void OPENSSL_cleanup(void) #endif /* * Note that cleanup order is important: * - RAND_cleanup could call an ENINGE's RAND cleanup function so must be * called before ENGINE_cleanup() * - rand_cleanup_intern could call an ENINGE's RAND cleanup function so * must be called before ENGINE_cleanup() * - ENGINEs use CRYPTO_EX_DATA and therefore, must be cleaned up * before the ex data handlers are wiped in CRYPTO_cleanup_all_ex_data(). * - CONF_modules_free() can end up in ENGINE code so must be called before * ENGINE_cleanup() */ RAND_cleanup(); rand_cleanup_intern(); CONF_modules_free(); #ifndef OPENSSL_NO_ENGINE ENGINE_cleanup(); Loading
crypto/rand/rand_lib.c +2 −2 Changes for crypto/rand/rand_lib.c: 2 added lines, 2 removed lines. Original line number Diff line number Diff line Loading @@ -59,7 +59,7 @@ #include <time.h> #include "internal/cryptlib.h" #include <openssl/opensslconf.h> #include <openssl/rand.h> #include "internal/rand.h" #include <openssl/engine.h> Loading Loading @@ -125,7 +125,7 @@ int RAND_set_rand_engine(ENGINE *engine) } #endif void RAND_cleanup(void) void rand_cleanup_intern(void) { const RAND_METHOD *meth = RAND_get_rand_method(); if (meth && meth->cleanup) Loading