mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-28 14:23:30 +01:00
Split 0119_PARANOIA into 0119_PARANOIA_[ABC]. A is "this is suspicious, and we have not tried running without this yet". B is "this is suspicious, but the last time we tested, it was okay." C is "How could this possibly be the cause?"
svn:r5840
This commit is contained in:
parent
2be4f537f7
commit
241310bbac
@ -228,7 +228,7 @@ crypto_global_init(int useAccel)
|
|||||||
void
|
void
|
||||||
crypto_thread_cleanup(void)
|
crypto_thread_cleanup(void)
|
||||||
{
|
{
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_B
|
||||||
ERR_remove_state(0);
|
ERR_remove_state(0);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@ -239,13 +239,13 @@ int
|
|||||||
crypto_global_cleanup(void)
|
crypto_global_cleanup(void)
|
||||||
{
|
{
|
||||||
EVP_cleanup();
|
EVP_cleanup();
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_C
|
||||||
ERR_remove_state(0);
|
ERR_remove_state(0);
|
||||||
#endif
|
#endif
|
||||||
ERR_free_strings();
|
ERR_free_strings();
|
||||||
#ifndef NO_ENGINES
|
#ifndef NO_ENGINES
|
||||||
ENGINE_cleanup();
|
ENGINE_cleanup();
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_C
|
||||||
CONF_modules_unload(1);
|
CONF_modules_unload(1);
|
||||||
CRYPTO_cleanup_all_ex_data();
|
CRYPTO_cleanup_all_ex_data();
|
||||||
#endif
|
#endif
|
||||||
@ -1381,7 +1381,7 @@ crypto_dh_new(void)
|
|||||||
if (!(res->dh->g = BN_dup(dh_param_g)))
|
if (!(res->dh->g = BN_dup(dh_param_g)))
|
||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_A
|
||||||
res->dh->length = DH_PRIVATE_KEY_BITS;
|
res->dh->length = DH_PRIVATE_KEY_BITS;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -1610,7 +1610,7 @@ crypto_dh_free(crypto_dh_env_t *dh)
|
|||||||
|
|
||||||
/* Use RAND_poll if openssl is 0.9.6 release or later. (The "f" means
|
/* Use RAND_poll if openssl is 0.9.6 release or later. (The "f" means
|
||||||
"release".) */
|
"release".) */
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_B
|
||||||
#define USE_RAND_POLL (OPENSSL_VERSION_NUMBER >= 0x0090600fl)
|
#define USE_RAND_POLL (OPENSSL_VERSION_NUMBER >= 0x0090600fl)
|
||||||
#else
|
#else
|
||||||
#define USE_RAND_POLL 0
|
#define USE_RAND_POLL 0
|
||||||
|
@ -15,7 +15,9 @@
|
|||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
#undef ENABLE_0119_PARANOIA
|
#undef ENABLE_0119_PARANOIA_A
|
||||||
|
#undef ENABLE_0119_PARANOIA_B
|
||||||
|
#undef ENABLE_0119_PARANOIA_C
|
||||||
|
|
||||||
/** Length of the output of our message digest. */
|
/** Length of the output of our message digest. */
|
||||||
#define DIGEST_LEN 20
|
#define DIGEST_LEN 20
|
||||||
|
@ -363,7 +363,7 @@ tor_tls_context_new(crypto_pk_env_t *identity,
|
|||||||
goto error;
|
goto error;
|
||||||
SSL_CTX_set_options(*ctx, SSL_OP_NO_SSLv2);
|
SSL_CTX_set_options(*ctx, SSL_OP_NO_SSLv2);
|
||||||
#endif
|
#endif
|
||||||
#ifndef ENABLE_0119_PARANOIA
|
#ifndef ENABLE_0119_PARANOIA_A
|
||||||
SSL_CTX_set_options(*ctx, SSL_OP_SINGLE_DH_USE);
|
SSL_CTX_set_options(*ctx, SSL_OP_SINGLE_DH_USE);
|
||||||
#endif
|
#endif
|
||||||
if (!SSL_CTX_set_cipher_list(*ctx, CIPHER_LIST))
|
if (!SSL_CTX_set_cipher_list(*ctx, CIPHER_LIST))
|
||||||
|
Loading…
Reference in New Issue
Block a user