News for hackers. Stuff that matters.
Re:Should random() be banned? by fanf2 on Friday February 12, 2021 @08:23AM (#26113334)
The most common case for me is when fuzzing, when I want reproducible random numbers, so it must be possible to initialize the RNG from a known fixed seed so that I can re-run and debug a failure.
Re:Should random() be banned? by tgsovlerkhgsel on Saturday February 13, 2021 @07:03PM (#26128314)
Hence my suggestion to use a deterministic cryptographic generator: This way, you can either get "proper" randomness by seeding it with a random value, or predictable (and yet strong against anyone who doesn't know the seed) randomness by seeding with a fixed value.