[issue21470] Better seeding for the random module

Charles-François Natali report at bugs.python.org
Tue May 13 11:46:00 CEST 2014


Charles-François Natali added the comment:

> According to man rand(3ssl), OpenSSL uses an internal state of 1023 bytes for the RNG.
>
> You only see it reading 32 bytes from /dev/urandom in the strace because it has already loaded 1024 bytes from the RNG state file ~/.rng before adding another 32 bytes:

Remove this .rnd file, and you'll see on the next run that it still
only reads 32 bytes.
Same holds for openssh.

I'm not using this as an argument against increasing the seed size -
Tim and Raymond convinced me - I'm just curious.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue21470>
_______________________________________


More information about the Python-bugs-list mailing list