vendredi 11 septembre 2020

Java: util.Random vs. security.SecureRandom

I've seen that util.Random uses a Linear Congruential Generator, which is too predictable for security purposes. In this case security.SecureRandom is preferred.

My question is:

Why does util.Random exist in the first place if there are better alternatives?

Do the algorithms for RNG differ that much in terms of runtime?




Aucun commentaire:

Enregistrer un commentaire