summaryrefslogtreecommitdiff
path: root/app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java
diff options
context:
space:
mode:
authorParménides GV <parmegv@sdf.org>2015-03-24 19:07:43 +0100
committerParménides GV <parmegv@sdf.org>2015-03-24 19:07:43 +0100
commitb87f082fe0e9c05cf45c56b510a2c4000133b572 (patch)
tree76a035cef8dc08b159eb19399fc0a823143d6742 /app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java
parent9bb172e96cfd741e528e692118ee32fc609c6da8 (diff)
Indent everything with IntelliJ
Diffstat (limited to 'app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java')
-rw-r--r--app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java17
1 files changed, 10 insertions, 7 deletions
diff --git a/app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java b/app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java
index 33d2971d..9e523751 100644
--- a/app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java
+++ b/app/src/main/java/se/leap/bitmaskclient/PRNGFixes.java
@@ -22,7 +22,7 @@ import java.security.Provider;
/**
* Fixes for the output of the default PRNG having low entropy.
- *
+ * <p/>
* The fixes need to be applied via {@link #apply()} before any use of Java
* Cryptography Architecture primitives. A good place to invoke them is in the
* application's {@code onCreate}.
@@ -32,10 +32,13 @@ public final class PRNGFixes {
private static final int VERSION_CODE_JELLY_BEAN = 16;
private static final int VERSION_CODE_JELLY_BEAN_MR2 = 18;
private static final byte[] BUILD_FINGERPRINT_AND_DEVICE_SERIAL =
- getBuildFingerprintAndDeviceSerial();
+ getBuildFingerprintAndDeviceSerial();
- /** Hidden constructor to prevent instantiation. */
- private PRNGFixes() {}
+ /**
+ * Hidden constructor to prevent instantiation.
+ */
+ private PRNGFixes() {
+ }
/**
* Applies all fixes.
@@ -102,7 +105,7 @@ public final class PRNGFixes {
if ((secureRandomProviders == null)
|| (secureRandomProviders.length < 1)
|| (!LinuxPRNGSecureRandomProvider.class.equals(
- secureRandomProviders[0].getClass()))) {
+ secureRandomProviders[0].getClass()))) {
Security.insertProviderAt(new LinuxPRNGSecureRandomProvider(), 1);
}
@@ -127,7 +130,7 @@ public final class PRNGFixes {
rng2.getProvider().getClass())) {
throw new SecurityException(
"SecureRandom.getInstance(\"SHA1PRNG\") backed by wrong"
- + " Provider: " + rng2.getProvider().getClass());
+ + " Provider: " + rng2.getProvider().getClass());
}
}
@@ -141,7 +144,7 @@ public final class PRNGFixes {
super("LinuxPRNG",
1.0,
"A Linux-specific random number provider that uses"
- + " /dev/urandom");
+ + " /dev/urandom");
// Although /dev/urandom is not a SHA-1 PRNG, some apps
// explicitly request a SHA1PRNG SecureRandom and we thus need to
// prevent them from getting the default implementation whose output