mirror of
https://github.com/status-im/status-keycard.git
synced 2025-01-13 15:24:53 +00:00
fix key size for native HMAC
This commit is contained in:
parent
fc4120cd0d
commit
c53b0cd811
@ -51,7 +51,7 @@ public class Crypto {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
hmacSHA512 = Signature.getInstance(Signature.ALG_HMAC_SHA_512, false);
|
hmacSHA512 = Signature.getInstance(Signature.ALG_HMAC_SHA_512, false);
|
||||||
hmacKey = (HMACKey) KeyBuilder.buildKey(KeyBuilder.TYPE_HMAC_TRANSIENT_DESELECT, KEY_SECRET_SIZE, false);
|
hmacKey = (HMACKey) KeyBuilder.buildKey(KeyBuilder.TYPE_HMAC_TRANSIENT_DESELECT, KeyBuilder.LENGTH_AES_256, false);
|
||||||
} catch (CryptoException e) {
|
} catch (CryptoException e) {
|
||||||
hmacSHA512 = null;
|
hmacSHA512 = null;
|
||||||
hmacBlock = JCSystem.makeTransientByteArray(HMAC_BLOCK_SIZE, JCSystem.CLEAR_ON_RESET);
|
hmacBlock = JCSystem.makeTransientByteArray(HMAC_BLOCK_SIZE, JCSystem.CLEAR_ON_RESET);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user