Simplify access to SecureRandom

This shouldn't matter at all, but it's more "correct," and shows
my age less.
This commit is contained in:
Moxie Marlinspike
2019-03-15 15:31:52 -07:00
committed by Greyson Parrelli
parent 8aa185070b
commit a52c295a38
8 changed files with 84 additions and 114 deletions

View File

@@ -264,8 +264,8 @@ public class MasterSecretUtil {
}
}
private static byte[] generateSalt() throws NoSuchAlgorithmException {
SecureRandom random = SecureRandom.getInstance("SHA1PRNG");
private static byte[] generateSalt() {
SecureRandom random = new SecureRandom();
byte[] salt = new byte[16];
random.nextBytes(salt);