mirror of
https://github.com/bitwarden/browser.git
synced 2024-12-25 16:59:17 +01:00
crypto fix for mac
This commit is contained in:
parent
180101400f
commit
f92c5a214f
@ -354,7 +354,7 @@ angular
|
||||
var ivBytes = forge.util.decode64(encPieces[0]);
|
||||
var ctBytes = forge.util.decode64(encPieces[1]);
|
||||
|
||||
if (key.macKey) {
|
||||
if (key.macKey && encPieces.length > 2) {
|
||||
var computedMac = computeMac(ctBytes, ivBytes, key.macKey);
|
||||
if (computedMac !== encPieces[2]) {
|
||||
console.error('MAC failed.');
|
||||
|
Loading…
Reference in New Issue
Block a user