Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 99c9acfe authored by Łukasz Stelmach's avatar Łukasz Stelmach Committed by Herbert Xu
Browse files

crypto: exynos - Reseed PRNG after generating 2^16 random bytes



Reseed PRNG after reading 65 kB of randomness. Although this may reduce
performance, in most cases the loss is not noticeable. Also the time
based threshold for reseeding is changed to one second. Reseeding is
performed whenever either limit is exceeded.

Reseeding of a PRNG does not increase entropy, but it helps preventing
backtracking the internal state of the device from its output sequence,
and hence, prevents potential attacker from predicting numbers to be
generated.

Signed-off-by: default avatarŁukasz Stelmach <l.stelmach@samsung.com>
Reviewed-by: default avatarStephan Mueller <smueller@chronox.de>
Reviewed-by: default avatarKrzysztof Kozlowski <krzk@kernel.org>
Signed-off-by: default avatarHerbert Xu <herbert@gondor.apana.org.au>
parent 3a5a5e5c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment