diff --git a/lib/crypto/random.js b/lib/crypto/random.js index 910b2ee1..ea1af3b8 100644 --- a/lib/crypto/random.js +++ b/lib/crypto/random.js @@ -48,7 +48,7 @@ if (crypto) { var i; for (i = 0; i < data.length; i++) - data[i] = ((Math.random() * 0x100000000) >>> 0) % 256; + data[i] = Math.floor(Math.random() * 256); return data; };