Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

js-crypto-hash

Package Overview
Dependencies
Maintainers
1
Versions
36
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

js-crypto-hash - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

25

dist/hash.js

@@ -22,3 +22,3 @@ "use strict";

var _sha = _interopRequireDefault(require("sha.js"));
var _hash = _interopRequireDefault(require("hash.js"));

@@ -48,2 +48,3 @@ /**

msgHash,
errMsg,
native,

@@ -87,4 +88,5 @@ alg,

_context.next = 12;
return webCrypto.digest(hash, msg).catch(function () {
return native = false;
return webCrypto.digest(hash, msg).catch(function (e) {
errMsg = e.message;
native = false;
});

@@ -110,2 +112,3 @@

} catch (e) {
errMsg = e.message;
native = false;

@@ -141,3 +144,4 @@ }

return msdigest(hash, msg).catch(function (e) {
return native = false;
errMsg = e.message;
native = false;
});

@@ -155,3 +159,3 @@

if (native) {
_context.next = 35;
_context.next = 36;
break;

@@ -162,3 +166,3 @@ }

msgHash = purejs(hash, msg);
_context.next = 35;
_context.next = 36;
break;

@@ -169,8 +173,9 @@

_context.t0 = _context["catch"](28);
throw new Error('UnsupportedEnvironment');
errMsg = "".concat(errMsg, " => ").concat(_context.t0.message);
throw new Error("UnsupportedEnvironment: ".concat(errMsg));
case 35:
case 36:
return _context.abrupt("return", new Uint8Array(msgHash));
case 36:
case 37:
case "end":

@@ -193,3 +198,3 @@ return _context.stop();

} else if (Object.keys(_params.default.hashes).indexOf(hash) >= 0) {
h = (0, _sha.default)(_params.default.hashes[hash].nodeName).update(msg).digest();
h = _hash.default[_params.default.hashes[hash].nodeName]().update(msg).digest();
} else throw new Error('UnsupportedHashInPureJs');

@@ -196,0 +201,0 @@

11

dist/jschash.bundle.js

@@ -1,2 +0,2 @@

!function(t,r){"object"==typeof exports&&"object"==typeof module?module.exports=r(require("crypto")):"function"==typeof define&&define.amd?define(["crypto"],r):"object"==typeof exports?exports.jschash=r(require("crypto")):t.jschash=r(t.crypto)}(this,function(t){return function(t){var r={};function e(n){if(r[n])return r[n].exports;var i=r[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,e),i.l=!0,i.exports}return e.m=t,e.c=r,e.d=function(t,r,n){e.o(t,r)||Object.defineProperty(t,r,{enumerable:!0,get:n})},e.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},e.t=function(t,r){if(1&r&&(t=e(t)),8&r)return t;if(4&r&&"object"==typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(e.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&r&&"string"!=typeof t)for(var i in t)e.d(n,i,function(r){return t[r]}.bind(null,i));return n},e.n=function(t){var r=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,r){return Object.prototype.hasOwnProperty.call(t,r)},e.p="/Users/jun/ProjectJavaScript/js_crypto_hash/dist",e(e.s=10)}([function(t,r,e){var n=e(17),i=n.Buffer;function o(t,r){for(var e in t)r[e]=t[e]}function s(t,r,e){return i(t,r,e)}i.from&&i.alloc&&i.allocUnsafe&&i.allocUnsafeSlow?t.exports=n:(o(n,r),r.Buffer=s),o(i,s),s.from=function(t,r,e){if("number"==typeof t)throw new TypeError("Argument must not be a number");return i(t,r,e)},s.alloc=function(t,r,e){if("number"!=typeof t)throw new TypeError("Argument must be a number");var n=i(t);return void 0!==r?"string"==typeof e?n.fill(r,e):n.fill(r):n.fill(0),n},s.allocUnsafe=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return i(t)},s.allocUnsafeSlow=function(t){if("number"!=typeof t)throw new TypeError("Argument must be a number");return n.SlowBuffer(t)}},function(t,r){"function"==typeof Object.create?t.exports=function(t,r){t.super_=r,t.prototype=Object.create(r.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(t,r){t.super_=r;var e=function(){};e.prototype=r.prototype,t.prototype=new e,t.prototype.constructor=t}},function(t,r,e){var n=e(0).Buffer;function i(t,r){this._block=n.alloc(t),this._finalSize=r,this._blockSize=t,this._len=0}i.prototype.update=function(t,r){"string"==typeof t&&(r=r||"utf8",t=n.from(t,r));for(var e=this._block,i=this._blockSize,o=t.length,s=this._len,h=0;h<o;){for(var u=s%i,f=Math.min(o-h,i-u),a=0;a<f;a++)e[u+a]=t[h+a];h+=f,(s+=f)%i==0&&this._update(e)}return this._len+=o,this},i.prototype.digest=function(t){var r=this._len%this._blockSize;this._block[r]=128,this._block.fill(0,r+1),r>=this._finalSize&&(this._update(this._block),this._block.fill(0));var e=8*this._len;if(e<=4294967295)this._block.writeUInt32BE(e,this._blockSize-4);else{var n=(4294967295&e)>>>0,i=(e-n)/4294967296;this._block.writeUInt32BE(i,this._blockSize-8),this._block.writeUInt32BE(n,this._blockSize-4)}this._update(this._block);var o=this._hash();return t?o.toString(t):o},i.prototype._update=function(){throw new Error("_update must be implemented by subclass")},t.exports=i},function(t,r,e){t.exports=e(11)},function(t,r){var e={utf8:{stringToBytes:function(t){return e.bin.stringToBytes(unescape(encodeURIComponent(t)))},bytesToString:function(t){return decodeURIComponent(escape(e.bin.bytesToString(t)))}},bin:{stringToBytes:function(t){for(var r=[],e=0;e<t.length;e++)r.push(255&t.charCodeAt(e));return r},bytesToString:function(t){for(var r=[],e=0;e<t.length;e++)r.push(String.fromCharCode(t[e]));return r.join("")}}};t.exports=e},function(t,r,e){var n=e(1),i=e(2),o=e(0).Buffer,s=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],h=new Array(64);function u(){this.init(),this._w=h,i.call(this,64,56)}function f(t,r,e){return e^t&(r^e)}function a(t,r,e){return t&r|e&(t|r)}function c(t){return(t>>>2|t<<30)^(t>>>13|t<<19)^(t>>>22|t<<10)}function l(t){return(t>>>6|t<<26)^(t>>>11|t<<21)^(t>>>25|t<<7)}function p(t){return(t>>>7|t<<25)^(t>>>18|t<<14)^t>>>3}function _(t){return(t>>>17|t<<15)^(t>>>19|t<<13)^t>>>10}n(u,i),u.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},u.prototype._update=function(t){for(var r=this._w,e=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,h=0|this._e,u=0|this._f,y=0|this._g,g=0|this._h,d=0;d<16;++d)r[d]=t.readInt32BE(4*d);for(;d<64;++d)r[d]=_(r[d-2])+r[d-7]+p(r[d-15])+r[d-16]|0;for(var w=0;w<64;++w){var v=g+l(h)+f(h,u,y)+s[w]+r[w]|0,b=c(e)+a(e,n,i)|0;g=y,y=u,u=h,h=o+v|0,o=i,i=n,n=e,e=v+b|0}this._a=e+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=h+this._e|0,this._f=u+this._f|0,this._g=y+this._g|0,this._h=g+this._h|0},u.prototype._hash=function(){var t=o.allocUnsafe(32);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t.writeInt32BE(this._h,28),t},t.exports=u},function(t,r,e){var n=e(1),i=e(2),o=e(0).Buffer,s=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591],h=new Array(160);function u(){this.init(),this._w=h,i.call(this,128,112)}function f(t,r,e){return e^t&(r^e)}function a(t,r,e){return t&r|e&(t|r)}function c(t,r){return(t>>>28|r<<4)^(r>>>2|t<<30)^(r>>>7|t<<25)}function l(t,r){return(t>>>14|r<<18)^(t>>>18|r<<14)^(r>>>9|t<<23)}function p(t,r){return(t>>>1|r<<31)^(t>>>8|r<<24)^t>>>7}function _(t,r){return(t>>>1|r<<31)^(t>>>8|r<<24)^(t>>>7|r<<25)}function y(t,r){return(t>>>19|r<<13)^(r>>>29|t<<3)^t>>>6}function g(t,r){return(t>>>19|r<<13)^(r>>>29|t<<3)^(t>>>6|r<<26)}function d(t,r){return t>>>0<r>>>0?1:0}n(u,i),u.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},u.prototype._update=function(t){for(var r=this._w,e=0|this._ah,n=0|this._bh,i=0|this._ch,o=0|this._dh,h=0|this._eh,u=0|this._fh,w=0|this._gh,v=0|this._hh,b=0|this._al,m=0|this._bl,E=0|this._cl,A=0|this._dl,B=0|this._el,x=0|this._fl,R=0|this._gl,S=0|this._hl,T=0;T<32;T+=2)r[T]=t.readInt32BE(4*T),r[T+1]=t.readInt32BE(4*T+4);for(;T<160;T+=2){var I=r[T-30],P=r[T-30+1],U=p(I,P),L=_(P,I),O=y(I=r[T-4],P=r[T-4+1]),k=g(P,I),Y=r[T-14],j=r[T-14+1],C=r[T-32],M=r[T-32+1],N=L+j|0,D=U+Y+d(N,L)|0;D=(D=D+O+d(N=N+k|0,k)|0)+C+d(N=N+M|0,M)|0,r[T]=D,r[T+1]=N}for(var z=0;z<160;z+=2){D=r[z],N=r[z+1];var F=a(e,n,i),H=a(b,m,E),G=c(e,b),q=c(b,e),J=l(h,B),V=l(B,h),W=s[z],X=s[z+1],Z=f(h,u,w),K=f(B,x,R),Q=S+V|0,$=v+J+d(Q,S)|0;$=($=($=$+Z+d(Q=Q+K|0,K)|0)+W+d(Q=Q+X|0,X)|0)+D+d(Q=Q+N|0,N)|0;var tt=q+H|0,rt=G+F+d(tt,q)|0;v=w,S=R,w=u,R=x,u=h,x=B,h=o+$+d(B=A+Q|0,A)|0,o=i,A=E,i=n,E=m,n=e,m=b,e=$+rt+d(b=Q+tt|0,Q)|0}this._al=this._al+b|0,this._bl=this._bl+m|0,this._cl=this._cl+E|0,this._dl=this._dl+A|0,this._el=this._el+B|0,this._fl=this._fl+x|0,this._gl=this._gl+R|0,this._hl=this._hl+S|0,this._ah=this._ah+e+d(this._al,b)|0,this._bh=this._bh+n+d(this._bl,m)|0,this._ch=this._ch+i+d(this._cl,E)|0,this._dh=this._dh+o+d(this._dl,A)|0,this._eh=this._eh+h+d(this._el,B)|0,this._fh=this._fh+u+d(this._fl,x)|0,this._gh=this._gh+w+d(this._gl,R)|0,this._hh=this._hh+v+d(this._hl,S)|0},u.prototype._hash=function(){var t=o.allocUnsafe(64);function r(r,e,n){t.writeInt32BE(r,n),t.writeInt32BE(e,n+4)}return r(this._ah,this._al,0),r(this._bh,this._bl,8),r(this._ch,this._cl,16),r(this._dh,this._dl,24),r(this._eh,this._el,32),r(this._fh,this._fl,40),r(this._gh,this._gl,48),r(this._hh,this._hl,56),t},t.exports=u},function(t,r){function e(t,r,e,n,i,o,s){try{var h=t[o](s),u=h.value}catch(t){return void e(t)}h.done?r(u):Promise.resolve(u).then(n,i)}t.exports=function(t){return function(){var r=this,n=arguments;return new Promise(function(i,o){var s=t.apply(r,n);function h(t){e(s,i,o,h,u,"next",t)}function u(t){e(s,i,o,h,u,"throw",t)}h(void 0)})}}},function(t,r,e){!function(){var r=e(14),n=e(4).utf8,i=e(15),o=e(4).bin,s=function(t,e){t.constructor==String?t=e&&"binary"===e.encoding?o.stringToBytes(t):n.stringToBytes(t):i(t)?t=Array.prototype.slice.call(t,0):Array.isArray(t)||(t=t.toString());for(var h=r.bytesToWords(t),u=8*t.length,f=1732584193,a=-271733879,c=-1732584194,l=271733878,p=0;p<h.length;p++)h[p]=16711935&(h[p]<<8|h[p]>>>24)|4278255360&(h[p]<<24|h[p]>>>8);h[u>>>5]|=128<<u%32,h[14+(u+64>>>9<<4)]=u;var _=s._ff,y=s._gg,g=s._hh,d=s._ii;for(p=0;p<h.length;p+=16){var w=f,v=a,b=c,m=l;a=d(a=d(a=d(a=d(a=g(a=g(a=g(a=g(a=y(a=y(a=y(a=y(a=_(a=_(a=_(a=_(a,c=_(c,l=_(l,f=_(f,a,c,l,h[p+0],7,-680876936),a,c,h[p+1],12,-389564586),f,a,h[p+2],17,606105819),l,f,h[p+3],22,-1044525330),c=_(c,l=_(l,f=_(f,a,c,l,h[p+4],7,-176418897),a,c,h[p+5],12,1200080426),f,a,h[p+6],17,-1473231341),l,f,h[p+7],22,-45705983),c=_(c,l=_(l,f=_(f,a,c,l,h[p+8],7,1770035416),a,c,h[p+9],12,-1958414417),f,a,h[p+10],17,-42063),l,f,h[p+11],22,-1990404162),c=_(c,l=_(l,f=_(f,a,c,l,h[p+12],7,1804603682),a,c,h[p+13],12,-40341101),f,a,h[p+14],17,-1502002290),l,f,h[p+15],22,1236535329),c=y(c,l=y(l,f=y(f,a,c,l,h[p+1],5,-165796510),a,c,h[p+6],9,-1069501632),f,a,h[p+11],14,643717713),l,f,h[p+0],20,-373897302),c=y(c,l=y(l,f=y(f,a,c,l,h[p+5],5,-701558691),a,c,h[p+10],9,38016083),f,a,h[p+15],14,-660478335),l,f,h[p+4],20,-405537848),c=y(c,l=y(l,f=y(f,a,c,l,h[p+9],5,568446438),a,c,h[p+14],9,-1019803690),f,a,h[p+3],14,-187363961),l,f,h[p+8],20,1163531501),c=y(c,l=y(l,f=y(f,a,c,l,h[p+13],5,-1444681467),a,c,h[p+2],9,-51403784),f,a,h[p+7],14,1735328473),l,f,h[p+12],20,-1926607734),c=g(c,l=g(l,f=g(f,a,c,l,h[p+5],4,-378558),a,c,h[p+8],11,-2022574463),f,a,h[p+11],16,1839030562),l,f,h[p+14],23,-35309556),c=g(c,l=g(l,f=g(f,a,c,l,h[p+1],4,-1530992060),a,c,h[p+4],11,1272893353),f,a,h[p+7],16,-155497632),l,f,h[p+10],23,-1094730640),c=g(c,l=g(l,f=g(f,a,c,l,h[p+13],4,681279174),a,c,h[p+0],11,-358537222),f,a,h[p+3],16,-722521979),l,f,h[p+6],23,76029189),c=g(c,l=g(l,f=g(f,a,c,l,h[p+9],4,-640364487),a,c,h[p+12],11,-421815835),f,a,h[p+15],16,530742520),l,f,h[p+2],23,-995338651),c=d(c,l=d(l,f=d(f,a,c,l,h[p+0],6,-198630844),a,c,h[p+7],10,1126891415),f,a,h[p+14],15,-1416354905),l,f,h[p+5],21,-57434055),c=d(c,l=d(l,f=d(f,a,c,l,h[p+12],6,1700485571),a,c,h[p+3],10,-1894986606),f,a,h[p+10],15,-1051523),l,f,h[p+1],21,-2054922799),c=d(c,l=d(l,f=d(f,a,c,l,h[p+8],6,1873313359),a,c,h[p+15],10,-30611744),f,a,h[p+6],15,-1560198380),l,f,h[p+13],21,1309151649),c=d(c,l=d(l,f=d(f,a,c,l,h[p+4],6,-145523070),a,c,h[p+11],10,-1120210379),f,a,h[p+2],15,718787259),l,f,h[p+9],21,-343485551),f=f+w>>>0,a=a+v>>>0,c=c+b>>>0,l=l+m>>>0}return r.endian([f,a,c,l])};s._ff=function(t,r,e,n,i,o,s){var h=t+(r&e|~r&n)+(i>>>0)+s;return(h<<o|h>>>32-o)+r},s._gg=function(t,r,e,n,i,o,s){var h=t+(r&n|e&~n)+(i>>>0)+s;return(h<<o|h>>>32-o)+r},s._hh=function(t,r,e,n,i,o,s){var h=t+(r^e^n)+(i>>>0)+s;return(h<<o|h>>>32-o)+r},s._ii=function(t,r,e,n,i,o,s){var h=t+(e^(r|~n))+(i>>>0)+s;return(h<<o|h>>>32-o)+r},s._blocksize=16,s._digestsize=16,t.exports=function(t,e){if(void 0===t||null===t)throw new Error("Illegal argument "+t);var n=r.wordsToBytes(s(t,e));return e&&e.asBytes?n:e&&e.asString?o.bytesToString(n):r.bytesToHex(n)}}()},function(t,r,e){(r=t.exports=function(t){t=t.toLowerCase();var e=r[t];if(!e)throw new Error(t+" is not supported (we accept pull requests)");return new e}).sha=e(16),r.sha1=e(22),r.sha224=e(23),r.sha256=e(5),r.sha384=e(24),r.sha512=e(6)},function(t,r,e){t.exports=e(25)},function(t,r,e){var n=function(){return this||"object"==typeof self&&self}()||Function("return this")(),i=n.regeneratorRuntime&&Object.getOwnPropertyNames(n).indexOf("regeneratorRuntime")>=0,o=i&&n.regeneratorRuntime;if(n.regeneratorRuntime=void 0,t.exports=e(12),i)n.regeneratorRuntime=o;else try{delete n.regeneratorRuntime}catch(t){n.regeneratorRuntime=void 0}},function(t,r){!function(r){"use strict";var e,n=Object.prototype,i=n.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",h=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag",f="object"==typeof t,a=r.regeneratorRuntime;if(a)f&&(t.exports=a);else{(a=r.regeneratorRuntime=f?t.exports:{}).wrap=b;var c="suspendedStart",l="suspendedYield",p="executing",_="completed",y={},g={};g[s]=function(){return this};var d=Object.getPrototypeOf,w=d&&d(d(U([])));w&&w!==n&&i.call(w,s)&&(g=w);var v=B.prototype=E.prototype=Object.create(g);A.prototype=v.constructor=B,B.constructor=A,B[u]=A.displayName="GeneratorFunction",a.isGeneratorFunction=function(t){var r="function"==typeof t&&t.constructor;return!!r&&(r===A||"GeneratorFunction"===(r.displayName||r.name))},a.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,B):(t.__proto__=B,u in t||(t[u]="GeneratorFunction")),t.prototype=Object.create(v),t},a.awrap=function(t){return{__await:t}},x(R.prototype),R.prototype[h]=function(){return this},a.AsyncIterator=R,a.async=function(t,r,e,n){var i=new R(b(t,r,e,n));return a.isGeneratorFunction(r)?i:i.next().then(function(t){return t.done?t.value:i.next()})},x(v),v[u]="Generator",v[s]=function(){return this},v.toString=function(){return"[object Generator]"},a.keys=function(t){var r=[];for(var e in t)r.push(e);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},a.values=U,P.prototype={constructor:P,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(I),!t)for(var r in this)"t"===r.charAt(0)&&i.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function n(n,i){return h.type="throw",h.arg=t,r.next=n,i&&(r.method="next",r.arg=e),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],h=s.completion;if("root"===s.tryLoc)return n("end");if(s.tryLoc<=this.prev){var u=i.call(s,"catchLoc"),f=i.call(s,"finallyLoc");if(u&&f){if(this.prev<s.catchLoc)return n(s.catchLoc,!0);if(this.prev<s.finallyLoc)return n(s.finallyLoc)}else if(u){if(this.prev<s.catchLoc)return n(s.catchLoc,!0)}else{if(!f)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return n(s.finallyLoc)}}}},abrupt:function(t,r){for(var e=this.tryEntries.length-1;e>=0;--e){var n=this.tryEntries[e];if(n.tryLoc<=this.prev&&i.call(n,"finallyLoc")&&this.prev<n.finallyLoc){var o=n;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=r&&r<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=t,s.arg=r,o?(this.method="next",this.next=o.finallyLoc,y):this.complete(s)},complete:function(t,r){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&r&&(this.next=r),y},finish:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.finallyLoc===t)return this.complete(e.completion,e.afterLoc),I(e),y}},catch:function(t){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.tryLoc===t){var n=e.completion;if("throw"===n.type){var i=n.arg;I(e)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:U(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),y}}}function b(t,r,e,n){var i=r&&r.prototype instanceof E?r:E,o=Object.create(i.prototype),s=new P(n||[]);return o._invoke=function(t,r,e){var n=c;return function(i,o){if(n===p)throw new Error("Generator is already running");if(n===_){if("throw"===i)throw o;return L()}for(e.method=i,e.arg=o;;){var s=e.delegate;if(s){var h=S(s,e);if(h){if(h===y)continue;return h}}if("next"===e.method)e.sent=e._sent=e.arg;else if("throw"===e.method){if(n===c)throw n=_,e.arg;e.dispatchException(e.arg)}else"return"===e.method&&e.abrupt("return",e.arg);n=p;var u=m(t,r,e);if("normal"===u.type){if(n=e.done?_:l,u.arg===y)continue;return{value:u.arg,done:e.done}}"throw"===u.type&&(n=_,e.method="throw",e.arg=u.arg)}}}(t,e,s),o}function m(t,r,e){try{return{type:"normal",arg:t.call(r,e)}}catch(t){return{type:"throw",arg:t}}}function E(){}function A(){}function B(){}function x(t){["next","throw","return"].forEach(function(r){t[r]=function(t){return this._invoke(r,t)}})}function R(t){var r;this._invoke=function(e,n){function o(){return new Promise(function(r,o){!function r(e,n,o,s){var h=m(t[e],t,n);if("throw"!==h.type){var u=h.arg,f=u.value;return f&&"object"==typeof f&&i.call(f,"__await")?Promise.resolve(f.__await).then(function(t){r("next",t,o,s)},function(t){r("throw",t,o,s)}):Promise.resolve(f).then(function(t){u.value=t,o(u)},function(t){return r("throw",t,o,s)})}s(h.arg)}(e,n,r,o)})}return r=r?r.then(o,o):o()}}function S(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator.return&&(r.method="return",r.arg=e,S(t,r),"throw"===r.method))return y;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return y}var i=m(n,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var o=i.arg;return o?o.done?(r[t.resultName]=o.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,y):o:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function T(t){var r={tryLoc:t[0]};1 in t&&(r.catchLoc=t[1]),2 in t&&(r.finallyLoc=t[2],r.afterLoc=t[3]),this.tryEntries.push(r)}function I(t){var r=t.completion||{};r.type="normal",delete r.arg,t.completion=r}function P(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(T,this),this.reset(!0)}function U(t){if(t){var r=t[s];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function r(){for(;++n<t.length;)if(i.call(t,n))return r.value=t[n],r.done=!1,r;return r.value=e,r.done=!0,r};return o.next=o}}return{next:L}}function L(){return{value:e,done:!0}}}(function(){return this||"object"==typeof self&&self}()||Function("return this")())},function(r,e){r.exports=t},function(t,r){!function(){var r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",e={rotl:function(t,r){return t<<r|t>>>32-r},rotr:function(t,r){return t<<32-r|t>>>r},endian:function(t){if(t.constructor==Number)return 16711935&e.rotl(t,8)|4278255360&e.rotl(t,24);for(var r=0;r<t.length;r++)t[r]=e.endian(t[r]);return t},randomBytes:function(t){for(var r=[];t>0;t--)r.push(Math.floor(256*Math.random()));return r},bytesToWords:function(t){for(var r=[],e=0,n=0;e<t.length;e++,n+=8)r[n>>>5]|=t[e]<<24-n%32;return r},wordsToBytes:function(t){for(var r=[],e=0;e<32*t.length;e+=8)r.push(t[e>>>5]>>>24-e%32&255);return r},bytesToHex:function(t){for(var r=[],e=0;e<t.length;e++)r.push((t[e]>>>4).toString(16)),r.push((15&t[e]).toString(16));return r.join("")},hexToBytes:function(t){for(var r=[],e=0;e<t.length;e+=2)r.push(parseInt(t.substr(e,2),16));return r},bytesToBase64:function(t){for(var e=[],n=0;n<t.length;n+=3)for(var i=t[n]<<16|t[n+1]<<8|t[n+2],o=0;o<4;o++)8*n+6*o<=8*t.length?e.push(r.charAt(i>>>6*(3-o)&63)):e.push("=");return e.join("")},base64ToBytes:function(t){t=t.replace(/[^A-Z0-9+\/]/gi,"");for(var e=[],n=0,i=0;n<t.length;i=++n%4)0!=i&&e.push((r.indexOf(t.charAt(n-1))&Math.pow(2,-2*i+8)-1)<<2*i|r.indexOf(t.charAt(n))>>>6-2*i);return e}};t.exports=e}()},function(t,r){function e(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}
!function(t,n){"object"==typeof exports&&"object"==typeof module?module.exports=n(require("crypto")):"function"==typeof define&&define.amd?define(["crypto"],n):"object"==typeof exports?exports.jschash=n(require("crypto")):t.jschash=n(t.crypto)}(this,function(t){return function(t){var n={};function r(e){if(n[e])return n[e].exports;var i=n[e]={i:e,l:!1,exports:{}};return t[e].call(i.exports,i,i.exports,r),i.l=!0,i.exports}return r.m=t,r.c=n,r.d=function(t,n,e){r.o(t,n)||Object.defineProperty(t,n,{enumerable:!0,get:e})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,n){if(1&n&&(t=r(t)),8&n)return t;if(4&n&&"object"==typeof t&&t&&t.__esModule)return t;var e=Object.create(null);if(r.r(e),Object.defineProperty(e,"default",{enumerable:!0,value:t}),2&n&&"string"!=typeof t)for(var i in t)r.d(e,i,function(n){return t[n]}.bind(null,i));return e},r.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(n,"a",n),n},r.o=function(t,n){return Object.prototype.hasOwnProperty.call(t,n)},r.p="/Users/jun/ProjectJavaScript/js_crypto_hash/dist",r(r.s=11)}([function(t,n,r){"use strict";var e=r(1),i=r(17);function o(t){return(t>>>24|t>>>8&65280|t<<8&16711680|(255&t)<<24)>>>0}function s(t){return 1===t.length?"0"+t:t}function h(t){return 7===t.length?"0"+t:6===t.length?"00"+t:5===t.length?"000"+t:4===t.length?"0000"+t:3===t.length?"00000"+t:2===t.length?"000000"+t:1===t.length?"0000000"+t:t}n.inherits=i,n.toArray=function(t,n){if(Array.isArray(t))return t.slice();if(!t)return[];var r=[];if("string"==typeof t)if(n){if("hex"===n)for((t=t.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(t="0"+t),e=0;e<t.length;e+=2)r.push(parseInt(t[e]+t[e+1],16))}else for(var e=0;e<t.length;e++){var i=t.charCodeAt(e),o=i>>8,s=255&i;o?r.push(o,s):r.push(s)}else for(e=0;e<t.length;e++)r[e]=0|t[e];return r},n.toHex=function(t){for(var n="",r=0;r<t.length;r++)n+=s(t[r].toString(16));return n},n.htonl=o,n.toHex32=function(t,n){for(var r="",e=0;e<t.length;e++){var i=t[e];"little"===n&&(i=o(i)),r+=h(i.toString(16))}return r},n.zero2=s,n.zero8=h,n.join32=function(t,n,r,i){var o=r-n;e(o%4==0);for(var s=new Array(o/4),h=0,u=n;h<s.length;h++,u+=4){var a;a="big"===i?t[u]<<24|t[u+1]<<16|t[u+2]<<8|t[u+3]:t[u+3]<<24|t[u+2]<<16|t[u+1]<<8|t[u],s[h]=a>>>0}return s},n.split32=function(t,n){for(var r=new Array(4*t.length),e=0,i=0;e<t.length;e++,i+=4){var o=t[e];"big"===n?(r[i]=o>>>24,r[i+1]=o>>>16&255,r[i+2]=o>>>8&255,r[i+3]=255&o):(r[i+3]=o>>>24,r[i+2]=o>>>16&255,r[i+1]=o>>>8&255,r[i]=255&o)}return r},n.rotr32=function(t,n){return t>>>n|t<<32-n},n.rotl32=function(t,n){return t<<n|t>>>32-n},n.sum32=function(t,n){return t+n>>>0},n.sum32_3=function(t,n,r){return t+n+r>>>0},n.sum32_4=function(t,n,r,e){return t+n+r+e>>>0},n.sum32_5=function(t,n,r,e,i){return t+n+r+e+i>>>0},n.sum64=function(t,n,r,e){var i=t[n],o=e+t[n+1]>>>0,s=(o<e?1:0)+r+i;t[n]=s>>>0,t[n+1]=o},n.sum64_hi=function(t,n,r,e){return(n+e>>>0<n?1:0)+t+r>>>0},n.sum64_lo=function(t,n,r,e){return n+e>>>0},n.sum64_4_hi=function(t,n,r,e,i,o,s,h){var u=0,a=n;return u+=(a=a+e>>>0)<n?1:0,u+=(a=a+o>>>0)<o?1:0,t+r+i+s+(u+=(a=a+h>>>0)<h?1:0)>>>0},n.sum64_4_lo=function(t,n,r,e,i,o,s,h){return n+e+o+h>>>0},n.sum64_5_hi=function(t,n,r,e,i,o,s,h,u,a){var c=0,f=n;return c+=(f=f+e>>>0)<n?1:0,c+=(f=f+o>>>0)<o?1:0,c+=(f=f+h>>>0)<h?1:0,t+r+i+s+u+(c+=(f=f+a>>>0)<a?1:0)>>>0},n.sum64_5_lo=function(t,n,r,e,i,o,s,h,u,a){return n+e+o+h+a>>>0},n.rotr64_hi=function(t,n,r){return(n<<32-r|t>>>r)>>>0},n.rotr64_lo=function(t,n,r){return(t<<32-r|n>>>r)>>>0},n.shr64_hi=function(t,n,r){return t>>>r},n.shr64_lo=function(t,n,r){return(t<<32-r|n>>>r)>>>0}},function(t,n){function r(t,n){if(!t)throw new Error(n||"Assertion failed")}t.exports=r,r.equal=function(t,n,r){if(t!=n)throw new Error(r||"Assertion failed: "+t+" != "+n)}},function(t,n,r){"use strict";var e=r(0),i=r(1);function o(){this.pending=null,this.pendingTotal=0,this.blockSize=this.constructor.blockSize,this.outSize=this.constructor.outSize,this.hmacStrength=this.constructor.hmacStrength,this.padLength=this.constructor.padLength/8,this.endian="big",this._delta8=this.blockSize/8,this._delta32=this.blockSize/32}n.BlockHash=o,o.prototype.update=function(t,n){if(t=e.toArray(t,n),this.pending?this.pending=this.pending.concat(t):this.pending=t,this.pendingTotal+=t.length,this.pending.length>=this._delta8){var r=(t=this.pending).length%this._delta8;this.pending=t.slice(t.length-r,t.length),0===this.pending.length&&(this.pending=null),t=e.join32(t,0,t.length-r,this.endian);for(var i=0;i<t.length;i+=this._delta32)this._update(t,i,i+this._delta32)}return this},o.prototype.digest=function(t){return this.update(this._pad()),i(null===this.pending),this._digest(t)},o.prototype._pad=function(){var t=this.pendingTotal,n=this._delta8,r=n-(t+this.padLength)%n,e=new Array(r+this.padLength);e[0]=128;for(var i=1;i<r;i++)e[i]=0;if(t<<=3,"big"===this.endian){for(var o=8;o<this.padLength;o++)e[i++]=0;e[i++]=0,e[i++]=0,e[i++]=0,e[i++]=0,e[i++]=t>>>24&255,e[i++]=t>>>16&255,e[i++]=t>>>8&255,e[i++]=255&t}else for(e[i++]=255&t,e[i++]=t>>>8&255,e[i++]=t>>>16&255,e[i++]=t>>>24&255,e[i++]=0,e[i++]=0,e[i++]=0,e[i++]=0,o=8;o<this.padLength;o++)e[i++]=0;return e}},function(t,n,r){t.exports=r(12)},function(t,n){var r={utf8:{stringToBytes:function(t){return r.bin.stringToBytes(unescape(encodeURIComponent(t)))},bytesToString:function(t){return decodeURIComponent(escape(r.bin.bytesToString(t)))}},bin:{stringToBytes:function(t){for(var n=[],r=0;r<t.length;r++)n.push(255&t.charCodeAt(r));return n},bytesToString:function(t){for(var n=[],r=0;r<t.length;r++)n.push(String.fromCharCode(t[r]));return n.join("")}}};t.exports=r},function(t,n,r){"use strict";var e=r(0).rotr32;function i(t,n,r){return t&n^~t&r}function o(t,n,r){return t&n^t&r^n&r}function s(t,n,r){return t^n^r}n.ft_1=function(t,n,r,e){return 0===t?i(n,r,e):1===t||3===t?s(n,r,e):2===t?o(n,r,e):void 0},n.ch32=i,n.maj32=o,n.p32=s,n.s0_256=function(t){return e(t,2)^e(t,13)^e(t,22)},n.s1_256=function(t){return e(t,6)^e(t,11)^e(t,25)},n.g0_256=function(t){return e(t,7)^e(t,18)^t>>>3},n.g1_256=function(t){return e(t,17)^e(t,19)^t>>>10}},function(t,n,r){"use strict";var e=r(0),i=r(2),o=r(5),s=r(1),h=e.sum32,u=e.sum32_4,a=e.sum32_5,c=o.ch32,f=o.maj32,l=o.s0_256,p=o.s1_256,g=o.g0_256,d=o.g1_256,y=i.BlockHash,v=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298];function m(){if(!(this instanceof m))return new m;y.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=v,this.W=new Array(64)}e.inherits(m,y),t.exports=m,m.blockSize=512,m.outSize=256,m.hmacStrength=192,m.padLength=64,m.prototype._update=function(t,n){for(var r=this.W,e=0;e<16;e++)r[e]=t[n+e];for(;e<r.length;e++)r[e]=u(d(r[e-2]),r[e-7],g(r[e-15]),r[e-16]);var i=this.h[0],o=this.h[1],y=this.h[2],v=this.h[3],m=this.h[4],_=this.h[5],b=this.h[6],w=this.h[7];for(s(this.k.length===r.length),e=0;e<r.length;e++){var x=a(w,p(m),c(m,_,b),this.k[e],r[e]),S=h(l(i),f(i,o,y));w=b,b=_,_=m,m=h(v,x),v=y,y=o,o=i,i=h(x,S)}this.h[0]=h(this.h[0],i),this.h[1]=h(this.h[1],o),this.h[2]=h(this.h[2],y),this.h[3]=h(this.h[3],v),this.h[4]=h(this.h[4],m),this.h[5]=h(this.h[5],_),this.h[6]=h(this.h[6],b),this.h[7]=h(this.h[7],w)},m.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h,"big"):e.split32(this.h,"big")}},function(t,n,r){"use strict";var e=r(0),i=r(2),o=r(1),s=e.rotr64_hi,h=e.rotr64_lo,u=e.shr64_hi,a=e.shr64_lo,c=e.sum64,f=e.sum64_hi,l=e.sum64_lo,p=e.sum64_4_hi,g=e.sum64_4_lo,d=e.sum64_5_hi,y=e.sum64_5_lo,v=i.BlockHash,m=[1116352408,3609767458,1899447441,602891725,3049323471,3964484399,3921009573,2173295548,961987163,4081628472,1508970993,3053834265,2453635748,2937671579,2870763221,3664609560,3624381080,2734883394,310598401,1164996542,607225278,1323610764,1426881987,3590304994,1925078388,4068182383,2162078206,991336113,2614888103,633803317,3248222580,3479774868,3835390401,2666613458,4022224774,944711139,264347078,2341262773,604807628,2007800933,770255983,1495990901,1249150122,1856431235,1555081692,3175218132,1996064986,2198950837,2554220882,3999719339,2821834349,766784016,2952996808,2566594879,3210313671,3203337956,3336571891,1034457026,3584528711,2466948901,113926993,3758326383,338241895,168717936,666307205,1188179964,773529912,1546045734,1294757372,1522805485,1396182291,2643833823,1695183700,2343527390,1986661051,1014477480,2177026350,1206759142,2456956037,344077627,2730485921,1290863460,2820302411,3158454273,3259730800,3505952657,3345764771,106217008,3516065817,3606008344,3600352804,1432725776,4094571909,1467031594,275423344,851169720,430227734,3100823752,506948616,1363258195,659060556,3750685593,883997877,3785050280,958139571,3318307427,1322822218,3812723403,1537002063,2003034995,1747873779,3602036899,1955562222,1575990012,2024104815,1125592928,2227730452,2716904306,2361852424,442776044,2428436474,593698344,2756734187,3733110249,3204031479,2999351573,3329325298,3815920427,3391569614,3928383900,3515267271,566280711,3940187606,3454069534,4118630271,4000239992,116418474,1914138554,174292421,2731055270,289380356,3203993006,460393269,320620315,685471733,587496836,852142971,1086792851,1017036298,365543100,1126000580,2618297676,1288033470,3409855158,1501505948,4234509866,1607167915,987167468,1816402316,1246189591];function _(){if(!(this instanceof _))return new _;v.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=m,this.W=new Array(160)}function b(t,n,r,e,i){var o=t&r^~t&i;return o<0&&(o+=4294967296),o}function w(t,n,r,e,i,o){var s=n&e^~n&o;return s<0&&(s+=4294967296),s}function x(t,n,r,e,i){var o=t&r^t&i^r&i;return o<0&&(o+=4294967296),o}function S(t,n,r,e,i,o){var s=n&e^n&o^e&o;return s<0&&(s+=4294967296),s}function k(t,n){var r=s(t,n,28)^s(n,t,2)^s(n,t,7);return r<0&&(r+=4294967296),r}function L(t,n){var r=h(t,n,28)^h(n,t,2)^h(n,t,7);return r<0&&(r+=4294967296),r}function j(t,n){var r=s(t,n,14)^s(t,n,18)^s(n,t,9);return r<0&&(r+=4294967296),r}function z(t,n){var r=h(t,n,14)^h(t,n,18)^h(n,t,9);return r<0&&(r+=4294967296),r}function A(t,n){var r=s(t,n,1)^s(t,n,8)^u(t,n,7);return r<0&&(r+=4294967296),r}function E(t,n){var r=h(t,n,1)^h(t,n,8)^a(t,n,7);return r<0&&(r+=4294967296),r}function O(t,n){var r=s(t,n,19)^s(n,t,29)^u(t,n,6);return r<0&&(r+=4294967296),r}function T(t,n){var r=h(t,n,19)^h(n,t,29)^a(t,n,6);return r<0&&(r+=4294967296),r}e.inherits(_,v),t.exports=_,_.blockSize=1024,_.outSize=512,_.hmacStrength=192,_.padLength=128,_.prototype._prepareBlock=function(t,n){for(var r=this.W,e=0;e<32;e++)r[e]=t[n+e];for(;e<r.length;e+=2){var i=O(r[e-4],r[e-3]),o=T(r[e-4],r[e-3]),s=r[e-14],h=r[e-13],u=A(r[e-30],r[e-29]),a=E(r[e-30],r[e-29]),c=r[e-32],f=r[e-31];r[e]=p(i,o,s,h,u,a,c,f),r[e+1]=g(i,o,s,h,u,a,c,f)}},_.prototype._update=function(t,n){this._prepareBlock(t,n);var r=this.W,e=this.h[0],i=this.h[1],s=this.h[2],h=this.h[3],u=this.h[4],a=this.h[5],p=this.h[6],g=this.h[7],v=this.h[8],m=this.h[9],_=this.h[10],A=this.h[11],E=this.h[12],O=this.h[13],T=this.h[14],H=this.h[15];o(this.k.length===r.length);for(var B=0;B<r.length;B+=2){var P=T,N=H,R=j(v,m),M=z(v,m),U=b(v,m,_,A,E),C=w(v,m,_,A,E,O),I=this.k[B],W=this.k[B+1],F=r[B],G=r[B+1],q=d(P,N,R,M,U,C,I,W,F,G),D=y(P,N,R,M,U,C,I,W,F,G);P=k(e,i),N=L(e,i),R=x(e,i,s,h,u),M=S(e,i,s,h,u,a);var J=f(P,N,R,M),Y=l(P,N,R,M);T=E,H=O,E=_,O=A,_=v,A=m,v=f(p,g,q,D),m=l(g,g,q,D),p=u,g=a,u=s,a=h,s=e,h=i,e=f(q,D,J,Y),i=l(q,D,J,Y)}c(this.h,0,e,i),c(this.h,2,s,h),c(this.h,4,u,a),c(this.h,6,p,g),c(this.h,8,v,m),c(this.h,10,_,A),c(this.h,12,E,O),c(this.h,14,T,H)},_.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h,"big"):e.split32(this.h,"big")}},function(t,n){function r(t,n,r,e,i,o,s){try{var h=t[o](s),u=h.value}catch(t){return void r(t)}h.done?n(u):Promise.resolve(u).then(e,i)}t.exports=function(t){return function(){var n=this,e=arguments;return new Promise(function(i,o){var s=t.apply(n,e);function h(t){r(s,i,o,h,u,"next",t)}function u(t){r(s,i,o,h,u,"throw",t)}h(void 0)})}}},function(t,n,r){!function(){var n=r(15),e=r(4).utf8,i=r(16),o=r(4).bin,s=function(t,r){t.constructor==String?t=r&&"binary"===r.encoding?o.stringToBytes(t):e.stringToBytes(t):i(t)?t=Array.prototype.slice.call(t,0):Array.isArray(t)||(t=t.toString());for(var h=n.bytesToWords(t),u=8*t.length,a=1732584193,c=-271733879,f=-1732584194,l=271733878,p=0;p<h.length;p++)h[p]=16711935&(h[p]<<8|h[p]>>>24)|4278255360&(h[p]<<24|h[p]>>>8);h[u>>>5]|=128<<u%32,h[14+(u+64>>>9<<4)]=u;var g=s._ff,d=s._gg,y=s._hh,v=s._ii;for(p=0;p<h.length;p+=16){var m=a,_=c,b=f,w=l;c=v(c=v(c=v(c=v(c=y(c=y(c=y(c=y(c=d(c=d(c=d(c=d(c=g(c=g(c=g(c=g(c,f=g(f,l=g(l,a=g(a,c,f,l,h[p+0],7,-680876936),c,f,h[p+1],12,-389564586),a,c,h[p+2],17,606105819),l,a,h[p+3],22,-1044525330),f=g(f,l=g(l,a=g(a,c,f,l,h[p+4],7,-176418897),c,f,h[p+5],12,1200080426),a,c,h[p+6],17,-1473231341),l,a,h[p+7],22,-45705983),f=g(f,l=g(l,a=g(a,c,f,l,h[p+8],7,1770035416),c,f,h[p+9],12,-1958414417),a,c,h[p+10],17,-42063),l,a,h[p+11],22,-1990404162),f=g(f,l=g(l,a=g(a,c,f,l,h[p+12],7,1804603682),c,f,h[p+13],12,-40341101),a,c,h[p+14],17,-1502002290),l,a,h[p+15],22,1236535329),f=d(f,l=d(l,a=d(a,c,f,l,h[p+1],5,-165796510),c,f,h[p+6],9,-1069501632),a,c,h[p+11],14,643717713),l,a,h[p+0],20,-373897302),f=d(f,l=d(l,a=d(a,c,f,l,h[p+5],5,-701558691),c,f,h[p+10],9,38016083),a,c,h[p+15],14,-660478335),l,a,h[p+4],20,-405537848),f=d(f,l=d(l,a=d(a,c,f,l,h[p+9],5,568446438),c,f,h[p+14],9,-1019803690),a,c,h[p+3],14,-187363961),l,a,h[p+8],20,1163531501),f=d(f,l=d(l,a=d(a,c,f,l,h[p+13],5,-1444681467),c,f,h[p+2],9,-51403784),a,c,h[p+7],14,1735328473),l,a,h[p+12],20,-1926607734),f=y(f,l=y(l,a=y(a,c,f,l,h[p+5],4,-378558),c,f,h[p+8],11,-2022574463),a,c,h[p+11],16,1839030562),l,a,h[p+14],23,-35309556),f=y(f,l=y(l,a=y(a,c,f,l,h[p+1],4,-1530992060),c,f,h[p+4],11,1272893353),a,c,h[p+7],16,-155497632),l,a,h[p+10],23,-1094730640),f=y(f,l=y(l,a=y(a,c,f,l,h[p+13],4,681279174),c,f,h[p+0],11,-358537222),a,c,h[p+3],16,-722521979),l,a,h[p+6],23,76029189),f=y(f,l=y(l,a=y(a,c,f,l,h[p+9],4,-640364487),c,f,h[p+12],11,-421815835),a,c,h[p+15],16,530742520),l,a,h[p+2],23,-995338651),f=v(f,l=v(l,a=v(a,c,f,l,h[p+0],6,-198630844),c,f,h[p+7],10,1126891415),a,c,h[p+14],15,-1416354905),l,a,h[p+5],21,-57434055),f=v(f,l=v(l,a=v(a,c,f,l,h[p+12],6,1700485571),c,f,h[p+3],10,-1894986606),a,c,h[p+10],15,-1051523),l,a,h[p+1],21,-2054922799),f=v(f,l=v(l,a=v(a,c,f,l,h[p+8],6,1873313359),c,f,h[p+15],10,-30611744),a,c,h[p+6],15,-1560198380),l,a,h[p+13],21,1309151649),f=v(f,l=v(l,a=v(a,c,f,l,h[p+4],6,-145523070),c,f,h[p+11],10,-1120210379),a,c,h[p+2],15,718787259),l,a,h[p+9],21,-343485551),a=a+m>>>0,c=c+_>>>0,f=f+b>>>0,l=l+w>>>0}return n.endian([a,c,f,l])};s._ff=function(t,n,r,e,i,o,s){var h=t+(n&r|~n&e)+(i>>>0)+s;return(h<<o|h>>>32-o)+n},s._gg=function(t,n,r,e,i,o,s){var h=t+(n&e|r&~e)+(i>>>0)+s;return(h<<o|h>>>32-o)+n},s._hh=function(t,n,r,e,i,o,s){var h=t+(n^r^e)+(i>>>0)+s;return(h<<o|h>>>32-o)+n},s._ii=function(t,n,r,e,i,o,s){var h=t+(r^(n|~e))+(i>>>0)+s;return(h<<o|h>>>32-o)+n},s._blocksize=16,s._digestsize=16,t.exports=function(t,r){if(void 0===t||null===t)throw new Error("Illegal argument "+t);var e=n.wordsToBytes(s(t,r));return r&&r.asBytes?e:r&&r.asString?o.bytesToString(e):n.bytesToHex(e)}}()},function(t,n,r){var e=n;e.utils=r(0),e.common=r(2),e.sha=r(18),e.ripemd=r(22),e.hmac=r(23),e.sha1=e.sha.sha1,e.sha256=e.sha.sha256,e.sha224=e.sha.sha224,e.sha384=e.sha.sha384,e.sha512=e.sha.sha512,e.ripemd160=e.ripemd.ripemd160},function(t,n,r){t.exports=r(24)},function(t,n,r){var e=function(){return this||"object"==typeof self&&self}()||Function("return this")(),i=e.regeneratorRuntime&&Object.getOwnPropertyNames(e).indexOf("regeneratorRuntime")>=0,o=i&&e.regeneratorRuntime;if(e.regeneratorRuntime=void 0,t.exports=r(13),i)e.regeneratorRuntime=o;else try{delete e.regeneratorRuntime}catch(t){e.regeneratorRuntime=void 0}},function(t,n){!function(n){"use strict";var r,e=Object.prototype,i=e.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",h=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag",a="object"==typeof t,c=n.regeneratorRuntime;if(c)a&&(t.exports=c);else{(c=n.regeneratorRuntime=a?t.exports:{}).wrap=b;var f="suspendedStart",l="suspendedYield",p="executing",g="completed",d={},y={};y[s]=function(){return this};var v=Object.getPrototypeOf,m=v&&v(v(T([])));m&&m!==e&&i.call(m,s)&&(y=m);var _=k.prototype=x.prototype=Object.create(y);S.prototype=_.constructor=k,k.constructor=S,k[u]=S.displayName="GeneratorFunction",c.isGeneratorFunction=function(t){var n="function"==typeof t&&t.constructor;return!!n&&(n===S||"GeneratorFunction"===(n.displayName||n.name))},c.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,k):(t.__proto__=k,u in t||(t[u]="GeneratorFunction")),t.prototype=Object.create(_),t},c.awrap=function(t){return{__await:t}},L(j.prototype),j.prototype[h]=function(){return this},c.AsyncIterator=j,c.async=function(t,n,r,e){var i=new j(b(t,n,r,e));return c.isGeneratorFunction(n)?i:i.next().then(function(t){return t.done?t.value:i.next()})},L(_),_[u]="Generator",_[s]=function(){return this},_.toString=function(){return"[object Generator]"},c.keys=function(t){var n=[];for(var r in t)n.push(r);return n.reverse(),function r(){for(;n.length;){var e=n.pop();if(e in t)return r.value=e,r.done=!1,r}return r.done=!0,r}},c.values=T,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(E),!t)for(var n in this)"t"===n.charAt(0)&&i.call(this,n)&&!isNaN(+n.slice(1))&&(this[n]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var n=this;function e(e,i){return h.type="throw",h.arg=t,n.next=e,i&&(n.method="next",n.arg=r),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],h=s.completion;if("root"===s.tryLoc)return e("end");if(s.tryLoc<=this.prev){var u=i.call(s,"catchLoc"),a=i.call(s,"finallyLoc");if(u&&a){if(this.prev<s.catchLoc)return e(s.catchLoc,!0);if(this.prev<s.finallyLoc)return e(s.finallyLoc)}else if(u){if(this.prev<s.catchLoc)return e(s.catchLoc,!0)}else{if(!a)throw new Error("try statement without catch or finally");if(this.prev<s.finallyLoc)return e(s.finallyLoc)}}}},abrupt:function(t,n){for(var r=this.tryEntries.length-1;r>=0;--r){var e=this.tryEntries[r];if(e.tryLoc<=this.prev&&i.call(e,"finallyLoc")&&this.prev<e.finallyLoc){var o=e;break}}o&&("break"===t||"continue"===t)&&o.tryLoc<=n&&n<=o.finallyLoc&&(o=null);var s=o?o.completion:{};return s.type=t,s.arg=n,o?(this.method="next",this.next=o.finallyLoc,d):this.complete(s)},complete:function(t,n){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&n&&(this.next=n),d},finish:function(t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),E(r),d}},catch:function(t){for(var n=this.tryEntries.length-1;n>=0;--n){var r=this.tryEntries[n];if(r.tryLoc===t){var e=r.completion;if("throw"===e.type){var i=e.arg;E(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,n,e){return this.delegate={iterator:T(t),resultName:n,nextLoc:e},"next"===this.method&&(this.arg=r),d}}}function b(t,n,r,e){var i=n&&n.prototype instanceof x?n:x,o=Object.create(i.prototype),s=new O(e||[]);return o._invoke=function(t,n,r){var e=f;return function(i,o){if(e===p)throw new Error("Generator is already running");if(e===g){if("throw"===i)throw o;return H()}for(r.method=i,r.arg=o;;){var s=r.delegate;if(s){var h=z(s,r);if(h){if(h===d)continue;return h}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(e===f)throw e=g,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);e=p;var u=w(t,n,r);if("normal"===u.type){if(e=r.done?g:l,u.arg===d)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(e=g,r.method="throw",r.arg=u.arg)}}}(t,r,s),o}function w(t,n,r){try{return{type:"normal",arg:t.call(n,r)}}catch(t){return{type:"throw",arg:t}}}function x(){}function S(){}function k(){}function L(t){["next","throw","return"].forEach(function(n){t[n]=function(t){return this._invoke(n,t)}})}function j(t){var n;this._invoke=function(r,e){function o(){return new Promise(function(n,o){!function n(r,e,o,s){var h=w(t[r],t,e);if("throw"!==h.type){var u=h.arg,a=u.value;return a&&"object"==typeof a&&i.call(a,"__await")?Promise.resolve(a.__await).then(function(t){n("next",t,o,s)},function(t){n("throw",t,o,s)}):Promise.resolve(a).then(function(t){u.value=t,o(u)},function(t){return n("throw",t,o,s)})}s(h.arg)}(r,e,n,o)})}return n=n?n.then(o,o):o()}}function z(t,n){var e=t.iterator[n.method];if(e===r){if(n.delegate=null,"throw"===n.method){if(t.iterator.return&&(n.method="return",n.arg=r,z(t,n),"throw"===n.method))return d;n.method="throw",n.arg=new TypeError("The iterator does not provide a 'throw' method")}return d}var i=w(e,t.iterator,n.arg);if("throw"===i.type)return n.method="throw",n.arg=i.arg,n.delegate=null,d;var o=i.arg;return o?o.done?(n[t.resultName]=o.value,n.next=t.nextLoc,"return"!==n.method&&(n.method="next",n.arg=r),n.delegate=null,d):o:(n.method="throw",n.arg=new TypeError("iterator result is not an object"),n.delegate=null,d)}function A(t){var n={tryLoc:t[0]};1 in t&&(n.catchLoc=t[1]),2 in t&&(n.finallyLoc=t[2],n.afterLoc=t[3]),this.tryEntries.push(n)}function E(t){var n=t.completion||{};n.type="normal",delete n.arg,t.completion=n}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function T(t){if(t){var n=t[s];if(n)return n.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var e=-1,o=function n(){for(;++e<t.length;)if(i.call(t,e))return n.value=t[e],n.done=!1,n;return n.value=r,n.done=!0,n};return o.next=o}}return{next:H}}function H(){return{value:r,done:!0}}}(function(){return this||"object"==typeof self&&self}()||Function("return this")())},function(n,r){n.exports=t},function(t,n){!function(){var n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",r={rotl:function(t,n){return t<<n|t>>>32-n},rotr:function(t,n){return t<<32-n|t>>>n},endian:function(t){if(t.constructor==Number)return 16711935&r.rotl(t,8)|4278255360&r.rotl(t,24);for(var n=0;n<t.length;n++)t[n]=r.endian(t[n]);return t},randomBytes:function(t){for(var n=[];t>0;t--)n.push(Math.floor(256*Math.random()));return n},bytesToWords:function(t){for(var n=[],r=0,e=0;r<t.length;r++,e+=8)n[e>>>5]|=t[r]<<24-e%32;return n},wordsToBytes:function(t){for(var n=[],r=0;r<32*t.length;r+=8)n.push(t[r>>>5]>>>24-r%32&255);return n},bytesToHex:function(t){for(var n=[],r=0;r<t.length;r++)n.push((t[r]>>>4).toString(16)),n.push((15&t[r]).toString(16));return n.join("")},hexToBytes:function(t){for(var n=[],r=0;r<t.length;r+=2)n.push(parseInt(t.substr(r,2),16));return n},bytesToBase64:function(t){for(var r=[],e=0;e<t.length;e+=3)for(var i=t[e]<<16|t[e+1]<<8|t[e+2],o=0;o<4;o++)8*e+6*o<=8*t.length?r.push(n.charAt(i>>>6*(3-o)&63)):r.push("=");return r.join("")},base64ToBytes:function(t){t=t.replace(/[^A-Z0-9+\/]/gi,"");for(var r=[],e=0,i=0;e<t.length;i=++e%4)0!=i&&r.push((n.indexOf(t.charAt(e-1))&Math.pow(2,-2*i+8)-1)<<2*i|n.indexOf(t.charAt(e))>>>6-2*i);return r}};t.exports=r}()},function(t,n){function r(t){return!!t.constructor&&"function"==typeof t.constructor.isBuffer&&t.constructor.isBuffer(t)}
/*!

@@ -8,9 +8,2 @@ * Determine if an object is a Buffer

*/
t.exports=function(t){return null!=t&&(e(t)||function(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&e(t.slice(0,0))}(t)||!!t._isBuffer)}},function(t,r,e){var n=e(1),i=e(2),o=e(0).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],h=new Array(80);function u(){this.init(),this._w=h,i.call(this,64,56)}function f(t){return t<<5|t>>>27}function a(t){return t<<30|t>>>2}function c(t,r,e,n){return 0===t?r&e|~r&n:2===t?r&e|r&n|e&n:r^e^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var r=this._w,e=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,h=0|this._e,u=0;u<16;++u)r[u]=t.readInt32BE(4*u);for(;u<80;++u)r[u]=r[u-3]^r[u-8]^r[u-14]^r[u-16];for(var l=0;l<80;++l){var p=~~(l/20),_=f(e)+c(p,n,i,o)+h+r[l]+s[p]|0;h=o,o=i,i=a(n),n=e,e=_}this._a=e+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=h+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,r,e){"use strict";(function(t){
/*!
* The buffer module from node.js, for the browser.
*
* @author Feross Aboukhadijeh <feross@feross.org> <http://feross.org>
* @license MIT
*/
var n=e(19),i=e(20),o=e(21);function s(){return u.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function h(t,r){if(s()<r)throw new RangeError("Invalid typed array length");return u.TYPED_ARRAY_SUPPORT?(t=new Uint8Array(r)).__proto__=u.prototype:(null===t&&(t=new u(r)),t.length=r),t}function u(t,r,e){if(!(u.TYPED_ARRAY_SUPPORT||this instanceof u))return new u(t,r,e);if("number"==typeof t){if("string"==typeof r)throw new Error("If encoding is specified then the first argument must be a string");return c(this,t)}return f(this,t,r,e)}function f(t,r,e,n){if("number"==typeof r)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&r instanceof ArrayBuffer?function(t,r,e,n){if(r.byteLength,e<0||r.byteLength<e)throw new RangeError("'offset' is out of bounds");if(r.byteLength<e+(n||0))throw new RangeError("'length' is out of bounds");r=void 0===e&&void 0===n?new Uint8Array(r):void 0===n?new Uint8Array(r,e):new Uint8Array(r,e,n);u.TYPED_ARRAY_SUPPORT?(t=r).__proto__=u.prototype:t=l(t,r);return t}(t,r,e,n):"string"==typeof r?function(t,r,e){"string"==typeof e&&""!==e||(e="utf8");if(!u.isEncoding(e))throw new TypeError('"encoding" must be a valid string encoding');var n=0|_(r,e),i=(t=h(t,n)).write(r,e);i!==n&&(t=t.slice(0,i));return t}(t,r,e):function(t,r){if(u.isBuffer(r)){var e=0|p(r.length);return 0===(t=h(t,e)).length?t:(r.copy(t,0,0,e),t)}if(r){if("undefined"!=typeof ArrayBuffer&&r.buffer instanceof ArrayBuffer||"length"in r)return"number"!=typeof r.length||function(t){return t!=t}(r.length)?h(t,0):l(t,r);if("Buffer"===r.type&&o(r.data))return l(t,r.data)}throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(t,r)}function a(t){if("number"!=typeof t)throw new TypeError('"size" argument must be a number');if(t<0)throw new RangeError('"size" argument must not be negative')}function c(t,r){if(a(r),t=h(t,r<0?0:0|p(r)),!u.TYPED_ARRAY_SUPPORT)for(var e=0;e<r;++e)t[e]=0;return t}function l(t,r){var e=r.length<0?0:0|p(r.length);t=h(t,e);for(var n=0;n<e;n+=1)t[n]=255&r[n];return t}function p(t){if(t>=s())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+s().toString(16)+" bytes");return 0|t}function _(t,r){if(u.isBuffer(t))return t.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(t)||t instanceof ArrayBuffer))return t.byteLength;"string"!=typeof t&&(t=""+t);var e=t.length;if(0===e)return 0;for(var n=!1;;)switch(r){case"ascii":case"latin1":case"binary":return e;case"utf8":case"utf-8":case void 0:return D(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*e;case"hex":return e>>>1;case"base64":return z(t).length;default:if(n)return D(t).length;r=(""+r).toLowerCase(),n=!0}}function y(t,r,e){var n=t[r];t[r]=t[e],t[e]=n}function g(t,r,e,n,i){if(0===t.length)return-1;if("string"==typeof e?(n=e,e=0):e>2147483647?e=2147483647:e<-2147483648&&(e=-2147483648),e=+e,isNaN(e)&&(e=i?0:t.length-1),e<0&&(e=t.length+e),e>=t.length){if(i)return-1;e=t.length-1}else if(e<0){if(!i)return-1;e=0}if("string"==typeof r&&(r=u.from(r,n)),u.isBuffer(r))return 0===r.length?-1:d(t,r,e,n,i);if("number"==typeof r)return r&=255,u.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?i?Uint8Array.prototype.indexOf.call(t,r,e):Uint8Array.prototype.lastIndexOf.call(t,r,e):d(t,[r],e,n,i);throw new TypeError("val must be string, number or Buffer")}function d(t,r,e,n,i){var o,s=1,h=t.length,u=r.length;if(void 0!==n&&("ucs2"===(n=String(n).toLowerCase())||"ucs-2"===n||"utf16le"===n||"utf-16le"===n)){if(t.length<2||r.length<2)return-1;s=2,h/=2,u/=2,e/=2}function f(t,r){return 1===s?t[r]:t.readUInt16BE(r*s)}if(i){var a=-1;for(o=e;o<h;o++)if(f(t,o)===f(r,-1===a?0:o-a)){if(-1===a&&(a=o),o-a+1===u)return a*s}else-1!==a&&(o-=o-a),a=-1}else for(e+u>h&&(e=h-u),o=e;o>=0;o--){for(var c=!0,l=0;l<u;l++)if(f(t,o+l)!==f(r,l)){c=!1;break}if(c)return o}return-1}function w(t,r,e,n){e=Number(e)||0;var i=t.length-e;n?(n=Number(n))>i&&(n=i):n=i;var o=r.length;if(o%2!=0)throw new TypeError("Invalid hex string");n>o/2&&(n=o/2);for(var s=0;s<n;++s){var h=parseInt(r.substr(2*s,2),16);if(isNaN(h))return s;t[e+s]=h}return s}function v(t,r,e,n){return F(D(r,t.length-e),t,e,n)}function b(t,r,e,n){return F(function(t){for(var r=[],e=0;e<t.length;++e)r.push(255&t.charCodeAt(e));return r}(r),t,e,n)}function m(t,r,e,n){return b(t,r,e,n)}function E(t,r,e,n){return F(z(r),t,e,n)}function A(t,r,e,n){return F(function(t,r){for(var e,n,i,o=[],s=0;s<t.length&&!((r-=2)<0);++s)e=t.charCodeAt(s),n=e>>8,i=e%256,o.push(i),o.push(n);return o}(r,t.length-e),t,e,n)}function B(t,r,e){return 0===r&&e===t.length?n.fromByteArray(t):n.fromByteArray(t.slice(r,e))}function x(t,r,e){e=Math.min(t.length,e);for(var n=[],i=r;i<e;){var o,s,h,u,f=t[i],a=null,c=f>239?4:f>223?3:f>191?2:1;if(i+c<=e)switch(c){case 1:f<128&&(a=f);break;case 2:128==(192&(o=t[i+1]))&&(u=(31&f)<<6|63&o)>127&&(a=u);break;case 3:o=t[i+1],s=t[i+2],128==(192&o)&&128==(192&s)&&(u=(15&f)<<12|(63&o)<<6|63&s)>2047&&(u<55296||u>57343)&&(a=u);break;case 4:o=t[i+1],s=t[i+2],h=t[i+3],128==(192&o)&&128==(192&s)&&128==(192&h)&&(u=(15&f)<<18|(63&o)<<12|(63&s)<<6|63&h)>65535&&u<1114112&&(a=u)}null===a?(a=65533,c=1):a>65535&&(a-=65536,n.push(a>>>10&1023|55296),a=56320|1023&a),n.push(a),i+=c}return function(t){var r=t.length;if(r<=R)return String.fromCharCode.apply(String,t);var e="",n=0;for(;n<r;)e+=String.fromCharCode.apply(String,t.slice(n,n+=R));return e}(n)}r.Buffer=u,r.SlowBuffer=function(t){+t!=t&&(t=0);return u.alloc(+t)},r.INSPECT_MAX_BYTES=50,u.TYPED_ARRAY_SUPPORT=void 0!==t.TYPED_ARRAY_SUPPORT?t.TYPED_ARRAY_SUPPORT:function(){try{var t=new Uint8Array(1);return t.__proto__={__proto__:Uint8Array.prototype,foo:function(){return 42}},42===t.foo()&&"function"==typeof t.subarray&&0===t.subarray(1,1).byteLength}catch(t){return!1}}(),r.kMaxLength=s(),u.poolSize=8192,u._augment=function(t){return t.__proto__=u.prototype,t},u.from=function(t,r,e){return f(null,t,r,e)},u.TYPED_ARRAY_SUPPORT&&(u.prototype.__proto__=Uint8Array.prototype,u.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&u[Symbol.species]===u&&Object.defineProperty(u,Symbol.species,{value:null,configurable:!0})),u.alloc=function(t,r,e){return function(t,r,e,n){return a(r),r<=0?h(t,r):void 0!==e?"string"==typeof n?h(t,r).fill(e,n):h(t,r).fill(e):h(t,r)}(null,t,r,e)},u.allocUnsafe=function(t){return c(null,t)},u.allocUnsafeSlow=function(t){return c(null,t)},u.isBuffer=function(t){return!(null==t||!t._isBuffer)},u.compare=function(t,r){if(!u.isBuffer(t)||!u.isBuffer(r))throw new TypeError("Arguments must be Buffers");if(t===r)return 0;for(var e=t.length,n=r.length,i=0,o=Math.min(e,n);i<o;++i)if(t[i]!==r[i]){e=t[i],n=r[i];break}return e<n?-1:n<e?1:0},u.isEncoding=function(t){switch(String(t).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},u.concat=function(t,r){if(!o(t))throw new TypeError('"list" argument must be an Array of Buffers');if(0===t.length)return u.alloc(0);var e;if(void 0===r)for(r=0,e=0;e<t.length;++e)r+=t[e].length;var n=u.allocUnsafe(r),i=0;for(e=0;e<t.length;++e){var s=t[e];if(!u.isBuffer(s))throw new TypeError('"list" argument must be an Array of Buffers');s.copy(n,i),i+=s.length}return n},u.byteLength=_,u.prototype._isBuffer=!0,u.prototype.swap16=function(){var t=this.length;if(t%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var r=0;r<t;r+=2)y(this,r,r+1);return this},u.prototype.swap32=function(){var t=this.length;if(t%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var r=0;r<t;r+=4)y(this,r,r+3),y(this,r+1,r+2);return this},u.prototype.swap64=function(){var t=this.length;if(t%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var r=0;r<t;r+=8)y(this,r,r+7),y(this,r+1,r+6),y(this,r+2,r+5),y(this,r+3,r+4);return this},u.prototype.toString=function(){var t=0|this.length;return 0===t?"":0===arguments.length?x(this,0,t):function(t,r,e){var n=!1;if((void 0===r||r<0)&&(r=0),r>this.length)return"";if((void 0===e||e>this.length)&&(e=this.length),e<=0)return"";if((e>>>=0)<=(r>>>=0))return"";for(t||(t="utf8");;)switch(t){case"hex":return I(this,r,e);case"utf8":case"utf-8":return x(this,r,e);case"ascii":return S(this,r,e);case"latin1":case"binary":return T(this,r,e);case"base64":return B(this,r,e);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return P(this,r,e);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}.apply(this,arguments)},u.prototype.equals=function(t){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");return this===t||0===u.compare(this,t)},u.prototype.inspect=function(){var t="",e=r.INSPECT_MAX_BYTES;return this.length>0&&(t=this.toString("hex",0,e).match(/.{2}/g).join(" "),this.length>e&&(t+=" ... ")),"<Buffer "+t+">"},u.prototype.compare=function(t,r,e,n,i){if(!u.isBuffer(t))throw new TypeError("Argument must be a Buffer");if(void 0===r&&(r=0),void 0===e&&(e=t?t.length:0),void 0===n&&(n=0),void 0===i&&(i=this.length),r<0||e>t.length||n<0||i>this.length)throw new RangeError("out of range index");if(n>=i&&r>=e)return 0;if(n>=i)return-1;if(r>=e)return 1;if(r>>>=0,e>>>=0,n>>>=0,i>>>=0,this===t)return 0;for(var o=i-n,s=e-r,h=Math.min(o,s),f=this.slice(n,i),a=t.slice(r,e),c=0;c<h;++c)if(f[c]!==a[c]){o=f[c],s=a[c];break}return o<s?-1:s<o?1:0},u.prototype.includes=function(t,r,e){return-1!==this.indexOf(t,r,e)},u.prototype.indexOf=function(t,r,e){return g(this,t,r,e,!0)},u.prototype.lastIndexOf=function(t,r,e){return g(this,t,r,e,!1)},u.prototype.write=function(t,r,e,n){if(void 0===r)n="utf8",e=this.length,r=0;else if(void 0===e&&"string"==typeof r)n=r,e=this.length,r=0;else{if(!isFinite(r))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");r|=0,isFinite(e)?(e|=0,void 0===n&&(n="utf8")):(n=e,e=void 0)}var i=this.length-r;if((void 0===e||e>i)&&(e=i),t.length>0&&(e<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");n||(n="utf8");for(var o=!1;;)switch(n){case"hex":return w(this,t,r,e);case"utf8":case"utf-8":return v(this,t,r,e);case"ascii":return b(this,t,r,e);case"latin1":case"binary":return m(this,t,r,e);case"base64":return E(this,t,r,e);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return A(this,t,r,e);default:if(o)throw new TypeError("Unknown encoding: "+n);n=(""+n).toLowerCase(),o=!0}},u.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var R=4096;function S(t,r,e){var n="";e=Math.min(t.length,e);for(var i=r;i<e;++i)n+=String.fromCharCode(127&t[i]);return n}function T(t,r,e){var n="";e=Math.min(t.length,e);for(var i=r;i<e;++i)n+=String.fromCharCode(t[i]);return n}function I(t,r,e){var n=t.length;(!r||r<0)&&(r=0),(!e||e<0||e>n)&&(e=n);for(var i="",o=r;o<e;++o)i+=N(t[o]);return i}function P(t,r,e){for(var n=t.slice(r,e),i="",o=0;o<n.length;o+=2)i+=String.fromCharCode(n[o]+256*n[o+1]);return i}function U(t,r,e){if(t%1!=0||t<0)throw new RangeError("offset is not uint");if(t+r>e)throw new RangeError("Trying to access beyond buffer length")}function L(t,r,e,n,i,o){if(!u.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(r>i||r<o)throw new RangeError('"value" argument is out of bounds');if(e+n>t.length)throw new RangeError("Index out of range")}function O(t,r,e,n){r<0&&(r=65535+r+1);for(var i=0,o=Math.min(t.length-e,2);i<o;++i)t[e+i]=(r&255<<8*(n?i:1-i))>>>8*(n?i:1-i)}function k(t,r,e,n){r<0&&(r=4294967295+r+1);for(var i=0,o=Math.min(t.length-e,4);i<o;++i)t[e+i]=r>>>8*(n?i:3-i)&255}function Y(t,r,e,n,i,o){if(e+n>t.length)throw new RangeError("Index out of range");if(e<0)throw new RangeError("Index out of range")}function j(t,r,e,n,o){return o||Y(t,0,e,4),i.write(t,r,e,n,23,4),e+4}function C(t,r,e,n,o){return o||Y(t,0,e,8),i.write(t,r,e,n,52,8),e+8}u.prototype.slice=function(t,r){var e,n=this.length;if(t=~~t,r=void 0===r?n:~~r,t<0?(t+=n)<0&&(t=0):t>n&&(t=n),r<0?(r+=n)<0&&(r=0):r>n&&(r=n),r<t&&(r=t),u.TYPED_ARRAY_SUPPORT)(e=this.subarray(t,r)).__proto__=u.prototype;else{var i=r-t;e=new u(i,void 0);for(var o=0;o<i;++o)e[o]=this[o+t]}return e},u.prototype.readUIntLE=function(t,r,e){t|=0,r|=0,e||U(t,r,this.length);for(var n=this[t],i=1,o=0;++o<r&&(i*=256);)n+=this[t+o]*i;return n},u.prototype.readUIntBE=function(t,r,e){t|=0,r|=0,e||U(t,r,this.length);for(var n=this[t+--r],i=1;r>0&&(i*=256);)n+=this[t+--r]*i;return n},u.prototype.readUInt8=function(t,r){return r||U(t,1,this.length),this[t]},u.prototype.readUInt16LE=function(t,r){return r||U(t,2,this.length),this[t]|this[t+1]<<8},u.prototype.readUInt16BE=function(t,r){return r||U(t,2,this.length),this[t]<<8|this[t+1]},u.prototype.readUInt32LE=function(t,r){return r||U(t,4,this.length),(this[t]|this[t+1]<<8|this[t+2]<<16)+16777216*this[t+3]},u.prototype.readUInt32BE=function(t,r){return r||U(t,4,this.length),16777216*this[t]+(this[t+1]<<16|this[t+2]<<8|this[t+3])},u.prototype.readIntLE=function(t,r,e){t|=0,r|=0,e||U(t,r,this.length);for(var n=this[t],i=1,o=0;++o<r&&(i*=256);)n+=this[t+o]*i;return n>=(i*=128)&&(n-=Math.pow(2,8*r)),n},u.prototype.readIntBE=function(t,r,e){t|=0,r|=0,e||U(t,r,this.length);for(var n=r,i=1,o=this[t+--n];n>0&&(i*=256);)o+=this[t+--n]*i;return o>=(i*=128)&&(o-=Math.pow(2,8*r)),o},u.prototype.readInt8=function(t,r){return r||U(t,1,this.length),128&this[t]?-1*(255-this[t]+1):this[t]},u.prototype.readInt16LE=function(t,r){r||U(t,2,this.length);var e=this[t]|this[t+1]<<8;return 32768&e?4294901760|e:e},u.prototype.readInt16BE=function(t,r){r||U(t,2,this.length);var e=this[t+1]|this[t]<<8;return 32768&e?4294901760|e:e},u.prototype.readInt32LE=function(t,r){return r||U(t,4,this.length),this[t]|this[t+1]<<8|this[t+2]<<16|this[t+3]<<24},u.prototype.readInt32BE=function(t,r){return r||U(t,4,this.length),this[t]<<24|this[t+1]<<16|this[t+2]<<8|this[t+3]},u.prototype.readFloatLE=function(t,r){return r||U(t,4,this.length),i.read(this,t,!0,23,4)},u.prototype.readFloatBE=function(t,r){return r||U(t,4,this.length),i.read(this,t,!1,23,4)},u.prototype.readDoubleLE=function(t,r){return r||U(t,8,this.length),i.read(this,t,!0,52,8)},u.prototype.readDoubleBE=function(t,r){return r||U(t,8,this.length),i.read(this,t,!1,52,8)},u.prototype.writeUIntLE=function(t,r,e,n){(t=+t,r|=0,e|=0,n)||L(this,t,r,e,Math.pow(2,8*e)-1,0);var i=1,o=0;for(this[r]=255&t;++o<e&&(i*=256);)this[r+o]=t/i&255;return r+e},u.prototype.writeUIntBE=function(t,r,e,n){(t=+t,r|=0,e|=0,n)||L(this,t,r,e,Math.pow(2,8*e)-1,0);var i=e-1,o=1;for(this[r+i]=255&t;--i>=0&&(o*=256);)this[r+i]=t/o&255;return r+e},u.prototype.writeUInt8=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,1,255,0),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),this[r]=255&t,r+1},u.prototype.writeUInt16LE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[r]=255&t,this[r+1]=t>>>8):O(this,t,r,!0),r+2},u.prototype.writeUInt16BE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,2,65535,0),u.TYPED_ARRAY_SUPPORT?(this[r]=t>>>8,this[r+1]=255&t):O(this,t,r,!1),r+2},u.prototype.writeUInt32LE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[r+3]=t>>>24,this[r+2]=t>>>16,this[r+1]=t>>>8,this[r]=255&t):k(this,t,r,!0),r+4},u.prototype.writeUInt32BE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,4,4294967295,0),u.TYPED_ARRAY_SUPPORT?(this[r]=t>>>24,this[r+1]=t>>>16,this[r+2]=t>>>8,this[r+3]=255&t):k(this,t,r,!1),r+4},u.prototype.writeIntLE=function(t,r,e,n){if(t=+t,r|=0,!n){var i=Math.pow(2,8*e-1);L(this,t,r,e,i-1,-i)}var o=0,s=1,h=0;for(this[r]=255&t;++o<e&&(s*=256);)t<0&&0===h&&0!==this[r+o-1]&&(h=1),this[r+o]=(t/s>>0)-h&255;return r+e},u.prototype.writeIntBE=function(t,r,e,n){if(t=+t,r|=0,!n){var i=Math.pow(2,8*e-1);L(this,t,r,e,i-1,-i)}var o=e-1,s=1,h=0;for(this[r+o]=255&t;--o>=0&&(s*=256);)t<0&&0===h&&0!==this[r+o+1]&&(h=1),this[r+o]=(t/s>>0)-h&255;return r+e},u.prototype.writeInt8=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,1,127,-128),u.TYPED_ARRAY_SUPPORT||(t=Math.floor(t)),t<0&&(t=255+t+1),this[r]=255&t,r+1},u.prototype.writeInt16LE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[r]=255&t,this[r+1]=t>>>8):O(this,t,r,!0),r+2},u.prototype.writeInt16BE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,2,32767,-32768),u.TYPED_ARRAY_SUPPORT?(this[r]=t>>>8,this[r+1]=255&t):O(this,t,r,!1),r+2},u.prototype.writeInt32LE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,4,2147483647,-2147483648),u.TYPED_ARRAY_SUPPORT?(this[r]=255&t,this[r+1]=t>>>8,this[r+2]=t>>>16,this[r+3]=t>>>24):k(this,t,r,!0),r+4},u.prototype.writeInt32BE=function(t,r,e){return t=+t,r|=0,e||L(this,t,r,4,2147483647,-2147483648),t<0&&(t=4294967295+t+1),u.TYPED_ARRAY_SUPPORT?(this[r]=t>>>24,this[r+1]=t>>>16,this[r+2]=t>>>8,this[r+3]=255&t):k(this,t,r,!1),r+4},u.prototype.writeFloatLE=function(t,r,e){return j(this,t,r,!0,e)},u.prototype.writeFloatBE=function(t,r,e){return j(this,t,r,!1,e)},u.prototype.writeDoubleLE=function(t,r,e){return C(this,t,r,!0,e)},u.prototype.writeDoubleBE=function(t,r,e){return C(this,t,r,!1,e)},u.prototype.copy=function(t,r,e,n){if(e||(e=0),n||0===n||(n=this.length),r>=t.length&&(r=t.length),r||(r=0),n>0&&n<e&&(n=e),n===e)return 0;if(0===t.length||0===this.length)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(e<0||e>=this.length)throw new RangeError("sourceStart out of bounds");if(n<0)throw new RangeError("sourceEnd out of bounds");n>this.length&&(n=this.length),t.length-r<n-e&&(n=t.length-r+e);var i,o=n-e;if(this===t&&e<r&&r<n)for(i=o-1;i>=0;--i)t[i+r]=this[i+e];else if(o<1e3||!u.TYPED_ARRAY_SUPPORT)for(i=0;i<o;++i)t[i+r]=this[i+e];else Uint8Array.prototype.set.call(t,this.subarray(e,e+o),r);return o},u.prototype.fill=function(t,r,e,n){if("string"==typeof t){if("string"==typeof r?(n=r,r=0,e=this.length):"string"==typeof e&&(n=e,e=this.length),1===t.length){var i=t.charCodeAt(0);i<256&&(t=i)}if(void 0!==n&&"string"!=typeof n)throw new TypeError("encoding must be a string");if("string"==typeof n&&!u.isEncoding(n))throw new TypeError("Unknown encoding: "+n)}else"number"==typeof t&&(t&=255);if(r<0||this.length<r||this.length<e)throw new RangeError("Out of range index");if(e<=r)return this;var o;if(r>>>=0,e=void 0===e?this.length:e>>>0,t||(t=0),"number"==typeof t)for(o=r;o<e;++o)this[o]=t;else{var s=u.isBuffer(t)?t:D(new u(t,n).toString()),h=s.length;for(o=0;o<e-r;++o)this[o+r]=s[o%h]}return this};var M=/[^+\/0-9A-Za-z-_]/g;function N(t){return t<16?"0"+t.toString(16):t.toString(16)}function D(t,r){var e;r=r||1/0;for(var n=t.length,i=null,o=[],s=0;s<n;++s){if((e=t.charCodeAt(s))>55295&&e<57344){if(!i){if(e>56319){(r-=3)>-1&&o.push(239,191,189);continue}if(s+1===n){(r-=3)>-1&&o.push(239,191,189);continue}i=e;continue}if(e<56320){(r-=3)>-1&&o.push(239,191,189),i=e;continue}e=65536+(i-55296<<10|e-56320)}else i&&(r-=3)>-1&&o.push(239,191,189);if(i=null,e<128){if((r-=1)<0)break;o.push(e)}else if(e<2048){if((r-=2)<0)break;o.push(e>>6|192,63&e|128)}else if(e<65536){if((r-=3)<0)break;o.push(e>>12|224,e>>6&63|128,63&e|128)}else{if(!(e<1114112))throw new Error("Invalid code point");if((r-=4)<0)break;o.push(e>>18|240,e>>12&63|128,e>>6&63|128,63&e|128)}}return o}function z(t){return n.toByteArray(function(t){if((t=function(t){return t.trim?t.trim():t.replace(/^\s+|\s+$/g,"")}(t).replace(M,"")).length<2)return"";for(;t.length%4!=0;)t+="=";return t}(t))}function F(t,r,e,n){for(var i=0;i<n&&!(i+e>=r.length||i>=t.length);++i)r[i+e]=t[i];return i}}).call(this,e(18))},function(t,r){var e;e=function(){return this}();try{e=e||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(e=window)}t.exports=e},function(t,r,e){"use strict";r.byteLength=function(t){var r=f(t),e=r[0],n=r[1];return 3*(e+n)/4-n},r.toByteArray=function(t){for(var r,e=f(t),n=e[0],s=e[1],h=new o(function(t,r,e){return 3*(r+e)/4-e}(0,n,s)),u=0,a=s>0?n-4:n,c=0;c<a;c+=4)r=i[t.charCodeAt(c)]<<18|i[t.charCodeAt(c+1)]<<12|i[t.charCodeAt(c+2)]<<6|i[t.charCodeAt(c+3)],h[u++]=r>>16&255,h[u++]=r>>8&255,h[u++]=255&r;2===s&&(r=i[t.charCodeAt(c)]<<2|i[t.charCodeAt(c+1)]>>4,h[u++]=255&r);1===s&&(r=i[t.charCodeAt(c)]<<10|i[t.charCodeAt(c+1)]<<4|i[t.charCodeAt(c+2)]>>2,h[u++]=r>>8&255,h[u++]=255&r);return h},r.fromByteArray=function(t){for(var r,e=t.length,i=e%3,o=[],s=0,h=e-i;s<h;s+=16383)o.push(c(t,s,s+16383>h?h:s+16383));1===i?(r=t[e-1],o.push(n[r>>2]+n[r<<4&63]+"==")):2===i&&(r=(t[e-2]<<8)+t[e-1],o.push(n[r>>10]+n[r>>4&63]+n[r<<2&63]+"="));return o.join("")};for(var n=[],i=[],o="undefined"!=typeof Uint8Array?Uint8Array:Array,s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",h=0,u=s.length;h<u;++h)n[h]=s[h],i[s.charCodeAt(h)]=h;function f(t){var r=t.length;if(r%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var e=t.indexOf("=");return-1===e&&(e=r),[e,e===r?0:4-e%4]}function a(t){return n[t>>18&63]+n[t>>12&63]+n[t>>6&63]+n[63&t]}function c(t,r,e){for(var n,i=[],o=r;o<e;o+=3)n=(t[o]<<16&16711680)+(t[o+1]<<8&65280)+(255&t[o+2]),i.push(a(n));return i.join("")}i["-".charCodeAt(0)]=62,i["_".charCodeAt(0)]=63},function(t,r){r.read=function(t,r,e,n,i){var o,s,h=8*i-n-1,u=(1<<h)-1,f=u>>1,a=-7,c=e?i-1:0,l=e?-1:1,p=t[r+c];for(c+=l,o=p&(1<<-a)-1,p>>=-a,a+=h;a>0;o=256*o+t[r+c],c+=l,a-=8);for(s=o&(1<<-a)-1,o>>=-a,a+=n;a>0;s=256*s+t[r+c],c+=l,a-=8);if(0===o)o=1-f;else{if(o===u)return s?NaN:1/0*(p?-1:1);s+=Math.pow(2,n),o-=f}return(p?-1:1)*s*Math.pow(2,o-n)},r.write=function(t,r,e,n,i,o){var s,h,u,f=8*o-i-1,a=(1<<f)-1,c=a>>1,l=23===i?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:o-1,_=n?1:-1,y=r<0||0===r&&1/r<0?1:0;for(r=Math.abs(r),isNaN(r)||r===1/0?(h=isNaN(r)?1:0,s=a):(s=Math.floor(Math.log(r)/Math.LN2),r*(u=Math.pow(2,-s))<1&&(s--,u*=2),(r+=s+c>=1?l/u:l*Math.pow(2,1-c))*u>=2&&(s++,u/=2),s+c>=a?(h=0,s=a):s+c>=1?(h=(r*u-1)*Math.pow(2,i),s+=c):(h=r*Math.pow(2,c-1)*Math.pow(2,i),s=0));i>=8;t[e+p]=255&h,p+=_,h/=256,i-=8);for(s=s<<i|h,f+=i;f>0;t[e+p]=255&s,p+=_,s/=256,f-=8);t[e+p-_]|=128*y}},function(t,r){var e={}.toString;t.exports=Array.isArray||function(t){return"[object Array]"==e.call(t)}},function(t,r,e){var n=e(1),i=e(2),o=e(0).Buffer,s=[1518500249,1859775393,-1894007588,-899497514],h=new Array(80);function u(){this.init(),this._w=h,i.call(this,64,56)}function f(t){return t<<1|t>>>31}function a(t){return t<<5|t>>>27}function c(t){return t<<30|t>>>2}function l(t,r,e,n){return 0===t?r&e|~r&n:2===t?r&e|r&n|e&n:r^e^n}n(u,i),u.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},u.prototype._update=function(t){for(var r=this._w,e=0|this._a,n=0|this._b,i=0|this._c,o=0|this._d,h=0|this._e,u=0;u<16;++u)r[u]=t.readInt32BE(4*u);for(;u<80;++u)r[u]=f(r[u-3]^r[u-8]^r[u-14]^r[u-16]);for(var p=0;p<80;++p){var _=~~(p/20),y=a(e)+l(_,n,i,o)+h+r[p]+s[_]|0;h=o,o=i,i=c(n),n=e,e=y}this._a=e+this._a|0,this._b=n+this._b|0,this._c=i+this._c|0,this._d=o+this._d|0,this._e=h+this._e|0},u.prototype._hash=function(){var t=o.allocUnsafe(20);return t.writeInt32BE(0|this._a,0),t.writeInt32BE(0|this._b,4),t.writeInt32BE(0|this._c,8),t.writeInt32BE(0|this._d,12),t.writeInt32BE(0|this._e,16),t},t.exports=u},function(t,r,e){var n=e(1),i=e(5),o=e(2),s=e(0).Buffer,h=new Array(64);function u(){this.init(),this._w=h,o.call(this,64,56)}n(u,i),u.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},u.prototype._hash=function(){var t=s.allocUnsafe(28);return t.writeInt32BE(this._a,0),t.writeInt32BE(this._b,4),t.writeInt32BE(this._c,8),t.writeInt32BE(this._d,12),t.writeInt32BE(this._e,16),t.writeInt32BE(this._f,20),t.writeInt32BE(this._g,24),t},t.exports=u},function(t,r,e){var n=e(1),i=e(6),o=e(2),s=e(0).Buffer,h=new Array(160);function u(){this.init(),this._w=h,o.call(this,128,112)}n(u,i),u.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},u.prototype._hash=function(){var t=s.allocUnsafe(48);function r(r,e,n){t.writeInt32BE(r,n),t.writeInt32BE(e,n+4)}return r(this._ah,this._al,0),r(this._bh,this._bl,8),r(this._ch,this._cl,16),r(this._dh,this._dl,24),r(this._eh,this._el,32),r(this._fh,this._fl,40),t},t.exports=u},function(t,r,e){"use strict";e.r(r);var n=e(3),i=e.n(n),o=e(7),s=e.n(o);function h(){if("undefined"!=typeof window)return window.crypto?window.crypto.subtle:void 0}function u(){if("undefined"!=typeof window&&!window.crypto)return window.msCrypto?window.msCrypto.subtle:void 0}var f={hashes:{"SHA-256":{nodeName:"sha256",hashSize:32},"SHA-384":{nodeName:"sha384",hashSize:48},"SHA-512":{nodeName:"sha512",hashSize:64},"SHA-1":{nodeName:"sha1",hashSize:20},MD5:{nodeName:"md5",hashSize:16}}},a=e(8),c=e.n(a),l=e(9),p=e.n(l);function _(t){return y.apply(this,arguments)}function y(){return(y=s()(i.a.mark(function t(r){var n,o,s,a,c,l,p,_,y,d=arguments;return i.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(n=d.length>1&&void 0!==d[1]?d[1]:"SHA-256",!(Object.keys(f.hashes).indexOf(n)<0)){t.next=3;break}throw new Error("UnsupportedHashAlgorithm");case 3:if(r instanceof Uint8Array){t.next=5;break}throw new Error("UnsupportedMessageType");case 5:if(o=h(),s="undefined"!=typeof window?void 0:e(13),a=u(),l=!0,void 0===o||"function"!=typeof o.digest||void 0!==a){t.next=15;break}return t.next=12,o.digest(n,r).catch(function(){return l=!1});case 12:c=t.sent,t.next=27;break;case 15:if(void 0===s){t.next=19;break}try{p=f.hashes[n].nodeName,(_=s.createHash(p)).update(r),c=_.digest()}catch(t){l=!1}t.next=27;break;case 19:if(void 0===a||"function"!=typeof a.digest){t.next=26;break}return y=function(t,r){return new Promise(function(e,n){var i=window.msCrypto.subtle.digest(t,r);i.oncomplete=function(t){e(t.target.result)},i.onerror=function(t){n(t)}})},t.next=23,y(n,r).catch(function(t){return l=!1});case 23:c=t.sent,t.next=27;break;case 26:l=!1;case 27:if(l){t.next=35;break}t.prev=28,c=g(n,r),t.next=35;break;case 32:throw t.prev=32,t.t0=t.catch(28),new Error("UnsupportedEnvironment");case 35:return t.abrupt("return",new Uint8Array(c));case 36:case"end":return t.stop()}},t,this,[[28,32]])}))).apply(this,arguments)}function g(t,r){var e;if("MD5"===t)e=c()(Array.from(r),{asBytes:!0});else{if(!(Object.keys(f.hashes).indexOf(t)>=0))throw new Error("UnsupportedHashInPureJs");e=p()(f.hashes[t].nodeName).update(r).digest()}return new Uint8Array(e)}e.d(r,"compute",function(){return _});r.default={compute:_}}])});
t.exports=function(t){return null!=t&&(r(t)||function(t){return"function"==typeof t.readFloatLE&&"function"==typeof t.slice&&r(t.slice(0,0))}(t)||!!t._isBuffer)}},function(t,n){"function"==typeof Object.create?t.exports=function(t,n){t.super_=n,t.prototype=Object.create(n.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:t.exports=function(t,n){t.super_=n;var r=function(){};r.prototype=n.prototype,t.prototype=new r,t.prototype.constructor=t}},function(t,n,r){"use strict";n.sha1=r(19),n.sha224=r(20),n.sha256=r(6),n.sha384=r(21),n.sha512=r(7)},function(t,n,r){"use strict";var e=r(0),i=r(2),o=r(5),s=e.rotl32,h=e.sum32,u=e.sum32_5,a=o.ft_1,c=i.BlockHash,f=[1518500249,1859775393,2400959708,3395469782];function l(){if(!(this instanceof l))return new l;c.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}e.inherits(l,c),t.exports=l,l.blockSize=512,l.outSize=160,l.hmacStrength=80,l.padLength=64,l.prototype._update=function(t,n){for(var r=this.W,e=0;e<16;e++)r[e]=t[n+e];for(;e<r.length;e++)r[e]=s(r[e-3]^r[e-8]^r[e-14]^r[e-16],1);var i=this.h[0],o=this.h[1],c=this.h[2],l=this.h[3],p=this.h[4];for(e=0;e<r.length;e++){var g=~~(e/20),d=u(s(i,5),a(g,o,c,l),p,r[e],f[g]);p=l,l=c,c=s(o,30),o=i,i=d}this.h[0]=h(this.h[0],i),this.h[1]=h(this.h[1],o),this.h[2]=h(this.h[2],c),this.h[3]=h(this.h[3],l),this.h[4]=h(this.h[4],p)},l.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h,"big"):e.split32(this.h,"big")}},function(t,n,r){"use strict";var e=r(0),i=r(6);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}e.inherits(o,i),t.exports=o,o.blockSize=512,o.outSize=224,o.hmacStrength=192,o.padLength=64,o.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h.slice(0,7),"big"):e.split32(this.h.slice(0,7),"big")}},function(t,n,r){"use strict";var e=r(0),i=r(7);function o(){if(!(this instanceof o))return new o;i.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}e.inherits(o,i),t.exports=o,o.blockSize=1024,o.outSize=384,o.hmacStrength=192,o.padLength=128,o.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h.slice(0,12),"big"):e.split32(this.h.slice(0,12),"big")}},function(t,n,r){"use strict";var e=r(0),i=r(2),o=e.rotl32,s=e.sum32,h=e.sum32_3,u=e.sum32_4,a=i.BlockHash;function c(){if(!(this instanceof c))return new c;a.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}function f(t,n,r,e){return t<=15?n^r^e:t<=31?n&r|~n&e:t<=47?(n|~r)^e:t<=63?n&e|r&~e:n^(r|~e)}function l(t){return t<=15?0:t<=31?1518500249:t<=47?1859775393:t<=63?2400959708:2840853838}function p(t){return t<=15?1352829926:t<=31?1548603684:t<=47?1836072691:t<=63?2053994217:0}e.inherits(c,a),n.ripemd160=c,c.blockSize=512,c.outSize=160,c.hmacStrength=192,c.padLength=64,c.prototype._update=function(t,n){for(var r=this.h[0],e=this.h[1],i=this.h[2],a=this.h[3],c=this.h[4],m=r,_=e,b=i,w=a,x=c,S=0;S<80;S++){var k=s(o(u(r,f(S,e,i,a),t[g[S]+n],l(S)),y[S]),c);r=c,c=a,a=o(i,10),i=e,e=k,k=s(o(u(m,f(79-S,_,b,w),t[d[S]+n],p(S)),v[S]),x),m=x,x=w,w=o(b,10),b=_,_=k}k=h(this.h[1],i,w),this.h[1]=h(this.h[2],a,x),this.h[2]=h(this.h[3],c,m),this.h[3]=h(this.h[4],r,_),this.h[4]=h(this.h[0],e,b),this.h[0]=k},c.prototype._digest=function(t){return"hex"===t?e.toHex32(this.h,"little"):e.split32(this.h,"little")};var g=[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,7,4,13,1,10,6,15,3,12,0,9,5,2,14,11,8,3,10,14,4,9,15,8,1,2,7,0,6,13,11,5,12,1,9,11,10,0,8,12,4,13,3,7,15,14,5,6,2,4,0,5,9,7,12,2,10,14,1,3,8,11,6,15,13],d=[5,14,7,0,9,2,11,4,13,6,15,8,1,10,3,12,6,11,3,7,0,13,5,10,14,15,8,12,4,9,1,2,15,5,1,3,7,14,6,9,11,8,12,2,10,0,4,13,8,6,4,1,3,11,15,0,5,12,2,13,9,7,10,14,12,15,10,4,1,5,8,7,6,2,13,14,0,3,9,11],y=[11,14,15,12,5,8,7,9,11,13,14,15,6,7,9,8,7,6,8,13,11,9,7,15,7,12,15,9,11,7,13,12,11,13,6,7,14,9,13,15,14,8,13,6,5,12,7,5,11,12,14,15,14,15,9,8,9,14,5,6,8,6,5,12,9,15,5,11,6,8,13,12,5,12,13,14,11,8,5,6],v=[8,9,9,11,13,15,15,5,7,7,8,11,14,14,12,6,9,13,15,7,12,8,9,11,7,7,12,7,6,15,13,11,9,7,15,11,8,6,6,14,12,13,5,14,13,13,7,5,15,5,8,11,14,14,6,14,6,9,12,9,12,5,15,8,8,5,12,9,12,5,14,6,8,13,6,5,15,13,11,11]},function(t,n,r){"use strict";var e=r(0),i=r(1);function o(t,n,r){if(!(this instanceof o))return new o(t,n,r);this.Hash=t,this.blockSize=t.blockSize/8,this.outSize=t.outSize/8,this.inner=null,this.outer=null,this._init(e.toArray(n,r))}t.exports=o,o.prototype._init=function(t){t.length>this.blockSize&&(t=(new this.Hash).update(t).digest()),i(t.length<=this.blockSize);for(var n=t.length;n<this.blockSize;n++)t.push(0);for(n=0;n<t.length;n++)t[n]^=54;for(this.inner=(new this.Hash).update(t),n=0;n<t.length;n++)t[n]^=106;this.outer=(new this.Hash).update(t)},o.prototype.update=function(t,n){return this.inner.update(t,n),this},o.prototype.digest=function(t){return this.outer.update(this.inner.digest()),this.outer.digest(t)}},function(t,n,r){"use strict";r.r(n);var e=r(3),i=r.n(e),o=r(8),s=r.n(o);function h(){if("undefined"!=typeof window)return window.crypto?window.crypto.subtle:void 0}function u(){if("undefined"!=typeof window&&!window.crypto)return window.msCrypto?window.msCrypto.subtle:void 0}var a={hashes:{"SHA-256":{nodeName:"sha256",hashSize:32},"SHA-384":{nodeName:"sha384",hashSize:48},"SHA-512":{nodeName:"sha512",hashSize:64},"SHA-1":{nodeName:"sha1",hashSize:20},MD5:{nodeName:"md5",hashSize:16}}},c=r(9),f=r.n(c),l=r(10),p=r.n(l);function g(t){return d.apply(this,arguments)}function d(){return(d=s()(i.a.mark(function t(n){var e,o,s,c,f,l,p,g,d,v,m=arguments;return i.a.wrap(function(t){for(;;)switch(t.prev=t.next){case 0:if(e=m.length>1&&void 0!==m[1]?m[1]:"SHA-256",!(Object.keys(a.hashes).indexOf(e)<0)){t.next=3;break}throw new Error("UnsupportedHashAlgorithm");case 3:if(n instanceof Uint8Array){t.next=5;break}throw new Error("UnsupportedMessageType");case 5:if(o=h(),s="undefined"!=typeof window?void 0:r(14),c=u(),p=!0,void 0===o||"function"!=typeof o.digest||void 0!==c){t.next=15;break}return t.next=12,o.digest(e,n).catch(function(t){l=t.message,p=!1});case 12:f=t.sent,t.next=27;break;case 15:if(void 0===s){t.next=19;break}try{g=a.hashes[e].nodeName,(d=s.createHash(g)).update(n),f=d.digest()}catch(t){l=t.message,p=!1}t.next=27;break;case 19:if(void 0===c||"function"!=typeof c.digest){t.next=26;break}return v=function(t,n){return new Promise(function(r,e){var i=window.msCrypto.subtle.digest(t,n);i.oncomplete=function(t){r(t.target.result)},i.onerror=function(t){e(t)}})},t.next=23,v(e,n).catch(function(t){l=t.message,p=!1});case 23:f=t.sent,t.next=27;break;case 26:p=!1;case 27:if(p){t.next=36;break}t.prev=28,f=y(e,n),t.next=36;break;case 32:throw t.prev=32,t.t0=t.catch(28),l="".concat(l," => ").concat(t.t0.message),new Error("UnsupportedEnvironment: ".concat(l));case 36:return t.abrupt("return",new Uint8Array(f));case 37:case"end":return t.stop()}},t,this,[[28,32]])}))).apply(this,arguments)}function y(t,n){var r;if("MD5"===t)r=f()(Array.from(n),{asBytes:!0});else{if(!(Object.keys(a.hashes).indexOf(t)>=0))throw new Error("UnsupportedHashInPureJs");r=p.a[a.hashes[t].nodeName]().update(n).digest()}return new Uint8Array(r)}r.d(n,"compute",function(){return g});n.default={compute:g}}])});
{
"name": "js-crypto-hash",
"version": "0.2.0",
"version": "0.2.1",
"description": "Universal Module for Hash Function in JavaScript",

@@ -57,5 +57,5 @@ "main": "dist/jschash.bundle.js",

"@babel/runtime": "7.1.2",
"md5": "^2.2.1",
"sha.js": "^2.4.11"
"hash.js": "^1.1.5",
"md5": "^2.2.1"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc