if(typeof Crypto=="undefined"||!Crypto.util)(function(){var h=Crypto={},k=h.util={rotl:function(b,d){return b<<d|b>>>32-d},rotr:function(b,d){return b<<32-d|b>>>d},endian:function(b){if(b.constructor==Number)return k.rotl(b,8)&16711935|k.rotl(b,24)&4278255360;for(var d=0;d<b.length;d++)b[d]=k.endian(b[d]);return b},randomBytes:function(b){for(var d=[];b>0;b--)d.push(Math.floor(Math.random()*256));return d},bytesToWords:function(b){for(var d=[],a=0,e=0;a<b.length;a++,e+=8)d[e>>>5]|=b[a]<<24-
e%32;return d},wordsToBytes:function(b){for(var d=[],a=0;a<b.length*32;a+=8)d.push(b[a>>>5]>>>24-a%32&255);return d},bytesToHex:function(b){for(var d=[],a=0;a<b.length;a++){d.push((b[a]>>>4).toString(16));d.push((b[a]&15).toString(16))}return d.join("")},hexToBytes:function(b){for(var d=[],a=0;a<b.length;a+=2)d.push(parseInt(b.substr(a,2),16));return d},bytesToBase64:function(b){if(typeof btoa=="function")return btoa(l.bytesToString(b));for(var d=[],a=0;a<b.length;a+=3)for(var e=b[a]<<16|b[a+1]<<
8|b[a+2],c=0;c<4;c++)a*8+c*6<=b.length*8?d.push("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".charAt(e>>>6*(3-c)&63)):d.push("=");return d.join("")},base64ToBytes:function(b){if(typeof atob=="function")return l.stringToBytes(atob(b));b=b.replace(/[^A-Z0-9+\/]/ig,"");for(var d=[],a=0,e=0;a<b.length;e=++a%4)e!=0&&d.push(("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".indexOf(b.charAt(a-1))&Math.pow(2,-2*e+8)-1)<<e*2|"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".indexOf(b.charAt(a))>>>
6-e*2);return d}};h.mode={};h=h.charenc={};h.UTF8={stringToBytes:function(b){return l.stringToBytes(unescape(encodeURIComponent(b)))},bytesToString:function(b){return decodeURIComponent(escape(l.bytesToString(b)))}};var l=h.Binary={stringToBytes:function(b){for(var d=[],a=0;a<b.length;a++)d.push(b.charCodeAt(a)&255);return d},bytesToString:function(b){for(var d=[],a=0;a<b.length;a++)d.push(String.fromCharCode(b[a]));return d.join("")}}})();
(function(){var h=Crypto,k=h.util,l=h.charenc,b=l.UTF8,d=l.Binary,a=h.SHA1=function(e,c){var f=k.wordsToBytes(a._sha1(e));return c&&c.asBytes?f:c&&c.asString?d.bytesToString(f):k.bytesToHex(f)};a._sha1=function(e){if(e.constructor==String)e=b.stringToBytes(e);var c=k.bytesToWords(e),f=e.length*8;e=[];var g=1732584193,i=-271733879,n=-1732584194,j=271733878,o=-1009589776;c[f>>5]|=128<<24-f%32;c[(f+64>>>9<<4)+15]=f;for(f=0;f<c.length;f+=16){for(var p=g,r=i,s=n,q=j,u=o,m=0;m<80;m++){if(m<16)e[m]=c[f+
m];else{var t=e[m-3]^e[m-8]^e[m-14]^e[m-16];e[m]=t<<1|t>>>31}t=(g<<5|g>>>27)+o+(e[m]>>>0)+(m<20?(i&n|~i&j)+1518500249:m<40?(i^n^j)+1859775393:m<60?(i&n|i&j|n&j)-1894007588:(i^n^j)-899497514);o=j;j=n;n=i<<30|i>>>2;i=g;g=t}g+=p;i+=r;n+=s;j+=q;o+=u}return[g,i,n,j,o]};a._blocksize=16;a._digestsize=20})();
(function(){var h=Crypto,k=h.util,l=h.charenc,b=l.UTF8,d=l.Binary;h.HMAC=function(a,e,c,f){if(e.constructor==String)e=b.stringToBytes(e);if(c.constructor==String)c=b.stringToBytes(c);if(c.length>a._blocksize*4)c=a(c,{asBytes:true});var g=c.slice(0);c=c.slice(0);for(var i=0;i<a._blocksize*4;i++){g[i]^=92;c[i]^=54}a=a(g.concat(a(c.concat(e),{asBytes:true})),{asBytes:true});return f&&f.asBytes?a:f&&f.asString?d.bytesToString(a):k.bytesToHex(a)}})();
(function(){var h=Crypto,k=h.util,l=h.charenc,b=l.UTF8,d=l.Binary;h.PBKDF2=function(a,e,c,f){function g(u,m){return h.HMAC(i,m,u,{asBytes:true})}if(a.constructor==String)a=b.stringToBytes(a);if(e.constructor==String)e=b.stringToBytes(e);for(var i=f&&f.hasher||h.SHA1,n=f&&f.iterations||1,j=[],o=1;j.length<c;){for(var p=g(a,e.concat(k.wordsToBytes([o]))),r=p,s=1;s<n;s++){r=g(a,r);for(var q=0;q<p.length;q++)p[q]^=r[q]}j=j.concat(p);o++}j.length=c;return f&&f.asBytes?j:f&&f.asString?d.bytesToString(j):
k.bytesToHex(j)}})();
(function(){var h=Crypto,k=h.util,l=h.charenc.UTF8,b=h.MARC4={encrypt:function(d,a){var e=l.stringToBytes(d),c=k.randomBytes(16),f=a.constructor==String?h.PBKDF2(a,c,32,{asBytes:true}):a;b._marc4(e,f,1536);return k.bytesToBase64(c.concat(e))},decrypt:function(d,a){var e=k.base64ToBytes(d),c=e.splice(0,16);c=a.constructor==String?h.PBKDF2(a,c,32,{asBytes:true}):a;b._marc4(e,c,1536);return l.bytesToString(e)},_marc4:function(d,a,e){var c,f,g,i;c=0;for(g=[];c<256;c++)g[c]=c;for(f=c=0;c<256;c++){f=(f+
g[c]+a[c%a.length])%256;i=g[c];g[c]=g[f];g[f]=i}c=f=0;for(a=-e;a<d.length;a++){c=(c+1)%256;f=(f+g[c])%256;i=g[c];g[c]=g[f];g[f]=i;a<0||(d[a]^=g[(g[c]+g[f])%256])}}}})();
