The question
There are limits to how much you can use a the DRBG before you have to reseed it. But, but are there any limits to how much you must use it before reseeding?
Take the following following scenarios as an example.example…
seed = seedFromUrandom // Reads entropy from /dev/urandom
genStart = drbgFromSeed seed
(v1, gen1) = genBytes genStart // Generates random data and the next state
// of the DRBG as a tuple
/*
Code using the random data in v1
*/
(v2, gen2) = genBytes gen1 // Generates more random data and the next state
// of the DRBG as a tuple. Note that gen1 is
// used here and not genStart.
/*
Code using the random data in v2
*/
seed = seedFromUrandom // Reads entropy from /dev/urandom
genStart = drbgFromSeed seed
(v1, _) = genBytes genStart // Generates random data and ignores the
// next instance of the DRBG.
/*
Code using the random data in v1
*/
seed = seedFromUrandom // Reads entropy from /dev/urandom
genStart = drbgFromSeed seed
(v2, _) = genBytes genStart // Generates random data and ignores the
// next instance of the DRBG.
/*
Code using the random data in v2
*/
Background information
When I say DRBG I mean the NIST standardized number-theoretically secure random number generator. Either HMAC (SHA512), Hash (SHA512) or counter (AES 128).Please note:
Like stated in the pseudo-code entropy is read from /dev/urandom
- When I say “DRBG”, I mean the NIST standardized number-theoretically secure random number generator. Either HMAC (SHA512), Hash (SHA512), or counter (AES 128).
- Like stated in the pseudo-code, entropy is read from
/dev/urandom
.