3 ms·
Good point, thank you! This problem can be mitigated by using random increments. If initial random value is 79-bit and increments are in range [M, 2^n], where M
by ivan_gammel 8y ago
Good point, thank you! This problem can be mitigated by using random increments. If initial random value is 79-bit and increments are in range [M, 2^n], where M>1 and n<=78 , by varying values of M and n you can find the right balance between density and security. This way server may also detect brute force attacks on IDs with specific millisecond value (by simply catching the misses) and progressively increase response time to make them ineffective.
- ngrilly 8y agogithub.com/oklog/ulid does something similar: https://godoc.org/github.com/oklog/ulid#Monotonic https://godoc.org/github.com/oklog/ulid#Monotonic