Skip to content

Commit d0f5731

Browse files
authored
Merge pull request TooTallNate#1133 from marci4/Issue1132
Use SecureRandom instead of Random
2 parents 32d5656 + feec867 commit d0f5731

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

‎src/main/java/org/java_websocket/drafts/Draft_6455.java‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@
2929
importjava.nio.ByteBuffer;
3030
importjava.security.MessageDigest;
3131
importjava.security.NoSuchAlgorithmException;
32+
importjava.security.SecureRandom;
3233
importjava.text.SimpleDateFormat;
3334
importjava.util.ArrayList;
3435
importjava.util.Calendar;
3536
importjava.util.Collections;
3637
importjava.util.LinkedList;
3738
importjava.util.List;
3839
importjava.util.Locale;
39-
importjava.util.Random;
4040
importjava.util.TimeZone;
4141
importorg.java_websocket.WebSocketImpl;
4242
importorg.java_websocket.enums.CloseHandshakeType;
@@ -150,7 +150,7 @@ public class Draft_6455 extends Draft{
150150
/**
151151
* Attribute for the reusable random instance
152152
*/
153-
privatefinalRandomreuseableRandom = newRandom();
153+
privatefinalSecureRandomreuseableRandom = newSecureRandom();
154154

155155
/**
156156
* Attribute for the maximum allowed size of a frame

0 commit comments

Comments
(0)