mdeweerd/class.uuid.php

UUID generator based on implementation by Fredrik Lindberg

v1.2 2021-09-18 08:36 UTC

This package is auto-updated.

Last update: 2024-12-18 15:47:41 UTC


README

Pure PHP UUID generator

Dual-licensed under BSDL (2-clause) or Apache 2.0 license

Important Note (Mario DE WEERD):

The original library incorrectly generates random UUIDs. The RFC4122 requires that the two most significant bits of clock_seq_hi... are as in 0b10xx_xxxx, but the original code generated a random number for that byte in the range 0..177.

As a result half of the generated random UUIDs (Version 4) were not compliant. This is fixed in this version.