mirror of
https://github.com/QuasarApp/openssl.git
synced 2025-05-14 02:19:39 +00:00
Check reseed interval before generating output.
This commit is contained in:
parent
7634137b8a
commit
ea17b0feec
@ -373,6 +373,9 @@ int FIPS_drbg_generate(DRBG_CTX *dctx, unsigned char *out, size_t outlen,
|
|||||||
goto end;
|
goto end;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (dctx->reseed_counter >= dctx->reseed_interval)
|
||||||
|
dctx->status = DRBG_STATUS_RESEED;
|
||||||
|
|
||||||
if (dctx->status == DRBG_STATUS_RESEED || prediction_resistance)
|
if (dctx->status == DRBG_STATUS_RESEED || prediction_resistance)
|
||||||
{
|
{
|
||||||
if (!FIPS_drbg_reseed(dctx, adin, adinlen))
|
if (!FIPS_drbg_reseed(dctx, adin, adinlen))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user