[openssl-commits] [openssl] master update

Rich Salz rsalz at openssl.org
Sun Aug 13 21:35:55 UTC 2017


The branch master has been updated
       via  bc5145e372db24e8382c34fd191614805164b28b (commit)
      from  bdcacd93b14ed7381a922b41d74c481224ef9fa1 (commit)


- Log -----------------------------------------------------------------
commit bc5145e372db24e8382c34fd191614805164b28b
Author: Rich Salz <rsalz at openssl.org>
Date:   Sat Aug 12 18:19:50 2017 -0400

    Instantiate when RAND_status() checks
    
    Reviewed-by: Kurt Roeckx <kurt at roeckx.be>
    (Merged from https://github.com/openssl/openssl/pull/4150)

-----------------------------------------------------------------------

Summary of changes:
 crypto/rand/drbg_lib.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/crypto/rand/drbg_lib.c b/crypto/rand/drbg_lib.c
index e9502db..0da4d48 100644
--- a/crypto/rand/drbg_lib.c
+++ b/crypto/rand/drbg_lib.c
@@ -403,6 +403,8 @@ static int drbg_status(void)
     int ret;
 
     CRYPTO_THREAD_write_lock(rand_drbg.lock);
+    if (rand_drbg.state == DRBG_UNINITIALISED)
+        RAND_DRBG_instantiate(&rand_drbg, NULL, 0);
     ret = rand_drbg.state == DRBG_READY ? 1 : 0;
     CRYPTO_THREAD_unlock(rand_drbg.lock);
     return ret;


More information about the openssl-commits mailing list