vendredi 12 juillet 2019

Can Math.random be replaced with a CSPRNG that generates a number with the same parameters?

I want to replace the Math.random function with a cryptographically-secure random number generator.

The generator's output must be from 0 (inclusive) to 1 (exclusive) to be consistent with the original Math.random, so it can be dropped into any project without potentially causing any errors.




Aucun commentaire:

Enregistrer un commentaire