Skip to content

Commit

Permalink
Update encryption algorithm, minimum java version should support it
Browse files Browse the repository at this point in the history
  • Loading branch information
duriancrepe committed Jan 17, 2022
1 parent 384c07d commit fa02968
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion common/src/main/java/bisq/common/crypto/Encryption.java
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ public static SecretKey generateSecretKey(int bits) {
*/
public static SecretKey generateSecretKey(String p, byte[] s, int i, int l) throws NoSuchAlgorithmException, InvalidKeySpecException {
PBEKeySpec ks = new PBEKeySpec(p.toCharArray(), s, i, l);
SecretKeyFactory skf = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA1");
SecretKeyFactory skf = SecretKeyFactory.getInstance("PBKDF2WithHmacSHA512");
SecretKey secret = skf.generateSecret(ks);
SecretKeySpec secretKeySpec = new SecretKeySpec(secret.getEncoded(), Encryption.SYM_KEY_ALGO);
return secretKeySpec;
Expand Down

0 comments on commit fa02968

Please sign in to comment.