From 67695e82f5362ead9425aa48881e70a30cb639a8 Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Mon, 11 Apr 2016 21:12:45 +0200 Subject: [PATCH] Use more secure RNG than Math.random() --- src/org/mxchange/jusercore/model/user/UserUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/org/mxchange/jusercore/model/user/UserUtils.java b/src/org/mxchange/jusercore/model/user/UserUtils.java index e7a299d..b21a217 100644 --- a/src/org/mxchange/jusercore/model/user/UserUtils.java +++ b/src/org/mxchange/jusercore/model/user/UserUtils.java @@ -107,7 +107,7 @@ public class UserUtils extends BaseFrameworkSystem { } // Generate large number - String number = Long.toString(Math.round(Math.random() * 10_000_000_000L)); + String number = Long.toString(RANDOM_NUMBER_GENERATOR.nextLong() * 10_000_000_000L); // Generate salt String salt = Crypt.crypt(number); -- 2.39.5