0
$\begingroup$

16 byte key where each byte is in range 0-255, generated using cryptograhic PRNG will be believed to have 128 bit strength.

What would be a bit strength of a key generated using same quality PRNG, also of 16 byte length, if each byte instead of being one of 256 random values, would be one of 16 hexadecimal characters?

Would that be calculated as (128 x 16) / 256 = 8 bit?

$\endgroup$
1
  • $\begingroup$ What is the purpose of generating crippled random bytes? $\endgroup$ – kelalaka Oct 27 '20 at 21:34
2
$\begingroup$

One hexadecimal digit is equivalent to 4 bits, so 16 of them would be 16 * 4 = 64 bits.

Intuitively, since one hexadecimal digit takes up exactly half an octet, your bit strength compared to using the full octet is also halved, so 128 / 2 = 64.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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