Fix cryptojs hmac implementation

Apparently the bowerized version of cryptojs's WordArray.create doesn't
handle arraybuffers correctly.
pull/749/head
lilia 11 years ago
parent 6e86a2b7cf
commit 6e3014895b

@ -30,7 +30,7 @@
assertIsArrayBuffer(key);
assertIsArrayBuffer(input);
return CryptoJS.HmacSHA256(
CryptoJS.lib.WordArray.create(input),
CryptoJS.enc.Latin1.parse(getString(input)),
CryptoJS.enc.Latin1.parse(getString(key))
).toString(CryptoJS.enc.Latin1);
};

Loading…
Cancel
Save