1
$\begingroup$

Am I correct in assuming that HMAC_DRBG would return different results if I, e.g. first request 4 bytes followed by a request of another 4 bytes instead of asking for 8 bytes at once?

It seems that in NIST SP800-90A chapter 10.1.2.5: Generating Pseudorandom Bits Using HMAC_DRBG first the K and V values are changed, then the requested number of bits is generated (changing just V), and then the K and V values are changed again. Besides that, leftover bits get chucked away as well.

Isn't it a strange property for a DRNG to return different value if DRNG(4) || DRNG(4) != DRNG(8) if the DRNG is not reseeded in between? Do other DRNG's have the same kind of property?

$\endgroup$
1
  • $\begingroup$ Or maybe I'm just too used to the properties of KBKDFs :) $\endgroup$
    – Maarten Bodewes
    Commented Oct 16, 2014 at 22:40

1 Answer 1

2
$\begingroup$

Yes, you are reading this right. The requests for random value from NIST 800-90 drbgs perturbed the state. If this is a problem you can add a layer that optionally buffers values and always makes constant size requests.

$\endgroup$
1
  • $\begingroup$ Whoops, waited a bit too long for other possible answers, sorry about that :) $\endgroup$
    – Maarten Bodewes
    Commented Oct 23, 2014 at 22:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.