From: deraadt Date: Thu, 17 Apr 2014 12:42:43 +0000 (+0000) Subject: RAND_seed now does nothing, so skip the operation X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=de2f1b52b8f6e065479b60c81d400a4c3735df4a;p=openbsd RAND_seed now does nothing, so skip the operation --- diff --git a/lib/libcrypto/bn/expspeed.c b/lib/libcrypto/bn/expspeed.c index 4d5f221f33a..1b434db1ab9 100644 --- a/lib/libcrypto/bn/expspeed.c +++ b/lib/libcrypto/bn/expspeed.c @@ -195,8 +195,6 @@ static int sizes[NUM_SIZES]={128,256,512,1024,2048,4096,8192}; static int mul_c[NUM_SIZES]={8*8*8*8*8*8,8*8*8*8*8,8*8*8*8,8*8*8,8*8,8,1}; /*static int sizes[NUM_SIZES]={59,179,299,419,539}; */ -#define RAND_SEED(string) { const char str[] = string; RAND_seed(string, sizeof str); } - void do_mul_exp(BIGNUM *r,BIGNUM *a,BIGNUM *b,BIGNUM *c,BN_CTX *ctx); int main(int argc, char **argv) @@ -215,10 +213,6 @@ int main(int argc, char **argv) c=BN_new(); r=BN_new(); - while (!RAND_status()) - /* not enough bits */ - RAND_SEED("I demand a manual recount!"); - do_mul_exp(r,a,b,c,ctx); return 0; } diff --git a/lib/libssl/src/crypto/bn/expspeed.c b/lib/libssl/src/crypto/bn/expspeed.c index 4d5f221f33a..1b434db1ab9 100644 --- a/lib/libssl/src/crypto/bn/expspeed.c +++ b/lib/libssl/src/crypto/bn/expspeed.c @@ -195,8 +195,6 @@ static int sizes[NUM_SIZES]={128,256,512,1024,2048,4096,8192}; static int mul_c[NUM_SIZES]={8*8*8*8*8*8,8*8*8*8*8,8*8*8*8,8*8*8,8*8,8,1}; /*static int sizes[NUM_SIZES]={59,179,299,419,539}; */ -#define RAND_SEED(string) { const char str[] = string; RAND_seed(string, sizeof str); } - void do_mul_exp(BIGNUM *r,BIGNUM *a,BIGNUM *b,BIGNUM *c,BN_CTX *ctx); int main(int argc, char **argv) @@ -215,10 +213,6 @@ int main(int argc, char **argv) c=BN_new(); r=BN_new(); - while (!RAND_status()) - /* not enough bits */ - RAND_SEED("I demand a manual recount!"); - do_mul_exp(r,a,b,c,ctx); return 0; }