Skip to content

Commit

Permalink
fix decryptMnemonicCodesStr bug
Browse files Browse the repository at this point in the history
  • Loading branch information
xizho10 committed Jul 4, 2018
1 parent ba5e5ad commit 49d4642
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ public static String decryptMnemonicCodesStr(String encryptedMnemonicCodesStr, S
cipher.init(Cipher.DECRYPT_MODE, skeySpec, new IvParameterSpec(iv));
byte[] rawMns = cipher.doFinal(encryptedkey);
String mnemonicCodesStr = new String(rawMns);
byte[] rawkey = MnemonicCode.getPrikeyFromMnemonicCodesStr(mnemonicCodesStr);
byte[] rawkey = MnemonicCode.getPrikeyFromMnemonicCodesStrBip44(mnemonicCodesStr);
String addressNew = new Account(rawkey, SignatureScheme.SHA256WITHECDSA).getAddressU160().toBase58();
byte[] addressNewHashTemp = Digest.sha256(Digest.sha256(addressNew.getBytes()));
byte[] saltNew = Arrays.copyOfRange(addressNewHashTemp, 0, 4);
Expand Down

0 comments on commit 49d4642

Please sign in to comment.