0
$\begingroup$

For example, if we grab 50 bytes from a high quality source and run them through a key stretching function like Argon2 and have it generate a 32 byte secret for AES.

Is there any downside to this? Do we lose any entropy during this process since it comes from a high quality source already?

$\endgroup$

1 Answer 1

5
$\begingroup$

Even with perfectly random input, if your final key size is 32 bytes, you cannot have more than 32 bytes of entropy in it.

But it seems pretty useless to use key stretching if you already have more random bytes than your key length, you could just use 32 bytes of your 'perfect' source as an AES key. You just expose yourself to possible weakness in the key stretching algorithm without any benefit.

$\endgroup$
1
  • $\begingroup$ These were my initial thoughts, as well. Unless you're accepting low quality input (ie: passwords), then it feels pretty useless to do any key stretching. $\endgroup$
    – Tuxxy
    Mar 1, 2017 at 18:58

Your Answer

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

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