Switch from ossl_rand to DRBG rand
[oweals/openssl.git] / crypto / bn / bn_rand.c
index a7c7309888fd57124b8364c464deb41814380585..0b9e43dbdd2eec57365b4f00802571ac980ac8ce 100644 (file)
@@ -18,7 +18,6 @@ static int bnrand(int testing, BIGNUM *rnd, int bits, int top, int bottom)
 {
     unsigned char *buf = NULL;
     int ret = 0, bit, bytes, mask;
-    time_t tim;
 
     if (bits == 0) {
         if (top != BN_RAND_TOP_ANY || bottom != BN_RAND_BOTTOM_ANY)
@@ -40,9 +39,6 @@ static int bnrand(int testing, BIGNUM *rnd, int bits, int top, int bottom)
     }
 
     /* make a random number and set the top and bottom bits */
-    time(&tim);
-    RAND_add(&tim, sizeof(tim), 0.0);
-
     if (RAND_bytes(buf, bytes) <= 0)
         goto err;