Serhiy Storchaka added the comment:
I suggest to reject this proposal because of a deterioration in security.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12986
___
Christian Heimes added the comment:
If somebody is going to implement uuid based on the random module that somebody
must take care of fork. Currently the PRGN in random isn't reseeded during
fork(). This would lead to 100% collisions. The tempfile module contains a
workaround for the issue.
Antoine Pitrou added the comment:
Ok, let's reject the issue then.
--
resolution: - rejected
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12986
Serhiy Storchaka storch...@gmail.com added the comment:
uuids = set()
for u in [uuid.uuid4() for i in range(1000)]:
uuids.add(u)
uuids = {uuid.uuid4() for i in range(1000)}
However, I'm not sure of the legitimacy of replacement suitable for
cryptographic
Antoine Pitrou pit...@free.fr added the comment:
However, I'm not sure of the legitimacy of replacement suitable for
cryptographic use `os.urandom` on fast pseudo-random
`random.getrandbits`. Especially for applications that need to generate
a lot of uuids.
Agreed. urandom() is supposed to
Terry J. Reedy tjre...@udel.edu added the comment:
You could help this along by both running Lib.test.test_uuid with your patch
applied and reporting that it passes.
Raymond, I added you because this is about changing random functions.
Side note: This code in test_uuid.test_uuid4()
Matt Chaput m...@whoosh.ca added the comment:
Passed all tests OK.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12986
___
___
Python-bugs-list
New submission from Matt Chaput m...@whoosh.ca:
Currently the 'uuid' module uses os.urandom (in the absence of a system UUID
generation function) to generate random UUIDs in the uuid.uudi4() function.
This patch changes the implementation of uuid4() to use random.getrandbits() as
the source
Changes by STINNER Victor victor.stin...@haypocalc.com:
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12986
___
___