You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Version 4 UUIDs [...] do not contain any information about the time they are created [...].
While this is not technically a bug breaking execution, this error in the statement (claiming to be version 4) might trap a developer into using this function by believing that the generated UUIDs do not contain any time information, leading to unintended leakage of (time) information.
Strictly speaking, Str::orderedUuid() doesn't produce UUIDs fully complying to RFC 4122, but just the customization "Timestamp-first COMB Codec":
In 2002, Jimmy Nilsson recognized this problem with random UUIDs and proposed a solution he called “COMBs” (see “The Cost of GUIDs as Primary Keys”).
Changing the function name would break implementations, but at least the comment should be updated.
Steps To Reproduce
See description.
The text was updated successfully, but these errors were encountered:
If you notice improper DocBlock, PHPStan, or IDE warnings while using Laravel, do not create a GitHub issue. Instead, please submit a pull request to fix the problem. Also see our contribution guide.
Laravel Version
10.44.0
PHP Version
8.3.1
Database Driver & Version
MySQL 8.2.0
Description
In the comment block for the function
Str::orderedUuid()
it is incorrectly stated:Correctly it should be written:
By definition
While this is not technically a bug breaking execution, this error in the statement (claiming to be version 4) might trap a developer into using this function by believing that the generated UUIDs do not contain any time information, leading to unintended leakage of (time) information.
Strictly speaking,
Str::orderedUuid()
doesn't produce UUIDs fully complying to RFC 4122, but just the customization "Timestamp-first COMB Codec":Changing the function name would break implementations, but at least the comment should be updated.
Steps To Reproduce
See description.
The text was updated successfully, but these errors were encountered: