Download the PHP package jp3cki/uuid without Composer
On this page you can find all versions of the php package jp3cki/uuid. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package uuid
jp3cki/uuid
A simple UUID and ULID implementation.
UUIDv6, v7 and v8 are implemented based on the draft.
Requirements
- PHP ≥ 8.2 (64 bit)
- Basic extensions
- PCRE (preg)
- Hash
Install
Usage
Timestamp-based UUID (version 1, 6, 7)
Random-based UUID (version 4, aka GUID)
Hash-based UUID (version 3 or 5)
Predefined UUIDs (for "namespace"):
jp3cki\uuid\NS::nil():00000000-0000-0000-0000-000000000000jp3cki\uuid\NS::dns():6ba7b810-9dad-11d1-80b4-00c04fd430c8jp3cki\uuid\NS::url():6ba7b811-9dad-11d1-80b4-00c04fd430c8jp3cki\uuid\NS::oid():6ba7b812-9dad-11d1-80b4-00c04fd430c8jp3cki\uuid\NS::x500():6ba7b814-9dad-11d1-80b4-00c04fd430c8
Hash-based UUID (version 8, sha2-256)
User-defined format UUID (version 8)
ULID
License
Under the MIT License.
Please refer the LICENSE file.
Breaking Changes
-
v6.0.0
-
Uuid::isValid()now also validates the variant bits. UUIDs with the NCS variant (0b0xxx) or the reserved variant (0b111x) are no longer accepted; only the RFC 4122 variant (0b10xx) and the Microsoft GUID variant (0b110x) pass. Strings that round-tripped throughUuid::fromString()andisValid()in v5 may now be reported as invalid. Uuid::v7()no longer guarantees monotonic ordering within the same millisecond. The previous process-widerand_acounter has been replaced by per-call CSPRNG output, which removes cross-request correlation and the 4096-per-ms wrap hazard. Sortability is still guaranteed at millisecond granularity, which is what RFC 9562 §5.7 requires; code that relied on strict intra-millisecond order needs to switch to UUIDv6 or carry an explicit sequence column.
-
-
v5.0.0
-
Changed minimum requirement to PHP 8.2.
-
Removed deprecated
Uuid::maxUuid()method. - Removed several static methods in the
internal\Randomclass that had been marked as deprecated.
-
-
v4.0.0
- Changed minimum requirement to PHP 8.1.
-
v3.0.0
-
Changed minimum requirement to PHP 8.0.
- Strict type checking is performed by PHP engine.
-
-
v2.0.0
-
This library no longer works with the 32-bit version of PHP.
-
All public classes are marked as
final. You are not permitted to inherit classes from this library. - The parameter type is now explicitly specified. I believe most users will not be affected by this, but you may get unexpected results if you call it using a variable of the wrong type.
-
- v1.0.0
- Changed minimum requirement to PHP 7.0
All versions of uuid with dependencies
php-64bit Version >= 8.2
ext-hash Version *
ext-pcre Version *
paragonie/constant_time_encoding Version ^3.1.3