[issue13396] new method random.getrandbytes()

Amaury Forgeot d'Arc report at bugs.python.org
Sun Nov 13 20:15:39 CET 2011


Amaury Forgeot d'Arc <amauryfa at gmail.com> added the comment:

> How would this work for other random number generators that don't
> supply genrand_int32()?

genrand_int32 is an internal function, only available in C for the Mersenne Twister generator.
random.SystemRandom() should provide getrandbytes as well, it would just call os.urandom(); I don't know other generators.

----------

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


More information about the Python-bugs-list mailing list