-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use rand.randbytes() instead of os.urandom() #493
Comments
randbytes is not cryptographically secure |
@Zaczero but ulid is not about security/cryptography, right ? But speed is important. |
Depends on the implementation, this specific one relies on cryptographically secure randomness: https://github.com/ahawker/ulid#components. ULID spec also recommends doing so: https://github.com/ulid/spec#components. |
If you don't care about unpredictability, maybe consider using the thread lock feature - https://github.com/ahawker/ulid#thread-lock - it removes the randomness for quick sequential id generations. |
The text was updated successfully, but these errors were encountered: