From 621984664d107c375a9c35ffda55cdb90d3a233a Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Fri, 23 Oct 2015 03:20:41 -0700 Subject: [PATCH] update botp --- bower_components/botp/sha1-hmac.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bower_components/botp/sha1-hmac.js b/bower_components/botp/sha1-hmac.js index 3a0e00c..df419e1 100644 --- a/bower_components/botp/sha1-hmac.js +++ b/bower_components/botp/sha1-hmac.js @@ -26,7 +26,7 @@ exports.sha1Hmac = function (key, bytes) { function useWebCrypto() { return (window.crypto.subtle||window.crypto.webkitSubtle).importKey( "raw" - , key.buffer + , key , { name: "HMAC" , hash: { name: "SHA-1" } } @@ -51,10 +51,10 @@ exports.sha1Hmac = function (key, bytes) { ["sign", "verify"] //can be any combination of "sign" and "verify" ) */ - .then(function (key) { + .then(function (cryptoKey) { return (window.crypto.subtle||window.crypto.webkitSubtle).sign( { name: "HMAC" } - , key // from generateKey or importKey above + , cryptoKey // from generateKey or importKey above , new Uint8Array(bytes) // ArrayBuffer of data you want to sign ) .then(function(signature){