5 ms·
Daniel J. Bernstein addressed this the 1990s: * Construct a tuple of the current TAI64NA time, the process ID, some other IDs, and a sequence number. * Encryp
by JdeBP 3y ago
Daniel J. Bernstein addressed this the 1990s:
* Construct a tuple of the current TAI64NA time, the process ID, some other IDs, and a sequence number.
* Encrypt this 384-bit tuple with a 1024-bit secret using SURF.
* The 256-bit result is the ID.
https://github.com/bruceg/ezmlm-idx/blob/master/lib/surf.3 https://github.com/bruceg/ezmlm-idx/blob/master/lib/surf.3
One could adapt this approach to UUIDs.
- tadfisher 3y agoThis eliminates the primary benefit of V7 UUIDs, which is that keys sort temporally, which is almost always the same as the insertion order of a database table (or most collection-like data structures(
- JdeBP 3y agoBut satisfies, as v7 does not satisfy, the actually stated constraint of "IDs that don't reveal when they were generated" whilst still using timestamps, no permanent IDs from hardware, and no centralized ticket-issuing mechanism for sequence numbers. There is more than one feature of v7, and the top of this sub-thread started a discussion of how one would trade them for better security.