Browse Source

- using java.util.Random in unit tests again, as performance doesn't change by using non-random PRNG - of course still using a cryptographically secure PRNG in production ;-)

Sebastian Stenzel 10 years ago
parent
commit
6dff296872

+ 1 - 10
main/crypto-aes/src/test/java/org/cryptomator/crypto/aes256/Aes256CryptorTest.java

@@ -37,7 +37,7 @@ import org.junit.Test;
 
 public class Aes256CryptorTest {
 
-	private static final Random TEST_PRNG = new NotReallyRandom();
+	private static final Random TEST_PRNG = new Random();
 
 	private Path tmpDir;
 	private Path masterKey;
@@ -185,13 +185,4 @@ public class Aes256CryptorTest {
 
 	}
 
-	private static class NotReallyRandom extends Random {
-		private static final long serialVersionUID = 6080187127141721369L;
-
-		@Override
-		protected int next(int bits) {
-			return 4; // http://xkcd.com/221/
-		}
-	}
-
 }