[issue44620] UUIDv1 is not RFC 4122 compliant
László Görög
report at bugs.python.org
Tue Jul 13 07:15:00 EDT 2021
New submission from László Görög <contact at nergal.xyz>:
Section 4.1.5 of RFC 4122 says the following about Clock Sequence:
If the clock is set backwards, or might have been set backwards
(e.g., while the system was powered off), and the UUID generator can
not be sure that no UUIDs were generated with timestamps larger than
the value to which the clock was set, then the clock sequence has to
be changed. If the previous value of the clock sequence is known, it
can just be incremented; otherwise it should be set to a random or
high-quality pseudo-random value.
However, the current implementation increments the timestamp and not the clock sequence. Ref: https://github.com/python/cpython/blob/bb3e0c240bc60fe08d332ff5955d54197f79751c/Lib/uuid.py#L689-L690
----------
components: Library (Lib)
messages: 397392
nosy: contact2
priority: normal
severity: normal
status: open
title: UUIDv1 is not RFC 4122 compliant
versions: Python 3.10, Python 3.11, Python 3.6, Python 3.7, Python 3.8, Python 3.9
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue44620>
_______________________________________
More information about the Python-bugs-list
mailing list