mirror of
https://github.com/mosip/inji-wallet.git
synced 2026-01-09 21:48:04 -05:00
Add encoding for decryption of HMAC
This commit is contained in:
@@ -25,9 +25,9 @@ class Storage {
|
||||
const HMACofCurrentVC = CryptoJS.AES.decrypt(
|
||||
encryptedHMACofCurrentVC,
|
||||
encryptionKey
|
||||
).toString();
|
||||
const HMACofVC = CryptoJS.HmacSHA256(encryptionKey, data).toString();
|
||||
).toString(CryptoJS.enc.Utf8);
|
||||
|
||||
const HMACofVC = CryptoJS.HmacSHA256(encryptionKey, data).toString();
|
||||
if (HMACofVC === HMACofCurrentVC) {
|
||||
return data;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user