@swapkit/wallet-keystore 1.7.6 → 1.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,13 +1,18 @@
1
- import{a as q5,c as B5}from"./chunk-nm00d52v.js";var{create:t6,defineProperty:n5,getOwnPropertyDescriptor:e6,getOwnPropertyNames:K7,getPrototypeOf:C7}=Object,X7=Object.prototype.hasOwnProperty,J9=(l,g)=>()=>(l&&(g=l(l=0)),g),G0=(l,g)=>()=>(g||l((g={exports:{}}).exports,g),g.exports),r5=(l,g)=>{for(var E in g)n5(l,E,{get:g[E],enumerable:!0})},s5=(l,g,E,M)=>{if(g&&typeof g=="object"||typeof g=="function")for(let U of K7(g))!X7.call(l,U)&&U!==E&&n5(l,U,{get:()=>g[U],enumerable:!(M=e6(g,U))||M.enumerable});return l},P9=(l,g,E)=>(s5(l,g,"default"),E&&s5(E,g,"default")),E5=(l,g,E)=>(E=l!=null?t6(C7(l)):{},s5(g||!l||!l.__esModule?n5(E,"default",{value:l,enumerable:!0}):E,l)),O5=(l)=>s5(n5({},"__esModule",{value:!0}),l),H7=G0((l)=>{l.byteLength=I,l.toByteArray=z,l.fromByteArray=N;var g=[],E=[],M=typeof Uint8Array<"u"?Uint8Array:Array,U="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(S=0,G=U.length;S<G;++S)g[S]=U[S],E[U.charCodeAt(S)]=S;var S,G;E[45]=62,E[95]=63;function W(j){var D=j.length;if(D%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var k=j.indexOf("=");k===-1&&(k=D);var A=k===D?0:4-k%4;return[k,A]}function I(j){var D=W(j),k=D[0],A=D[1];return(k+A)*3/4-A}function V(j,D,k){return(D+k)*3/4-k}function z(j){var D,k=W(j),A=k[0],x=k[1],v=new M(V(j,A,x)),y=0,p=x>0?A-4:A,c;for(c=0;c<p;c+=4)D=E[j.charCodeAt(c)]<<18|E[j.charCodeAt(c+1)]<<12|E[j.charCodeAt(c+2)]<<6|E[j.charCodeAt(c+3)],v[y++]=D>>16&255,v[y++]=D>>8&255,v[y++]=D&255;return x===2&&(D=E[j.charCodeAt(c)]<<2|E[j.charCodeAt(c+1)]>>4,v[y++]=D&255),x===1&&(D=E[j.charCodeAt(c)]<<10|E[j.charCodeAt(c+1)]<<4|E[j.charCodeAt(c+2)]>>2,v[y++]=D>>8&255,v[y++]=D&255),v}function F(j){return g[j>>18&63]+g[j>>12&63]+g[j>>6&63]+g[j&63]}function O(j,D,k){for(var A,x=[],v=D;v<k;v+=3)A=(j[v]<<16&16711680)+(j[v+1]<<8&65280)+(j[v+2]&255),x.push(F(A));return x.join("")}function N(j){for(var D,k=j.length,A=k%3,x=[],v=16383,y=0,p=k-A;y<p;y+=v)x.push(O(j,y,y+v>p?p:y+v));return A===1?(D=j[k-1],x.push(g[D>>2]+g[D<<4&63]+"==")):A===2&&(D=(j[k-2]<<8)+j[k-1],x.push(g[D>>10]+g[D>>4&63]+g[D<<2&63]+"=")),x.join("")}}),Y7=G0((l)=>{l.read=function(g,E,M,U,S){var G,W,I=S*8-U-1,V=(1<<I)-1,z=V>>1,F=-7,O=M?S-1:0,N=M?-1:1,j=g[E+O];for(O+=N,G=j&(1<<-F)-1,j>>=-F,F+=I;F>0;G=G*256+g[E+O],O+=N,F-=8);for(W=G&(1<<-F)-1,G>>=-F,F+=U;F>0;W=W*256+g[E+O],O+=N,F-=8);if(G===0)G=1-z;else{if(G===V)return W?NaN:(j?-1:1)*(1/0);W=W+Math.pow(2,U),G=G-z}return(j?-1:1)*W*Math.pow(2,G-U)},l.write=function(g,E,M,U,S,G){var W,I,V,z=G*8-S-1,F=(1<<z)-1,O=F>>1,N=S===23?Math.pow(2,-24)-Math.pow(2,-77):0,j=U?0:G-1,D=U?1:-1,k=E<0||E===0&&1/E<0?1:0;for(E=Math.abs(E),isNaN(E)||E===1/0?(I=isNaN(E)?1:0,W=F):(W=Math.floor(Math.log(E)/Math.LN2),E*(V=Math.pow(2,-W))<1&&(W--,V*=2),W+O>=1?E+=N/V:E+=N*Math.pow(2,1-O),E*V>=2&&(W++,V/=2),W+O>=F?(I=0,W=F):W+O>=1?(I=(E*V-1)*Math.pow(2,S),W=W+O):(I=E*Math.pow(2,O-1)*Math.pow(2,S),W=0));S>=8;g[M+j]=I&255,j+=D,I/=256,S-=8);for(W=W<<S|I,z+=S;z>0;g[M+j]=W&255,j+=D,W/=256,z-=8);g[M+j-D]|=k*128}}),j5=G0((l)=>{var g=H7(),E=Y7(),M=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;l.Buffer=W,l.SlowBuffer=x,l.INSPECT_MAX_BYTES=50;var U=2147483647;l.kMaxLength=U,W.TYPED_ARRAY_SUPPORT=S(),!W.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function S(){try{let T=new Uint8Array(1),B={foo:function(){return 42}};return Object.setPrototypeOf(B,Uint8Array.prototype),Object.setPrototypeOf(T,B),T.foo()===42}catch{return!1}}Object.defineProperty(W.prototype,"parent",{enumerable:!0,get:function(){if(W.isBuffer(this))return this.buffer}}),Object.defineProperty(W.prototype,"offset",{enumerable:!0,get:function(){if(W.isBuffer(this))return this.byteOffset}});function G(T){if(T>U)throw new RangeError('The value "'+T+'" is invalid for option "size"');let B=new Uint8Array(T);return Object.setPrototypeOf(B,W.prototype),B}function W(T,B,b){if(typeof T=="number"){if(typeof B=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return F(T)}return I(T,B,b)}W.poolSize=8192;function I(T,B,b){if(typeof T=="string")return O(T,B);if(ArrayBuffer.isView(T))return j(T);if(T==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof T);if(J0(T,ArrayBuffer)||T&&J0(T.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(J0(T,SharedArrayBuffer)||T&&J0(T.buffer,SharedArrayBuffer)))return D(T,B,b);if(typeof T=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let h=T.valueOf&&T.valueOf();if(h!=null&&h!==T)return W.from(h,B,b);let o=k(T);if(o)return o;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof T[Symbol.toPrimitive]=="function")return W.from(T[Symbol.toPrimitive]("string"),B,b);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof T)}W.from=function(T,B,b){return I(T,B,b)},Object.setPrototypeOf(W.prototype,Uint8Array.prototype),Object.setPrototypeOf(W,Uint8Array);function V(T){if(typeof T!="number")throw new TypeError('"size" argument must be of type number');if(T<0)throw new RangeError('The value "'+T+'" is invalid for option "size"')}function z(T,B,b){return V(T),T<=0?G(T):B!==void 0?typeof b=="string"?G(T).fill(B,b):G(T).fill(B):G(T)}W.alloc=function(T,B,b){return z(T,B,b)};function F(T){return V(T),G(T<0?0:A(T)|0)}W.allocUnsafe=function(T){return F(T)},W.allocUnsafeSlow=function(T){return F(T)};function O(T,B){if((typeof B!="string"||B==="")&&(B="utf8"),!W.isEncoding(B))throw new TypeError("Unknown encoding: "+B);let b=v(T,B)|0,h=G(b),o=h.write(T,B);return o!==b&&(h=h.slice(0,o)),h}function N(T){let B=T.length<0?0:A(T.length)|0,b=G(B);for(let h=0;h<B;h+=1)b[h]=T[h]&255;return b}function j(T){if(J0(T,Uint8Array)){let B=new Uint8Array(T);return D(B.buffer,B.byteOffset,B.byteLength)}return N(T)}function D(T,B,b){if(B<0||T.byteLength<B)throw new RangeError('"offset" is outside of buffer bounds');if(T.byteLength<B+(b||0))throw new RangeError('"length" is outside of buffer bounds');let h;return B===void 0&&b===void 0?h=new Uint8Array(T):b===void 0?h=new Uint8Array(T,B):h=new Uint8Array(T,B,b),Object.setPrototypeOf(h,W.prototype),h}function k(T){if(W.isBuffer(T)){let B=A(T.length)|0,b=G(B);return b.length===0||T.copy(b,0,0,B),b}if(T.length!==void 0)return typeof T.length!="number"||w0(T.length)?G(0):N(T);if(T.type==="Buffer"&&Array.isArray(T.data))return N(T.data)}function A(T){if(T>=U)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+U.toString(16)+" bytes");return T|0}function x(T){return+T!=T&&(T=0),W.alloc(+T)}W.isBuffer=function(T){return T!=null&&T._isBuffer===!0&&T!==W.prototype},W.compare=function(T,B){if(J0(T,Uint8Array)&&(T=W.from(T,T.offset,T.byteLength)),J0(B,Uint8Array)&&(B=W.from(B,B.offset,B.byteLength)),!W.isBuffer(T)||!W.isBuffer(B))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(T===B)return 0;let b=T.length,h=B.length;for(let o=0,O0=Math.min(b,h);o<O0;++o)if(T[o]!==B[o]){b=T[o],h=B[o];break}return b<h?-1:h<b?1:0},W.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}},W.concat=function(T,B){if(!Array.isArray(T))throw new TypeError('"list" argument must be an Array of Buffers');if(T.length===0)return W.alloc(0);let b;if(B===void 0)for(B=0,b=0;b<T.length;++b)B+=T[b].length;let h=W.allocUnsafe(B),o=0;for(b=0;b<T.length;++b){let O0=T[b];if(J0(O0,Uint8Array))o+O0.length>h.length?(W.isBuffer(O0)||(O0=W.from(O0)),O0.copy(h,o)):Uint8Array.prototype.set.call(h,O0,o);else if(W.isBuffer(O0))O0.copy(h,o);else throw new TypeError('"list" argument must be an Array of Buffers');o+=O0.length}return h};function v(T,B){if(W.isBuffer(T))return T.length;if(ArrayBuffer.isView(T)||J0(T,ArrayBuffer))return T.byteLength;if(typeof T!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof T);let b=T.length,h=arguments.length>2&&arguments[2]===!0;if(!h&&b===0)return 0;let o=!1;for(;;)switch(B){case"ascii":case"latin1":case"binary":return b;case"utf8":case"utf-8":return e(T).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return b*2;case"hex":return b>>>1;case"base64":return _0(T).length;default:if(o)return h?-1:e(T).length;B=(""+B).toLowerCase(),o=!0}}W.byteLength=v;function y(T,B,b){let h=!1;if((B===void 0||B<0)&&(B=0),B>this.length||((b===void 0||b>this.length)&&(b=this.length),b<=0)||(b>>>=0,B>>>=0,b<=B))return"";for(T||(T="utf8");;)switch(T){case"hex":return $(this,B,b);case"utf8":case"utf-8":return Y(this,B,b);case"ascii":return P(this,B,b);case"latin1":case"binary":return Z(this,B,b);case"base64":return X(this,B,b);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return C(this,B,b);default:if(h)throw new TypeError("Unknown encoding: "+T);T=(T+"").toLowerCase(),h=!0}}W.prototype._isBuffer=!0;function p(T,B,b){let h=T[B];T[B]=T[b],T[b]=h}W.prototype.swap16=function(){let T=this.length;if(T%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let B=0;B<T;B+=2)p(this,B,B+1);return this},W.prototype.swap32=function(){let T=this.length;if(T%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let B=0;B<T;B+=4)p(this,B,B+3),p(this,B+1,B+2);return this},W.prototype.swap64=function(){let T=this.length;if(T%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let B=0;B<T;B+=8)p(this,B,B+7),p(this,B+1,B+6),p(this,B+2,B+5),p(this,B+3,B+4);return this},W.prototype.toString=function(){let T=this.length;return T===0?"":arguments.length===0?Y(this,0,T):y.apply(this,arguments)},W.prototype.toLocaleString=W.prototype.toString,W.prototype.equals=function(T){if(!W.isBuffer(T))throw new TypeError("Argument must be a Buffer");return this===T?!0:W.compare(this,T)===0},W.prototype.inspect=function(){let T="",B=l.INSPECT_MAX_BYTES;return T=this.toString("hex",0,B).replace(/(.{2})/g,"$1 ").trim(),this.length>B&&(T+=" ... "),"<Buffer "+T+">"},M&&(W.prototype[M]=W.prototype.inspect),W.prototype.compare=function(T,B,b,h,o){if(J0(T,Uint8Array)&&(T=W.from(T,T.offset,T.byteLength)),!W.isBuffer(T))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof T);if(B===void 0&&(B=0),b===void 0&&(b=T?T.length:0),h===void 0&&(h=0),o===void 0&&(o=this.length),B<0||b>T.length||h<0||o>this.length)throw new RangeError("out of range index");if(h>=o&&B>=b)return 0;if(h>=o)return-1;if(B>=b)return 1;if(B>>>=0,b>>>=0,h>>>=0,o>>>=0,this===T)return 0;let O0=o-h,Y0=b-B,F0=Math.min(O0,Y0),b0=this.slice(h,o),W0=T.slice(B,b);for(let U0=0;U0<F0;++U0)if(b0[U0]!==W0[U0]){O0=b0[U0],Y0=W0[U0];break}return O0<Y0?-1:Y0<O0?1:0};function c(T,B,b,h,o){if(T.length===0)return-1;if(typeof b=="string"?(h=b,b=0):b>2147483647?b=2147483647:b<-2147483648&&(b=-2147483648),b=+b,w0(b)&&(b=o?0:T.length-1),b<0&&(b=T.length+b),b>=T.length){if(o)return-1;b=T.length-1}else if(b<0)if(o)b=0;else return-1;if(typeof B=="string"&&(B=W.from(B,h)),W.isBuffer(B))return B.length===0?-1:n(T,B,b,h,o);if(typeof B=="number")return B=B&255,typeof Uint8Array.prototype.indexOf=="function"?o?Uint8Array.prototype.indexOf.call(T,B,b):Uint8Array.prototype.lastIndexOf.call(T,B,b):n(T,[B],b,h,o);throw new TypeError("val must be string, number or Buffer")}function n(T,B,b,h,o){let O0=1,Y0=T.length,F0=B.length;if(h!==void 0&&(h=String(h).toLowerCase(),h==="ucs2"||h==="ucs-2"||h==="utf16le"||h==="utf-16le")){if(T.length<2||B.length<2)return-1;O0=2,Y0/=2,F0/=2,b/=2}function b0(U0,y0){return O0===1?U0[y0]:U0.readUInt16BE(y0*O0)}let W0;if(o){let U0=-1;for(W0=b;W0<Y0;W0++)if(b0(T,W0)===b0(B,U0===-1?0:W0-U0)){if(U0===-1&&(U0=W0),W0-U0+1===F0)return U0*O0}else U0!==-1&&(W0-=W0-U0),U0=-1}else for(b+F0>Y0&&(b=Y0-F0),W0=b;W0>=0;W0--){let U0=!0;for(let y0=0;y0<F0;y0++)if(b0(T,W0+y0)!==b0(B,y0)){U0=!1;break}if(U0)return W0}return-1}W.prototype.includes=function(T,B,b){return this.indexOf(T,B,b)!==-1},W.prototype.indexOf=function(T,B,b){return c(this,T,B,b,!0)},W.prototype.lastIndexOf=function(T,B,b){return c(this,T,B,b,!1)};function i(T,B,b,h){b=Number(b)||0;let o=T.length-b;h?(h=Number(h),h>o&&(h=o)):h=o;let O0=B.length;h>O0/2&&(h=O0/2);let Y0;for(Y0=0;Y0<h;++Y0){let F0=parseInt(B.substr(Y0*2,2),16);if(w0(F0))return Y0;T[b+Y0]=F0}return Y0}function H0(T,B,b,h){return $0(e(B,T.length-b),T,b,h)}function a(T,B,b,h){return $0(C0(B),T,b,h)}function P0(T,B,b,h){return $0(_0(B),T,b,h)}function K(T,B,b,h){return $0(t(B,T.length-b),T,b,h)}W.prototype.write=function(T,B,b,h){if(B===void 0)h="utf8",b=this.length,B=0;else if(b===void 0&&typeof B=="string")h=B,b=this.length,B=0;else if(isFinite(B))B=B>>>0,isFinite(b)?(b=b>>>0,h===void 0&&(h="utf8")):(h=b,b=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let o=this.length-B;if((b===void 0||b>o)&&(b=o),T.length>0&&(b<0||B<0)||B>this.length)throw new RangeError("Attempt to write outside buffer bounds");h||(h="utf8");let O0=!1;for(;;)switch(h){case"hex":return i(this,T,B,b);case"utf8":case"utf-8":return H0(this,T,B,b);case"ascii":case"latin1":case"binary":return a(this,T,B,b);case"base64":return P0(this,T,B,b);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return K(this,T,B,b);default:if(O0)throw new TypeError("Unknown encoding: "+h);h=(""+h).toLowerCase(),O0=!0}},W.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function X(T,B,b){return B===0&&b===T.length?g.fromByteArray(T):g.fromByteArray(T.slice(B,b))}function Y(T,B,b){b=Math.min(T.length,b);let h=[],o=B;for(;o<b;){let O0=T[o],Y0=null,F0=O0>239?4:O0>223?3:O0>191?2:1;if(o+F0<=b){let b0,W0,U0,y0;switch(F0){case 1:O0<128&&(Y0=O0);break;case 2:b0=T[o+1],(b0&192)===128&&(y0=(O0&31)<<6|b0&63,y0>127&&(Y0=y0));break;case 3:b0=T[o+1],W0=T[o+2],(b0&192)===128&&(W0&192)===128&&(y0=(O0&15)<<12|(b0&63)<<6|W0&63,y0>2047&&(y0<55296||y0>57343)&&(Y0=y0));break;case 4:b0=T[o+1],W0=T[o+2],U0=T[o+3],(b0&192)===128&&(W0&192)===128&&(U0&192)===128&&(y0=(O0&15)<<18|(b0&63)<<12|(W0&63)<<6|U0&63,y0>65535&&y0<1114112&&(Y0=y0))}}Y0===null?(Y0=65533,F0=1):Y0>65535&&(Y0-=65536,h.push(Y0>>>10&1023|55296),Y0=56320|Y0&1023),h.push(Y0),o+=F0}return Q(h)}var H=4096;function Q(T){let B=T.length;if(B<=H)return String.fromCharCode.apply(String,T);let b="",h=0;for(;h<B;)b+=String.fromCharCode.apply(String,T.slice(h,h+=H));return b}function P(T,B,b){let h="";b=Math.min(T.length,b);for(let o=B;o<b;++o)h+=String.fromCharCode(T[o]&127);return h}function Z(T,B,b){let h="";b=Math.min(T.length,b);for(let o=B;o<b;++o)h+=String.fromCharCode(T[o]);return h}function $(T,B,b){let h=T.length;(!B||B<0)&&(B=0),(!b||b<0||b>h)&&(b=h);let o="";for(let O0=B;O0<b;++O0)o+=j0[T[O0]];return o}function C(T,B,b){let h=T.slice(B,b),o="";for(let O0=0;O0<h.length-1;O0+=2)o+=String.fromCharCode(h[O0]+h[O0+1]*256);return o}W.prototype.slice=function(T,B){let b=this.length;T=~~T,B=B===void 0?b:~~B,T<0?(T+=b,T<0&&(T=0)):T>b&&(T=b),B<0?(B+=b,B<0&&(B=0)):B>b&&(B=b),B<T&&(B=T);let h=this.subarray(T,B);return Object.setPrototypeOf(h,W.prototype),h};function J(T,B,b){if(T%1!==0||T<0)throw new RangeError("offset is not uint");if(T+B>b)throw new RangeError("Trying to access beyond buffer length")}W.prototype.readUintLE=W.prototype.readUIntLE=function(T,B,b){T=T>>>0,B=B>>>0,b||J(T,B,this.length);let h=this[T],o=1,O0=0;for(;++O0<B&&(o*=256);)h+=this[T+O0]*o;return h},W.prototype.readUintBE=W.prototype.readUIntBE=function(T,B,b){T=T>>>0,B=B>>>0,b||J(T,B,this.length);let h=this[T+--B],o=1;for(;B>0&&(o*=256);)h+=this[T+--B]*o;return h},W.prototype.readUint8=W.prototype.readUInt8=function(T,B){return T=T>>>0,B||J(T,1,this.length),this[T]},W.prototype.readUint16LE=W.prototype.readUInt16LE=function(T,B){return T=T>>>0,B||J(T,2,this.length),this[T]|this[T+1]<<8},W.prototype.readUint16BE=W.prototype.readUInt16BE=function(T,B){return T=T>>>0,B||J(T,2,this.length),this[T]<<8|this[T+1]},W.prototype.readUint32LE=W.prototype.readUInt32LE=function(T,B){return T=T>>>0,B||J(T,4,this.length),(this[T]|this[T+1]<<8|this[T+2]<<16)+this[T+3]*16777216},W.prototype.readUint32BE=W.prototype.readUInt32BE=function(T,B){return T=T>>>0,B||J(T,4,this.length),this[T]*16777216+(this[T+1]<<16|this[T+2]<<8|this[T+3])},W.prototype.readBigUInt64LE=Z0(function(T){T=T>>>0,Q0(T,"offset");let B=this[T],b=this[T+7];(B===void 0||b===void 0)&&w(T,this.length-8);let h=B+this[++T]*256+this[++T]*65536+this[++T]*16777216,o=this[++T]+this[++T]*256+this[++T]*65536+b*16777216;return BigInt(h)+(BigInt(o)<<BigInt(32))}),W.prototype.readBigUInt64BE=Z0(function(T){T=T>>>0,Q0(T,"offset");let B=this[T],b=this[T+7];(B===void 0||b===void 0)&&w(T,this.length-8);let h=B*16777216+this[++T]*65536+this[++T]*256+this[++T],o=this[++T]*16777216+this[++T]*65536+this[++T]*256+b;return(BigInt(h)<<BigInt(32))+BigInt(o)}),W.prototype.readIntLE=function(T,B,b){T=T>>>0,B=B>>>0,b||J(T,B,this.length);let h=this[T],o=1,O0=0;for(;++O0<B&&(o*=256);)h+=this[T+O0]*o;return o*=128,h>=o&&(h-=Math.pow(2,8*B)),h},W.prototype.readIntBE=function(T,B,b){T=T>>>0,B=B>>>0,b||J(T,B,this.length);let h=B,o=1,O0=this[T+--h];for(;h>0&&(o*=256);)O0+=this[T+--h]*o;return o*=128,O0>=o&&(O0-=Math.pow(2,8*B)),O0},W.prototype.readInt8=function(T,B){return T=T>>>0,B||J(T,1,this.length),this[T]&128?(255-this[T]+1)*-1:this[T]},W.prototype.readInt16LE=function(T,B){T=T>>>0,B||J(T,2,this.length);let b=this[T]|this[T+1]<<8;return b&32768?b|4294901760:b},W.prototype.readInt16BE=function(T,B){T=T>>>0,B||J(T,2,this.length);let b=this[T+1]|this[T]<<8;return b&32768?b|4294901760:b},W.prototype.readInt32LE=function(T,B){return T=T>>>0,B||J(T,4,this.length),this[T]|this[T+1]<<8|this[T+2]<<16|this[T+3]<<24},W.prototype.readInt32BE=function(T,B){return T=T>>>0,B||J(T,4,this.length),this[T]<<24|this[T+1]<<16|this[T+2]<<8|this[T+3]},W.prototype.readBigInt64LE=Z0(function(T){T=T>>>0,Q0(T,"offset");let B=this[T],b=this[T+7];(B===void 0||b===void 0)&&w(T,this.length-8);let h=this[T+4]+this[T+5]*256+this[T+6]*65536+(b<<24);return(BigInt(h)<<BigInt(32))+BigInt(B+this[++T]*256+this[++T]*65536+this[++T]*16777216)}),W.prototype.readBigInt64BE=Z0(function(T){T=T>>>0,Q0(T,"offset");let B=this[T],b=this[T+7];(B===void 0||b===void 0)&&w(T,this.length-8);let h=(B<<24)+this[++T]*65536+this[++T]*256+this[++T];return(BigInt(h)<<BigInt(32))+BigInt(this[++T]*16777216+this[++T]*65536+this[++T]*256+b)}),W.prototype.readFloatLE=function(T,B){return T=T>>>0,B||J(T,4,this.length),E.read(this,T,!0,23,4)},W.prototype.readFloatBE=function(T,B){return T=T>>>0,B||J(T,4,this.length),E.read(this,T,!1,23,4)},W.prototype.readDoubleLE=function(T,B){return T=T>>>0,B||J(T,8,this.length),E.read(this,T,!0,52,8)},W.prototype.readDoubleBE=function(T,B){return T=T>>>0,B||J(T,8,this.length),E.read(this,T,!1,52,8)};function R(T,B,b,h,o,O0){if(!W.isBuffer(T))throw new TypeError('"buffer" argument must be a Buffer instance');if(B>o||B<O0)throw new RangeError('"value" argument is out of bounds');if(b+h>T.length)throw new RangeError("Index out of range")}W.prototype.writeUintLE=W.prototype.writeUIntLE=function(T,B,b,h){if(T=+T,B=B>>>0,b=b>>>0,!h){let Y0=Math.pow(2,8*b)-1;R(this,T,B,b,Y0,0)}let o=1,O0=0;for(this[B]=T&255;++O0<b&&(o*=256);)this[B+O0]=T/o&255;return B+b},W.prototype.writeUintBE=W.prototype.writeUIntBE=function(T,B,b,h){if(T=+T,B=B>>>0,b=b>>>0,!h){let Y0=Math.pow(2,8*b)-1;R(this,T,B,b,Y0,0)}let o=b-1,O0=1;for(this[B+o]=T&255;--o>=0&&(O0*=256);)this[B+o]=T/O0&255;return B+b},W.prototype.writeUint8=W.prototype.writeUInt8=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,1,255,0),this[B]=T&255,B+1},W.prototype.writeUint16LE=W.prototype.writeUInt16LE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,2,65535,0),this[B]=T&255,this[B+1]=T>>>8,B+2},W.prototype.writeUint16BE=W.prototype.writeUInt16BE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,2,65535,0),this[B]=T>>>8,this[B+1]=T&255,B+2},W.prototype.writeUint32LE=W.prototype.writeUInt32LE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,4,4294967295,0),this[B+3]=T>>>24,this[B+2]=T>>>16,this[B+1]=T>>>8,this[B]=T&255,B+4},W.prototype.writeUint32BE=W.prototype.writeUInt32BE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,4,4294967295,0),this[B]=T>>>24,this[B+1]=T>>>16,this[B+2]=T>>>8,this[B+3]=T&255,B+4};function L(T,B,b,h,o){K0(B,h,o,T,b,7);let O0=Number(B&BigInt(4294967295));T[b++]=O0,O0=O0>>8,T[b++]=O0,O0=O0>>8,T[b++]=O0,O0=O0>>8,T[b++]=O0;let Y0=Number(B>>BigInt(32)&BigInt(4294967295));return T[b++]=Y0,Y0=Y0>>8,T[b++]=Y0,Y0=Y0>>8,T[b++]=Y0,Y0=Y0>>8,T[b++]=Y0,b}function _(T,B,b,h,o){K0(B,h,o,T,b,7);let O0=Number(B&BigInt(4294967295));T[b+7]=O0,O0=O0>>8,T[b+6]=O0,O0=O0>>8,T[b+5]=O0,O0=O0>>8,T[b+4]=O0;let Y0=Number(B>>BigInt(32)&BigInt(4294967295));return T[b+3]=Y0,Y0=Y0>>8,T[b+2]=Y0,Y0=Y0>>8,T[b+1]=Y0,Y0=Y0>>8,T[b]=Y0,b+8}W.prototype.writeBigUInt64LE=Z0(function(T,B=0){return L(this,T,B,BigInt(0),BigInt("0xffffffffffffffff"))}),W.prototype.writeBigUInt64BE=Z0(function(T,B=0){return _(this,T,B,BigInt(0),BigInt("0xffffffffffffffff"))}),W.prototype.writeIntLE=function(T,B,b,h){if(T=+T,B=B>>>0,!h){let F0=Math.pow(2,8*b-1);R(this,T,B,b,F0-1,-F0)}let o=0,O0=1,Y0=0;for(this[B]=T&255;++o<b&&(O0*=256);)T<0&&Y0===0&&this[B+o-1]!==0&&(Y0=1),this[B+o]=(T/O0>>0)-Y0&255;return B+b},W.prototype.writeIntBE=function(T,B,b,h){if(T=+T,B=B>>>0,!h){let F0=Math.pow(2,8*b-1);R(this,T,B,b,F0-1,-F0)}let o=b-1,O0=1,Y0=0;for(this[B+o]=T&255;--o>=0&&(O0*=256);)T<0&&Y0===0&&this[B+o+1]!==0&&(Y0=1),this[B+o]=(T/O0>>0)-Y0&255;return B+b},W.prototype.writeInt8=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,1,127,-128),T<0&&(T=255+T+1),this[B]=T&255,B+1},W.prototype.writeInt16LE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,2,32767,-32768),this[B]=T&255,this[B+1]=T>>>8,B+2},W.prototype.writeInt16BE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,2,32767,-32768),this[B]=T>>>8,this[B+1]=T&255,B+2},W.prototype.writeInt32LE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,4,2147483647,-2147483648),this[B]=T&255,this[B+1]=T>>>8,this[B+2]=T>>>16,this[B+3]=T>>>24,B+4},W.prototype.writeInt32BE=function(T,B,b){return T=+T,B=B>>>0,b||R(this,T,B,4,2147483647,-2147483648),T<0&&(T=4294967295+T+1),this[B]=T>>>24,this[B+1]=T>>>16,this[B+2]=T>>>8,this[B+3]=T&255,B+4},W.prototype.writeBigInt64LE=Z0(function(T,B=0){return L(this,T,B,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),W.prototype.writeBigInt64BE=Z0(function(T,B=0){return _(this,T,B,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function s(T,B,b,h,o,O0){if(b+h>T.length)throw new RangeError("Index out of range");if(b<0)throw new RangeError("Index out of range")}function r(T,B,b,h,o){return B=+B,b=b>>>0,o||s(T,B,b,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000),E.write(T,B,b,h,23,4),b+4}W.prototype.writeFloatLE=function(T,B,b){return r(this,T,B,!0,b)},W.prototype.writeFloatBE=function(T,B,b){return r(this,T,B,!1,b)};function X0(T,B,b,h,o){return B=+B,b=b>>>0,o||s(T,B,b,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000),E.write(T,B,b,h,52,8),b+8}W.prototype.writeDoubleLE=function(T,B,b){return X0(this,T,B,!0,b)},W.prototype.writeDoubleBE=function(T,B,b){return X0(this,T,B,!1,b)},W.prototype.copy=function(T,B,b,h){if(!W.isBuffer(T))throw new TypeError("argument should be a Buffer");if(b||(b=0),!h&&h!==0&&(h=this.length),B>=T.length&&(B=T.length),B||(B=0),h>0&&h<b&&(h=b),h===b||T.length===0||this.length===0)return 0;if(B<0)throw new RangeError("targetStart out of bounds");if(b<0||b>=this.length)throw new RangeError("Index out of range");if(h<0)throw new RangeError("sourceEnd out of bounds");h>this.length&&(h=this.length),T.length-B<h-b&&(h=T.length-B+b);let o=h-b;return this===T&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(B,b,h):Uint8Array.prototype.set.call(T,this.subarray(b,h),B),o},W.prototype.fill=function(T,B,b,h){if(typeof T=="string"){if(typeof B=="string"?(h=B,B=0,b=this.length):typeof b=="string"&&(h=b,b=this.length),h!==void 0&&typeof h!="string")throw new TypeError("encoding must be a string");if(typeof h=="string"&&!W.isEncoding(h))throw new TypeError("Unknown encoding: "+h);if(T.length===1){let O0=T.charCodeAt(0);(h==="utf8"&&O0<128||h==="latin1")&&(T=O0)}}else typeof T=="number"?T=T&255:typeof T=="boolean"&&(T=Number(T));if(B<0||this.length<B||this.length<b)throw new RangeError("Out of range index");if(b<=B)return this;B=B>>>0,b=b===void 0?this.length:b>>>0,T||(T=0);let o;if(typeof T=="number")for(o=B;o<b;++o)this[o]=T;else{let O0=W.isBuffer(T)?T:W.from(T,h),Y0=O0.length;if(Y0===0)throw new TypeError('The value "'+T+'" is invalid for argument "value"');for(o=0;o<b-B;++o)this[o+B]=O0[o%Y0]}return this};var u={};function d(T,B,b){u[T]=class extends b{constructor(){super(),Object.defineProperty(this,"message",{value:B.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${T}]`,this.stack,delete this.name}get code(){return T}set code(h){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:h,writable:!0})}toString(){return`${this.name} [${T}]: ${this.message}`}}}d("ERR_BUFFER_OUT_OF_BOUNDS",function(T){return T?`${T} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),d("ERR_INVALID_ARG_TYPE",function(T,B){return`The "${T}" argument must be of type number. Received type ${typeof B}`},TypeError),d("ERR_OUT_OF_RANGE",function(T,B,b){let h=`The value of "${T}" is out of range.`,o=b;return Number.isInteger(b)&&Math.abs(b)>4294967296?o=f(String(b)):typeof b=="bigint"&&(o=String(b),(b>BigInt(2)**BigInt(32)||b<-(BigInt(2)**BigInt(32)))&&(o=f(o)),o+="n"),h+=` It must be ${B}. Received ${o}`,h},RangeError);function f(T){let B="",b=T.length,h=T[0]==="-"?1:0;for(;b>=h+4;b-=3)B=`_${T.slice(b-3,b)}${B}`;return`${T.slice(0,b)}${B}`}function z0(T,B,b){Q0(B,"offset"),(T[B]===void 0||T[B+b]===void 0)&&w(B,T.length-(b+1))}function K0(T,B,b,h,o,O0){if(T>b||T<B){let Y0=typeof B=="bigint"?"n":"",F0;throw O0>3?B===0||B===BigInt(0)?F0=`>= 0${Y0} and < 2${Y0} ** ${(O0+1)*8}${Y0}`:F0=`>= -(2${Y0} ** ${(O0+1)*8-1}${Y0}) and < 2 ** ${(O0+1)*8-1}${Y0}`:F0=`>= ${B}${Y0} and <= ${b}${Y0}`,new u.ERR_OUT_OF_RANGE("value",F0,T)}z0(h,o,O0)}function Q0(T,B){if(typeof T!="number")throw new u.ERR_INVALID_ARG_TYPE(B,"number",T)}function w(T,B,b){throw Math.floor(T)!==T?(Q0(T,b),new u.ERR_OUT_OF_RANGE(b||"offset","an integer",T)):B<0?new u.ERR_BUFFER_OUT_OF_BOUNDS:new u.ERR_OUT_OF_RANGE(b||"offset",`>= ${b?1:0} and <= ${B}`,T)}var q=/[^+/0-9A-Za-z-_]/g;function m(T){if(T=T.split("=")[0],T=T.trim().replace(q,""),T.length<2)return"";for(;T.length%4!==0;)T=T+"=";return T}function e(T,B){B=B||1/0;let b,h=T.length,o=null,O0=[];for(let Y0=0;Y0<h;++Y0){if(b=T.charCodeAt(Y0),b>55295&&b<57344){if(!o){if(b>56319){(B-=3)>-1&&O0.push(239,191,189);continue}else if(Y0+1===h){(B-=3)>-1&&O0.push(239,191,189);continue}o=b;continue}if(b<56320){(B-=3)>-1&&O0.push(239,191,189),o=b;continue}b=(o-55296<<10|b-56320)+65536}else o&&(B-=3)>-1&&O0.push(239,191,189);if(o=null,b<128){if((B-=1)<0)break;O0.push(b)}else if(b<2048){if((B-=2)<0)break;O0.push(b>>6|192,b&63|128)}else if(b<65536){if((B-=3)<0)break;O0.push(b>>12|224,b>>6&63|128,b&63|128)}else if(b<1114112){if((B-=4)<0)break;O0.push(b>>18|240,b>>12&63|128,b>>6&63|128,b&63|128)}else throw new Error("Invalid code point")}return O0}function C0(T){let B=[];for(let b=0;b<T.length;++b)B.push(T.charCodeAt(b)&255);return B}function t(T,B){let b,h,o,O0=[];for(let Y0=0;Y0<T.length&&!((B-=2)<0);++Y0)b=T.charCodeAt(Y0),h=b>>8,o=b%256,O0.push(o),O0.push(h);return O0}function _0(T){return g.toByteArray(m(T))}function $0(T,B,b,h){let o;for(o=0;o<h&&!(o+b>=B.length||o>=T.length);++o)B[o+b]=T[o];return o}function J0(T,B){return T instanceof B||T!=null&&T.constructor!=null&&T.constructor.name!=null&&T.constructor.name===B.name}function w0(T){return T!==T}var j0=function(){let T="0123456789abcdef",B=new Array(256);for(let b=0;b<16;++b){let h=b*16;for(let o=0;o<16;++o)B[h+o]=T[b]+T[o]}return B}();function Z0(T){return typeof BigInt>"u"?c0:T}function c0(){throw new Error("BigInt not supported")}}),d0=G0((l,g)=>{var E=j5(),M=E.Buffer;function U(G,W){for(var I in G)W[I]=G[I]}M.from&&M.alloc&&M.allocUnsafe&&M.allocUnsafeSlow?g.exports=E:(U(E,l),l.Buffer=S);function S(G,W,I){return M(G,W,I)}S.prototype=Object.create(M.prototype),U(M,S),S.from=function(G,W,I){if(typeof G=="number")throw new TypeError("Argument must not be a number");return M(G,W,I)},S.alloc=function(G,W,I){if(typeof G!="number")throw new TypeError("Argument must be a number");var V=M(G);return W!==void 0?typeof I=="string"?V.fill(W,I):V.fill(W):V.fill(0),V},S.allocUnsafe=function(G){if(typeof G!="number")throw new TypeError("Argument must be a number");return M(G)},S.allocUnsafeSlow=function(G){if(typeof G!="number")throw new TypeError("Argument must be a number");return E.SlowBuffer(G)}}),g5=G0((l,g)=>{var E=65536,M=4294967295;function U(){throw new Error(`Secure random number generation is not supported by this browser.
2
- Use Chrome, Firefox or Internet Explorer 11`)}var S=d0().Buffer,G=global.crypto||global.msCrypto;G&&G.getRandomValues?g.exports=W:g.exports=U;function W(I,V){if(I>M)throw new RangeError("requested too many random bytes");var z=S.allocUnsafe(I);if(I>0)if(I>E)for(var F=0;F<I;F+=E)G.getRandomValues(z.slice(F,F+E));else G.getRandomValues(z);return typeof V=="function"?process.nextTick(function(){V(null,z)}):z}}),p0=G0((l,g)=>{typeof Object.create=="function"?g.exports=function(E,M){M&&(E.super_=M,E.prototype=Object.create(M.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}))}:g.exports=function(E,M){if(M){E.super_=M;var U=function(){};U.prototype=M.prototype,E.prototype=new U,E.prototype.constructor=E}}}),S5=G0((l,g)=>{var E=typeof Reflect=="object"?Reflect:null,M=E&&typeof E.apply=="function"?E.apply:function(c,n,i){return Function.prototype.apply.call(c,n,i)},U;E&&typeof E.ownKeys=="function"?U=E.ownKeys:Object.getOwnPropertySymbols?U=function(c){return Object.getOwnPropertyNames(c).concat(Object.getOwnPropertySymbols(c))}:U=function(c){return Object.getOwnPropertyNames(c)};function S(c){console&&console.warn&&console.warn(c)}var G=Number.isNaN||function(c){return c!==c};function W(){W.init.call(this)}g.exports=W,g.exports.once=v,W.EventEmitter=W,W.prototype._events=void 0,W.prototype._eventsCount=0,W.prototype._maxListeners=void 0;var I=10;function V(c){if(typeof c!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof c)}Object.defineProperty(W,"defaultMaxListeners",{enumerable:!0,get:function(){return I},set:function(c){if(typeof c!="number"||c<0||G(c))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+c+".");I=c}}),W.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0},W.prototype.setMaxListeners=function(c){if(typeof c!="number"||c<0||G(c))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+c+".");return this._maxListeners=c,this};function z(c){return c._maxListeners===void 0?W.defaultMaxListeners:c._maxListeners}W.prototype.getMaxListeners=function(){return z(this)},W.prototype.emit=function(c){for(var n=[],i=1;i<arguments.length;i++)n.push(arguments[i]);var H0=c==="error",a=this._events;if(a!==void 0)H0=H0&&a.error===void 0;else if(!H0)return!1;if(H0){var P0;if(n.length>0&&(P0=n[0]),P0 instanceof Error)throw P0;var K=new Error("Unhandled error."+(P0?" ("+P0.message+")":""));throw K.context=P0,K}var X=a[c];if(X===void 0)return!1;if(typeof X=="function")M(X,this,n);else for(var Y=X.length,H=k(X,Y),i=0;i<Y;++i)M(H[i],this,n);return!0};function F(c,n,i,H0){var a,P0,K;if(V(i),P0=c._events,P0===void 0?(P0=c._events=Object.create(null),c._eventsCount=0):(P0.newListener!==void 0&&(c.emit("newListener",n,i.listener?i.listener:i),P0=c._events),K=P0[n]),K===void 0)K=P0[n]=i,++c._eventsCount;else if(typeof K=="function"?K=P0[n]=H0?[i,K]:[K,i]:H0?K.unshift(i):K.push(i),a=z(c),a>0&&K.length>a&&!K.warned){K.warned=!0;var X=new Error("Possible EventEmitter memory leak detected. "+K.length+" "+String(n)+" listeners added. Use emitter.setMaxListeners() to increase limit");X.name="MaxListenersExceededWarning",X.emitter=c,X.type=n,X.count=K.length,S(X)}return c}W.prototype.addListener=function(c,n){return F(this,c,n,!1)},W.prototype.on=W.prototype.addListener,W.prototype.prependListener=function(c,n){return F(this,c,n,!0)};function O(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function N(c,n,i){var H0={fired:!1,wrapFn:void 0,target:c,type:n,listener:i},a=O.bind(H0);return a.listener=i,H0.wrapFn=a,a}W.prototype.once=function(c,n){return V(n),this.on(c,N(this,c,n)),this},W.prototype.prependOnceListener=function(c,n){return V(n),this.prependListener(c,N(this,c,n)),this},W.prototype.removeListener=function(c,n){var i,H0,a,P0,K;if(V(n),H0=this._events,H0===void 0)return this;if(i=H0[c],i===void 0)return this;if(i===n||i.listener===n)--this._eventsCount===0?this._events=Object.create(null):(delete H0[c],H0.removeListener&&this.emit("removeListener",c,i.listener||n));else if(typeof i!="function"){for(a=-1,P0=i.length-1;P0>=0;P0--)if(i[P0]===n||i[P0].listener===n){K=i[P0].listener,a=P0;break}if(a<0)return this;a===0?i.shift():A(i,a),i.length===1&&(H0[c]=i[0]),H0.removeListener!==void 0&&this.emit("removeListener",c,K||n)}return this},W.prototype.off=W.prototype.removeListener,W.prototype.removeAllListeners=function(c){var n,i,H0;if(i=this._events,i===void 0)return this;if(i.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):i[c]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete i[c]),this;if(arguments.length===0){var a=Object.keys(i),P0;for(H0=0;H0<a.length;++H0)P0=a[H0],P0!=="removeListener"&&this.removeAllListeners(P0);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(n=i[c],typeof n=="function")this.removeListener(c,n);else if(n!==void 0)for(H0=n.length-1;H0>=0;H0--)this.removeListener(c,n[H0]);return this};function j(c,n,i){var H0=c._events;if(H0===void 0)return[];var a=H0[n];return a===void 0?[]:typeof a=="function"?i?[a.listener||a]:[a]:i?x(a):k(a,a.length)}W.prototype.listeners=function(c){return j(this,c,!0)},W.prototype.rawListeners=function(c){return j(this,c,!1)},W.listenerCount=function(c,n){return typeof c.listenerCount=="function"?c.listenerCount(n):D.call(c,n)},W.prototype.listenerCount=D;function D(c){var n=this._events;if(n!==void 0){var i=n[c];if(typeof i=="function")return 1;if(i!==void 0)return i.length}return 0}W.prototype.eventNames=function(){return this._eventsCount>0?U(this._events):[]};function k(c,n){for(var i=new Array(n),H0=0;H0<n;++H0)i[H0]=c[H0];return i}function A(c,n){for(;n+1<c.length;n++)c[n]=c[n+1];c.pop()}function x(c){for(var n=new Array(c.length),i=0;i<n.length;++i)n[i]=c[i].listener||c[i];return n}function v(c,n){return new Promise(function(i,H0){function a(K){c.removeListener(n,P0),H0(K)}function P0(){typeof c.removeListener=="function"&&c.removeListener("error",a),i([].slice.call(arguments))}p(c,n,P0,{once:!0}),n!=="error"&&y(c,a,{once:!0})})}function y(c,n,i){typeof c.on=="function"&&p(c,"error",n,i)}function p(c,n,i,H0){if(typeof c.on=="function")H0.once?c.once(n,i):c.on(n,i);else if(typeof c.addEventListener=="function")c.addEventListener(n,function a(P0){H0.once&&c.removeEventListener(n,a),i(P0)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof c)}}),c9=G0((l,g)=>{g.exports=S5().EventEmitter}),i5=G0(()=>{}),Q7=G0((l,g)=>{function E(j,D){var k=Object.keys(j);if(Object.getOwnPropertySymbols){var A=Object.getOwnPropertySymbols(j);D&&(A=A.filter(function(x){return Object.getOwnPropertyDescriptor(j,x).enumerable})),k.push.apply(k,A)}return k}function M(j){for(var D=1;D<arguments.length;D++){var k=arguments[D]!=null?arguments[D]:{};D%2?E(Object(k),!0).forEach(function(A){U(j,A,k[A])}):Object.getOwnPropertyDescriptors?Object.defineProperties(j,Object.getOwnPropertyDescriptors(k)):E(Object(k)).forEach(function(A){Object.defineProperty(j,A,Object.getOwnPropertyDescriptor(k,A))})}return j}function U(j,D,k){return D in j?Object.defineProperty(j,D,{value:k,enumerable:!0,configurable:!0,writable:!0}):j[D]=k,j}function S(j,D){if(!(j instanceof D))throw new TypeError("Cannot call a class as a function")}function G(j,D){for(var k=0;k<D.length;k++){var A=D[k];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(j,A.key,A)}}function W(j,D,k){return D&&G(j.prototype,D),k&&G(j,k),j}var I=j5(),V=I.Buffer,z=i5(),F=z.inspect,O=F&&F.custom||"inspect";function N(j,D,k){V.prototype.copy.call(j,D,k)}g.exports=function(){function j(){S(this,j),this.head=null,this.tail=null,this.length=0}return W(j,[{key:"push",value:function(D){var k={data:D,next:null};this.length>0?this.tail.next=k:this.head=k,this.tail=k,++this.length}},{key:"unshift",value:function(D){var k={data:D,next:this.head};this.length===0&&(this.tail=k),this.head=k,++this.length}},{key:"shift",value:function(){if(this.length!==0){var D=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,D}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(D){if(this.length===0)return"";for(var k=this.head,A=""+k.data;k=k.next;)A+=D+k.data;return A}},{key:"concat",value:function(D){if(this.length===0)return V.alloc(0);for(var k=V.allocUnsafe(D>>>0),A=this.head,x=0;A;)N(A.data,k,x),x+=A.data.length,A=A.next;return k}},{key:"consume",value:function(D,k){var A;return D<this.head.data.length?(A=this.head.data.slice(0,D),this.head.data=this.head.data.slice(D)):D===this.head.data.length?A=this.shift():A=k?this._getString(D):this._getBuffer(D),A}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(D){var k=this.head,A=1,x=k.data;for(D-=x.length;k=k.next;){var v=k.data,y=D>v.length?v.length:D;if(y===v.length?x+=v:x+=v.slice(0,D),D-=y,D===0){y===v.length?(++A,k.next?this.head=k.next:this.head=this.tail=null):(this.head=k,k.data=v.slice(y));break}++A}return this.length-=A,x}},{key:"_getBuffer",value:function(D){var k=V.allocUnsafe(D),A=this.head,x=1;for(A.data.copy(k),D-=A.data.length;A=A.next;){var v=A.data,y=D>v.length?v.length:D;if(v.copy(k,k.length-D,0,y),D-=y,D===0){y===v.length?(++x,A.next?this.head=A.next:this.head=this.tail=null):(this.head=A,A.data=v.slice(y));break}++x}return this.length-=x,k}},{key:O,value:function(D,k){return F(this,M({},k,{depth:0,customInspect:!1}))}}]),j}()}),d9=G0((l,g)=>{function E(I,V){var z=this,F=this._readableState&&this._readableState.destroyed,O=this._writableState&&this._writableState.destroyed;return F||O?(V?V(I):I&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(G,this,I)):process.nextTick(G,this,I)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(I||null,function(N){!V&&N?z._writableState?z._writableState.errorEmitted?process.nextTick(U,z):(z._writableState.errorEmitted=!0,process.nextTick(M,z,N)):process.nextTick(M,z,N):V?(process.nextTick(U,z),V(N)):process.nextTick(U,z)}),this)}function M(I,V){G(I,V),U(I)}function U(I){I._writableState&&!I._writableState.emitClose||I._readableState&&!I._readableState.emitClose||I.emit("close")}function S(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function G(I,V){I.emit("error",V)}function W(I,V){var{_readableState:z,_writableState:F}=I;z&&z.autoDestroy||F&&F.autoDestroy?I.destroy(V):I.emit("error",V)}g.exports={destroy:E,undestroy:S,errorOrDestroy:W}}),m5=G0((l,g)=>{function E(V,z){V.prototype=Object.create(z.prototype),V.prototype.constructor=V,V.__proto__=z}var M={};function U(V,z,F){F||(F=Error);function O(j,D,k){return typeof z=="string"?z:z(j,D,k)}var N=function(j){E(D,j);function D(k,A,x){return j.call(this,O(k,A,x))||this}return D}(F);N.prototype.name=F.name,N.prototype.code=V,M[V]=N}function S(V,z){if(Array.isArray(V)){var F=V.length;return V=V.map(function(O){return String(O)}),F>2?"one of ".concat(z," ").concat(V.slice(0,F-1).join(", "),", or ")+V[F-1]:F===2?"one of ".concat(z," ").concat(V[0]," or ").concat(V[1]):"of ".concat(z," ").concat(V[0])}else return"of ".concat(z," ").concat(String(V))}function G(V,z,F){return V.substr(!F||F<0?0:+F,z.length)===z}function W(V,z,F){return(F===void 0||F>V.length)&&(F=V.length),V.substring(F-z.length,F)===z}function I(V,z,F){return typeof F!="number"&&(F=0),F+z.length>V.length?!1:V.indexOf(z,F)!==-1}U("ERR_INVALID_OPT_VALUE",function(V,z){return'The value "'+z+'" is invalid for option "'+V+'"'},TypeError),U("ERR_INVALID_ARG_TYPE",function(V,z,F){var O;typeof z=="string"&&G(z,"not ")?(O="must not be",z=z.replace(/^not /,"")):O="must be";var N;if(W(V," argument"))N="The ".concat(V," ").concat(O," ").concat(S(z,"type"));else{var j=I(V,".")?"property":"argument";N='The "'.concat(V,'" ').concat(j," ").concat(O," ").concat(S(z,"type"))}return N+=". Received type ".concat(typeof F),N},TypeError),U("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),U("ERR_METHOD_NOT_IMPLEMENTED",function(V){return"The "+V+" method is not implemented"}),U("ERR_STREAM_PREMATURE_CLOSE","Premature close"),U("ERR_STREAM_DESTROYED",function(V){return"Cannot call "+V+" after a stream was destroyed"}),U("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),U("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),U("ERR_STREAM_WRITE_AFTER_END","write after end"),U("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),U("ERR_UNKNOWN_ENCODING",function(V){return"Unknown encoding: "+V},TypeError),U("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),g.exports.codes=M}),l9=G0((l,g)=>{var E=m5().codes.ERR_INVALID_OPT_VALUE;function M(S,G,W){return S.highWaterMark!=null?S.highWaterMark:G?S[W]:null}function U(S,G,W,I){var V=M(G,I,W);if(V!=null){if(!(isFinite(V)&&Math.floor(V)===V)||V<0){var z=I?W:"highWaterMark";throw new E(z,V)}return Math.floor(V)}return S.objectMode?16:16384}g.exports={getHighWaterMark:U}}),h9=G0((l,g)=>{g.exports=E;function E(U,S){if(M("noDeprecation"))return U;var G=!1;function W(){if(!G){if(M("throwDeprecation"))throw new Error(S);M("traceDeprecation")?console.trace(S):console.warn(S),G=!0}return U.apply(this,arguments)}return W}function M(U){try{if(!global.localStorage)return!1}catch{return!1}var S=global.localStorage[U];return S==null?!1:String(S).toLowerCase()==="true"}}),u9=G0((l,g)=>{g.exports=a;function E(u){var d=this;this.next=null,this.entry=null,this.finish=function(){X0(d,u)}}var M;a.WritableState=i;var U={deprecate:h9()},S=c9(),G=j5().Buffer,W=global.Uint8Array||function(){};function I(u){return G.from(u)}function V(u){return G.isBuffer(u)||u instanceof W}var z=d9(),F=l9(),O=F.getHighWaterMark,N=m5().codes,j=N.ERR_INVALID_ARG_TYPE,D=N.ERR_METHOD_NOT_IMPLEMENTED,k=N.ERR_MULTIPLE_CALLBACK,A=N.ERR_STREAM_CANNOT_PIPE,x=N.ERR_STREAM_DESTROYED,v=N.ERR_STREAM_NULL_VALUES,y=N.ERR_STREAM_WRITE_AFTER_END,p=N.ERR_UNKNOWN_ENCODING,c=z.errorOrDestroy;p0()(a,S);function n(){}function i(u,d,f){M=M||w5(),u=u||{},typeof f!="boolean"&&(f=d instanceof M),this.objectMode=!!u.objectMode,f&&(this.objectMode=this.objectMode||!!u.writableObjectMode),this.highWaterMark=O(this,u,"writableHighWaterMark",f),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var z0=u.decodeStrings===!1;this.decodeStrings=!z0,this.defaultEncoding=u.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(K0){Z(d,K0)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=u.emitClose!==!1,this.autoDestroy=!!u.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new E(this)}i.prototype.getBuffer=function(){for(var u=this.bufferedRequest,d=[];u;)d.push(u),u=u.next;return d},function(){try{Object.defineProperty(i.prototype,"buffer",{get:U.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var H0;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(H0=Function.prototype[Symbol.hasInstance],Object.defineProperty(a,Symbol.hasInstance,{value:function(u){return H0.call(this,u)?!0:this!==a?!1:u&&u._writableState instanceof i}})):H0=function(u){return u instanceof this};function a(u){M=M||w5();var d=this instanceof M;if(!d&&!H0.call(a,this))return new a(u);this._writableState=new i(u,this,d),this.writable=!0,u&&(typeof u.write=="function"&&(this._write=u.write),typeof u.writev=="function"&&(this._writev=u.writev),typeof u.destroy=="function"&&(this._destroy=u.destroy),typeof u.final=="function"&&(this._final=u.final)),S.call(this)}a.prototype.pipe=function(){c(this,new A)};function P0(u,d){var f=new y;c(u,f),process.nextTick(d,f)}function K(u,d,f,z0){var K0;return f===null?K0=new v:typeof f!="string"&&!d.objectMode&&(K0=new j("chunk",["string","Buffer"],f)),K0?(c(u,K0),process.nextTick(z0,K0),!1):!0}a.prototype.write=function(u,d,f){var z0=this._writableState,K0=!1,Q0=!z0.objectMode&&V(u);return Q0&&!G.isBuffer(u)&&(u=I(u)),typeof d=="function"&&(f=d,d=null),Q0?d="buffer":d||(d=z0.defaultEncoding),typeof f!="function"&&(f=n),z0.ending?P0(this,f):(Q0||K(this,z0,u,f))&&(z0.pendingcb++,K0=Y(this,z0,Q0,u,d,f)),K0},a.prototype.cork=function(){this._writableState.corked++},a.prototype.uncork=function(){var u=this._writableState;u.corked&&(u.corked--,!u.writing&&!u.corked&&!u.bufferProcessing&&u.bufferedRequest&&J(this,u))},a.prototype.setDefaultEncoding=function(u){if(typeof u=="string"&&(u=u.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((u+"").toLowerCase())>-1))throw new p(u);return this._writableState.defaultEncoding=u,this},Object.defineProperty(a.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function X(u,d,f){return!u.objectMode&&u.decodeStrings!==!1&&typeof d=="string"&&(d=G.from(d,f)),d}Object.defineProperty(a.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function Y(u,d,f,z0,K0,Q0){if(!f){var w=X(d,z0,K0);z0!==w&&(f=!0,K0="buffer",z0=w)}var q=d.objectMode?1:z0.length;d.length+=q;var m=d.length<d.highWaterMark;if(m||(d.needDrain=!0),d.writing||d.corked){var e=d.lastBufferedRequest;d.lastBufferedRequest={chunk:z0,encoding:K0,isBuf:f,callback:Q0,next:null},e?e.next=d.lastBufferedRequest:d.bufferedRequest=d.lastBufferedRequest,d.bufferedRequestCount+=1}else H(u,d,!1,q,z0,K0,Q0);return m}function H(u,d,f,z0,K0,Q0,w){d.writelen=z0,d.writecb=w,d.writing=!0,d.sync=!0,d.destroyed?d.onwrite(new x("write")):f?u._writev(K0,d.onwrite):u._write(K0,Q0,d.onwrite),d.sync=!1}function Q(u,d,f,z0,K0){--d.pendingcb,f?(process.nextTick(K0,z0),process.nextTick(s,u,d),u._writableState.errorEmitted=!0,c(u,z0)):(K0(z0),u._writableState.errorEmitted=!0,c(u,z0),s(u,d))}function P(u){u.writing=!1,u.writecb=null,u.length-=u.writelen,u.writelen=0}function Z(u,d){var f=u._writableState,z0=f.sync,K0=f.writecb;if(typeof K0!="function")throw new k;if(P(f),d)Q(u,f,z0,d,K0);else{var Q0=R(f)||u.destroyed;!Q0&&!f.corked&&!f.bufferProcessing&&f.bufferedRequest&&J(u,f),z0?process.nextTick($,u,f,Q0,K0):$(u,f,Q0,K0)}}function $(u,d,f,z0){f||C(u,d),d.pendingcb--,z0(),s(u,d)}function C(u,d){d.length===0&&d.needDrain&&(d.needDrain=!1,u.emit("drain"))}function J(u,d){d.bufferProcessing=!0;var f=d.bufferedRequest;if(u._writev&&f&&f.next){var z0=d.bufferedRequestCount,K0=new Array(z0),Q0=d.corkedRequestsFree;Q0.entry=f;for(var w=0,q=!0;f;)K0[w]=f,f.isBuf||(q=!1),f=f.next,w+=1;K0.allBuffers=q,H(u,d,!0,d.length,K0,"",Q0.finish),d.pendingcb++,d.lastBufferedRequest=null,Q0.next?(d.corkedRequestsFree=Q0.next,Q0.next=null):d.corkedRequestsFree=new E(d),d.bufferedRequestCount=0}else{for(;f;){var{chunk:m,encoding:e,callback:C0}=f,t=d.objectMode?1:m.length;if(H(u,d,!1,t,m,e,C0),f=f.next,d.bufferedRequestCount--,d.writing)break}f===null&&(d.lastBufferedRequest=null)}d.bufferedRequest=f,d.bufferProcessing=!1}a.prototype._write=function(u,d,f){f(new D("_write()"))},a.prototype._writev=null,a.prototype.end=function(u,d,f){var z0=this._writableState;return typeof u=="function"?(f=u,u=null,d=null):typeof d=="function"&&(f=d,d=null),u!=null&&this.write(u,d),z0.corked&&(z0.corked=1,this.uncork()),z0.ending||r(this,z0,f),this},Object.defineProperty(a.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function R(u){return u.ending&&u.length===0&&u.bufferedRequest===null&&!u.finished&&!u.writing}function L(u,d){u._final(function(f){d.pendingcb--,f&&c(u,f),d.prefinished=!0,u.emit("prefinish"),s(u,d)})}function _(u,d){!d.prefinished&&!d.finalCalled&&(typeof u._final=="function"&&!d.destroyed?(d.pendingcb++,d.finalCalled=!0,process.nextTick(L,u,d)):(d.prefinished=!0,u.emit("prefinish")))}function s(u,d){var f=R(d);if(f&&(_(u,d),d.pendingcb===0&&(d.finished=!0,u.emit("finish"),d.autoDestroy))){var z0=u._readableState;(!z0||z0.autoDestroy&&z0.endEmitted)&&u.destroy()}return f}function r(u,d,f){d.ending=!0,s(u,d),f&&(d.finished?process.nextTick(f):u.once("finish",f)),d.ended=!0,u.writable=!1}function X0(u,d,f){var z0=u.entry;for(u.entry=null;z0;){var K0=z0.callback;d.pendingcb--,K0(f),z0=z0.next}d.corkedRequestsFree.next=u}Object.defineProperty(a.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(u){!this._writableState||(this._writableState.destroyed=u)}}),a.prototype.destroy=z.destroy,a.prototype._undestroy=z.undestroy,a.prototype._destroy=function(u,d){d(u)}}),w5=G0((l,g)=>{var E=Object.keys||function(F){var O=[];for(var N in F)O.push(N);return O};g.exports=I;var M=o9(),U=u9();p0()(I,M);for(S=E(U.prototype),W=0;W<S.length;W++)G=S[W],I.prototype[G]||(I.prototype[G]=U.prototype[G]);var S,G,W;function I(F){if(!(this instanceof I))return new I(F);M.call(this,F),U.call(this,F),this.allowHalfOpen=!0,F&&(F.readable===!1&&(this.readable=!1),F.writable===!1&&(this.writable=!1),F.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",V)))}Object.defineProperty(I.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(I.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(I.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function V(){this._writableState.ended||process.nextTick(z,this)}function z(F){F.end()}Object.defineProperty(I.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(F){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=F,this._writableState.destroyed=F)}})}),Z9=G0((l)=>{var g=d0().Buffer,E=g.isEncoding||function(x){switch(x=""+x,x&&x.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function M(x){if(!x)return"utf8";for(var v;;)switch(x){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return x;default:if(v)return;x=(""+x).toLowerCase(),v=!0}}function U(x){var v=M(x);if(typeof v!="string"&&(g.isEncoding===E||!E(x)))throw new Error("Unknown encoding: "+x);return v||x}l.StringDecoder=S;function S(x){this.encoding=U(x);var v;switch(this.encoding){case"utf16le":this.text=O,this.end=N,v=4;break;case"utf8":this.fillLast=V,v=4;break;case"base64":this.text=j,this.end=D,v=3;break;default:this.write=k,this.end=A;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=g.allocUnsafe(v)}S.prototype.write=function(x){if(x.length===0)return"";var v,y;if(this.lastNeed){if(v=this.fillLast(x),v===void 0)return"";y=this.lastNeed,this.lastNeed=0}else y=0;return y<x.length?v?v+this.text(x,y):this.text(x,y):v||""},S.prototype.end=F,S.prototype.text=z,S.prototype.fillLast=function(x){if(this.lastNeed<=x.length)return x.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);x.copy(this.lastChar,this.lastTotal-this.lastNeed,0,x.length),this.lastNeed-=x.length};function G(x){return x<=127?0:x>>5===6?2:x>>4===14?3:x>>3===30?4:x>>6===2?-1:-2}function W(x,v,y){var p=v.length-1;if(p<y)return 0;var c=G(v[p]);return c>=0?(c>0&&(x.lastNeed=c-1),c):--p<y||c===-2?0:(c=G(v[p]),c>=0?(c>0&&(x.lastNeed=c-2),c):--p<y||c===-2?0:(c=G(v[p]),c>=0?(c>0&&(c===2?c=0:x.lastNeed=c-3),c):0))}function I(x,v,y){if((v[0]&192)!==128)return x.lastNeed=0,"�";if(x.lastNeed>1&&v.length>1){if((v[1]&192)!==128)return x.lastNeed=1,"�";if(x.lastNeed>2&&v.length>2&&(v[2]&192)!==128)return x.lastNeed=2,"�"}}function V(x){var v=this.lastTotal-this.lastNeed,y=I(this,x,v);if(y!==void 0)return y;if(this.lastNeed<=x.length)return x.copy(this.lastChar,v,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);x.copy(this.lastChar,v,0,x.length),this.lastNeed-=x.length}function z(x,v){var y=W(this,x,v);if(!this.lastNeed)return x.toString("utf8",v);this.lastTotal=y;var p=x.length-(y-this.lastNeed);return x.copy(this.lastChar,0,p),x.toString("utf8",v,p)}function F(x){var v=x&&x.length?this.write(x):"";return this.lastNeed?v+"�":v}function O(x,v){if((x.length-v)%2===0){var y=x.toString("utf16le",v);if(y){var p=y.charCodeAt(y.length-1);if(p>=55296&&p<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=x[x.length-2],this.lastChar[1]=x[x.length-1],y.slice(0,-1)}return y}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=x[x.length-1],x.toString("utf16le",v,x.length-1)}function N(x){var v=x&&x.length?this.write(x):"";if(this.lastNeed){var y=this.lastTotal-this.lastNeed;return v+this.lastChar.toString("utf16le",0,y)}return v}function j(x,v){var y=(x.length-v)%3;return y===0?x.toString("base64",v):(this.lastNeed=3-y,this.lastTotal=3,y===1?this.lastChar[0]=x[x.length-1]:(this.lastChar[0]=x[x.length-2],this.lastChar[1]=x[x.length-1]),x.toString("base64",v,x.length-y))}function D(x){var v=x&&x.length?this.write(x):"";return this.lastNeed?v+this.lastChar.toString("base64",0,3-this.lastNeed):v}function k(x){return x.toString(this.encoding)}function A(x){return x&&x.length?this.write(x):""}}),d5={};r5(d5,{StringDecoder:()=>G9.StringDecoder,default:()=>G9.StringDecoder});var G9,a5=J9(()=>{G9=E5(Z9())}),F9=G0((l,g)=>{var E=m5().codes.ERR_STREAM_PREMATURE_CLOSE;function M(W){var I=!1;return function(){if(!I){I=!0;for(var V=arguments.length,z=new Array(V),F=0;F<V;F++)z[F]=arguments[F];W.apply(this,z)}}}function U(){}function S(W){return W.setHeader&&typeof W.abort=="function"}function G(W,I,V){if(typeof I=="function")return G(W,null,I);I||(I={}),V=M(V||U);var z=I.readable||I.readable!==!1&&W.readable,F=I.writable||I.writable!==!1&&W.writable,O=function(){W.writable||j()},N=W._writableState&&W._writableState.finished,j=function(){F=!1,N=!0,z||V.call(W)},D=W._readableState&&W._readableState.endEmitted,k=function(){z=!1,D=!0,F||V.call(W)},A=function(y){V.call(W,y)},x=function(){var y;if(z&&!D)return(!W._readableState||!W._readableState.ended)&&(y=new E),V.call(W,y);if(F&&!N)return(!W._writableState||!W._writableState.ended)&&(y=new E),V.call(W,y)},v=function(){W.req.on("finish",j)};return S(W)?(W.on("complete",j),W.on("abort",x),W.req?v():W.on("request",v)):F&&!W._writableState&&(W.on("end",O),W.on("close",O)),W.on("end",k),W.on("finish",j),I.error!==!1&&W.on("error",A),W.on("close",x),function(){W.removeListener("complete",j),W.removeListener("abort",x),W.removeListener("request",v),W.req&&W.req.removeListener("finish",j),W.removeListener("end",O),W.removeListener("close",O),W.removeListener("finish",j),W.removeListener("end",k),W.removeListener("error",A),W.removeListener("close",x)}}g.exports=G}),$7=G0((l,g)=>{var E;function M(v,y,p){return y in v?Object.defineProperty(v,y,{value:p,enumerable:!0,configurable:!0,writable:!0}):v[y]=p,v}var U=F9(),S=Symbol("lastResolve"),G=Symbol("lastReject"),W=Symbol("error"),I=Symbol("ended"),V=Symbol("lastPromise"),z=Symbol("handlePromise"),F=Symbol("stream");function O(v,y){return{value:v,done:y}}function N(v){var y=v[S];if(y!==null){var p=v[F].read();p!==null&&(v[V]=null,v[S]=null,v[G]=null,y(O(p,!1)))}}function j(v){process.nextTick(N,v)}function D(v,y){return function(p,c){v.then(function(){if(y[I]){p(O(void 0,!0));return}y[z](p,c)},c)}}var k=Object.getPrototypeOf(function(){}),A=Object.setPrototypeOf((E={get stream(){return this[F]},next:function(){var v=this,y=this[W];if(y!==null)return Promise.reject(y);if(this[I])return Promise.resolve(O(void 0,!0));if(this[F].destroyed)return new Promise(function(i,H0){process.nextTick(function(){v[W]?H0(v[W]):i(O(void 0,!0))})});var p=this[V],c;if(p)c=new Promise(D(p,this));else{var n=this[F].read();if(n!==null)return Promise.resolve(O(n,!1));c=new Promise(this[z])}return this[V]=c,c}},M(E,Symbol.asyncIterator,function(){return this}),M(E,"return",function(){var v=this;return new Promise(function(y,p){v[F].destroy(null,function(c){if(c){p(c);return}y(O(void 0,!0))})})}),E),k),x=function(v){var y,p=Object.create(A,(y={},M(y,F,{value:v,writable:!0}),M(y,S,{value:null,writable:!0}),M(y,G,{value:null,writable:!0}),M(y,W,{value:null,writable:!0}),M(y,I,{value:v._readableState.endEmitted,writable:!0}),M(y,z,{value:function(c,n){var i=p[F].read();i?(p[V]=null,p[S]=null,p[G]=null,c(O(i,!1))):(p[S]=c,p[G]=n)},writable:!0}),y));return p[V]=null,U(v,function(c){if(c&&c.code!=="ERR_STREAM_PREMATURE_CLOSE"){var n=p[G];n!==null&&(p[V]=null,p[S]=null,p[G]=null,n(c)),p[W]=c;return}var i=p[S];i!==null&&(p[V]=null,p[S]=null,p[G]=null,i(O(void 0,!0))),p[I]=!0}),v.on("readable",j.bind(null,p)),p};g.exports=x}),G7=G0((l,g)=>{g.exports=function(){throw new Error("Readable.from is not available in the browser")}}),o9=G0((l,g)=>{g.exports=K;var E;K.ReadableState=P0;var M=S5().EventEmitter,U=function(w,q){return w.listeners(q).length},S=c9(),G=j5().Buffer,W=global.Uint8Array||function(){};function I(w){return G.from(w)}function V(w){return G.isBuffer(w)||w instanceof W}var z=i5(),F;z&&z.debuglog?F=z.debuglog("stream"):F=function(){};var O=Q7(),N=d9(),j=l9(),D=j.getHighWaterMark,k=m5().codes,A=k.ERR_INVALID_ARG_TYPE,x=k.ERR_STREAM_PUSH_AFTER_EOF,v=k.ERR_METHOD_NOT_IMPLEMENTED,y=k.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,p,c,n;p0()(K,S);var i=N.errorOrDestroy,H0=["error","close","destroy","pause","resume"];function a(w,q,m){if(typeof w.prependListener=="function")return w.prependListener(q,m);!w._events||!w._events[q]?w.on(q,m):Array.isArray(w._events[q])?w._events[q].unshift(m):w._events[q]=[m,w._events[q]]}function P0(w,q,m){E=E||w5(),w=w||{},typeof m!="boolean"&&(m=q instanceof E),this.objectMode=!!w.objectMode,m&&(this.objectMode=this.objectMode||!!w.readableObjectMode),this.highWaterMark=D(this,w,"readableHighWaterMark",m),this.buffer=new O,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=w.emitClose!==!1,this.autoDestroy=!!w.autoDestroy,this.destroyed=!1,this.defaultEncoding=w.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,w.encoding&&(p||(p=(a5(),O5(d5)).StringDecoder),this.decoder=new p(w.encoding),this.encoding=w.encoding)}function K(w){if(E=E||w5(),!(this instanceof K))return new K(w);var q=this instanceof E;this._readableState=new P0(w,this,q),this.readable=!0,w&&(typeof w.read=="function"&&(this._read=w.read),typeof w.destroy=="function"&&(this._destroy=w.destroy)),S.call(this)}Object.defineProperty(K.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(w){!this._readableState||(this._readableState.destroyed=w)}}),K.prototype.destroy=N.destroy,K.prototype._undestroy=N.undestroy,K.prototype._destroy=function(w,q){q(w)},K.prototype.push=function(w,q){var m=this._readableState,e;return m.objectMode?e=!0:typeof w=="string"&&(q=q||m.defaultEncoding,q!==m.encoding&&(w=G.from(w,q),q=""),e=!0),X(this,w,q,!1,e)},K.prototype.unshift=function(w){return X(this,w,null,!0,!1)};function X(w,q,m,e,C0){F("readableAddChunk",q);var t=w._readableState;if(q===null)t.reading=!1,$(w,t);else{var _0;if(C0||(_0=H(t,q)),_0)i(w,_0);else if(t.objectMode||q&&q.length>0)if(typeof q!="string"&&!t.objectMode&&Object.getPrototypeOf(q)!==G.prototype&&(q=I(q)),e)t.endEmitted?i(w,new y):Y(w,t,q,!0);else if(t.ended)i(w,new x);else{if(t.destroyed)return!1;t.reading=!1,t.decoder&&!m?(q=t.decoder.write(q),t.objectMode||q.length!==0?Y(w,t,q,!1):R(w,t)):Y(w,t,q,!1)}else e||(t.reading=!1,R(w,t))}return!t.ended&&(t.length<t.highWaterMark||t.length===0)}function Y(w,q,m,e){q.flowing&&q.length===0&&!q.sync?(q.awaitDrain=0,w.emit("data",m)):(q.length+=q.objectMode?1:m.length,e?q.buffer.unshift(m):q.buffer.push(m),q.needReadable&&C(w)),R(w,q)}function H(w,q){var m;return!V(q)&&typeof q!="string"&&q!==void 0&&!w.objectMode&&(m=new A("chunk",["string","Buffer","Uint8Array"],q)),m}K.prototype.isPaused=function(){return this._readableState.flowing===!1},K.prototype.setEncoding=function(w){p||(p=(a5(),O5(d5)).StringDecoder);var q=new p(w);this._readableState.decoder=q,this._readableState.encoding=this._readableState.decoder.encoding;for(var m=this._readableState.buffer.head,e="";m!==null;)e+=q.write(m.data),m=m.next;return this._readableState.buffer.clear(),e!==""&&this._readableState.buffer.push(e),this._readableState.length=e.length,this};var Q=1073741824;function P(w){return w>=Q?w=Q:(w--,w|=w>>>1,w|=w>>>2,w|=w>>>4,w|=w>>>8,w|=w>>>16,w++),w}function Z(w,q){return w<=0||q.length===0&&q.ended?0:q.objectMode?1:w!==w?q.flowing&&q.length?q.buffer.head.data.length:q.length:(w>q.highWaterMark&&(q.highWaterMark=P(w)),w<=q.length?w:q.ended?q.length:(q.needReadable=!0,0))}K.prototype.read=function(w){F("read",w),w=parseInt(w,10);var q=this._readableState,m=w;if(w!==0&&(q.emittedReadable=!1),w===0&&q.needReadable&&((q.highWaterMark!==0?q.length>=q.highWaterMark:q.length>0)||q.ended))return F("read: emitReadable",q.length,q.ended),q.length===0&&q.ended?z0(this):C(this),null;if(w=Z(w,q),w===0&&q.ended)return q.length===0&&z0(this),null;var e=q.needReadable;F("need readable",e),(q.length===0||q.length-w<q.highWaterMark)&&(e=!0,F("length less than watermark",e)),q.ended||q.reading?(e=!1,F("reading or ended",e)):e&&(F("do read"),q.reading=!0,q.sync=!0,q.length===0&&(q.needReadable=!0),this._read(q.highWaterMark),q.sync=!1,q.reading||(w=Z(m,q)));var C0;return w>0?C0=f(w,q):C0=null,C0===null?(q.needReadable=q.length<=q.highWaterMark,w=0):(q.length-=w,q.awaitDrain=0),q.length===0&&(q.ended||(q.needReadable=!0),m!==w&&q.ended&&z0(this)),C0!==null&&this.emit("data",C0),C0};function $(w,q){if(F("onEofChunk"),!q.ended){if(q.decoder){var m=q.decoder.end();m&&m.length&&(q.buffer.push(m),q.length+=q.objectMode?1:m.length)}q.ended=!0,q.sync?C(w):(q.needReadable=!1,q.emittedReadable||(q.emittedReadable=!0,J(w)))}}function C(w){var q=w._readableState;F("emitReadable",q.needReadable,q.emittedReadable),q.needReadable=!1,q.emittedReadable||(F("emitReadable",q.flowing),q.emittedReadable=!0,process.nextTick(J,w))}function J(w){var q=w._readableState;F("emitReadable_",q.destroyed,q.length,q.ended),!q.destroyed&&(q.length||q.ended)&&(w.emit("readable"),q.emittedReadable=!1),q.needReadable=!q.flowing&&!q.ended&&q.length<=q.highWaterMark,d(w)}function R(w,q){q.readingMore||(q.readingMore=!0,process.nextTick(L,w,q))}function L(w,q){for(;!q.reading&&!q.ended&&(q.length<q.highWaterMark||q.flowing&&q.length===0);){var m=q.length;if(F("maybeReadMore read 0"),w.read(0),m===q.length)break}q.readingMore=!1}K.prototype._read=function(w){i(this,new v("_read()"))},K.prototype.pipe=function(w,q){var m=this,e=this._readableState;switch(e.pipesCount){case 0:e.pipes=w;break;case 1:e.pipes=[e.pipes,w];break;default:e.pipes.push(w);break}e.pipesCount+=1,F("pipe count=%d opts=%j",e.pipesCount,q);var C0=(!q||q.end!==!1)&&w!==process.stdout&&w!==process.stderr,t=C0?$0:b;e.endEmitted?process.nextTick(t):m.once("end",t),w.on("unpipe",_0);function _0(h,o){F("onunpipe"),h===m&&o&&o.hasUnpiped===!1&&(o.hasUnpiped=!0,j0())}function $0(){F("onend"),w.end()}var J0=_(m);w.on("drain",J0);var w0=!1;function j0(){F("cleanup"),w.removeListener("close",T),w.removeListener("finish",B),w.removeListener("drain",J0),w.removeListener("error",c0),w.removeListener("unpipe",_0),m.removeListener("end",$0),m.removeListener("end",b),m.removeListener("data",Z0),w0=!0,e.awaitDrain&&(!w._writableState||w._writableState.needDrain)&&J0()}m.on("data",Z0);function Z0(h){F("ondata");var o=w.write(h);F("dest.write",o),o===!1&&((e.pipesCount===1&&e.pipes===w||e.pipesCount>1&&Q0(e.pipes,w)!==-1)&&!w0&&(F("false write response, pause",e.awaitDrain),e.awaitDrain++),m.pause())}function c0(h){F("onerror",h),b(),w.removeListener("error",c0),U(w,"error")===0&&i(w,h)}a(w,"error",c0);function T(){w.removeListener("finish",B),b()}w.once("close",T);function B(){F("onfinish"),w.removeListener("close",T),b()}w.once("finish",B);function b(){F("unpipe"),m.unpipe(w)}return w.emit("pipe",m),e.flowing||(F("pipe resume"),m.resume()),w};function _(w){return function(){var q=w._readableState;F("pipeOnDrain",q.awaitDrain),q.awaitDrain&&q.awaitDrain--,q.awaitDrain===0&&U(w,"data")&&(q.flowing=!0,d(w))}}K.prototype.unpipe=function(w){var q=this._readableState,m={hasUnpiped:!1};if(q.pipesCount===0)return this;if(q.pipesCount===1)return w&&w!==q.pipes?this:(w||(w=q.pipes),q.pipes=null,q.pipesCount=0,q.flowing=!1,w&&w.emit("unpipe",this,m),this);if(!w){var{pipes:e,pipesCount:C0}=q;q.pipes=null,q.pipesCount=0,q.flowing=!1;for(var t=0;t<C0;t++)e[t].emit("unpipe",this,{hasUnpiped:!1});return this}var _0=Q0(q.pipes,w);return _0===-1?this:(q.pipes.splice(_0,1),q.pipesCount-=1,q.pipesCount===1&&(q.pipes=q.pipes[0]),w.emit("unpipe",this,m),this)},K.prototype.on=function(w,q){var m=S.prototype.on.call(this,w,q),e=this._readableState;return w==="data"?(e.readableListening=this.listenerCount("readable")>0,e.flowing!==!1&&this.resume()):w==="readable"&&!e.endEmitted&&!e.readableListening&&(e.readableListening=e.needReadable=!0,e.flowing=!1,e.emittedReadable=!1,F("on readable",e.length,e.reading),e.length?C(this):e.reading||process.nextTick(r,this)),m},K.prototype.addListener=K.prototype.on,K.prototype.removeListener=function(w,q){var m=S.prototype.removeListener.call(this,w,q);return w==="readable"&&process.nextTick(s,this),m},K.prototype.removeAllListeners=function(w){var q=S.prototype.removeAllListeners.apply(this,arguments);return(w==="readable"||w===void 0)&&process.nextTick(s,this),q};function s(w){var q=w._readableState;q.readableListening=w.listenerCount("readable")>0,q.resumeScheduled&&!q.paused?q.flowing=!0:w.listenerCount("data")>0&&w.resume()}function r(w){F("readable nexttick read 0"),w.read(0)}K.prototype.resume=function(){var w=this._readableState;return w.flowing||(F("resume"),w.flowing=!w.readableListening,X0(this,w)),w.paused=!1,this};function X0(w,q){q.resumeScheduled||(q.resumeScheduled=!0,process.nextTick(u,w,q))}function u(w,q){F("resume",q.reading),q.reading||w.read(0),q.resumeScheduled=!1,w.emit("resume"),d(w),q.flowing&&!q.reading&&w.read(0)}K.prototype.pause=function(){return F("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(F("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function d(w){var q=w._readableState;for(F("flow",q.flowing);q.flowing&&w.read()!==null;);}K.prototype.wrap=function(w){var q=this,m=this._readableState,e=!1;w.on("end",function(){if(F("wrapped end"),m.decoder&&!m.ended){var _0=m.decoder.end();_0&&_0.length&&q.push(_0)}q.push(null)}),w.on("data",function(_0){if(F("wrapped data"),m.decoder&&(_0=m.decoder.write(_0)),!(m.objectMode&&_0==null)&&!(!m.objectMode&&(!_0||!_0.length))){var $0=q.push(_0);$0||(e=!0,w.pause())}});for(var C0 in w)this[C0]===void 0&&typeof w[C0]=="function"&&(this[C0]=function(_0){return function(){return w[_0].apply(w,arguments)}}(C0));for(var t=0;t<H0.length;t++)w.on(H0[t],this.emit.bind(this,H0[t]));return this._read=function(_0){F("wrapped _read",_0),e&&(e=!1,w.resume())},this},typeof Symbol=="function"&&(K.prototype[Symbol.asyncIterator]=function(){return c===void 0&&(c=$7()),c(this)}),Object.defineProperty(K.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(K.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(K.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(w){this._readableState&&(this._readableState.flowing=w)}}),K._fromList=f,Object.defineProperty(K.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function f(w,q){if(q.length===0)return null;var m;return q.objectMode?m=q.buffer.shift():!w||w>=q.length?(q.decoder?m=q.buffer.join(""):q.buffer.length===1?m=q.buffer.first():m=q.buffer.concat(q.length),q.buffer.clear()):m=q.buffer.consume(w,q.decoder),m}function z0(w){var q=w._readableState;F("endReadable",q.endEmitted),q.endEmitted||(q.ended=!0,process.nextTick(K0,q,w))}function K0(w,q){if(F("endReadableNT",w.endEmitted,w.length),!w.endEmitted&&w.length===0&&(w.endEmitted=!0,q.readable=!1,q.emit("end"),w.autoDestroy)){var m=q._writableState;(!m||m.autoDestroy&&m.finished)&&q.destroy()}}typeof Symbol=="function"&&(K.from=function(w,q){return n===void 0&&(n=G7()),n(K,w,q)});function Q0(w,q){for(var m=0,e=w.length;m<e;m++)if(w[m]===q)return m;return-1}}),s9=G0((l,g)=>{g.exports=V;var E=m5().codes,M=E.ERR_METHOD_NOT_IMPLEMENTED,U=E.ERR_MULTIPLE_CALLBACK,S=E.ERR_TRANSFORM_ALREADY_TRANSFORMING,G=E.ERR_TRANSFORM_WITH_LENGTH_0,W=w5();p0()(V,W);function I(O,N){var j=this._transformState;j.transforming=!1;var D=j.writecb;if(D===null)return this.emit("error",new U);j.writechunk=null,j.writecb=null,N!=null&&this.push(N),D(O);var k=this._readableState;k.reading=!1,(k.needReadable||k.length<k.highWaterMark)&&this._read(k.highWaterMark)}function V(O){if(!(this instanceof V))return new V(O);W.call(this,O),this._transformState={afterTransform:I.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,O&&(typeof O.transform=="function"&&(this._transform=O.transform),typeof O.flush=="function"&&(this._flush=O.flush)),this.on("prefinish",z)}function z(){var O=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(N,j){F(O,N,j)}):F(this,null,null)}V.prototype.push=function(O,N){return this._transformState.needTransform=!1,W.prototype.push.call(this,O,N)},V.prototype._transform=function(O,N,j){j(new M("_transform()"))},V.prototype._write=function(O,N,j){var D=this._transformState;if(D.writecb=j,D.writechunk=O,D.writeencoding=N,!D.transforming){var k=this._readableState;(D.needTransform||k.needReadable||k.length<k.highWaterMark)&&this._read(k.highWaterMark)}},V.prototype._read=function(O){var N=this._transformState;N.writechunk!==null&&!N.transforming?(N.transforming=!0,this._transform(N.writechunk,N.writeencoding,N.afterTransform)):N.needTransform=!0},V.prototype._destroy=function(O,N){W.prototype._destroy.call(this,O,function(j){N(j)})};function F(O,N,j){if(N)return O.emit("error",N);if(j!=null&&O.push(j),O._writableState.length)throw new G;if(O._transformState.transforming)throw new S;return O.push(null)}}),J7=G0((l,g)=>{g.exports=M;var E=s9();p0()(M,E);function M(U){if(!(this instanceof M))return new M(U);E.call(this,U)}M.prototype._transform=function(U,S,G){G(null,U)}}),P7=G0((l,g)=>{var E;function M(j){var D=!1;return function(){D||(D=!0,j.apply(void 0,arguments))}}var U=m5().codes,S=U.ERR_MISSING_ARGS,G=U.ERR_STREAM_DESTROYED;function W(j){if(j)throw j}function I(j){return j.setHeader&&typeof j.abort=="function"}function V(j,D,k,A){A=M(A);var x=!1;j.on("close",function(){x=!0}),E===void 0&&(E=F9()),E(j,{readable:D,writable:k},function(y){if(y)return A(y);x=!0,A()});var v=!1;return function(y){if(!x&&!v){if(v=!0,I(j))return j.abort();if(typeof j.destroy=="function")return j.destroy();A(y||new G("pipe"))}}}function z(j){j()}function F(j,D){return j.pipe(D)}function O(j){return!j.length||typeof j[j.length-1]!="function"?W:j.pop()}function N(){for(var j=arguments.length,D=new Array(j),k=0;k<j;k++)D[k]=arguments[k];var A=O(D);if(Array.isArray(D[0])&&(D=D[0]),D.length<2)throw new S("streams");var x,v=D.map(function(y,p){var c=p<D.length-1,n=p>0;return V(y,c,n,function(i){x||(x=i),i&&v.forEach(z),!c&&(v.forEach(z),A(x))})});return D.reduce(F)}g.exports=N}),Z7=G0((l,g)=>{l=g.exports=o9(),l.Stream=l,l.Readable=l,l.Writable=u9(),l.Duplex=w5(),l.Transform=s9(),l.PassThrough=J7(),l.finished=F9(),l.pipeline=P7()}),a9=G0((l,g)=>{var E=d0().Buffer,M=Z7().Transform,U=p0();function S(W,I){if(!E.isBuffer(W)&&typeof W!="string")throw new TypeError(I+" must be a string or a buffer")}function G(W){M.call(this),this._block=E.allocUnsafe(W),this._blockSize=W,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}U(G,M),G.prototype._transform=function(W,I,V){var z=null;try{this.update(W,I)}catch(F){z=F}V(z)},G.prototype._flush=function(W){var I=null;try{this.push(this.digest())}catch(V){I=V}W(I)},G.prototype.update=function(W,I){if(S(W,"Data"),this._finalized)throw new Error("Digest already called");E.isBuffer(W)||(W=E.from(W,I));for(var V=this._block,z=0;this._blockOffset+W.length-z>=this._blockSize;){for(var F=this._blockOffset;F<this._blockSize;)V[F++]=W[z++];this._update(),this._blockOffset=0}for(;z<W.length;)V[this._blockOffset++]=W[z++];for(var O=0,N=W.length*8;N>0;++O)this._length[O]+=N,N=this._length[O]/4294967296|0,N>0&&(this._length[O]-=4294967296*N);return this},G.prototype._update=function(){throw new Error("_update is not implemented")},G.prototype.digest=function(W){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var I=this._digest();W!==void 0&&(I=I.toString(W)),this._block.fill(0),this._blockOffset=0;for(var V=0;V<4;++V)this._length[V]=0;return I},G.prototype._digest=function(){throw new Error("_digest is not implemented")},g.exports=G}),U9=G0((l,g)=>{var E=p0(),M=a9(),U=d0().Buffer,S=new Array(16);function G(){M.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}E(G,M),G.prototype._update=function(){for(var O=S,N=0;N<16;++N)O[N]=this._block.readInt32LE(N*4);var j=this._a,D=this._b,k=this._c,A=this._d;j=I(j,D,k,A,O[0],3614090360,7),A=I(A,j,D,k,O[1],3905402710,12),k=I(k,A,j,D,O[2],606105819,17),D=I(D,k,A,j,O[3],3250441966,22),j=I(j,D,k,A,O[4],4118548399,7),A=I(A,j,D,k,O[5],1200080426,12),k=I(k,A,j,D,O[6],2821735955,17),D=I(D,k,A,j,O[7],4249261313,22),j=I(j,D,k,A,O[8],1770035416,7),A=I(A,j,D,k,O[9],2336552879,12),k=I(k,A,j,D,O[10],4294925233,17),D=I(D,k,A,j,O[11],2304563134,22),j=I(j,D,k,A,O[12],1804603682,7),A=I(A,j,D,k,O[13],4254626195,12),k=I(k,A,j,D,O[14],2792965006,17),D=I(D,k,A,j,O[15],1236535329,22),j=V(j,D,k,A,O[1],4129170786,5),A=V(A,j,D,k,O[6],3225465664,9),k=V(k,A,j,D,O[11],643717713,14),D=V(D,k,A,j,O[0],3921069994,20),j=V(j,D,k,A,O[5],3593408605,5),A=V(A,j,D,k,O[10],38016083,9),k=V(k,A,j,D,O[15],3634488961,14),D=V(D,k,A,j,O[4],3889429448,20),j=V(j,D,k,A,O[9],568446438,5),A=V(A,j,D,k,O[14],3275163606,9),k=V(k,A,j,D,O[3],4107603335,14),D=V(D,k,A,j,O[8],1163531501,20),j=V(j,D,k,A,O[13],2850285829,5),A=V(A,j,D,k,O[2],4243563512,9),k=V(k,A,j,D,O[7],1735328473,14),D=V(D,k,A,j,O[12],2368359562,20),j=z(j,D,k,A,O[5],4294588738,4),A=z(A,j,D,k,O[8],2272392833,11),k=z(k,A,j,D,O[11],1839030562,16),D=z(D,k,A,j,O[14],4259657740,23),j=z(j,D,k,A,O[1],2763975236,4),A=z(A,j,D,k,O[4],1272893353,11),k=z(k,A,j,D,O[7],4139469664,16),D=z(D,k,A,j,O[10],3200236656,23),j=z(j,D,k,A,O[13],681279174,4),A=z(A,j,D,k,O[0],3936430074,11),k=z(k,A,j,D,O[3],3572445317,16),D=z(D,k,A,j,O[6],76029189,23),j=z(j,D,k,A,O[9],3654602809,4),A=z(A,j,D,k,O[12],3873151461,11),k=z(k,A,j,D,O[15],530742520,16),D=z(D,k,A,j,O[2],3299628645,23),j=F(j,D,k,A,O[0],4096336452,6),A=F(A,j,D,k,O[7],1126891415,10),k=F(k,A,j,D,O[14],2878612391,15),D=F(D,k,A,j,O[5],4237533241,21),j=F(j,D,k,A,O[12],1700485571,6),A=F(A,j,D,k,O[3],2399980690,10),k=F(k,A,j,D,O[10],4293915773,15),D=F(D,k,A,j,O[1],2240044497,21),j=F(j,D,k,A,O[8],1873313359,6),A=F(A,j,D,k,O[15],4264355552,10),k=F(k,A,j,D,O[6],2734768916,15),D=F(D,k,A,j,O[13],1309151649,21),j=F(j,D,k,A,O[4],4149444226,6),A=F(A,j,D,k,O[11],3174756917,10),k=F(k,A,j,D,O[2],718787259,15),D=F(D,k,A,j,O[9],3951481745,21),this._a=this._a+j|0,this._b=this._b+D|0,this._c=this._c+k|0,this._d=this._d+A|0},G.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var O=U.allocUnsafe(16);return O.writeInt32LE(this._a,0),O.writeInt32LE(this._b,4),O.writeInt32LE(this._c,8),O.writeInt32LE(this._d,12),O};function W(O,N){return O<<N|O>>>32-N}function I(O,N,j,D,k,A,x){return W(O+(N&j|~N&D)+k+A|0,x)+N|0}function V(O,N,j,D,k,A,x){return W(O+(N&D|j&~D)+k+A|0,x)+N|0}function z(O,N,j,D,k,A,x){return W(O+(N^j^D)+k+A|0,x)+N|0}function F(O,N,j,D,k,A,x){return W(O+(j^(N|~D))+k+A|0,x)+N|0}g.exports=G}),W9=G0((l,g)=>{var E=j5().Buffer,M=p0(),U=a9(),S=new Array(16),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],W=[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],I=[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],z=[0,1518500249,1859775393,2400959708,2840853838],F=[1352829926,1548603684,1836072691,2053994217,0];function O(){U.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}M(O,U),O.prototype._update=function(){for(var v=S,y=0;y<16;++y)v[y]=this._block.readInt32LE(y*4);for(var p=this._a|0,c=this._b|0,n=this._c|0,i=this._d|0,H0=this._e|0,a=this._a|0,P0=this._b|0,K=this._c|0,X=this._d|0,Y=this._e|0,H=0;H<80;H+=1){var Q,P;H<16?(Q=j(p,c,n,i,H0,v[G[H]],z[0],I[H]),P=x(a,P0,K,X,Y,v[W[H]],F[0],V[H])):H<32?(Q=D(p,c,n,i,H0,v[G[H]],z[1],I[H]),P=A(a,P0,K,X,Y,v[W[H]],F[1],V[H])):H<48?(Q=k(p,c,n,i,H0,v[G[H]],z[2],I[H]),P=k(a,P0,K,X,Y,v[W[H]],F[2],V[H])):H<64?(Q=A(p,c,n,i,H0,v[G[H]],z[3],I[H]),P=D(a,P0,K,X,Y,v[W[H]],F[3],V[H])):(Q=x(p,c,n,i,H0,v[G[H]],z[4],I[H]),P=j(a,P0,K,X,Y,v[W[H]],F[4],V[H])),p=H0,H0=i,i=N(n,10),n=c,c=Q,a=Y,Y=X,X=N(K,10),K=P0,P0=P}var Z=this._b+n+X|0;this._b=this._c+i+Y|0,this._c=this._d+H0+a|0,this._d=this._e+p+P0|0,this._e=this._a+c+K|0,this._a=Z},O.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var v=E.alloc?E.alloc(20):new E(20);return v.writeInt32LE(this._a,0),v.writeInt32LE(this._b,4),v.writeInt32LE(this._c,8),v.writeInt32LE(this._d,12),v.writeInt32LE(this._e,16),v};function N(v,y){return v<<y|v>>>32-y}function j(v,y,p,c,n,i,H0,a){return N(v+(y^p^c)+i+H0|0,a)+n|0}function D(v,y,p,c,n,i,H0,a){return N(v+(y&p|~y&c)+i+H0|0,a)+n|0}function k(v,y,p,c,n,i,H0,a){return N(v+((y|~p)^c)+i+H0|0,a)+n|0}function A(v,y,p,c,n,i,H0,a){return N(v+(y&c|p&~c)+i+H0|0,a)+n|0}function x(v,y,p,c,n,i,H0,a){return N(v+(y^(p|~c))+i+H0|0,a)+n|0}g.exports=O}),p5=G0((l,g)=>{var E=d0().Buffer;function M(U,S){this._block=E.alloc(U),this._finalSize=S,this._blockSize=U,this._len=0}M.prototype.update=function(U,S){typeof U=="string"&&(S=S||"utf8",U=E.from(U,S));for(var G=this._block,W=this._blockSize,I=U.length,V=this._len,z=0;z<I;){for(var F=V%W,O=Math.min(I-z,W-F),N=0;N<O;N++)G[F+N]=U[z+N];V+=O,z+=O,V%W===0&&this._update(G)}return this._len+=I,this},M.prototype.digest=function(U){var S=this._len%this._blockSize;this._block[S]=128,this._block.fill(0,S+1),S>=this._finalSize&&(this._update(this._block),this._block.fill(0));var G=this._len*8;if(G<=4294967295)this._block.writeUInt32BE(G,this._blockSize-4);else{var W=(G&4294967295)>>>0,I=(G-W)/4294967296;this._block.writeUInt32BE(I,this._blockSize-8),this._block.writeUInt32BE(W,this._blockSize-4)}this._update(this._block);var V=this._hash();return U?V.toString(U):V},M.prototype._update=function(){throw new Error("_update must be implemented by subclass")},g.exports=M}),F7=G0((l,g)=>{var E=p0(),M=p5(),U=d0().Buffer,S=[1518500249,1859775393,-1894007588,-899497514],G=new Array(80);function W(){this.init(),this._w=G,M.call(this,64,56)}E(W,M),W.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function I(F){return F<<5|F>>>27}function V(F){return F<<30|F>>>2}function z(F,O,N,j){return F===0?O&N|~O&j:F===2?O&N|O&j|N&j:O^N^j}W.prototype._update=function(F){for(var O=this._w,N=this._a|0,j=this._b|0,D=this._c|0,k=this._d|0,A=this._e|0,x=0;x<16;++x)O[x]=F.readInt32BE(x*4);for(;x<80;++x)O[x]=O[x-3]^O[x-8]^O[x-14]^O[x-16];for(var v=0;v<80;++v){var y=~~(v/20),p=I(N)+z(y,j,D,k)+A+O[v]+S[y]|0;A=k,k=D,D=V(j),j=N,N=p}this._a=N+this._a|0,this._b=j+this._b|0,this._c=D+this._c|0,this._d=k+this._d|0,this._e=A+this._e|0},W.prototype._hash=function(){var F=U.allocUnsafe(20);return F.writeInt32BE(this._a|0,0),F.writeInt32BE(this._b|0,4),F.writeInt32BE(this._c|0,8),F.writeInt32BE(this._d|0,12),F.writeInt32BE(this._e|0,16),F},g.exports=W}),U7=G0((l,g)=>{var E=p0(),M=p5(),U=d0().Buffer,S=[1518500249,1859775393,-1894007588,-899497514],G=new Array(80);function W(){this.init(),this._w=G,M.call(this,64,56)}E(W,M),W.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this};function I(O){return O<<1|O>>>31}function V(O){return O<<5|O>>>27}function z(O){return O<<30|O>>>2}function F(O,N,j,D){return O===0?N&j|~N&D:O===2?N&j|N&D|j&D:N^j^D}W.prototype._update=function(O){for(var N=this._w,j=this._a|0,D=this._b|0,k=this._c|0,A=this._d|0,x=this._e|0,v=0;v<16;++v)N[v]=O.readInt32BE(v*4);for(;v<80;++v)N[v]=I(N[v-3]^N[v-8]^N[v-14]^N[v-16]);for(var y=0;y<80;++y){var p=~~(y/20),c=V(j)+F(p,D,k,A)+x+N[y]+S[p]|0;x=A,A=k,k=z(D),D=j,j=c}this._a=j+this._a|0,this._b=D+this._b|0,this._c=k+this._c|0,this._d=A+this._d|0,this._e=x+this._e|0},W.prototype._hash=function(){var O=U.allocUnsafe(20);return O.writeInt32BE(this._a|0,0),O.writeInt32BE(this._b|0,4),O.writeInt32BE(this._c|0,8),O.writeInt32BE(this._d|0,12),O.writeInt32BE(this._e|0,16),O},g.exports=W}),f9=G0((l,g)=>{var E=p0(),M=p5(),U=d0().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],G=new Array(64);function W(){this.init(),this._w=G,M.call(this,64,56)}E(W,M),W.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};function I(j,D,k){return k^j&(D^k)}function V(j,D,k){return j&D|k&(j|D)}function z(j){return(j>>>2|j<<30)^(j>>>13|j<<19)^(j>>>22|j<<10)}function F(j){return(j>>>6|j<<26)^(j>>>11|j<<21)^(j>>>25|j<<7)}function O(j){return(j>>>7|j<<25)^(j>>>18|j<<14)^j>>>3}function N(j){return(j>>>17|j<<15)^(j>>>19|j<<13)^j>>>10}W.prototype._update=function(j){for(var D=this._w,k=this._a|0,A=this._b|0,x=this._c|0,v=this._d|0,y=this._e|0,p=this._f|0,c=this._g|0,n=this._h|0,i=0;i<16;++i)D[i]=j.readInt32BE(i*4);for(;i<64;++i)D[i]=N(D[i-2])+D[i-7]+O(D[i-15])+D[i-16]|0;for(var H0=0;H0<64;++H0){var a=n+F(y)+I(y,p,c)+S[H0]+D[H0]|0,P0=z(k)+V(k,A,x)|0;n=c,c=p,p=y,y=v+a|0,v=x,x=A,A=k,k=a+P0|0}this._a=k+this._a|0,this._b=A+this._b|0,this._c=x+this._c|0,this._d=v+this._d|0,this._e=y+this._e|0,this._f=p+this._f|0,this._g=c+this._g|0,this._h=n+this._h|0},W.prototype._hash=function(){var j=U.allocUnsafe(32);return j.writeInt32BE(this._a,0),j.writeInt32BE(this._b,4),j.writeInt32BE(this._c,8),j.writeInt32BE(this._d,12),j.writeInt32BE(this._e,16),j.writeInt32BE(this._f,20),j.writeInt32BE(this._g,24),j.writeInt32BE(this._h,28),j},g.exports=W}),W7=G0((l,g)=>{var E=p0(),M=f9(),U=p5(),S=d0().Buffer,G=new Array(64);function W(){this.init(),this._w=G,U.call(this,64,56)}E(W,M),W.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},W.prototype._hash=function(){var I=S.allocUnsafe(28);return I.writeInt32BE(this._a,0),I.writeInt32BE(this._b,4),I.writeInt32BE(this._c,8),I.writeInt32BE(this._d,12),I.writeInt32BE(this._e,16),I.writeInt32BE(this._f,20),I.writeInt32BE(this._g,24),I},g.exports=W}),n9=G0((l,g)=>{var E=p0(),M=p5(),U=d0().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],G=new Array(160);function W(){this.init(),this._w=G,M.call(this,128,112)}E(W,M),W.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};function I(A,x,v){return v^A&(x^v)}function V(A,x,v){return A&x|v&(A|x)}function z(A,x){return(A>>>28|x<<4)^(x>>>2|A<<30)^(x>>>7|A<<25)}function F(A,x){return(A>>>14|x<<18)^(A>>>18|x<<14)^(x>>>9|A<<23)}function O(A,x){return(A>>>1|x<<31)^(A>>>8|x<<24)^A>>>7}function N(A,x){return(A>>>1|x<<31)^(A>>>8|x<<24)^(A>>>7|x<<25)}function j(A,x){return(A>>>19|x<<13)^(x>>>29|A<<3)^A>>>6}function D(A,x){return(A>>>19|x<<13)^(x>>>29|A<<3)^(A>>>6|x<<26)}function k(A,x){return A>>>0<x>>>0?1:0}W.prototype._update=function(A){for(var x=this._w,v=this._ah|0,y=this._bh|0,p=this._ch|0,c=this._dh|0,n=this._eh|0,i=this._fh|0,H0=this._gh|0,a=this._hh|0,P0=this._al|0,K=this._bl|0,X=this._cl|0,Y=this._dl|0,H=this._el|0,Q=this._fl|0,P=this._gl|0,Z=this._hl|0,$=0;$<32;$+=2)x[$]=A.readInt32BE($*4),x[$+1]=A.readInt32BE($*4+4);for(;$<160;$+=2){var C=x[$-30],J=x[$-30+1],R=O(C,J),L=N(J,C);C=x[$-4],J=x[$-4+1];var _=j(C,J),s=D(J,C),r=x[$-14],X0=x[$-14+1],u=x[$-32],d=x[$-32+1],f=L+X0|0,z0=R+r+k(f,L)|0;f=f+s|0,z0=z0+_+k(f,s)|0,f=f+d|0,z0=z0+u+k(f,d)|0,x[$]=z0,x[$+1]=f}for(var K0=0;K0<160;K0+=2){z0=x[K0],f=x[K0+1];var Q0=V(v,y,p),w=V(P0,K,X),q=z(v,P0),m=z(P0,v),e=F(n,H),C0=F(H,n),t=S[K0],_0=S[K0+1],$0=I(n,i,H0),J0=I(H,Q,P),w0=Z+C0|0,j0=a+e+k(w0,Z)|0;w0=w0+J0|0,j0=j0+$0+k(w0,J0)|0,w0=w0+_0|0,j0=j0+t+k(w0,_0)|0,w0=w0+f|0,j0=j0+z0+k(w0,f)|0;var Z0=m+w|0,c0=q+Q0+k(Z0,m)|0;a=H0,Z=P,H0=i,P=Q,i=n,Q=H,H=Y+w0|0,n=c+j0+k(H,Y)|0,c=p,Y=X,p=y,X=K,y=v,K=P0,P0=w0+Z0|0,v=j0+c0+k(P0,w0)|0}this._al=this._al+P0|0,this._bl=this._bl+K|0,this._cl=this._cl+X|0,this._dl=this._dl+Y|0,this._el=this._el+H|0,this._fl=this._fl+Q|0,this._gl=this._gl+P|0,this._hl=this._hl+Z|0,this._ah=this._ah+v+k(this._al,P0)|0,this._bh=this._bh+y+k(this._bl,K)|0,this._ch=this._ch+p+k(this._cl,X)|0,this._dh=this._dh+c+k(this._dl,Y)|0,this._eh=this._eh+n+k(this._el,H)|0,this._fh=this._fh+i+k(this._fl,Q)|0,this._gh=this._gh+H0+k(this._gl,P)|0,this._hh=this._hh+a+k(this._hl,Z)|0},W.prototype._hash=function(){var A=U.allocUnsafe(64);function x(v,y,p){A.writeInt32BE(v,p),A.writeInt32BE(y,p+4)}return x(this._ah,this._al,0),x(this._bh,this._bl,8),x(this._ch,this._cl,16),x(this._dh,this._dl,24),x(this._eh,this._el,32),x(this._fh,this._fl,40),x(this._gh,this._gl,48),x(this._hh,this._hl,56),A},g.exports=W}),j7=G0((l,g)=>{var E=p0(),M=n9(),U=p5(),S=d0().Buffer,G=new Array(160);function W(){this.init(),this._w=G,U.call(this,128,112)}E(W,M),W.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},W.prototype._hash=function(){var I=S.allocUnsafe(48);function V(z,F,O){I.writeInt32BE(z,O),I.writeInt32BE(F,O+4)}return V(this._ah,this._al,0),V(this._bh,this._bl,8),V(this._ch,this._cl,16),V(this._dh,this._dl,24),V(this._eh,this._el,32),V(this._fh,this._fl,40),I},g.exports=W}),j9=G0((E,g)=>{var E=g.exports=function(M){M=M.toLowerCase();var U=E[M];if(!U)throw new Error(M+" is not supported (we accept pull requests)");return new U};E.sha=F7(),E.sha1=U7(),E.sha224=W7(),E.sha256=f9(),E.sha384=j7(),E.sha512=n9()}),W5=G0((l,g)=>{g.exports={ArrayIsArray(E){return Array.isArray(E)},ArrayPrototypeIncludes(E,M){return E.includes(M)},ArrayPrototypeIndexOf(E,M){return E.indexOf(M)},ArrayPrototypeJoin(E,M){return E.join(M)},ArrayPrototypeMap(E,M){return E.map(M)},ArrayPrototypePop(E,M){return E.pop(M)},ArrayPrototypePush(E,M){return E.push(M)},ArrayPrototypeSlice(E,M,U){return E.slice(M,U)},Error,FunctionPrototypeCall(E,M,...U){return E.call(M,...U)},FunctionPrototypeSymbolHasInstance(E,M){return Function.prototype[Symbol.hasInstance].call(E,M)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(E,M){return Object.defineProperties(E,M)},ObjectDefineProperty(E,M,U){return Object.defineProperty(E,M,U)},ObjectGetOwnPropertyDescriptor(E,M){return Object.getOwnPropertyDescriptor(E,M)},ObjectKeys(E){return Object.keys(E)},ObjectSetPrototypeOf(E,M){return Object.setPrototypeOf(E,M)},Promise,PromisePrototypeCatch(E,M){return E.catch(M)},PromisePrototypeThen(E,M,U){return E.then(M,U)},PromiseReject(E){return Promise.reject(E)},ReflectApply:Reflect.apply,RegExpPrototypeTest(E,M){return E.test(M)},SafeSet:Set,String,StringPrototypeSlice(E,M,U){return E.slice(M,U)},StringPrototypeToLowerCase(E){return E.toLowerCase()},StringPrototypeToUpperCase(E){return E.toUpperCase()},StringPrototypeTrim(E){return E.trim()},Symbol,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,TypedArrayPrototypeSet(E,M,U){return E.set(M,U)},Uint8Array}}),N5=G0((l,g)=>{var E=j5(),M=Object.getPrototypeOf(async function(){}).constructor,U=globalThis.Blob||E.Blob,S=typeof U<"u"?function(W){return W instanceof U}:function(W){return!1},G=class extends Error{constructor(W){if(!Array.isArray(W))throw new TypeError(`Expected input to be an Array, got ${typeof W}`);let I="";for(let V=0;V<W.length;V++)I+=` ${W[V].stack}
3
- `;super(I),this.name="AggregateError",this.errors=W}};g.exports={AggregateError:G,kEmptyObject:Object.freeze({}),once(W){let I=!1;return function(...V){I||(I=!0,W.apply(this,V))}},createDeferredPromise:function(){let W,I;return{promise:new Promise((V,z)=>{W=V,I=z}),resolve:W,reject:I}},promisify(W){return new Promise((I,V)=>{W((z,...F)=>z?V(z):I(...F))})},debuglog(){return function(){}},format(W,...I){return W.replace(/%([sdifj])/g,function(...[V,z]){let F=I.shift();return z==="f"?F.toFixed(6):z==="j"?JSON.stringify(F):z==="s"&&typeof F=="object"?`${F.constructor!==Object?F.constructor.name:""} {}`.trim():F.toString()})},inspect(W){switch(typeof W){case"string":if(W.includes("'"))if(W.includes('"')){if(!W.includes("`")&&!W.includes("${"))return`\`${W}\``}else return`"${W}"`;return`'${W}'`;case"number":return isNaN(W)?"NaN":Object.is(W,-0)?String(W):W;case"bigint":return`${String(W)}n`;case"boolean":case"undefined":return String(W);case"object":return"{}"}},types:{isAsyncFunction(W){return W instanceof M},isArrayBufferView(W){return ArrayBuffer.isView(W)}},isBlob:S},g.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),z9=G0((l,g)=>{var{AbortController:E,AbortSignal:M}=typeof self<"u"?self:typeof window<"u"?window:void 0;g.exports=E,g.exports.AbortSignal=M,g.exports.default=E}),z5=G0((l,g)=>{var{format:E,inspect:M,AggregateError:U}=N5(),S=globalThis.AggregateError||U,G=Symbol("kIsNodeError"),W=["string","function","number","object","Function","Object","boolean","bigint","symbol"],I=/^([A-Z][a-z0-9]*)+$/,V="__node_internal_",z={};function F(x,v){if(!x)throw new z.ERR_INTERNAL_ASSERTION(v)}function O(x){let v="",y=x.length,p=x[0]==="-"?1:0;for(;y>=p+4;y-=3)v=`_${x.slice(y-3,y)}${v}`;return`${x.slice(0,y)}${v}`}function N(x,v,y){if(typeof v=="function")return F(v.length<=y.length,`Code: ${x}; The provided arguments length (${y.length}) does not match the required ones (${v.length}).`),v(...y);let p=(v.match(/%[dfijoOs]/g)||[]).length;return F(p===y.length,`Code: ${x}; The provided arguments length (${y.length}) does not match the required ones (${p}).`),y.length===0?v:E(v,...y)}function j(x,v,y){y||(y=Error);class p extends y{constructor(...c){super(N(x,v,c))}toString(){return`${this.name} [${x}]: ${this.message}`}}Object.defineProperties(p.prototype,{name:{value:y.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${x}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),p.prototype.code=x,p.prototype[G]=!0,z[x]=p}function D(x){let v=V+x.name;return Object.defineProperty(x,"name",{value:v}),x}function k(x,v){if(x&&v&&x!==v){if(Array.isArray(v.errors))return v.errors.push(x),v;let y=new S([v,x],v.message);return y.code=v.code,y}return x||v}var A=class extends Error{constructor(x="The operation was aborted",v=void 0){if(v!==void 0&&typeof v!="object")throw new z.ERR_INVALID_ARG_TYPE("options","Object",v);super(x,v),this.code="ABORT_ERR",this.name="AbortError"}};j("ERR_ASSERTION","%s",Error),j("ERR_INVALID_ARG_TYPE",(x,v,y)=>{F(typeof x=="string","'name' must be a string"),Array.isArray(v)||(v=[v]);let p="The ";x.endsWith(" argument")?p+=`${x} `:p+=`"${x}" ${x.includes(".")?"property":"argument"} `,p+="must be ";let c=[],n=[],i=[];for(let a of v)F(typeof a=="string","All expected entries have to be of type string"),W.includes(a)?c.push(a.toLowerCase()):I.test(a)?n.push(a):(F(a!=="object",'The value "object" should be written as "Object"'),i.push(a));if(n.length>0){let a=c.indexOf("object");a!==-1&&(c.splice(c,a,1),n.push("Object"))}if(c.length>0){switch(c.length){case 1:p+=`of type ${c[0]}`;break;case 2:p+=`one of type ${c[0]} or ${c[1]}`;break;default:{let a=c.pop();p+=`one of type ${c.join(", ")}, or ${a}`}}(n.length>0||i.length>0)&&(p+=" or ")}if(n.length>0){switch(n.length){case 1:p+=`an instance of ${n[0]}`;break;case 2:p+=`an instance of ${n[0]} or ${n[1]}`;break;default:{let a=n.pop();p+=`an instance of ${n.join(", ")}, or ${a}`}}i.length>0&&(p+=" or ")}switch(i.length){case 0:break;case 1:i[0].toLowerCase()!==i[0]&&(p+="an "),p+=`${i[0]}`;break;case 2:p+=`one of ${i[0]} or ${i[1]}`;break;default:{let a=i.pop();p+=`one of ${i.join(", ")}, or ${a}`}}if(y==null)p+=`. Received ${y}`;else if(typeof y=="function"&&y.name)p+=`. Received function ${y.name}`;else if(typeof y=="object"){var H0;(H0=y.constructor)!==null&&H0!==void 0&&H0.name?p+=`. Received an instance of ${y.constructor.name}`:p+=`. Received ${M(y,{depth:-1})}`}else{let a=M(y,{colors:!1});a.length>25&&(a=`${a.slice(0,25)}...`),p+=`. Received type ${typeof y} (${a})`}return p},TypeError),j("ERR_INVALID_ARG_VALUE",(x,v,y="is invalid")=>{let p=M(v);return p.length>128&&(p=p.slice(0,128)+"..."),`The ${x.includes(".")?"property":"argument"} '${x}' ${y}. Received ${p}`},TypeError),j("ERR_INVALID_RETURN_VALUE",(x,v,y)=>{var p;let c=y!=null&&(p=y.constructor)!==null&&p!==void 0&&p.name?`instance of ${y.constructor.name}`:`type ${typeof y}`;return`Expected ${x} to be returned from the "${v}" function but got ${c}.`},TypeError),j("ERR_MISSING_ARGS",(...x)=>{F(x.length>0,"At least one arg needs to be specified");let v,y=x.length;switch(x=(Array.isArray(x)?x:[x]).map((p)=>`"${p}"`).join(" or "),y){case 1:v+=`The ${x[0]} argument`;break;case 2:v+=`The ${x[0]} and ${x[1]} arguments`;break;default:{let p=x.pop();v+=`The ${x.join(", ")}, and ${p} arguments`}break}return`${v} must be specified`},TypeError),j("ERR_OUT_OF_RANGE",(x,v,y)=>{F(v,'Missing "range" argument');let p;return Number.isInteger(y)&&Math.abs(y)>4294967296?p=O(String(y)):typeof y=="bigint"?(p=String(y),(y>2n**32n||y<-(2n**32n))&&(p=O(p)),p+="n"):p=M(y),`The value of "${x}" is out of range. It must be ${v}. Received ${p}`},RangeError),j("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),j("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),j("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),j("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),j("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),j("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),j("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),j("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),j("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),j("ERR_STREAM_WRITE_AFTER_END","write after end",Error),j("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),g.exports={AbortError:A,aggregateTwoErrors:D(k),hideStackFrames:D,codes:z}}),t5=G0((l,g)=>{var{ArrayIsArray:E,ArrayPrototypeIncludes:M,ArrayPrototypeJoin:U,ArrayPrototypeMap:S,NumberIsInteger:G,NumberIsNaN:W,NumberMAX_SAFE_INTEGER:I,NumberMIN_SAFE_INTEGER:V,NumberParseInt:z,ObjectPrototypeHasOwnProperty:F,RegExpPrototypeExec:O,String:N,StringPrototypeToUpperCase:j,StringPrototypeTrim:D}=W5(),{hideStackFrames:k,codes:{ERR_SOCKET_BAD_PORT:A,ERR_INVALID_ARG_TYPE:x,ERR_INVALID_ARG_VALUE:v,ERR_OUT_OF_RANGE:y,ERR_UNKNOWN_SIGNAL:p}}=z5(),{normalizeEncoding:c}=N5(),{isAsyncFunction:n,isArrayBufferView:i}=N5().types,H0={};function a(w){return w===(w|0)}function P0(w){return w===w>>>0}var K=/^[0-7]+$/,X="must be a 32-bit unsigned integer or an octal string";function Y(w,q,m){if(typeof w>"u"&&(w=m),typeof w=="string"){if(O(K,w)===null)throw new v(q,w,X);w=z(w,8)}return P(w,q),w}var H=k((w,q,m=V,e=I)=>{if(typeof w!="number")throw new x(q,"number",w);if(!G(w))throw new y(q,"an integer",w);if(w<m||w>e)throw new y(q,`>= ${m} && <= ${e}`,w)}),Q=k((w,q,m=-2147483648,e=2147483647)=>{if(typeof w!="number")throw new x(q,"number",w);if(!G(w))throw new y(q,"an integer",w);if(w<m||w>e)throw new y(q,`>= ${m} && <= ${e}`,w)}),P=k((w,q,m=!1)=>{if(typeof w!="number")throw new x(q,"number",w);if(!G(w))throw new y(q,"an integer",w);let e=m?1:0,C0=4294967295;if(w<e||w>C0)throw new y(q,`>= ${e} && <= ${C0}`,w)});function Z(w,q){if(typeof w!="string")throw new x(q,"string",w)}function $(w,q,m=void 0,e){if(typeof w!="number")throw new x(q,"number",w);if(m!=null&&w<m||e!=null&&w>e||(m!=null||e!=null)&&W(w))throw new y(q,`${m!=null?`>= ${m}`:""}${m!=null&&e!=null?" && ":""}${e!=null?`<= ${e}`:""}`,w)}var C=k((w,q,m)=>{if(!M(m,w)){let e=U(S(m,(t)=>typeof t=="string"?`'${t}'`:N(t)),", "),C0="must be one of: "+e;throw new v(q,w,C0)}});function J(w,q){if(typeof w!="boolean")throw new x(q,"boolean",w)}function R(w,q,m){return w==null||!F(w,q)?m:w[q]}var L=k((w,q,m=null)=>{let e=R(m,"allowArray",!1),C0=R(m,"allowFunction",!1);if(!R(m,"nullable",!1)&&w===null||!e&&E(w)||typeof w!="object"&&(!C0||typeof w!="function"))throw new x(q,"Object",w)}),_=k((w,q,m=0)=>{if(!E(w))throw new x(q,"Array",w);if(w.length<m){let e=`must be longer than ${m}`;throw new v(q,w,e)}});function s(w,q="signal"){if(Z(w,q),H0[w]===void 0)throw H0[j(w)]!==void 0?new p(w+" (signals must use all capital letters)"):new p(w)}var r=k((w,q="buffer")=>{if(!i(w))throw new x(q,["Buffer","TypedArray","DataView"],w)});function X0(w,q){let m=c(q),e=w.length;if(m==="hex"&&e%2!==0)throw new v("encoding",q,`is invalid for data of length ${e}`)}function u(w,q="Port",m=!0){if(typeof w!="number"&&typeof w!="string"||typeof w=="string"&&D(w).length===0||+w!==+w>>>0||w>65535||w===0&&!m)throw new A(q,w,m);return w|0}var d=k((w,q)=>{if(w!==void 0&&(w===null||typeof w!="object"||!("aborted"in w)))throw new x(q,"AbortSignal",w)}),f=k((w,q)=>{if(typeof w!="function")throw new x(q,"Function",w)}),z0=k((w,q)=>{if(typeof w!="function"||n(w))throw new x(q,"Function",w)}),K0=k((w,q)=>{if(w!==void 0)throw new x(q,"undefined",w)});function Q0(w,q,m){if(!M(m,w))throw new x(q,`('${U(m,"|")}')`,w)}g.exports={isInt32:a,isUint32:P0,parseFileMode:Y,validateArray:_,validateBoolean:J,validateBuffer:r,validateEncoding:X0,validateFunction:f,validateInt32:Q,validateInteger:H,validateNumber:$,validateObject:L,validateOneOf:C,validatePlainFunction:z0,validatePort:u,validateSignalName:s,validateString:Z,validateUint32:P,validateUndefined:K0,validateUnion:Q0,validateAbortSignal:d}}),m9=G0((l,g)=>{var E=g.exports={},M,U;function S(){throw new Error("setTimeout has not been defined")}function G(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?M=setTimeout:M=S}catch{M=S}try{typeof clearTimeout=="function"?U=clearTimeout:U=G}catch{U=G}})();function W(A){if(M===setTimeout)return setTimeout(A,0);if((M===S||!M)&&setTimeout)return M=setTimeout,setTimeout(A,0);try{return M(A,0)}catch{try{return M.call(null,A,0)}catch{return M.call(this,A,0)}}}function I(A){if(U===clearTimeout)return clearTimeout(A);if((U===G||!U)&&clearTimeout)return U=clearTimeout,clearTimeout(A);try{return U(A)}catch{try{return U.call(null,A)}catch{return U.call(this,A)}}}var V=[],z=!1,F,O=-1;function N(){!z||!F||(z=!1,F.length?V=F.concat(V):O=-1,V.length&&j())}function j(){if(!z){var A=W(N);z=!0;for(var x=V.length;x;){for(F=V,V=[];++O<x;)F&&F[O].run();O=-1,x=V.length}F=null,z=!1,I(A)}}E.nextTick=function(A){var x=new Array(arguments.length-1);if(arguments.length>1)for(var v=1;v<arguments.length;v++)x[v-1]=arguments[v];V.push(new D(A,x)),V.length===1&&!z&&W(j)};function D(A,x){this.fun=A,this.array=x}D.prototype.run=function(){this.fun.apply(null,this.array)},E.title="browser",E.browser=!0,E.env={},E.argv=[],E.version="",E.versions={};function k(){}E.on=k,E.addListener=k,E.once=k,E.off=k,E.removeListener=k,E.removeAllListeners=k,E.emit=k,E.prependListener=k,E.prependOnceListener=k,E.listeners=function(A){return[]},E.binding=function(A){throw new Error("process.binding is not supported")},E.cwd=function(){return"/"},E.chdir=function(A){throw new Error("process.chdir is not supported")},E.umask=function(){return 0}}),I5={};r5(I5,{default:()=>r9});var r9,x5=J9(()=>{P9(I5,E5(m9())),r9=E5(m9())}),A5=G0((l,g)=>{var{Symbol:E,SymbolAsyncIterator:M,SymbolIterator:U}=W5(),S=E("kDestroyed"),G=E("kIsErrored"),W=E("kIsReadable"),I=E("kIsDisturbed");function V(H,Q=!1){var P;return!!(H&&typeof H.pipe=="function"&&typeof H.on=="function"&&(!Q||typeof H.pause=="function"&&typeof H.resume=="function")&&(!H._writableState||((P=H._readableState)===null||P===void 0?void 0:P.readable)!==!1)&&(!H._writableState||H._readableState))}function z(H){var Q;return!!(H&&typeof H.write=="function"&&typeof H.on=="function"&&(!H._readableState||((Q=H._writableState)===null||Q===void 0?void 0:Q.writable)!==!1))}function F(H){return!!(H&&typeof H.pipe=="function"&&H._readableState&&typeof H.on=="function"&&typeof H.write=="function")}function O(H){return H&&(H._readableState||H._writableState||typeof H.write=="function"&&typeof H.on=="function"||typeof H.pipe=="function"&&typeof H.on=="function")}function N(H,Q){return H==null?!1:Q===!0?typeof H[M]=="function":Q===!1?typeof H[U]=="function":typeof H[M]=="function"||typeof H[U]=="function"}function j(H){if(!O(H))return null;let{_writableState:Q,_readableState:P}=H,Z=Q||P;return!!(H.destroyed||H[S]||Z!=null&&Z.destroyed)}function D(H){if(!z(H))return null;if(H.writableEnded===!0)return!0;let Q=H._writableState;return Q!=null&&Q.errored?!1:typeof Q?.ended!="boolean"?null:Q.ended}function k(H,Q){if(!z(H))return null;if(H.writableFinished===!0)return!0;let P=H._writableState;return P!=null&&P.errored?!1:typeof P?.finished!="boolean"?null:!!(P.finished||Q===!1&&P.ended===!0&&P.length===0)}function A(H){if(!V(H))return null;if(H.readableEnded===!0)return!0;let Q=H._readableState;return!Q||Q.errored?!1:typeof Q?.ended!="boolean"?null:Q.ended}function x(H,Q){if(!V(H))return null;let P=H._readableState;return P!=null&&P.errored?!1:typeof P?.endEmitted!="boolean"?null:!!(P.endEmitted||Q===!1&&P.ended===!0&&P.length===0)}function v(H){return H&&H[W]!=null?H[W]:typeof H?.readable!="boolean"?null:j(H)?!1:V(H)&&H.readable&&!x(H)}function y(H){return typeof H?.writable!="boolean"?null:j(H)?!1:z(H)&&H.writable&&!D(H)}function p(H,Q){return O(H)?j(H)?!0:!(Q?.readable!==!1&&v(H)||Q?.writable!==!1&&y(H)):null}function c(H){var Q,P;return O(H)?H.writableErrored?H.writableErrored:(Q=(P=H._writableState)===null||P===void 0?void 0:P.errored)!==null&&Q!==void 0?Q:null:null}function n(H){var Q,P;return O(H)?H.readableErrored?H.readableErrored:(Q=(P=H._readableState)===null||P===void 0?void 0:P.errored)!==null&&Q!==void 0?Q:null:null}function i(H){if(!O(H))return null;if(typeof H.closed=="boolean")return H.closed;let{_writableState:Q,_readableState:P}=H;return typeof Q?.closed=="boolean"||typeof P?.closed=="boolean"?Q?.closed||P?.closed:typeof H._closed=="boolean"&&H0(H)?H._closed:null}function H0(H){return typeof H._closed=="boolean"&&typeof H._defaultKeepAlive=="boolean"&&typeof H._removedConnection=="boolean"&&typeof H._removedContLen=="boolean"}function a(H){return typeof H._sent100=="boolean"&&H0(H)}function P0(H){var Q;return typeof H._consuming=="boolean"&&typeof H._dumped=="boolean"&&((Q=H.req)===null||Q===void 0?void 0:Q.upgradeOrConnect)===void 0}function K(H){if(!O(H))return null;let{_writableState:Q,_readableState:P}=H,Z=Q||P;return!Z&&a(H)||!!(Z&&Z.autoDestroy&&Z.emitClose&&Z.closed===!1)}function X(H){var Q;return!!(H&&((Q=H[I])!==null&&Q!==void 0?Q:H.readableDidRead||H.readableAborted))}function Y(H){var Q,P,Z,$,C,J,R,L,_,s;return!!(H&&((Q=(P=(Z=($=(C=(J=H[G])!==null&&J!==void 0?J:H.readableErrored)!==null&&C!==void 0?C:H.writableErrored)!==null&&$!==void 0?$:(R=H._readableState)===null||R===void 0?void 0:R.errorEmitted)!==null&&Z!==void 0?Z:(L=H._writableState)===null||L===void 0?void 0:L.errorEmitted)!==null&&P!==void 0?P:(_=H._readableState)===null||_===void 0?void 0:_.errored)!==null&&Q!==void 0?Q:(s=H._writableState)===null||s===void 0?void 0:s.errored))}g.exports={kDestroyed:S,isDisturbed:X,kIsDisturbed:I,isErrored:Y,kIsErrored:G,isReadable:v,kIsReadable:W,isClosed:i,isDestroyed:j,isDuplexNodeStream:F,isFinished:p,isIterable:N,isReadableNodeStream:V,isReadableEnded:A,isReadableFinished:x,isReadableErrored:n,isNodeStream:O,isWritable:y,isWritableNodeStream:z,isWritableEnded:D,isWritableFinished:k,isWritableErrored:c,isServerRequest:P0,isServerResponse:a,willEmitClose:K}}),v5=G0((l,g)=>{var E=(x5(),O5(I5)),{AbortError:M,codes:U}=z5(),{ERR_INVALID_ARG_TYPE:S,ERR_STREAM_PREMATURE_CLOSE:G}=U,{kEmptyObject:W,once:I}=N5(),{validateAbortSignal:V,validateFunction:z,validateObject:F}=t5(),{Promise:O}=W5(),{isClosed:N,isReadable:j,isReadableNodeStream:D,isReadableFinished:k,isReadableErrored:A,isWritable:x,isWritableNodeStream:v,isWritableFinished:y,isWritableErrored:p,isNodeStream:c,willEmitClose:n}=A5();function i(K){return K.setHeader&&typeof K.abort=="function"}var H0=()=>{};function a(K,X,Y){var H,Q;arguments.length===2?(Y=X,X=W):X==null?X=W:F(X,"options"),z(Y,"callback"),V(X.signal,"options.signal"),Y=I(Y);let P=(H=X.readable)!==null&&H!==void 0?H:D(K),Z=(Q=X.writable)!==null&&Q!==void 0?Q:v(K);if(!c(K))throw new S("stream","Stream",K);let{_writableState:$,_readableState:C}=K,J=()=>{K.writable||_()},R=n(K)&&D(K)===P&&v(K)===Z,L=y(K,!1),_=()=>{L=!0,K.destroyed&&(R=!1),!(R&&(!K.readable||P))&&(!P||s)&&Y.call(K)},s=k(K,!1),r=()=>{s=!0,K.destroyed&&(R=!1),!(R&&(!K.writable||Z))&&(!Z||L)&&Y.call(K)},X0=(K0)=>{Y.call(K,K0)},u=N(K),d=()=>{u=!0;let K0=p(K)||A(K);if(K0&&typeof K0!="boolean")return Y.call(K,K0);if(P&&!s&&D(K,!0)&&!k(K,!1))return Y.call(K,new G);if(Z&&!L&&!y(K,!1))return Y.call(K,new G);Y.call(K)},f=()=>{K.req.on("finish",_)};i(K)?(K.on("complete",_),R||K.on("abort",d),K.req?f():K.on("request",f)):Z&&!$&&(K.on("end",J),K.on("close",J)),!R&&typeof K.aborted=="boolean"&&K.on("aborted",d),K.on("end",r),K.on("finish",_),X.error!==!1&&K.on("error",X0),K.on("close",d),u?E.nextTick(d):$!=null&&$.errorEmitted||C!=null&&C.errorEmitted?R||E.nextTick(d):(!P&&(!R||j(K))&&(L||x(K)===!1)||!Z&&(!R||x(K))&&(s||j(K)===!1)||C&&K.req&&K.aborted)&&E.nextTick(d);let z0=()=>{Y=H0,K.removeListener("aborted",d),K.removeListener("complete",_),K.removeListener("abort",d),K.removeListener("request",f),K.req&&K.req.removeListener("finish",_),K.removeListener("end",J),K.removeListener("close",J),K.removeListener("finish",_),K.removeListener("end",r),K.removeListener("error",X0),K.removeListener("close",d)};if(X.signal&&!u){let K0=()=>{let Q0=Y;z0(),Q0.call(K,new M(void 0,{cause:X.signal.reason}))};if(X.signal.aborted)E.nextTick(K0);else{let Q0=Y;Y=I((...w)=>{X.signal.removeEventListener("abort",K0),Q0.apply(K,w)}),X.signal.addEventListener("abort",K0)}}return z0}function P0(K,X){return new O((Y,H)=>{a(K,X,(Q)=>{Q?H(Q):Y()})})}g.exports=a,g.exports.finished=P0}),z7=G0((l,g)=>{var E=globalThis.AbortController||z9().AbortController,{codes:{ERR_INVALID_ARG_TYPE:M,ERR_MISSING_ARGS:U,ERR_OUT_OF_RANGE:S},AbortError:G}=z5(),{validateAbortSignal:W,validateInteger:I,validateObject:V}=t5(),z=W5().Symbol("kWeak"),{finished:F}=v5(),{ArrayPrototypePush:O,MathFloor:N,Number:j,NumberIsNaN:D,Promise:k,PromiseReject:A,PromisePrototypeThen:x,Symbol:v}=W5(),y=v("kEmpty"),p=v("kEof");function c(C,J){if(typeof C!="function")throw new M("fn",["Function","AsyncFunction"],C);J!=null&&V(J,"options"),J?.signal!=null&&W(J.signal,"options.signal");let R=1;return J?.concurrency!=null&&(R=N(J.concurrency)),I(R,"concurrency",1),async function*(){var L,_;let s=new E,r=this,X0=[],u=s.signal,d={signal:u},f=()=>s.abort();J!=null&&(L=J.signal)!==null&&L!==void 0&&L.aborted&&f(),J==null||(_=J.signal)===null||_===void 0||_.addEventListener("abort",f);let z0,K0,Q0=!1;function w(){Q0=!0}async function q(){try{for await(let C0 of r){var m;if(Q0)return;if(u.aborted)throw new G;try{C0=C(C0,d)}catch(t){C0=A(t)}C0!==y&&(typeof((m=C0)===null||m===void 0?void 0:m.catch)=="function"&&C0.catch(w),X0.push(C0),z0&&(z0(),z0=null),!Q0&&X0.length&&X0.length>=R&&await new k((t)=>{K0=t}))}X0.push(p)}catch(C0){let t=A(C0);x(t,void 0,w),X0.push(t)}finally{var e;Q0=!0,z0&&(z0(),z0=null),J==null||(e=J.signal)===null||e===void 0||e.removeEventListener("abort",f)}}q();try{for(;;){for(;X0.length>0;){let m=await X0[0];if(m===p)return;if(u.aborted)throw new G;m!==y&&(yield m),X0.shift(),K0&&(K0(),K0=null)}await new k((m)=>{z0=m})}}finally{s.abort(),Q0=!0,K0&&(K0(),K0=null)}}.call(this)}function n(C=void 0){return C!=null&&V(C,"options"),C?.signal!=null&&W(C.signal,"options.signal"),async function*(){let J=0;for await(let L of this){var R;if(C!=null&&(R=C.signal)!==null&&R!==void 0&&R.aborted)throw new G({cause:C.signal.reason});yield[J++,L]}}.call(this)}async function i(C,J=void 0){for await(let R of K.call(this,C,J))return!0;return!1}async function H0(C,J=void 0){if(typeof C!="function")throw new M("fn",["Function","AsyncFunction"],C);return!await i.call(this,async(...R)=>!await C(...R),J)}async function a(C,J){for await(let R of K.call(this,C,J))return R}async function P0(C,J){if(typeof C!="function")throw new M("fn",["Function","AsyncFunction"],C);async function R(L,_){return await C(L,_),y}for await(let L of c.call(this,R,J));}function K(C,J){if(typeof C!="function")throw new M("fn",["Function","AsyncFunction"],C);async function R(L,_){return await C(L,_)?L:y}return c.call(this,R,J)}var X=class extends U{constructor(){super("reduce"),this.message="Reduce of an empty stream requires an initial value"}};async function Y(C,J,R){var L;if(typeof C!="function")throw new M("reducer",["Function","AsyncFunction"],C);R!=null&&V(R,"options"),R?.signal!=null&&W(R.signal,"options.signal");let _=arguments.length>1;if(R!=null&&(L=R.signal)!==null&&L!==void 0&&L.aborted){let d=new G(void 0,{cause:R.signal.reason});throw this.once("error",()=>{}),await F(this.destroy(d)),d}let s=new E,r=s.signal;if(R!=null&&R.signal){let d={once:!0,[z]:this};R.signal.addEventListener("abort",()=>s.abort(),d)}let X0=!1;try{for await(let d of this){var u;if(X0=!0,R!=null&&(u=R.signal)!==null&&u!==void 0&&u.aborted)throw new G;_?J=await C(J,d,{signal:r}):(J=d,_=!0)}if(!X0&&!_)throw new X}finally{s.abort()}return J}async function H(C){C!=null&&V(C,"options"),C?.signal!=null&&W(C.signal,"options.signal");let J=[];for await(let L of this){var R;if(C!=null&&(R=C.signal)!==null&&R!==void 0&&R.aborted)throw new G(void 0,{cause:C.signal.reason});O(J,L)}return J}function Q(C,J){let R=c.call(this,C,J);return async function*(){for await(let L of R)yield*L}.call(this)}function P(C){if(C=j(C),D(C))return 0;if(C<0)throw new S("number",">= 0",C);return C}function Z(C,J=void 0){return J!=null&&V(J,"options"),J?.signal!=null&&W(J.signal,"options.signal"),C=P(C),async function*(){var R;if(J!=null&&(R=J.signal)!==null&&R!==void 0&&R.aborted)throw new G;for await(let _ of this){var L;if(J!=null&&(L=J.signal)!==null&&L!==void 0&&L.aborted)throw new G;C--<=0&&(yield _)}}.call(this)}function $(C,J=void 0){return J!=null&&V(J,"options"),J?.signal!=null&&W(J.signal,"options.signal"),C=P(C),async function*(){var R;if(J!=null&&(R=J.signal)!==null&&R!==void 0&&R.aborted)throw new G;for await(let _ of this){var L;if(J!=null&&(L=J.signal)!==null&&L!==void 0&&L.aborted)throw new G;if(C-- >0)yield _;else return}}.call(this)}g.exports.streamReturningOperators={asIndexedPairs:n,drop:Z,filter:K,flatMap:Q,map:c,take:$},g.exports.promiseReturningOperators={every:H0,forEach:P0,reduce:Y,toArray:H,some:i,find:a}}),b5=G0((l,g)=>{var E=(x5(),O5(I5)),{aggregateTwoErrors:M,codes:{ERR_MULTIPLE_CALLBACK:U},AbortError:S}=z5(),{Symbol:G}=W5(),{kDestroyed:W,isDestroyed:I,isFinished:V,isServerRequest:z}=A5(),F=G("kDestroy"),O=G("kConstruct");function N(K,X,Y){K&&(K.stack,X&&!X.errored&&(X.errored=K),Y&&!Y.errored&&(Y.errored=K))}function j(K,X){let Y=this._readableState,H=this._writableState,Q=H||Y;return H&&H.destroyed||Y&&Y.destroyed?(typeof X=="function"&&X(),this):(N(K,H,Y),H&&(H.destroyed=!0),Y&&(Y.destroyed=!0),Q.constructed?D(this,K,X):this.once(F,function(P){D(this,M(P,K),X)}),this)}function D(K,X,Y){let H=!1;function Q(P){if(H)return;H=!0;let{_readableState:Z,_writableState:$}=K;N(P,$,Z),$&&($.closed=!0),Z&&(Z.closed=!0),typeof Y=="function"&&Y(P),P?E.nextTick(k,K,P):E.nextTick(A,K)}try{K._destroy(X||null,Q)}catch(P){Q(P)}}function k(K,X){x(K,X),A(K)}function A(K){let{_readableState:X,_writableState:Y}=K;Y&&(Y.closeEmitted=!0),X&&(X.closeEmitted=!0),(Y&&Y.emitClose||X&&X.emitClose)&&K.emit("close")}function x(K,X){let{_readableState:Y,_writableState:H}=K;H&&H.errorEmitted||Y&&Y.errorEmitted||(H&&(H.errorEmitted=!0),Y&&(Y.errorEmitted=!0),K.emit("error",X))}function v(){let K=this._readableState,X=this._writableState;K&&(K.constructed=!0,K.closed=!1,K.closeEmitted=!1,K.destroyed=!1,K.errored=null,K.errorEmitted=!1,K.reading=!1,K.ended=K.readable===!1,K.endEmitted=K.readable===!1),X&&(X.constructed=!0,X.destroyed=!1,X.closed=!1,X.closeEmitted=!1,X.errored=null,X.errorEmitted=!1,X.finalCalled=!1,X.prefinished=!1,X.ended=X.writable===!1,X.ending=X.writable===!1,X.finished=X.writable===!1)}function y(K,X,Y){let{_readableState:H,_writableState:Q}=K;if(Q&&Q.destroyed||H&&H.destroyed)return this;H&&H.autoDestroy||Q&&Q.autoDestroy?K.destroy(X):X&&(X.stack,Q&&!Q.errored&&(Q.errored=X),H&&!H.errored&&(H.errored=X),Y?E.nextTick(x,K,X):x(K,X))}function p(K,X){if(typeof K._construct!="function")return;let{_readableState:Y,_writableState:H}=K;Y&&(Y.constructed=!1),H&&(H.constructed=!1),K.once(O,X),!(K.listenerCount(O)>1)&&E.nextTick(c,K)}function c(K){let X=!1;function Y(H){if(X){y(K,H??new U);return}X=!0;let{_readableState:Q,_writableState:P}=K,Z=P||Q;Q&&(Q.constructed=!0),P&&(P.constructed=!0),Z.destroyed?K.emit(F,H):H?y(K,H,!0):E.nextTick(n,K)}try{K._construct(Y)}catch(H){Y(H)}}function n(K){K.emit(O)}function i(K){return K&&K.setHeader&&typeof K.abort=="function"}function H0(K){K.emit("close")}function a(K,X){K.emit("error",X),E.nextTick(H0,K)}function P0(K,X){!K||I(K)||(!X&&!V(K)&&(X=new S),z(K)?(K.socket=null,K.destroy(X)):i(K)?K.abort():i(K.req)?K.req.abort():typeof K.destroy=="function"?K.destroy(X):typeof K.close=="function"?K.close():X?E.nextTick(a,K,X):E.nextTick(H0,K),K.destroyed||(K[W]=!0))}g.exports={construct:p,destroyer:P0,destroy:j,undestroy:v,errorOrDestroy:y}}),O9=G0((l,g)=>{var{ArrayIsArray:E,ObjectSetPrototypeOf:M}=W5(),{EventEmitter:U}=S5();function S(W){U.call(this,W)}M(S.prototype,U.prototype),M(S,U),S.prototype.pipe=function(W,I){let V=this;function z(A){W.writable&&W.write(A)===!1&&V.pause&&V.pause()}V.on("data",z);function F(){V.readable&&V.resume&&V.resume()}W.on("drain",F),!W._isStdio&&(!I||I.end!==!1)&&(V.on("end",N),V.on("close",j));let O=!1;function N(){O||(O=!0,W.end())}function j(){O||(O=!0,typeof W.destroy=="function"&&W.destroy())}function D(A){k(),U.listenerCount(this,"error")===0&&this.emit("error",A)}G(V,"error",D),G(W,"error",D);function k(){V.removeListener("data",z),W.removeListener("drain",F),V.removeListener("end",N),V.removeListener("close",j),V.removeListener("error",D),W.removeListener("error",D),V.removeListener("end",k),V.removeListener("close",k),W.removeListener("close",k)}return V.on("end",k),V.on("close",k),W.on("close",k),W.emit("pipe",V),W};function G(W,I,V){if(typeof W.prependListener=="function")return W.prependListener(I,V);!W._events||!W._events[I]?W.on(I,V):E(W._events[I])?W._events[I].unshift(V):W._events[I]=[V,W._events[I]]}g.exports={Stream:S,prependListener:G}}),V9=G0((l,g)=>{var{AbortError:E,codes:M}=z5(),U=v5(),{ERR_INVALID_ARG_TYPE:S}=M,G=(I,V)=>{if(typeof I!="object"||!("aborted"in I))throw new S(V,"AbortSignal",I)};function W(I){return!!(I&&typeof I.pipe=="function")}g.exports.addAbortSignal=function(I,V){if(G(I,"signal"),!W(V))throw new S("stream","stream.Stream",V);return g.exports.addAbortSignalNoValidate(I,V)},g.exports.addAbortSignalNoValidate=function(I,V){if(typeof I!="object"||!("aborted"in I))return V;let z=()=>{V.destroy(new E(void 0,{cause:I.reason}))};return I.aborted?z():(I.addEventListener("abort",z),U(V,()=>I.removeEventListener("abort",z))),V}}),O7=G0((l,g)=>{var{StringPrototypeSlice:E,SymbolIterator:M,TypedArrayPrototypeSet:U,Uint8Array:S}=W5(),{Buffer:G}=j5(),{inspect:W}=N5();g.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(I){let V={data:I,next:null};this.length>0?this.tail.next=V:this.head=V,this.tail=V,++this.length}unshift(I){let V={data:I,next:this.head};this.length===0&&(this.tail=V),this.head=V,++this.length}shift(){if(this.length===0)return;let I=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,I}clear(){this.head=this.tail=null,this.length=0}join(I){if(this.length===0)return"";let V=this.head,z=""+V.data;for(;(V=V.next)!==null;)z+=I+V.data;return z}concat(I){if(this.length===0)return G.alloc(0);let V=G.allocUnsafe(I>>>0),z=this.head,F=0;for(;z;)U(V,z.data,F),F+=z.data.length,z=z.next;return V}consume(I,V){let z=this.head.data;if(I<z.length){let F=z.slice(0,I);return this.head.data=z.slice(I),F}return I===z.length?this.shift():V?this._getString(I):this._getBuffer(I)}first(){return this.head.data}*[M](){for(let I=this.head;I;I=I.next)yield I.data}_getString(I){let V="",z=this.head,F=0;do{let O=z.data;if(I>O.length)V+=O,I-=O.length;else{I===O.length?(V+=O,++F,z.next?this.head=z.next:this.head=this.tail=null):(V+=E(O,0,I),this.head=z,z.data=E(O,I));break}++F}while((z=z.next)!==null);return this.length-=F,V}_getBuffer(I){let V=G.allocUnsafe(I),z=I,F=this.head,O=0;do{let N=F.data;if(I>N.length)U(V,N,z-I),I-=N.length;else{I===N.length?(U(V,N,z-I),++O,F.next?this.head=F.next:this.head=this.tail=null):(U(V,new S(N.buffer,N.byteOffset,I),z-I),this.head=F,F.data=N.slice(I));break}++O}while((F=F.next)!==null);return this.length-=O,V}[Symbol.for("nodejs.util.inspect.custom")](I,V){return W(this,{...V,depth:0,customInspect:!1})}}}),T9=G0((l,g)=>{var{MathFloor:E,NumberIsInteger:M}=W5(),{ERR_INVALID_ARG_VALUE:U}=z5().codes;function S(I,V,z){return I.highWaterMark!=null?I.highWaterMark:V?I[z]:null}function G(I){return I?16:16384}function W(I,V,z,F){let O=S(V,F,z);if(O!=null){if(!M(O)||O<0){let N=F?`options.${z}`:"options.highWaterMark";throw new U(N,O)}return E(O)}return G(I.objectMode)}g.exports={getHighWaterMark:W,getDefaultHighWaterMark:G}}),i9=G0((l,g)=>{var E=(x5(),O5(I5)),{PromisePrototypeThen:M,SymbolAsyncIterator:U,SymbolIterator:S}=W5(),{Buffer:G}=j5(),{ERR_INVALID_ARG_TYPE:W,ERR_STREAM_NULL_VALUES:I}=z5().codes;function V(z,F,O){let N;if(typeof F=="string"||F instanceof G)return new z({objectMode:!0,...O,read(){this.push(F),this.push(null)}});let j;if(F&&F[U])j=!0,N=F[U]();else if(F&&F[S])j=!1,N=F[S]();else throw new W("iterable",["Iterable"],F);let D=new z({objectMode:!0,highWaterMark:1,...O}),k=!1;D._read=function(){k||(k=!0,x())},D._destroy=function(v,y){M(A(v),()=>E.nextTick(y,v),(p)=>E.nextTick(y,p||v))};async function A(v){let y=v!=null,p=typeof N.throw=="function";if(y&&p){let{value:c,done:n}=await N.throw(v);if(await c,n)return}if(typeof N.return=="function"){let{value:c}=await N.return();await c}}async function x(){for(;;){try{let{value:v,done:y}=j?await N.next():N.next();if(y)D.push(null);else{let p=v&&typeof v.then=="function"?await v:v;if(p===null)throw k=!1,new I;if(D.push(p))continue;k=!1}}catch(v){D.destroy(v)}break}}return D}g.exports=V}),e5=G0((l,g)=>{var E=(x5(),O5(I5)),{ArrayPrototypeIndexOf:M,NumberIsInteger:U,NumberIsNaN:S,NumberParseInt:G,ObjectDefineProperties:W,ObjectKeys:I,ObjectSetPrototypeOf:V,Promise:z,SafeSet:F,SymbolAsyncIterator:O,Symbol:N}=W5();g.exports=R,R.ReadableState=J;var{EventEmitter:j}=S5(),{Stream:D,prependListener:k}=O9(),{Buffer:A}=j5(),{addAbortSignal:x}=V9(),v=v5(),y=N5().debuglog("stream",(T)=>{y=T}),p=O7(),c=b5(),{getHighWaterMark:n,getDefaultHighWaterMark:i}=T9(),{aggregateTwoErrors:H0,codes:{ERR_INVALID_ARG_TYPE:a,ERR_METHOD_NOT_IMPLEMENTED:P0,ERR_OUT_OF_RANGE:K,ERR_STREAM_PUSH_AFTER_EOF:X,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:Y}}=z5(),{validateObject:H}=t5(),Q=N("kPaused"),{StringDecoder:P}=Z9(),Z=i9();V(R.prototype,D.prototype),V(R,D);var $=()=>{},{errorOrDestroy:C}=c;function J(T,B,b){typeof b!="boolean"&&(b=B instanceof L5()),this.objectMode=!!(T&&T.objectMode),b&&(this.objectMode=this.objectMode||!!(T&&T.readableObjectMode)),this.highWaterMark=T?n(this,T,"readableHighWaterMark",b):i(!1),this.buffer=new p,this.length=0,this.pipes=[],this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.constructed=!0,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this[Q]=null,this.errorEmitted=!1,this.emitClose=!T||T.emitClose!==!1,this.autoDestroy=!T||T.autoDestroy!==!1,this.destroyed=!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this.defaultEncoding=T&&T.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.multiAwaitDrain=!1,this.readingMore=!1,this.dataEmitted=!1,this.decoder=null,this.encoding=null,T&&T.encoding&&(this.decoder=new P(T.encoding),this.encoding=T.encoding)}function R(T){if(!(this instanceof R))return new R(T);let B=this instanceof L5();this._readableState=new J(T,this,B),T&&(typeof T.read=="function"&&(this._read=T.read),typeof T.destroy=="function"&&(this._destroy=T.destroy),typeof T.construct=="function"&&(this._construct=T.construct),T.signal&&!B&&x(T.signal,this)),D.call(this,T),c.construct(this,()=>{this._readableState.needReadable&&z0(this,this._readableState)})}R.prototype.destroy=c.destroy,R.prototype._undestroy=c.undestroy,R.prototype._destroy=function(T,B){B(T)},R.prototype[j.captureRejectionSymbol]=function(T){this.destroy(T)},R.prototype.push=function(T,B){return L(this,T,B,!1)},R.prototype.unshift=function(T,B){return L(this,T,B,!0)};function L(T,B,b,h){y("readableAddChunk",B);let o=T._readableState,O0;if(o.objectMode||(typeof B=="string"?(b=b||o.defaultEncoding,o.encoding!==b&&(h&&o.encoding?B=A.from(B,b).toString(o.encoding):(B=A.from(B,b),b=""))):B instanceof A?b="":D._isUint8Array(B)?(B=D._uint8ArrayToBuffer(B),b=""):B!=null&&(O0=new a("chunk",["string","Buffer","Uint8Array"],B))),O0)C(T,O0);else if(B===null)o.reading=!1,u(T,o);else if(o.objectMode||B&&B.length>0)if(h)if(o.endEmitted)C(T,new Y);else{if(o.destroyed||o.errored)return!1;_(T,o,B,!0)}else if(o.ended)C(T,new X);else{if(o.destroyed||o.errored)return!1;o.reading=!1,o.decoder&&!b?(B=o.decoder.write(B),o.objectMode||B.length!==0?_(T,o,B,!1):z0(T,o)):_(T,o,B,!1)}else h||(o.reading=!1,z0(T,o));return!o.ended&&(o.length<o.highWaterMark||o.length===0)}function _(T,B,b,h){B.flowing&&B.length===0&&!B.sync&&T.listenerCount("data")>0?(B.multiAwaitDrain?B.awaitDrainWriters.clear():B.awaitDrainWriters=null,B.dataEmitted=!0,T.emit("data",b)):(B.length+=B.objectMode?1:b.length,h?B.buffer.unshift(b):B.buffer.push(b),B.needReadable&&d(T)),z0(T,B)}R.prototype.isPaused=function(){let T=this._readableState;return T[Q]===!0||T.flowing===!1},R.prototype.setEncoding=function(T){let B=new P(T);this._readableState.decoder=B,this._readableState.encoding=this._readableState.decoder.encoding;let b=this._readableState.buffer,h="";for(let o of b)h+=B.write(o);return b.clear(),h!==""&&b.push(h),this._readableState.length=h.length,this};var s=1073741824;function r(T){if(T>s)throw new K("size","<= 1GiB",T);return T--,T|=T>>>1,T|=T>>>2,T|=T>>>4,T|=T>>>8,T|=T>>>16,T++,T}function X0(T,B){return T<=0||B.length===0&&B.ended?0:B.objectMode?1:S(T)?B.flowing&&B.length?B.buffer.first().length:B.length:T<=B.length?T:B.ended?B.length:0}R.prototype.read=function(T){y("read",T),T===void 0?T=NaN:U(T)||(T=G(T,10));let B=this._readableState,b=T;if(T>B.highWaterMark&&(B.highWaterMark=r(T)),T!==0&&(B.emittedReadable=!1),T===0&&B.needReadable&&((B.highWaterMark!==0?B.length>=B.highWaterMark:B.length>0)||B.ended))return y("read: emitReadable",B.length,B.ended),B.length===0&&B.ended?J0(this):d(this),null;if(T=X0(T,B),T===0&&B.ended)return B.length===0&&J0(this),null;let h=B.needReadable;if(y("need readable",h),(B.length===0||B.length-T<B.highWaterMark)&&(h=!0,y("length less than watermark",h)),B.ended||B.reading||B.destroyed||B.errored||!B.constructed)h=!1,y("reading, ended or constructing",h);else if(h){y("do read"),B.reading=!0,B.sync=!0,B.length===0&&(B.needReadable=!0);try{this._read(B.highWaterMark)}catch(O0){C(this,O0)}B.sync=!1,B.reading||(T=X0(b,B))}let o;return T>0?o=$0(T,B):o=null,o===null?(B.needReadable=B.length<=B.highWaterMark,T=0):(B.length-=T,B.multiAwaitDrain?B.awaitDrainWriters.clear():B.awaitDrainWriters=null),B.length===0&&(B.ended||(B.needReadable=!0),b!==T&&B.ended&&J0(this)),o!==null&&!B.errorEmitted&&!B.closeEmitted&&(B.dataEmitted=!0,this.emit("data",o)),o};function u(T,B){if(y("onEofChunk"),!B.ended){if(B.decoder){let b=B.decoder.end();b&&b.length&&(B.buffer.push(b),B.length+=B.objectMode?1:b.length)}B.ended=!0,B.sync?d(T):(B.needReadable=!1,B.emittedReadable=!0,f(T))}}function d(T){let B=T._readableState;y("emitReadable",B.needReadable,B.emittedReadable),B.needReadable=!1,B.emittedReadable||(y("emitReadable",B.flowing),B.emittedReadable=!0,E.nextTick(f,T))}function f(T){let B=T._readableState;y("emitReadable_",B.destroyed,B.length,B.ended),!B.destroyed&&!B.errored&&(B.length||B.ended)&&(T.emit("readable"),B.emittedReadable=!1),B.needReadable=!B.flowing&&!B.ended&&B.length<=B.highWaterMark,C0(T)}function z0(T,B){!B.readingMore&&B.constructed&&(B.readingMore=!0,E.nextTick(K0,T,B))}function K0(T,B){for(;!B.reading&&!B.ended&&(B.length<B.highWaterMark||B.flowing&&B.length===0);){let b=B.length;if(y("maybeReadMore read 0"),T.read(0),b===B.length)break}B.readingMore=!1}R.prototype._read=function(T){throw new P0("_read()")},R.prototype.pipe=function(T,B){let b=this,h=this._readableState;h.pipes.length===1&&(h.multiAwaitDrain||(h.multiAwaitDrain=!0,h.awaitDrainWriters=new F(h.awaitDrainWriters?[h.awaitDrainWriters]:[]))),h.pipes.push(T),y("pipe count=%d opts=%j",h.pipes.length,B);let o=(!B||B.end!==!1)&&T!==E.stdout&&T!==E.stderr?Y0:T0;h.endEmitted?E.nextTick(o):b.once("end",o),T.on("unpipe",O0);function O0(V0,l0){y("onunpipe"),V0===b&&l0&&l0.hasUnpiped===!1&&(l0.hasUnpiped=!0,W0())}function Y0(){y("onend"),T.end()}let F0,b0=!1;function W0(){y("cleanup"),T.removeListener("close",N0),T.removeListener("finish",G5),F0&&T.removeListener("drain",F0),T.removeListener("error",D0),T.removeListener("unpipe",O0),b.removeListener("end",Y0),b.removeListener("end",T0),b.removeListener("data",y0),b0=!0,F0&&h.awaitDrainWriters&&(!T._writableState||T._writableState.needDrain)&&F0()}function U0(){b0||(h.pipes.length===1&&h.pipes[0]===T?(y("false write response, pause",0),h.awaitDrainWriters=T,h.multiAwaitDrain=!1):h.pipes.length>1&&h.pipes.includes(T)&&(y("false write response, pause",h.awaitDrainWriters.size),h.awaitDrainWriters.add(T)),b.pause()),F0||(F0=Q0(b,T),T.on("drain",F0))}b.on("data",y0);function y0(V0){y("ondata");let l0=T.write(V0);y("dest.write",l0),l0===!1&&U0()}function D0(V0){if(y("onerror",V0),T0(),T.removeListener("error",D0),T.listenerCount("error")===0){let l0=T._writableState||T._readableState;l0&&!l0.errorEmitted?C(T,V0):T.emit("error",V0)}}k(T,"error",D0);function N0(){T.removeListener("finish",G5),T0()}T.once("close",N0);function G5(){y("onfinish"),T.removeListener("close",N0),T0()}T.once("finish",G5);function T0(){y("unpipe"),b.unpipe(T)}return T.emit("pipe",b),T.writableNeedDrain===!0?h.flowing&&U0():h.flowing||(y("pipe resume"),b.resume()),T};function Q0(T,B){return function(){let b=T._readableState;b.awaitDrainWriters===B?(y("pipeOnDrain",1),b.awaitDrainWriters=null):b.multiAwaitDrain&&(y("pipeOnDrain",b.awaitDrainWriters.size),b.awaitDrainWriters.delete(B)),(!b.awaitDrainWriters||b.awaitDrainWriters.size===0)&&T.listenerCount("data")&&T.resume()}}R.prototype.unpipe=function(T){let B=this._readableState,b={hasUnpiped:!1};if(B.pipes.length===0)return this;if(!T){let o=B.pipes;B.pipes=[],this.pause();for(let O0=0;O0<o.length;O0++)o[O0].emit("unpipe",this,{hasUnpiped:!1});return this}let h=M(B.pipes,T);return h===-1?this:(B.pipes.splice(h,1),B.pipes.length===0&&this.pause(),T.emit("unpipe",this,b),this)},R.prototype.on=function(T,B){let b=D.prototype.on.call(this,T,B),h=this._readableState;return T==="data"?(h.readableListening=this.listenerCount("readable")>0,h.flowing!==!1&&this.resume()):T==="readable"&&!h.endEmitted&&!h.readableListening&&(h.readableListening=h.needReadable=!0,h.flowing=!1,h.emittedReadable=!1,y("on readable",h.length,h.reading),h.length?d(this):h.reading||E.nextTick(q,this)),b},R.prototype.addListener=R.prototype.on,R.prototype.removeListener=function(T,B){let b=D.prototype.removeListener.call(this,T,B);return T==="readable"&&E.nextTick(w,this),b},R.prototype.off=R.prototype.removeListener,R.prototype.removeAllListeners=function(T){let B=D.prototype.removeAllListeners.apply(this,arguments);return(T==="readable"||T===void 0)&&E.nextTick(w,this),B};function w(T){let B=T._readableState;B.readableListening=T.listenerCount("readable")>0,B.resumeScheduled&&B[Q]===!1?B.flowing=!0:T.listenerCount("data")>0?T.resume():B.readableListening||(B.flowing=null)}function q(T){y("readable nexttick read 0"),T.read(0)}R.prototype.resume=function(){let T=this._readableState;return T.flowing||(y("resume"),T.flowing=!T.readableListening,m(this,T)),T[Q]=!1,this};function m(T,B){B.resumeScheduled||(B.resumeScheduled=!0,E.nextTick(e,T,B))}function e(T,B){y("resume",B.reading),B.reading||T.read(0),B.resumeScheduled=!1,T.emit("resume"),C0(T),B.flowing&&!B.reading&&T.read(0)}R.prototype.pause=function(){return y("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(y("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState[Q]=!0,this};function C0(T){let B=T._readableState;for(y("flow",B.flowing);B.flowing&&T.read()!==null;);}R.prototype.wrap=function(T){let B=!1;T.on("data",(h)=>{!this.push(h)&&T.pause&&(B=!0,T.pause())}),T.on("end",()=>{this.push(null)}),T.on("error",(h)=>{C(this,h)}),T.on("close",()=>{this.destroy()}),T.on("destroy",()=>{this.destroy()}),this._read=()=>{B&&T.resume&&(B=!1,T.resume())};let b=I(T);for(let h=1;h<b.length;h++){let o=b[h];this[o]===void 0&&typeof T[o]=="function"&&(this[o]=T[o].bind(T))}return this},R.prototype[O]=function(){return t(this)},R.prototype.iterator=function(T){return T!==void 0&&H(T,"options"),t(this,T)};function t(T,B){typeof T.read!="function"&&(T=R.wrap(T,{objectMode:!0}));let b=_0(T,B);return b.stream=T,b}async function*_0(T,B){let b=$;function h(Y0){this===T?(b(),b=$):b=Y0}T.on("readable",h);let o,O0=v(T,{writable:!1},(Y0)=>{o=Y0?H0(o,Y0):null,b(),b=$});try{for(;;){let Y0=T.destroyed?null:T.read();if(Y0!==null)yield Y0;else{if(o)throw o;if(o===null)return;await new z(h)}}}catch(Y0){throw o=H0(o,Y0),o}finally{(o||B?.destroyOnReturn!==!1)&&(o===void 0||T._readableState.autoDestroy)?c.destroyer(T,null):(T.off("readable",h),O0())}}W(R.prototype,{readable:{__proto__:null,get(){let T=this._readableState;return!!T&&T.readable!==!1&&!T.destroyed&&!T.errorEmitted&&!T.endEmitted},set(T){this._readableState&&(this._readableState.readable=!!T)}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(T){this._readableState&&(this._readableState.flowing=T)}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(T){!this._readableState||(this._readableState.destroyed=T)}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),W(J.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[Q]!==!1},set(T){this[Q]=!!T}}}),R._fromList=$0;function $0(T,B){if(B.length===0)return null;let b;return B.objectMode?b=B.buffer.shift():!T||T>=B.length?(B.decoder?b=B.buffer.join(""):B.buffer.length===1?b=B.buffer.first():b=B.buffer.concat(B.length),B.buffer.clear()):b=B.buffer.consume(T,B.decoder),b}function J0(T){let B=T._readableState;y("endReadable",B.endEmitted),B.endEmitted||(B.ended=!0,E.nextTick(w0,B,T))}function w0(T,B){if(y("endReadableNT",T.endEmitted,T.length),!T.errored&&!T.closeEmitted&&!T.endEmitted&&T.length===0){if(T.endEmitted=!0,B.emit("end"),B.writable&&B.allowHalfOpen===!1)E.nextTick(j0,B);else if(T.autoDestroy){let b=B._writableState;(!b||b.autoDestroy&&(b.finished||b.writable===!1))&&B.destroy()}}}function j0(T){T.writable&&!T.writableEnded&&!T.destroyed&&T.end()}R.from=function(T,B){return Z(R,T,B)};var Z0;function c0(){return Z0===void 0&&(Z0={}),Z0}R.fromWeb=function(T,B){return c0().newStreamReadableFromReadableStream(T,B)},R.toWeb=function(T,B){return c0().newReadableStreamFromStreamReadable(T,B)},R.wrap=function(T,B){var b,h;return new R({objectMode:(b=(h=T.readableObjectMode)!==null&&h!==void 0?h:T.objectMode)!==null&&b!==void 0?b:!0,...B,destroy(o,O0){c.destroyer(T,o),O0(o)}}).wrap(T)}}),t9=G0((l,g)=>{var E=(x5(),O5(I5)),{ArrayPrototypeSlice:M,Error:U,FunctionPrototypeSymbolHasInstance:S,ObjectDefineProperty:G,ObjectDefineProperties:W,ObjectSetPrototypeOf:I,StringPrototypeToLowerCase:V,Symbol:z,SymbolHasInstance:F}=W5();g.exports=P,P.WritableState=H;var{EventEmitter:O}=S5(),N=O9().Stream,{Buffer:j}=j5(),D=b5(),{addAbortSignal:k}=V9(),{getHighWaterMark:A,getDefaultHighWaterMark:x}=T9(),{ERR_INVALID_ARG_TYPE:v,ERR_METHOD_NOT_IMPLEMENTED:y,ERR_MULTIPLE_CALLBACK:p,ERR_STREAM_CANNOT_PIPE:c,ERR_STREAM_DESTROYED:n,ERR_STREAM_ALREADY_FINISHED:i,ERR_STREAM_NULL_VALUES:H0,ERR_STREAM_WRITE_AFTER_END:a,ERR_UNKNOWN_ENCODING:P0}=z5().codes,{errorOrDestroy:K}=D;I(P.prototype,N.prototype),I(P,N);function X(){}var Y=z("kOnFinished");function H(q,m,e){typeof e!="boolean"&&(e=m instanceof L5()),this.objectMode=!!(q&&q.objectMode),e&&(this.objectMode=this.objectMode||!!(q&&q.writableObjectMode)),this.highWaterMark=q?A(this,q,"writableHighWaterMark",e):x(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let C0=!!(q&&q.decodeStrings===!1);this.decodeStrings=!C0,this.defaultEncoding=q&&q.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=R.bind(void 0,m),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,Q(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!q||q.emitClose!==!1,this.autoDestroy=!q||q.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[Y]=[]}function Q(q){q.buffered=[],q.bufferedIndex=0,q.allBuffers=!0,q.allNoop=!0}H.prototype.getBuffer=function(){return M(this.buffered,this.bufferedIndex)},G(H.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function P(q){let m=this instanceof L5();if(!m&&!S(P,this))return new P(q);this._writableState=new H(q,this,m),q&&(typeof q.write=="function"&&(this._write=q.write),typeof q.writev=="function"&&(this._writev=q.writev),typeof q.destroy=="function"&&(this._destroy=q.destroy),typeof q.final=="function"&&(this._final=q.final),typeof q.construct=="function"&&(this._construct=q.construct),q.signal&&k(q.signal,this)),N.call(this,q),D.construct(this,()=>{let e=this._writableState;e.writing||r(this,e),f(this,e)})}G(P,F,{__proto__:null,value:function(q){return S(this,q)?!0:this!==P?!1:q&&q._writableState instanceof H}}),P.prototype.pipe=function(){K(this,new c)};function Z(q,m,e,C0){let t=q._writableState;if(typeof e=="function")C0=e,e=t.defaultEncoding;else{if(!e)e=t.defaultEncoding;else if(e!=="buffer"&&!j.isEncoding(e))throw new P0(e);typeof C0!="function"&&(C0=X)}if(m===null)throw new H0;if(!t.objectMode)if(typeof m=="string")t.decodeStrings!==!1&&(m=j.from(m,e),e="buffer");else if(m instanceof j)e="buffer";else if(N._isUint8Array(m))m=N._uint8ArrayToBuffer(m),e="buffer";else throw new v("chunk",["string","Buffer","Uint8Array"],m);let _0;return t.ending?_0=new a:t.destroyed&&(_0=new n("write")),_0?(E.nextTick(C0,_0),K(q,_0,!0),_0):(t.pendingcb++,$(q,t,m,e,C0))}P.prototype.write=function(q,m,e){return Z(this,q,m,e)===!0},P.prototype.cork=function(){this._writableState.corked++},P.prototype.uncork=function(){let q=this._writableState;q.corked&&(q.corked--,q.writing||r(this,q))},P.prototype.setDefaultEncoding=function(q){if(typeof q=="string"&&(q=V(q)),!j.isEncoding(q))throw new P0(q);return this._writableState.defaultEncoding=q,this};function $(q,m,e,C0,t){let _0=m.objectMode?1:e.length;m.length+=_0;let $0=m.length<m.highWaterMark;return $0||(m.needDrain=!0),m.writing||m.corked||m.errored||!m.constructed?(m.buffered.push({chunk:e,encoding:C0,callback:t}),m.allBuffers&&C0!=="buffer"&&(m.allBuffers=!1),m.allNoop&&t!==X&&(m.allNoop=!1)):(m.writelen=_0,m.writecb=t,m.writing=!0,m.sync=!0,q._write(e,C0,m.onwrite),m.sync=!1),$0&&!m.errored&&!m.destroyed}function C(q,m,e,C0,t,_0,$0){m.writelen=C0,m.writecb=$0,m.writing=!0,m.sync=!0,m.destroyed?m.onwrite(new n("write")):e?q._writev(t,m.onwrite):q._write(t,_0,m.onwrite),m.sync=!1}function J(q,m,e,C0){--m.pendingcb,C0(e),s(m),K(q,e)}function R(q,m){let e=q._writableState,C0=e.sync,t=e.writecb;if(typeof t!="function"){K(q,new p);return}e.writing=!1,e.writecb=null,e.length-=e.writelen,e.writelen=0,m?(m.stack,e.errored||(e.errored=m),q._readableState&&!q._readableState.errored&&(q._readableState.errored=m),C0?E.nextTick(J,q,e,m,t):J(q,e,m,t)):(e.buffered.length>e.bufferedIndex&&r(q,e),C0?e.afterWriteTickInfo!==null&&e.afterWriteTickInfo.cb===t?e.afterWriteTickInfo.count++:(e.afterWriteTickInfo={count:1,cb:t,stream:q,state:e},E.nextTick(L,e.afterWriteTickInfo)):_(q,e,1,t))}function L({stream:q,state:m,count:e,cb:C0}){return m.afterWriteTickInfo=null,_(q,m,e,C0)}function _(q,m,e,C0){for(!m.ending&&!q.destroyed&&m.length===0&&m.needDrain&&(m.needDrain=!1,q.emit("drain"));e-- >0;)m.pendingcb--,C0();m.destroyed&&s(m),f(q,m)}function s(q){if(q.writing)return;for(let t=q.bufferedIndex;t<q.buffered.length;++t){var m;let{chunk:_0,callback:$0}=q.buffered[t],J0=q.objectMode?1:_0.length;q.length-=J0,$0((m=q.errored)!==null&&m!==void 0?m:new n("write"))}let e=q[Y].splice(0);for(let t=0;t<e.length;t++){var C0;e[t]((C0=q.errored)!==null&&C0!==void 0?C0:new n("end"))}Q(q)}function r(q,m){if(m.corked||m.bufferProcessing||m.destroyed||!m.constructed)return;let{buffered:e,bufferedIndex:C0,objectMode:t}=m,_0=e.length-C0;if(!_0)return;let $0=C0;if(m.bufferProcessing=!0,_0>1&&q._writev){m.pendingcb-=_0-1;let J0=m.allNoop?X:(j0)=>{for(let Z0=$0;Z0<e.length;++Z0)e[Z0].callback(j0)},w0=m.allNoop&&$0===0?e:M(e,$0);w0.allBuffers=m.allBuffers,C(q,m,!0,m.length,w0,"",J0),Q(m)}else{do{let{chunk:J0,encoding:w0,callback:j0}=e[$0];e[$0++]=null;let Z0=t?1:J0.length;C(q,m,!1,Z0,J0,w0,j0)}while($0<e.length&&!m.writing);$0===e.length?Q(m):$0>256?(e.splice(0,$0),m.bufferedIndex=0):m.bufferedIndex=$0}m.bufferProcessing=!1}P.prototype._write=function(q,m,e){if(this._writev)this._writev([{chunk:q,encoding:m}],e);else throw new y("_write()")},P.prototype._writev=null,P.prototype.end=function(q,m,e){let C0=this._writableState;typeof q=="function"?(e=q,q=null,m=null):typeof m=="function"&&(e=m,m=null);let t;if(q!=null){let _0=Z(this,q,m);_0 instanceof U&&(t=_0)}return C0.corked&&(C0.corked=1,this.uncork()),t||(!C0.errored&&!C0.ending?(C0.ending=!0,f(this,C0,!0),C0.ended=!0):C0.finished?t=new i("end"):C0.destroyed&&(t=new n("end"))),typeof e=="function"&&(t||C0.finished?E.nextTick(e,t):C0[Y].push(e)),this};function X0(q){return q.ending&&!q.destroyed&&q.constructed&&q.length===0&&!q.errored&&q.buffered.length===0&&!q.finished&&!q.writing&&!q.errorEmitted&&!q.closeEmitted}function u(q,m){let e=!1;function C0(t){if(e){K(q,t??p());return}if(e=!0,m.pendingcb--,t){let _0=m[Y].splice(0);for(let $0=0;$0<_0.length;$0++)_0[$0](t);K(q,t,m.sync)}else X0(m)&&(m.prefinished=!0,q.emit("prefinish"),m.pendingcb++,E.nextTick(z0,q,m))}m.sync=!0,m.pendingcb++;try{q._final(C0)}catch(t){C0(t)}m.sync=!1}function d(q,m){!m.prefinished&&!m.finalCalled&&(typeof q._final=="function"&&!m.destroyed?(m.finalCalled=!0,u(q,m)):(m.prefinished=!0,q.emit("prefinish")))}function f(q,m,e){X0(m)&&(d(q,m),m.pendingcb===0&&(e?(m.pendingcb++,E.nextTick((C0,t)=>{X0(t)?z0(C0,t):t.pendingcb--},q,m)):X0(m)&&(m.pendingcb++,z0(q,m))))}function z0(q,m){m.pendingcb--,m.finished=!0;let e=m[Y].splice(0);for(let C0=0;C0<e.length;C0++)e[C0]();if(q.emit("finish"),m.autoDestroy){let C0=q._readableState;(!C0||C0.autoDestroy&&(C0.endEmitted||C0.readable===!1))&&q.destroy()}}W(P.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(q){this._writableState&&(this._writableState.destroyed=q)}},writable:{__proto__:null,get(){let q=this._writableState;return!!q&&q.writable!==!1&&!q.destroyed&&!q.errored&&!q.ending&&!q.ended},set(q){this._writableState&&(this._writableState.writable=!!q)}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let q=this._writableState;return q?!q.destroyed&&!q.ending&&q.needDrain:!1}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var K0=D.destroy;P.prototype.destroy=function(q,m){let e=this._writableState;return!e.destroyed&&(e.bufferedIndex<e.buffered.length||e[Y].length)&&E.nextTick(s,e),K0.call(this,q,m),this},P.prototype._undestroy=D.undestroy,P.prototype._destroy=function(q,m){m(q)},P.prototype[O.captureRejectionSymbol]=function(q){this.destroy(q)};var Q0;function w(){return Q0===void 0&&(Q0={}),Q0}P.fromWeb=function(q,m){return w().newStreamWritableFromWritableStream(q,m)},P.toWeb=function(q){return w().newWritableStreamFromStreamWritable(q)}}),V7=G0((l,g)=>{var E=(x5(),O5(I5)),M=j5(),{isReadable:U,isWritable:S,isIterable:G,isNodeStream:W,isReadableNodeStream:I,isWritableNodeStream:V,isDuplexNodeStream:z}=A5(),F=v5(),{AbortError:O,codes:{ERR_INVALID_ARG_TYPE:N,ERR_INVALID_RETURN_VALUE:j}}=z5(),{destroyer:D}=b5(),k=L5(),A=e5(),{createDeferredPromise:x}=N5(),v=i9(),y=globalThis.Blob||M.Blob,p=typeof y<"u"?function(P0){return P0 instanceof y}:function(P0){return!1},c=globalThis.AbortController||z9().AbortController,{FunctionPrototypeCall:n}=W5(),i=class extends k{constructor(P0){super(P0),P0?.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),P0?.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)}};g.exports=function P0(K,X){if(z(K))return K;if(I(K))return a({readable:K});if(V(K))return a({writable:K});if(W(K))return a({writable:!1,readable:!1});if(typeof K=="function"){let{value:H,write:Q,final:P,destroy:Z}=H0(K);if(G(H))return v(i,H,{objectMode:!0,write:Q,final:P,destroy:Z});let $=H?.then;if(typeof $=="function"){let C,J=n($,H,(R)=>{if(R!=null)throw new j("nully","body",R)},(R)=>{D(C,R)});return C=new i({objectMode:!0,readable:!1,write:Q,final(R){P(async()=>{try{await J,E.nextTick(R,null)}catch(L){E.nextTick(R,L)}})},destroy:Z})}throw new j("Iterable, AsyncIterable or AsyncFunction",X,H)}if(p(K))return P0(K.arrayBuffer());if(G(K))return v(i,K,{objectMode:!0,writable:!1});if(typeof K?.writable=="object"||typeof K?.readable=="object"){let H=K!=null&&K.readable?I(K?.readable)?K?.readable:P0(K.readable):void 0,Q=K!=null&&K.writable?V(K?.writable)?K?.writable:P0(K.writable):void 0;return a({readable:H,writable:Q})}let Y=K?.then;if(typeof Y=="function"){let H;return n(Y,K,(Q)=>{Q!=null&&H.push(Q),H.push(null)},(Q)=>{D(H,Q)}),H=new i({objectMode:!0,writable:!1,read(){}})}throw new N(X,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],K)};function H0(P0){let{promise:K,resolve:X}=x(),Y=new c,H=Y.signal;return{value:P0(async function*(){for(;;){let Q=K;K=null;let{chunk:P,done:Z,cb:$}=await Q;if(E.nextTick($),Z)return;if(H.aborted)throw new O(void 0,{cause:H.reason});({promise:K,resolve:X}=x()),yield P}}(),{signal:H}),write(Q,P,Z){let $=X;X=null,$({chunk:Q,done:!1,cb:Z})},final(Q){let P=X;X=null,P({done:!0,cb:Q})},destroy(Q,P){Y.abort(),P(Q)}}}function a(P0){let K=P0.readable&&typeof P0.readable.read!="function"?A.wrap(P0.readable):P0.readable,X=P0.writable,Y=!!U(K),H=!!S(X),Q,P,Z,$,C;function J(R){let L=$;$=null,L?L(R):R?C.destroy(R):!Y&&!H&&C.destroy()}return C=new i({readableObjectMode:!!(K!=null&&K.readableObjectMode),writableObjectMode:!!(X!=null&&X.writableObjectMode),readable:Y,writable:H}),H&&(F(X,(R)=>{H=!1,R&&D(K,R),J(R)}),C._write=function(R,L,_){X.write(R,L)?_():Q=_},C._final=function(R){X.end(),P=R},X.on("drain",function(){if(Q){let R=Q;Q=null,R()}}),X.on("finish",function(){if(P){let R=P;P=null,R()}})),Y&&(F(K,(R)=>{Y=!1,R&&D(K,R),J(R)}),K.on("readable",function(){if(Z){let R=Z;Z=null,R()}}),K.on("end",function(){C.push(null)}),C._read=function(){for(;;){let R=K.read();if(R===null){Z=C._read;return}if(!C.push(R))return}}),C._destroy=function(R,L){!R&&$!==null&&(R=new O),Z=null,Q=null,P=null,$===null?L(R):($=L,D(X,R),D(K,R))},C}}),L5=G0((l,g)=>{var{ObjectDefineProperties:E,ObjectGetOwnPropertyDescriptor:M,ObjectKeys:U,ObjectSetPrototypeOf:S}=W5();g.exports=I;var G=e5(),W=t9();S(I.prototype,G.prototype),S(I,G);{let O=U(W.prototype);for(let N=0;N<O.length;N++){let j=O[N];I.prototype[j]||(I.prototype[j]=W.prototype[j])}}function I(O){if(!(this instanceof I))return new I(O);G.call(this,O),W.call(this,O),O?(this.allowHalfOpen=O.allowHalfOpen!==!1,O.readable===!1&&(this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0),O.writable===!1&&(this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0)):this.allowHalfOpen=!0}E(I.prototype,{writable:{__proto__:null,...M(W.prototype,"writable")},writableHighWaterMark:{__proto__:null,...M(W.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...M(W.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...M(W.prototype,"writableBuffer")},writableLength:{__proto__:null,...M(W.prototype,"writableLength")},writableFinished:{__proto__:null,...M(W.prototype,"writableFinished")},writableCorked:{__proto__:null,...M(W.prototype,"writableCorked")},writableEnded:{__proto__:null,...M(W.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...M(W.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set(O){this._readableState&&this._writableState&&(this._readableState.destroyed=O,this._writableState.destroyed=O)}}});var V;function z(){return V===void 0&&(V={}),V}I.fromWeb=function(O,N){return z().newStreamDuplexFromReadableWritablePair(O,N)},I.toWeb=function(O){return z().newReadableWritablePairFromDuplex(O)};var F;I.from=function(O){return F||(F=V7()),F(O,"body")}}),e9=G0((l,g)=>{var{ObjectSetPrototypeOf:E,Symbol:M}=W5();g.exports=I;var{ERR_METHOD_NOT_IMPLEMENTED:U}=z5().codes,S=L5(),{getHighWaterMark:G}=T9();E(I.prototype,S.prototype),E(I,S);var W=M("kCallback");function I(F){if(!(this instanceof I))return new I(F);let O=F?G(this,F,"readableHighWaterMark",!0):null;O===0&&(F={...F,highWaterMark:null,readableHighWaterMark:O,writableHighWaterMark:F.writableHighWaterMark||0}),S.call(this,F),this._readableState.sync=!1,this[W]=null,F&&(typeof F.transform=="function"&&(this._transform=F.transform),typeof F.flush=="function"&&(this._flush=F.flush)),this.on("prefinish",z)}function V(F){typeof this._flush=="function"&&!this.destroyed?this._flush((O,N)=>{if(O){F?F(O):this.destroy(O);return}N!=null&&this.push(N),this.push(null),F&&F()}):(this.push(null),F&&F())}function z(){this._final!==V&&V.call(this)}I.prototype._final=V,I.prototype._transform=function(F,O,N){throw new U("_transform()")},I.prototype._write=function(F,O,N){let j=this._readableState,D=this._writableState,k=j.length;this._transform(F,O,(A,x)=>{if(A){N(A);return}x!=null&&this.push(x),D.ended||k===j.length||j.length<j.highWaterMark?N():this[W]=N})},I.prototype._read=function(){if(this[W]){let F=this[W];this[W]=null,F()}}}),K6=G0((l,g)=>{var{ObjectSetPrototypeOf:E}=W5();g.exports=U;var M=e9();E(U.prototype,M.prototype),E(U,M);function U(S){if(!(this instanceof U))return new U(S);M.call(this,S)}U.prototype._transform=function(S,G,W){W(null,S)}}),D9=G0((l,g)=>{var E=(x5(),O5(I5)),{ArrayIsArray:M,Promise:U,SymbolAsyncIterator:S}=W5(),G=v5(),{once:W}=N5(),I=b5(),V=L5(),{aggregateTwoErrors:z,codes:{ERR_INVALID_ARG_TYPE:F,ERR_INVALID_RETURN_VALUE:O,ERR_MISSING_ARGS:N,ERR_STREAM_DESTROYED:j,ERR_STREAM_PREMATURE_CLOSE:D},AbortError:k}=z5(),{validateFunction:A,validateAbortSignal:x}=t5(),{isIterable:v,isReadable:y,isReadableNodeStream:p,isNodeStream:c}=A5(),n=globalThis.AbortController||z9().AbortController,i,H0;function a(Z,$,C){let J=!1;Z.on("close",()=>{J=!0});let R=G(Z,{readable:$,writable:C},(L)=>{J=!L});return{destroy:(L)=>{J||(J=!0,I.destroyer(Z,L||new j("pipe")))},cleanup:R}}function P0(Z){return A(Z[Z.length-1],"streams[stream.length - 1]"),Z.pop()}function K(Z){if(v(Z))return Z;if(p(Z))return X(Z);throw new F("val",["Readable","Iterable","AsyncIterable"],Z)}async function*X(Z){H0||(H0=e5()),yield*H0.prototype[S].call(Z)}async function Y(Z,$,C,{end:J}){let R,L=null,_=(X0)=>{if(X0&&(R=X0),L){let u=L;L=null,u()}},s=()=>new U((X0,u)=>{R?u(R):L=()=>{R?u(R):X0()}});$.on("drain",_);let r=G($,{readable:!1},_);try{$.writableNeedDrain&&await s();for await(let X0 of Z)$.write(X0)||await s();J&&$.end(),await s(),C()}catch(X0){C(R!==X0?z(R,X0):X0)}finally{r(),$.off("drain",_)}}function H(...Z){return Q(Z,W(P0(Z)))}function Q(Z,$,C){if(Z.length===1&&M(Z[0])&&(Z=Z[0]),Z.length<2)throw new N("streams");let J=new n,R=J.signal,L=C?.signal,_=[];x(L,"options.signal");function s(){z0(new k)}L?.addEventListener("abort",s);let r,X0,u=[],d=0;function f(q){z0(q,--d===0)}function z0(q,m){if(q&&(!r||r.code==="ERR_STREAM_PREMATURE_CLOSE")&&(r=q),!(!r&&!m)){for(;u.length;)u.shift()(r);L?.removeEventListener("abort",s),J.abort(),m&&(r||_.forEach((e)=>e()),E.nextTick($,r,X0))}}let K0;for(let q=0;q<Z.length;q++){let m=Z[q],e=q<Z.length-1,C0=q>0,t=e||C?.end!==!1,_0=q===Z.length-1;if(c(m)){let $0=function(J0){J0&&J0.name!=="AbortError"&&J0.code!=="ERR_STREAM_PREMATURE_CLOSE"&&f(J0)};var Q0=$0;if(t){let{destroy:J0,cleanup:w0}=a(m,e,C0);u.push(J0),y(m)&&_0&&_.push(w0)}m.on("error",$0),y(m)&&_0&&_.push(()=>{m.removeListener("error",$0)})}if(q===0)if(typeof m=="function"){if(K0=m({signal:R}),!v(K0))throw new O("Iterable, AsyncIterable or Stream","source",K0)}else v(m)||p(m)?K0=m:K0=V.from(m);else if(typeof m=="function")if(K0=K(K0),K0=m(K0,{signal:R}),e){if(!v(K0,!0))throw new O("AsyncIterable",`transform[${q-1}]`,K0)}else{var w;i||(i=K6());let $0=new i({objectMode:!0}),J0=(w=K0)===null||w===void 0?void 0:w.then;if(typeof J0=="function")d++,J0.call(K0,(Z0)=>{X0=Z0,Z0!=null&&$0.write(Z0),t&&$0.end(),E.nextTick(f)},(Z0)=>{$0.destroy(Z0),E.nextTick(f,Z0)});else if(v(K0,!0))d++,Y(K0,$0,f,{end:t});else throw new O("AsyncIterable or Promise","destination",K0);K0=$0;let{destroy:w0,cleanup:j0}=a(K0,!1,!0);u.push(w0),_0&&_.push(j0)}else if(c(m)){if(p(K0)){d+=2;let $0=P(K0,m,f,{end:t});y(m)&&_0&&_.push($0)}else if(v(K0))d++,Y(K0,m,f,{end:t});else throw new F("val",["Readable","Iterable","AsyncIterable"],K0);K0=m}else K0=V.from(m)}return(R!=null&&R.aborted||L!=null&&L.aborted)&&E.nextTick(s),K0}function P(Z,$,C,{end:J}){let R=!1;return $.on("close",()=>{R||C(new D)}),Z.pipe($,{end:J}),J?Z.once("end",()=>{R=!0,$.end()}):C(),G(Z,{readable:!0,writable:!1},(L)=>{let _=Z._readableState;L&&L.code==="ERR_STREAM_PREMATURE_CLOSE"&&_&&_.ended&&!_.errored&&!_.errorEmitted?Z.once("end",C).once("error",C):C(L)}),G($,{readable:!1,writable:!0},C)}g.exports={pipelineImpl:Q,pipeline:H}}),T7=G0((l,g)=>{var{pipeline:E}=D9(),M=L5(),{destroyer:U}=b5(),{isNodeStream:S,isReadable:G,isWritable:W}=A5(),{AbortError:I,codes:{ERR_INVALID_ARG_VALUE:V,ERR_MISSING_ARGS:z}}=z5();g.exports=function(...F){if(F.length===0)throw new z("streams");if(F.length===1)return M.from(F[0]);let O=[...F];if(typeof F[0]=="function"&&(F[0]=M.from(F[0])),typeof F[F.length-1]=="function"){let n=F.length-1;F[n]=M.from(F[n])}for(let n=0;n<F.length;++n)if(S(F[n])){if(n<F.length-1&&!G(F[n]))throw new V(`streams[${n}]`,O[n],"must be readable");if(n>0&&!W(F[n]))throw new V(`streams[${n}]`,O[n],"must be writable")}let N,j,D,k,A;function x(n){let i=k;k=null,i?i(n):n?A.destroy(n):!c&&!p&&A.destroy()}let v=F[0],y=E(F,x),p=!!W(v),c=!!G(y);return A=new M({writableObjectMode:!!(v!=null&&v.writableObjectMode),readableObjectMode:!!(y!=null&&y.writableObjectMode),writable:p,readable:c}),p&&(A._write=function(n,i,H0){v.write(n,i)?H0():N=H0},A._final=function(n){v.end(),j=n},v.on("drain",function(){if(N){let n=N;N=null,n()}}),y.on("finish",function(){if(j){let n=j;j=null,n()}})),c&&(y.on("readable",function(){if(D){let n=D;D=null,n()}}),y.on("end",function(){A.push(null)}),A._read=function(){for(;;){let n=y.read();if(n===null){D=A._read;return}if(!A.push(n))return}}),A._destroy=function(n,i){!n&&k!==null&&(n=new I),D=null,N=null,j=null,k===null?i(n):(k=i,U(y,n))},A}}),C6=G0((l,g)=>{var{ArrayPrototypePop:E,Promise:M}=W5(),{isIterable:U,isNodeStream:S}=A5(),{pipelineImpl:G}=D9(),{finished:W}=v5();function I(...V){return new M((z,F)=>{let O,N,j=V[V.length-1];if(j&&typeof j=="object"&&!S(j)&&!U(j)){let D=E(V);O=D.signal,N=D.end}G(V,(D,k)=>{D?F(D):z(k)},{signal:O,end:N})})}g.exports={finished:W,pipeline:I}}),D7=G0((l,g)=>{var{Buffer:E}=j5(),{ObjectDefineProperty:M,ObjectKeys:U,ReflectApply:S}=W5(),{promisify:{custom:G}}=N5(),{streamReturningOperators:W,promiseReturningOperators:I}=z7(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:V}}=z5(),z=T7(),{pipeline:F}=D9(),{destroyer:O}=b5(),N=v5(),j=C6(),D=A5(),k=g.exports=O9().Stream;k.isDisturbed=D.isDisturbed,k.isErrored=D.isErrored,k.isReadable=D.isReadable,k.Readable=e5();for(let v of U(W)){let y=function(...c){if(new.target)throw V();return k.Readable.from(S(p,this,c))};A=y;let p=W[v];M(y,"name",{__proto__:null,value:p.name}),M(y,"length",{__proto__:null,value:p.length}),M(k.Readable.prototype,v,{__proto__:null,value:y,enumerable:!1,configurable:!0,writable:!0})}var A;for(let v of U(I)){let y=function(...c){if(new.target)throw V();return S(p,this,c)};A=y;let p=I[v];M(y,"name",{__proto__:null,value:p.name}),M(y,"length",{__proto__:null,value:p.length}),M(k.Readable.prototype,v,{__proto__:null,value:y,enumerable:!1,configurable:!0,writable:!0})}var A;k.Writable=t9(),k.Duplex=L5(),k.Transform=e9(),k.PassThrough=K6(),k.pipeline=F;var{addAbortSignal:x}=V9();k.addAbortSignal=x,k.finished=N,k.destroy=O,k.compose=z,M(k,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return j}}),M(F,G,{__proto__:null,enumerable:!0,get(){return j.pipeline}}),M(N,G,{__proto__:null,enumerable:!0,get(){return j.finished}}),k.Stream=k,k._isUint8Array=function(v){return v instanceof Uint8Array},k._uint8ArrayToBuffer=function(v){return E.from(v.buffer,v.byteOffset,v.byteLength)}}),p9=G0((l,g)=>{var E=D7(),M=C6(),U=E.Readable.destroy;g.exports=E.Readable,g.exports._uint8ArrayToBuffer=E._uint8ArrayToBuffer,g.exports._isUint8Array=E._isUint8Array,g.exports.isDisturbed=E.isDisturbed,g.exports.isErrored=E.isErrored,g.exports.isReadable=E.isReadable,g.exports.Readable=E.Readable,g.exports.Writable=E.Writable,g.exports.Duplex=E.Duplex,g.exports.Transform=E.Transform,g.exports.PassThrough=E.PassThrough,g.exports.addAbortSignal=E.addAbortSignal,g.exports.finished=E.finished,g.exports.destroy=E.destroy,g.exports.destroy=U,g.exports.pipeline=E.pipeline,g.exports.compose=E.compose,Object.defineProperty(E,"promises",{configurable:!0,enumerable:!0,get(){return M}}),g.exports.Stream=E.Stream,g.exports.default=g.exports}),N9={};r5(N9,{default:()=>X6});var X6,N7=J9(()=>{P9(N9,E5(p9())),X6=E5(p9())}),R5=G0((l,g)=>{var E=d0().Buffer,M=(N7(),O5(N9)).Transform,U=Z9().StringDecoder,S=p0();function G(W){M.call(this),this.hashMode=typeof W=="string",this.hashMode?this[W]=this._finalOrDigest:this.final=this._finalOrDigest,this._final&&(this.__final=this._final,this._final=null),this._decoder=null,this._encoding=null}S(G,M),G.prototype.update=function(W,I,V){typeof W=="string"&&(W=E.from(W,I));var z=this._update(W);return this.hashMode?this:(V&&(z=this._toString(z,V)),z)},G.prototype.setAutoPadding=function(){},G.prototype.getAuthTag=function(){throw new Error("trying to get auth tag in unsupported state")},G.prototype.setAuthTag=function(){throw new Error("trying to set auth tag in unsupported state")},G.prototype.setAAD=function(){throw new Error("trying to set aad in unsupported state")},G.prototype._transform=function(W,I,V){var z;try{this.hashMode?this._update(W):this.push(this._update(W))}catch(F){z=F}finally{V(z)}},G.prototype._flush=function(W){var I;try{this.push(this.__final())}catch(V){I=V}W(I)},G.prototype._finalOrDigest=function(W){var I=this.__final()||E.alloc(0);return W&&(I=this._toString(I,W,!0)),I},G.prototype._toString=function(W,I,V){if(this._decoder||(this._decoder=new U(I),this._encoding=I),this._encoding!==I)throw new Error("can't switch encodings");var z=this._decoder.write(W);return V&&(z+=this._decoder.end()),z},g.exports=G}),h5=G0((l,g)=>{var E=p0(),M=U9(),U=W9(),S=j9(),G=R5();function W(I){G.call(this,"digest"),this._hash=I}E(W,G),W.prototype._update=function(I){this._hash.update(I)},W.prototype._final=function(){return this._hash.digest()},g.exports=function(I){return I=I.toLowerCase(),I==="md5"?new M:I==="rmd160"||I==="ripemd160"?new U:new W(S(I))}}),L7=G0((l,g)=>{var E=p0(),M=d0().Buffer,U=R5(),S=M.alloc(128),G=64;function W(I,V){U.call(this,"digest"),typeof V=="string"&&(V=M.from(V)),this._alg=I,this._key=V,V.length>G?V=I(V):V.length<G&&(V=M.concat([V,S],G));for(var z=this._ipad=M.allocUnsafe(G),F=this._opad=M.allocUnsafe(G),O=0;O<G;O++)z[O]=V[O]^54,F[O]=V[O]^92;this._hash=[z]}E(W,U),W.prototype._update=function(I){this._hash.push(I)},W.prototype._final=function(){var I=this._alg(M.concat(this._hash));return this._alg(M.concat([this._opad,I]))},g.exports=W}),H6=G0((l,g)=>{var E=U9();g.exports=function(M){return new E().update(M).digest()}}),Y6=G0((l,g)=>{var E=p0(),M=L7(),U=R5(),S=d0().Buffer,G=H6(),W=W9(),I=j9(),V=S.alloc(128);function z(F,O){U.call(this,"digest"),typeof O=="string"&&(O=S.from(O));var N=F==="sha512"||F==="sha384"?128:64;if(this._alg=F,this._key=O,O.length>N){var j=F==="rmd160"?new W:I(F);O=j.update(O).digest()}else O.length<N&&(O=S.concat([O,V],N));for(var D=this._ipad=S.allocUnsafe(N),k=this._opad=S.allocUnsafe(N),A=0;A<N;A++)D[A]=O[A]^54,k[A]=O[A]^92;this._hash=F==="rmd160"?new W:I(F),this._hash.update(D)}E(z,U),z.prototype._update=function(F){this._hash.update(F)},z.prototype._final=function(){var F=this._hash.digest(),O=this._alg==="rmd160"?new W:I(this._alg);return O.update(this._opad).update(F).digest()},g.exports=function(F,O){return F=F.toLowerCase(),F==="rmd160"||F==="ripemd160"?new z("rmd160",O):F==="md5"?new M(G,O):new z(F,O)}}),Q6=G0((l,g)=>{g.exports={sha224WithRSAEncryption:{sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption:{sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption:{sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption:{sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:{sign:"ecdsa",hash:"sha256",id:""},sha224:{sign:"ecdsa",hash:"sha224",id:""},sha384:{sign:"ecdsa",hash:"sha384",id:""},sha512:{sign:"ecdsa",hash:"sha512",id:""},"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA:{sign:"dsa",hash:"sha1",id:""},"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA:{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption:{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}}}),I7=G0((l,g)=>{g.exports=Q6()}),$6=G0((l,g)=>{var E=Math.pow(2,30)-1;g.exports=function(M,U){if(typeof M!="number")throw new TypeError("Iterations not a number");if(M<0)throw new TypeError("Bad iterations");if(typeof U!="number")throw new TypeError("Key length not a number");if(U<0||U>E||U!==U)throw new TypeError("Bad key length")}}),G6=G0((l,g)=>{var E;global.process&&global.process.browser?E="utf-8":global.process&&global.process.version?(M=parseInt(process.version.split(".")[0].slice(1),10),E=M>=6?"utf-8":"binary"):E="utf-8";var M;g.exports=E}),J6=G0((l,g)=>{var E=d0().Buffer;g.exports=function(M,U,S){if(E.isBuffer(M))return M;if(typeof M=="string")return E.from(M,U);if(ArrayBuffer.isView(M))return E.from(M.buffer);throw new TypeError(S+" must be a string, a Buffer, a typed array or a DataView")}}),P6=G0((l,g)=>{var E=H6(),M=W9(),U=j9(),S=d0().Buffer,G=$6(),W=G6(),I=J6(),V=S.alloc(128),z={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20};function F(j,D,k){var A=O(j),x=j==="sha512"||j==="sha384"?128:64;D.length>x?D=A(D):D.length<x&&(D=S.concat([D,V],x));for(var v=S.allocUnsafe(x+z[j]),y=S.allocUnsafe(x+z[j]),p=0;p<x;p++)v[p]=D[p]^54,y[p]=D[p]^92;var c=S.allocUnsafe(x+k+4);v.copy(c,0,0,x),this.ipad1=c,this.ipad2=v,this.opad=y,this.alg=j,this.blocksize=x,this.hash=A,this.size=z[j]}F.prototype.run=function(j,D){j.copy(D,this.blocksize);var k=this.hash(D);return k.copy(this.opad,this.blocksize),this.hash(this.opad)};function O(j){function D(A){return U(j).update(A).digest()}function k(A){return new M().update(A).digest()}return j==="rmd160"||j==="ripemd160"?k:j==="md5"?E:D}function N(j,D,k,A,x){G(k,A),j=I(j,W,"Password"),D=I(D,W,"Salt"),x=x||"sha1";var v=new F(x,j,D.length),y=S.allocUnsafe(A),p=S.allocUnsafe(D.length+4);D.copy(p,0,0,D.length);for(var c=0,n=z[x],i=Math.ceil(A/n),H0=1;H0<=i;H0++){p.writeUInt32BE(H0,D.length);for(var a=v.run(p,v.ipad1),P0=a,K=1;K<k;K++){P0=v.run(P0,v.ipad2);for(var X=0;X<n;X++)a[X]^=P0[X]}a.copy(y,c),c+=n}return y}g.exports=N}),k7=G0((l,g)=>{var E=d0().Buffer,M=$6(),U=G6(),S=P6(),G=J6(),W,I=global.crypto&&global.crypto.subtle,V={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},z=[];function F(k){if(global.process&&!global.process.browser||!I||!I.importKey||!I.deriveBits)return Promise.resolve(!1);if(z[k]!==void 0)return z[k];W=W||E.alloc(8);var A=j(W,W,10,128,k).then(function(){return!0}).catch(function(){return!1});return z[k]=A,A}var O;function N(){return O||(global.process&&global.process.nextTick?O=global.process.nextTick:global.queueMicrotask?O=global.queueMicrotask:global.setImmediate?O=global.setImmediate:O=global.setTimeout,O)}function j(k,A,x,v,y){return I.importKey("raw",k,{name:"PBKDF2"},!1,["deriveBits"]).then(function(p){return I.deriveBits({name:"PBKDF2",salt:A,iterations:x,hash:{name:y}},p,v<<3)}).then(function(p){return E.from(p)})}function D(k,A){k.then(function(x){N()(function(){A(null,x)})},function(x){N()(function(){A(x)})})}g.exports=function(k,A,x,v,y,p){typeof y=="function"&&(p=y,y=void 0),y=y||"sha1";var c=V[y.toLowerCase()];if(!c||typeof global.Promise!="function"){N()(function(){var n;try{n=S(k,A,x,v,y)}catch(i){return p(i)}p(null,n)});return}if(M(x,v),k=G(k,U,"Password"),A=G(A,U,"Salt"),typeof p!="function")throw new Error("No callback provided to pbkdf2");D(F(c).then(function(n){return n?j(k,A,x,v,c):S(k,A,x,v,y)}),p)}}),Z6=G0((l)=>{l.pbkdf2=k7(),l.pbkdf2Sync=P6()}),F6=G0((l)=>{l.readUInt32BE=function(U,S){var G=U[0+S]<<24|U[1+S]<<16|U[2+S]<<8|U[3+S];return G>>>0},l.writeUInt32BE=function(U,S,G){U[0+G]=S>>>24,U[1+G]=S>>>16&255,U[2+G]=S>>>8&255,U[3+G]=S&255},l.ip=function(U,S,G,W){for(var I=0,V=0,z=6;z>=0;z-=2){for(var F=0;F<=24;F+=8)I<<=1,I|=S>>>F+z&1;for(var F=0;F<=24;F+=8)I<<=1,I|=U>>>F+z&1}for(var z=6;z>=0;z-=2){for(var F=1;F<=25;F+=8)V<<=1,V|=S>>>F+z&1;for(var F=1;F<=25;F+=8)V<<=1,V|=U>>>F+z&1}G[W+0]=I>>>0,G[W+1]=V>>>0},l.rip=function(U,S,G,W){for(var I=0,V=0,z=0;z<4;z++)for(var F=24;F>=0;F-=8)I<<=1,I|=S>>>F+z&1,I<<=1,I|=U>>>F+z&1;for(var z=4;z<8;z++)for(var F=24;F>=0;F-=8)V<<=1,V|=S>>>F+z&1,V<<=1,V|=U>>>F+z&1;G[W+0]=I>>>0,G[W+1]=V>>>0},l.pc1=function(U,S,G,W){for(var I=0,V=0,z=7;z>=5;z--){for(var F=0;F<=24;F+=8)I<<=1,I|=S>>F+z&1;for(var F=0;F<=24;F+=8)I<<=1,I|=U>>F+z&1}for(var F=0;F<=24;F+=8)I<<=1,I|=S>>F+z&1;for(var z=1;z<=3;z++){for(var F=0;F<=24;F+=8)V<<=1,V|=S>>F+z&1;for(var F=0;F<=24;F+=8)V<<=1,V|=U>>F+z&1}for(var F=0;F<=24;F+=8)V<<=1,V|=U>>F+z&1;G[W+0]=I>>>0,G[W+1]=V>>>0},l.r28shl=function(U,S){return U<<S&268435455|U>>>28-S};var g=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];l.pc2=function(U,S,G,W){for(var I=0,V=0,z=g.length>>>1,F=0;F<z;F++)I<<=1,I|=U>>>g[F]&1;for(var F=z;F<g.length;F++)V<<=1,V|=S>>>g[F]&1;G[W+0]=I>>>0,G[W+1]=V>>>0},l.expand=function(U,S,G){var W=0,I=0;W=(U&1)<<5|U>>>27;for(var V=23;V>=15;V-=4)W<<=6,W|=U>>>V&63;for(var V=11;V>=3;V-=4)I|=U>>>V&63,I<<=6;I|=(U&31)<<1|U>>>31,S[G+0]=W>>>0,S[G+1]=I>>>0};var E=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];l.substitute=function(U,S){for(var G=0,W=0;W<4;W++){var I=U>>>18-W*6&63,V=E[W*64+I];G<<=4,G|=V}for(var W=0;W<4;W++){var I=S>>>18-W*6&63,V=E[256+W*64+I];G<<=4,G|=V}return G>>>0};var M=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];l.permute=function(U){for(var S=0,G=0;G<M.length;G++)S<<=1,S|=U>>>M[G]&1;return S>>>0},l.padSplit=function(U,S,G){for(var W=U.toString(2);W.length<S;)W="0"+W;for(var I=[],V=0;V<S;V+=G)I.push(W.slice(V,V+G));return I.join(" ")}}),V5=G0((l,g)=>{g.exports=E;function E(M,U){if(!M)throw new Error(U||"Assertion failed")}E.equal=function(M,U,S){if(M!=U)throw new Error(S||"Assertion failed: "+M+" != "+U)}}),L9=G0((l,g)=>{var E=V5();function M(U){this.options=U,this.type=this.options.type,this.blockSize=8,this._init(),this.buffer=new Array(this.blockSize),this.bufferOff=0}g.exports=M,M.prototype._init=function(){},M.prototype.update=function(U){return U.length===0?[]:this.type==="decrypt"?this._updateDecrypt(U):this._updateEncrypt(U)},M.prototype._buffer=function(U,S){for(var G=Math.min(this.buffer.length-this.bufferOff,U.length-S),W=0;W<G;W++)this.buffer[this.bufferOff+W]=U[S+W];return this.bufferOff+=G,G},M.prototype._flushBuffer=function(U,S){return this._update(this.buffer,0,U,S),this.bufferOff=0,this.blockSize},M.prototype._updateEncrypt=function(U){var S=0,G=0,W=(this.bufferOff+U.length)/this.blockSize|0,I=new Array(W*this.blockSize);this.bufferOff!==0&&(S+=this._buffer(U,S),this.bufferOff===this.buffer.length&&(G+=this._flushBuffer(I,G)));for(var V=U.length-(U.length-S)%this.blockSize;S<V;S+=this.blockSize)this._update(U,S,I,G),G+=this.blockSize;for(;S<U.length;S++,this.bufferOff++)this.buffer[this.bufferOff]=U[S];return I},M.prototype._updateDecrypt=function(U){for(var S=0,G=0,W=Math.ceil((this.bufferOff+U.length)/this.blockSize)-1,I=new Array(W*this.blockSize);W>0;W--)S+=this._buffer(U,S),G+=this._flushBuffer(I,G);return S+=this._buffer(U,S),I},M.prototype.final=function(U){var S;U&&(S=this.update(U));var G;return this.type==="encrypt"?G=this._finalEncrypt():G=this._finalDecrypt(),S?S.concat(G):G},M.prototype._pad=function(U,S){if(S===0)return!1;for(;S<U.length;)U[S++]=0;return!0},M.prototype._finalEncrypt=function(){if(!this._pad(this.buffer,this.bufferOff))return[];var U=new Array(this.blockSize);return this._update(this.buffer,0,U,0),U},M.prototype._unpad=function(U){return U},M.prototype._finalDecrypt=function(){E.equal(this.bufferOff,this.blockSize,"Not enough data to decrypt");var U=new Array(this.blockSize);return this._flushBuffer(U,0),this._unpad(U)}}),U6=G0((l,g)=>{var E=V5(),M=p0(),U=F6(),S=L9();function G(){this.tmp=new Array(2),this.keys=null}function W(V){S.call(this,V);var z=new G;this._desState=z,this.deriveKeys(z,V.key)}M(W,S),g.exports=W,W.create=function(V){return new W(V)};var I=[1,1,2,2,2,2,2,2,1,2,2,2,2,2,2,1];W.prototype.deriveKeys=function(V,z){V.keys=new Array(32),E.equal(z.length,this.blockSize,"Invalid key length");var F=U.readUInt32BE(z,0),O=U.readUInt32BE(z,4);U.pc1(F,O,V.tmp,0),F=V.tmp[0],O=V.tmp[1];for(var N=0;N<V.keys.length;N+=2){var j=I[N>>>1];F=U.r28shl(F,j),O=U.r28shl(O,j),U.pc2(F,O,V.keys,N)}},W.prototype._update=function(V,z,F,O){var N=this._desState,j=U.readUInt32BE(V,z),D=U.readUInt32BE(V,z+4);U.ip(j,D,N.tmp,0),j=N.tmp[0],D=N.tmp[1],this.type==="encrypt"?this._encrypt(N,j,D,N.tmp,0):this._decrypt(N,j,D,N.tmp,0),j=N.tmp[0],D=N.tmp[1],U.writeUInt32BE(F,j,O),U.writeUInt32BE(F,D,O+4)},W.prototype._pad=function(V,z){for(var F=V.length-z,O=z;O<V.length;O++)V[O]=F;return!0},W.prototype._unpad=function(V){for(var z=V[V.length-1],F=V.length-z;F<V.length;F++)E.equal(V[F],z);return V.slice(0,V.length-z)},W.prototype._encrypt=function(V,z,F,O,N){for(var j=z,D=F,k=0;k<V.keys.length;k+=2){var A=V.keys[k],x=V.keys[k+1];U.expand(D,V.tmp,0),A^=V.tmp[0],x^=V.tmp[1];var v=U.substitute(A,x),y=U.permute(v),p=D;D=(j^y)>>>0,j=p}U.rip(D,j,O,N)},W.prototype._decrypt=function(V,z,F,O,N){for(var j=F,D=z,k=V.keys.length-2;k>=0;k-=2){var A=V.keys[k],x=V.keys[k+1];U.expand(j,V.tmp,0),A^=V.tmp[0],x^=V.tmp[1];var v=U.substitute(A,x),y=U.permute(v),p=j;j=(D^y)>>>0,D=p}U.rip(j,D,O,N)}}),q7=G0((l)=>{var g=V5(),E=p0(),M={};function U(G){g.equal(G.length,8,"Invalid IV length"),this.iv=new Array(8);for(var W=0;W<this.iv.length;W++)this.iv[W]=G[W]}function S(G){function W(F){G.call(this,F),this._cbcInit()}E(W,G);for(var I=Object.keys(M),V=0;V<I.length;V++){var z=I[V];W.prototype[z]=M[z]}return W.create=function(F){return new W(F)},W}l.instantiate=S,M._cbcInit=function(){var G=new U(this.options.iv);this._cbcState=G},M._update=function(G,W,I,V){var z=this._cbcState,F=this.constructor.super_.prototype,O=z.iv;if(this.type==="encrypt"){for(var N=0;N<this.blockSize;N++)O[N]^=G[W+N];F._update.call(this,O,0,I,V);for(var N=0;N<this.blockSize;N++)O[N]=I[V+N]}else{F._update.call(this,G,W,I,V);for(var N=0;N<this.blockSize;N++)I[V+N]^=O[N];for(var N=0;N<this.blockSize;N++)O[N]=G[W+N]}}}),B7=G0((l,g)=>{var E=V5(),M=p0(),U=L9(),S=U6();function G(I,V){E.equal(V.length,24,"Invalid key length");var z=V.slice(0,8),F=V.slice(8,16),O=V.slice(16,24);I==="encrypt"?this.ciphers=[S.create({type:"encrypt",key:z}),S.create({type:"decrypt",key:F}),S.create({type:"encrypt",key:O})]:this.ciphers=[S.create({type:"decrypt",key:O}),S.create({type:"encrypt",key:F}),S.create({type:"decrypt",key:z})]}function W(I){U.call(this,I);var V=new G(this.type,this.options.key);this._edeState=V}M(W,U),g.exports=W,W.create=function(I){return new W(I)},W.prototype._update=function(I,V,z,F){var O=this._edeState;O.ciphers[0]._update(I,V,z,F),O.ciphers[1]._update(z,F,z,F),O.ciphers[2]._update(z,F,z,F)},W.prototype._pad=S.prototype._pad,W.prototype._unpad=S.prototype._unpad}),R7=G0((l)=>{l.utils=F6(),l.Cipher=L9(),l.DES=U6(),l.CBC=q7(),l.EDE=B7()}),E7=G0((l,g)=>{var E=R5(),M=R7(),U=p0(),S=d0().Buffer,G={"des-ede3-cbc":M.CBC.instantiate(M.EDE),"des-ede3":M.EDE,"des-ede-cbc":M.CBC.instantiate(M.EDE),"des-ede":M.EDE,"des-cbc":M.CBC.instantiate(M.DES),"des-ecb":M.DES};G.des=G["des-cbc"],G.des3=G["des-ede3-cbc"],g.exports=W,U(W,E);function W(I){E.call(this);var V=I.mode.toLowerCase(),z=G[V],F;I.decrypt?F="decrypt":F="encrypt";var O=I.key;S.isBuffer(O)||(O=S.from(O)),(V==="des-ede"||V==="des-ede-cbc")&&(O=S.concat([O,O.slice(0,8)]));var N=I.iv;S.isBuffer(N)||(N=S.from(N)),this._des=z.create({key:O,iv:N,type:F})}W.prototype._update=function(I){return S.from(this._des.update(I))},W.prototype._final=function(){return S.from(this._des.final())}}),S7=G0((l)=>{l.encrypt=function(g,E){return g._cipher.encryptBlock(E)},l.decrypt=function(g,E){return g._cipher.decryptBlock(E)}}),u5=G0((l,g)=>{g.exports=function(E,M){for(var U=Math.min(E.length,M.length),S=new Buffer(U),G=0;G<U;++G)S[G]=E[G]^M[G];return S}}),x7=G0((l)=>{var g=u5();l.encrypt=function(E,M){var U=g(M,E._prev);return E._prev=E._cipher.encryptBlock(U),E._prev},l.decrypt=function(E,M){var U=E._prev;E._prev=M;var S=E._cipher.decryptBlock(M);return g(S,U)}}),A7=G0((l)=>{var g=d0().Buffer,E=u5();function M(U,S,G){var W=S.length,I=E(S,U._cache);return U._cache=U._cache.slice(W),U._prev=g.concat([U._prev,G?S:I]),I}l.encrypt=function(U,S,G){for(var W=g.allocUnsafe(0),I;S.length;)if(U._cache.length===0&&(U._cache=U._cipher.encryptBlock(U._prev),U._prev=g.allocUnsafe(0)),U._cache.length<=S.length)I=U._cache.length,W=g.concat([W,M(U,S.slice(0,I),G)]),S=S.slice(I);else{W=g.concat([W,M(U,S,G)]);break}return W}}),v7=G0((l)=>{var g=d0().Buffer;function E(M,U,S){var G=M._cipher.encryptBlock(M._prev),W=G[0]^U;return M._prev=g.concat([M._prev.slice(1),g.from([S?U:W])]),W}l.encrypt=function(M,U,S){for(var G=U.length,W=g.allocUnsafe(G),I=-1;++I<G;)W[I]=E(M,U[I],S);return W}}),M7=G0((l)=>{var g=d0().Buffer;function E(U,S,G){for(var W,I=-1,V=8,z=0,F,O;++I<V;)W=U._cipher.encryptBlock(U._prev),F=S&1<<7-I?128:0,O=W[0]^F,z+=(O&128)>>I%8,U._prev=M(U._prev,G?F:O);return z}function M(U,S){var G=U.length,W=-1,I=g.allocUnsafe(U.length);for(U=g.concat([U,g.from([S])]);++W<G;)I[W]=U[W]<<1|U[W+1]>>7;return I}l.encrypt=function(U,S,G){for(var W=S.length,I=g.allocUnsafe(W),V=-1;++V<W;)I[V]=E(U,S[V],G);return I}}),_7=G0((l)=>{var g=u5();function E(M){return M._prev=M._cipher.encryptBlock(M._prev),M._prev}l.encrypt=function(M,U){for(;M._cache.length<U.length;)M._cache=Buffer.concat([M._cache,E(M)]);var S=M._cache.slice(0,U.length);return M._cache=M._cache.slice(U.length),g(U,S)}}),W6=G0((l,g)=>{function E(M){for(var U=M.length,S;U--;)if(S=M.readUInt8(U),S===255)M.writeUInt8(0,U);else{S++,M.writeUInt8(S,U);break}}g.exports=E}),b9=G0((l)=>{var g=u5(),E=d0().Buffer,M=W6();function U(G){var W=G._cipher.encryptBlockRaw(G._prev);return M(G._prev),W}var S=16;l.encrypt=function(G,W){var I=Math.ceil(W.length/S),V=G._cache.length;G._cache=E.concat([G._cache,E.allocUnsafe(I*S)]);for(var z=0;z<I;z++){var F=U(G),O=V+z*S;G._cache.writeUInt32BE(F[0],O+0),G._cache.writeUInt32BE(F[1],O+4),G._cache.writeUInt32BE(F[2],O+8),G._cache.writeUInt32BE(F[3],O+12)}var N=G._cache.slice(0,W.length);return G._cache=G._cache.slice(W.length),g(W,N)}}),j6=G0((l,g)=>{g.exports={"aes-128-ecb":{cipher:"AES",key:128,iv:0,mode:"ECB",type:"block"},"aes-192-ecb":{cipher:"AES",key:192,iv:0,mode:"ECB",type:"block"},"aes-256-ecb":{cipher:"AES",key:256,iv:0,mode:"ECB",type:"block"},"aes-128-cbc":{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},"aes-192-cbc":{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},"aes-256-cbc":{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},aes128:{cipher:"AES",key:128,iv:16,mode:"CBC",type:"block"},aes192:{cipher:"AES",key:192,iv:16,mode:"CBC",type:"block"},aes256:{cipher:"AES",key:256,iv:16,mode:"CBC",type:"block"},"aes-128-cfb":{cipher:"AES",key:128,iv:16,mode:"CFB",type:"stream"},"aes-192-cfb":{cipher:"AES",key:192,iv:16,mode:"CFB",type:"stream"},"aes-256-cfb":{cipher:"AES",key:256,iv:16,mode:"CFB",type:"stream"},"aes-128-cfb8":{cipher:"AES",key:128,iv:16,mode:"CFB8",type:"stream"},"aes-192-cfb8":{cipher:"AES",key:192,iv:16,mode:"CFB8",type:"stream"},"aes-256-cfb8":{cipher:"AES",key:256,iv:16,mode:"CFB8",type:"stream"},"aes-128-cfb1":{cipher:"AES",key:128,iv:16,mode:"CFB1",type:"stream"},"aes-192-cfb1":{cipher:"AES",key:192,iv:16,mode:"CFB1",type:"stream"},"aes-256-cfb1":{cipher:"AES",key:256,iv:16,mode:"CFB1",type:"stream"},"aes-128-ofb":{cipher:"AES",key:128,iv:16,mode:"OFB",type:"stream"},"aes-192-ofb":{cipher:"AES",key:192,iv:16,mode:"OFB",type:"stream"},"aes-256-ofb":{cipher:"AES",key:256,iv:16,mode:"OFB",type:"stream"},"aes-128-ctr":{cipher:"AES",key:128,iv:16,mode:"CTR",type:"stream"},"aes-192-ctr":{cipher:"AES",key:192,iv:16,mode:"CTR",type:"stream"},"aes-256-ctr":{cipher:"AES",key:256,iv:16,mode:"CTR",type:"stream"},"aes-128-gcm":{cipher:"AES",key:128,iv:12,mode:"GCM",type:"auth"},"aes-192-gcm":{cipher:"AES",key:192,iv:12,mode:"GCM",type:"auth"},"aes-256-gcm":{cipher:"AES",key:256,iv:12,mode:"GCM",type:"auth"}}}),I9=G0((l,g)=>{var E={ECB:S7(),CBC:x7(),CFB:A7(),CFB8:v7(),CFB1:M7(),OFB:_7(),CTR:b9(),GCM:b9()},M=j6();for(U in M)M[U].module=E[M[U].mode];var U;g.exports=M}),K9=G0((l,g)=>{var E=d0().Buffer;function M(V){E.isBuffer(V)||(V=E.from(V));for(var z=V.length/4|0,F=new Array(z),O=0;O<z;O++)F[O]=V.readUInt32BE(O*4);return F}function U(V){for(var z=0;z<V.length;V++)V[z]=0}function S(V,z,F,O,N){for(var j=F[0],D=F[1],k=F[2],A=F[3],x=V[0]^z[0],v=V[1]^z[1],y=V[2]^z[2],p=V[3]^z[3],c,n,i,H0,a=4,P0=1;P0<N;P0++)c=j[x>>>24]^D[v>>>16&255]^k[y>>>8&255]^A[p&255]^z[a++],n=j[v>>>24]^D[y>>>16&255]^k[p>>>8&255]^A[x&255]^z[a++],i=j[y>>>24]^D[p>>>16&255]^k[x>>>8&255]^A[v&255]^z[a++],H0=j[p>>>24]^D[x>>>16&255]^k[v>>>8&255]^A[y&255]^z[a++],x=c,v=n,y=i,p=H0;return c=(O[x>>>24]<<24|O[v>>>16&255]<<16|O[y>>>8&255]<<8|O[p&255])^z[a++],n=(O[v>>>24]<<24|O[y>>>16&255]<<16|O[p>>>8&255]<<8|O[x&255])^z[a++],i=(O[y>>>24]<<24|O[p>>>16&255]<<16|O[x>>>8&255]<<8|O[v&255])^z[a++],H0=(O[p>>>24]<<24|O[x>>>16&255]<<16|O[v>>>8&255]<<8|O[y&255])^z[a++],c=c>>>0,n=n>>>0,i=i>>>0,H0=H0>>>0,[c,n,i,H0]}var G=[0,1,2,4,8,16,32,64,128,27,54],W=function(){for(var V=new Array(256),z=0;z<256;z++)z<128?V[z]=z<<1:V[z]=z<<1^283;for(var F=[],O=[],N=[[],[],[],[]],j=[[],[],[],[]],D=0,k=0,A=0;A<256;++A){var x=k^k<<1^k<<2^k<<3^k<<4;x=x>>>8^x&255^99,F[D]=x,O[x]=D;var v=V[D],y=V[v],p=V[y],c=V[x]*257^x*16843008;N[0][D]=c<<24|c>>>8,N[1][D]=c<<16|c>>>16,N[2][D]=c<<8|c>>>24,N[3][D]=c,c=p*16843009^y*65537^v*257^D*16843008,j[0][x]=c<<24|c>>>8,j[1][x]=c<<16|c>>>16,j[2][x]=c<<8|c>>>24,j[3][x]=c,D===0?D=k=1:(D=v^V[V[V[p^v]]],k^=V[V[k]])}return{SBOX:F,INV_SBOX:O,SUB_MIX:N,INV_SUB_MIX:j}}();function I(V){this._key=M(V),this._reset()}I.blockSize=16,I.keySize=32,I.prototype.blockSize=I.blockSize,I.prototype.keySize=I.keySize,I.prototype._reset=function(){for(var V=this._key,z=V.length,F=z+6,O=(F+1)*4,N=[],j=0;j<z;j++)N[j]=V[j];for(j=z;j<O;j++){var D=N[j-1];j%z===0?(D=D<<8|D>>>24,D=W.SBOX[D>>>24]<<24|W.SBOX[D>>>16&255]<<16|W.SBOX[D>>>8&255]<<8|W.SBOX[D&255],D^=G[j/z|0]<<24):z>6&&j%z===4&&(D=W.SBOX[D>>>24]<<24|W.SBOX[D>>>16&255]<<16|W.SBOX[D>>>8&255]<<8|W.SBOX[D&255]),N[j]=N[j-z]^D}for(var k=[],A=0;A<O;A++){var x=O-A,v=N[x-(A%4?0:4)];A<4||x<=4?k[A]=v:k[A]=W.INV_SUB_MIX[0][W.SBOX[v>>>24]]^W.INV_SUB_MIX[1][W.SBOX[v>>>16&255]]^W.INV_SUB_MIX[2][W.SBOX[v>>>8&255]]^W.INV_SUB_MIX[3][W.SBOX[v&255]]}this._nRounds=F,this._keySchedule=N,this._invKeySchedule=k},I.prototype.encryptBlockRaw=function(V){return V=M(V),S(V,this._keySchedule,W.SUB_MIX,W.SBOX,this._nRounds)},I.prototype.encryptBlock=function(V){var z=this.encryptBlockRaw(V),F=E.allocUnsafe(16);return F.writeUInt32BE(z[0],0),F.writeUInt32BE(z[1],4),F.writeUInt32BE(z[2],8),F.writeUInt32BE(z[3],12),F},I.prototype.decryptBlock=function(V){V=M(V);var z=V[1];V[1]=V[3],V[3]=z;var F=S(V,this._invKeySchedule,W.INV_SUB_MIX,W.INV_SBOX,this._nRounds),O=E.allocUnsafe(16);return O.writeUInt32BE(F[0],0),O.writeUInt32BE(F[3],4),O.writeUInt32BE(F[2],8),O.writeUInt32BE(F[1],12),O},I.prototype.scrub=function(){U(this._keySchedule),U(this._invKeySchedule),U(this._key)},g.exports.AES=I}),w7=G0((l,g)=>{var E=d0().Buffer,M=E.alloc(16,0);function U(W){return[W.readUInt32BE(0),W.readUInt32BE(4),W.readUInt32BE(8),W.readUInt32BE(12)]}function S(W){var I=E.allocUnsafe(16);return I.writeUInt32BE(W[0]>>>0,0),I.writeUInt32BE(W[1]>>>0,4),I.writeUInt32BE(W[2]>>>0,8),I.writeUInt32BE(W[3]>>>0,12),I}function G(W){this.h=W,this.state=E.alloc(16,0),this.cache=E.allocUnsafe(0)}G.prototype.ghash=function(W){for(var I=-1;++I<W.length;)this.state[I]^=W[I];this._multiply()},G.prototype._multiply=function(){for(var W=U(this.h),I=[0,0,0,0],V,z,F,O=-1;++O<128;){for(z=(this.state[~~(O/8)]&1<<7-O%8)!==0,z&&(I[0]^=W[0],I[1]^=W[1],I[2]^=W[2],I[3]^=W[3]),F=(W[3]&1)!==0,V=3;V>0;V--)W[V]=W[V]>>>1|(W[V-1]&1)<<31;W[0]=W[0]>>>1,F&&(W[0]=W[0]^-520093696)}this.state=S(I)},G.prototype.update=function(W){this.cache=E.concat([this.cache,W]);for(var I;this.cache.length>=16;)I=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(I)},G.prototype.final=function(W,I){return this.cache.length&&this.ghash(E.concat([this.cache,M],16)),this.ghash(S([0,W,0,I])),this.state},g.exports=G}),z6=G0((l,g)=>{var E=K9(),M=d0().Buffer,U=R5(),S=p0(),G=w7(),W=u5(),I=W6();function V(O,N){var j=0;O.length!==N.length&&j++;for(var D=Math.min(O.length,N.length),k=0;k<D;++k)j+=O[k]^N[k];return j}function z(O,N,j){if(N.length===12)return O._finID=M.concat([N,M.from([0,0,0,1])]),M.concat([N,M.from([0,0,0,2])]);var D=new G(j),k=N.length,A=k%16;D.update(N),A&&(A=16-A,D.update(M.alloc(A,0))),D.update(M.alloc(8,0));var x=k*8,v=M.alloc(8);v.writeUIntBE(x,0,8),D.update(v),O._finID=D.state;var y=M.from(O._finID);return I(y),y}function F(O,N,j,D){U.call(this);var k=M.alloc(4,0);this._cipher=new E.AES(N);var A=this._cipher.encryptBlock(k);this._ghash=new G(A),j=z(this,j,A),this._prev=M.from(j),this._cache=M.allocUnsafe(0),this._secCache=M.allocUnsafe(0),this._decrypt=D,this._alen=0,this._len=0,this._mode=O,this._authTag=null,this._called=!1}S(F,U),F.prototype._update=function(O){if(!this._called&&this._alen){var N=16-this._alen%16;N<16&&(N=M.alloc(N,0),this._ghash.update(N))}this._called=!0;var j=this._mode.encrypt(this,O);return this._decrypt?this._ghash.update(O):this._ghash.update(j),this._len+=O.length,j},F.prototype._final=function(){if(this._decrypt&&!this._authTag)throw new Error("Unsupported state or unable to authenticate data");var O=W(this._ghash.final(this._alen*8,this._len*8),this._cipher.encryptBlock(this._finID));if(this._decrypt&&V(O,this._authTag))throw new Error("Unsupported state or unable to authenticate data");this._authTag=O,this._cipher.scrub()},F.prototype.getAuthTag=function(){if(this._decrypt||!M.isBuffer(this._authTag))throw new Error("Attempting to get auth tag in unsupported state");return this._authTag},F.prototype.setAuthTag=function(O){if(!this._decrypt)throw new Error("Attempting to set auth tag in unsupported state");this._authTag=O},F.prototype.setAAD=function(O){if(this._called)throw new Error("Attempting to set AAD in unsupported state");this._ghash.update(O),this._alen+=O.length},g.exports=F}),O6=G0((l,g)=>{var E=K9(),M=d0().Buffer,U=R5(),S=p0();function G(W,I,V,z){U.call(this),this._cipher=new E.AES(I),this._prev=M.from(V),this._cache=M.allocUnsafe(0),this._secCache=M.allocUnsafe(0),this._decrypt=z,this._mode=W}S(G,U),G.prototype._update=function(W){return this._mode.encrypt(this,W,this._decrypt)},G.prototype._final=function(){this._cipher.scrub()},g.exports=G}),C9=G0((l,g)=>{var E=d0().Buffer,M=U9();function U(S,G,W,I){if(E.isBuffer(S)||(S=E.from(S,"binary")),G&&(E.isBuffer(G)||(G=E.from(G,"binary")),G.length!==8))throw new RangeError("salt should be Buffer with 8 byte length");for(var V=W/8,z=E.alloc(V),F=E.alloc(I||0),O=E.alloc(0);V>0||I>0;){var N=new M;N.update(O),N.update(S),G&&N.update(G),O=N.digest();var j=0;if(V>0){var D=z.length-V;j=Math.min(V,O.length),O.copy(z,D,0,j),V-=j}if(j<O.length&&I>0){var k=F.length-I,A=Math.min(I,O.length-j);O.copy(F,k,j,j+A),I-=A}}return O.fill(0),{key:z,iv:F}}g.exports=U}),y7=G0((l)=>{var g=I9(),E=z6(),M=d0().Buffer,U=O6(),S=R5(),G=K9(),W=C9(),I=p0();function V(j,D,k){S.call(this),this._cache=new F,this._cipher=new G.AES(D),this._prev=M.from(k),this._mode=j,this._autopadding=!0}I(V,S),V.prototype._update=function(j){this._cache.add(j);for(var D,k,A=[];D=this._cache.get();)k=this._mode.encrypt(this,D),A.push(k);return M.concat(A)};var z=M.alloc(16,16);V.prototype._final=function(){var j=this._cache.flush();if(this._autopadding)return j=this._mode.encrypt(this,j),this._cipher.scrub(),j;if(!j.equals(z))throw this._cipher.scrub(),new Error("data not multiple of block length")},V.prototype.setAutoPadding=function(j){return this._autopadding=!!j,this};function F(){this.cache=M.allocUnsafe(0)}F.prototype.add=function(j){this.cache=M.concat([this.cache,j])},F.prototype.get=function(){if(this.cache.length>15){var j=this.cache.slice(0,16);return this.cache=this.cache.slice(16),j}return null},F.prototype.flush=function(){for(var j=16-this.cache.length,D=M.allocUnsafe(j),k=-1;++k<j;)D.writeUInt8(j,k);return M.concat([this.cache,D])};function O(j,D,k){var A=g[j.toLowerCase()];if(!A)throw new TypeError("invalid suite type");if(typeof D=="string"&&(D=M.from(D)),D.length!==A.key/8)throw new TypeError("invalid key length "+D.length);if(typeof k=="string"&&(k=M.from(k)),A.mode!=="GCM"&&k.length!==A.iv)throw new TypeError("invalid iv length "+k.length);return A.type==="stream"?new U(A.module,D,k):A.type==="auth"?new E(A.module,D,k):new V(A.module,D,k)}function N(j,D){var k=g[j.toLowerCase()];if(!k)throw new TypeError("invalid suite type");var A=W(D,!1,k.key,k.iv);return O(j,A.key,A.iv)}l.createCipheriv=O,l.createCipher=N}),g7=G0((l)=>{var g=z6(),E=d0().Buffer,M=I9(),U=O6(),S=R5(),G=K9(),W=C9(),I=p0();function V(j,D,k){S.call(this),this._cache=new z,this._last=void 0,this._cipher=new G.AES(D),this._prev=E.from(k),this._mode=j,this._autopadding=!0}I(V,S),V.prototype._update=function(j){this._cache.add(j);for(var D,k,A=[];D=this._cache.get(this._autopadding);)k=this._mode.decrypt(this,D),A.push(k);return E.concat(A)},V.prototype._final=function(){var j=this._cache.flush();if(this._autopadding)return F(this._mode.decrypt(this,j));if(j)throw new Error("data not multiple of block length")},V.prototype.setAutoPadding=function(j){return this._autopadding=!!j,this};function z(){this.cache=E.allocUnsafe(0)}z.prototype.add=function(j){this.cache=E.concat([this.cache,j])},z.prototype.get=function(j){var D;if(j){if(this.cache.length>16)return D=this.cache.slice(0,16),this.cache=this.cache.slice(16),D}else if(this.cache.length>=16)return D=this.cache.slice(0,16),this.cache=this.cache.slice(16),D;return null},z.prototype.flush=function(){if(this.cache.length)return this.cache};function F(j){var D=j[15];if(D<1||D>16)throw new Error("unable to decrypt data");for(var k=-1;++k<D;)if(j[k+(16-D)]!==D)throw new Error("unable to decrypt data");if(D!==16)return j.slice(0,16-D)}function O(j,D,k){var A=M[j.toLowerCase()];if(!A)throw new TypeError("invalid suite type");if(typeof k=="string"&&(k=E.from(k)),A.mode!=="GCM"&&k.length!==A.iv)throw new TypeError("invalid iv length "+k.length);if(typeof D=="string"&&(D=E.from(D)),D.length!==A.key/8)throw new TypeError("invalid key length "+D.length);return A.type==="stream"?new U(A.module,D,k,!0):A.type==="auth"?new g(A.module,D,k,!0):new V(A.module,D,k)}function N(j,D){var k=M[j.toLowerCase()];if(!k)throw new TypeError("invalid suite type");var A=W(D,!1,k.key,k.iv);return O(j,A.key,A.iv)}l.createDecipher=N,l.createDecipheriv=O}),k9=G0((l)=>{var g=y7(),E=g7(),M=j6();function U(){return Object.keys(M)}l.createCipher=l.Cipher=g.createCipher,l.createCipheriv=l.Cipheriv=g.createCipheriv,l.createDecipher=l.Decipher=E.createDecipher,l.createDecipheriv=l.Decipheriv=E.createDecipheriv,l.listCiphers=l.getCiphers=U}),m7=G0((l)=>{l["des-ecb"]={key:8,iv:0},l["des-cbc"]=l.des={key:8,iv:8},l["des-ede3-cbc"]=l.des3={key:24,iv:8},l["des-ede3"]={key:24,iv:0},l["des-ede-cbc"]={key:16,iv:8},l["des-ede"]={key:16,iv:0}}),p7=G0((l)=>{var g=E7(),E=k9(),M=I9(),U=m7(),S=C9();function G(F,O){F=F.toLowerCase();var N,j;if(M[F])N=M[F].key,j=M[F].iv;else if(U[F])N=U[F].key*8,j=U[F].iv;else throw new TypeError("invalid suite type");var D=S(O,!1,N,j);return I(F,D.key,D.iv)}function W(F,O){F=F.toLowerCase();var N,j;if(M[F])N=M[F].key,j=M[F].iv;else if(U[F])N=U[F].key*8,j=U[F].iv;else throw new TypeError("invalid suite type");var D=S(O,!1,N,j);return V(F,D.key,D.iv)}function I(F,O,N){if(F=F.toLowerCase(),M[F])return E.createCipheriv(F,O,N);if(U[F])return new g({key:O,iv:N,mode:F});throw new TypeError("invalid suite type")}function V(F,O,N){if(F=F.toLowerCase(),M[F])return E.createDecipheriv(F,O,N);if(U[F])return new g({key:O,iv:N,mode:F,decrypt:!0});throw new TypeError("invalid suite type")}function z(){return Object.keys(U).concat(E.getCiphers())}l.createCipher=l.Cipher=G,l.createCipheriv=l.Cipheriv=I,l.createDecipher=l.Decipher=W,l.createDecipheriv=l.Decipheriv=V,l.listCiphers=l.getCiphers=z}),M5=G0(()=>{}),V6=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),b7=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),c7=G0(()=>{}),q9=G0((l,g)=>{var E;g.exports=function(S){return E||(E=new M(null)),E.generate(S)};function M(S){this.rand=S}if(g.exports.Rand=M,M.prototype.generate=function(S){return this._rand(S)},M.prototype._rand=function(S){if(this.rand.getBytes)return this.rand.getBytes(S);for(var G=new Uint8Array(S),W=0;W<G.length;W++)G[W]=this.rand.getByte();return G},typeof self=="object")self.crypto&&self.crypto.getRandomValues?M.prototype._rand=function(S){var G=new Uint8Array(S);return self.crypto.getRandomValues(G),G}:self.msCrypto&&self.msCrypto.getRandomValues?M.prototype._rand=function(S){var G=new Uint8Array(S);return self.msCrypto.getRandomValues(G),G}:typeof window=="object"&&(M.prototype._rand=function(){throw new Error("Not implemented yet")});else try{if(U=c7(),typeof U.randomBytes!="function")throw new Error("Not supported");M.prototype._rand=function(S){return U.randomBytes(S)}}catch{}var U}),T6=G0((l,g)=>{var E=b7(),M=q9();function U(S){this.rand=S||new M.Rand}g.exports=U,U.create=function(S){return new U(S)},U.prototype._randbelow=function(S){var G=S.bitLength(),W=Math.ceil(G/8);do var I=new E(this.rand.generate(W));while(I.cmp(S)>=0);return I},U.prototype._randrange=function(S,G){var W=G.sub(S);return S.add(this._randbelow(W))},U.prototype.test=function(S,G,W){var I=S.bitLength(),V=E.mont(S),z=new E(1).toRed(V);G||(G=Math.max(1,I/48|0));for(var F=S.subn(1),O=0;!F.testn(O);O++);for(var N=S.shrn(O),j=F.toRed(V),D=!0;G>0;G--){var k=this._randrange(new E(2),F);W&&W(k);var A=k.toRed(V).redPow(N);if(!(A.cmp(z)===0||A.cmp(j)===0)){for(var x=1;x<O;x++){if(A=A.redSqr(),A.cmp(z)===0)return!1;if(A.cmp(j)===0)break}if(x===O)return!1}}return D},U.prototype.getDivisor=function(S,G){var W=S.bitLength(),I=E.mont(S),V=new E(1).toRed(I);G||(G=Math.max(1,W/48|0));for(var z=S.subn(1),F=0;!z.testn(F);F++);for(var O=S.shrn(F),N=z.toRed(I);G>0;G--){var j=this._randrange(new E(2),z),D=S.gcd(j);if(D.cmpn(1)!==0)return D;var k=j.toRed(I).redPow(O);if(!(k.cmp(V)===0||k.cmp(N)===0)){for(var A=1;A<F;A++){if(k=k.redSqr(),k.cmp(V)===0)return k.fromRed().subn(1).gcd(S);if(k.cmp(N)===0)break}if(A===F)return k=k.redSqr(),k.fromRed().subn(1).gcd(S)}}return!1}}),D6=G0((l,g)=>{var E=g5();g.exports=c,c.simpleSieve=y,c.fermatTest=p;var M=V6(),U=new M(24),S=T6(),G=new S,W=new M(1),I=new M(2),V=new M(5),z=new M(16),F=new M(8),O=new M(10),N=new M(3),j=new M(7),D=new M(11),k=new M(4),A=new M(12),x=null;function v(){if(x!==null)return x;var n=1048576,i=[];i[0]=2;for(var H0=1,a=3;a<n;a+=2){for(var P0=Math.ceil(Math.sqrt(a)),K=0;K<H0&&i[K]<=P0&&a%i[K]!==0;K++);H0!==K&&i[K]<=P0||(i[H0++]=a)}return x=i,i}function y(n){for(var i=v(),H0=0;H0<i.length;H0++)if(n.modn(i[H0])===0)return n.cmpn(i[H0])===0;return!0}function p(n){var i=M.mont(n);return I.toRed(i).redPow(n.subn(1)).fromRed().cmpn(1)===0}function c(n,i){if(n<16)return i===2||i===5?new M([140,123]):new M([140,39]);i=new M(i);for(var H0,a;;){for(H0=new M(E(Math.ceil(n/8)));H0.bitLength()>n;)H0.ishrn(1);if(H0.isEven()&&H0.iadd(W),H0.testn(1)||H0.iadd(I),i.cmp(I)){if(!i.cmp(V))for(;H0.mod(O).cmp(N);)H0.iadd(k)}else for(;H0.mod(U).cmp(D);)H0.iadd(k);if(a=H0.shrn(1),y(a)&&y(H0)&&p(a)&&p(H0)&&G.test(a)&&G.test(H0))return H0}}}),d7=G0((l,g)=>{g.exports={modp1:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a63a3620ffffffffffffffff"},modp2:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece65381ffffffffffffffff"},modp5:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca237327ffffffffffffffff"},modp14:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aacaa68ffffffffffffffff"},modp15:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a93ad2caffffffffffffffff"},modp16:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c934063199ffffffffffffffff"},modp17:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dcc4024ffffffffffffffff"},modp18:{gen:"02",prime:"ffffffffffffffffc90fdaa22168c234c4c6628b80dc1cd129024e088a67cc74020bbea63b139b22514a08798e3404ddef9519b3cd3a431b302b0a6df25f14374fe1356d6d51c245e485b576625e7ec6f44c42e9a637ed6b0bff5cb6f406b7edee386bfb5a899fa5ae9f24117c4b1fe649286651ece45b3dc2007cb8a163bf0598da48361c55d39a69163fa8fd24cf5f83655d23dca3ad961c62f356208552bb9ed529077096966d670c354e4abc9804f1746c08ca18217c32905e462e36ce3be39e772c180e86039b2783a2ec07a28fb5c55df06f4c52c9de2bcbf6955817183995497cea956ae515d2261898fa051015728e5a8aaac42dad33170d04507a33a85521abdf1cba64ecfb850458dbef0a8aea71575d060c7db3970f85a6e1e4c7abf5ae8cdb0933d71e8c94e04a25619dcee3d2261ad2ee6bf12ffa06d98a0864d87602733ec86a64521f2b18177b200cbbe117577a615d6c770988c0bad946e208e24fa074e5ab3143db5bfce0fd108e4b82d120a92108011a723c12a787e6d788719a10bdba5b2699c327186af4e23c1a946834b6150bda2583e9ca2ad44ce8dbbbc2db04de8ef92e8efc141fbecaa6287c59474e6bc05d99b2964fa090c3a2233ba186515be7ed1f612970cee2d7afb81bdd762170481cd0069127d5b05aa993b4ea988d8fddc186ffb7dc90a6c08f4df435c93402849236c3fab4d27c7026c1d4dcb2602646dec9751e763dba37bdf8ff9406ad9e530ee5db382f413001aeb06a53ed9027d831179727b0865a8918da3edbebcf9b14ed44ce6cbaced4bb1bdb7f1447e6cc254b332051512bd7af426fb8f401378cd2bf5983ca01c64b92ecf032ea15d1721d03f482d7ce6e74fef6d55e702f46980c82b5a84031900b1c9e59e7c97fbec7e8f323a97a7e36cc88be0f1d45b7ff585ac54bd407b22b4154aacc8f6d7ebf48e1d814cc5ed20f8037e0a79715eef29be32806a1d58bb7c5da76f550aa3d8a1fbff0eb19ccb1a313d55cda56c9ec2ef29632387fe8d76e3c0468043e8f663f4860ee12bf2d5b0b7474d6e694f91e6dbe115974a3926f12fee5e438777cb6a932df8cd8bec4d073b931ba3bc832b68d9dd300741fa7bf8afc47ed2576f6936ba424663aab639c5ae4f5683423b4742bf1c978238f16cbe39d652de3fdb8befc848ad922222e04a4037c0713eb57a81a23f0c73473fc646cea306b4bcbc8862f8385ddfa9d4b7fa2c087e879683303ed5bdd3a062b3cf5b3a278a66d2a13f83f44f82ddf310ee074ab6a364597e899a0255dc164f31cc50846851df9ab48195ded7ea1b1d510bd7ee74d73faf36bc31ecfa268359046f4eb879f924009438b481c6cd7889a002ed5ee382bc9190da6fc026e479558e4475677e9aa9e3050e2765694dfc81f56e880b96e7160c980dd98edd3dfffffffffffffffff"}}}),l7=G0((l,g)=>{var E=V6(),M=T6(),U=new M,S=new E(24),G=new E(11),W=new E(10),I=new E(3),V=new E(7),z=D6(),F=g5();g.exports=k;function O(x,v){return v=v||"utf8",Buffer.isBuffer(x)||(x=new Buffer(x,v)),this._pub=new E(x),this}function N(x,v){return v=v||"utf8",Buffer.isBuffer(x)||(x=new Buffer(x,v)),this._priv=new E(x),this}var j={};function D(x,v){var y=v.toString("hex"),p=[y,x.toString(16)].join("_");if(p in j)return j[p];var c=0;if(x.isEven()||!z.simpleSieve||!z.fermatTest(x)||!U.test(x))return c+=1,y==="02"||y==="05"?c+=8:c+=4,j[p]=c,c;U.test(x.shrn(1))||(c+=2);var n;switch(y){case"02":x.mod(S).cmp(G)&&(c+=8);break;case"05":n=x.mod(W),n.cmp(I)&&n.cmp(V)&&(c+=8);break;default:c+=4}return j[p]=c,c}function k(x,v,y){this.setGenerator(v),this.__prime=new E(x),this._prime=E.mont(this.__prime),this._primeLen=x.length,this._pub=void 0,this._priv=void 0,this._primeCode=void 0,y?(this.setPublicKey=O,this.setPrivateKey=N):this._primeCode=8}Object.defineProperty(k.prototype,"verifyError",{enumerable:!0,get:function(){return typeof this._primeCode!="number"&&(this._primeCode=D(this.__prime,this.__gen)),this._primeCode}}),k.prototype.generateKeys=function(){return this._priv||(this._priv=new E(F(this._primeLen))),this._pub=this._gen.toRed(this._prime).redPow(this._priv).fromRed(),this.getPublicKey()},k.prototype.computeSecret=function(x){x=new E(x),x=x.toRed(this._prime);var v=x.redPow(this._priv).fromRed(),y=new Buffer(v.toArray()),p=this.getPrime();if(y.length<p.length){var c=new Buffer(p.length-y.length);c.fill(0),y=Buffer.concat([c,y])}return y},k.prototype.getPublicKey=function(x){return A(this._pub,x)},k.prototype.getPrivateKey=function(x){return A(this._priv,x)},k.prototype.getPrime=function(x){return A(this.__prime,x)},k.prototype.getGenerator=function(x){return A(this._gen,x)},k.prototype.setGenerator=function(x,v){return v=v||"utf8",Buffer.isBuffer(x)||(x=new Buffer(x,v)),this.__gen=x,this._gen=new E(x),this};function A(x,v){var y=new Buffer(x.toArray());return v?y.toString(v):y}}),h7=G0((l)=>{var g=D6(),E=d7(),M=l7();function U(W){var I=new Buffer(E[W].prime,"hex"),V=new Buffer(E[W].gen,"hex");return new M(I,V)}var S={binary:!0,hex:!0,base64:!0};function G(W,I,V,z){return Buffer.isBuffer(I)||S[I]===void 0?G(W,"binary",I,V):(I=I||"binary",z=z||"binary",V=V||new Buffer([2]),Buffer.isBuffer(V)||(V=new Buffer(V,z)),typeof W=="number"?new M(g(W,V),V,!0):(Buffer.isBuffer(W)||(W=new Buffer(W,I)),new M(W,V,!0)))}l.DiffieHellmanGroup=l.createDiffieHellmanGroup=l.getDiffieHellman=U,l.createDiffieHellman=l.DiffieHellman=G}),N6=G0((l,g)=>{g.exports=S5().EventEmitter}),u7=G0((l,g)=>{function E(j,D){var k=Object.keys(j);if(Object.getOwnPropertySymbols){var A=Object.getOwnPropertySymbols(j);D&&(A=A.filter(function(x){return Object.getOwnPropertyDescriptor(j,x).enumerable})),k.push.apply(k,A)}return k}function M(j){for(var D=1;D<arguments.length;D++){var k=arguments[D]!=null?arguments[D]:{};D%2?E(Object(k),!0).forEach(function(A){U(j,A,k[A])}):Object.getOwnPropertyDescriptors?Object.defineProperties(j,Object.getOwnPropertyDescriptors(k)):E(Object(k)).forEach(function(A){Object.defineProperty(j,A,Object.getOwnPropertyDescriptor(k,A))})}return j}function U(j,D,k){return D in j?Object.defineProperty(j,D,{value:k,enumerable:!0,configurable:!0,writable:!0}):j[D]=k,j}function S(j,D){if(!(j instanceof D))throw new TypeError("Cannot call a class as a function")}function G(j,D){for(var k=0;k<D.length;k++){var A=D[k];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(j,A.key,A)}}function W(j,D,k){return D&&G(j.prototype,D),k&&G(j,k),j}var I=j5(),V=I.Buffer,z=i5(),F=z.inspect,O=F&&F.custom||"inspect";function N(j,D,k){V.prototype.copy.call(j,D,k)}g.exports=function(){function j(){S(this,j),this.head=null,this.tail=null,this.length=0}return W(j,[{key:"push",value:function(D){var k={data:D,next:null};this.length>0?this.tail.next=k:this.head=k,this.tail=k,++this.length}},{key:"unshift",value:function(D){var k={data:D,next:this.head};this.length===0&&(this.tail=k),this.head=k,++this.length}},{key:"shift",value:function(){if(this.length!==0){var D=this.head.data;return this.length===1?this.head=this.tail=null:this.head=this.head.next,--this.length,D}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(D){if(this.length===0)return"";for(var k=this.head,A=""+k.data;k=k.next;)A+=D+k.data;return A}},{key:"concat",value:function(D){if(this.length===0)return V.alloc(0);for(var k=V.allocUnsafe(D>>>0),A=this.head,x=0;A;)N(A.data,k,x),x+=A.data.length,A=A.next;return k}},{key:"consume",value:function(D,k){var A;return D<this.head.data.length?(A=this.head.data.slice(0,D),this.head.data=this.head.data.slice(D)):D===this.head.data.length?A=this.shift():A=k?this._getString(D):this._getBuffer(D),A}},{key:"first",value:function(){return this.head.data}},{key:"_getString",value:function(D){var k=this.head,A=1,x=k.data;for(D-=x.length;k=k.next;){var v=k.data,y=D>v.length?v.length:D;if(y===v.length?x+=v:x+=v.slice(0,D),D-=y,D===0){y===v.length?(++A,k.next?this.head=k.next:this.head=this.tail=null):(this.head=k,k.data=v.slice(y));break}++A}return this.length-=A,x}},{key:"_getBuffer",value:function(D){var k=V.allocUnsafe(D),A=this.head,x=1;for(A.data.copy(k),D-=A.data.length;A=A.next;){var v=A.data,y=D>v.length?v.length:D;if(v.copy(k,k.length-D,0,y),D-=y,D===0){y===v.length?(++x,A.next?this.head=A.next:this.head=this.tail=null):(this.head=A,A.data=v.slice(y));break}++x}return this.length-=x,k}},{key:O,value:function(D,k){return F(this,M({},k,{depth:0,customInspect:!1}))}}]),j}()}),L6=G0((l,g)=>{function E(I,V){var z=this,F=this._readableState&&this._readableState.destroyed,O=this._writableState&&this._writableState.destroyed;return F||O?(V?V(I):I&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,process.nextTick(G,this,I)):process.nextTick(G,this,I)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(I||null,function(N){!V&&N?z._writableState?z._writableState.errorEmitted?process.nextTick(U,z):(z._writableState.errorEmitted=!0,process.nextTick(M,z,N)):process.nextTick(M,z,N):V?(process.nextTick(U,z),V(N)):process.nextTick(U,z)}),this)}function M(I,V){G(I,V),U(I)}function U(I){I._writableState&&!I._writableState.emitClose||I._readableState&&!I._readableState.emitClose||I.emit("close")}function S(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function G(I,V){I.emit("error",V)}function W(I,V){var{_readableState:z,_writableState:F}=I;z&&z.autoDestroy||F&&F.autoDestroy?I.destroy(V):I.emit("error",V)}g.exports={destroy:E,undestroy:S,errorOrDestroy:W}}),c5=G0((l,g)=>{function E(V,z){V.prototype=Object.create(z.prototype),V.prototype.constructor=V,V.__proto__=z}var M={};function U(V,z,F){F||(F=Error);function O(j,D,k){return typeof z=="string"?z:z(j,D,k)}var N=function(j){E(D,j);function D(k,A,x){return j.call(this,O(k,A,x))||this}return D}(F);N.prototype.name=F.name,N.prototype.code=V,M[V]=N}function S(V,z){if(Array.isArray(V)){var F=V.length;return V=V.map(function(O){return String(O)}),F>2?"one of ".concat(z," ").concat(V.slice(0,F-1).join(", "),", or ")+V[F-1]:F===2?"one of ".concat(z," ").concat(V[0]," or ").concat(V[1]):"of ".concat(z," ").concat(V[0])}else return"of ".concat(z," ").concat(String(V))}function G(V,z,F){return V.substr(!F||F<0?0:+F,z.length)===z}function W(V,z,F){return(F===void 0||F>V.length)&&(F=V.length),V.substring(F-z.length,F)===z}function I(V,z,F){return typeof F!="number"&&(F=0),F+z.length>V.length?!1:V.indexOf(z,F)!==-1}U("ERR_INVALID_OPT_VALUE",function(V,z){return'The value "'+z+'" is invalid for option "'+V+'"'},TypeError),U("ERR_INVALID_ARG_TYPE",function(V,z,F){var O;typeof z=="string"&&G(z,"not ")?(O="must not be",z=z.replace(/^not /,"")):O="must be";var N;if(W(V," argument"))N="The ".concat(V," ").concat(O," ").concat(S(z,"type"));else{var j=I(V,".")?"property":"argument";N='The "'.concat(V,'" ').concat(j," ").concat(O," ").concat(S(z,"type"))}return N+=". Received type ".concat(typeof F),N},TypeError),U("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),U("ERR_METHOD_NOT_IMPLEMENTED",function(V){return"The "+V+" method is not implemented"}),U("ERR_STREAM_PREMATURE_CLOSE","Premature close"),U("ERR_STREAM_DESTROYED",function(V){return"Cannot call "+V+" after a stream was destroyed"}),U("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),U("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),U("ERR_STREAM_WRITE_AFTER_END","write after end"),U("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),U("ERR_UNKNOWN_ENCODING",function(V){return"Unknown encoding: "+V},TypeError),U("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),g.exports.codes=M}),I6=G0((l,g)=>{var E=c5().codes.ERR_INVALID_OPT_VALUE;function M(S,G,W){return S.highWaterMark!=null?S.highWaterMark:G?S[W]:null}function U(S,G,W,I){var V=M(G,I,W);if(V!=null){if(!(isFinite(V)&&Math.floor(V)===V)||V<0){var z=I?W:"highWaterMark";throw new E(z,V)}return Math.floor(V)}return S.objectMode?16:16384}g.exports={getHighWaterMark:U}}),k6=G0((l,g)=>{g.exports=a;function E(u){var d=this;this.next=null,this.entry=null,this.finish=function(){X0(d,u)}}var M;a.WritableState=i;var U={deprecate:h9()},S=N6(),G=j5().Buffer,W=global.Uint8Array||function(){};function I(u){return G.from(u)}function V(u){return G.isBuffer(u)||u instanceof W}var z=L6(),F=I6(),O=F.getHighWaterMark,N=c5().codes,j=N.ERR_INVALID_ARG_TYPE,D=N.ERR_METHOD_NOT_IMPLEMENTED,k=N.ERR_MULTIPLE_CALLBACK,A=N.ERR_STREAM_CANNOT_PIPE,x=N.ERR_STREAM_DESTROYED,v=N.ERR_STREAM_NULL_VALUES,y=N.ERR_STREAM_WRITE_AFTER_END,p=N.ERR_UNKNOWN_ENCODING,c=z.errorOrDestroy;p0()(a,S);function n(){}function i(u,d,f){M=M||y5(),u=u||{},typeof f!="boolean"&&(f=d instanceof M),this.objectMode=!!u.objectMode,f&&(this.objectMode=this.objectMode||!!u.writableObjectMode),this.highWaterMark=O(this,u,"writableHighWaterMark",f),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;var z0=u.decodeStrings===!1;this.decodeStrings=!z0,this.defaultEncoding=u.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=function(K0){Z(d,K0)},this.writecb=null,this.writelen=0,this.bufferedRequest=null,this.lastBufferedRequest=null,this.pendingcb=0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=u.emitClose!==!1,this.autoDestroy=!!u.autoDestroy,this.bufferedRequestCount=0,this.corkedRequestsFree=new E(this)}i.prototype.getBuffer=function(){for(var u=this.bufferedRequest,d=[];u;)d.push(u),u=u.next;return d},function(){try{Object.defineProperty(i.prototype,"buffer",{get:U.deprecate(function(){return this.getBuffer()},"_writableState.buffer is deprecated. Use _writableState.getBuffer instead.","DEP0003")})}catch{}}();var H0;typeof Symbol=="function"&&Symbol.hasInstance&&typeof Function.prototype[Symbol.hasInstance]=="function"?(H0=Function.prototype[Symbol.hasInstance],Object.defineProperty(a,Symbol.hasInstance,{value:function(u){return H0.call(this,u)?!0:this!==a?!1:u&&u._writableState instanceof i}})):H0=function(u){return u instanceof this};function a(u){M=M||y5();var d=this instanceof M;if(!d&&!H0.call(a,this))return new a(u);this._writableState=new i(u,this,d),this.writable=!0,u&&(typeof u.write=="function"&&(this._write=u.write),typeof u.writev=="function"&&(this._writev=u.writev),typeof u.destroy=="function"&&(this._destroy=u.destroy),typeof u.final=="function"&&(this._final=u.final)),S.call(this)}a.prototype.pipe=function(){c(this,new A)};function P0(u,d){var f=new y;c(u,f),process.nextTick(d,f)}function K(u,d,f,z0){var K0;return f===null?K0=new v:typeof f!="string"&&!d.objectMode&&(K0=new j("chunk",["string","Buffer"],f)),K0?(c(u,K0),process.nextTick(z0,K0),!1):!0}a.prototype.write=function(u,d,f){var z0=this._writableState,K0=!1,Q0=!z0.objectMode&&V(u);return Q0&&!G.isBuffer(u)&&(u=I(u)),typeof d=="function"&&(f=d,d=null),Q0?d="buffer":d||(d=z0.defaultEncoding),typeof f!="function"&&(f=n),z0.ending?P0(this,f):(Q0||K(this,z0,u,f))&&(z0.pendingcb++,K0=Y(this,z0,Q0,u,d,f)),K0},a.prototype.cork=function(){this._writableState.corked++},a.prototype.uncork=function(){var u=this._writableState;u.corked&&(u.corked--,!u.writing&&!u.corked&&!u.bufferProcessing&&u.bufferedRequest&&J(this,u))},a.prototype.setDefaultEncoding=function(u){if(typeof u=="string"&&(u=u.toLowerCase()),!(["hex","utf8","utf-8","ascii","binary","base64","ucs2","ucs-2","utf16le","utf-16le","raw"].indexOf((u+"").toLowerCase())>-1))throw new p(u);return this._writableState.defaultEncoding=u,this},Object.defineProperty(a.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}});function X(u,d,f){return!u.objectMode&&u.decodeStrings!==!1&&typeof d=="string"&&(d=G.from(d,f)),d}Object.defineProperty(a.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}});function Y(u,d,f,z0,K0,Q0){if(!f){var w=X(d,z0,K0);z0!==w&&(f=!0,K0="buffer",z0=w)}var q=d.objectMode?1:z0.length;d.length+=q;var m=d.length<d.highWaterMark;if(m||(d.needDrain=!0),d.writing||d.corked){var e=d.lastBufferedRequest;d.lastBufferedRequest={chunk:z0,encoding:K0,isBuf:f,callback:Q0,next:null},e?e.next=d.lastBufferedRequest:d.bufferedRequest=d.lastBufferedRequest,d.bufferedRequestCount+=1}else H(u,d,!1,q,z0,K0,Q0);return m}function H(u,d,f,z0,K0,Q0,w){d.writelen=z0,d.writecb=w,d.writing=!0,d.sync=!0,d.destroyed?d.onwrite(new x("write")):f?u._writev(K0,d.onwrite):u._write(K0,Q0,d.onwrite),d.sync=!1}function Q(u,d,f,z0,K0){--d.pendingcb,f?(process.nextTick(K0,z0),process.nextTick(s,u,d),u._writableState.errorEmitted=!0,c(u,z0)):(K0(z0),u._writableState.errorEmitted=!0,c(u,z0),s(u,d))}function P(u){u.writing=!1,u.writecb=null,u.length-=u.writelen,u.writelen=0}function Z(u,d){var f=u._writableState,z0=f.sync,K0=f.writecb;if(typeof K0!="function")throw new k;if(P(f),d)Q(u,f,z0,d,K0);else{var Q0=R(f)||u.destroyed;!Q0&&!f.corked&&!f.bufferProcessing&&f.bufferedRequest&&J(u,f),z0?process.nextTick($,u,f,Q0,K0):$(u,f,Q0,K0)}}function $(u,d,f,z0){f||C(u,d),d.pendingcb--,z0(),s(u,d)}function C(u,d){d.length===0&&d.needDrain&&(d.needDrain=!1,u.emit("drain"))}function J(u,d){d.bufferProcessing=!0;var f=d.bufferedRequest;if(u._writev&&f&&f.next){var z0=d.bufferedRequestCount,K0=new Array(z0),Q0=d.corkedRequestsFree;Q0.entry=f;for(var w=0,q=!0;f;)K0[w]=f,f.isBuf||(q=!1),f=f.next,w+=1;K0.allBuffers=q,H(u,d,!0,d.length,K0,"",Q0.finish),d.pendingcb++,d.lastBufferedRequest=null,Q0.next?(d.corkedRequestsFree=Q0.next,Q0.next=null):d.corkedRequestsFree=new E(d),d.bufferedRequestCount=0}else{for(;f;){var{chunk:m,encoding:e,callback:C0}=f,t=d.objectMode?1:m.length;if(H(u,d,!1,t,m,e,C0),f=f.next,d.bufferedRequestCount--,d.writing)break}f===null&&(d.lastBufferedRequest=null)}d.bufferedRequest=f,d.bufferProcessing=!1}a.prototype._write=function(u,d,f){f(new D("_write()"))},a.prototype._writev=null,a.prototype.end=function(u,d,f){var z0=this._writableState;return typeof u=="function"?(f=u,u=null,d=null):typeof d=="function"&&(f=d,d=null),u!=null&&this.write(u,d),z0.corked&&(z0.corked=1,this.uncork()),z0.ending||r(this,z0,f),this},Object.defineProperty(a.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function R(u){return u.ending&&u.length===0&&u.bufferedRequest===null&&!u.finished&&!u.writing}function L(u,d){u._final(function(f){d.pendingcb--,f&&c(u,f),d.prefinished=!0,u.emit("prefinish"),s(u,d)})}function _(u,d){!d.prefinished&&!d.finalCalled&&(typeof u._final=="function"&&!d.destroyed?(d.pendingcb++,d.finalCalled=!0,process.nextTick(L,u,d)):(d.prefinished=!0,u.emit("prefinish")))}function s(u,d){var f=R(d);if(f&&(_(u,d),d.pendingcb===0&&(d.finished=!0,u.emit("finish"),d.autoDestroy))){var z0=u._readableState;(!z0||z0.autoDestroy&&z0.endEmitted)&&u.destroy()}return f}function r(u,d,f){d.ending=!0,s(u,d),f&&(d.finished?process.nextTick(f):u.once("finish",f)),d.ended=!0,u.writable=!1}function X0(u,d,f){var z0=u.entry;for(u.entry=null;z0;){var K0=z0.callback;d.pendingcb--,K0(f),z0=z0.next}d.corkedRequestsFree.next=u}Object.defineProperty(a.prototype,"destroyed",{enumerable:!1,get:function(){return this._writableState===void 0?!1:this._writableState.destroyed},set:function(u){!this._writableState||(this._writableState.destroyed=u)}}),a.prototype.destroy=z.destroy,a.prototype._undestroy=z.undestroy,a.prototype._destroy=function(u,d){d(u)}}),y5=G0((l,g)=>{var E=Object.keys||function(F){var O=[];for(var N in F)O.push(N);return O};g.exports=I;var M=q6(),U=k6();p0()(I,M);for(S=E(U.prototype),W=0;W<S.length;W++)G=S[W],I.prototype[G]||(I.prototype[G]=U.prototype[G]);var S,G,W;function I(F){if(!(this instanceof I))return new I(F);M.call(this,F),U.call(this,F),this.allowHalfOpen=!0,F&&(F.readable===!1&&(this.readable=!1),F.writable===!1&&(this.writable=!1),F.allowHalfOpen===!1&&(this.allowHalfOpen=!1,this.once("end",V)))}Object.defineProperty(I.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),Object.defineProperty(I.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(I.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}});function V(){this._writableState.ended||process.nextTick(z,this)}function z(F){F.end()}Object.defineProperty(I.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0||this._writableState===void 0?!1:this._readableState.destroyed&&this._writableState.destroyed},set:function(F){this._readableState===void 0||this._writableState===void 0||(this._readableState.destroyed=F,this._writableState.destroyed=F)}})}),B9=G0((l,g)=>{var E=c5().codes.ERR_STREAM_PREMATURE_CLOSE;function M(W){var I=!1;return function(){if(!I){I=!0;for(var V=arguments.length,z=new Array(V),F=0;F<V;F++)z[F]=arguments[F];W.apply(this,z)}}}function U(){}function S(W){return W.setHeader&&typeof W.abort=="function"}function G(W,I,V){if(typeof I=="function")return G(W,null,I);I||(I={}),V=M(V||U);var z=I.readable||I.readable!==!1&&W.readable,F=I.writable||I.writable!==!1&&W.writable,O=function(){W.writable||j()},N=W._writableState&&W._writableState.finished,j=function(){F=!1,N=!0,z||V.call(W)},D=W._readableState&&W._readableState.endEmitted,k=function(){z=!1,D=!0,F||V.call(W)},A=function(y){V.call(W,y)},x=function(){var y;if(z&&!D)return(!W._readableState||!W._readableState.ended)&&(y=new E),V.call(W,y);if(F&&!N)return(!W._writableState||!W._writableState.ended)&&(y=new E),V.call(W,y)},v=function(){W.req.on("finish",j)};return S(W)?(W.on("complete",j),W.on("abort",x),W.req?v():W.on("request",v)):F&&!W._writableState&&(W.on("end",O),W.on("close",O)),W.on("end",k),W.on("finish",j),I.error!==!1&&W.on("error",A),W.on("close",x),function(){W.removeListener("complete",j),W.removeListener("abort",x),W.removeListener("request",v),W.req&&W.req.removeListener("finish",j),W.removeListener("end",O),W.removeListener("close",O),W.removeListener("finish",j),W.removeListener("end",k),W.removeListener("error",A),W.removeListener("close",x)}}g.exports=G}),o7=G0((l,g)=>{var E;function M(v,y,p){return y in v?Object.defineProperty(v,y,{value:p,enumerable:!0,configurable:!0,writable:!0}):v[y]=p,v}var U=B9(),S=Symbol("lastResolve"),G=Symbol("lastReject"),W=Symbol("error"),I=Symbol("ended"),V=Symbol("lastPromise"),z=Symbol("handlePromise"),F=Symbol("stream");function O(v,y){return{value:v,done:y}}function N(v){var y=v[S];if(y!==null){var p=v[F].read();p!==null&&(v[V]=null,v[S]=null,v[G]=null,y(O(p,!1)))}}function j(v){process.nextTick(N,v)}function D(v,y){return function(p,c){v.then(function(){if(y[I]){p(O(void 0,!0));return}y[z](p,c)},c)}}var k=Object.getPrototypeOf(function(){}),A=Object.setPrototypeOf((E={get stream(){return this[F]},next:function(){var v=this,y=this[W];if(y!==null)return Promise.reject(y);if(this[I])return Promise.resolve(O(void 0,!0));if(this[F].destroyed)return new Promise(function(i,H0){process.nextTick(function(){v[W]?H0(v[W]):i(O(void 0,!0))})});var p=this[V],c;if(p)c=new Promise(D(p,this));else{var n=this[F].read();if(n!==null)return Promise.resolve(O(n,!1));c=new Promise(this[z])}return this[V]=c,c}},M(E,Symbol.asyncIterator,function(){return this}),M(E,"return",function(){var v=this;return new Promise(function(y,p){v[F].destroy(null,function(c){if(c){p(c);return}y(O(void 0,!0))})})}),E),k),x=function(v){var y,p=Object.create(A,(y={},M(y,F,{value:v,writable:!0}),M(y,S,{value:null,writable:!0}),M(y,G,{value:null,writable:!0}),M(y,W,{value:null,writable:!0}),M(y,I,{value:v._readableState.endEmitted,writable:!0}),M(y,z,{value:function(c,n){var i=p[F].read();i?(p[V]=null,p[S]=null,p[G]=null,c(O(i,!1))):(p[S]=c,p[G]=n)},writable:!0}),y));return p[V]=null,U(v,function(c){if(c&&c.code!=="ERR_STREAM_PREMATURE_CLOSE"){var n=p[G];n!==null&&(p[V]=null,p[S]=null,p[G]=null,n(c)),p[W]=c;return}var i=p[S];i!==null&&(p[V]=null,p[S]=null,p[G]=null,i(O(void 0,!0))),p[I]=!0}),v.on("readable",j.bind(null,p)),p};g.exports=x}),s7=G0((l,g)=>{g.exports=function(){throw new Error("Readable.from is not available in the browser")}}),q6=G0((l,g)=>{g.exports=K;var E;K.ReadableState=P0;var M=S5().EventEmitter,U=function(w,q){return w.listeners(q).length},S=N6(),G=j5().Buffer,W=global.Uint8Array||function(){};function I(w){return G.from(w)}function V(w){return G.isBuffer(w)||w instanceof W}var z=i5(),F;z&&z.debuglog?F=z.debuglog("stream"):F=function(){};var O=u7(),N=L6(),j=I6(),D=j.getHighWaterMark,k=c5().codes,A=k.ERR_INVALID_ARG_TYPE,x=k.ERR_STREAM_PUSH_AFTER_EOF,v=k.ERR_METHOD_NOT_IMPLEMENTED,y=k.ERR_STREAM_UNSHIFT_AFTER_END_EVENT,p,c,n;p0()(K,S);var i=N.errorOrDestroy,H0=["error","close","destroy","pause","resume"];function a(w,q,m){if(typeof w.prependListener=="function")return w.prependListener(q,m);!w._events||!w._events[q]?w.on(q,m):Array.isArray(w._events[q])?w._events[q].unshift(m):w._events[q]=[m,w._events[q]]}function P0(w,q,m){E=E||y5(),w=w||{},typeof m!="boolean"&&(m=q instanceof E),this.objectMode=!!w.objectMode,m&&(this.objectMode=this.objectMode||!!w.readableObjectMode),this.highWaterMark=D(this,w,"readableHighWaterMark",m),this.buffer=new O,this.length=0,this.pipes=null,this.pipesCount=0,this.flowing=null,this.ended=!1,this.endEmitted=!1,this.reading=!1,this.sync=!0,this.needReadable=!1,this.emittedReadable=!1,this.readableListening=!1,this.resumeScheduled=!1,this.paused=!0,this.emitClose=w.emitClose!==!1,this.autoDestroy=!!w.autoDestroy,this.destroyed=!1,this.defaultEncoding=w.defaultEncoding||"utf8",this.awaitDrain=0,this.readingMore=!1,this.decoder=null,this.encoding=null,w.encoding&&(p||(p=(a5(),O5(d5)).StringDecoder),this.decoder=new p(w.encoding),this.encoding=w.encoding)}function K(w){if(E=E||y5(),!(this instanceof K))return new K(w);var q=this instanceof E;this._readableState=new P0(w,this,q),this.readable=!0,w&&(typeof w.read=="function"&&(this._read=w.read),typeof w.destroy=="function"&&(this._destroy=w.destroy)),S.call(this)}Object.defineProperty(K.prototype,"destroyed",{enumerable:!1,get:function(){return this._readableState===void 0?!1:this._readableState.destroyed},set:function(w){!this._readableState||(this._readableState.destroyed=w)}}),K.prototype.destroy=N.destroy,K.prototype._undestroy=N.undestroy,K.prototype._destroy=function(w,q){q(w)},K.prototype.push=function(w,q){var m=this._readableState,e;return m.objectMode?e=!0:typeof w=="string"&&(q=q||m.defaultEncoding,q!==m.encoding&&(w=G.from(w,q),q=""),e=!0),X(this,w,q,!1,e)},K.prototype.unshift=function(w){return X(this,w,null,!0,!1)};function X(w,q,m,e,C0){F("readableAddChunk",q);var t=w._readableState;if(q===null)t.reading=!1,$(w,t);else{var _0;if(C0||(_0=H(t,q)),_0)i(w,_0);else if(t.objectMode||q&&q.length>0)if(typeof q!="string"&&!t.objectMode&&Object.getPrototypeOf(q)!==G.prototype&&(q=I(q)),e)t.endEmitted?i(w,new y):Y(w,t,q,!0);else if(t.ended)i(w,new x);else{if(t.destroyed)return!1;t.reading=!1,t.decoder&&!m?(q=t.decoder.write(q),t.objectMode||q.length!==0?Y(w,t,q,!1):R(w,t)):Y(w,t,q,!1)}else e||(t.reading=!1,R(w,t))}return!t.ended&&(t.length<t.highWaterMark||t.length===0)}function Y(w,q,m,e){q.flowing&&q.length===0&&!q.sync?(q.awaitDrain=0,w.emit("data",m)):(q.length+=q.objectMode?1:m.length,e?q.buffer.unshift(m):q.buffer.push(m),q.needReadable&&C(w)),R(w,q)}function H(w,q){var m;return!V(q)&&typeof q!="string"&&q!==void 0&&!w.objectMode&&(m=new A("chunk",["string","Buffer","Uint8Array"],q)),m}K.prototype.isPaused=function(){return this._readableState.flowing===!1},K.prototype.setEncoding=function(w){p||(p=(a5(),O5(d5)).StringDecoder);var q=new p(w);this._readableState.decoder=q,this._readableState.encoding=this._readableState.decoder.encoding;for(var m=this._readableState.buffer.head,e="";m!==null;)e+=q.write(m.data),m=m.next;return this._readableState.buffer.clear(),e!==""&&this._readableState.buffer.push(e),this._readableState.length=e.length,this};var Q=1073741824;function P(w){return w>=Q?w=Q:(w--,w|=w>>>1,w|=w>>>2,w|=w>>>4,w|=w>>>8,w|=w>>>16,w++),w}function Z(w,q){return w<=0||q.length===0&&q.ended?0:q.objectMode?1:w!==w?q.flowing&&q.length?q.buffer.head.data.length:q.length:(w>q.highWaterMark&&(q.highWaterMark=P(w)),w<=q.length?w:q.ended?q.length:(q.needReadable=!0,0))}K.prototype.read=function(w){F("read",w),w=parseInt(w,10);var q=this._readableState,m=w;if(w!==0&&(q.emittedReadable=!1),w===0&&q.needReadable&&((q.highWaterMark!==0?q.length>=q.highWaterMark:q.length>0)||q.ended))return F("read: emitReadable",q.length,q.ended),q.length===0&&q.ended?z0(this):C(this),null;if(w=Z(w,q),w===0&&q.ended)return q.length===0&&z0(this),null;var e=q.needReadable;F("need readable",e),(q.length===0||q.length-w<q.highWaterMark)&&(e=!0,F("length less than watermark",e)),q.ended||q.reading?(e=!1,F("reading or ended",e)):e&&(F("do read"),q.reading=!0,q.sync=!0,q.length===0&&(q.needReadable=!0),this._read(q.highWaterMark),q.sync=!1,q.reading||(w=Z(m,q)));var C0;return w>0?C0=f(w,q):C0=null,C0===null?(q.needReadable=q.length<=q.highWaterMark,w=0):(q.length-=w,q.awaitDrain=0),q.length===0&&(q.ended||(q.needReadable=!0),m!==w&&q.ended&&z0(this)),C0!==null&&this.emit("data",C0),C0};function $(w,q){if(F("onEofChunk"),!q.ended){if(q.decoder){var m=q.decoder.end();m&&m.length&&(q.buffer.push(m),q.length+=q.objectMode?1:m.length)}q.ended=!0,q.sync?C(w):(q.needReadable=!1,q.emittedReadable||(q.emittedReadable=!0,J(w)))}}function C(w){var q=w._readableState;F("emitReadable",q.needReadable,q.emittedReadable),q.needReadable=!1,q.emittedReadable||(F("emitReadable",q.flowing),q.emittedReadable=!0,process.nextTick(J,w))}function J(w){var q=w._readableState;F("emitReadable_",q.destroyed,q.length,q.ended),!q.destroyed&&(q.length||q.ended)&&(w.emit("readable"),q.emittedReadable=!1),q.needReadable=!q.flowing&&!q.ended&&q.length<=q.highWaterMark,d(w)}function R(w,q){q.readingMore||(q.readingMore=!0,process.nextTick(L,w,q))}function L(w,q){for(;!q.reading&&!q.ended&&(q.length<q.highWaterMark||q.flowing&&q.length===0);){var m=q.length;if(F("maybeReadMore read 0"),w.read(0),m===q.length)break}q.readingMore=!1}K.prototype._read=function(w){i(this,new v("_read()"))},K.prototype.pipe=function(w,q){var m=this,e=this._readableState;switch(e.pipesCount){case 0:e.pipes=w;break;case 1:e.pipes=[e.pipes,w];break;default:e.pipes.push(w);break}e.pipesCount+=1,F("pipe count=%d opts=%j",e.pipesCount,q);var C0=(!q||q.end!==!1)&&w!==process.stdout&&w!==process.stderr,t=C0?$0:b;e.endEmitted?process.nextTick(t):m.once("end",t),w.on("unpipe",_0);function _0(h,o){F("onunpipe"),h===m&&o&&o.hasUnpiped===!1&&(o.hasUnpiped=!0,j0())}function $0(){F("onend"),w.end()}var J0=_(m);w.on("drain",J0);var w0=!1;function j0(){F("cleanup"),w.removeListener("close",T),w.removeListener("finish",B),w.removeListener("drain",J0),w.removeListener("error",c0),w.removeListener("unpipe",_0),m.removeListener("end",$0),m.removeListener("end",b),m.removeListener("data",Z0),w0=!0,e.awaitDrain&&(!w._writableState||w._writableState.needDrain)&&J0()}m.on("data",Z0);function Z0(h){F("ondata");var o=w.write(h);F("dest.write",o),o===!1&&((e.pipesCount===1&&e.pipes===w||e.pipesCount>1&&Q0(e.pipes,w)!==-1)&&!w0&&(F("false write response, pause",e.awaitDrain),e.awaitDrain++),m.pause())}function c0(h){F("onerror",h),b(),w.removeListener("error",c0),U(w,"error")===0&&i(w,h)}a(w,"error",c0);function T(){w.removeListener("finish",B),b()}w.once("close",T);function B(){F("onfinish"),w.removeListener("close",T),b()}w.once("finish",B);function b(){F("unpipe"),m.unpipe(w)}return w.emit("pipe",m),e.flowing||(F("pipe resume"),m.resume()),w};function _(w){return function(){var q=w._readableState;F("pipeOnDrain",q.awaitDrain),q.awaitDrain&&q.awaitDrain--,q.awaitDrain===0&&U(w,"data")&&(q.flowing=!0,d(w))}}K.prototype.unpipe=function(w){var q=this._readableState,m={hasUnpiped:!1};if(q.pipesCount===0)return this;if(q.pipesCount===1)return w&&w!==q.pipes?this:(w||(w=q.pipes),q.pipes=null,q.pipesCount=0,q.flowing=!1,w&&w.emit("unpipe",this,m),this);if(!w){var{pipes:e,pipesCount:C0}=q;q.pipes=null,q.pipesCount=0,q.flowing=!1;for(var t=0;t<C0;t++)e[t].emit("unpipe",this,{hasUnpiped:!1});return this}var _0=Q0(q.pipes,w);return _0===-1?this:(q.pipes.splice(_0,1),q.pipesCount-=1,q.pipesCount===1&&(q.pipes=q.pipes[0]),w.emit("unpipe",this,m),this)},K.prototype.on=function(w,q){var m=S.prototype.on.call(this,w,q),e=this._readableState;return w==="data"?(e.readableListening=this.listenerCount("readable")>0,e.flowing!==!1&&this.resume()):w==="readable"&&!e.endEmitted&&!e.readableListening&&(e.readableListening=e.needReadable=!0,e.flowing=!1,e.emittedReadable=!1,F("on readable",e.length,e.reading),e.length?C(this):e.reading||process.nextTick(r,this)),m},K.prototype.addListener=K.prototype.on,K.prototype.removeListener=function(w,q){var m=S.prototype.removeListener.call(this,w,q);return w==="readable"&&process.nextTick(s,this),m},K.prototype.removeAllListeners=function(w){var q=S.prototype.removeAllListeners.apply(this,arguments);return(w==="readable"||w===void 0)&&process.nextTick(s,this),q};function s(w){var q=w._readableState;q.readableListening=w.listenerCount("readable")>0,q.resumeScheduled&&!q.paused?q.flowing=!0:w.listenerCount("data")>0&&w.resume()}function r(w){F("readable nexttick read 0"),w.read(0)}K.prototype.resume=function(){var w=this._readableState;return w.flowing||(F("resume"),w.flowing=!w.readableListening,X0(this,w)),w.paused=!1,this};function X0(w,q){q.resumeScheduled||(q.resumeScheduled=!0,process.nextTick(u,w,q))}function u(w,q){F("resume",q.reading),q.reading||w.read(0),q.resumeScheduled=!1,w.emit("resume"),d(w),q.flowing&&!q.reading&&w.read(0)}K.prototype.pause=function(){return F("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1&&(F("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this};function d(w){var q=w._readableState;for(F("flow",q.flowing);q.flowing&&w.read()!==null;);}K.prototype.wrap=function(w){var q=this,m=this._readableState,e=!1;w.on("end",function(){if(F("wrapped end"),m.decoder&&!m.ended){var _0=m.decoder.end();_0&&_0.length&&q.push(_0)}q.push(null)}),w.on("data",function(_0){if(F("wrapped data"),m.decoder&&(_0=m.decoder.write(_0)),!(m.objectMode&&_0==null)&&!(!m.objectMode&&(!_0||!_0.length))){var $0=q.push(_0);$0||(e=!0,w.pause())}});for(var C0 in w)this[C0]===void 0&&typeof w[C0]=="function"&&(this[C0]=function(_0){return function(){return w[_0].apply(w,arguments)}}(C0));for(var t=0;t<H0.length;t++)w.on(H0[t],this.emit.bind(this,H0[t]));return this._read=function(_0){F("wrapped _read",_0),e&&(e=!1,w.resume())},this},typeof Symbol=="function"&&(K.prototype[Symbol.asyncIterator]=function(){return c===void 0&&(c=o7()),c(this)}),Object.defineProperty(K.prototype,"readableHighWaterMark",{enumerable:!1,get:function(){return this._readableState.highWaterMark}}),Object.defineProperty(K.prototype,"readableBuffer",{enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}}),Object.defineProperty(K.prototype,"readableFlowing",{enumerable:!1,get:function(){return this._readableState.flowing},set:function(w){this._readableState&&(this._readableState.flowing=w)}}),K._fromList=f,Object.defineProperty(K.prototype,"readableLength",{enumerable:!1,get:function(){return this._readableState.length}});function f(w,q){if(q.length===0)return null;var m;return q.objectMode?m=q.buffer.shift():!w||w>=q.length?(q.decoder?m=q.buffer.join(""):q.buffer.length===1?m=q.buffer.first():m=q.buffer.concat(q.length),q.buffer.clear()):m=q.buffer.consume(w,q.decoder),m}function z0(w){var q=w._readableState;F("endReadable",q.endEmitted),q.endEmitted||(q.ended=!0,process.nextTick(K0,q,w))}function K0(w,q){if(F("endReadableNT",w.endEmitted,w.length),!w.endEmitted&&w.length===0&&(w.endEmitted=!0,q.readable=!1,q.emit("end"),w.autoDestroy)){var m=q._writableState;(!m||m.autoDestroy&&m.finished)&&q.destroy()}}typeof Symbol=="function"&&(K.from=function(w,q){return n===void 0&&(n=s7()),n(K,w,q)});function Q0(w,q){for(var m=0,e=w.length;m<e;m++)if(w[m]===q)return m;return-1}}),B6=G0((l,g)=>{g.exports=V;var E=c5().codes,M=E.ERR_METHOD_NOT_IMPLEMENTED,U=E.ERR_MULTIPLE_CALLBACK,S=E.ERR_TRANSFORM_ALREADY_TRANSFORMING,G=E.ERR_TRANSFORM_WITH_LENGTH_0,W=y5();p0()(V,W);function I(O,N){var j=this._transformState;j.transforming=!1;var D=j.writecb;if(D===null)return this.emit("error",new U);j.writechunk=null,j.writecb=null,N!=null&&this.push(N),D(O);var k=this._readableState;k.reading=!1,(k.needReadable||k.length<k.highWaterMark)&&this._read(k.highWaterMark)}function V(O){if(!(this instanceof V))return new V(O);W.call(this,O),this._transformState={afterTransform:I.bind(this),needTransform:!1,transforming:!1,writecb:null,writechunk:null,writeencoding:null},this._readableState.needReadable=!0,this._readableState.sync=!1,O&&(typeof O.transform=="function"&&(this._transform=O.transform),typeof O.flush=="function"&&(this._flush=O.flush)),this.on("prefinish",z)}function z(){var O=this;typeof this._flush=="function"&&!this._readableState.destroyed?this._flush(function(N,j){F(O,N,j)}):F(this,null,null)}V.prototype.push=function(O,N){return this._transformState.needTransform=!1,W.prototype.push.call(this,O,N)},V.prototype._transform=function(O,N,j){j(new M("_transform()"))},V.prototype._write=function(O,N,j){var D=this._transformState;if(D.writecb=j,D.writechunk=O,D.writeencoding=N,!D.transforming){var k=this._readableState;(D.needTransform||k.needReadable||k.length<k.highWaterMark)&&this._read(k.highWaterMark)}},V.prototype._read=function(O){var N=this._transformState;N.writechunk!==null&&!N.transforming?(N.transforming=!0,this._transform(N.writechunk,N.writeencoding,N.afterTransform)):N.needTransform=!0},V.prototype._destroy=function(O,N){W.prototype._destroy.call(this,O,function(j){N(j)})};function F(O,N,j){if(N)return O.emit("error",N);if(j!=null&&O.push(j),O._writableState.length)throw new G;if(O._transformState.transforming)throw new S;return O.push(null)}}),a7=G0((l,g)=>{g.exports=M;var E=B6();p0()(M,E);function M(U){if(!(this instanceof M))return new M(U);E.call(this,U)}M.prototype._transform=function(U,S,G){G(null,U)}}),f7=G0((l,g)=>{var E;function M(j){var D=!1;return function(){D||(D=!0,j.apply(void 0,arguments))}}var U=c5().codes,S=U.ERR_MISSING_ARGS,G=U.ERR_STREAM_DESTROYED;function W(j){if(j)throw j}function I(j){return j.setHeader&&typeof j.abort=="function"}function V(j,D,k,A){A=M(A);var x=!1;j.on("close",function(){x=!0}),E===void 0&&(E=B9()),E(j,{readable:D,writable:k},function(y){if(y)return A(y);x=!0,A()});var v=!1;return function(y){if(!x&&!v){if(v=!0,I(j))return j.abort();if(typeof j.destroy=="function")return j.destroy();A(y||new G("pipe"))}}}function z(j){j()}function F(j,D){return j.pipe(D)}function O(j){return!j.length||typeof j[j.length-1]!="function"?W:j.pop()}function N(){for(var j=arguments.length,D=new Array(j),k=0;k<j;k++)D[k]=arguments[k];var A=O(D);if(Array.isArray(D[0])&&(D=D[0]),D.length<2)throw new S("streams");var x,v=D.map(function(y,p){var c=p<D.length-1,n=p>0;return V(y,c,n,function(i){x||(x=i),i&&v.forEach(z),!c&&(v.forEach(z),A(x))})});return D.reduce(F)}g.exports=N}),n7=G0((l,g)=>{l=g.exports=q6(),l.Stream=l,l.Readable=l,l.Writable=k6(),l.Duplex=y5(),l.Transform=B6(),l.PassThrough=a7(),l.finished=B9(),l.pipeline=f7()}),R9=G0((l,g)=>{(function(E,M){function U(H,Q){if(!H)throw new Error(Q||"Assertion failed")}function S(H,Q){H.super_=Q;var P=function(){};P.prototype=Q.prototype,H.prototype=new P,H.prototype.constructor=H}function G(H,Q,P){if(G.isBN(H))return H;this.negative=0,this.words=null,this.length=0,this.red=null,H!==null&&((Q==="le"||Q==="be")&&(P=Q,Q=10),this._init(H||0,Q||10,P||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(H){return H instanceof G?!0:H!==null&&typeof H=="object"&&H.constructor.wordSize===G.wordSize&&Array.isArray(H.words)},G.max=function(H,Q){return H.cmp(Q)>0?H:Q},G.min=function(H,Q){return H.cmp(Q)<0?H:Q},G.prototype._init=function(H,Q,P){if(typeof H=="number")return this._initNumber(H,Q,P);if(typeof H=="object")return this._initArray(H,Q,P);Q==="hex"&&(Q=16),U(Q===(Q|0)&&Q>=2&&Q<=36),H=H.toString().replace(/\s+/g,"");var Z=0;H[0]==="-"&&(Z++,this.negative=1),Z<H.length&&(Q===16?this._parseHex(H,Z,P):(this._parseBase(H,Q,Z),P==="le"&&this._initArray(this.toArray(),Q,P)))},G.prototype._initNumber=function(H,Q,P){H<0&&(this.negative=1,H=-H),H<67108864?(this.words=[H&67108863],this.length=1):H<4503599627370496?(this.words=[H&67108863,H/67108864&67108863],this.length=2):(U(H<9007199254740992),this.words=[H&67108863,H/67108864&67108863,1],this.length=3),P==="le"&&this._initArray(this.toArray(),Q,P)},G.prototype._initArray=function(H,Q,P){if(U(typeof H.length=="number"),H.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(H.length/3),this.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var $,C,J=0;if(P==="be")for(Z=H.length-1,$=0;Z>=0;Z-=3)C=H[Z]|H[Z-1]<<8|H[Z-2]<<16,this.words[$]|=C<<J&67108863,this.words[$+1]=C>>>26-J&67108863,J+=24,J>=26&&(J-=26,$++);else if(P==="le")for(Z=0,$=0;Z<H.length;Z+=3)C=H[Z]|H[Z+1]<<8|H[Z+2]<<16,this.words[$]|=C<<J&67108863,this.words[$+1]=C>>>26-J&67108863,J+=24,J>=26&&(J-=26,$++);return this._strip()};function I(H,Q){var P=H.charCodeAt(Q);if(P>=48&&P<=57)return P-48;if(P>=65&&P<=70)return P-55;if(P>=97&&P<=102)return P-87;U(!1,"Invalid character in "+H)}function V(H,Q,P){var Z=I(H,P);return P-1>=Q&&(Z|=I(H,P-1)<<4),Z}G.prototype._parseHex=function(H,Q,P){this.length=Math.ceil((H.length-Q)/6),this.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var $=0,C=0,J;if(P==="be")for(Z=H.length-1;Z>=Q;Z-=2)J=V(H,Q,Z)<<$,this.words[C]|=J&67108863,$>=18?($-=18,C+=1,this.words[C]|=J>>>26):$+=8;else{var R=H.length-Q;for(Z=R%2===0?Q+1:Q;Z<H.length;Z+=2)J=V(H,Q,Z)<<$,this.words[C]|=J&67108863,$>=18?($-=18,C+=1,this.words[C]|=J>>>26):$+=8}this._strip()};function z(H,Q,P,Z){for(var $=0,C=0,J=Math.min(H.length,P),R=Q;R<J;R++){var L=H.charCodeAt(R)-48;$*=Z,L>=49?C=L-49+10:L>=17?C=L-17+10:C=L,U(L>=0&&C<Z,"Invalid character"),$+=C}return $}G.prototype._parseBase=function(H,Q,P){this.words=[0],this.length=1;for(var Z=0,$=1;$<=67108863;$*=Q)Z++;Z--,$=$/Q|0;for(var C=H.length-P,J=C%Z,R=Math.min(C,C-J)+P,L=0,_=P;_<R;_+=Z)L=z(H,_,_+Z,Q),this.imuln($),this.words[0]+L<67108864?this.words[0]+=L:this._iaddn(L);if(J!==0){var s=1;for(L=z(H,_,H.length,Q),_=0;_<J;_++)s*=Q;this.imuln(s),this.words[0]+L<67108864?this.words[0]+=L:this._iaddn(L)}this._strip()},G.prototype.copy=function(H){H.words=new Array(this.length);for(var Q=0;Q<this.length;Q++)H.words[Q]=this.words[Q];H.length=this.length,H.negative=this.negative,H.red=this.red};function F(H,Q){H.words=Q.words,H.length=Q.length,H.negative=Q.negative,H.red=Q.red}if(G.prototype._move=function(H){F(H,this)},G.prototype.clone=function(){var H=new G(null);return this.copy(H),H},G.prototype._expand=function(H){for(;this.length<H;)this.words[this.length++]=0;return this},G.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol<"u"&&typeof Symbol.for=="function")try{G.prototype[Symbol.for("nodejs.util.inspect.custom")]=O}catch{G.prototype.inspect=O}else G.prototype.inspect=O;function O(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var N=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],j=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],D=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(H,Q){H=H||10,Q=Q|0||1;var P;if(H===16||H==="hex"){P="";for(var Z=0,$=0,C=0;C<this.length;C++){var J=this.words[C],R=((J<<Z|$)&16777215).toString(16);$=J>>>24-Z&16777215,Z+=2,Z>=26&&(Z-=26,C--),$!==0||C!==this.length-1?P=N[6-R.length]+R+P:P=R+P}for($!==0&&(P=$.toString(16)+P);P.length%Q!==0;)P="0"+P;return this.negative!==0&&(P="-"+P),P}if(H===(H|0)&&H>=2&&H<=36){var L=j[H],_=D[H];P="";var s=this.clone();for(s.negative=0;!s.isZero();){var r=s.modrn(_).toString(H);s=s.idivn(_),s.isZero()?P=r+P:P=N[L-r.length]+r+P}for(this.isZero()&&(P="0"+P);P.length%Q!==0;)P="0"+P;return this.negative!==0&&(P="-"+P),P}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var H=this.words[0];return this.length===2?H+=this.words[1]*67108864:this.length===3&&this.words[2]===1?H+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-H:H},G.prototype.toJSON=function(){return this.toString(16,2)},W&&(G.prototype.toBuffer=function(H,Q){return this.toArrayLike(W,H,Q)}),G.prototype.toArray=function(H,Q){return this.toArrayLike(Array,H,Q)};var k=function(H,Q){return H.allocUnsafe?H.allocUnsafe(Q):new H(Q)};G.prototype.toArrayLike=function(H,Q,P){this._strip();var Z=this.byteLength(),$=P||Math.max(1,Z);U(Z<=$,"byte array longer than desired length"),U($>0,"Requested array length <= 0");var C=k(H,$),J=Q==="le"?"LE":"BE";return this["_toArrayLike"+J](C,Z),C},G.prototype._toArrayLikeLE=function(H,Q){for(var P=0,Z=0,$=0,C=0;$<this.length;$++){var J=this.words[$]<<C|Z;H[P++]=J&255,P<H.length&&(H[P++]=J>>8&255),P<H.length&&(H[P++]=J>>16&255),C===6?(P<H.length&&(H[P++]=J>>24&255),Z=0,C=0):(Z=J>>>24,C+=2)}if(P<H.length)for(H[P++]=Z;P<H.length;)H[P++]=0},G.prototype._toArrayLikeBE=function(H,Q){for(var P=H.length-1,Z=0,$=0,C=0;$<this.length;$++){var J=this.words[$]<<C|Z;H[P--]=J&255,P>=0&&(H[P--]=J>>8&255),P>=0&&(H[P--]=J>>16&255),C===6?(P>=0&&(H[P--]=J>>24&255),Z=0,C=0):(Z=J>>>24,C+=2)}if(P>=0)for(H[P--]=Z;P>=0;)H[P--]=0},Math.clz32?G.prototype._countBits=function(H){return 32-Math.clz32(H)}:G.prototype._countBits=function(H){var Q=H,P=0;return Q>=4096&&(P+=13,Q>>>=13),Q>=64&&(P+=7,Q>>>=7),Q>=8&&(P+=4,Q>>>=4),Q>=2&&(P+=2,Q>>>=2),P+Q},G.prototype._zeroBits=function(H){if(H===0)return 26;var Q=H,P=0;return(Q&8191)===0&&(P+=13,Q>>>=13),(Q&127)===0&&(P+=7,Q>>>=7),(Q&15)===0&&(P+=4,Q>>>=4),(Q&3)===0&&(P+=2,Q>>>=2),(Q&1)===0&&P++,P},G.prototype.bitLength=function(){var H=this.words[this.length-1],Q=this._countBits(H);return(this.length-1)*26+Q};function A(H){for(var Q=new Array(H.bitLength()),P=0;P<Q.length;P++){var Z=P/26|0,$=P%26;Q[P]=H.words[Z]>>>$&1}return Q}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var H=0,Q=0;Q<this.length;Q++){var P=this._zeroBits(this.words[Q]);if(H+=P,P!==26)break}return H},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(H){return this.negative!==0?this.abs().inotn(H).iaddn(1):this.clone()},G.prototype.fromTwos=function(H){return this.testn(H-1)?this.notn(H).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(H){for(;this.length<H.length;)this.words[this.length++]=0;for(var Q=0;Q<H.length;Q++)this.words[Q]=this.words[Q]|H.words[Q];return this._strip()},G.prototype.ior=function(H){return U((this.negative|H.negative)===0),this.iuor(H)},G.prototype.or=function(H){return this.length>H.length?this.clone().ior(H):H.clone().ior(this)},G.prototype.uor=function(H){return this.length>H.length?this.clone().iuor(H):H.clone().iuor(this)},G.prototype.iuand=function(H){var Q;this.length>H.length?Q=H:Q=this;for(var P=0;P<Q.length;P++)this.words[P]=this.words[P]&H.words[P];return this.length=Q.length,this._strip()},G.prototype.iand=function(H){return U((this.negative|H.negative)===0),this.iuand(H)},G.prototype.and=function(H){return this.length>H.length?this.clone().iand(H):H.clone().iand(this)},G.prototype.uand=function(H){return this.length>H.length?this.clone().iuand(H):H.clone().iuand(this)},G.prototype.iuxor=function(H){var Q,P;this.length>H.length?(Q=this,P=H):(Q=H,P=this);for(var Z=0;Z<P.length;Z++)this.words[Z]=Q.words[Z]^P.words[Z];if(this!==Q)for(;Z<Q.length;Z++)this.words[Z]=Q.words[Z];return this.length=Q.length,this._strip()},G.prototype.ixor=function(H){return U((this.negative|H.negative)===0),this.iuxor(H)},G.prototype.xor=function(H){return this.length>H.length?this.clone().ixor(H):H.clone().ixor(this)},G.prototype.uxor=function(H){return this.length>H.length?this.clone().iuxor(H):H.clone().iuxor(this)},G.prototype.inotn=function(H){U(typeof H=="number"&&H>=0);var Q=Math.ceil(H/26)|0,P=H%26;this._expand(Q),P>0&&Q--;for(var Z=0;Z<Q;Z++)this.words[Z]=~this.words[Z]&67108863;return P>0&&(this.words[Z]=~this.words[Z]&67108863>>26-P),this._strip()},G.prototype.notn=function(H){return this.clone().inotn(H)},G.prototype.setn=function(H,Q){U(typeof H=="number"&&H>=0);var P=H/26|0,Z=H%26;return this._expand(P+1),Q?this.words[P]=this.words[P]|1<<Z:this.words[P]=this.words[P]&~(1<<Z),this._strip()},G.prototype.iadd=function(H){var Q;if(this.negative!==0&&H.negative===0)return this.negative=0,Q=this.isub(H),this.negative^=1,this._normSign();if(this.negative===0&&H.negative!==0)return H.negative=0,Q=this.isub(H),H.negative=1,Q._normSign();var P,Z;this.length>H.length?(P=this,Z=H):(P=H,Z=this);for(var $=0,C=0;C<Z.length;C++)Q=(P.words[C]|0)+(Z.words[C]|0)+$,this.words[C]=Q&67108863,$=Q>>>26;for(;$!==0&&C<P.length;C++)Q=(P.words[C]|0)+$,this.words[C]=Q&67108863,$=Q>>>26;if(this.length=P.length,$!==0)this.words[this.length]=$,this.length++;else if(P!==this)for(;C<P.length;C++)this.words[C]=P.words[C];return this},G.prototype.add=function(H){var Q;return H.negative!==0&&this.negative===0?(H.negative=0,Q=this.sub(H),H.negative^=1,Q):H.negative===0&&this.negative!==0?(this.negative=0,Q=H.sub(this),this.negative=1,Q):this.length>H.length?this.clone().iadd(H):H.clone().iadd(this)},G.prototype.isub=function(H){if(H.negative!==0){H.negative=0;var Q=this.iadd(H);return H.negative=1,Q._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(H),this.negative=1,this._normSign();var P=this.cmp(H);if(P===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Z,$;P>0?(Z=this,$=H):(Z=H,$=this);for(var C=0,J=0;J<$.length;J++)Q=(Z.words[J]|0)-($.words[J]|0)+C,C=Q>>26,this.words[J]=Q&67108863;for(;C!==0&&J<Z.length;J++)Q=(Z.words[J]|0)+C,C=Q>>26,this.words[J]=Q&67108863;if(C===0&&J<Z.length&&Z!==this)for(;J<Z.length;J++)this.words[J]=Z.words[J];return this.length=Math.max(this.length,J),Z!==this&&(this.negative=1),this._strip()},G.prototype.sub=function(H){return this.clone().isub(H)};function x(H,Q,P){P.negative=Q.negative^H.negative;var Z=H.length+Q.length|0;P.length=Z,Z=Z-1|0;var $=H.words[0]|0,C=Q.words[0]|0,J=$*C,R=J&67108863,L=J/67108864|0;P.words[0]=R;for(var _=1;_<Z;_++){for(var s=L>>>26,r=L&67108863,X0=Math.min(_,Q.length-1),u=Math.max(0,_-H.length+1);u<=X0;u++){var d=_-u|0;$=H.words[d]|0,C=Q.words[u]|0,J=$*C+r,s+=J/67108864|0,r=J&67108863}P.words[_]=r|0,L=s|0}return L!==0?P.words[_]=L|0:P.length--,P._strip()}var v=function(H,Q,P){var Z=H.words,$=Q.words,C=P.words,J=0,R,L,_,s=Z[0]|0,r=s&8191,X0=s>>>13,u=Z[1]|0,d=u&8191,f=u>>>13,z0=Z[2]|0,K0=z0&8191,Q0=z0>>>13,w=Z[3]|0,q=w&8191,m=w>>>13,e=Z[4]|0,C0=e&8191,t=e>>>13,_0=Z[5]|0,$0=_0&8191,J0=_0>>>13,w0=Z[6]|0,j0=w0&8191,Z0=w0>>>13,c0=Z[7]|0,T=c0&8191,B=c0>>>13,b=Z[8]|0,h=b&8191,o=b>>>13,O0=Z[9]|0,Y0=O0&8191,F0=O0>>>13,b0=$[0]|0,W0=b0&8191,U0=b0>>>13,y0=$[1]|0,D0=y0&8191,N0=y0>>>13,G5=$[2]|0,T0=G5&8191,V0=G5>>>13,l0=$[3]|0,L0=l0&8191,I0=l0>>>13,J5=$[4]|0,k0=J5&8191,q0=J5>>>13,P5=$[5]|0,B0=P5&8191,R0=P5>>>13,Z5=$[6]|0,E0=Z5&8191,S0=Z5>>>13,F5=$[7]|0,x0=F5&8191,A0=F5>>>13,U5=$[8]|0,v0=U5&8191,M0=U5>>>13,$5=$[9]|0,g0=$5&8191,m0=$5>>>13;P.negative=H.negative^Q.negative,P.length=19,R=Math.imul(r,W0),L=Math.imul(r,U0),L=L+Math.imul(X0,W0)|0,_=Math.imul(X0,U0);var u0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(u0>>>26)|0,u0&=67108863,R=Math.imul(d,W0),L=Math.imul(d,U0),L=L+Math.imul(f,W0)|0,_=Math.imul(f,U0),R=R+Math.imul(r,D0)|0,L=L+Math.imul(r,N0)|0,L=L+Math.imul(X0,D0)|0,_=_+Math.imul(X0,N0)|0;var o0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(o0>>>26)|0,o0&=67108863,R=Math.imul(K0,W0),L=Math.imul(K0,U0),L=L+Math.imul(Q0,W0)|0,_=Math.imul(Q0,U0),R=R+Math.imul(d,D0)|0,L=L+Math.imul(d,N0)|0,L=L+Math.imul(f,D0)|0,_=_+Math.imul(f,N0)|0,R=R+Math.imul(r,T0)|0,L=L+Math.imul(r,V0)|0,L=L+Math.imul(X0,T0)|0,_=_+Math.imul(X0,V0)|0;var s0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(s0>>>26)|0,s0&=67108863,R=Math.imul(q,W0),L=Math.imul(q,U0),L=L+Math.imul(m,W0)|0,_=Math.imul(m,U0),R=R+Math.imul(K0,D0)|0,L=L+Math.imul(K0,N0)|0,L=L+Math.imul(Q0,D0)|0,_=_+Math.imul(Q0,N0)|0,R=R+Math.imul(d,T0)|0,L=L+Math.imul(d,V0)|0,L=L+Math.imul(f,T0)|0,_=_+Math.imul(f,V0)|0,R=R+Math.imul(r,L0)|0,L=L+Math.imul(r,I0)|0,L=L+Math.imul(X0,L0)|0,_=_+Math.imul(X0,I0)|0;var a0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(a0>>>26)|0,a0&=67108863,R=Math.imul(C0,W0),L=Math.imul(C0,U0),L=L+Math.imul(t,W0)|0,_=Math.imul(t,U0),R=R+Math.imul(q,D0)|0,L=L+Math.imul(q,N0)|0,L=L+Math.imul(m,D0)|0,_=_+Math.imul(m,N0)|0,R=R+Math.imul(K0,T0)|0,L=L+Math.imul(K0,V0)|0,L=L+Math.imul(Q0,T0)|0,_=_+Math.imul(Q0,V0)|0,R=R+Math.imul(d,L0)|0,L=L+Math.imul(d,I0)|0,L=L+Math.imul(f,L0)|0,_=_+Math.imul(f,I0)|0,R=R+Math.imul(r,k0)|0,L=L+Math.imul(r,q0)|0,L=L+Math.imul(X0,k0)|0,_=_+Math.imul(X0,q0)|0;var f0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(f0>>>26)|0,f0&=67108863,R=Math.imul($0,W0),L=Math.imul($0,U0),L=L+Math.imul(J0,W0)|0,_=Math.imul(J0,U0),R=R+Math.imul(C0,D0)|0,L=L+Math.imul(C0,N0)|0,L=L+Math.imul(t,D0)|0,_=_+Math.imul(t,N0)|0,R=R+Math.imul(q,T0)|0,L=L+Math.imul(q,V0)|0,L=L+Math.imul(m,T0)|0,_=_+Math.imul(m,V0)|0,R=R+Math.imul(K0,L0)|0,L=L+Math.imul(K0,I0)|0,L=L+Math.imul(Q0,L0)|0,_=_+Math.imul(Q0,I0)|0,R=R+Math.imul(d,k0)|0,L=L+Math.imul(d,q0)|0,L=L+Math.imul(f,k0)|0,_=_+Math.imul(f,q0)|0,R=R+Math.imul(r,B0)|0,L=L+Math.imul(r,R0)|0,L=L+Math.imul(X0,B0)|0,_=_+Math.imul(X0,R0)|0;var n0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(n0>>>26)|0,n0&=67108863,R=Math.imul(j0,W0),L=Math.imul(j0,U0),L=L+Math.imul(Z0,W0)|0,_=Math.imul(Z0,U0),R=R+Math.imul($0,D0)|0,L=L+Math.imul($0,N0)|0,L=L+Math.imul(J0,D0)|0,_=_+Math.imul(J0,N0)|0,R=R+Math.imul(C0,T0)|0,L=L+Math.imul(C0,V0)|0,L=L+Math.imul(t,T0)|0,_=_+Math.imul(t,V0)|0,R=R+Math.imul(q,L0)|0,L=L+Math.imul(q,I0)|0,L=L+Math.imul(m,L0)|0,_=_+Math.imul(m,I0)|0,R=R+Math.imul(K0,k0)|0,L=L+Math.imul(K0,q0)|0,L=L+Math.imul(Q0,k0)|0,_=_+Math.imul(Q0,q0)|0,R=R+Math.imul(d,B0)|0,L=L+Math.imul(d,R0)|0,L=L+Math.imul(f,B0)|0,_=_+Math.imul(f,R0)|0,R=R+Math.imul(r,E0)|0,L=L+Math.imul(r,S0)|0,L=L+Math.imul(X0,E0)|0,_=_+Math.imul(X0,S0)|0;var r0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(r0>>>26)|0,r0&=67108863,R=Math.imul(T,W0),L=Math.imul(T,U0),L=L+Math.imul(B,W0)|0,_=Math.imul(B,U0),R=R+Math.imul(j0,D0)|0,L=L+Math.imul(j0,N0)|0,L=L+Math.imul(Z0,D0)|0,_=_+Math.imul(Z0,N0)|0,R=R+Math.imul($0,T0)|0,L=L+Math.imul($0,V0)|0,L=L+Math.imul(J0,T0)|0,_=_+Math.imul(J0,V0)|0,R=R+Math.imul(C0,L0)|0,L=L+Math.imul(C0,I0)|0,L=L+Math.imul(t,L0)|0,_=_+Math.imul(t,I0)|0,R=R+Math.imul(q,k0)|0,L=L+Math.imul(q,q0)|0,L=L+Math.imul(m,k0)|0,_=_+Math.imul(m,q0)|0,R=R+Math.imul(K0,B0)|0,L=L+Math.imul(K0,R0)|0,L=L+Math.imul(Q0,B0)|0,_=_+Math.imul(Q0,R0)|0,R=R+Math.imul(d,E0)|0,L=L+Math.imul(d,S0)|0,L=L+Math.imul(f,E0)|0,_=_+Math.imul(f,S0)|0,R=R+Math.imul(r,x0)|0,L=L+Math.imul(r,A0)|0,L=L+Math.imul(X0,x0)|0,_=_+Math.imul(X0,A0)|0;var i0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(i0>>>26)|0,i0&=67108863,R=Math.imul(h,W0),L=Math.imul(h,U0),L=L+Math.imul(o,W0)|0,_=Math.imul(o,U0),R=R+Math.imul(T,D0)|0,L=L+Math.imul(T,N0)|0,L=L+Math.imul(B,D0)|0,_=_+Math.imul(B,N0)|0,R=R+Math.imul(j0,T0)|0,L=L+Math.imul(j0,V0)|0,L=L+Math.imul(Z0,T0)|0,_=_+Math.imul(Z0,V0)|0,R=R+Math.imul($0,L0)|0,L=L+Math.imul($0,I0)|0,L=L+Math.imul(J0,L0)|0,_=_+Math.imul(J0,I0)|0,R=R+Math.imul(C0,k0)|0,L=L+Math.imul(C0,q0)|0,L=L+Math.imul(t,k0)|0,_=_+Math.imul(t,q0)|0,R=R+Math.imul(q,B0)|0,L=L+Math.imul(q,R0)|0,L=L+Math.imul(m,B0)|0,_=_+Math.imul(m,R0)|0,R=R+Math.imul(K0,E0)|0,L=L+Math.imul(K0,S0)|0,L=L+Math.imul(Q0,E0)|0,_=_+Math.imul(Q0,S0)|0,R=R+Math.imul(d,x0)|0,L=L+Math.imul(d,A0)|0,L=L+Math.imul(f,x0)|0,_=_+Math.imul(f,A0)|0,R=R+Math.imul(r,v0)|0,L=L+Math.imul(r,M0)|0,L=L+Math.imul(X0,v0)|0,_=_+Math.imul(X0,M0)|0;var t0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(t0>>>26)|0,t0&=67108863,R=Math.imul(Y0,W0),L=Math.imul(Y0,U0),L=L+Math.imul(F0,W0)|0,_=Math.imul(F0,U0),R=R+Math.imul(h,D0)|0,L=L+Math.imul(h,N0)|0,L=L+Math.imul(o,D0)|0,_=_+Math.imul(o,N0)|0,R=R+Math.imul(T,T0)|0,L=L+Math.imul(T,V0)|0,L=L+Math.imul(B,T0)|0,_=_+Math.imul(B,V0)|0,R=R+Math.imul(j0,L0)|0,L=L+Math.imul(j0,I0)|0,L=L+Math.imul(Z0,L0)|0,_=_+Math.imul(Z0,I0)|0,R=R+Math.imul($0,k0)|0,L=L+Math.imul($0,q0)|0,L=L+Math.imul(J0,k0)|0,_=_+Math.imul(J0,q0)|0,R=R+Math.imul(C0,B0)|0,L=L+Math.imul(C0,R0)|0,L=L+Math.imul(t,B0)|0,_=_+Math.imul(t,R0)|0,R=R+Math.imul(q,E0)|0,L=L+Math.imul(q,S0)|0,L=L+Math.imul(m,E0)|0,_=_+Math.imul(m,S0)|0,R=R+Math.imul(K0,x0)|0,L=L+Math.imul(K0,A0)|0,L=L+Math.imul(Q0,x0)|0,_=_+Math.imul(Q0,A0)|0,R=R+Math.imul(d,v0)|0,L=L+Math.imul(d,M0)|0,L=L+Math.imul(f,v0)|0,_=_+Math.imul(f,M0)|0,R=R+Math.imul(r,g0)|0,L=L+Math.imul(r,m0)|0,L=L+Math.imul(X0,g0)|0,_=_+Math.imul(X0,m0)|0;var e0=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(e0>>>26)|0,e0&=67108863,R=Math.imul(Y0,D0),L=Math.imul(Y0,N0),L=L+Math.imul(F0,D0)|0,_=Math.imul(F0,N0),R=R+Math.imul(h,T0)|0,L=L+Math.imul(h,V0)|0,L=L+Math.imul(o,T0)|0,_=_+Math.imul(o,V0)|0,R=R+Math.imul(T,L0)|0,L=L+Math.imul(T,I0)|0,L=L+Math.imul(B,L0)|0,_=_+Math.imul(B,I0)|0,R=R+Math.imul(j0,k0)|0,L=L+Math.imul(j0,q0)|0,L=L+Math.imul(Z0,k0)|0,_=_+Math.imul(Z0,q0)|0,R=R+Math.imul($0,B0)|0,L=L+Math.imul($0,R0)|0,L=L+Math.imul(J0,B0)|0,_=_+Math.imul(J0,R0)|0,R=R+Math.imul(C0,E0)|0,L=L+Math.imul(C0,S0)|0,L=L+Math.imul(t,E0)|0,_=_+Math.imul(t,S0)|0,R=R+Math.imul(q,x0)|0,L=L+Math.imul(q,A0)|0,L=L+Math.imul(m,x0)|0,_=_+Math.imul(m,A0)|0,R=R+Math.imul(K0,v0)|0,L=L+Math.imul(K0,M0)|0,L=L+Math.imul(Q0,v0)|0,_=_+Math.imul(Q0,M0)|0,R=R+Math.imul(d,g0)|0,L=L+Math.imul(d,m0)|0,L=L+Math.imul(f,g0)|0,_=_+Math.imul(f,m0)|0;var K5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(K5>>>26)|0,K5&=67108863,R=Math.imul(Y0,T0),L=Math.imul(Y0,V0),L=L+Math.imul(F0,T0)|0,_=Math.imul(F0,V0),R=R+Math.imul(h,L0)|0,L=L+Math.imul(h,I0)|0,L=L+Math.imul(o,L0)|0,_=_+Math.imul(o,I0)|0,R=R+Math.imul(T,k0)|0,L=L+Math.imul(T,q0)|0,L=L+Math.imul(B,k0)|0,_=_+Math.imul(B,q0)|0,R=R+Math.imul(j0,B0)|0,L=L+Math.imul(j0,R0)|0,L=L+Math.imul(Z0,B0)|0,_=_+Math.imul(Z0,R0)|0,R=R+Math.imul($0,E0)|0,L=L+Math.imul($0,S0)|0,L=L+Math.imul(J0,E0)|0,_=_+Math.imul(J0,S0)|0,R=R+Math.imul(C0,x0)|0,L=L+Math.imul(C0,A0)|0,L=L+Math.imul(t,x0)|0,_=_+Math.imul(t,A0)|0,R=R+Math.imul(q,v0)|0,L=L+Math.imul(q,M0)|0,L=L+Math.imul(m,v0)|0,_=_+Math.imul(m,M0)|0,R=R+Math.imul(K0,g0)|0,L=L+Math.imul(K0,m0)|0,L=L+Math.imul(Q0,g0)|0,_=_+Math.imul(Q0,m0)|0;var C5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(C5>>>26)|0,C5&=67108863,R=Math.imul(Y0,L0),L=Math.imul(Y0,I0),L=L+Math.imul(F0,L0)|0,_=Math.imul(F0,I0),R=R+Math.imul(h,k0)|0,L=L+Math.imul(h,q0)|0,L=L+Math.imul(o,k0)|0,_=_+Math.imul(o,q0)|0,R=R+Math.imul(T,B0)|0,L=L+Math.imul(T,R0)|0,L=L+Math.imul(B,B0)|0,_=_+Math.imul(B,R0)|0,R=R+Math.imul(j0,E0)|0,L=L+Math.imul(j0,S0)|0,L=L+Math.imul(Z0,E0)|0,_=_+Math.imul(Z0,S0)|0,R=R+Math.imul($0,x0)|0,L=L+Math.imul($0,A0)|0,L=L+Math.imul(J0,x0)|0,_=_+Math.imul(J0,A0)|0,R=R+Math.imul(C0,v0)|0,L=L+Math.imul(C0,M0)|0,L=L+Math.imul(t,v0)|0,_=_+Math.imul(t,M0)|0,R=R+Math.imul(q,g0)|0,L=L+Math.imul(q,m0)|0,L=L+Math.imul(m,g0)|0,_=_+Math.imul(m,m0)|0;var X5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(X5>>>26)|0,X5&=67108863,R=Math.imul(Y0,k0),L=Math.imul(Y0,q0),L=L+Math.imul(F0,k0)|0,_=Math.imul(F0,q0),R=R+Math.imul(h,B0)|0,L=L+Math.imul(h,R0)|0,L=L+Math.imul(o,B0)|0,_=_+Math.imul(o,R0)|0,R=R+Math.imul(T,E0)|0,L=L+Math.imul(T,S0)|0,L=L+Math.imul(B,E0)|0,_=_+Math.imul(B,S0)|0,R=R+Math.imul(j0,x0)|0,L=L+Math.imul(j0,A0)|0,L=L+Math.imul(Z0,x0)|0,_=_+Math.imul(Z0,A0)|0,R=R+Math.imul($0,v0)|0,L=L+Math.imul($0,M0)|0,L=L+Math.imul(J0,v0)|0,_=_+Math.imul(J0,M0)|0,R=R+Math.imul(C0,g0)|0,L=L+Math.imul(C0,m0)|0,L=L+Math.imul(t,g0)|0,_=_+Math.imul(t,m0)|0;var H5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(H5>>>26)|0,H5&=67108863,R=Math.imul(Y0,B0),L=Math.imul(Y0,R0),L=L+Math.imul(F0,B0)|0,_=Math.imul(F0,R0),R=R+Math.imul(h,E0)|0,L=L+Math.imul(h,S0)|0,L=L+Math.imul(o,E0)|0,_=_+Math.imul(o,S0)|0,R=R+Math.imul(T,x0)|0,L=L+Math.imul(T,A0)|0,L=L+Math.imul(B,x0)|0,_=_+Math.imul(B,A0)|0,R=R+Math.imul(j0,v0)|0,L=L+Math.imul(j0,M0)|0,L=L+Math.imul(Z0,v0)|0,_=_+Math.imul(Z0,M0)|0,R=R+Math.imul($0,g0)|0,L=L+Math.imul($0,m0)|0,L=L+Math.imul(J0,g0)|0,_=_+Math.imul(J0,m0)|0;var Y5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,R=Math.imul(Y0,E0),L=Math.imul(Y0,S0),L=L+Math.imul(F0,E0)|0,_=Math.imul(F0,S0),R=R+Math.imul(h,x0)|0,L=L+Math.imul(h,A0)|0,L=L+Math.imul(o,x0)|0,_=_+Math.imul(o,A0)|0,R=R+Math.imul(T,v0)|0,L=L+Math.imul(T,M0)|0,L=L+Math.imul(B,v0)|0,_=_+Math.imul(B,M0)|0,R=R+Math.imul(j0,g0)|0,L=L+Math.imul(j0,m0)|0,L=L+Math.imul(Z0,g0)|0,_=_+Math.imul(Z0,m0)|0;var Q5=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,R=Math.imul(Y0,x0),L=Math.imul(Y0,A0),L=L+Math.imul(F0,x0)|0,_=Math.imul(F0,A0),R=R+Math.imul(h,v0)|0,L=L+Math.imul(h,M0)|0,L=L+Math.imul(o,v0)|0,_=_+Math.imul(o,M0)|0,R=R+Math.imul(T,g0)|0,L=L+Math.imul(T,m0)|0,L=L+Math.imul(B,g0)|0,_=_+Math.imul(B,m0)|0;var Y9=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(Y9>>>26)|0,Y9&=67108863,R=Math.imul(Y0,v0),L=Math.imul(Y0,M0),L=L+Math.imul(F0,v0)|0,_=Math.imul(F0,M0),R=R+Math.imul(h,g0)|0,L=L+Math.imul(h,m0)|0,L=L+Math.imul(o,g0)|0,_=_+Math.imul(o,m0)|0;var Q9=(J+R|0)+((L&8191)<<13)|0;J=(_+(L>>>13)|0)+(Q9>>>26)|0,Q9&=67108863,R=Math.imul(Y0,g0),L=Math.imul(Y0,m0),L=L+Math.imul(F0,g0)|0,_=Math.imul(F0,m0);var $9=(J+R|0)+((L&8191)<<13)|0;return J=(_+(L>>>13)|0)+($9>>>26)|0,$9&=67108863,C[0]=u0,C[1]=o0,C[2]=s0,C[3]=a0,C[4]=f0,C[5]=n0,C[6]=r0,C[7]=i0,C[8]=t0,C[9]=e0,C[10]=K5,C[11]=C5,C[12]=X5,C[13]=H5,C[14]=Y5,C[15]=Q5,C[16]=Y9,C[17]=Q9,C[18]=$9,J!==0&&(C[19]=J,P.length++),P};Math.imul||(v=x);function y(H,Q,P){P.negative=Q.negative^H.negative,P.length=H.length+Q.length;for(var Z=0,$=0,C=0;C<P.length-1;C++){var J=$;$=0;for(var R=Z&67108863,L=Math.min(C,Q.length-1),_=Math.max(0,C-H.length+1);_<=L;_++){var s=C-_,r=H.words[s]|0,X0=Q.words[_]|0,u=r*X0,d=u&67108863;J=J+(u/67108864|0)|0,d=d+R|0,R=d&67108863,J=J+(d>>>26)|0,$+=J>>>26,J&=67108863}P.words[C]=R,Z=J,J=$}return Z!==0?P.words[C]=Z:P.length--,P._strip()}function p(H,Q,P){return y(H,Q,P)}G.prototype.mulTo=function(H,Q){var P,Z=this.length+H.length;return this.length===10&&H.length===10?P=v(this,H,Q):Z<63?P=x(this,H,Q):Z<1024?P=y(this,H,Q):P=p(this,H,Q),P};function c(H,Q){this.x=H,this.y=Q}c.prototype.makeRBT=function(H){for(var Q=new Array(H),P=G.prototype._countBits(H)-1,Z=0;Z<H;Z++)Q[Z]=this.revBin(Z,P,H);return Q},c.prototype.revBin=function(H,Q,P){if(H===0||H===P-1)return H;for(var Z=0,$=0;$<Q;$++)Z|=(H&1)<<Q-$-1,H>>=1;return Z},c.prototype.permute=function(H,Q,P,Z,$,C){for(var J=0;J<C;J++)Z[J]=Q[H[J]],$[J]=P[H[J]]},c.prototype.transform=function(H,Q,P,Z,$,C){this.permute(C,H,Q,P,Z,$);for(var J=1;J<$;J<<=1)for(var R=J<<1,L=Math.cos(2*Math.PI/R),_=Math.sin(2*Math.PI/R),s=0;s<$;s+=R)for(var r=L,X0=_,u=0;u<J;u++){var d=P[s+u],f=Z[s+u],z0=P[s+u+J],K0=Z[s+u+J],Q0=r*z0-X0*K0;K0=r*K0+X0*z0,z0=Q0,P[s+u]=d+z0,Z[s+u]=f+K0,P[s+u+J]=d-z0,Z[s+u+J]=f-K0,u!==R&&(Q0=L*r-_*X0,X0=L*X0+_*r,r=Q0)}},c.prototype.guessLen13b=function(H,Q){var P=Math.max(Q,H)|1,Z=P&1,$=0;for(P=P/2|0;P;P=P>>>1)$++;return 1<<$+1+Z},c.prototype.conjugate=function(H,Q,P){if(!(P<=1))for(var Z=0;Z<P/2;Z++){var $=H[Z];H[Z]=H[P-Z-1],H[P-Z-1]=$,$=Q[Z],Q[Z]=-Q[P-Z-1],Q[P-Z-1]=-$}},c.prototype.normalize13b=function(H,Q){for(var P=0,Z=0;Z<Q/2;Z++){var $=Math.round(H[2*Z+1]/Q)*8192+Math.round(H[2*Z]/Q)+P;H[Z]=$&67108863,$<67108864?P=0:P=$/67108864|0}return H},c.prototype.convert13b=function(H,Q,P,Z){for(var $=0,C=0;C<Q;C++)$=$+(H[C]|0),P[2*C]=$&8191,$=$>>>13,P[2*C+1]=$&8191,$=$>>>13;for(C=2*Q;C<Z;++C)P[C]=0;U($===0),U(($&-8192)===0)},c.prototype.stub=function(H){for(var Q=new Array(H),P=0;P<H;P++)Q[P]=0;return Q},c.prototype.mulp=function(H,Q,P){var Z=2*this.guessLen13b(H.length,Q.length),$=this.makeRBT(Z),C=this.stub(Z),J=new Array(Z),R=new Array(Z),L=new Array(Z),_=new Array(Z),s=new Array(Z),r=new Array(Z),X0=P.words;X0.length=Z,this.convert13b(H.words,H.length,J,Z),this.convert13b(Q.words,Q.length,_,Z),this.transform(J,C,R,L,Z,$),this.transform(_,C,s,r,Z,$);for(var u=0;u<Z;u++){var d=R[u]*s[u]-L[u]*r[u];L[u]=R[u]*r[u]+L[u]*s[u],R[u]=d}return this.conjugate(R,L,Z),this.transform(R,L,X0,C,Z,$),this.conjugate(X0,C,Z),this.normalize13b(X0,Z),P.negative=H.negative^Q.negative,P.length=H.length+Q.length,P._strip()},G.prototype.mul=function(H){var Q=new G(null);return Q.words=new Array(this.length+H.length),this.mulTo(H,Q)},G.prototype.mulf=function(H){var Q=new G(null);return Q.words=new Array(this.length+H.length),p(this,H,Q)},G.prototype.imul=function(H){return this.clone().mulTo(H,this)},G.prototype.imuln=function(H){var Q=H<0;Q&&(H=-H),U(typeof H=="number"),U(H<67108864);for(var P=0,Z=0;Z<this.length;Z++){var $=(this.words[Z]|0)*H,C=($&67108863)+(P&67108863);P>>=26,P+=$/67108864|0,P+=C>>>26,this.words[Z]=C&67108863}return P!==0&&(this.words[Z]=P,this.length++),Q?this.ineg():this},G.prototype.muln=function(H){return this.clone().imuln(H)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(H){var Q=A(H);if(Q.length===0)return new G(1);for(var P=this,Z=0;Z<Q.length&&Q[Z]===0;Z++,P=P.sqr());if(++Z<Q.length)for(var $=P.sqr();Z<Q.length;Z++,$=$.sqr())Q[Z]!==0&&(P=P.mul($));return P},G.prototype.iushln=function(H){U(typeof H=="number"&&H>=0);var Q=H%26,P=(H-Q)/26,Z=67108863>>>26-Q<<26-Q,$;if(Q!==0){var C=0;for($=0;$<this.length;$++){var J=this.words[$]&Z,R=(this.words[$]|0)-J<<Q;this.words[$]=R|C,C=J>>>26-Q}C&&(this.words[$]=C,this.length++)}if(P!==0){for($=this.length-1;$>=0;$--)this.words[$+P]=this.words[$];for($=0;$<P;$++)this.words[$]=0;this.length+=P}return this._strip()},G.prototype.ishln=function(H){return U(this.negative===0),this.iushln(H)},G.prototype.iushrn=function(H,Q,P){U(typeof H=="number"&&H>=0);var Z;Q?Z=(Q-Q%26)/26:Z=0;var $=H%26,C=Math.min((H-$)/26,this.length),J=67108863^67108863>>>$<<$,R=P;if(Z-=C,Z=Math.max(0,Z),R){for(var L=0;L<C;L++)R.words[L]=this.words[L];R.length=C}if(C!==0)if(this.length>C)for(this.length-=C,L=0;L<this.length;L++)this.words[L]=this.words[L+C];else this.words[0]=0,this.length=1;var _=0;for(L=this.length-1;L>=0&&(_!==0||L>=Z);L--){var s=this.words[L]|0;this.words[L]=_<<26-$|s>>>$,_=s&J}return R&&_!==0&&(R.words[R.length++]=_),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},G.prototype.ishrn=function(H,Q,P){return U(this.negative===0),this.iushrn(H,Q,P)},G.prototype.shln=function(H){return this.clone().ishln(H)},G.prototype.ushln=function(H){return this.clone().iushln(H)},G.prototype.shrn=function(H){return this.clone().ishrn(H)},G.prototype.ushrn=function(H){return this.clone().iushrn(H)},G.prototype.testn=function(H){U(typeof H=="number"&&H>=0);var Q=H%26,P=(H-Q)/26,Z=1<<Q;if(this.length<=P)return!1;var $=this.words[P];return!!($&Z)},G.prototype.imaskn=function(H){U(typeof H=="number"&&H>=0);var Q=H%26,P=(H-Q)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=P)return this;if(Q!==0&&P++,this.length=Math.min(P,this.length),Q!==0){var Z=67108863^67108863>>>Q<<Q;this.words[this.length-1]&=Z}return this._strip()},G.prototype.maskn=function(H){return this.clone().imaskn(H)},G.prototype.iaddn=function(H){return U(typeof H=="number"),U(H<67108864),H<0?this.isubn(-H):this.negative!==0?this.length===1&&(this.words[0]|0)<=H?(this.words[0]=H-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(H),this.negative=1,this):this._iaddn(H)},G.prototype._iaddn=function(H){this.words[0]+=H;for(var Q=0;Q<this.length&&this.words[Q]>=67108864;Q++)this.words[Q]-=67108864,Q===this.length-1?this.words[Q+1]=1:this.words[Q+1]++;return this.length=Math.max(this.length,Q+1),this},G.prototype.isubn=function(H){if(U(typeof H=="number"),U(H<67108864),H<0)return this.iaddn(-H);if(this.negative!==0)return this.negative=0,this.iaddn(H),this.negative=1,this;if(this.words[0]-=H,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Q=0;Q<this.length&&this.words[Q]<0;Q++)this.words[Q]+=67108864,this.words[Q+1]-=1;return this._strip()},G.prototype.addn=function(H){return this.clone().iaddn(H)},G.prototype.subn=function(H){return this.clone().isubn(H)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(H,Q,P){var Z=H.length+P,$;this._expand(Z);var C,J=0;for($=0;$<H.length;$++){C=(this.words[$+P]|0)+J;var R=(H.words[$]|0)*Q;C-=R&67108863,J=(C>>26)-(R/67108864|0),this.words[$+P]=C&67108863}for(;$<this.length-P;$++)C=(this.words[$+P]|0)+J,J=C>>26,this.words[$+P]=C&67108863;if(J===0)return this._strip();for(U(J===-1),J=0,$=0;$<this.length;$++)C=-(this.words[$]|0)+J,J=C>>26,this.words[$]=C&67108863;return this.negative=1,this._strip()},G.prototype._wordDiv=function(H,Q){var P=this.length-H.length,Z=this.clone(),$=H,C=$.words[$.length-1]|0,J=this._countBits(C);P=26-J,P!==0&&($=$.ushln(P),Z.iushln(P),C=$.words[$.length-1]|0);var R=Z.length-$.length,L;if(Q!=="mod"){L=new G(null),L.length=R+1,L.words=new Array(L.length);for(var _=0;_<L.length;_++)L.words[_]=0}var s=Z.clone()._ishlnsubmul($,1,R);s.negative===0&&(Z=s,L&&(L.words[R]=1));for(var r=R-1;r>=0;r--){var X0=(Z.words[$.length+r]|0)*67108864+(Z.words[$.length+r-1]|0);for(X0=Math.min(X0/C|0,67108863),Z._ishlnsubmul($,X0,r);Z.negative!==0;)X0--,Z.negative=0,Z._ishlnsubmul($,1,r),Z.isZero()||(Z.negative^=1);L&&(L.words[r]=X0)}return L&&L._strip(),Z._strip(),Q!=="div"&&P!==0&&Z.iushrn(P),{div:L||null,mod:Z}},G.prototype.divmod=function(H,Q,P){if(U(!H.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var Z,$,C;return this.negative!==0&&H.negative===0?(C=this.neg().divmod(H,Q),Q!=="mod"&&(Z=C.div.neg()),Q!=="div"&&($=C.mod.neg(),P&&$.negative!==0&&$.iadd(H)),{div:Z,mod:$}):this.negative===0&&H.negative!==0?(C=this.divmod(H.neg(),Q),Q!=="mod"&&(Z=C.div.neg()),{div:Z,mod:C.mod}):(this.negative&H.negative)!==0?(C=this.neg().divmod(H.neg(),Q),Q!=="div"&&($=C.mod.neg(),P&&$.negative!==0&&$.isub(H)),{div:C.div,mod:$}):H.length>this.length||this.cmp(H)<0?{div:new G(0),mod:this}:H.length===1?Q==="div"?{div:this.divn(H.words[0]),mod:null}:Q==="mod"?{div:null,mod:new G(this.modrn(H.words[0]))}:{div:this.divn(H.words[0]),mod:new G(this.modrn(H.words[0]))}:this._wordDiv(H,Q)},G.prototype.div=function(H){return this.divmod(H,"div",!1).div},G.prototype.mod=function(H){return this.divmod(H,"mod",!1).mod},G.prototype.umod=function(H){return this.divmod(H,"mod",!0).mod},G.prototype.divRound=function(H){var Q=this.divmod(H);if(Q.mod.isZero())return Q.div;var P=Q.div.negative!==0?Q.mod.isub(H):Q.mod,Z=H.ushrn(1),$=H.andln(1),C=P.cmp(Z);return C<0||$===1&&C===0?Q.div:Q.div.negative!==0?Q.div.isubn(1):Q.div.iaddn(1)},G.prototype.modrn=function(H){var Q=H<0;Q&&(H=-H),U(H<=67108863);for(var P=67108864%H,Z=0,$=this.length-1;$>=0;$--)Z=(P*Z+(this.words[$]|0))%H;return Q?-Z:Z},G.prototype.modn=function(H){return this.modrn(H)},G.prototype.idivn=function(H){var Q=H<0;Q&&(H=-H),U(H<=67108863);for(var P=0,Z=this.length-1;Z>=0;Z--){var $=(this.words[Z]|0)+P*67108864;this.words[Z]=$/H|0,P=$%H}return this._strip(),Q?this.ineg():this},G.prototype.divn=function(H){return this.clone().idivn(H)},G.prototype.egcd=function(H){U(H.negative===0),U(!H.isZero());var Q=this,P=H.clone();Q.negative!==0?Q=Q.umod(H):Q=Q.clone();for(var Z=new G(1),$=new G(0),C=new G(0),J=new G(1),R=0;Q.isEven()&&P.isEven();)Q.iushrn(1),P.iushrn(1),++R;for(var L=P.clone(),_=Q.clone();!Q.isZero();){for(var s=0,r=1;(Q.words[0]&r)===0&&s<26;++s,r<<=1);if(s>0)for(Q.iushrn(s);s-- >0;)(Z.isOdd()||$.isOdd())&&(Z.iadd(L),$.isub(_)),Z.iushrn(1),$.iushrn(1);for(var X0=0,u=1;(P.words[0]&u)===0&&X0<26;++X0,u<<=1);if(X0>0)for(P.iushrn(X0);X0-- >0;)(C.isOdd()||J.isOdd())&&(C.iadd(L),J.isub(_)),C.iushrn(1),J.iushrn(1);Q.cmp(P)>=0?(Q.isub(P),Z.isub(C),$.isub(J)):(P.isub(Q),C.isub(Z),J.isub($))}return{a:C,b:J,gcd:P.iushln(R)}},G.prototype._invmp=function(H){U(H.negative===0),U(!H.isZero());var Q=this,P=H.clone();Q.negative!==0?Q=Q.umod(H):Q=Q.clone();for(var Z=new G(1),$=new G(0),C=P.clone();Q.cmpn(1)>0&&P.cmpn(1)>0;){for(var J=0,R=1;(Q.words[0]&R)===0&&J<26;++J,R<<=1);if(J>0)for(Q.iushrn(J);J-- >0;)Z.isOdd()&&Z.iadd(C),Z.iushrn(1);for(var L=0,_=1;(P.words[0]&_)===0&&L<26;++L,_<<=1);if(L>0)for(P.iushrn(L);L-- >0;)$.isOdd()&&$.iadd(C),$.iushrn(1);Q.cmp(P)>=0?(Q.isub(P),Z.isub($)):(P.isub(Q),$.isub(Z))}var s;return Q.cmpn(1)===0?s=Z:s=$,s.cmpn(0)<0&&s.iadd(H),s},G.prototype.gcd=function(H){if(this.isZero())return H.abs();if(H.isZero())return this.abs();var Q=this.clone(),P=H.clone();Q.negative=0,P.negative=0;for(var Z=0;Q.isEven()&&P.isEven();Z++)Q.iushrn(1),P.iushrn(1);do{for(;Q.isEven();)Q.iushrn(1);for(;P.isEven();)P.iushrn(1);var $=Q.cmp(P);if($<0){var C=Q;Q=P,P=C}else if($===0||P.cmpn(1)===0)break;Q.isub(P)}while(!0);return P.iushln(Z)},G.prototype.invm=function(H){return this.egcd(H).a.umod(H)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(H){return this.words[0]&H},G.prototype.bincn=function(H){U(typeof H=="number");var Q=H%26,P=(H-Q)/26,Z=1<<Q;if(this.length<=P)return this._expand(P+1),this.words[P]|=Z,this;for(var $=Z,C=P;$!==0&&C<this.length;C++){var J=this.words[C]|0;J+=$,$=J>>>26,J&=67108863,this.words[C]=J}return $!==0&&(this.words[C]=$,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(H){var Q=H<0;if(this.negative!==0&&!Q)return-1;if(this.negative===0&&Q)return 1;this._strip();var P;if(this.length>1)P=1;else{Q&&(H=-H),U(H<=67108863,"Number is too big");var Z=this.words[0]|0;P=Z===H?0:Z<H?-1:1}return this.negative!==0?-P|0:P},G.prototype.cmp=function(H){if(this.negative!==0&&H.negative===0)return-1;if(this.negative===0&&H.negative!==0)return 1;var Q=this.ucmp(H);return this.negative!==0?-Q|0:Q},G.prototype.ucmp=function(H){if(this.length>H.length)return 1;if(this.length<H.length)return-1;for(var Q=0,P=this.length-1;P>=0;P--){var Z=this.words[P]|0,$=H.words[P]|0;if(Z!==$){Z<$?Q=-1:Z>$&&(Q=1);break}}return Q},G.prototype.gtn=function(H){return this.cmpn(H)===1},G.prototype.gt=function(H){return this.cmp(H)===1},G.prototype.gten=function(H){return this.cmpn(H)>=0},G.prototype.gte=function(H){return this.cmp(H)>=0},G.prototype.ltn=function(H){return this.cmpn(H)===-1},G.prototype.lt=function(H){return this.cmp(H)===-1},G.prototype.lten=function(H){return this.cmpn(H)<=0},G.prototype.lte=function(H){return this.cmp(H)<=0},G.prototype.eqn=function(H){return this.cmpn(H)===0},G.prototype.eq=function(H){return this.cmp(H)===0},G.red=function(H){return new X(H)},G.prototype.toRed=function(H){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),H.convertTo(this)._forceRed(H)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(H){return this.red=H,this},G.prototype.forceRed=function(H){return U(!this.red,"Already a number in reduction context"),this._forceRed(H)},G.prototype.redAdd=function(H){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,H)},G.prototype.redIAdd=function(H){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,H)},G.prototype.redSub=function(H){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,H)},G.prototype.redISub=function(H){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,H)},G.prototype.redShl=function(H){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,H)},G.prototype.redMul=function(H){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,H),this.red.mul(this,H)},G.prototype.redIMul=function(H){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,H),this.red.imul(this,H)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(H){return U(this.red&&!H.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,H)};var n={k256:null,p224:null,p192:null,p25519:null};function i(H,Q){this.name=H,this.p=new G(Q,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}i.prototype._tmp=function(){var H=new G(null);return H.words=new Array(Math.ceil(this.n/13)),H},i.prototype.ireduce=function(H){var Q=H,P;do this.split(Q,this.tmp),Q=this.imulK(Q),Q=Q.iadd(this.tmp),P=Q.bitLength();while(P>this.n);var Z=P<this.n?-1:Q.ucmp(this.p);return Z===0?(Q.words[0]=0,Q.length=1):Z>0?Q.isub(this.p):Q.strip!==void 0?Q.strip():Q._strip(),Q},i.prototype.split=function(H,Q){H.iushrn(this.n,0,Q)},i.prototype.imulK=function(H){return H.imul(this.k)};function H0(){i.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(H0,i),H0.prototype.split=function(H,Q){for(var P=4194303,Z=Math.min(H.length,9),$=0;$<Z;$++)Q.words[$]=H.words[$];if(Q.length=Z,H.length<=9){H.words[0]=0,H.length=1;return}var C=H.words[9];for(Q.words[Q.length++]=C&P,$=10;$<H.length;$++){var J=H.words[$]|0;H.words[$-10]=(J&P)<<4|C>>>22,C=J}C>>>=22,H.words[$-10]=C,C===0&&H.length>10?H.length-=10:H.length-=9},H0.prototype.imulK=function(H){H.words[H.length]=0,H.words[H.length+1]=0,H.length+=2;for(var Q=0,P=0;P<H.length;P++){var Z=H.words[P]|0;Q+=Z*977,H.words[P]=Q&67108863,Q=Z*64+(Q/67108864|0)}return H.words[H.length-1]===0&&(H.length--,H.words[H.length-1]===0&&H.length--),H};function a(){i.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(a,i);function P0(){i.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(P0,i);function K(){i.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(K,i),K.prototype.imulK=function(H){for(var Q=0,P=0;P<H.length;P++){var Z=(H.words[P]|0)*19+Q,$=Z&67108863;Z>>>=26,H.words[P]=$,Q=Z}return Q!==0&&(H.words[H.length++]=Q),H},G._prime=function(H){if(n[H])return n[H];var Q;if(H==="k256")Q=new H0;else if(H==="p224")Q=new a;else if(H==="p192")Q=new P0;else if(H==="p25519")Q=new K;else throw new Error("Unknown prime "+H);return n[H]=Q,Q};function X(H){if(typeof H=="string"){var Q=G._prime(H);this.m=Q.p,this.prime=Q}else U(H.gtn(1),"modulus must be greater than 1"),this.m=H,this.prime=null}X.prototype._verify1=function(H){U(H.negative===0,"red works only with positives"),U(H.red,"red works only with red numbers")},X.prototype._verify2=function(H,Q){U((H.negative|Q.negative)===0,"red works only with positives"),U(H.red&&H.red===Q.red,"red works only with red numbers")},X.prototype.imod=function(H){return this.prime?this.prime.ireduce(H)._forceRed(this):(F(H,H.umod(this.m)._forceRed(this)),H)},X.prototype.neg=function(H){return H.isZero()?H.clone():this.m.sub(H)._forceRed(this)},X.prototype.add=function(H,Q){this._verify2(H,Q);var P=H.add(Q);return P.cmp(this.m)>=0&&P.isub(this.m),P._forceRed(this)},X.prototype.iadd=function(H,Q){this._verify2(H,Q);var P=H.iadd(Q);return P.cmp(this.m)>=0&&P.isub(this.m),P},X.prototype.sub=function(H,Q){this._verify2(H,Q);var P=H.sub(Q);return P.cmpn(0)<0&&P.iadd(this.m),P._forceRed(this)},X.prototype.isub=function(H,Q){this._verify2(H,Q);var P=H.isub(Q);return P.cmpn(0)<0&&P.iadd(this.m),P},X.prototype.shl=function(H,Q){return this._verify1(H),this.imod(H.ushln(Q))},X.prototype.imul=function(H,Q){return this._verify2(H,Q),this.imod(H.imul(Q))},X.prototype.mul=function(H,Q){return this._verify2(H,Q),this.imod(H.mul(Q))},X.prototype.isqr=function(H){return this.imul(H,H.clone())},X.prototype.sqr=function(H){return this.mul(H,H)},X.prototype.sqrt=function(H){if(H.isZero())return H.clone();var Q=this.m.andln(3);if(U(Q%2===1),Q===3){var P=this.m.add(new G(1)).iushrn(2);return this.pow(H,P)}for(var Z=this.m.subn(1),$=0;!Z.isZero()&&Z.andln(1)===0;)$++,Z.iushrn(1);U(!Z.isZero());var C=new G(1).toRed(this),J=C.redNeg(),R=this.m.subn(1).iushrn(1),L=this.m.bitLength();for(L=new G(2*L*L).toRed(this);this.pow(L,R).cmp(J)!==0;)L.redIAdd(J);for(var _=this.pow(L,Z),s=this.pow(H,Z.addn(1).iushrn(1)),r=this.pow(H,Z),X0=$;r.cmp(C)!==0;){for(var u=r,d=0;u.cmp(C)!==0;d++)u=u.redSqr();U(d<X0);var f=this.pow(_,new G(1).iushln(X0-d-1));s=s.redMul(f),_=f.redSqr(),r=r.redMul(_),X0=d}return s},X.prototype.invm=function(H){var Q=H._invmp(this.m);return Q.negative!==0?(Q.negative=0,this.imod(Q).redNeg()):this.imod(Q)},X.prototype.pow=function(H,Q){if(Q.isZero())return new G(1).toRed(this);if(Q.cmpn(1)===0)return H.clone();var P=4,Z=new Array(1<<P);Z[0]=new G(1).toRed(this),Z[1]=H;for(var $=2;$<Z.length;$++)Z[$]=this.mul(Z[$-1],H);var C=Z[0],J=0,R=0,L=Q.bitLength()%26;for(L===0&&(L=26),$=Q.length-1;$>=0;$--){for(var _=Q.words[$],s=L-1;s>=0;s--){var r=_>>s&1;if(C!==Z[0]&&(C=this.sqr(C)),r===0&&J===0){R=0;continue}J<<=1,J|=r,R++,!(R!==P&&($!==0||s!==0))&&(C=this.mul(C,Z[J]),R=0,J=0)}L=26}return C},X.prototype.convertTo=function(H){var Q=H.umod(this.m);return Q===H?Q.clone():Q},X.prototype.convertFrom=function(H){var Q=H.clone();return Q.red=null,Q},G.mont=function(H){return new Y(H)};function Y(H){X.call(this,H),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(Y,X),Y.prototype.convertTo=function(H){return this.imod(H.ushln(this.shift))},Y.prototype.convertFrom=function(H){var Q=this.imod(H.mul(this.rinv));return Q.red=null,Q},Y.prototype.imul=function(H,Q){if(H.isZero()||Q.isZero())return H.words[0]=0,H.length=1,H;var P=H.imul(Q),Z=P.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=P.isub(Z).iushrn(this.shift),C=$;return $.cmp(this.m)>=0?C=$.isub(this.m):$.cmpn(0)<0&&(C=$.iadd(this.m)),C._forceRed(this)},Y.prototype.mul=function(H,Q){if(H.isZero()||Q.isZero())return new G(0)._forceRed(this);var P=H.mul(Q),Z=P.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=P.isub(Z).iushrn(this.shift),C=$;return $.cmp(this.m)>=0?C=$.isub(this.m):$.cmpn(0)<0&&(C=$.iadd(this.m)),C._forceRed(this)},Y.prototype.invm=function(H){var Q=this.imod(H._invmp(this.m).mul(this.r2));return Q._forceRed(this)}})(typeof g>"u"||g,l)}),E9=G0((l,g)=>{var E=R9(),M=g5();function U(W){var I=S(W),V=I.toRed(E.mont(W.modulus)).redPow(new E(W.publicExponent)).fromRed();return{blinder:V,unblinder:I.invm(W.modulus)}}function S(W){var I=W.modulus.byteLength(),V;do V=new E(M(I));while(V.cmp(W.modulus)>=0||!V.umod(W.prime1)||!V.umod(W.prime2));return V}function G(W,I){var V=U(I),z=I.modulus.byteLength(),F=new E(W).mul(V.blinder).umod(I.modulus),O=F.toRed(E.mont(I.prime1)),N=F.toRed(E.mont(I.prime2)),j=I.coefficient,D=I.prime1,k=I.prime2,A=O.redPow(I.exponent1).fromRed(),x=N.redPow(I.exponent2).fromRed(),v=A.isub(x).imul(j).umod(D).imul(k);return x.iadd(v).imul(V.unblinder).umod(I.modulus).toArrayLike(Buffer,"be",z)}G.getr=S,g.exports=G}),r7=G0((l,g)=>{g.exports={name:"elliptic",version:"6.5.4",description:"EC cryptography",main:"lib/elliptic.js",files:["lib"],scripts:{lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository:{type:"git",url:"git@github.com:indutny/elliptic"},keywords:["EC","Elliptic","curve","Cryptography"],author:"Fedor Indutny <fedor@indutny.com>",license:"MIT",bugs:{url:"https://github.com/indutny/elliptic/issues"},homepage:"https://github.com/indutny/elliptic",devDependencies:{brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies:{"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"}}}),k5=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),R6=G0((l)=>{var g=l;function E(S,G){if(Array.isArray(S))return S.slice();if(!S)return[];var W=[];if(typeof S!="string"){for(var I=0;I<S.length;I++)W[I]=S[I]|0;return W}if(G==="hex"){S=S.replace(/[^a-z0-9]+/ig,""),S.length%2!==0&&(S="0"+S);for(var I=0;I<S.length;I+=2)W.push(parseInt(S[I]+S[I+1],16))}else for(var I=0;I<S.length;I++){var V=S.charCodeAt(I),z=V>>8,F=V&255;z?W.push(z,F):W.push(F)}return W}g.toArray=E;function M(S){return S.length===1?"0"+S:S}g.zero2=M;function U(S){for(var G="",W=0;W<S.length;W++)G+=M(S[W].toString(16));return G}g.toHex=U,g.encode=function(S,G){return G==="hex"?U(S):S}}),T5=G0((l)=>{var g=l,E=k5(),M=V5(),U=R6();g.assert=M,g.toArray=U.toArray,g.zero2=U.zero2,g.toHex=U.toHex,g.encode=U.encode;function S(z,F,O){var N=new Array(Math.max(z.bitLength(),O)+1);N.fill(0);for(var j=1<<F+1,D=z.clone(),k=0;k<N.length;k++){var A,x=D.andln(j-1);D.isOdd()?(x>(j>>1)-1?A=(j>>1)-x:A=x,D.isubn(A)):A=0,N[k]=A,D.iushrn(1)}return N}g.getNAF=S;function G(z,F){var O=[[],[]];z=z.clone(),F=F.clone();for(var N=0,j=0,D;z.cmpn(-N)>0||F.cmpn(-j)>0;){var k=z.andln(3)+N&3,A=F.andln(3)+j&3;k===3&&(k=-1),A===3&&(A=-1);var x;(k&1)===0?x=0:(D=z.andln(7)+N&7,(D===3||D===5)&&A===2?x=-k:x=k),O[0].push(x);var v;(A&1)===0?v=0:(D=F.andln(7)+j&7,(D===3||D===5)&&k===2?v=-A:v=A),O[1].push(v),2*N===x+1&&(N=1-N),2*j===v+1&&(j=1-j),z.iushrn(1),F.iushrn(1)}return O}g.getJSF=G;function W(z,F,O){var N="_"+F;z.prototype[F]=function(){return this[N]!==void 0?this[N]:this[N]=O.call(this)}}g.cachedProperty=W;function I(z){return typeof z=="string"?g.toArray(z,"hex"):z}g.parseBytes=I;function V(z){return new E(z,"hex","le")}g.intFromLE=V}),X9=G0((l,g)=>{var E=k5(),M=T5(),U=M.getNAF,S=M.getJSF,G=M.assert;function W(V,z){this.type=V,this.p=new E(z.p,16),this.red=z.prime?E.red(z.prime):E.mont(this.p),this.zero=new E(0).toRed(this.red),this.one=new E(1).toRed(this.red),this.two=new E(2).toRed(this.red),this.n=z.n&&new E(z.n,16),this.g=z.g&&this.pointFromJSON(z.g,z.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var F=this.n&&this.p.div(this.n);!F||F.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}g.exports=W,W.prototype.point=function(){throw new Error("Not implemented")},W.prototype.validate=function(){throw new Error("Not implemented")},W.prototype._fixedNafMul=function(V,z){G(V.precomputed);var F=V._getDoubles(),O=U(z,1,this._bitLength),N=(1<<F.step+1)-(F.step%2===0?2:1);N/=3;var j=[],D,k;for(D=0;D<O.length;D+=F.step){k=0;for(var A=D+F.step-1;A>=D;A--)k=(k<<1)+O[A];j.push(k)}for(var x=this.jpoint(null,null,null),v=this.jpoint(null,null,null),y=N;y>0;y--){for(D=0;D<j.length;D++)k=j[D],k===y?v=v.mixedAdd(F.points[D]):k===-y&&(v=v.mixedAdd(F.points[D].neg()));x=x.add(v)}return x.toP()},W.prototype._wnafMul=function(V,z){var F=4,O=V._getNAFPoints(F);F=O.wnd;for(var N=O.points,j=U(z,F,this._bitLength),D=this.jpoint(null,null,null),k=j.length-1;k>=0;k--){for(var A=0;k>=0&&j[k]===0;k--)A++;if(k>=0&&A++,D=D.dblp(A),k<0)break;var x=j[k];G(x!==0),V.type==="affine"?x>0?D=D.mixedAdd(N[x-1>>1]):D=D.mixedAdd(N[-x-1>>1].neg()):x>0?D=D.add(N[x-1>>1]):D=D.add(N[-x-1>>1].neg())}return V.type==="affine"?D.toP():D},W.prototype._wnafMulAdd=function(V,z,F,O,N){var j=this._wnafT1,D=this._wnafT2,k=this._wnafT3,A=0,x,v,y;for(x=0;x<O;x++){y=z[x];var p=y._getNAFPoints(V);j[x]=p.wnd,D[x]=p.points}for(x=O-1;x>=1;x-=2){var c=x-1,n=x;if(j[c]!==1||j[n]!==1){k[c]=U(F[c],j[c],this._bitLength),k[n]=U(F[n],j[n],this._bitLength),A=Math.max(k[c].length,A),A=Math.max(k[n].length,A);continue}var i=[z[c],null,null,z[n]];z[c].y.cmp(z[n].y)===0?(i[1]=z[c].add(z[n]),i[2]=z[c].toJ().mixedAdd(z[n].neg())):z[c].y.cmp(z[n].y.redNeg())===0?(i[1]=z[c].toJ().mixedAdd(z[n]),i[2]=z[c].add(z[n].neg())):(i[1]=z[c].toJ().mixedAdd(z[n]),i[2]=z[c].toJ().mixedAdd(z[n].neg()));var H0=[-3,-1,-5,-7,0,7,5,1,3],a=S(F[c],F[n]);for(A=Math.max(a[0].length,A),k[c]=new Array(A),k[n]=new Array(A),v=0;v<A;v++){var P0=a[0][v]|0,K=a[1][v]|0;k[c][v]=H0[(P0+1)*3+(K+1)],k[n][v]=0,D[c]=i}}var X=this.jpoint(null,null,null),Y=this._wnafT4;for(x=A;x>=0;x--){for(var H=0;x>=0;){var Q=!0;for(v=0;v<O;v++)Y[v]=k[v][x]|0,Y[v]!==0&&(Q=!1);if(!Q)break;H++,x--}if(x>=0&&H++,X=X.dblp(H),x<0)break;for(v=0;v<O;v++){var P=Y[v];P!==0&&(P>0?y=D[v][P-1>>1]:P<0&&(y=D[v][-P-1>>1].neg()),y.type==="affine"?X=X.mixedAdd(y):X=X.add(y))}}for(x=0;x<O;x++)D[x]=null;return N?X:X.toP()};function I(V,z){this.curve=V,this.type=z,this.precomputed=null}W.BasePoint=I,I.prototype.eq=function(){throw new Error("Not implemented")},I.prototype.validate=function(){return this.curve.validate(this)},W.prototype.decodePoint=function(V,z){V=M.toArray(V,z);var F=this.p.byteLength();if((V[0]===4||V[0]===6||V[0]===7)&&V.length-1===2*F){V[0]===6?G(V[V.length-1]%2===0):V[0]===7&&G(V[V.length-1]%2===1);var O=this.point(V.slice(1,1+F),V.slice(1+F,1+2*F));return O}else if((V[0]===2||V[0]===3)&&V.length-1===F)return this.pointFromX(V.slice(1,1+F),V[0]===3);throw new Error("Unknown point format")},I.prototype.encodeCompressed=function(V){return this.encode(V,!0)},I.prototype._encode=function(V){var z=this.curve.p.byteLength(),F=this.getX().toArray("be",z);return V?[this.getY().isEven()?2:3].concat(F):[4].concat(F,this.getY().toArray("be",z))},I.prototype.encode=function(V,z){return M.encode(this._encode(z),V)},I.prototype.precompute=function(V){if(this.precomputed)return this;var z={doubles:null,naf:null,beta:null};return z.naf=this._getNAFPoints(8),z.doubles=this._getDoubles(4,V),z.beta=this._getBeta(),this.precomputed=z,this},I.prototype._hasDoubles=function(V){if(!this.precomputed)return!1;var z=this.precomputed.doubles;return z?z.points.length>=Math.ceil((V.bitLength()+1)/z.step):!1},I.prototype._getDoubles=function(V,z){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var F=[this],O=this,N=0;N<z;N+=V){for(var j=0;j<V;j++)O=O.dbl();F.push(O)}return{step:V,points:F}},I.prototype._getNAFPoints=function(V){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;for(var z=[this],F=(1<<V)-1,O=F===1?null:this.dbl(),N=1;N<F;N++)z[N]=z[N-1].add(O);return{wnd:V,points:z}},I.prototype._getBeta=function(){return null},I.prototype.dblp=function(V){for(var z=this,F=0;F<V;F++)z=z.dbl();return z}}),i7=G0((l,g)=>{var E=T5(),M=k5(),U=p0(),S=X9(),G=E.assert;function W(z){S.call(this,"short",z),this.a=new M(z.a,16).toRed(this.red),this.b=new M(z.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(z),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}U(W,S),g.exports=W,W.prototype._getEndomorphism=function(z){if(!(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)){var F,O;if(z.beta)F=new M(z.beta,16).toRed(this.red);else{var N=this._getEndoRoots(this.p);F=N[0].cmp(N[1])<0?N[0]:N[1],F=F.toRed(this.red)}if(z.lambda)O=new M(z.lambda,16);else{var j=this._getEndoRoots(this.n);this.g.mul(j[0]).x.cmp(this.g.x.redMul(F))===0?O=j[0]:(O=j[1],G(this.g.mul(O).x.cmp(this.g.x.redMul(F))===0))}var D;return z.basis?D=z.basis.map(function(k){return{a:new M(k.a,16),b:new M(k.b,16)}}):D=this._getEndoBasis(O),{beta:F,lambda:O,basis:D}}},W.prototype._getEndoRoots=function(z){var F=z===this.p?this.red:M.mont(z),O=new M(2).toRed(F).redInvm(),N=O.redNeg(),j=new M(3).toRed(F).redNeg().redSqrt().redMul(O),D=N.redAdd(j).fromRed(),k=N.redSub(j).fromRed();return[D,k]},W.prototype._getEndoBasis=function(z){for(var F=this.n.ushrn(Math.floor(this.n.bitLength()/2)),O=z,N=this.n.clone(),j=new M(1),D=new M(0),k=new M(0),A=new M(1),x,v,y,p,c,n,i,H0=0,a,P0;O.cmpn(0)!==0;){var K=N.div(O);a=N.sub(K.mul(O)),P0=k.sub(K.mul(j));var X=A.sub(K.mul(D));if(!y&&a.cmp(F)<0)x=i.neg(),v=j,y=a.neg(),p=P0;else if(y&&++H0===2)break;i=a,N=O,O=a,k=j,j=P0,A=D,D=X}c=a.neg(),n=P0;var Y=y.sqr().add(p.sqr()),H=c.sqr().add(n.sqr());return H.cmp(Y)>=0&&(c=x,n=v),y.negative&&(y=y.neg(),p=p.neg()),c.negative&&(c=c.neg(),n=n.neg()),[{a:y,b:p},{a:c,b:n}]},W.prototype._endoSplit=function(z){var F=this.endo.basis,O=F[0],N=F[1],j=N.b.mul(z).divRound(this.n),D=O.b.neg().mul(z).divRound(this.n),k=j.mul(O.a),A=D.mul(N.a),x=j.mul(O.b),v=D.mul(N.b),y=z.sub(k).sub(A),p=x.add(v).neg();return{k1:y,k2:p}},W.prototype.pointFromX=function(z,F){z=new M(z,16),z.red||(z=z.toRed(this.red));var O=z.redSqr().redMul(z).redIAdd(z.redMul(this.a)).redIAdd(this.b),N=O.redSqrt();if(N.redSqr().redSub(O).cmp(this.zero)!==0)throw new Error("invalid point");var j=N.fromRed().isOdd();return(F&&!j||!F&&j)&&(N=N.redNeg()),this.point(z,N)},W.prototype.validate=function(z){if(z.inf)return!0;var{x:F,y:O}=z,N=this.a.redMul(F),j=F.redSqr().redMul(F).redIAdd(N).redIAdd(this.b);return O.redSqr().redISub(j).cmpn(0)===0},W.prototype._endoWnafMulAdd=function(z,F,O){for(var N=this._endoWnafT1,j=this._endoWnafT2,D=0;D<z.length;D++){var k=this._endoSplit(F[D]),A=z[D],x=A._getBeta();k.k1.negative&&(k.k1.ineg(),A=A.neg(!0)),k.k2.negative&&(k.k2.ineg(),x=x.neg(!0)),N[D*2]=A,N[D*2+1]=x,j[D*2]=k.k1,j[D*2+1]=k.k2}for(var v=this._wnafMulAdd(1,N,j,D*2,O),y=0;y<D*2;y++)N[y]=null,j[y]=null;return v};function I(z,F,O,N){S.BasePoint.call(this,z,"affine"),F===null&&O===null?(this.x=null,this.y=null,this.inf=!0):(this.x=new M(F,16),this.y=new M(O,16),N&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}U(I,S.BasePoint),W.prototype.point=function(z,F,O){return new I(this,z,F,O)},W.prototype.pointFromJSON=function(z,F){return I.fromJSON(this,z,F)},I.prototype._getBeta=function(){if(this.curve.endo){var z=this.precomputed;if(z&&z.beta)return z.beta;var F=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(z){var O=this.curve,N=function(j){return O.point(j.x.redMul(O.endo.beta),j.y)};z.beta=F,F.precomputed={beta:null,naf:z.naf&&{wnd:z.naf.wnd,points:z.naf.points.map(N)},doubles:z.doubles&&{step:z.doubles.step,points:z.doubles.points.map(N)}}}return F}},I.prototype.toJSON=function(){return this.precomputed?[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]:[this.x,this.y]},I.fromJSON=function(z,F,O){typeof F=="string"&&(F=JSON.parse(F));var N=z.point(F[0],F[1],O);if(!F[2])return N;function j(k){return z.point(k[0],k[1],O)}var D=F[2];return N.precomputed={beta:null,doubles:D.doubles&&{step:D.doubles.step,points:[N].concat(D.doubles.points.map(j))},naf:D.naf&&{wnd:D.naf.wnd,points:[N].concat(D.naf.points.map(j))}},N},I.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},I.prototype.isInfinity=function(){return this.inf},I.prototype.add=function(z){if(this.inf)return z;if(z.inf)return this;if(this.eq(z))return this.dbl();if(this.neg().eq(z))return this.curve.point(null,null);if(this.x.cmp(z.x)===0)return this.curve.point(null,null);var F=this.y.redSub(z.y);F.cmpn(0)!==0&&(F=F.redMul(this.x.redSub(z.x).redInvm()));var O=F.redSqr().redISub(this.x).redISub(z.x),N=F.redMul(this.x.redSub(O)).redISub(this.y);return this.curve.point(O,N)},I.prototype.dbl=function(){if(this.inf)return this;var z=this.y.redAdd(this.y);if(z.cmpn(0)===0)return this.curve.point(null,null);var F=this.curve.a,O=this.x.redSqr(),N=z.redInvm(),j=O.redAdd(O).redIAdd(O).redIAdd(F).redMul(N),D=j.redSqr().redISub(this.x.redAdd(this.x)),k=j.redMul(this.x.redSub(D)).redISub(this.y);return this.curve.point(D,k)},I.prototype.getX=function(){return this.x.fromRed()},I.prototype.getY=function(){return this.y.fromRed()},I.prototype.mul=function(z){return z=new M(z,16),this.isInfinity()?this:this._hasDoubles(z)?this.curve._fixedNafMul(this,z):this.curve.endo?this.curve._endoWnafMulAdd([this],[z]):this.curve._wnafMul(this,z)},I.prototype.mulAdd=function(z,F,O){var N=[this,F],j=[z,O];return this.curve.endo?this.curve._endoWnafMulAdd(N,j):this.curve._wnafMulAdd(1,N,j,2)},I.prototype.jmulAdd=function(z,F,O){var N=[this,F],j=[z,O];return this.curve.endo?this.curve._endoWnafMulAdd(N,j,!0):this.curve._wnafMulAdd(1,N,j,2,!0)},I.prototype.eq=function(z){return this===z||this.inf===z.inf&&(this.inf||this.x.cmp(z.x)===0&&this.y.cmp(z.y)===0)},I.prototype.neg=function(z){if(this.inf)return this;var F=this.curve.point(this.x,this.y.redNeg());if(z&&this.precomputed){var O=this.precomputed,N=function(j){return j.neg()};F.precomputed={naf:O.naf&&{wnd:O.naf.wnd,points:O.naf.points.map(N)},doubles:O.doubles&&{step:O.doubles.step,points:O.doubles.points.map(N)}}}return F},I.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var z=this.curve.jpoint(this.x,this.y,this.curve.one);return z};function V(z,F,O,N){S.BasePoint.call(this,z,"jacobian"),F===null&&O===null&&N===null?(this.x=this.curve.one,this.y=this.curve.one,this.z=new M(0)):(this.x=new M(F,16),this.y=new M(O,16),this.z=new M(N,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}U(V,S.BasePoint),W.prototype.jpoint=function(z,F,O){return new V(this,z,F,O)},V.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var z=this.z.redInvm(),F=z.redSqr(),O=this.x.redMul(F),N=this.y.redMul(F).redMul(z);return this.curve.point(O,N)},V.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},V.prototype.add=function(z){if(this.isInfinity())return z;if(z.isInfinity())return this;var F=z.z.redSqr(),O=this.z.redSqr(),N=this.x.redMul(F),j=z.x.redMul(O),D=this.y.redMul(F.redMul(z.z)),k=z.y.redMul(O.redMul(this.z)),A=N.redSub(j),x=D.redSub(k);if(A.cmpn(0)===0)return x.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var v=A.redSqr(),y=v.redMul(A),p=N.redMul(v),c=x.redSqr().redIAdd(y).redISub(p).redISub(p),n=x.redMul(p.redISub(c)).redISub(D.redMul(y)),i=this.z.redMul(z.z).redMul(A);return this.curve.jpoint(c,n,i)},V.prototype.mixedAdd=function(z){if(this.isInfinity())return z.toJ();if(z.isInfinity())return this;var F=this.z.redSqr(),O=this.x,N=z.x.redMul(F),j=this.y,D=z.y.redMul(F).redMul(this.z),k=O.redSub(N),A=j.redSub(D);if(k.cmpn(0)===0)return A.cmpn(0)!==0?this.curve.jpoint(null,null,null):this.dbl();var x=k.redSqr(),v=x.redMul(k),y=O.redMul(x),p=A.redSqr().redIAdd(v).redISub(y).redISub(y),c=A.redMul(y.redISub(p)).redISub(j.redMul(v)),n=this.z.redMul(k);return this.curve.jpoint(p,c,n)},V.prototype.dblp=function(z){if(z===0)return this;if(this.isInfinity())return this;if(!z)return this.dbl();var F;if(this.curve.zeroA||this.curve.threeA){var O=this;for(F=0;F<z;F++)O=O.dbl();return O}var N=this.curve.a,j=this.curve.tinv,D=this.x,k=this.y,A=this.z,x=A.redSqr().redSqr(),v=k.redAdd(k);for(F=0;F<z;F++){var y=D.redSqr(),p=v.redSqr(),c=p.redSqr(),n=y.redAdd(y).redIAdd(y).redIAdd(N.redMul(x)),i=D.redMul(p),H0=n.redSqr().redISub(i.redAdd(i)),a=i.redISub(H0),P0=n.redMul(a);P0=P0.redIAdd(P0).redISub(c);var K=v.redMul(A);F+1<z&&(x=x.redMul(c)),D=H0,A=K,v=P0}return this.curve.jpoint(D,v.redMul(j),A)},V.prototype.dbl=function(){return this.isInfinity()?this:this.curve.zeroA?this._zeroDbl():this.curve.threeA?this._threeDbl():this._dbl()},V.prototype._zeroDbl=function(){var z,F,O;if(this.zOne){var N=this.x.redSqr(),j=this.y.redSqr(),D=j.redSqr(),k=this.x.redAdd(j).redSqr().redISub(N).redISub(D);k=k.redIAdd(k);var A=N.redAdd(N).redIAdd(N),x=A.redSqr().redISub(k).redISub(k),v=D.redIAdd(D);v=v.redIAdd(v),v=v.redIAdd(v),z=x,F=A.redMul(k.redISub(x)).redISub(v),O=this.y.redAdd(this.y)}else{var y=this.x.redSqr(),p=this.y.redSqr(),c=p.redSqr(),n=this.x.redAdd(p).redSqr().redISub(y).redISub(c);n=n.redIAdd(n);var i=y.redAdd(y).redIAdd(y),H0=i.redSqr(),a=c.redIAdd(c);a=a.redIAdd(a),a=a.redIAdd(a),z=H0.redISub(n).redISub(n),F=i.redMul(n.redISub(z)).redISub(a),O=this.y.redMul(this.z),O=O.redIAdd(O)}return this.curve.jpoint(z,F,O)},V.prototype._threeDbl=function(){var z,F,O;if(this.zOne){var N=this.x.redSqr(),j=this.y.redSqr(),D=j.redSqr(),k=this.x.redAdd(j).redSqr().redISub(N).redISub(D);k=k.redIAdd(k);var A=N.redAdd(N).redIAdd(N).redIAdd(this.curve.a),x=A.redSqr().redISub(k).redISub(k);z=x;var v=D.redIAdd(D);v=v.redIAdd(v),v=v.redIAdd(v),F=A.redMul(k.redISub(x)).redISub(v),O=this.y.redAdd(this.y)}else{var y=this.z.redSqr(),p=this.y.redSqr(),c=this.x.redMul(p),n=this.x.redSub(y).redMul(this.x.redAdd(y));n=n.redAdd(n).redIAdd(n);var i=c.redIAdd(c);i=i.redIAdd(i);var H0=i.redAdd(i);z=n.redSqr().redISub(H0),O=this.y.redAdd(this.z).redSqr().redISub(p).redISub(y);var a=p.redSqr();a=a.redIAdd(a),a=a.redIAdd(a),a=a.redIAdd(a),F=n.redMul(i.redISub(z)).redISub(a)}return this.curve.jpoint(z,F,O)},V.prototype._dbl=function(){var z=this.curve.a,F=this.x,O=this.y,N=this.z,j=N.redSqr().redSqr(),D=F.redSqr(),k=O.redSqr(),A=D.redAdd(D).redIAdd(D).redIAdd(z.redMul(j)),x=F.redAdd(F);x=x.redIAdd(x);var v=x.redMul(k),y=A.redSqr().redISub(v.redAdd(v)),p=v.redISub(y),c=k.redSqr();c=c.redIAdd(c),c=c.redIAdd(c),c=c.redIAdd(c);var n=A.redMul(p).redISub(c),i=O.redAdd(O).redMul(N);return this.curve.jpoint(y,n,i)},V.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var z=this.x.redSqr(),F=this.y.redSqr(),O=this.z.redSqr(),N=F.redSqr(),j=z.redAdd(z).redIAdd(z),D=j.redSqr(),k=this.x.redAdd(F).redSqr().redISub(z).redISub(N);k=k.redIAdd(k),k=k.redAdd(k).redIAdd(k),k=k.redISub(D);var A=k.redSqr(),x=N.redIAdd(N);x=x.redIAdd(x),x=x.redIAdd(x),x=x.redIAdd(x);var v=j.redIAdd(k).redSqr().redISub(D).redISub(A).redISub(x),y=F.redMul(v);y=y.redIAdd(y),y=y.redIAdd(y);var p=this.x.redMul(A).redISub(y);p=p.redIAdd(p),p=p.redIAdd(p);var c=this.y.redMul(v.redMul(x.redISub(v)).redISub(k.redMul(A)));c=c.redIAdd(c),c=c.redIAdd(c),c=c.redIAdd(c);var n=this.z.redAdd(k).redSqr().redISub(O).redISub(A);return this.curve.jpoint(p,c,n)},V.prototype.mul=function(z,F){return z=new M(z,F),this.curve._wnafMul(this,z)},V.prototype.eq=function(z){if(z.type==="affine")return this.eq(z.toJ());if(this===z)return!0;var F=this.z.redSqr(),O=z.z.redSqr();if(this.x.redMul(O).redISub(z.x.redMul(F)).cmpn(0)!==0)return!1;var N=F.redMul(this.z),j=O.redMul(z.z);return this.y.redMul(j).redISub(z.y.redMul(N)).cmpn(0)===0},V.prototype.eqXToP=function(z){var F=this.z.redSqr(),O=z.toRed(this.curve.red).redMul(F);if(this.x.cmp(O)===0)return!0;for(var N=z.clone(),j=this.curve.redN.redMul(F);;){if(N.iadd(this.curve.n),N.cmp(this.curve.p)>=0)return!1;if(O.redIAdd(j),this.x.cmp(O)===0)return!0}},V.prototype.inspect=function(){return this.isInfinity()?"<EC JPoint Infinity>":"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},V.prototype.isInfinity=function(){return this.z.cmpn(0)===0}}),t7=G0((l,g)=>{var E=k5(),M=p0(),U=X9(),S=T5();function G(I){U.call(this,"mont",I),this.a=new E(I.a,16).toRed(this.red),this.b=new E(I.b,16).toRed(this.red),this.i4=new E(4).toRed(this.red).redInvm(),this.two=new E(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}M(G,U),g.exports=G,G.prototype.validate=function(I){var V=I.normalize().x,z=V.redSqr(),F=z.redMul(V).redAdd(z.redMul(this.a)).redAdd(V),O=F.redSqrt();return O.redSqr().cmp(F)===0};function W(I,V,z){U.BasePoint.call(this,I,"projective"),V===null&&z===null?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new E(V,16),this.z=new E(z,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}M(W,U.BasePoint),G.prototype.decodePoint=function(I,V){return this.point(S.toArray(I,V),1)},G.prototype.point=function(I,V){return new W(this,I,V)},G.prototype.pointFromJSON=function(I){return W.fromJSON(this,I)},W.prototype.precompute=function(){},W.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},W.fromJSON=function(I,V){return new W(I,V[0],V[1]||I.one)},W.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},W.prototype.isInfinity=function(){return this.z.cmpn(0)===0},W.prototype.dbl=function(){var I=this.x.redAdd(this.z),V=I.redSqr(),z=this.x.redSub(this.z),F=z.redSqr(),O=V.redSub(F),N=V.redMul(F),j=O.redMul(F.redAdd(this.curve.a24.redMul(O)));return this.curve.point(N,j)},W.prototype.add=function(){throw new Error("Not supported on Montgomery curve")},W.prototype.diffAdd=function(I,V){var z=this.x.redAdd(this.z),F=this.x.redSub(this.z),O=I.x.redAdd(I.z),N=I.x.redSub(I.z),j=N.redMul(z),D=O.redMul(F),k=V.z.redMul(j.redAdd(D).redSqr()),A=V.x.redMul(j.redISub(D).redSqr());return this.curve.point(k,A)},W.prototype.mul=function(I){for(var V=I.clone(),z=this,F=this.curve.point(null,null),O=this,N=[];V.cmpn(0)!==0;V.iushrn(1))N.push(V.andln(1));for(var j=N.length-1;j>=0;j--)N[j]===0?(z=z.diffAdd(F,O),F=F.dbl()):(F=z.diffAdd(F,O),z=z.dbl());return F},W.prototype.mulAdd=function(){throw new Error("Not supported on Montgomery curve")},W.prototype.jumlAdd=function(){throw new Error("Not supported on Montgomery curve")},W.prototype.eq=function(I){return this.getX().cmp(I.getX())===0},W.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},W.prototype.getX=function(){return this.normalize(),this.x.fromRed()}}),e7=G0((l,g)=>{var E=T5(),M=k5(),U=p0(),S=X9(),G=E.assert;function W(V){this.twisted=(V.a|0)!==1,this.mOneA=this.twisted&&(V.a|0)===-1,this.extended=this.mOneA,S.call(this,"edwards",V),this.a=new M(V.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new M(V.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new M(V.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),G(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(V.c|0)===1}U(W,S),g.exports=W,W.prototype._mulA=function(V){return this.mOneA?V.redNeg():this.a.redMul(V)},W.prototype._mulC=function(V){return this.oneC?V:this.c.redMul(V)},W.prototype.jpoint=function(V,z,F,O){return this.point(V,z,F,O)},W.prototype.pointFromX=function(V,z){V=new M(V,16),V.red||(V=V.toRed(this.red));var F=V.redSqr(),O=this.c2.redSub(this.a.redMul(F)),N=this.one.redSub(this.c2.redMul(this.d).redMul(F)),j=O.redMul(N.redInvm()),D=j.redSqrt();if(D.redSqr().redSub(j).cmp(this.zero)!==0)throw new Error("invalid point");var k=D.fromRed().isOdd();return(z&&!k||!z&&k)&&(D=D.redNeg()),this.point(V,D)},W.prototype.pointFromY=function(V,z){V=new M(V,16),V.red||(V=V.toRed(this.red));var F=V.redSqr(),O=F.redSub(this.c2),N=F.redMul(this.d).redMul(this.c2).redSub(this.a),j=O.redMul(N.redInvm());if(j.cmp(this.zero)===0){if(z)throw new Error("invalid point");return this.point(this.zero,V)}var D=j.redSqrt();if(D.redSqr().redSub(j).cmp(this.zero)!==0)throw new Error("invalid point");return D.fromRed().isOdd()!==z&&(D=D.redNeg()),this.point(D,V)},W.prototype.validate=function(V){if(V.isInfinity())return!0;V.normalize();var z=V.x.redSqr(),F=V.y.redSqr(),O=z.redMul(this.a).redAdd(F),N=this.c2.redMul(this.one.redAdd(this.d.redMul(z).redMul(F)));return O.cmp(N)===0};function I(V,z,F,O,N){S.BasePoint.call(this,V,"projective"),z===null&&F===null&&O===null?(this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0):(this.x=new M(z,16),this.y=new M(F,16),this.z=O?new M(O,16):this.curve.one,this.t=N&&new M(N,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.t&&!this.t.red&&(this.t=this.t.toRed(this.curve.red)),this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t&&(this.t=this.x.redMul(this.y),this.zOne||(this.t=this.t.redMul(this.z.redInvm()))))}U(I,S.BasePoint),W.prototype.pointFromJSON=function(V){return I.fromJSON(this,V)},W.prototype.point=function(V,z,F,O){return new I(this,V,z,F,O)},I.fromJSON=function(V,z){return new I(V,z[0],z[1],z[2])},I.prototype.inspect=function(){return this.isInfinity()?"<EC Point Infinity>":"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},I.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},I.prototype._extDbl=function(){var V=this.x.redSqr(),z=this.y.redSqr(),F=this.z.redSqr();F=F.redIAdd(F);var O=this.curve._mulA(V),N=this.x.redAdd(this.y).redSqr().redISub(V).redISub(z),j=O.redAdd(z),D=j.redSub(F),k=O.redSub(z),A=N.redMul(D),x=j.redMul(k),v=N.redMul(k),y=D.redMul(j);return this.curve.point(A,x,y,v)},I.prototype._projDbl=function(){var V=this.x.redAdd(this.y).redSqr(),z=this.x.redSqr(),F=this.y.redSqr(),O,N,j,D,k,A;if(this.curve.twisted){D=this.curve._mulA(z);var x=D.redAdd(F);this.zOne?(O=V.redSub(z).redSub(F).redMul(x.redSub(this.curve.two)),N=x.redMul(D.redSub(F)),j=x.redSqr().redSub(x).redSub(x)):(k=this.z.redSqr(),A=x.redSub(k).redISub(k),O=V.redSub(z).redISub(F).redMul(A),N=x.redMul(D.redSub(F)),j=x.redMul(A))}else D=z.redAdd(F),k=this.curve._mulC(this.z).redSqr(),A=D.redSub(k).redSub(k),O=this.curve._mulC(V.redISub(D)).redMul(A),N=this.curve._mulC(D).redMul(z.redISub(F)),j=D.redMul(A);return this.curve.point(O,N,j)},I.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},I.prototype._extAdd=function(V){var z=this.y.redSub(this.x).redMul(V.y.redSub(V.x)),F=this.y.redAdd(this.x).redMul(V.y.redAdd(V.x)),O=this.t.redMul(this.curve.dd).redMul(V.t),N=this.z.redMul(V.z.redAdd(V.z)),j=F.redSub(z),D=N.redSub(O),k=N.redAdd(O),A=F.redAdd(z),x=j.redMul(D),v=k.redMul(A),y=j.redMul(A),p=D.redMul(k);return this.curve.point(x,v,p,y)},I.prototype._projAdd=function(V){var z=this.z.redMul(V.z),F=z.redSqr(),O=this.x.redMul(V.x),N=this.y.redMul(V.y),j=this.curve.d.redMul(O).redMul(N),D=F.redSub(j),k=F.redAdd(j),A=this.x.redAdd(this.y).redMul(V.x.redAdd(V.y)).redISub(O).redISub(N),x=z.redMul(D).redMul(A),v,y;return this.curve.twisted?(v=z.redMul(k).redMul(N.redSub(this.curve._mulA(O))),y=D.redMul(k)):(v=z.redMul(k).redMul(N.redSub(O)),y=this.curve._mulC(D).redMul(k)),this.curve.point(x,v,y)},I.prototype.add=function(V){return this.isInfinity()?V:V.isInfinity()?this:this.curve.extended?this._extAdd(V):this._projAdd(V)},I.prototype.mul=function(V){return this._hasDoubles(V)?this.curve._fixedNafMul(this,V):this.curve._wnafMul(this,V)},I.prototype.mulAdd=function(V,z,F){return this.curve._wnafMulAdd(1,[this,z],[V,F],2,!1)},I.prototype.jmulAdd=function(V,z,F){return this.curve._wnafMulAdd(1,[this,z],[V,F],2,!0)},I.prototype.normalize=function(){if(this.zOne)return this;var V=this.z.redInvm();return this.x=this.x.redMul(V),this.y=this.y.redMul(V),this.t&&(this.t=this.t.redMul(V)),this.z=this.curve.one,this.zOne=!0,this},I.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},I.prototype.getX=function(){return this.normalize(),this.x.fromRed()},I.prototype.getY=function(){return this.normalize(),this.y.fromRed()},I.prototype.eq=function(V){return this===V||this.getX().cmp(V.getX())===0&&this.getY().cmp(V.getY())===0},I.prototype.eqXToP=function(V){var z=V.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(z)===0)return!0;for(var F=V.clone(),O=this.curve.redN.redMul(this.z);;){if(F.iadd(this.curve.n),F.cmp(this.curve.p)>=0)return!1;if(z.redIAdd(O),this.x.cmp(z)===0)return!0}},I.prototype.toP=I.prototype.normalize,I.prototype.mixedAdd=I.prototype.add}),E6=G0((l)=>{var g=l;g.base=X9(),g.short=i7(),g.mont=t7(),g.edwards=e7()}),D5=G0((l)=>{var g=V5(),E=p0();l.inherits=E;function M(X,Y){return(X.charCodeAt(Y)&64512)!==55296||Y<0||Y+1>=X.length?!1:(X.charCodeAt(Y+1)&64512)===56320}function U(X,Y){if(Array.isArray(X))return X.slice();if(!X)return[];var H=[];if(typeof X=="string")if(Y){if(Y==="hex")for(X=X.replace(/[^a-z0-9]+/ig,""),X.length%2!==0&&(X="0"+X),P=0;P<X.length;P+=2)H.push(parseInt(X[P]+X[P+1],16))}else for(var Q=0,P=0;P<X.length;P++){var Z=X.charCodeAt(P);Z<128?H[Q++]=Z:Z<2048?(H[Q++]=Z>>6|192,H[Q++]=Z&63|128):M(X,P)?(Z=65536+((Z&1023)<<10)+(X.charCodeAt(++P)&1023),H[Q++]=Z>>18|240,H[Q++]=Z>>12&63|128,H[Q++]=Z>>6&63|128,H[Q++]=Z&63|128):(H[Q++]=Z>>12|224,H[Q++]=Z>>6&63|128,H[Q++]=Z&63|128)}else for(P=0;P<X.length;P++)H[P]=X[P]|0;return H}l.toArray=U;function S(X){for(var Y="",H=0;H<X.length;H++)Y+=I(X[H].toString(16));return Y}l.toHex=S;function G(X){var Y=X>>>24|X>>>8&65280|X<<8&16711680|(X&255)<<24;return Y>>>0}l.htonl=G;function W(X,Y){for(var H="",Q=0;Q<X.length;Q++){var P=X[Q];Y==="little"&&(P=G(P)),H+=V(P.toString(16))}return H}l.toHex32=W;function I(X){return X.length===1?"0"+X:X}l.zero2=I;function V(X){return X.length===7?"0"+X:X.length===6?"00"+X:X.length===5?"000"+X:X.length===4?"0000"+X:X.length===3?"00000"+X:X.length===2?"000000"+X:X.length===1?"0000000"+X:X}l.zero8=V;function z(X,Y,H,Q){var P=H-Y;g(P%4===0);for(var Z=new Array(P/4),$=0,C=Y;$<Z.length;$++,C+=4){var J;Q==="big"?J=X[C]<<24|X[C+1]<<16|X[C+2]<<8|X[C+3]:J=X[C+3]<<24|X[C+2]<<16|X[C+1]<<8|X[C],Z[$]=J>>>0}return Z}l.join32=z;function F(X,Y){for(var H=new Array(X.length*4),Q=0,P=0;Q<X.length;Q++,P+=4){var Z=X[Q];Y==="big"?(H[P]=Z>>>24,H[P+1]=Z>>>16&255,H[P+2]=Z>>>8&255,H[P+3]=Z&255):(H[P+3]=Z>>>24,H[P+2]=Z>>>16&255,H[P+1]=Z>>>8&255,H[P]=Z&255)}return H}l.split32=F;function O(X,Y){return X>>>Y|X<<32-Y}l.rotr32=O;function N(X,Y){return X<<Y|X>>>32-Y}l.rotl32=N;function j(X,Y){return X+Y>>>0}l.sum32=j;function D(X,Y,H){return X+Y+H>>>0}l.sum32_3=D;function k(X,Y,H,Q){return X+Y+H+Q>>>0}l.sum32_4=k;function A(X,Y,H,Q,P){return X+Y+H+Q+P>>>0}l.sum32_5=A;function x(X,Y,H,Q){var P=X[Y],Z=X[Y+1],$=Q+Z>>>0,C=($<Q?1:0)+H+P;X[Y]=C>>>0,X[Y+1]=$}l.sum64=x;function v(X,Y,H,Q){var P=Y+Q>>>0,Z=(P<Y?1:0)+X+H;return Z>>>0}l.sum64_hi=v;function y(X,Y,H,Q){var P=Y+Q;return P>>>0}l.sum64_lo=y;function p(X,Y,H,Q,P,Z,$,C){var J=0,R=Y;R=R+Q>>>0,J+=R<Y?1:0,R=R+Z>>>0,J+=R<Z?1:0,R=R+C>>>0,J+=R<C?1:0;var L=X+H+P+$+J;return L>>>0}l.sum64_4_hi=p;function c(X,Y,H,Q,P,Z,$,C){var J=Y+Q+Z+C;return J>>>0}l.sum64_4_lo=c;function n(X,Y,H,Q,P,Z,$,C,J,R){var L=0,_=Y;_=_+Q>>>0,L+=_<Y?1:0,_=_+Z>>>0,L+=_<Z?1:0,_=_+C>>>0,L+=_<C?1:0,_=_+R>>>0,L+=_<R?1:0;var s=X+H+P+$+J+L;return s>>>0}l.sum64_5_hi=n;function i(X,Y,H,Q,P,Z,$,C,J,R){var L=Y+Q+Z+C+R;return L>>>0}l.sum64_5_lo=i;function H0(X,Y,H){var Q=Y<<32-H|X>>>H;return Q>>>0}l.rotr64_hi=H0;function a(X,Y,H){var Q=X<<32-H|Y>>>H;return Q>>>0}l.rotr64_lo=a;function P0(X,Y,H){return X>>>H}l.shr64_hi=P0;function K(X,Y,H){var Q=X<<32-H|Y>>>H;return Q>>>0}l.shr64_lo=K}),o5=G0((l)=>{var g=D5(),E=V5();function M(){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}l.BlockHash=M,M.prototype.update=function(U,S){if(U=g.toArray(U,S),this.pending?this.pending=this.pending.concat(U):this.pending=U,this.pendingTotal+=U.length,this.pending.length>=this._delta8){U=this.pending;var G=U.length%this._delta8;this.pending=U.slice(U.length-G,U.length),this.pending.length===0&&(this.pending=null),U=g.join32(U,0,U.length-G,this.endian);for(var W=0;W<U.length;W+=this._delta32)this._update(U,W,W+this._delta32)}return this},M.prototype.digest=function(U){return this.update(this._pad()),E(this.pending===null),this._digest(U)},M.prototype._pad=function(){var U=this.pendingTotal,S=this._delta8,G=S-(U+this.padLength)%S,W=new Array(G+this.padLength);W[0]=128;for(var I=1;I<G;I++)W[I]=0;if(U<<=3,this.endian==="big"){for(var V=8;V<this.padLength;V++)W[I++]=0;W[I++]=0,W[I++]=0,W[I++]=0,W[I++]=0,W[I++]=U>>>24&255,W[I++]=U>>>16&255,W[I++]=U>>>8&255,W[I++]=U&255}else for(W[I++]=U&255,W[I++]=U>>>8&255,W[I++]=U>>>16&255,W[I++]=U>>>24&255,W[I++]=0,W[I++]=0,W[I++]=0,W[I++]=0,V=8;V<this.padLength;V++)W[I++]=0;return W}}),S6=G0((l)=>{var g=D5(),E=g.rotr32;function M(F,O,N,j){if(F===0)return U(O,N,j);if(F===1||F===3)return G(O,N,j);if(F===2)return S(O,N,j)}l.ft_1=M;function U(F,O,N){return F&O^~F&N}l.ch32=U;function S(F,O,N){return F&O^F&N^O&N}l.maj32=S;function G(F,O,N){return F^O^N}l.p32=G;function W(F){return E(F,2)^E(F,13)^E(F,22)}l.s0_256=W;function I(F){return E(F,6)^E(F,11)^E(F,25)}l.s1_256=I;function V(F){return E(F,7)^E(F,18)^F>>>3}l.g0_256=V;function z(F){return E(F,17)^E(F,19)^F>>>10}l.g1_256=z}),K8=G0((l,g)=>{var E=D5(),M=o5(),U=S6(),S=E.rotl32,G=E.sum32,W=E.sum32_5,I=U.ft_1,V=M.BlockHash,z=[1518500249,1859775393,2400959708,3395469782];function F(){if(!(this instanceof F))return new F;V.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}E.inherits(F,V),g.exports=F,F.blockSize=512,F.outSize=160,F.hmacStrength=80,F.padLength=64,F.prototype._update=function(O,N){for(var j=this.W,D=0;D<16;D++)j[D]=O[N+D];for(;D<j.length;D++)j[D]=S(j[D-3]^j[D-8]^j[D-14]^j[D-16],1);var k=this.h[0],A=this.h[1],x=this.h[2],v=this.h[3],y=this.h[4];for(D=0;D<j.length;D++){var p=~~(D/20),c=W(S(k,5),I(p,A,x,v),y,j[D],z[p]);y=v,v=x,x=S(A,30),A=k,k=c}this.h[0]=G(this.h[0],k),this.h[1]=G(this.h[1],A),this.h[2]=G(this.h[2],x),this.h[3]=G(this.h[3],v),this.h[4]=G(this.h[4],y)},F.prototype._digest=function(O){return O==="hex"?E.toHex32(this.h,"big"):E.split32(this.h,"big")}}),x6=G0((l,g)=>{var E=D5(),M=o5(),U=S6(),S=V5(),G=E.sum32,W=E.sum32_4,I=E.sum32_5,V=U.ch32,z=U.maj32,F=U.s0_256,O=U.s1_256,N=U.g0_256,j=U.g1_256,D=M.BlockHash,k=[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 A(){if(!(this instanceof A))return new A;D.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=k,this.W=new Array(64)}E.inherits(A,D),g.exports=A,A.blockSize=512,A.outSize=256,A.hmacStrength=192,A.padLength=64,A.prototype._update=function(x,v){for(var y=this.W,p=0;p<16;p++)y[p]=x[v+p];for(;p<y.length;p++)y[p]=W(j(y[p-2]),y[p-7],N(y[p-15]),y[p-16]);var c=this.h[0],n=this.h[1],i=this.h[2],H0=this.h[3],a=this.h[4],P0=this.h[5],K=this.h[6],X=this.h[7];for(S(this.k.length===y.length),p=0;p<y.length;p++){var Y=I(X,O(a),V(a,P0,K),this.k[p],y[p]),H=G(F(c),z(c,n,i));X=K,K=P0,P0=a,a=G(H0,Y),H0=i,i=n,n=c,c=G(Y,H)}this.h[0]=G(this.h[0],c),this.h[1]=G(this.h[1],n),this.h[2]=G(this.h[2],i),this.h[3]=G(this.h[3],H0),this.h[4]=G(this.h[4],a),this.h[5]=G(this.h[5],P0),this.h[6]=G(this.h[6],K),this.h[7]=G(this.h[7],X)},A.prototype._digest=function(x){return x==="hex"?E.toHex32(this.h,"big"):E.split32(this.h,"big")}}),C8=G0((l,g)=>{var E=D5(),M=x6();function U(){if(!(this instanceof U))return new U;M.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}E.inherits(U,M),g.exports=U,U.blockSize=512,U.outSize=224,U.hmacStrength=192,U.padLength=64,U.prototype._digest=function(S){return S==="hex"?E.toHex32(this.h.slice(0,7),"big"):E.split32(this.h.slice(0,7),"big")}}),A6=G0((l,g)=>{var E=D5(),M=o5(),U=V5(),S=E.rotr64_hi,G=E.rotr64_lo,W=E.shr64_hi,I=E.shr64_lo,V=E.sum64,z=E.sum64_hi,F=E.sum64_lo,O=E.sum64_4_hi,N=E.sum64_4_lo,j=E.sum64_5_hi,D=E.sum64_5_lo,k=M.BlockHash,A=[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 x(){if(!(this instanceof x))return new x;k.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=A,this.W=new Array(160)}E.inherits(x,k),g.exports=x,x.blockSize=1024,x.outSize=512,x.hmacStrength=192,x.padLength=128,x.prototype._prepareBlock=function(H,Q){for(var P=this.W,Z=0;Z<32;Z++)P[Z]=H[Q+Z];for(;Z<P.length;Z+=2){var $=X(P[Z-4],P[Z-3]),C=Y(P[Z-4],P[Z-3]),J=P[Z-14],R=P[Z-13],L=P0(P[Z-30],P[Z-29]),_=K(P[Z-30],P[Z-29]),s=P[Z-32],r=P[Z-31];P[Z]=O($,C,J,R,L,_,s,r),P[Z+1]=N($,C,J,R,L,_,s,r)}},x.prototype._update=function(H,Q){this._prepareBlock(H,Q);var P=this.W,Z=this.h[0],$=this.h[1],C=this.h[2],J=this.h[3],R=this.h[4],L=this.h[5],_=this.h[6],s=this.h[7],r=this.h[8],X0=this.h[9],u=this.h[10],d=this.h[11],f=this.h[12],z0=this.h[13],K0=this.h[14],Q0=this.h[15];U(this.k.length===P.length);for(var w=0;w<P.length;w+=2){var q=K0,m=Q0,e=H0(r,X0),C0=a(r,X0),t=v(r,X0,u,d,f,z0),_0=y(r,X0,u,d,f,z0),$0=this.k[w],J0=this.k[w+1],w0=P[w],j0=P[w+1],Z0=j(q,m,e,C0,t,_0,$0,J0,w0,j0),c0=D(q,m,e,C0,t,_0,$0,J0,w0,j0);q=n(Z,$),m=i(Z,$),e=p(Z,$,C,J,R,L),C0=c(Z,$,C,J,R,L);var T=z(q,m,e,C0),B=F(q,m,e,C0);K0=f,Q0=z0,f=u,z0=d,u=r,d=X0,r=z(_,s,Z0,c0),X0=F(s,s,Z0,c0),_=R,s=L,R=C,L=J,C=Z,J=$,Z=z(Z0,c0,T,B),$=F(Z0,c0,T,B)}V(this.h,0,Z,$),V(this.h,2,C,J),V(this.h,4,R,L),V(this.h,6,_,s),V(this.h,8,r,X0),V(this.h,10,u,d),V(this.h,12,f,z0),V(this.h,14,K0,Q0)},x.prototype._digest=function(H){return H==="hex"?E.toHex32(this.h,"big"):E.split32(this.h,"big")};function v(H,Q,P,Z,$){var C=H&P^~H&$;return C<0&&(C+=4294967296),C}function y(H,Q,P,Z,$,C){var J=Q&Z^~Q&C;return J<0&&(J+=4294967296),J}function p(H,Q,P,Z,$){var C=H&P^H&$^P&$;return C<0&&(C+=4294967296),C}function c(H,Q,P,Z,$,C){var J=Q&Z^Q&C^Z&C;return J<0&&(J+=4294967296),J}function n(H,Q){var P=S(H,Q,28),Z=S(Q,H,2),$=S(Q,H,7),C=P^Z^$;return C<0&&(C+=4294967296),C}function i(H,Q){var P=G(H,Q,28),Z=G(Q,H,2),$=G(Q,H,7),C=P^Z^$;return C<0&&(C+=4294967296),C}function H0(H,Q){var P=S(H,Q,14),Z=S(H,Q,18),$=S(Q,H,9),C=P^Z^$;return C<0&&(C+=4294967296),C}function a(H,Q){var P=G(H,Q,14),Z=G(H,Q,18),$=G(Q,H,9),C=P^Z^$;return C<0&&(C+=4294967296),C}function P0(H,Q){var P=S(H,Q,1),Z=S(H,Q,8),$=W(H,Q,7),C=P^Z^$;return C<0&&(C+=4294967296),C}function K(H,Q){var P=G(H,Q,1),Z=G(H,Q,8),$=I(H,Q,7),C=P^Z^$;return C<0&&(C+=4294967296),C}function X(H,Q){var P=S(H,Q,19),Z=S(Q,H,29),$=W(H,Q,6),C=P^Z^$;return C<0&&(C+=4294967296),C}function Y(H,Q){var P=G(H,Q,19),Z=G(Q,H,29),$=I(H,Q,6),C=P^Z^$;return C<0&&(C+=4294967296),C}}),X8=G0((l,g)=>{var E=D5(),M=A6();function U(){if(!(this instanceof U))return new U;M.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}E.inherits(U,M),g.exports=U,U.blockSize=1024,U.outSize=384,U.hmacStrength=192,U.padLength=128,U.prototype._digest=function(S){return S==="hex"?E.toHex32(this.h.slice(0,12),"big"):E.split32(this.h.slice(0,12),"big")}}),H8=G0((l)=>{l.sha1=K8(),l.sha224=C8(),l.sha256=x6(),l.sha384=X8(),l.sha512=A6()}),Y8=G0((l)=>{var g=D5(),E=o5(),M=g.rotl32,U=g.sum32,S=g.sum32_3,G=g.sum32_4,W=E.BlockHash;function I(){if(!(this instanceof I))return new I;W.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}g.inherits(I,W),l.ripemd160=I,I.blockSize=512,I.outSize=160,I.hmacStrength=192,I.padLength=64,I.prototype._update=function(k,A){for(var x=this.h[0],v=this.h[1],y=this.h[2],p=this.h[3],c=this.h[4],n=x,i=v,H0=y,a=p,P0=c,K=0;K<80;K++){var X=U(M(G(x,V(K,v,y,p),k[O[K]+A],z(K)),j[K]),c);x=c,c=p,p=M(y,10),y=v,v=X,X=U(M(G(n,V(79-K,i,H0,a),k[N[K]+A],F(K)),D[K]),P0),n=P0,P0=a,a=M(H0,10),H0=i,i=X}X=S(this.h[1],y,a),this.h[1]=S(this.h[2],p,P0),this.h[2]=S(this.h[3],c,n),this.h[3]=S(this.h[4],x,i),this.h[4]=S(this.h[0],v,H0),this.h[0]=X},I.prototype._digest=function(k){return k==="hex"?g.toHex32(this.h,"little"):g.split32(this.h,"little")};function V(k,A,x,v){return k<=15?A^x^v:k<=31?A&x|~A&v:k<=47?(A|~x)^v:k<=63?A&v|x&~v:A^(x|~v)}function z(k){return k<=15?0:k<=31?1518500249:k<=47?1859775393:k<=63?2400959708:2840853838}function F(k){return k<=15?1352829926:k<=31?1548603684:k<=47?1836072691:k<=63?2053994217:0}var O=[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],N=[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],j=[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],D=[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]}),Q8=G0((l,g)=>{var E=D5(),M=V5();function U(S,G,W){if(!(this instanceof U))return new U(S,G,W);this.Hash=S,this.blockSize=S.blockSize/8,this.outSize=S.outSize/8,this.inner=null,this.outer=null,this._init(E.toArray(G,W))}g.exports=U,U.prototype._init=function(S){S.length>this.blockSize&&(S=new this.Hash().update(S).digest()),M(S.length<=this.blockSize);for(var G=S.length;G<this.blockSize;G++)S.push(0);for(G=0;G<S.length;G++)S[G]^=54;for(this.inner=new this.Hash().update(S),G=0;G<S.length;G++)S[G]^=106;this.outer=new this.Hash().update(S)},U.prototype.update=function(S,G){return this.inner.update(S,G),this},U.prototype.digest=function(S){return this.outer.update(this.inner.digest()),this.outer.digest(S)}}),S9=G0((l)=>{var g=l;g.utils=D5(),g.common=o5(),g.sha=H8(),g.ripemd=Y8(),g.hmac=Q8(),g.sha1=g.sha.sha1,g.sha256=g.sha.sha256,g.sha224=g.sha.sha224,g.sha384=g.sha.sha384,g.sha512=g.sha.sha512,g.ripemd160=g.ripemd.ripemd160}),$8=G0((l,g)=>{g.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}}),x9=G0((l)=>{var g=l,E=S9(),M=E6(),U=T5(),S=U.assert;function G(V){V.type==="short"?this.curve=new M.short(V):V.type==="edwards"?this.curve=new M.edwards(V):this.curve=new M.mont(V),this.g=this.curve.g,this.n=this.curve.n,this.hash=V.hash,S(this.g.validate(),"Invalid curve"),S(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}g.PresetCurve=G;function W(V,z){Object.defineProperty(g,V,{configurable:!0,enumerable:!0,get:function(){var F=new G(z);return Object.defineProperty(g,V,{configurable:!0,enumerable:!0,value:F}),F}})}W("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:E.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),W("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:E.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),W("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:E.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),W("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:E.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),W("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:E.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),W("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:E.sha256,gRed:!1,g:["9"]}),W("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:E.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var I;try{I=$8()}catch{I=void 0}W("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:E.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",I]})}),G8=G0((l,g)=>{var E=S9(),M=R6(),U=V5();function S(G){if(!(this instanceof S))return new S(G);this.hash=G.hash,this.predResist=!!G.predResist,this.outLen=this.hash.outSize,this.minEntropy=G.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var W=M.toArray(G.entropy,G.entropyEnc||"hex"),I=M.toArray(G.nonce,G.nonceEnc||"hex"),V=M.toArray(G.pers,G.persEnc||"hex");U(W.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(W,I,V)}g.exports=S,S.prototype._init=function(G,W,I){var V=G.concat(W).concat(I);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var z=0;z<this.V.length;z++)this.K[z]=0,this.V[z]=1;this._update(V),this._reseed=1,this.reseedInterval=281474976710656},S.prototype._hmac=function(){return new E.hmac(this.hash,this.K)},S.prototype._update=function(G){var W=this._hmac().update(this.V).update([0]);G&&(W=W.update(G)),this.K=W.digest(),this.V=this._hmac().update(this.V).digest(),G&&(this.K=this._hmac().update(this.V).update([1]).update(G).digest(),this.V=this._hmac().update(this.V).digest())},S.prototype.reseed=function(G,W,I,V){typeof W!="string"&&(V=I,I=W,W=null),G=M.toArray(G,W),I=M.toArray(I,V),U(G.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(G.concat(I||[])),this._reseed=1},S.prototype.generate=function(G,W,I,V){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");typeof W!="string"&&(V=I,I=W,W=null),I&&(I=M.toArray(I,V||"hex"),this._update(I));for(var z=[];z.length<G;)this.V=this._hmac().update(this.V).digest(),z=z.concat(this.V);var F=z.slice(0,G);return this._update(I),this._reseed++,M.encode(F,W)}}),J8=G0((l,g)=>{var E=k5(),M=T5(),U=M.assert;function S(G,W){this.ec=G,this.priv=null,this.pub=null,W.priv&&this._importPrivate(W.priv,W.privEnc),W.pub&&this._importPublic(W.pub,W.pubEnc)}g.exports=S,S.fromPublic=function(G,W,I){return W instanceof S?W:new S(G,{pub:W,pubEnc:I})},S.fromPrivate=function(G,W,I){return W instanceof S?W:new S(G,{priv:W,privEnc:I})},S.prototype.validate=function(){var G=this.getPublic();return G.isInfinity()?{result:!1,reason:"Invalid public key"}:G.validate()?G.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},S.prototype.getPublic=function(G,W){return typeof G=="string"&&(W=G,G=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),W?this.pub.encode(W,G):this.pub},S.prototype.getPrivate=function(G){return G==="hex"?this.priv.toString(16,2):this.priv},S.prototype._importPrivate=function(G,W){this.priv=new E(G,W||16),this.priv=this.priv.umod(this.ec.curve.n)},S.prototype._importPublic=function(G,W){if(G.x||G.y){this.ec.curve.type==="mont"?U(G.x,"Need x coordinate"):(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")&&U(G.x&&G.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(G.x,G.y);return}this.pub=this.ec.curve.decodePoint(G,W)},S.prototype.derive=function(G){return G.validate()||U(G.validate(),"public point not validated"),G.mul(this.priv).getX()},S.prototype.sign=function(G,W,I){return this.ec.sign(G,this,W,I)},S.prototype.verify=function(G,W){return this.ec.verify(G,W,this)},S.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}}),P8=G0((l,g)=>{var E=k5(),M=T5(),U=M.assert;function S(z,F){if(z instanceof S)return z;this._importDER(z,F)||(U(z.r&&z.s,"Signature without r or s"),this.r=new E(z.r,16),this.s=new E(z.s,16),z.recoveryParam===void 0?this.recoveryParam=null:this.recoveryParam=z.recoveryParam)}g.exports=S;function G(){this.place=0}function W(z,F){var O=z[F.place++];if(!(O&128))return O;var N=O&15;if(N===0||N>4)return!1;for(var j=0,D=0,k=F.place;D<N;D++,k++)j<<=8,j|=z[k],j>>>=0;return j<=127?!1:(F.place=k,j)}function I(z){for(var F=0,O=z.length-1;!z[F]&&!(z[F+1]&128)&&F<O;)F++;return F===0?z:z.slice(F)}S.prototype._importDER=function(z,F){z=M.toArray(z,F);var O=new G;if(z[O.place++]!==48)return!1;var N=W(z,O);if(N===!1||N+O.place!==z.length||z[O.place++]!==2)return!1;var j=W(z,O);if(j===!1)return!1;var D=z.slice(O.place,j+O.place);if(O.place+=j,z[O.place++]!==2)return!1;var k=W(z,O);if(k===!1||z.length!==k+O.place)return!1;var A=z.slice(O.place,k+O.place);if(D[0]===0)if(D[1]&128)D=D.slice(1);else return!1;if(A[0]===0)if(A[1]&128)A=A.slice(1);else return!1;return this.r=new E(D),this.s=new E(A),this.recoveryParam=null,!0};function V(z,F){if(F<128){z.push(F);return}var O=1+(Math.log(F)/Math.LN2>>>3);for(z.push(O|128);--O;)z.push(F>>>(O<<3)&255);z.push(F)}S.prototype.toDER=function(z){var F=this.r.toArray(),O=this.s.toArray();for(F[0]&128&&(F=[0].concat(F)),O[0]&128&&(O=[0].concat(O)),F=I(F),O=I(O);!O[0]&&!(O[1]&128);)O=O.slice(1);var N=[2];V(N,F.length),N=N.concat(F),N.push(2),V(N,O.length);var j=N.concat(O),D=[48];return V(D,j.length),D=D.concat(j),M.encode(D,z)}}),Z8=G0((l,g)=>{var E=k5(),M=G8(),U=T5(),S=x9(),G=q9(),W=U.assert,I=J8(),V=P8();function z(F){if(!(this instanceof z))return new z(F);typeof F=="string"&&(W(Object.prototype.hasOwnProperty.call(S,F),"Unknown curve "+F),F=S[F]),F instanceof S.PresetCurve&&(F={curve:F}),this.curve=F.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=F.curve.g,this.g.precompute(F.curve.n.bitLength()+1),this.hash=F.hash||F.curve.hash}g.exports=z,z.prototype.keyPair=function(F){return new I(this,F)},z.prototype.keyFromPrivate=function(F,O){return I.fromPrivate(this,F,O)},z.prototype.keyFromPublic=function(F,O){return I.fromPublic(this,F,O)},z.prototype.genKeyPair=function(F){F||(F={});for(var O=new M({hash:this.hash,pers:F.pers,persEnc:F.persEnc||"utf8",entropy:F.entropy||G(this.hash.hmacStrength),entropyEnc:F.entropy&&F.entropyEnc||"utf8",nonce:this.n.toArray()}),N=this.n.byteLength(),j=this.n.sub(new E(2));;){var D=new E(O.generate(N));if(!(D.cmp(j)>0))return D.iaddn(1),this.keyFromPrivate(D)}},z.prototype._truncateToN=function(F,O){var N=F.byteLength()*8-this.n.bitLength();return N>0&&(F=F.ushrn(N)),!O&&F.cmp(this.n)>=0?F.sub(this.n):F},z.prototype.sign=function(F,O,N,j){typeof N=="object"&&(j=N,N=null),j||(j={}),O=this.keyFromPrivate(O,N),F=this._truncateToN(new E(F,16));for(var D=this.n.byteLength(),k=O.getPrivate().toArray("be",D),A=F.toArray("be",D),x=new M({hash:this.hash,entropy:k,nonce:A,pers:j.pers,persEnc:j.persEnc||"utf8"}),v=this.n.sub(new E(1)),y=0;;y++){var p=j.k?j.k(y):new E(x.generate(this.n.byteLength()));if(p=this._truncateToN(p,!0),!(p.cmpn(1)<=0||p.cmp(v)>=0)){var c=this.g.mul(p);if(!c.isInfinity()){var n=c.getX(),i=n.umod(this.n);if(i.cmpn(0)!==0){var H0=p.invm(this.n).mul(i.mul(O.getPrivate()).iadd(F));if(H0=H0.umod(this.n),H0.cmpn(0)!==0){var a=(c.getY().isOdd()?1:0)|(n.cmp(i)!==0?2:0);return j.canonical&&H0.cmp(this.nh)>0&&(H0=this.n.sub(H0),a^=1),new V({r:i,s:H0,recoveryParam:a})}}}}}},z.prototype.verify=function(F,O,N,j){F=this._truncateToN(new E(F,16)),N=this.keyFromPublic(N,j),O=new V(O,"hex");var{r:D,s:k}=O;if(D.cmpn(1)<0||D.cmp(this.n)>=0||k.cmpn(1)<0||k.cmp(this.n)>=0)return!1;var A=k.invm(this.n),x=A.mul(F).umod(this.n),v=A.mul(D).umod(this.n),y;return this.curve._maxwellTrick?(y=this.g.jmulAdd(x,N.getPublic(),v),y.isInfinity()?!1:y.eqXToP(D)):(y=this.g.mulAdd(x,N.getPublic(),v),y.isInfinity()?!1:y.getX().umod(this.n).cmp(D)===0)},z.prototype.recoverPubKey=function(F,O,N,j){W((3&N)===N,"The recovery param is more than two bits"),O=new V(O,j);var D=this.n,k=new E(F),A=O.r,x=O.s,v=N&1,y=N>>1;if(A.cmp(this.curve.p.umod(this.curve.n))>=0&&y)throw new Error("Unable to find sencond key candinate");y?A=this.curve.pointFromX(A.add(this.curve.n),v):A=this.curve.pointFromX(A,v);var p=O.r.invm(D),c=D.sub(k).mul(p).umod(D),n=x.mul(p).umod(D);return this.g.mulAdd(c,A,n)},z.prototype.getKeyRecoveryParam=function(F,O,N,j){if(O=new V(O,j),O.recoveryParam!==null)return O.recoveryParam;for(var D=0;D<4;D++){var k;try{k=this.recoverPubKey(F,O,D)}catch{continue}if(k.eq(N))return D}throw new Error("Unable to find valid recovery factor")}}),F8=G0((l,g)=>{var E=T5(),M=E.assert,U=E.parseBytes,S=E.cachedProperty;function G(W,I){this.eddsa=W,this._secret=U(I.secret),W.isPoint(I.pub)?this._pub=I.pub:this._pubBytes=U(I.pub)}G.fromPublic=function(W,I){return I instanceof G?I:new G(W,{pub:I})},G.fromSecret=function(W,I){return I instanceof G?I:new G(W,{secret:I})},G.prototype.secret=function(){return this._secret},S(G,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),S(G,"pub",function(){return this._pubBytes?this.eddsa.decodePoint(this._pubBytes):this.eddsa.g.mul(this.priv())}),S(G,"privBytes",function(){var W=this.eddsa,I=this.hash(),V=W.encodingLength-1,z=I.slice(0,W.encodingLength);return z[0]&=248,z[V]&=127,z[V]|=64,z}),S(G,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),S(G,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),S(G,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),G.prototype.sign=function(W){return M(this._secret,"KeyPair can only verify"),this.eddsa.sign(W,this)},G.prototype.verify=function(W,I){return this.eddsa.verify(W,I,this)},G.prototype.getSecret=function(W){return M(this._secret,"KeyPair is public only"),E.encode(this.secret(),W)},G.prototype.getPublic=function(W){return E.encode(this.pubBytes(),W)},g.exports=G}),U8=G0((l,g)=>{var E=k5(),M=T5(),U=M.assert,S=M.cachedProperty,G=M.parseBytes;function W(I,V){this.eddsa=I,typeof V!="object"&&(V=G(V)),Array.isArray(V)&&(V={R:V.slice(0,I.encodingLength),S:V.slice(I.encodingLength)}),U(V.R&&V.S,"Signature without R or S"),I.isPoint(V.R)&&(this._R=V.R),V.S instanceof E&&(this._S=V.S),this._Rencoded=Array.isArray(V.R)?V.R:V.Rencoded,this._Sencoded=Array.isArray(V.S)?V.S:V.Sencoded}S(W,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),S(W,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),S(W,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),S(W,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),W.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},W.prototype.toHex=function(){return M.encode(this.toBytes(),"hex").toUpperCase()},g.exports=W}),W8=G0((l,g)=>{var E=S9(),M=x9(),U=T5(),S=U.assert,G=U.parseBytes,W=F8(),I=U8();function V(z){if(S(z==="ed25519","only tested with ed25519 so far"),!(this instanceof V))return new V(z);z=M[z].curve,this.curve=z,this.g=z.g,this.g.precompute(z.n.bitLength()+1),this.pointClass=z.point().constructor,this.encodingLength=Math.ceil(z.n.bitLength()/8),this.hash=E.sha512}g.exports=V,V.prototype.sign=function(z,F){z=G(z);var O=this.keyFromSecret(F),N=this.hashInt(O.messagePrefix(),z),j=this.g.mul(N),D=this.encodePoint(j),k=this.hashInt(D,O.pubBytes(),z).mul(O.priv()),A=N.add(k).umod(this.curve.n);return this.makeSignature({R:j,S:A,Rencoded:D})},V.prototype.verify=function(z,F,O){z=G(z),F=this.makeSignature(F);var N=this.keyFromPublic(O),j=this.hashInt(F.Rencoded(),N.pubBytes(),z),D=this.g.mul(F.S()),k=F.R().add(N.pub().mul(j));return k.eq(D)},V.prototype.hashInt=function(){for(var z=this.hash(),F=0;F<arguments.length;F++)z.update(arguments[F]);return U.intFromLE(z.digest()).umod(this.curve.n)},V.prototype.keyFromPublic=function(z){return W.fromPublic(this,z)},V.prototype.keyFromSecret=function(z){return W.fromSecret(this,z)},V.prototype.makeSignature=function(z){return z instanceof I?z:new I(this,z)},V.prototype.encodePoint=function(z){var F=z.getY().toArray("le",this.encodingLength);return F[this.encodingLength-1]|=z.getX().isOdd()?128:0,F},V.prototype.decodePoint=function(z){z=U.parseBytes(z);var F=z.length-1,O=z.slice(0,F).concat(z[F]&-129),N=(z[F]&128)!==0,j=U.intFromLE(O);return this.curve.pointFromY(j,N)},V.prototype.encodeInt=function(z){return z.toArray("le",this.encodingLength)},V.prototype.decodeInt=function(z){return U.intFromLE(z)},V.prototype.isPoint=function(z){return z instanceof this.pointClass}}),A9=G0((l)=>{var g=l;g.version=r7().version,g.utils=T5(),g.rand=q9(),g.curve=E6(),g.curves=x9(),g.ec=Z8(),g.eddsa=W8()}),v6=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),v9=G0((l,g)=>{var E=j5(),M=E.Buffer,U={},S;for(S in E)!E.hasOwnProperty(S)||S==="SlowBuffer"||S==="Buffer"||(U[S]=E[S]);var G=U.Buffer={};for(S in M)!M.hasOwnProperty(S)||S==="allocUnsafe"||S==="allocUnsafeSlow"||(G[S]=M[S]);if(U.Buffer.prototype=M.prototype,(!G.from||G.from===Uint8Array.from)&&(G.from=function(W,I,V){if(typeof W=="number")throw new TypeError('The "value" argument must not be of type number. Received type '+typeof W);if(W&&typeof W.length>"u")throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof W);return M(W,I,V)}),G.alloc||(G.alloc=function(W,I,V){if(typeof W!="number")throw new TypeError('The "size" argument must be of type number. Received type '+typeof W);if(W<0||W>=2147483648)throw new RangeError('The value "'+W+'" is invalid for option "size"');var z=M(W);return!I||I.length===0?z.fill(0):typeof V=="string"?z.fill(I,V):z.fill(I),z}),!U.kStringMaxLength)try{U.kStringMaxLength=process.binding("buffer").kStringMaxLength}catch{}U.constants||(U.constants={MAX_LENGTH:U.kMaxLength},U.kStringMaxLength&&(U.constants.MAX_STRING_LENGTH=U.kStringMaxLength)),g.exports=U}),M9=G0((l)=>{var g=p0();function E(U){this._reporterState={obj:null,path:[],options:U||{},errors:[]}}l.Reporter=E,E.prototype.isError=function(U){return U instanceof M},E.prototype.save=function(){let U=this._reporterState;return{obj:U.obj,pathLen:U.path.length}},E.prototype.restore=function(U){let S=this._reporterState;S.obj=U.obj,S.path=S.path.slice(0,U.pathLen)},E.prototype.enterKey=function(U){return this._reporterState.path.push(U)},E.prototype.exitKey=function(U){let S=this._reporterState;S.path=S.path.slice(0,U-1)},E.prototype.leaveKey=function(U,S,G){let W=this._reporterState;this.exitKey(U),W.obj!==null&&(W.obj[S]=G)},E.prototype.path=function(){return this._reporterState.path.join("/")},E.prototype.enterObject=function(){let U=this._reporterState,S=U.obj;return U.obj={},S},E.prototype.leaveObject=function(U){let S=this._reporterState,G=S.obj;return S.obj=U,G},E.prototype.error=function(U){let S,G=this._reporterState,W=U instanceof M;if(W?S=U:S=new M(G.path.map(function(I){return"["+JSON.stringify(I)+"]"}).join(""),U.message||U,U.stack),!G.options.partial)throw S;return W||G.errors.push(S),S},E.prototype.wrapResult=function(U){let S=this._reporterState;return S.options.partial?{result:this.isError(U)?null:U,errors:S.errors}:U};function M(U,S){this.path=U,this.rethrow(S)}g(M,Error),M.prototype.rethrow=function(U){if(this.message=U+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,M),!this.stack)try{throw new Error(this.message)}catch(S){this.stack=S.stack}return this}}),l5=G0((l)=>{var g=p0(),E=M9().Reporter,M=v9().Buffer;function U(G,W){if(E.call(this,W),!M.isBuffer(G)){this.error("Input not Buffer");return}this.base=G,this.offset=0,this.length=G.length}g(U,E),l.DecoderBuffer=U,U.isDecoderBuffer=function(G){return G instanceof U?!0:typeof G=="object"&&M.isBuffer(G.base)&&G.constructor.name==="DecoderBuffer"&&typeof G.offset=="number"&&typeof G.length=="number"&&typeof G.save=="function"&&typeof G.restore=="function"&&typeof G.isEmpty=="function"&&typeof G.readUInt8=="function"&&typeof G.skip=="function"&&typeof G.raw=="function"},U.prototype.save=function(){return{offset:this.offset,reporter:E.prototype.save.call(this)}},U.prototype.restore=function(G){let W=new U(this.base);return W.offset=G.offset,W.length=this.offset,this.offset=G.offset,E.prototype.restore.call(this,G.reporter),W},U.prototype.isEmpty=function(){return this.offset===this.length},U.prototype.readUInt8=function(G){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(G||"DecoderBuffer overrun")},U.prototype.skip=function(G,W){if(!(this.offset+G<=this.length))return this.error(W||"DecoderBuffer overrun");let I=new U(this.base);return I._reporterState=this._reporterState,I.offset=this.offset,I.length=this.offset+G,this.offset+=G,I},U.prototype.raw=function(G){return this.base.slice(G?G.offset:this.offset,this.length)};function S(G,W){if(Array.isArray(G))this.length=0,this.value=G.map(function(I){return S.isEncoderBuffer(I)||(I=new S(I,W)),this.length+=I.length,I},this);else if(typeof G=="number"){if(!(0<=G&&G<=255))return W.error("non-byte EncoderBuffer value");this.value=G,this.length=1}else if(typeof G=="string")this.value=G,this.length=M.byteLength(G);else if(M.isBuffer(G))this.value=G,this.length=G.length;else return W.error("Unsupported type: "+typeof G)}l.EncoderBuffer=S,S.isEncoderBuffer=function(G){return G instanceof S?!0:typeof G=="object"&&G.constructor.name==="EncoderBuffer"&&typeof G.length=="number"&&typeof G.join=="function"},S.prototype.join=function(G,W){return G||(G=M.alloc(this.length)),W||(W=0),this.length===0||(Array.isArray(this.value)?this.value.forEach(function(I){I.join(G,W),W+=I.length}):(typeof this.value=="number"?G[W]=this.value:typeof this.value=="string"?G.write(this.value,W):M.isBuffer(this.value)&&this.value.copy(G,W),W+=this.length)),G}}),_9=G0((l,g)=>{var E=M9().Reporter,M=l5().EncoderBuffer,U=l5().DecoderBuffer,S=V5(),G=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],W=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(G),I=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function V(F,O,N){let j={};this._baseState=j,j.name=N,j.enc=F,j.parent=O||null,j.children=null,j.tag=null,j.args=null,j.reverseArgs=null,j.choice=null,j.optional=!1,j.any=!1,j.obj=!1,j.use=null,j.useDecoder=null,j.key=null,j.default=null,j.explicit=null,j.implicit=null,j.contains=null,j.parent||(j.children=[],this._wrap())}g.exports=V;var z=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];V.prototype.clone=function(){let F=this._baseState,O={};z.forEach(function(j){O[j]=F[j]});let N=new this.constructor(O.parent);return N._baseState=O,N},V.prototype._wrap=function(){let F=this._baseState;W.forEach(function(O){this[O]=function(){let N=new this.constructor(this);return F.children.push(N),N[O].apply(N,arguments)}},this)},V.prototype._init=function(F){let O=this._baseState;S(O.parent===null),F.call(this),O.children=O.children.filter(function(N){return N._baseState.parent===this},this),S.equal(O.children.length,1,"Root node can have only one child")},V.prototype._useArgs=function(F){let O=this._baseState,N=F.filter(function(j){return j instanceof this.constructor},this);F=F.filter(function(j){return!(j instanceof this.constructor)},this),N.length!==0&&(S(O.children===null),O.children=N,N.forEach(function(j){j._baseState.parent=this},this)),F.length!==0&&(S(O.args===null),O.args=F,O.reverseArgs=F.map(function(j){if(typeof j!="object"||j.constructor!==Object)return j;let D={};return Object.keys(j).forEach(function(k){k==(k|0)&&(k|=0);let A=j[k];D[A]=k}),D}))},I.forEach(function(F){V.prototype[F]=function(){let O=this._baseState;throw new Error(F+" not implemented for encoding: "+O.enc)}}),G.forEach(function(F){V.prototype[F]=function(){let O=this._baseState,N=Array.prototype.slice.call(arguments);return S(O.tag===null),O.tag=F,this._useArgs(N),this}}),V.prototype.use=function(F){S(F);let O=this._baseState;return S(O.use===null),O.use=F,this},V.prototype.optional=function(){let F=this._baseState;return F.optional=!0,this},V.prototype.def=function(F){let O=this._baseState;return S(O.default===null),O.default=F,O.optional=!0,this},V.prototype.explicit=function(F){let O=this._baseState;return S(O.explicit===null&&O.implicit===null),O.explicit=F,this},V.prototype.implicit=function(F){let O=this._baseState;return S(O.explicit===null&&O.implicit===null),O.implicit=F,this},V.prototype.obj=function(){let F=this._baseState,O=Array.prototype.slice.call(arguments);return F.obj=!0,O.length!==0&&this._useArgs(O),this},V.prototype.key=function(F){let O=this._baseState;return S(O.key===null),O.key=F,this},V.prototype.any=function(){let F=this._baseState;return F.any=!0,this},V.prototype.choice=function(F){let O=this._baseState;return S(O.choice===null),O.choice=F,this._useArgs(Object.keys(F).map(function(N){return F[N]})),this},V.prototype.contains=function(F){let O=this._baseState;return S(O.use===null),O.contains=F,this},V.prototype._decode=function(F,O){let N=this._baseState;if(N.parent===null)return F.wrapResult(N.children[0]._decode(F,O));let j=N.default,D=!0,k=null;if(N.key!==null&&(k=F.enterKey(N.key)),N.optional){let x=null;if(N.explicit!==null?x=N.explicit:N.implicit!==null?x=N.implicit:N.tag!==null&&(x=N.tag),x===null&&!N.any){let v=F.save();try{N.choice===null?this._decodeGeneric(N.tag,F,O):this._decodeChoice(F,O),D=!0}catch{D=!1}F.restore(v)}else if(D=this._peekTag(F,x,N.any),F.isError(D))return D}let A;if(N.obj&&D&&(A=F.enterObject()),D){if(N.explicit!==null){let v=this._decodeTag(F,N.explicit);if(F.isError(v))return v;F=v}let x=F.offset;if(N.use===null&&N.choice===null){let v;N.any&&(v=F.save());let y=this._decodeTag(F,N.implicit!==null?N.implicit:N.tag,N.any);if(F.isError(y))return y;N.any?j=F.raw(v):F=y}if(O&&O.track&&N.tag!==null&&O.track(F.path(),x,F.length,"tagged"),O&&O.track&&N.tag!==null&&O.track(F.path(),F.offset,F.length,"content"),N.any||(N.choice===null?j=this._decodeGeneric(N.tag,F,O):j=this._decodeChoice(F,O)),F.isError(j))return j;if(!N.any&&N.choice===null&&N.children!==null&&N.children.forEach(function(v){v._decode(F,O)}),N.contains&&(N.tag==="octstr"||N.tag==="bitstr")){let v=new U(j);j=this._getUse(N.contains,F._reporterState.obj)._decode(v,O)}}return N.obj&&D&&(j=F.leaveObject(A)),N.key!==null&&(j!==null||D===!0)?F.leaveKey(k,N.key,j):k!==null&&F.exitKey(k),j},V.prototype._decodeGeneric=function(F,O,N){let j=this._baseState;return F==="seq"||F==="set"?null:F==="seqof"||F==="setof"?this._decodeList(O,F,j.args[0],N):/str$/.test(F)?this._decodeStr(O,F,N):F==="objid"&&j.args?this._decodeObjid(O,j.args[0],j.args[1],N):F==="objid"?this._decodeObjid(O,null,null,N):F==="gentime"||F==="utctime"?this._decodeTime(O,F,N):F==="null_"?this._decodeNull(O,N):F==="bool"?this._decodeBool(O,N):F==="objDesc"?this._decodeStr(O,F,N):F==="int"||F==="enum"?this._decodeInt(O,j.args&&j.args[0],N):j.use!==null?this._getUse(j.use,O._reporterState.obj)._decode(O,N):O.error("unknown tag: "+F)},V.prototype._getUse=function(F,O){let N=this._baseState;return N.useDecoder=this._use(F,O),S(N.useDecoder._baseState.parent===null),N.useDecoder=N.useDecoder._baseState.children[0],N.implicit!==N.useDecoder._baseState.implicit&&(N.useDecoder=N.useDecoder.clone(),N.useDecoder._baseState.implicit=N.implicit),N.useDecoder},V.prototype._decodeChoice=function(F,O){let N=this._baseState,j=null,D=!1;return Object.keys(N.choice).some(function(k){let A=F.save(),x=N.choice[k];try{let v=x._decode(F,O);if(F.isError(v))return!1;j={type:k,value:v},D=!0}catch{return F.restore(A),!1}return!0},this),D?j:F.error("Choice not matched")},V.prototype._createEncoderBuffer=function(F){return new M(F,this.reporter)},V.prototype._encode=function(F,O,N){let j=this._baseState;if(j.default!==null&&j.default===F)return;let D=this._encodeValue(F,O,N);if(D!==void 0&&!this._skipDefault(D,O,N))return D},V.prototype._encodeValue=function(F,O,N){let j=this._baseState;if(j.parent===null)return j.children[0]._encode(F,O||new E);let D=null;if(this.reporter=O,j.optional&&F===void 0)if(j.default!==null)F=j.default;else return;let k=null,A=!1;if(j.any)D=this._createEncoderBuffer(F);else if(j.choice)D=this._encodeChoice(F,O);else if(j.contains)k=this._getUse(j.contains,N)._encode(F,O),A=!0;else if(j.children)k=j.children.map(function(x){if(x._baseState.tag==="null_")return x._encode(null,O,F);if(x._baseState.key===null)return O.error("Child should have a key");let v=O.enterKey(x._baseState.key);if(typeof F!="object")return O.error("Child expected, but input is not object");let y=x._encode(F[x._baseState.key],O,F);return O.leaveKey(v),y},this).filter(function(x){return x}),k=this._createEncoderBuffer(k);else if(j.tag==="seqof"||j.tag==="setof"){if(!(j.args&&j.args.length===1))return O.error("Too many args for : "+j.tag);if(!Array.isArray(F))return O.error("seqof/setof, but data is not Array");let x=this.clone();x._baseState.implicit=null,k=this._createEncoderBuffer(F.map(function(v){let y=this._baseState;return this._getUse(y.args[0],F)._encode(v,O)},x))}else j.use!==null?D=this._getUse(j.use,N)._encode(F,O):(k=this._encodePrimitive(j.tag,F),A=!0);if(!j.any&&j.choice===null){let x=j.implicit!==null?j.implicit:j.tag,v=j.implicit===null?"universal":"context";x===null?j.use===null&&O.error("Tag could be omitted only for .use()"):j.use===null&&(D=this._encodeComposite(x,A,v,k))}return j.explicit!==null&&(D=this._encodeComposite(j.explicit,!1,"context",D)),D},V.prototype._encodeChoice=function(F,O){let N=this._baseState,j=N.choice[F.type];return j||S(!1,F.type+" not found in "+JSON.stringify(Object.keys(N.choice))),j._encode(F.value,O)},V.prototype._encodePrimitive=function(F,O){let N=this._baseState;if(/str$/.test(F))return this._encodeStr(O,F);if(F==="objid"&&N.args)return this._encodeObjid(O,N.reverseArgs[0],N.args[1]);if(F==="objid")return this._encodeObjid(O,null,null);if(F==="gentime"||F==="utctime")return this._encodeTime(O,F);if(F==="null_")return this._encodeNull();if(F==="int"||F==="enum")return this._encodeInt(O,N.args&&N.reverseArgs[0]);if(F==="bool")return this._encodeBool(O);if(F==="objDesc")return this._encodeStr(O,F);throw new Error("Unsupported tag: "+F)},V.prototype._isNumstr=function(F){return/^[0-9 ]*$/.test(F)},V.prototype._isPrintstr=function(F){return/^[A-Za-z0-9 '()+,-./:=?]*$/.test(F)}}),w9=G0((l)=>{function g(E){let M={};return Object.keys(E).forEach(function(U){(U|0)==U&&(U=U|0);let S=E[U];M[S]=U}),M}l.tagClass={0:"universal",1:"application",2:"context",3:"private"},l.tagClassByName=g(l.tagClass),l.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},l.tagByName=g(l.tag)}),M6=G0((l,g)=>{var E=p0(),M=v9().Buffer,U=_9(),S=w9();function G(z){this.enc="der",this.name=z.name,this.entity=z,this.tree=new W,this.tree._init(z.body)}g.exports=G,G.prototype.encode=function(z,F){return this.tree._encode(z,F).join()};function W(z){U.call(this,"der",z)}E(W,U),W.prototype._encodeComposite=function(z,F,O,N){let j=V(z,F,O,this.reporter);if(N.length<128){let A=M.alloc(2);return A[0]=j,A[1]=N.length,this._createEncoderBuffer([A,N])}let D=1;for(let A=N.length;A>=256;A>>=8)D++;let k=M.alloc(2+D);k[0]=j,k[1]=128|D;for(let A=1+D,x=N.length;x>0;A--,x>>=8)k[A]=x&255;return this._createEncoderBuffer([k,N])},W.prototype._encodeStr=function(z,F){if(F==="bitstr")return this._createEncoderBuffer([z.unused|0,z.data]);if(F==="bmpstr"){let O=M.alloc(z.length*2);for(let N=0;N<z.length;N++)O.writeUInt16BE(z.charCodeAt(N),N*2);return this._createEncoderBuffer(O)}else return F==="numstr"?this._isNumstr(z)?this._createEncoderBuffer(z):this.reporter.error("Encoding of string type: numstr supports only digits and space"):F==="printstr"?this._isPrintstr(z)?this._createEncoderBuffer(z):this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark"):/str$/.test(F)?this._createEncoderBuffer(z):F==="objDesc"?this._createEncoderBuffer(z):this.reporter.error("Encoding of string type: "+F+" unsupported")},W.prototype._encodeObjid=function(z,F,O){if(typeof z=="string"){if(!F)return this.reporter.error("string objid given, but no values map found");if(!F.hasOwnProperty(z))return this.reporter.error("objid not found in values map");z=F[z].split(/[\s.]+/g);for(let k=0;k<z.length;k++)z[k]|=0}else if(Array.isArray(z)){z=z.slice();for(let k=0;k<z.length;k++)z[k]|=0}if(!Array.isArray(z))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(z));if(!O){if(z[1]>=40)return this.reporter.error("Second objid identifier OOB");z.splice(0,2,z[0]*40+z[1])}let N=0;for(let k=0;k<z.length;k++){let A=z[k];for(N++;A>=128;A>>=7)N++}let j=M.alloc(N),D=j.length-1;for(let k=z.length-1;k>=0;k--){let A=z[k];for(j[D--]=A&127;(A>>=7)>0;)j[D--]=128|A&127}return this._createEncoderBuffer(j)};function I(z){return z<10?"0"+z:z}W.prototype._encodeTime=function(z,F){let O,N=new Date(z);return F==="gentime"?O=[I(N.getUTCFullYear()),I(N.getUTCMonth()+1),I(N.getUTCDate()),I(N.getUTCHours()),I(N.getUTCMinutes()),I(N.getUTCSeconds()),"Z"].join(""):F==="utctime"?O=[I(N.getUTCFullYear()%100),I(N.getUTCMonth()+1),I(N.getUTCDate()),I(N.getUTCHours()),I(N.getUTCMinutes()),I(N.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+F+" time is not supported yet"),this._encodeStr(O,"octstr")},W.prototype._encodeNull=function(){return this._createEncoderBuffer("")},W.prototype._encodeInt=function(z,F){if(typeof z=="string"){if(!F)return this.reporter.error("String int or enum given, but no values map");if(!F.hasOwnProperty(z))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(z));z=F[z]}if(typeof z!="number"&&!M.isBuffer(z)){let j=z.toArray();!z.sign&&j[0]&128&&j.unshift(0),z=M.from(j)}if(M.isBuffer(z)){let j=z.length;z.length===0&&j++;let D=M.alloc(j);return z.copy(D),z.length===0&&(D[0]=0),this._createEncoderBuffer(D)}if(z<128)return this._createEncoderBuffer(z);if(z<256)return this._createEncoderBuffer([0,z]);let O=1;for(let j=z;j>=256;j>>=8)O++;let N=new Array(O);for(let j=N.length-1;j>=0;j--)N[j]=z&255,z>>=8;return N[0]&128&&N.unshift(0),this._createEncoderBuffer(M.from(N))},W.prototype._encodeBool=function(z){return this._createEncoderBuffer(z?255:0)},W.prototype._use=function(z,F){return typeof z=="function"&&(z=z(F)),z._getEncoder("der").tree},W.prototype._skipDefault=function(z,F,O){let N=this._baseState,j;if(N.default===null)return!1;let D=z.join();if(N.defaultBuffer===void 0&&(N.defaultBuffer=this._encodeValue(N.default,F,O).join()),D.length!==N.defaultBuffer.length)return!1;for(j=0;j<D.length;j++)if(D[j]!==N.defaultBuffer[j])return!1;return!0};function V(z,F,O,N){let j;if(z==="seqof"?z="seq":z==="setof"&&(z="set"),S.tagByName.hasOwnProperty(z))j=S.tagByName[z];else if(typeof z=="number"&&(z|0)===z)j=z;else return N.error("Unknown tag: "+z);return j>=31?N.error("Multi-octet tag encoding unsupported"):(F||(j|=32),j|=S.tagClassByName[O||"universal"]<<6,j)}}),j8=G0((l,g)=>{var E=p0(),M=M6();function U(S){M.call(this,S),this.enc="pem"}E(U,M),g.exports=U,U.prototype.encode=function(S,G){let W=M.prototype.encode.call(this,S).toString("base64"),I=["-----BEGIN "+G.label+"-----"];for(let V=0;V<W.length;V+=64)I.push(W.slice(V,V+64));return I.push("-----END "+G.label+"-----"),I.join(`
4
- `)}}),_6=G0((l)=>{var g=l;g.der=M6(),g.pem=j8()}),w6=G0((l,g)=>{var E=p0(),M=v6(),U=l5().DecoderBuffer,S=_9(),G=w9();function W(F){this.enc="der",this.name=F.name,this.entity=F,this.tree=new I,this.tree._init(F.body)}g.exports=W,W.prototype.decode=function(F,O){return U.isDecoderBuffer(F)||(F=new U(F,O)),this.tree._decode(F,O)};function I(F){S.call(this,"der",F)}E(I,S),I.prototype._peekTag=function(F,O,N){if(F.isEmpty())return!1;let j=F.save(),D=V(F,'Failed to peek tag: "'+O+'"');return F.isError(D)?D:(F.restore(j),D.tag===O||D.tagStr===O||D.tagStr+"of"===O||N)},I.prototype._decodeTag=function(F,O,N){let j=V(F,'Failed to decode tag of "'+O+'"');if(F.isError(j))return j;let D=z(F,j.primitive,'Failed to get length of "'+O+'"');if(F.isError(D))return D;if(!N&&j.tag!==O&&j.tagStr!==O&&j.tagStr+"of"!==O)return F.error('Failed to match tag: "'+O+'"');if(j.primitive||D!==null)return F.skip(D,'Failed to match body of: "'+O+'"');let k=F.save(),A=this._skipUntilEnd(F,'Failed to skip indefinite length body: "'+this.tag+'"');return F.isError(A)?A:(D=F.offset-k.offset,F.restore(k),F.skip(D,'Failed to match body of: "'+O+'"'))},I.prototype._skipUntilEnd=function(F,O){for(;;){let N=V(F,O);if(F.isError(N))return N;let j=z(F,N.primitive,O);if(F.isError(j))return j;let D;if(N.primitive||j!==null?D=F.skip(j):D=this._skipUntilEnd(F,O),F.isError(D))return D;if(N.tagStr==="end")break}},I.prototype._decodeList=function(F,O,N,j){let D=[];for(;!F.isEmpty();){let k=this._peekTag(F,"end");if(F.isError(k))return k;let A=N.decode(F,"der",j);if(F.isError(A)&&k)break;D.push(A)}return D},I.prototype._decodeStr=function(F,O){if(O==="bitstr"){let N=F.readUInt8();return F.isError(N)?N:{unused:N,data:F.raw()}}else if(O==="bmpstr"){let N=F.raw();if(N.length%2===1)return F.error("Decoding of string type: bmpstr length mismatch");let j="";for(let D=0;D<N.length/2;D++)j+=String.fromCharCode(N.readUInt16BE(D*2));return j}else if(O==="numstr"){let N=F.raw().toString("ascii");return this._isNumstr(N)?N:F.error("Decoding of string type: numstr unsupported characters")}else{if(O==="octstr")return F.raw();if(O==="objDesc")return F.raw();if(O==="printstr"){let N=F.raw().toString("ascii");return this._isPrintstr(N)?N:F.error("Decoding of string type: printstr unsupported characters")}else return/str$/.test(O)?F.raw().toString():F.error("Decoding of string type: "+O+" unsupported")}},I.prototype._decodeObjid=function(F,O,N){let j,D=[],k=0,A=0;for(;!F.isEmpty();)A=F.readUInt8(),k<<=7,k|=A&127,(A&128)===0&&(D.push(k),k=0);A&128&&D.push(k);let x=D[0]/40|0,v=D[0]%40;if(N?j=D:j=[x,v].concat(D.slice(1)),O){let y=O[j.join(" ")];y===void 0&&(y=O[j.join(".")]),y!==void 0&&(j=y)}return j},I.prototype._decodeTime=function(F,O){let N=F.raw().toString(),j,D,k,A,x,v;if(O==="gentime")j=N.slice(0,4)|0,D=N.slice(4,6)|0,k=N.slice(6,8)|0,A=N.slice(8,10)|0,x=N.slice(10,12)|0,v=N.slice(12,14)|0;else if(O==="utctime")j=N.slice(0,2)|0,D=N.slice(2,4)|0,k=N.slice(4,6)|0,A=N.slice(6,8)|0,x=N.slice(8,10)|0,v=N.slice(10,12)|0,j<70?j=2000+j:j=1900+j;else return F.error("Decoding "+O+" time is not supported yet");return Date.UTC(j,D-1,k,A,x,v,0)},I.prototype._decodeNull=function(){return null},I.prototype._decodeBool=function(F){let O=F.readUInt8();return F.isError(O)?O:O!==0},I.prototype._decodeInt=function(F,O){let N=F.raw(),j=new M(N);return O&&(j=O[j.toString(10)]||j),j},I.prototype._use=function(F,O){return typeof F=="function"&&(F=F(O)),F._getDecoder("der").tree};function V(F,O){let N=F.readUInt8(O);if(F.isError(N))return N;let j=G.tagClass[N>>6],D=(N&32)===0;if((N&31)===31){let A=N;for(N=0;(A&128)===128;){if(A=F.readUInt8(O),F.isError(A))return A;N<<=7,N|=A&127}}else N&=31;let k=G.tag[N];return{cls:j,primitive:D,tag:N,tagStr:k}}function z(F,O,N){let j=F.readUInt8(N);if(F.isError(j))return j;if(!O&&j===128)return null;if((j&128)===0)return j;let D=j&127;if(D>4)return F.error("length octect is too long");j=0;for(let k=0;k<D;k++){j<<=8;let A=F.readUInt8(N);if(F.isError(A))return A;j|=A}return j}}),z8=G0((l,g)=>{var E=p0(),M=v9().Buffer,U=w6();function S(G){U.call(this,G),this.enc="pem"}E(S,U),g.exports=S,S.prototype.decode=function(G,W){let I=G.toString().split(/[\r\n]+/g),V=W.label.toUpperCase(),z=/^-----(BEGIN|END) ([^-]+)-----$/,F=-1,O=-1;for(let D=0;D<I.length;D++){let k=I[D].match(z);if(k!==null&&k[2]===V)if(F===-1){if(k[1]!=="BEGIN")break;F=D}else{if(k[1]!=="END")break;O=D;break}}if(F===-1||O===-1)throw new Error("PEM section not found for: "+V);let N=I.slice(F+1,O).join("");N.replace(/[^a-z0-9+/=]+/gi,"");let j=M.from(N,"base64");return U.prototype.decode.call(this,j,W)}}),y6=G0((l)=>{var g=l;g.der=w6(),g.pem=z8()}),O8=G0((l)=>{var g=_6(),E=y6(),M=p0(),U=l;U.define=function(G,W){return new S(G,W)};function S(G,W){this.name=G,this.body=W,this.decoders={},this.encoders={}}S.prototype._createNamed=function(G){let W=this.name;function I(V){this._initNamed(V,W)}return M(I,G),I.prototype._initNamed=function(V,z){G.call(this,V,z)},new I(this)},S.prototype._getDecoder=function(G){return G=G||"der",this.decoders.hasOwnProperty(G)||(this.decoders[G]=this._createNamed(E[G])),this.decoders[G]},S.prototype.decode=function(G,W,I){return this._getDecoder(W).decode(G,I)},S.prototype._getEncoder=function(G){return G=G||"der",this.encoders.hasOwnProperty(G)||(this.encoders[G]=this._createNamed(g[G])),this.encoders[G]},S.prototype.encode=function(G,W,I){return this._getEncoder(W).encode(G,I)}}),V8=G0((l)=>{var g=l;g.Reporter=M9().Reporter,g.DecoderBuffer=l5().DecoderBuffer,g.EncoderBuffer=l5().EncoderBuffer,g.Node=_9()}),T8=G0((l)=>{var g=l;g._reverse=function(E){let M={};return Object.keys(E).forEach(function(U){(U|0)==U&&(U=U|0);let S=E[U];M[S]=U}),M},g.der=w9()}),g6=G0((l)=>{var g=l;g.bignum=v6(),g.define=O8().define,g.base=V8(),g.constants=T8(),g.decoders=y6(),g.encoders=_6()}),D8=G0((l,g)=>{var E=g6(),M=E.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),U=E.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),S=E.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),G=E.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(S),this.key("subjectPublicKey").bitstr())}),W=E.define("RelativeDistinguishedName",function(){this.setof(U)}),I=E.define("RDNSequence",function(){this.seqof(W)}),V=E.define("Name",function(){this.choice({rdnSequence:this.use(I)})}),z=E.define("Validity",function(){this.seq().obj(this.key("notBefore").use(M),this.key("notAfter").use(M))}),F=E.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),O=E.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(S),this.key("issuer").use(V),this.key("validity").use(z),this.key("subject").use(V),this.key("subjectPublicKeyInfo").use(G),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(F).optional())}),N=E.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(O),this.key("signatureAlgorithm").use(S),this.key("signatureValue").bitstr())});g.exports=N}),N8=G0((l)=>{var g=g6();l.certificate=D8();var E=g.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});l.RSAPrivateKey=E;var M=g.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});l.RSAPublicKey=M;var U=g.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(S),this.key("subjectPublicKey").bitstr())});l.PublicKey=U;var S=g.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),G=g.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(S),this.key("subjectPrivateKey").octstr())});l.PrivateKey=G;var W=g.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});l.EncryptedPrivateKey=W;var I=g.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});l.DSAPrivateKey=I,l.DSAparam=g.define("DSAparam",function(){this.int()});var V=g.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(z),this.key("publicKey").optional().explicit(1).bitstr())});l.ECPrivateKey=V;var z=g.define("ECParameters",function(){this.choice({namedCurve:this.objid()})});l.signature=g.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})}),L8=G0((l,g)=>{g.exports={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}}),I8=G0((l,g)=>{var E=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,M=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,U=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,S=C9(),G=k9(),W=d0().Buffer;g.exports=function(I,V){var z=I.toString(),F=z.match(E),O;if(F){var N="aes"+F[1],j=W.from(F[2],"hex"),D=W.from(F[3].replace(/[\r\n]/g,""),"base64"),k=S(V,j.slice(0,8),parseInt(F[1],10)).key,A=[],x=G.createDecipheriv(N,k,j);A.push(x.update(D)),A.push(x.final()),O=W.concat(A)}else{var v=z.match(U);O=W.from(v[2].replace(/[\r\n]/g,""),"base64")}var y=z.match(M)[1];return{tag:y,data:O}}}),H9=G0((l,g)=>{var E=N8(),M=L8(),U=I8(),S=k9(),G=Z6(),W=d0().Buffer;g.exports=I;function I(z){var F;typeof z=="object"&&!W.isBuffer(z)&&(F=z.passphrase,z=z.key),typeof z=="string"&&(z=W.from(z));var O=U(z,F),N=O.tag,j=O.data,D,k;switch(N){case"CERTIFICATE":k=E.certificate.decode(j,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":switch(k||(k=E.PublicKey.decode(j,"der")),D=k.algorithm.algorithm.join("."),D){case"1.2.840.113549.1.1.1":return E.RSAPublicKey.decode(k.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return k.subjectPrivateKey=k.subjectPublicKey,{type:"ec",data:k};case"1.2.840.10040.4.1":return k.algorithm.params.pub_key=E.DSAparam.decode(k.subjectPublicKey.data,"der"),{type:"dsa",data:k.algorithm.params};default:throw new Error("unknown key id "+D)}case"ENCRYPTED PRIVATE KEY":j=E.EncryptedPrivateKey.decode(j,"der"),j=V(j,F);case"PRIVATE KEY":switch(k=E.PrivateKey.decode(j,"der"),D=k.algorithm.algorithm.join("."),D){case"1.2.840.113549.1.1.1":return E.RSAPrivateKey.decode(k.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:k.algorithm.curve,privateKey:E.ECPrivateKey.decode(k.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return k.algorithm.params.priv_key=E.DSAparam.decode(k.subjectPrivateKey,"der"),{type:"dsa",params:k.algorithm.params};default:throw new Error("unknown key id "+D)}case"RSA PUBLIC KEY":return E.RSAPublicKey.decode(j,"der");case"RSA PRIVATE KEY":return E.RSAPrivateKey.decode(j,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:E.DSAPrivateKey.decode(j,"der")};case"EC PRIVATE KEY":return j=E.ECPrivateKey.decode(j,"der"),{curve:j.parameters.value,privateKey:j.privateKey};default:throw new Error("unknown key type "+N)}}I.signature=E.signature;function V(z,F){var O=z.algorithm.decrypt.kde.kdeparams.salt,N=parseInt(z.algorithm.decrypt.kde.kdeparams.iters.toString(),10),j=M[z.algorithm.decrypt.cipher.algo.join(".")],D=z.algorithm.decrypt.cipher.iv,k=z.subjectPrivateKey,A=parseInt(j.split("-")[1],10)/8,x=G.pbkdf2Sync(F,O,N,A,"sha1"),v=S.createDecipheriv(j,x,D),y=[];return y.push(v.update(k)),y.push(v.final()),W.concat(y)}}),m6=G0((l,g)=>{g.exports={"1.3.132.0.10":"secp256k1","1.3.132.0.33":"p224","1.2.840.10045.3.1.1":"p192","1.2.840.10045.3.1.7":"p256","1.3.132.0.34":"p384","1.3.132.0.35":"p521"}}),k8=G0((l,g)=>{var E=d0().Buffer,M=Y6(),U=E9(),S=A9().ec,G=R9(),W=H9(),I=m6();function V(x,v,y,p,c){var n=W(v);if(n.curve){if(p!=="ecdsa"&&p!=="ecdsa/rsa")throw new Error("wrong private key type");return z(x,n)}else if(n.type==="dsa"){if(p!=="dsa")throw new Error("wrong private key type");return F(x,n,y)}else if(p!=="rsa"&&p!=="ecdsa/rsa")throw new Error("wrong private key type");x=E.concat([c,x]);for(var i=n.modulus.byteLength(),H0=[0,1];x.length+H0.length+1<i;)H0.push(255);H0.push(0);for(var a=-1;++a<x.length;)H0.push(x[a]);var P0=U(H0,n);return P0}function z(x,v){var y=I[v.curve.join(".")];if(!y)throw new Error("unknown curve "+v.curve.join("."));var p=new S(y),c=p.keyFromPrivate(v.privateKey),n=c.sign(x);return E.from(n.toDER())}function F(x,v,y){for(var p=v.params.priv_key,c=v.params.p,n=v.params.q,i=v.params.g,H0=new G(0),a,P0=j(x,n).mod(n),K=!1,X=N(p,n,x,y);K===!1;)a=k(n,X,y),H0=A(i,a,c,n),K=a.invm(n).imul(P0.add(p.mul(H0))).mod(n),K.cmpn(0)===0&&(K=!1,H0=new G(0));return O(H0,K)}function O(x,v){x=x.toArray(),v=v.toArray(),x[0]&128&&(x=[0].concat(x)),v[0]&128&&(v=[0].concat(v));var y=x.length+v.length+4,p=[48,y,2,x.length];return p=p.concat(x,[2,v.length],v),E.from(p)}function N(x,v,y,p){if(x=E.from(x.toArray()),x.length<v.byteLength()){var c=E.alloc(v.byteLength()-x.length);x=E.concat([c,x])}var n=y.length,i=D(y,v),H0=E.alloc(n);H0.fill(1);var a=E.alloc(n);return a=M(p,a).update(H0).update(E.from([0])).update(x).update(i).digest(),H0=M(p,a).update(H0).digest(),a=M(p,a).update(H0).update(E.from([1])).update(x).update(i).digest(),H0=M(p,a).update(H0).digest(),{k:a,v:H0}}function j(x,v){var y=new G(x),p=(x.length<<3)-v.bitLength();return p>0&&y.ishrn(p),y}function D(x,v){x=j(x,v),x=x.mod(v);var y=E.from(x.toArray());if(y.length<v.byteLength()){var p=E.alloc(v.byteLength()-y.length);y=E.concat([p,y])}return y}function k(x,v,y){var p,c;do{for(p=E.alloc(0);p.length*8<x.bitLength();)v.v=M(y,v.k).update(v.v).digest(),p=E.concat([p,v.v]);c=j(p,x),v.k=M(y,v.k).update(v.v).update(E.from([0])).digest(),v.v=M(y,v.k).update(v.v).digest()}while(c.cmp(x)!==-1);return c}function A(x,v,y,p){return x.toRed(G.mont(y)).redPow(v).fromRed().mod(p)}g.exports=V,g.exports.getKey=N,g.exports.makeKey=k}),q8=G0((l,g)=>{var E=d0().Buffer,M=R9(),U=A9().ec,S=H9(),G=m6();function W(F,O,N,j,D){var k=S(N);if(k.type==="ec"){if(j!=="ecdsa"&&j!=="ecdsa/rsa")throw new Error("wrong public key type");return I(F,O,k)}else if(k.type==="dsa"){if(j!=="dsa")throw new Error("wrong public key type");return V(F,O,k)}else if(j!=="rsa"&&j!=="ecdsa/rsa")throw new Error("wrong public key type");O=E.concat([D,O]);for(var A=k.modulus.byteLength(),x=[1],v=0;O.length+x.length+2<A;)x.push(255),v++;x.push(0);for(var y=-1;++y<O.length;)x.push(O[y]);x=E.from(x);var p=M.mont(k.modulus);F=new M(F).toRed(p),F=F.redPow(new M(k.publicExponent)),F=E.from(F.fromRed().toArray());var c=v<8?1:0;for(A=Math.min(F.length,x.length),F.length!==x.length&&(c=1),y=-1;++y<A;)c|=F[y]^x[y];return c===0}function I(F,O,N){var j=G[N.data.algorithm.curve.join(".")];if(!j)throw new Error("unknown curve "+N.data.algorithm.curve.join("."));var D=new U(j),k=N.data.subjectPrivateKey.data;return D.verify(O,F,k)}function V(F,O,N){var j=N.data.p,D=N.data.q,k=N.data.g,A=N.data.pub_key,x=S.signature.decode(F,"der"),v=x.s,y=x.r;z(v,D),z(y,D);var p=M.mont(j),c=v.invm(D),n=k.toRed(p).redPow(new M(O).mul(c).mod(D)).fromRed().mul(A.toRed(p).redPow(y.mul(c).mod(D)).fromRed()).mod(j).mod(D);return n.cmp(y)===0}function z(F,O){if(F.cmpn(0)<=0)throw new Error("invalid sig");if(F.cmp(O)>=O)throw new Error("invalid sig")}g.exports=W}),B8=G0((l,g)=>{var E=d0().Buffer,M=h5(),U=n7(),S=p0(),G=k8(),W=q8(),I=Q6();Object.keys(I).forEach(function(N){I[N].id=E.from(I[N].id,"hex"),I[N.toLowerCase()]=I[N]});function V(N){U.Writable.call(this);var j=I[N];if(!j)throw new Error("Unknown message digest");this._hashType=j.hash,this._hash=M(j.hash),this._tag=j.id,this._signType=j.sign}S(V,U.Writable),V.prototype._write=function(N,j,D){this._hash.update(N),D()},V.prototype.update=function(N,j){return typeof N=="string"&&(N=E.from(N,j)),this._hash.update(N),this},V.prototype.sign=function(N,j){this.end();var D=this._hash.digest(),k=G(D,N,this._hashType,this._signType,this._tag);return j?k.toString(j):k};function z(N){U.Writable.call(this);var j=I[N];if(!j)throw new Error("Unknown message digest");this._hash=M(j.hash),this._tag=j.id,this._signType=j.sign}S(z,U.Writable),z.prototype._write=function(N,j,D){this._hash.update(N),D()},z.prototype.update=function(N,j){return typeof N=="string"&&(N=E.from(N,j)),this._hash.update(N),this},z.prototype.verify=function(N,j,D){typeof j=="string"&&(j=E.from(j,D)),this.end();var k=this._hash.digest();return W(j,k,N,this._signType,this._tag)};function F(N){return new V(N)}function O(N){return new z(N)}g.exports={Sign:F,Verify:O,createSign:F,createVerify:O}}),R8=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),E8=G0((l,g)=>{var E=A9(),M=R8();g.exports=function(W){return new S(W)};var U={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};U.p224=U.secp224r1,U.p256=U.secp256r1=U.prime256v1,U.p192=U.secp192r1=U.prime192v1,U.p384=U.secp384r1,U.p521=U.secp521r1;function S(W){this.curveType=U[W],this.curveType||(this.curveType={name:W}),this.curve=new E.ec(this.curveType.name),this.keys=void 0}S.prototype.generateKeys=function(W,I){return this.keys=this.curve.genKeyPair(),this.getPublicKey(W,I)},S.prototype.computeSecret=function(W,I,V){I=I||"utf8",Buffer.isBuffer(W)||(W=new Buffer(W,I));var z=this.curve.keyFromPublic(W).getPublic(),F=z.mul(this.keys.getPrivate()).getX();return G(F,V,this.curveType.byteLength)},S.prototype.getPublicKey=function(W,I){var V=this.keys.getPublic(I==="compressed",!0);return I==="hybrid"&&(V[V.length-1]%2?V[0]=7:V[0]=6),G(V,W)},S.prototype.getPrivateKey=function(W){return G(this.keys.getPrivate(),W)},S.prototype.setPublicKey=function(W,I){return I=I||"utf8",Buffer.isBuffer(W)||(W=new Buffer(W,I)),this.keys._importPublic(W),this},S.prototype.setPrivateKey=function(W,I){I=I||"utf8",Buffer.isBuffer(W)||(W=new Buffer(W,I));var V=new M(W);return V=V.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(V),this};function G(W,I,V){Array.isArray(W)||(W=W.toArray());var z=new Buffer(W);if(V&&z.length<V){var F=new Buffer(V-z.length);F.fill(0),z=Buffer.concat([F,z])}return I?z.toString(I):z}}),p6=G0((l,g)=>{var E=h5(),M=d0().Buffer;g.exports=function(S,G){for(var W=M.alloc(0),I=0,V;W.length<G;)V=U(I++),W=M.concat([W,E("sha1").update(S).update(V).digest()]);return W.slice(0,G)};function U(S){var G=M.allocUnsafe(4);return G.writeUInt32BE(S,0),G}}),b6=G0((l,g)=>{g.exports=function(E,M){for(var U=E.length,S=-1;++S<U;)E[S]^=M[S];return E}}),y9=G0((l,g)=>{(function(E,M){function U(K,X){if(!K)throw new Error(X||"Assertion failed")}function S(K,X){K.super_=X;var Y=function(){};Y.prototype=X.prototype,K.prototype=new Y,K.prototype.constructor=K}function G(K,X,Y){if(G.isBN(K))return K;this.negative=0,this.words=null,this.length=0,this.red=null,K!==null&&((X==="le"||X==="be")&&(Y=X,X=10),this._init(K||0,X||10,Y||"be"))}typeof E=="object"?E.exports=G:M.BN=G,G.BN=G,G.wordSize=26;var W;try{typeof window<"u"&&typeof window.Buffer<"u"?W=window.Buffer:W=M5().Buffer}catch{}G.isBN=function(K){return K instanceof G?!0:K!==null&&typeof K=="object"&&K.constructor.wordSize===G.wordSize&&Array.isArray(K.words)},G.max=function(K,X){return K.cmp(X)>0?K:X},G.min=function(K,X){return K.cmp(X)<0?K:X},G.prototype._init=function(K,X,Y){if(typeof K=="number")return this._initNumber(K,X,Y);if(typeof K=="object")return this._initArray(K,X,Y);X==="hex"&&(X=16),U(X===(X|0)&&X>=2&&X<=36),K=K.toString().replace(/\s+/g,"");var H=0;K[0]==="-"&&(H++,this.negative=1),H<K.length&&(X===16?this._parseHex(K,H,Y):(this._parseBase(K,X,H),Y==="le"&&this._initArray(this.toArray(),X,Y)))},G.prototype._initNumber=function(K,X,Y){K<0&&(this.negative=1,K=-K),K<67108864?(this.words=[K&67108863],this.length=1):K<4503599627370496?(this.words=[K&67108863,K/67108864&67108863],this.length=2):(U(K<9007199254740992),this.words=[K&67108863,K/67108864&67108863,1],this.length=3),Y==="le"&&this._initArray(this.toArray(),X,Y)},G.prototype._initArray=function(K,X,Y){if(U(typeof K.length=="number"),K.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(K.length/3),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q,P,Z=0;if(Y==="be")for(H=K.length-1,Q=0;H>=0;H-=3)P=K[H]|K[H-1]<<8|K[H-2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);else if(Y==="le")for(H=0,Q=0;H<K.length;H+=3)P=K[H]|K[H+1]<<8|K[H+2]<<16,this.words[Q]|=P<<Z&67108863,this.words[Q+1]=P>>>26-Z&67108863,Z+=24,Z>=26&&(Z-=26,Q++);return this.strip()};function I(K,X){var Y=K.charCodeAt(X);return Y>=65&&Y<=70?Y-55:Y>=97&&Y<=102?Y-87:Y-48&15}function V(K,X,Y){var H=I(K,Y);return Y-1>=X&&(H|=I(K,Y-1)<<4),H}G.prototype._parseHex=function(K,X,Y){this.length=Math.ceil((K.length-X)/6),this.words=new Array(this.length);for(var H=0;H<this.length;H++)this.words[H]=0;var Q=0,P=0,Z;if(Y==="be")for(H=K.length-1;H>=X;H-=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8;else{var $=K.length-X;for(H=$%2===0?X+1:X;H<K.length;H+=2)Z=V(K,X,H)<<Q,this.words[P]|=Z&67108863,Q>=18?(Q-=18,P+=1,this.words[P]|=Z>>>26):Q+=8}this.strip()};function z(K,X,Y,H){for(var Q=0,P=Math.min(K.length,Y),Z=X;Z<P;Z++){var $=K.charCodeAt(Z)-48;Q*=H,$>=49?Q+=$-49+10:$>=17?Q+=$-17+10:Q+=$}return Q}G.prototype._parseBase=function(K,X,Y){this.words=[0],this.length=1;for(var H=0,Q=1;Q<=67108863;Q*=X)H++;H--,Q=Q/X|0;for(var P=K.length-Y,Z=P%H,$=Math.min(P,P-Z)+Y,C=0,J=Y;J<$;J+=H)C=z(K,J,J+H,X),this.imuln(Q),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C);if(Z!==0){var R=1;for(C=z(K,J,K.length,X),J=0;J<Z;J++)R*=X;this.imuln(R),this.words[0]+C<67108864?this.words[0]+=C:this._iaddn(C)}this.strip()},G.prototype.copy=function(K){K.words=new Array(this.length);for(var X=0;X<this.length;X++)K.words[X]=this.words[X];K.length=this.length,K.negative=this.negative,K.red=this.red},G.prototype.clone=function(){var K=new G(null);return this.copy(K),K},G.prototype._expand=function(K){for(;this.length<K;)this.words[this.length++]=0;return this},G.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},G.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},G.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var F=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],O=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],N=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];G.prototype.toString=function(K,X){K=K||10,X=X|0||1;var Y;if(K===16||K==="hex"){Y="";for(var H=0,Q=0,P=0;P<this.length;P++){var Z=this.words[P],$=((Z<<H|Q)&16777215).toString(16);Q=Z>>>24-H&16777215,Q!==0||P!==this.length-1?Y=F[6-$.length]+$+Y:Y=$+Y,H+=2,H>=26&&(H-=26,P--)}for(Q!==0&&(Y=Q.toString(16)+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}if(K===(K|0)&&K>=2&&K<=36){var C=O[K],J=N[K];Y="";var R=this.clone();for(R.negative=0;!R.isZero();){var L=R.modn(J).toString(K);R=R.idivn(J),R.isZero()?Y=L+Y:Y=F[C-L.length]+L+Y}for(this.isZero()&&(Y="0"+Y);Y.length%X!==0;)Y="0"+Y;return this.negative!==0&&(Y="-"+Y),Y}U(!1,"Base should be between 2 and 36")},G.prototype.toNumber=function(){var K=this.words[0];return this.length===2?K+=this.words[1]*67108864:this.length===3&&this.words[2]===1?K+=4503599627370496+this.words[1]*67108864:this.length>2&&U(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-K:K},G.prototype.toJSON=function(){return this.toString(16)},G.prototype.toBuffer=function(K,X){return U(typeof W<"u"),this.toArrayLike(W,K,X)},G.prototype.toArray=function(K,X){return this.toArrayLike(Array,K,X)},G.prototype.toArrayLike=function(K,X,Y){var H=this.byteLength(),Q=Y||Math.max(1,H);U(H<=Q,"byte array longer than desired length"),U(Q>0,"Requested array length <= 0"),this.strip();var P=X==="le",Z=new K(Q),$,C,J=this.clone();if(P){for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[C]=$;for(;C<Q;C++)Z[C]=0}else{for(C=0;C<Q-H;C++)Z[C]=0;for(C=0;!J.isZero();C++)$=J.andln(255),J.iushrn(8),Z[Q-C-1]=$}return Z},Math.clz32?G.prototype._countBits=function(K){return 32-Math.clz32(K)}:G.prototype._countBits=function(K){var X=K,Y=0;return X>=4096&&(Y+=13,X>>>=13),X>=64&&(Y+=7,X>>>=7),X>=8&&(Y+=4,X>>>=4),X>=2&&(Y+=2,X>>>=2),Y+X},G.prototype._zeroBits=function(K){if(K===0)return 26;var X=K,Y=0;return(X&8191)===0&&(Y+=13,X>>>=13),(X&127)===0&&(Y+=7,X>>>=7),(X&15)===0&&(Y+=4,X>>>=4),(X&3)===0&&(Y+=2,X>>>=2),(X&1)===0&&Y++,Y},G.prototype.bitLength=function(){var K=this.words[this.length-1],X=this._countBits(K);return(this.length-1)*26+X};function j(K){for(var X=new Array(K.bitLength()),Y=0;Y<X.length;Y++){var H=Y/26|0,Q=Y%26;X[Y]=(K.words[H]&1<<Q)>>>Q}return X}G.prototype.zeroBits=function(){if(this.isZero())return 0;for(var K=0,X=0;X<this.length;X++){var Y=this._zeroBits(this.words[X]);if(K+=Y,Y!==26)break}return K},G.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},G.prototype.toTwos=function(K){return this.negative!==0?this.abs().inotn(K).iaddn(1):this.clone()},G.prototype.fromTwos=function(K){return this.testn(K-1)?this.notn(K).iaddn(1).ineg():this.clone()},G.prototype.isNeg=function(){return this.negative!==0},G.prototype.neg=function(){return this.clone().ineg()},G.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},G.prototype.iuor=function(K){for(;this.length<K.length;)this.words[this.length++]=0;for(var X=0;X<K.length;X++)this.words[X]=this.words[X]|K.words[X];return this.strip()},G.prototype.ior=function(K){return U((this.negative|K.negative)===0),this.iuor(K)},G.prototype.or=function(K){return this.length>K.length?this.clone().ior(K):K.clone().ior(this)},G.prototype.uor=function(K){return this.length>K.length?this.clone().iuor(K):K.clone().iuor(this)},G.prototype.iuand=function(K){var X;this.length>K.length?X=K:X=this;for(var Y=0;Y<X.length;Y++)this.words[Y]=this.words[Y]&K.words[Y];return this.length=X.length,this.strip()},G.prototype.iand=function(K){return U((this.negative|K.negative)===0),this.iuand(K)},G.prototype.and=function(K){return this.length>K.length?this.clone().iand(K):K.clone().iand(this)},G.prototype.uand=function(K){return this.length>K.length?this.clone().iuand(K):K.clone().iuand(this)},G.prototype.iuxor=function(K){var X,Y;this.length>K.length?(X=this,Y=K):(X=K,Y=this);for(var H=0;H<Y.length;H++)this.words[H]=X.words[H]^Y.words[H];if(this!==X)for(;H<X.length;H++)this.words[H]=X.words[H];return this.length=X.length,this.strip()},G.prototype.ixor=function(K){return U((this.negative|K.negative)===0),this.iuxor(K)},G.prototype.xor=function(K){return this.length>K.length?this.clone().ixor(K):K.clone().ixor(this)},G.prototype.uxor=function(K){return this.length>K.length?this.clone().iuxor(K):K.clone().iuxor(this)},G.prototype.inotn=function(K){U(typeof K=="number"&&K>=0);var X=Math.ceil(K/26)|0,Y=K%26;this._expand(X),Y>0&&X--;for(var H=0;H<X;H++)this.words[H]=~this.words[H]&67108863;return Y>0&&(this.words[H]=~this.words[H]&67108863>>26-Y),this.strip()},G.prototype.notn=function(K){return this.clone().inotn(K)},G.prototype.setn=function(K,X){U(typeof K=="number"&&K>=0);var Y=K/26|0,H=K%26;return this._expand(Y+1),X?this.words[Y]=this.words[Y]|1<<H:this.words[Y]=this.words[Y]&~(1<<H),this.strip()},G.prototype.iadd=function(K){var X;if(this.negative!==0&&K.negative===0)return this.negative=0,X=this.isub(K),this.negative^=1,this._normSign();if(this.negative===0&&K.negative!==0)return K.negative=0,X=this.isub(K),K.negative=1,X._normSign();var Y,H;this.length>K.length?(Y=this,H=K):(Y=K,H=this);for(var Q=0,P=0;P<H.length;P++)X=(Y.words[P]|0)+(H.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;for(;Q!==0&&P<Y.length;P++)X=(Y.words[P]|0)+Q,this.words[P]=X&67108863,Q=X>>>26;if(this.length=Y.length,Q!==0)this.words[this.length]=Q,this.length++;else if(Y!==this)for(;P<Y.length;P++)this.words[P]=Y.words[P];return this},G.prototype.add=function(K){var X;return K.negative!==0&&this.negative===0?(K.negative=0,X=this.sub(K),K.negative^=1,X):K.negative===0&&this.negative!==0?(this.negative=0,X=K.sub(this),this.negative=1,X):this.length>K.length?this.clone().iadd(K):K.clone().iadd(this)},G.prototype.isub=function(K){if(K.negative!==0){K.negative=0;var X=this.iadd(K);return K.negative=1,X._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(K),this.negative=1,this._normSign();var Y=this.cmp(K);if(Y===0)return this.negative=0,this.length=1,this.words[0]=0,this;var H,Q;Y>0?(H=this,Q=K):(H=K,Q=this);for(var P=0,Z=0;Z<Q.length;Z++)X=(H.words[Z]|0)-(Q.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;for(;P!==0&&Z<H.length;Z++)X=(H.words[Z]|0)+P,P=X>>26,this.words[Z]=X&67108863;if(P===0&&Z<H.length&&H!==this)for(;Z<H.length;Z++)this.words[Z]=H.words[Z];return this.length=Math.max(this.length,Z),H!==this&&(this.negative=1),this.strip()},G.prototype.sub=function(K){return this.clone().isub(K)};function D(K,X,Y){Y.negative=X.negative^K.negative;var H=K.length+X.length|0;Y.length=H,H=H-1|0;var Q=K.words[0]|0,P=X.words[0]|0,Z=Q*P,$=Z&67108863,C=Z/67108864|0;Y.words[0]=$;for(var J=1;J<H;J++){for(var R=C>>>26,L=C&67108863,_=Math.min(J,X.length-1),s=Math.max(0,J-K.length+1);s<=_;s++){var r=J-s|0;Q=K.words[r]|0,P=X.words[s]|0,Z=Q*P+L,R+=Z/67108864|0,L=Z&67108863}Y.words[J]=L|0,C=R|0}return C!==0?Y.words[J]=C|0:Y.length--,Y.strip()}var k=function(K,X,Y){var H=K.words,Q=X.words,P=Y.words,Z=0,$,C,J,R=H[0]|0,L=R&8191,_=R>>>13,s=H[1]|0,r=s&8191,X0=s>>>13,u=H[2]|0,d=u&8191,f=u>>>13,z0=H[3]|0,K0=z0&8191,Q0=z0>>>13,w=H[4]|0,q=w&8191,m=w>>>13,e=H[5]|0,C0=e&8191,t=e>>>13,_0=H[6]|0,$0=_0&8191,J0=_0>>>13,w0=H[7]|0,j0=w0&8191,Z0=w0>>>13,c0=H[8]|0,T=c0&8191,B=c0>>>13,b=H[9]|0,h=b&8191,o=b>>>13,O0=Q[0]|0,Y0=O0&8191,F0=O0>>>13,b0=Q[1]|0,W0=b0&8191,U0=b0>>>13,y0=Q[2]|0,D0=y0&8191,N0=y0>>>13,G5=Q[3]|0,T0=G5&8191,V0=G5>>>13,l0=Q[4]|0,L0=l0&8191,I0=l0>>>13,J5=Q[5]|0,k0=J5&8191,q0=J5>>>13,P5=Q[6]|0,B0=P5&8191,R0=P5>>>13,Z5=Q[7]|0,E0=Z5&8191,S0=Z5>>>13,F5=Q[8]|0,x0=F5&8191,A0=F5>>>13,U5=Q[9]|0,v0=U5&8191,M0=U5>>>13;Y.negative=K.negative^X.negative,Y.length=19,$=Math.imul(L,Y0),C=Math.imul(L,F0),C=C+Math.imul(_,Y0)|0,J=Math.imul(_,F0);var $5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+($5>>>26)|0,$5&=67108863,$=Math.imul(r,Y0),C=Math.imul(r,F0),C=C+Math.imul(X0,Y0)|0,J=Math.imul(X0,F0),$=$+Math.imul(L,W0)|0,C=C+Math.imul(L,U0)|0,C=C+Math.imul(_,W0)|0,J=J+Math.imul(_,U0)|0;var g0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(g0>>>26)|0,g0&=67108863,$=Math.imul(d,Y0),C=Math.imul(d,F0),C=C+Math.imul(f,Y0)|0,J=Math.imul(f,F0),$=$+Math.imul(r,W0)|0,C=C+Math.imul(r,U0)|0,C=C+Math.imul(X0,W0)|0,J=J+Math.imul(X0,U0)|0,$=$+Math.imul(L,D0)|0,C=C+Math.imul(L,N0)|0,C=C+Math.imul(_,D0)|0,J=J+Math.imul(_,N0)|0;var m0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(m0>>>26)|0,m0&=67108863,$=Math.imul(K0,Y0),C=Math.imul(K0,F0),C=C+Math.imul(Q0,Y0)|0,J=Math.imul(Q0,F0),$=$+Math.imul(d,W0)|0,C=C+Math.imul(d,U0)|0,C=C+Math.imul(f,W0)|0,J=J+Math.imul(f,U0)|0,$=$+Math.imul(r,D0)|0,C=C+Math.imul(r,N0)|0,C=C+Math.imul(X0,D0)|0,J=J+Math.imul(X0,N0)|0,$=$+Math.imul(L,T0)|0,C=C+Math.imul(L,V0)|0,C=C+Math.imul(_,T0)|0,J=J+Math.imul(_,V0)|0;var u0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(u0>>>26)|0,u0&=67108863,$=Math.imul(q,Y0),C=Math.imul(q,F0),C=C+Math.imul(m,Y0)|0,J=Math.imul(m,F0),$=$+Math.imul(K0,W0)|0,C=C+Math.imul(K0,U0)|0,C=C+Math.imul(Q0,W0)|0,J=J+Math.imul(Q0,U0)|0,$=$+Math.imul(d,D0)|0,C=C+Math.imul(d,N0)|0,C=C+Math.imul(f,D0)|0,J=J+Math.imul(f,N0)|0,$=$+Math.imul(r,T0)|0,C=C+Math.imul(r,V0)|0,C=C+Math.imul(X0,T0)|0,J=J+Math.imul(X0,V0)|0,$=$+Math.imul(L,L0)|0,C=C+Math.imul(L,I0)|0,C=C+Math.imul(_,L0)|0,J=J+Math.imul(_,I0)|0;var o0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(o0>>>26)|0,o0&=67108863,$=Math.imul(C0,Y0),C=Math.imul(C0,F0),C=C+Math.imul(t,Y0)|0,J=Math.imul(t,F0),$=$+Math.imul(q,W0)|0,C=C+Math.imul(q,U0)|0,C=C+Math.imul(m,W0)|0,J=J+Math.imul(m,U0)|0,$=$+Math.imul(K0,D0)|0,C=C+Math.imul(K0,N0)|0,C=C+Math.imul(Q0,D0)|0,J=J+Math.imul(Q0,N0)|0,$=$+Math.imul(d,T0)|0,C=C+Math.imul(d,V0)|0,C=C+Math.imul(f,T0)|0,J=J+Math.imul(f,V0)|0,$=$+Math.imul(r,L0)|0,C=C+Math.imul(r,I0)|0,C=C+Math.imul(X0,L0)|0,J=J+Math.imul(X0,I0)|0,$=$+Math.imul(L,k0)|0,C=C+Math.imul(L,q0)|0,C=C+Math.imul(_,k0)|0,J=J+Math.imul(_,q0)|0;var s0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(s0>>>26)|0,s0&=67108863,$=Math.imul($0,Y0),C=Math.imul($0,F0),C=C+Math.imul(J0,Y0)|0,J=Math.imul(J0,F0),$=$+Math.imul(C0,W0)|0,C=C+Math.imul(C0,U0)|0,C=C+Math.imul(t,W0)|0,J=J+Math.imul(t,U0)|0,$=$+Math.imul(q,D0)|0,C=C+Math.imul(q,N0)|0,C=C+Math.imul(m,D0)|0,J=J+Math.imul(m,N0)|0,$=$+Math.imul(K0,T0)|0,C=C+Math.imul(K0,V0)|0,C=C+Math.imul(Q0,T0)|0,J=J+Math.imul(Q0,V0)|0,$=$+Math.imul(d,L0)|0,C=C+Math.imul(d,I0)|0,C=C+Math.imul(f,L0)|0,J=J+Math.imul(f,I0)|0,$=$+Math.imul(r,k0)|0,C=C+Math.imul(r,q0)|0,C=C+Math.imul(X0,k0)|0,J=J+Math.imul(X0,q0)|0,$=$+Math.imul(L,B0)|0,C=C+Math.imul(L,R0)|0,C=C+Math.imul(_,B0)|0,J=J+Math.imul(_,R0)|0;var a0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(a0>>>26)|0,a0&=67108863,$=Math.imul(j0,Y0),C=Math.imul(j0,F0),C=C+Math.imul(Z0,Y0)|0,J=Math.imul(Z0,F0),$=$+Math.imul($0,W0)|0,C=C+Math.imul($0,U0)|0,C=C+Math.imul(J0,W0)|0,J=J+Math.imul(J0,U0)|0,$=$+Math.imul(C0,D0)|0,C=C+Math.imul(C0,N0)|0,C=C+Math.imul(t,D0)|0,J=J+Math.imul(t,N0)|0,$=$+Math.imul(q,T0)|0,C=C+Math.imul(q,V0)|0,C=C+Math.imul(m,T0)|0,J=J+Math.imul(m,V0)|0,$=$+Math.imul(K0,L0)|0,C=C+Math.imul(K0,I0)|0,C=C+Math.imul(Q0,L0)|0,J=J+Math.imul(Q0,I0)|0,$=$+Math.imul(d,k0)|0,C=C+Math.imul(d,q0)|0,C=C+Math.imul(f,k0)|0,J=J+Math.imul(f,q0)|0,$=$+Math.imul(r,B0)|0,C=C+Math.imul(r,R0)|0,C=C+Math.imul(X0,B0)|0,J=J+Math.imul(X0,R0)|0,$=$+Math.imul(L,E0)|0,C=C+Math.imul(L,S0)|0,C=C+Math.imul(_,E0)|0,J=J+Math.imul(_,S0)|0;var f0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(f0>>>26)|0,f0&=67108863,$=Math.imul(T,Y0),C=Math.imul(T,F0),C=C+Math.imul(B,Y0)|0,J=Math.imul(B,F0),$=$+Math.imul(j0,W0)|0,C=C+Math.imul(j0,U0)|0,C=C+Math.imul(Z0,W0)|0,J=J+Math.imul(Z0,U0)|0,$=$+Math.imul($0,D0)|0,C=C+Math.imul($0,N0)|0,C=C+Math.imul(J0,D0)|0,J=J+Math.imul(J0,N0)|0,$=$+Math.imul(C0,T0)|0,C=C+Math.imul(C0,V0)|0,C=C+Math.imul(t,T0)|0,J=J+Math.imul(t,V0)|0,$=$+Math.imul(q,L0)|0,C=C+Math.imul(q,I0)|0,C=C+Math.imul(m,L0)|0,J=J+Math.imul(m,I0)|0,$=$+Math.imul(K0,k0)|0,C=C+Math.imul(K0,q0)|0,C=C+Math.imul(Q0,k0)|0,J=J+Math.imul(Q0,q0)|0,$=$+Math.imul(d,B0)|0,C=C+Math.imul(d,R0)|0,C=C+Math.imul(f,B0)|0,J=J+Math.imul(f,R0)|0,$=$+Math.imul(r,E0)|0,C=C+Math.imul(r,S0)|0,C=C+Math.imul(X0,E0)|0,J=J+Math.imul(X0,S0)|0,$=$+Math.imul(L,x0)|0,C=C+Math.imul(L,A0)|0,C=C+Math.imul(_,x0)|0,J=J+Math.imul(_,A0)|0;var n0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(n0>>>26)|0,n0&=67108863,$=Math.imul(h,Y0),C=Math.imul(h,F0),C=C+Math.imul(o,Y0)|0,J=Math.imul(o,F0),$=$+Math.imul(T,W0)|0,C=C+Math.imul(T,U0)|0,C=C+Math.imul(B,W0)|0,J=J+Math.imul(B,U0)|0,$=$+Math.imul(j0,D0)|0,C=C+Math.imul(j0,N0)|0,C=C+Math.imul(Z0,D0)|0,J=J+Math.imul(Z0,N0)|0,$=$+Math.imul($0,T0)|0,C=C+Math.imul($0,V0)|0,C=C+Math.imul(J0,T0)|0,J=J+Math.imul(J0,V0)|0,$=$+Math.imul(C0,L0)|0,C=C+Math.imul(C0,I0)|0,C=C+Math.imul(t,L0)|0,J=J+Math.imul(t,I0)|0,$=$+Math.imul(q,k0)|0,C=C+Math.imul(q,q0)|0,C=C+Math.imul(m,k0)|0,J=J+Math.imul(m,q0)|0,$=$+Math.imul(K0,B0)|0,C=C+Math.imul(K0,R0)|0,C=C+Math.imul(Q0,B0)|0,J=J+Math.imul(Q0,R0)|0,$=$+Math.imul(d,E0)|0,C=C+Math.imul(d,S0)|0,C=C+Math.imul(f,E0)|0,J=J+Math.imul(f,S0)|0,$=$+Math.imul(r,x0)|0,C=C+Math.imul(r,A0)|0,C=C+Math.imul(X0,x0)|0,J=J+Math.imul(X0,A0)|0,$=$+Math.imul(L,v0)|0,C=C+Math.imul(L,M0)|0,C=C+Math.imul(_,v0)|0,J=J+Math.imul(_,M0)|0;var r0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(r0>>>26)|0,r0&=67108863,$=Math.imul(h,W0),C=Math.imul(h,U0),C=C+Math.imul(o,W0)|0,J=Math.imul(o,U0),$=$+Math.imul(T,D0)|0,C=C+Math.imul(T,N0)|0,C=C+Math.imul(B,D0)|0,J=J+Math.imul(B,N0)|0,$=$+Math.imul(j0,T0)|0,C=C+Math.imul(j0,V0)|0,C=C+Math.imul(Z0,T0)|0,J=J+Math.imul(Z0,V0)|0,$=$+Math.imul($0,L0)|0,C=C+Math.imul($0,I0)|0,C=C+Math.imul(J0,L0)|0,J=J+Math.imul(J0,I0)|0,$=$+Math.imul(C0,k0)|0,C=C+Math.imul(C0,q0)|0,C=C+Math.imul(t,k0)|0,J=J+Math.imul(t,q0)|0,$=$+Math.imul(q,B0)|0,C=C+Math.imul(q,R0)|0,C=C+Math.imul(m,B0)|0,J=J+Math.imul(m,R0)|0,$=$+Math.imul(K0,E0)|0,C=C+Math.imul(K0,S0)|0,C=C+Math.imul(Q0,E0)|0,J=J+Math.imul(Q0,S0)|0,$=$+Math.imul(d,x0)|0,C=C+Math.imul(d,A0)|0,C=C+Math.imul(f,x0)|0,J=J+Math.imul(f,A0)|0,$=$+Math.imul(r,v0)|0,C=C+Math.imul(r,M0)|0,C=C+Math.imul(X0,v0)|0,J=J+Math.imul(X0,M0)|0;var i0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(i0>>>26)|0,i0&=67108863,$=Math.imul(h,D0),C=Math.imul(h,N0),C=C+Math.imul(o,D0)|0,J=Math.imul(o,N0),$=$+Math.imul(T,T0)|0,C=C+Math.imul(T,V0)|0,C=C+Math.imul(B,T0)|0,J=J+Math.imul(B,V0)|0,$=$+Math.imul(j0,L0)|0,C=C+Math.imul(j0,I0)|0,C=C+Math.imul(Z0,L0)|0,J=J+Math.imul(Z0,I0)|0,$=$+Math.imul($0,k0)|0,C=C+Math.imul($0,q0)|0,C=C+Math.imul(J0,k0)|0,J=J+Math.imul(J0,q0)|0,$=$+Math.imul(C0,B0)|0,C=C+Math.imul(C0,R0)|0,C=C+Math.imul(t,B0)|0,J=J+Math.imul(t,R0)|0,$=$+Math.imul(q,E0)|0,C=C+Math.imul(q,S0)|0,C=C+Math.imul(m,E0)|0,J=J+Math.imul(m,S0)|0,$=$+Math.imul(K0,x0)|0,C=C+Math.imul(K0,A0)|0,C=C+Math.imul(Q0,x0)|0,J=J+Math.imul(Q0,A0)|0,$=$+Math.imul(d,v0)|0,C=C+Math.imul(d,M0)|0,C=C+Math.imul(f,v0)|0,J=J+Math.imul(f,M0)|0;var t0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(t0>>>26)|0,t0&=67108863,$=Math.imul(h,T0),C=Math.imul(h,V0),C=C+Math.imul(o,T0)|0,J=Math.imul(o,V0),$=$+Math.imul(T,L0)|0,C=C+Math.imul(T,I0)|0,C=C+Math.imul(B,L0)|0,J=J+Math.imul(B,I0)|0,$=$+Math.imul(j0,k0)|0,C=C+Math.imul(j0,q0)|0,C=C+Math.imul(Z0,k0)|0,J=J+Math.imul(Z0,q0)|0,$=$+Math.imul($0,B0)|0,C=C+Math.imul($0,R0)|0,C=C+Math.imul(J0,B0)|0,J=J+Math.imul(J0,R0)|0,$=$+Math.imul(C0,E0)|0,C=C+Math.imul(C0,S0)|0,C=C+Math.imul(t,E0)|0,J=J+Math.imul(t,S0)|0,$=$+Math.imul(q,x0)|0,C=C+Math.imul(q,A0)|0,C=C+Math.imul(m,x0)|0,J=J+Math.imul(m,A0)|0,$=$+Math.imul(K0,v0)|0,C=C+Math.imul(K0,M0)|0,C=C+Math.imul(Q0,v0)|0,J=J+Math.imul(Q0,M0)|0;var e0=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(e0>>>26)|0,e0&=67108863,$=Math.imul(h,L0),C=Math.imul(h,I0),C=C+Math.imul(o,L0)|0,J=Math.imul(o,I0),$=$+Math.imul(T,k0)|0,C=C+Math.imul(T,q0)|0,C=C+Math.imul(B,k0)|0,J=J+Math.imul(B,q0)|0,$=$+Math.imul(j0,B0)|0,C=C+Math.imul(j0,R0)|0,C=C+Math.imul(Z0,B0)|0,J=J+Math.imul(Z0,R0)|0,$=$+Math.imul($0,E0)|0,C=C+Math.imul($0,S0)|0,C=C+Math.imul(J0,E0)|0,J=J+Math.imul(J0,S0)|0,$=$+Math.imul(C0,x0)|0,C=C+Math.imul(C0,A0)|0,C=C+Math.imul(t,x0)|0,J=J+Math.imul(t,A0)|0,$=$+Math.imul(q,v0)|0,C=C+Math.imul(q,M0)|0,C=C+Math.imul(m,v0)|0,J=J+Math.imul(m,M0)|0;var K5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(K5>>>26)|0,K5&=67108863,$=Math.imul(h,k0),C=Math.imul(h,q0),C=C+Math.imul(o,k0)|0,J=Math.imul(o,q0),$=$+Math.imul(T,B0)|0,C=C+Math.imul(T,R0)|0,C=C+Math.imul(B,B0)|0,J=J+Math.imul(B,R0)|0,$=$+Math.imul(j0,E0)|0,C=C+Math.imul(j0,S0)|0,C=C+Math.imul(Z0,E0)|0,J=J+Math.imul(Z0,S0)|0,$=$+Math.imul($0,x0)|0,C=C+Math.imul($0,A0)|0,C=C+Math.imul(J0,x0)|0,J=J+Math.imul(J0,A0)|0,$=$+Math.imul(C0,v0)|0,C=C+Math.imul(C0,M0)|0,C=C+Math.imul(t,v0)|0,J=J+Math.imul(t,M0)|0;var C5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(C5>>>26)|0,C5&=67108863,$=Math.imul(h,B0),C=Math.imul(h,R0),C=C+Math.imul(o,B0)|0,J=Math.imul(o,R0),$=$+Math.imul(T,E0)|0,C=C+Math.imul(T,S0)|0,C=C+Math.imul(B,E0)|0,J=J+Math.imul(B,S0)|0,$=$+Math.imul(j0,x0)|0,C=C+Math.imul(j0,A0)|0,C=C+Math.imul(Z0,x0)|0,J=J+Math.imul(Z0,A0)|0,$=$+Math.imul($0,v0)|0,C=C+Math.imul($0,M0)|0,C=C+Math.imul(J0,v0)|0,J=J+Math.imul(J0,M0)|0;var X5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(X5>>>26)|0,X5&=67108863,$=Math.imul(h,E0),C=Math.imul(h,S0),C=C+Math.imul(o,E0)|0,J=Math.imul(o,S0),$=$+Math.imul(T,x0)|0,C=C+Math.imul(T,A0)|0,C=C+Math.imul(B,x0)|0,J=J+Math.imul(B,A0)|0,$=$+Math.imul(j0,v0)|0,C=C+Math.imul(j0,M0)|0,C=C+Math.imul(Z0,v0)|0,J=J+Math.imul(Z0,M0)|0;var H5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(H5>>>26)|0,H5&=67108863,$=Math.imul(h,x0),C=Math.imul(h,A0),C=C+Math.imul(o,x0)|0,J=Math.imul(o,A0),$=$+Math.imul(T,v0)|0,C=C+Math.imul(T,M0)|0,C=C+Math.imul(B,v0)|0,J=J+Math.imul(B,M0)|0;var Y5=(Z+$|0)+((C&8191)<<13)|0;Z=(J+(C>>>13)|0)+(Y5>>>26)|0,Y5&=67108863,$=Math.imul(h,v0),C=Math.imul(h,M0),C=C+Math.imul(o,v0)|0,J=Math.imul(o,M0);var Q5=(Z+$|0)+((C&8191)<<13)|0;return Z=(J+(C>>>13)|0)+(Q5>>>26)|0,Q5&=67108863,P[0]=$5,P[1]=g0,P[2]=m0,P[3]=u0,P[4]=o0,P[5]=s0,P[6]=a0,P[7]=f0,P[8]=n0,P[9]=r0,P[10]=i0,P[11]=t0,P[12]=e0,P[13]=K5,P[14]=C5,P[15]=X5,P[16]=H5,P[17]=Y5,P[18]=Q5,Z!==0&&(P[19]=Z,Y.length++),Y};Math.imul||(k=D);function A(K,X,Y){Y.negative=X.negative^K.negative,Y.length=K.length+X.length;for(var H=0,Q=0,P=0;P<Y.length-1;P++){var Z=Q;Q=0;for(var $=H&67108863,C=Math.min(P,X.length-1),J=Math.max(0,P-K.length+1);J<=C;J++){var R=P-J,L=K.words[R]|0,_=X.words[J]|0,s=L*_,r=s&67108863;Z=Z+(s/67108864|0)|0,r=r+$|0,$=r&67108863,Z=Z+(r>>>26)|0,Q+=Z>>>26,Z&=67108863}Y.words[P]=$,H=Z,Z=Q}return H!==0?Y.words[P]=H:Y.length--,Y.strip()}function x(K,X,Y){var H=new v;return H.mulp(K,X,Y)}G.prototype.mulTo=function(K,X){var Y,H=this.length+K.length;return this.length===10&&K.length===10?Y=k(this,K,X):H<63?Y=D(this,K,X):H<1024?Y=A(this,K,X):Y=x(this,K,X),Y};function v(K,X){this.x=K,this.y=X}v.prototype.makeRBT=function(K){for(var X=new Array(K),Y=G.prototype._countBits(K)-1,H=0;H<K;H++)X[H]=this.revBin(H,Y,K);return X},v.prototype.revBin=function(K,X,Y){if(K===0||K===Y-1)return K;for(var H=0,Q=0;Q<X;Q++)H|=(K&1)<<X-Q-1,K>>=1;return H},v.prototype.permute=function(K,X,Y,H,Q,P){for(var Z=0;Z<P;Z++)H[Z]=X[K[Z]],Q[Z]=Y[K[Z]]},v.prototype.transform=function(K,X,Y,H,Q,P){this.permute(P,K,X,Y,H,Q);for(var Z=1;Z<Q;Z<<=1)for(var $=Z<<1,C=Math.cos(2*Math.PI/$),J=Math.sin(2*Math.PI/$),R=0;R<Q;R+=$)for(var L=C,_=J,s=0;s<Z;s++){var r=Y[R+s],X0=H[R+s],u=Y[R+s+Z],d=H[R+s+Z],f=L*u-_*d;d=L*d+_*u,u=f,Y[R+s]=r+u,H[R+s]=X0+d,Y[R+s+Z]=r-u,H[R+s+Z]=X0-d,s!==$&&(f=C*L-J*_,_=C*_+J*L,L=f)}},v.prototype.guessLen13b=function(K,X){var Y=Math.max(X,K)|1,H=Y&1,Q=0;for(Y=Y/2|0;Y;Y=Y>>>1)Q++;return 1<<Q+1+H},v.prototype.conjugate=function(K,X,Y){if(!(Y<=1))for(var H=0;H<Y/2;H++){var Q=K[H];K[H]=K[Y-H-1],K[Y-H-1]=Q,Q=X[H],X[H]=-X[Y-H-1],X[Y-H-1]=-Q}},v.prototype.normalize13b=function(K,X){for(var Y=0,H=0;H<X/2;H++){var Q=Math.round(K[2*H+1]/X)*8192+Math.round(K[2*H]/X)+Y;K[H]=Q&67108863,Q<67108864?Y=0:Y=Q/67108864|0}return K},v.prototype.convert13b=function(K,X,Y,H){for(var Q=0,P=0;P<X;P++)Q=Q+(K[P]|0),Y[2*P]=Q&8191,Q=Q>>>13,Y[2*P+1]=Q&8191,Q=Q>>>13;for(P=2*X;P<H;++P)Y[P]=0;U(Q===0),U((Q&-8192)===0)},v.prototype.stub=function(K){for(var X=new Array(K),Y=0;Y<K;Y++)X[Y]=0;return X},v.prototype.mulp=function(K,X,Y){var H=2*this.guessLen13b(K.length,X.length),Q=this.makeRBT(H),P=this.stub(H),Z=new Array(H),$=new Array(H),C=new Array(H),J=new Array(H),R=new Array(H),L=new Array(H),_=Y.words;_.length=H,this.convert13b(K.words,K.length,Z,H),this.convert13b(X.words,X.length,J,H),this.transform(Z,P,$,C,H,Q),this.transform(J,P,R,L,H,Q);for(var s=0;s<H;s++){var r=$[s]*R[s]-C[s]*L[s];C[s]=$[s]*L[s]+C[s]*R[s],$[s]=r}return this.conjugate($,C,H),this.transform($,C,_,P,H,Q),this.conjugate(_,P,H),this.normalize13b(_,H),Y.negative=K.negative^X.negative,Y.length=K.length+X.length,Y.strip()},G.prototype.mul=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),this.mulTo(K,X)},G.prototype.mulf=function(K){var X=new G(null);return X.words=new Array(this.length+K.length),x(this,K,X)},G.prototype.imul=function(K){return this.clone().mulTo(K,this)},G.prototype.imuln=function(K){U(typeof K=="number"),U(K<67108864);for(var X=0,Y=0;Y<this.length;Y++){var H=(this.words[Y]|0)*K,Q=(H&67108863)+(X&67108863);X>>=26,X+=H/67108864|0,X+=Q>>>26,this.words[Y]=Q&67108863}return X!==0&&(this.words[Y]=X,this.length++),this},G.prototype.muln=function(K){return this.clone().imuln(K)},G.prototype.sqr=function(){return this.mul(this)},G.prototype.isqr=function(){return this.imul(this.clone())},G.prototype.pow=function(K){var X=j(K);if(X.length===0)return new G(1);for(var Y=this,H=0;H<X.length&&X[H]===0;H++,Y=Y.sqr());if(++H<X.length)for(var Q=Y.sqr();H<X.length;H++,Q=Q.sqr())X[H]!==0&&(Y=Y.mul(Q));return Y},G.prototype.iushln=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=67108863>>>26-X<<26-X,Q;if(X!==0){var P=0;for(Q=0;Q<this.length;Q++){var Z=this.words[Q]&H,$=(this.words[Q]|0)-Z<<X;this.words[Q]=$|P,P=Z>>>26-X}P&&(this.words[Q]=P,this.length++)}if(Y!==0){for(Q=this.length-1;Q>=0;Q--)this.words[Q+Y]=this.words[Q];for(Q=0;Q<Y;Q++)this.words[Q]=0;this.length+=Y}return this.strip()},G.prototype.ishln=function(K){return U(this.negative===0),this.iushln(K)},G.prototype.iushrn=function(K,X,Y){U(typeof K=="number"&&K>=0);var H;X?H=(X-X%26)/26:H=0;var Q=K%26,P=Math.min((K-Q)/26,this.length),Z=67108863^67108863>>>Q<<Q,$=Y;if(H-=P,H=Math.max(0,H),$){for(var C=0;C<P;C++)$.words[C]=this.words[C];$.length=P}if(P!==0)if(this.length>P)for(this.length-=P,C=0;C<this.length;C++)this.words[C]=this.words[C+P];else this.words[0]=0,this.length=1;var J=0;for(C=this.length-1;C>=0&&(J!==0||C>=H);C--){var R=this.words[C]|0;this.words[C]=J<<26-Q|R>>>Q,J=R&Z}return $&&J!==0&&($.words[$.length++]=J),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},G.prototype.ishrn=function(K,X,Y){return U(this.negative===0),this.iushrn(K,X,Y)},G.prototype.shln=function(K){return this.clone().ishln(K)},G.prototype.ushln=function(K){return this.clone().iushln(K)},G.prototype.shrn=function(K){return this.clone().ishrn(K)},G.prototype.ushrn=function(K){return this.clone().iushrn(K)},G.prototype.testn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return!1;var Q=this.words[Y];return!!(Q&H)},G.prototype.imaskn=function(K){U(typeof K=="number"&&K>=0);var X=K%26,Y=(K-X)/26;if(U(this.negative===0,"imaskn works only with positive numbers"),this.length<=Y)return this;if(X!==0&&Y++,this.length=Math.min(Y,this.length),X!==0){var H=67108863^67108863>>>X<<X;this.words[this.length-1]&=H}return this.strip()},G.prototype.maskn=function(K){return this.clone().imaskn(K)},G.prototype.iaddn=function(K){return U(typeof K=="number"),U(K<67108864),K<0?this.isubn(-K):this.negative!==0?this.length===1&&(this.words[0]|0)<K?(this.words[0]=K-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(K),this.negative=1,this):this._iaddn(K)},G.prototype._iaddn=function(K){this.words[0]+=K;for(var X=0;X<this.length&&this.words[X]>=67108864;X++)this.words[X]-=67108864,X===this.length-1?this.words[X+1]=1:this.words[X+1]++;return this.length=Math.max(this.length,X+1),this},G.prototype.isubn=function(K){if(U(typeof K=="number"),U(K<67108864),K<0)return this.iaddn(-K);if(this.negative!==0)return this.negative=0,this.iaddn(K),this.negative=1,this;if(this.words[0]-=K,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var X=0;X<this.length&&this.words[X]<0;X++)this.words[X]+=67108864,this.words[X+1]-=1;return this.strip()},G.prototype.addn=function(K){return this.clone().iaddn(K)},G.prototype.subn=function(K){return this.clone().isubn(K)},G.prototype.iabs=function(){return this.negative=0,this},G.prototype.abs=function(){return this.clone().iabs()},G.prototype._ishlnsubmul=function(K,X,Y){var H=K.length+Y,Q;this._expand(H);var P,Z=0;for(Q=0;Q<K.length;Q++){P=(this.words[Q+Y]|0)+Z;var $=(K.words[Q]|0)*X;P-=$&67108863,Z=(P>>26)-($/67108864|0),this.words[Q+Y]=P&67108863}for(;Q<this.length-Y;Q++)P=(this.words[Q+Y]|0)+Z,Z=P>>26,this.words[Q+Y]=P&67108863;if(Z===0)return this.strip();for(U(Z===-1),Z=0,Q=0;Q<this.length;Q++)P=-(this.words[Q]|0)+Z,Z=P>>26,this.words[Q]=P&67108863;return this.negative=1,this.strip()},G.prototype._wordDiv=function(K,X){var Y=this.length-K.length,H=this.clone(),Q=K,P=Q.words[Q.length-1]|0,Z=this._countBits(P);Y=26-Z,Y!==0&&(Q=Q.ushln(Y),H.iushln(Y),P=Q.words[Q.length-1]|0);var $=H.length-Q.length,C;if(X!=="mod"){C=new G(null),C.length=$+1,C.words=new Array(C.length);for(var J=0;J<C.length;J++)C.words[J]=0}var R=H.clone()._ishlnsubmul(Q,1,$);R.negative===0&&(H=R,C&&(C.words[$]=1));for(var L=$-1;L>=0;L--){var _=(H.words[Q.length+L]|0)*67108864+(H.words[Q.length+L-1]|0);for(_=Math.min(_/P|0,67108863),H._ishlnsubmul(Q,_,L);H.negative!==0;)_--,H.negative=0,H._ishlnsubmul(Q,1,L),H.isZero()||(H.negative^=1);C&&(C.words[L]=_)}return C&&C.strip(),H.strip(),X!=="div"&&Y!==0&&H.iushrn(Y),{div:C||null,mod:H}},G.prototype.divmod=function(K,X,Y){if(U(!K.isZero()),this.isZero())return{div:new G(0),mod:new G(0)};var H,Q,P;return this.negative!==0&&K.negative===0?(P=this.neg().divmod(K,X),X!=="mod"&&(H=P.div.neg()),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.iadd(K)),{div:H,mod:Q}):this.negative===0&&K.negative!==0?(P=this.divmod(K.neg(),X),X!=="mod"&&(H=P.div.neg()),{div:H,mod:P.mod}):(this.negative&K.negative)!==0?(P=this.neg().divmod(K.neg(),X),X!=="div"&&(Q=P.mod.neg(),Y&&Q.negative!==0&&Q.isub(K)),{div:P.div,mod:Q}):K.length>this.length||this.cmp(K)<0?{div:new G(0),mod:this}:K.length===1?X==="div"?{div:this.divn(K.words[0]),mod:null}:X==="mod"?{div:null,mod:new G(this.modn(K.words[0]))}:{div:this.divn(K.words[0]),mod:new G(this.modn(K.words[0]))}:this._wordDiv(K,X)},G.prototype.div=function(K){return this.divmod(K,"div",!1).div},G.prototype.mod=function(K){return this.divmod(K,"mod",!1).mod},G.prototype.umod=function(K){return this.divmod(K,"mod",!0).mod},G.prototype.divRound=function(K){var X=this.divmod(K);if(X.mod.isZero())return X.div;var Y=X.div.negative!==0?X.mod.isub(K):X.mod,H=K.ushrn(1),Q=K.andln(1),P=Y.cmp(H);return P<0||Q===1&&P===0?X.div:X.div.negative!==0?X.div.isubn(1):X.div.iaddn(1)},G.prototype.modn=function(K){U(K<=67108863);for(var X=67108864%K,Y=0,H=this.length-1;H>=0;H--)Y=(X*Y+(this.words[H]|0))%K;return Y},G.prototype.idivn=function(K){U(K<=67108863);for(var X=0,Y=this.length-1;Y>=0;Y--){var H=(this.words[Y]|0)+X*67108864;this.words[Y]=H/K|0,X=H%K}return this.strip()},G.prototype.divn=function(K){return this.clone().idivn(K)},G.prototype.egcd=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=new G(0),Z=new G(1),$=0;X.isEven()&&Y.isEven();)X.iushrn(1),Y.iushrn(1),++$;for(var C=Y.clone(),J=X.clone();!X.isZero();){for(var R=0,L=1;(X.words[0]&L)===0&&R<26;++R,L<<=1);if(R>0)for(X.iushrn(R);R-- >0;)(H.isOdd()||Q.isOdd())&&(H.iadd(C),Q.isub(J)),H.iushrn(1),Q.iushrn(1);for(var _=0,s=1;(Y.words[0]&s)===0&&_<26;++_,s<<=1);if(_>0)for(Y.iushrn(_);_-- >0;)(P.isOdd()||Z.isOdd())&&(P.iadd(C),Z.isub(J)),P.iushrn(1),Z.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(P),Q.isub(Z)):(Y.isub(X),P.isub(H),Z.isub(Q))}return{a:P,b:Z,gcd:Y.iushln($)}},G.prototype._invmp=function(K){U(K.negative===0),U(!K.isZero());var X=this,Y=K.clone();X.negative!==0?X=X.umod(K):X=X.clone();for(var H=new G(1),Q=new G(0),P=Y.clone();X.cmpn(1)>0&&Y.cmpn(1)>0;){for(var Z=0,$=1;(X.words[0]&$)===0&&Z<26;++Z,$<<=1);if(Z>0)for(X.iushrn(Z);Z-- >0;)H.isOdd()&&H.iadd(P),H.iushrn(1);for(var C=0,J=1;(Y.words[0]&J)===0&&C<26;++C,J<<=1);if(C>0)for(Y.iushrn(C);C-- >0;)Q.isOdd()&&Q.iadd(P),Q.iushrn(1);X.cmp(Y)>=0?(X.isub(Y),H.isub(Q)):(Y.isub(X),Q.isub(H))}var R;return X.cmpn(1)===0?R=H:R=Q,R.cmpn(0)<0&&R.iadd(K),R},G.prototype.gcd=function(K){if(this.isZero())return K.abs();if(K.isZero())return this.abs();var X=this.clone(),Y=K.clone();X.negative=0,Y.negative=0;for(var H=0;X.isEven()&&Y.isEven();H++)X.iushrn(1),Y.iushrn(1);do{for(;X.isEven();)X.iushrn(1);for(;Y.isEven();)Y.iushrn(1);var Q=X.cmp(Y);if(Q<0){var P=X;X=Y,Y=P}else if(Q===0||Y.cmpn(1)===0)break;X.isub(Y)}while(!0);return Y.iushln(H)},G.prototype.invm=function(K){return this.egcd(K).a.umod(K)},G.prototype.isEven=function(){return(this.words[0]&1)===0},G.prototype.isOdd=function(){return(this.words[0]&1)===1},G.prototype.andln=function(K){return this.words[0]&K},G.prototype.bincn=function(K){U(typeof K=="number");var X=K%26,Y=(K-X)/26,H=1<<X;if(this.length<=Y)return this._expand(Y+1),this.words[Y]|=H,this;for(var Q=H,P=Y;Q!==0&&P<this.length;P++){var Z=this.words[P]|0;Z+=Q,Q=Z>>>26,Z&=67108863,this.words[P]=Z}return Q!==0&&(this.words[P]=Q,this.length++),this},G.prototype.isZero=function(){return this.length===1&&this.words[0]===0},G.prototype.cmpn=function(K){var X=K<0;if(this.negative!==0&&!X)return-1;if(this.negative===0&&X)return 1;this.strip();var Y;if(this.length>1)Y=1;else{X&&(K=-K),U(K<=67108863,"Number is too big");var H=this.words[0]|0;Y=H===K?0:H<K?-1:1}return this.negative!==0?-Y|0:Y},G.prototype.cmp=function(K){if(this.negative!==0&&K.negative===0)return-1;if(this.negative===0&&K.negative!==0)return 1;var X=this.ucmp(K);return this.negative!==0?-X|0:X},G.prototype.ucmp=function(K){if(this.length>K.length)return 1;if(this.length<K.length)return-1;for(var X=0,Y=this.length-1;Y>=0;Y--){var H=this.words[Y]|0,Q=K.words[Y]|0;if(H!==Q){H<Q?X=-1:H>Q&&(X=1);break}}return X},G.prototype.gtn=function(K){return this.cmpn(K)===1},G.prototype.gt=function(K){return this.cmp(K)===1},G.prototype.gten=function(K){return this.cmpn(K)>=0},G.prototype.gte=function(K){return this.cmp(K)>=0},G.prototype.ltn=function(K){return this.cmpn(K)===-1},G.prototype.lt=function(K){return this.cmp(K)===-1},G.prototype.lten=function(K){return this.cmpn(K)<=0},G.prototype.lte=function(K){return this.cmp(K)<=0},G.prototype.eqn=function(K){return this.cmpn(K)===0},G.prototype.eq=function(K){return this.cmp(K)===0},G.red=function(K){return new a(K)},G.prototype.toRed=function(K){return U(!this.red,"Already a number in reduction context"),U(this.negative===0,"red works only with positives"),K.convertTo(this)._forceRed(K)},G.prototype.fromRed=function(){return U(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},G.prototype._forceRed=function(K){return this.red=K,this},G.prototype.forceRed=function(K){return U(!this.red,"Already a number in reduction context"),this._forceRed(K)},G.prototype.redAdd=function(K){return U(this.red,"redAdd works only with red numbers"),this.red.add(this,K)},G.prototype.redIAdd=function(K){return U(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,K)},G.prototype.redSub=function(K){return U(this.red,"redSub works only with red numbers"),this.red.sub(this,K)},G.prototype.redISub=function(K){return U(this.red,"redISub works only with red numbers"),this.red.isub(this,K)},G.prototype.redShl=function(K){return U(this.red,"redShl works only with red numbers"),this.red.shl(this,K)},G.prototype.redMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.mul(this,K)},G.prototype.redIMul=function(K){return U(this.red,"redMul works only with red numbers"),this.red._verify2(this,K),this.red.imul(this,K)},G.prototype.redSqr=function(){return U(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},G.prototype.redISqr=function(){return U(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},G.prototype.redSqrt=function(){return U(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},G.prototype.redInvm=function(){return U(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},G.prototype.redNeg=function(){return U(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},G.prototype.redPow=function(K){return U(this.red&&!K.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,K)};var y={k256:null,p224:null,p192:null,p25519:null};function p(K,X){this.name=K,this.p=new G(X,16),this.n=this.p.bitLength(),this.k=new G(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}p.prototype._tmp=function(){var K=new G(null);return K.words=new Array(Math.ceil(this.n/13)),K},p.prototype.ireduce=function(K){var X=K,Y;do this.split(X,this.tmp),X=this.imulK(X),X=X.iadd(this.tmp),Y=X.bitLength();while(Y>this.n);var H=Y<this.n?-1:X.ucmp(this.p);return H===0?(X.words[0]=0,X.length=1):H>0?X.isub(this.p):X.strip!==void 0?X.strip():X._strip(),X},p.prototype.split=function(K,X){K.iushrn(this.n,0,X)},p.prototype.imulK=function(K){return K.imul(this.k)};function c(){p.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}S(c,p),c.prototype.split=function(K,X){for(var Y=4194303,H=Math.min(K.length,9),Q=0;Q<H;Q++)X.words[Q]=K.words[Q];if(X.length=H,K.length<=9){K.words[0]=0,K.length=1;return}var P=K.words[9];for(X.words[X.length++]=P&Y,Q=10;Q<K.length;Q++){var Z=K.words[Q]|0;K.words[Q-10]=(Z&Y)<<4|P>>>22,P=Z}P>>>=22,K.words[Q-10]=P,P===0&&K.length>10?K.length-=10:K.length-=9},c.prototype.imulK=function(K){K.words[K.length]=0,K.words[K.length+1]=0,K.length+=2;for(var X=0,Y=0;Y<K.length;Y++){var H=K.words[Y]|0;X+=H*977,K.words[Y]=X&67108863,X=H*64+(X/67108864|0)}return K.words[K.length-1]===0&&(K.length--,K.words[K.length-1]===0&&K.length--),K};function n(){p.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}S(n,p);function i(){p.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}S(i,p);function H0(){p.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}S(H0,p),H0.prototype.imulK=function(K){for(var X=0,Y=0;Y<K.length;Y++){var H=(K.words[Y]|0)*19+X,Q=H&67108863;H>>>=26,K.words[Y]=Q,X=H}return X!==0&&(K.words[K.length++]=X),K},G._prime=function(K){if(y[K])return y[K];var X;if(K==="k256")X=new c;else if(K==="p224")X=new n;else if(K==="p192")X=new i;else if(K==="p25519")X=new H0;else throw new Error("Unknown prime "+K);return y[K]=X,X};function a(K){if(typeof K=="string"){var X=G._prime(K);this.m=X.p,this.prime=X}else U(K.gtn(1),"modulus must be greater than 1"),this.m=K,this.prime=null}a.prototype._verify1=function(K){U(K.negative===0,"red works only with positives"),U(K.red,"red works only with red numbers")},a.prototype._verify2=function(K,X){U((K.negative|X.negative)===0,"red works only with positives"),U(K.red&&K.red===X.red,"red works only with red numbers")},a.prototype.imod=function(K){return this.prime?this.prime.ireduce(K)._forceRed(this):K.umod(this.m)._forceRed(this)},a.prototype.neg=function(K){return K.isZero()?K.clone():this.m.sub(K)._forceRed(this)},a.prototype.add=function(K,X){this._verify2(K,X);var Y=K.add(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y._forceRed(this)},a.prototype.iadd=function(K,X){this._verify2(K,X);var Y=K.iadd(X);return Y.cmp(this.m)>=0&&Y.isub(this.m),Y},a.prototype.sub=function(K,X){this._verify2(K,X);var Y=K.sub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y._forceRed(this)},a.prototype.isub=function(K,X){this._verify2(K,X);var Y=K.isub(X);return Y.cmpn(0)<0&&Y.iadd(this.m),Y},a.prototype.shl=function(K,X){return this._verify1(K),this.imod(K.ushln(X))},a.prototype.imul=function(K,X){return this._verify2(K,X),this.imod(K.imul(X))},a.prototype.mul=function(K,X){return this._verify2(K,X),this.imod(K.mul(X))},a.prototype.isqr=function(K){return this.imul(K,K.clone())},a.prototype.sqr=function(K){return this.mul(K,K)},a.prototype.sqrt=function(K){if(K.isZero())return K.clone();var X=this.m.andln(3);if(U(X%2===1),X===3){var Y=this.m.add(new G(1)).iushrn(2);return this.pow(K,Y)}for(var H=this.m.subn(1),Q=0;!H.isZero()&&H.andln(1)===0;)Q++,H.iushrn(1);U(!H.isZero());var P=new G(1).toRed(this),Z=P.redNeg(),$=this.m.subn(1).iushrn(1),C=this.m.bitLength();for(C=new G(2*C*C).toRed(this);this.pow(C,$).cmp(Z)!==0;)C.redIAdd(Z);for(var J=this.pow(C,H),R=this.pow(K,H.addn(1).iushrn(1)),L=this.pow(K,H),_=Q;L.cmp(P)!==0;){for(var s=L,r=0;s.cmp(P)!==0;r++)s=s.redSqr();U(r<_);var X0=this.pow(J,new G(1).iushln(_-r-1));R=R.redMul(X0),J=X0.redSqr(),L=L.redMul(J),_=r}return R},a.prototype.invm=function(K){var X=K._invmp(this.m);return X.negative!==0?(X.negative=0,this.imod(X).redNeg()):this.imod(X)},a.prototype.pow=function(K,X){if(X.isZero())return new G(1).toRed(this);if(X.cmpn(1)===0)return K.clone();var Y=4,H=new Array(1<<Y);H[0]=new G(1).toRed(this),H[1]=K;for(var Q=2;Q<H.length;Q++)H[Q]=this.mul(H[Q-1],K);var P=H[0],Z=0,$=0,C=X.bitLength()%26;for(C===0&&(C=26),Q=X.length-1;Q>=0;Q--){for(var J=X.words[Q],R=C-1;R>=0;R--){var L=J>>R&1;if(P!==H[0]&&(P=this.sqr(P)),L===0&&Z===0){$=0;continue}Z<<=1,Z|=L,$++,!($!==Y&&(Q!==0||R!==0))&&(P=this.mul(P,H[Z]),$=0,Z=0)}C=26}return P},a.prototype.convertTo=function(K){var X=K.umod(this.m);return X===K?X.clone():X},a.prototype.convertFrom=function(K){var X=K.clone();return X.red=null,X},G.mont=function(K){return new P0(K)};function P0(K){a.call(this,K),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new G(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}S(P0,a),P0.prototype.convertTo=function(K){return this.imod(K.ushln(this.shift))},P0.prototype.convertFrom=function(K){var X=this.imod(K.mul(this.rinv));return X.red=null,X},P0.prototype.imul=function(K,X){if(K.isZero()||X.isZero())return K.words[0]=0,K.length=1,K;var Y=K.imul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.mul=function(K,X){if(K.isZero()||X.isZero())return new G(0)._forceRed(this);var Y=K.mul(X),H=Y.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Q=Y.isub(H).iushrn(this.shift),P=Q;return Q.cmp(this.m)>=0?P=Q.isub(this.m):Q.cmpn(0)<0&&(P=Q.iadd(this.m)),P._forceRed(this)},P0.prototype.invm=function(K){var X=this.imod(K._invmp(this.m).mul(this.r2));return X._forceRed(this)}})(typeof g>"u"||g,l)}),c6=G0((l,g)=>{var E=y9(),M=d0().Buffer;function U(S,G){return M.from(S.toRed(E.mont(G.modulus)).redPow(new E(G.publicExponent)).fromRed().toArray())}g.exports=U}),S8=G0((l,g)=>{var E=H9(),M=g5(),U=h5(),S=p6(),G=b6(),W=y9(),I=c6(),V=E9(),z=d0().Buffer;g.exports=function(j,D,k){var A;j.padding?A=j.padding:k?A=1:A=4;var x=E(j),v;if(A===4)v=F(x,D);else if(A===1)v=O(x,D,k);else if(A===3){if(v=new W(D),v.cmp(x.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");return k?V(v,x):I(v,x)};function F(j,D){var k=j.modulus.byteLength(),A=D.length,x=U("sha1").update(z.alloc(0)).digest(),v=x.length,y=2*v;if(A>k-y-2)throw new Error("message too long");var p=z.alloc(k-A-y-2),c=k-v-1,n=M(v),i=G(z.concat([x,p,z.alloc(1,1),D],c),S(n,c)),H0=G(n,S(i,v));return new W(z.concat([z.alloc(1),H0,i],k))}function O(j,D,k){var A=D.length,x=j.modulus.byteLength();if(A>x-11)throw new Error("message too long");var v;return k?v=z.alloc(x-A-3,255):v=N(x-A-3),new W(z.concat([z.from([0,k?1:2]),v,z.alloc(1),D],x))}function N(j){for(var D=z.allocUnsafe(j),k=0,A=M(j*2),x=0,v;k<j;)x===A.length&&(A=M(j*2),x=0),v=A[x++],v&&(D[k++]=v);return D}}),x8=G0((l,g)=>{var E=H9(),M=p6(),U=b6(),S=y9(),G=E9(),W=h5(),I=c6(),V=d0().Buffer;g.exports=function(N,j,D){var k;N.padding?k=N.padding:D?k=1:k=4;var A=E(N),x=A.modulus.byteLength();if(j.length>x||new S(j).cmp(A.modulus)>=0)throw new Error("decryption error");var v;D?v=I(new S(j),A):v=G(j,A);var y=V.alloc(x-v.length);if(v=V.concat([y,v],x),k===4)return z(A,v);if(k===1)return F(A,v,D);if(k===3)return v;throw new Error("unknown padding")};function z(N,j){var D=N.modulus.byteLength(),k=W("sha1").update(V.alloc(0)).digest(),A=k.length;if(j[0]!==0)throw new Error("decryption error");var x=j.slice(1,A+1),v=j.slice(A+1),y=U(x,M(v,A)),p=U(v,M(y,D-A-1));if(O(k,p.slice(0,A)))throw new Error("decryption error");for(var c=A;p[c]===0;)c++;if(p[c++]!==1)throw new Error("decryption error");return p.slice(c)}function F(N,j,D){for(var k=j.slice(0,2),A=2,x=0;j[A++]!==0;)if(A>=j.length){x++;break}var v=j.slice(2,A-1);if((k.toString("hex")!=="0002"&&!D||k.toString("hex")!=="0001"&&D)&&x++,v.length<8&&x++,x)throw new Error("decryption error");return j.slice(A)}function O(N,j){N=V.from(N),j=V.from(j);var D=0,k=N.length;N.length!==j.length&&(D++,k=Math.min(N.length,j.length));for(var A=-1;++A<k;)D+=N[A]^j[A];return D}}),A8=G0((l)=>{l.publicEncrypt=S8(),l.privateDecrypt=x8(),l.privateEncrypt=function(g,E){return l.publicEncrypt(g,E,!0)},l.publicDecrypt=function(g,E){return l.privateDecrypt(g,E,!0)}}),v8=G0((l)=>{function g(){throw new Error(`secure random number generation not supported by this browser
5
- use chrome, FireFox or Internet Explorer 11`)}var E=d0(),M=g5(),U=E.Buffer,S=E.kMaxLength,G=global.crypto||global.msCrypto,W=Math.pow(2,32)-1;function I(N,j){if(typeof N!="number"||N!==N)throw new TypeError("offset must be a number");if(N>W||N<0)throw new TypeError("offset must be a uint32");if(N>S||N>j)throw new RangeError("offset out of range")}function V(N,j,D){if(typeof N!="number"||N!==N)throw new TypeError("size must be a number");if(N>W||N<0)throw new TypeError("size must be a uint32");if(N+j>D||N>S)throw new RangeError("buffer too small")}G&&G.getRandomValues?(l.randomFill=z,l.randomFillSync=O):(l.randomFill=g,l.randomFillSync=g);function z(N,j,D,k){if(!U.isBuffer(N)&&!(N instanceof global.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof j=="function")k=j,j=0,D=N.length;else if(typeof D=="function")k=D,D=N.length-j;else if(typeof k!="function")throw new TypeError('"cb" argument must be a function');return I(j,N.length),V(D,j,N.length),F(N,j,D,k)}function F(N,j,D,k){var A=N.buffer,x=new Uint8Array(A,j,D);if(G.getRandomValues(x),k){process.nextTick(function(){k(null,N)});return}return N;var v}function O(N,j,D){if(typeof j>"u"&&(j=0),!U.isBuffer(N)&&!(N instanceof global.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');return I(j,N.length),D===void 0&&(D=N.length-j),V(D,j,N.length),F(N,j,D)}}),d6=G0((l)=>{l.randomBytes=l.rng=l.pseudoRandomBytes=l.prng=g5(),l.createHash=l.Hash=h5(),l.createHmac=l.Hmac=Y6();var g=I7(),E=Object.keys(g),M=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(E);l.getHashes=function(){return M};var U=Z6();l.pbkdf2=U.pbkdf2,l.pbkdf2Sync=U.pbkdf2Sync;var S=p7();l.Cipher=S.Cipher,l.createCipher=S.createCipher,l.Cipheriv=S.Cipheriv,l.createCipheriv=S.createCipheriv,l.Decipher=S.Decipher,l.createDecipher=S.createDecipher,l.Decipheriv=S.Decipheriv,l.createDecipheriv=S.createDecipheriv,l.getCiphers=S.getCiphers,l.listCiphers=S.listCiphers;var G=h7();l.DiffieHellmanGroup=G.DiffieHellmanGroup,l.createDiffieHellmanGroup=G.createDiffieHellmanGroup,l.getDiffieHellman=G.getDiffieHellman,l.createDiffieHellman=G.createDiffieHellman,l.DiffieHellman=G.DiffieHellman;var W=B8();l.createSign=W.createSign,l.Sign=W.Sign,l.createVerify=W.createVerify,l.Verify=W.Verify,l.createECDH=E8();var I=A8();l.publicEncrypt=I.publicEncrypt,l.privateEncrypt=I.privateEncrypt,l.publicDecrypt=I.publicDecrypt,l.privateDecrypt=I.privateDecrypt;var V=v8();l.randomFill=V.randomFill,l.randomFillSync=V.randomFillSync,l.createCredentials=function(){throw new Error(["sorry, createCredentials is not implemented yet","we accept pull requests","https://github.com/crypto-browserify/crypto-browserify"].join(`
6
- `))},l.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}}),l6={};r5(l6,{DEFAULT_ENCODING:()=>_8,default:()=>_5,getCurves:()=>o6,getRandomValues:()=>h6,randomUUID:()=>u6,timingSafeEqual:()=>f5,webcrypto:()=>s6});P9(l6,E5(d6()));var M8=E5(d6()),_8="buffer",h6=(l)=>crypto.getRandomValues(l),u6=()=>crypto.randomUUID(),w8=["p192","p224","p256","p384","p521","curve25519","ed25519","secp256k1","secp224r1","prime256v1","prime192v1","ed25519","secp384r1","secp521r1"];function o6(){return w8}var f5="timingSafeEqual"in crypto?(l,g)=>{let{byteLength:E}=l,{byteLength:M}=g;if(typeof E!="number"||typeof M!="number")throw new TypeError("Input must be an array buffer view");if(E!==M)throw new RangeError("Input buffers must have the same length");return crypto.timingSafeEqual(l,g)}:void 0;f5&&Object.defineProperty(f5,"name",{value:"::bunternal::"});var s6=crypto,_5={...M8,getRandomValues:h6,randomUUID:u6,timingSafeEqual:f5,webcrypto:s6,getCurves:o6};/*!
7
- * The buffer module from node.js, for the browser.
8
- *
9
- * @author Feross Aboukhadijeh <https://feross.org>
10
- * @license MIT
11
- *//*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> *//*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */import{generateMnemonic as y8,validateMnemonic as g8}from"@scure/bip39";import{wordlist as a6}from"@scure/bip39/wordlists/english";import g9 from"blakejs";var f6=(l)=>{let g=l;if(!(g instanceof Buffer))g=Buffer.from(g,"hex");let E=g9.blake2bInit(32);return g9.blake2bUpdate(E,g),Array.from(g9.blake2bFinal(E)).map((M)=>M<16?`0${M.toString(16)}`:M.toString(16)).join("")},n6=(l,g,E,M,U)=>new Promise((S,G)=>{_5.pbkdf2(l,g,E,M,U,(W,I)=>{if(W)G(W);else S(I)})}),G4=async(l,g)=>{let E=_5.randomBytes(32),M=_5.randomBytes(16),U={c:262144,prf:"hmac-sha256",dklen:32,salt:E.toString("hex")},S="aes-128-ctr",G=await n6(Buffer.from(g),E,U.c,U.dklen,"sha256"),W=_5.createCipheriv("aes-128-ctr",G.subarray(0,16),M),I=Buffer.concat([W.update(Buffer.from(l,"utf8")),W.final()]);return{meta:"xchain-keystore",version:1,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:M.toString("hex")},ciphertext:I.toString("hex"),kdf:"pbkdf2",kdfparams:U,mac:f6(Buffer.concat([G.subarray(16,32),Buffer.from(I)]))}}},J4=(l=12)=>{return y8(a6,l===12?128:256)},P4=(l)=>{return g8(l,a6)},Z4=async(l,g)=>{switch(l.version){case 1:{let E=l.crypto.kdfparams,M=await n6(Buffer.from(g),Buffer.from(E.salt,"hex"),E.c,E.dklen,"sha256"),U=Buffer.from(l.crypto.ciphertext,"hex");if(f6(Buffer.concat([M.subarray(16,32),U]))!==l.crypto.mac)throw new Error("Invalid password");let G=_5.createDecipheriv(l.crypto.cipher,M.subarray(0,16),Buffer.from(l.crypto.cipherparams.iv,"hex"));return Buffer.concat([G.update(U),G.final()]).toString("utf8")}default:throw new Error("Unsupported keystore version")}};import{Chain as h0,CosmosChains as m8,EVMChains as p8,NetworkDerivationPath as b8,UTXOChains as c8,WalletOption as r6,derivationPathToString as d8,filterSupportedChains as l8,getRPCUrl as i6,pickEvmApiKey as h8,setRequestClientConfig as u8,updatedLastIndex as o8}from"@swapkit/helpers";var s8=[...p8,...c8,...m8,h0.Polkadot,h0.Chainflip,h0.Solana,h0.Ripple],a8=async({apis:l,rpcUrl:g,chain:E,phrase:M,ethplorerApiKey:U,covalentApiKey:S,blockchairApiKey:G,swapkitApiKey:W,derivationPath:I,stagenet:V})=>{switch(E){case h0.Arbitrum:case h0.Avalanche:case h0.Base:case h0.BinanceSmartChain:case h0.Ethereum:case h0.Optimism:case h0.Polygon:{let{getProvider:z,getToolboxByChain:F}=await import("@swapkit/toolbox-evm"),{HDNodeWallet:O}=await import("./chunk-7r0bsnk5.js"),N=l?.[E],j=h8({chain:E,nonEthApiKey:S,ethApiKey:U}),D=z(E,g),k=O.fromPhrase(M).connect(D),A={api:N,apiKey:j,provider:D,signer:k};return{address:k.address,walletMethods:F(E)(A)}}case h0.BitcoinCash:{let D=function({builder:A,utxos:x}){return x.forEach((v,y)=>{A.sign(y,N,void 0,65,v.witnessUtxo.value)}),A.build()},{BCHToolbox:z}=await import("@swapkit/toolbox-utxo"),F=l?.[E],O=z({rpcUrl:g,apiKey:G,apiClient:F}),N=await O.createKeysForPath({phrase:M,derivationPath:I}),j=O.getAddressFromKeys(N),k={...O,transfer:(A)=>O.transfer({...A,from:j,signTransaction:D})};return{address:j,walletMethods:k}}case h0.Bitcoin:case h0.Dash:case h0.Dogecoin:case h0.Litecoin:{let{getToolboxByChain:z}=await import("@swapkit/toolbox-utxo"),F=l?.[E],O=z(E)({rpcUrl:g,apiKey:G,apiClient:F}),N=O.createKeysForPath({phrase:M,derivationPath:I}),j=O.getAddressFromKeys(N);return{address:j,walletMethods:{...O,transfer:(D)=>O.transfer({...D,from:j,signTransaction:(k)=>k.signAllInputs(N)})}}}case h0.Cosmos:case h0.Kujira:{let{getToolboxByChain:z}=await import("@swapkit/toolbox-cosmos"),F=l?.[E],O=z(E)({server:F,stagenet:V,swapkitApiKey:W}),N=await O.getAddressFromMnemonic(M),j=await O.getSigner(M);return{address:N,walletMethods:{...O,transfer:(k)=>O.transfer({...k,signer:j})}}}case h0.Maya:case h0.THORChain:{let{getToolboxByChain:z}=await import("@swapkit/toolbox-cosmos"),F=l?.[E],O=z(E)({server:F,stagenet:V}),N=await O.getSigner(M),j=await O.getAddressFromMnemonic(M);return{address:j,walletMethods:{...O,deposit:({assetValue:D,memo:k})=>O.deposit({assetValue:D,memo:k,from:j,signer:N}),transfer:(D)=>O.transfer({...D,from:j,signer:N}),signMessage:async(D)=>{let k=await O.createPrivateKeyFromPhrase(M);return O.signWithPrivateKey({privateKey:k,message:D})}}}}case h0.Polkadot:case h0.Chainflip:{let{Network:z,getToolboxByChain:F,createKeyring:O}=await import("@swapkit/toolbox-substrate"),N=await O(M,z[E].prefix),j=await F(E,{signer:N,providerUrl:E===h0.Polkadot?i6(h0.Polkadot):i6(h0.Chainflip)});return{address:N.address,walletMethods:j}}case h0.Solana:{let{SOLToolbox:z,createKeysForPath:F}=await import("@swapkit/toolbox-solana"),O=F({phrase:M,derivationPath:I}),N=z({rpcUrl:g,signer:O});return{address:N.getAddressFromKeys(O),walletMethods:{...N}}}case h0.Ripple:{let{XRPToolbox:z,createSigner:F}=await import("@swapkit/toolbox-ripple"),O=F(M),N=z({rpcUrl:g,signer:O});return{address:O.address,walletMethods:{...N}}}default:throw new Error(`Unsupported chain ${E}`)}};function f8({addChain:l,apis:g,rpcUrls:E,config:{thorswapApiKey:M,covalentApiKey:U,ethplorerApiKey:S,blockchairApiKey:G,stagenet:W,swapkitApiKey:I}}){return async function V(z,F,O){u8({apiKey:M});let j=l8(z,s8,r6.KEYSTORE).map(async(D)=>{let k=typeof O==="number"?O:0,A=O&&typeof O==="object"?O[D]:void 0,[x,v,y,p,c]=b8[D],n=A||o8(D===h0.Solana?[x,v,y,p]:[x,v,y,p,c],k),i=d8(n),{address:H0,walletMethods:a}=await a8({derivationPath:i,chain:D,apis:g,rpcUrl:E[D],covalentApiKey:U,ethplorerApiKey:S,phrase:F,blockchairApiKey:G,swapkitApiKey:I,stagenet:W});l({...a,chain:D,address:H0,balance:[],walletType:r6.KEYSTORE})});return await Promise.all(j),!0}}var n8={connectKeystore:f8};export{P4 as validatePhrase,n8 as keystoreWallet,J4 as generatePhrase,G4 as encryptToKeyStore,Z4 as decryptFromKeystore};
1
+ import{a as dU,b as y0,c as IX,d as ZX,e as wU}from"./chunk-newnqy8q.js";var xU={};IX(xU,{versions:()=>tZ,version:()=>mZ,umask:()=>GQ,title:()=>bZ,removeListener:()=>UQ,removeAllListeners:()=>XQ,prependOnceListener:()=>QQ,prependListener:()=>ZQ,once:()=>eZ,on:()=>rZ,off:()=>iZ,nextTick:()=>dZ,listeners:()=>$Q,env:()=>nZ,emit:()=>IQ,cwd:()=>VQ,chdir:()=>OQ,browser:()=>oZ,binding:()=>YQ,argv:()=>sZ,addListener:()=>aZ});function lZ(){if(!XX||!mU)return;if(XX=!1,mU.length)fU=mU.concat(fU);else DX=-1;if(fU.length)LI()}function LI(){if(XX)return;var E=setTimeout(lZ,0);XX=!0;var G=fU.length;while(G){mU=fU,fU=[];while(++DX<G)if(mU){var W=mU[DX];W.fun.apply(null,W.array)}DX=-1,G=fU.length}mU=null,XX=!1,clearTimeout(E,0)}function dZ(E){var G=new Array(arguments.length-1);if(arguments.length>1)for(var W=1;W<arguments.length;W++)G[W-1]=arguments[W];if(fU.push({fun:E,args:G}),fU.length===1&&!XX)setTimeout(LI,0)}function cU(){}var fU,XX=!1,mU,DX=-1,bZ="browser",oZ=!0,nZ,sZ,mZ="",tZ,rZ,aZ,eZ,iZ,UQ,XQ,IQ,ZQ,QQ,$Q=function(E){return[]},YQ=function(E){throw new Error("process.binding is not supported in browser polyfill")},VQ=function(){return"/"},OQ=function(E){throw new Error("process.chdir is not supported in browser polyfill")},GQ=function(){return 0};var gU=ZX(()=>{fU=[];nZ={},sZ=[],tZ={};rZ=cU,aZ=cU,eZ=cU,iZ=cU,UQ=cU,XQ=cU,IQ=cU,ZQ=cU,QQ=cU});var FU={};IX(FU,{transcode:()=>tQ,resolveObjectURL:()=>nQ,kStringMaxLength:()=>kI,kMaxLength:()=>GX,isUtf8:()=>sQ,isAscii:()=>mQ,default:()=>rQ,constants:()=>LQ,btoa:()=>EQ,atob:()=>CQ,INSPECT_MAX_BYTES:()=>AQ,File:()=>TQ,Buffer:()=>K0,Blob:()=>DQ});function KQ(E){var G=E.length;if(G%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var W=E.indexOf("=");if(W===-1)W=G;var C=W===G?0:4-W%4;return[W,C]}function WQ(E,G){return(E+G)*3/4-G}function JQ(E){var G,W=KQ(E),C=W[0],H=W[1],z=new Uint8Array(WQ(C,H)),V=0,P=H>0?C-4:C,k;for(k=0;k<P;k+=4)G=jU[E.charCodeAt(k)]<<18|jU[E.charCodeAt(k+1)]<<12|jU[E.charCodeAt(k+2)]<<6|jU[E.charCodeAt(k+3)],z[V++]=G>>16&255,z[V++]=G>>8&255,z[V++]=G&255;if(H===2)G=jU[E.charCodeAt(k)]<<2|jU[E.charCodeAt(k+1)]>>4,z[V++]=G&255;if(H===1)G=jU[E.charCodeAt(k)]<<10|jU[E.charCodeAt(k+1)]<<4|jU[E.charCodeAt(k+2)]>>2,z[V++]=G>>8&255,z[V++]=G&255;return z}function FQ(E){return NU[E>>18&63]+NU[E>>12&63]+NU[E>>6&63]+NU[E&63]}function HQ(E,G,W){var C,H=[];for(var z=G;z<W;z+=3)C=(E[z]<<16&16711680)+(E[z+1]<<8&65280)+(E[z+2]&255),H.push(FQ(C));return H.join("")}function MI(E){var G,W=E.length,C=W%3,H=[],z=16383;for(var V=0,P=W-C;V<P;V+=z)H.push(HQ(E,V,V+z>P?P:V+z));if(C===1)G=E[W-1],H.push(NU[G>>2]+NU[G<<4&63]+"==");else if(C===2)G=(E[W-2]<<8)+E[W-1],H.push(NU[G>>10]+NU[G>>4&63]+NU[G<<2&63]+"=");return H.join("")}function LX(E,G,W,C,H){var z,V,P=H*8-C-1,k=(1<<P)-1,R=k>>1,S=-7,D=W?H-1:0,A=W?-1:1,L=E[G+D];D+=A,z=L&(1<<-S)-1,L>>=-S,S+=P;for(;S>0;z=z*256+E[G+D],D+=A,S-=8);V=z&(1<<-S)-1,z>>=-S,S+=C;for(;S>0;V=V*256+E[G+D],D+=A,S-=8);if(z===0)z=1-R;else if(z===k)return V?NaN:(L?-1:1)*(1/0);else V=V+Math.pow(2,C),z=z-R;return(L?-1:1)*V*Math.pow(2,z-C)}function vI(E,G,W,C,H,z){var V,P,k,R=z*8-H-1,S=(1<<R)-1,D=S>>1,A=H===23?Math.pow(2,-24)-Math.pow(2,-77):0,L=C?0:z-1,M=C?1:-1,q=G<0||G===0&&1/G<0?1:0;if(G=Math.abs(G),isNaN(G)||G===1/0)P=isNaN(G)?1:0,V=S;else{if(V=Math.floor(Math.log(G)/Math.LN2),G*(k=Math.pow(2,-V))<1)V--,k*=2;if(V+D>=1)G+=A/k;else G+=A*Math.pow(2,1-D);if(G*k>=2)V++,k/=2;if(V+D>=S)P=0,V=S;else if(V+D>=1)P=(G*k-1)*Math.pow(2,H),V=V+D;else P=G*Math.pow(2,D-1)*Math.pow(2,H),V=0}for(;H>=8;E[W+L]=P&255,L+=M,P/=256,H-=8);V=V<<H|P,R+=H;for(;R>0;E[W+L]=V&255,L+=M,V/=256,R-=8);E[W+L-M]|=q*128}function pU(E){if(E>GX)throw new RangeError('The value "'+E+'" is invalid for option "size"');let G=new Uint8Array(E);return Object.setPrototypeOf(G,K0.prototype),G}function bX(E,G,W){return class C extends W{constructor(){super();Object.defineProperty(this,"message",{value:G.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${E}]`,this.stack,delete this.name}get code(){return E}set code(H){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:H,writable:!0})}toString(){return`${this.name} [${E}]: ${this.message}`}}}function K0(E,G,W){if(typeof E==="number"){if(typeof G==="string")throw new TypeError('The "string" argument must be of type string. Received type number');return oX(E)}return jI(E,G,W)}function jI(E,G,W){if(typeof E==="string")return SQ(E,G);if(ArrayBuffer.isView(E))return PQ(E);if(E==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof E);if(_U(E,ArrayBuffer)||E&&_U(E.buffer,ArrayBuffer))return lX(E,G,W);if(typeof SharedArrayBuffer!=="undefined"&&(_U(E,SharedArrayBuffer)||E&&_U(E.buffer,SharedArrayBuffer)))return lX(E,G,W);if(typeof E==="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let C=E.valueOf&&E.valueOf();if(C!=null&&C!==E)return K0.from(C,G,W);let H=qQ(E);if(H)return H;if(typeof Symbol!=="undefined"&&Symbol.toPrimitive!=null&&typeof E[Symbol.toPrimitive]==="function")return K0.from(E[Symbol.toPrimitive]("string"),G,W);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof E)}function BI(E){if(typeof E!=="number")throw new TypeError('"size" argument must be of type number');else if(E<0)throw new RangeError('The value "'+E+'" is invalid for option "size"')}function RQ(E,G,W){if(BI(E),E<=0)return pU(E);if(G!==void 0)return typeof W==="string"?pU(E).fill(G,W):pU(E).fill(G);return pU(E)}function oX(E){return BI(E),pU(E<0?0:nX(E)|0)}function SQ(E,G){if(typeof G!=="string"||G==="")G="utf8";if(!K0.isEncoding(G))throw new TypeError("Unknown encoding: "+G);let W=xI(E,G)|0,C=pU(W),H=C.write(E,G);if(H!==W)C=C.slice(0,H);return C}function uX(E){let G=E.length<0?0:nX(E.length)|0,W=pU(G);for(let C=0;C<G;C+=1)W[C]=E[C]&255;return W}function PQ(E){if(_U(E,Uint8Array)){let G=new Uint8Array(E);return lX(G.buffer,G.byteOffset,G.byteLength)}return uX(E)}function lX(E,G,W){if(G<0||E.byteLength<G)throw new RangeError('"offset" is outside of buffer bounds');if(E.byteLength<G+(W||0))throw new RangeError('"length" is outside of buffer bounds');let C;if(G===void 0&&W===void 0)C=new Uint8Array(E);else if(W===void 0)C=new Uint8Array(E,G);else C=new Uint8Array(E,G,W);return Object.setPrototypeOf(C,K0.prototype),C}function qQ(E){if(K0.isBuffer(E)){let G=nX(E.length)|0,W=pU(G);if(W.length===0)return W;return E.copy(W,0,0,G),W}if(E.length!==void 0){if(typeof E.length!=="number"||numberIsNaN(E.length))return pU(0);return uX(E)}if(E.type==="Buffer"&&Array.isArray(E.data))return uX(E.data)}function nX(E){if(E>=GX)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+GX.toString(16)+" bytes");return E|0}function xI(E,G){if(K0.isBuffer(E))return E.length;if(ArrayBuffer.isView(E)||_U(E,ArrayBuffer))return E.byteLength;if(typeof E!=="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof E);let W=E.length,C=arguments.length>2&&arguments[2]===!0;if(!C&&W===0)return 0;let H=!1;for(;;)switch(G){case"ascii":case"latin1":case"binary":return W;case"utf8":case"utf-8":return dX(E).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return W*2;case"hex":return W>>>1;case"base64":return hI(E).length;default:if(H)return C?-1:dX(E).length;G=(""+G).toLowerCase(),H=!0}}function vQ(E,G,W){let C=!1;if(G===void 0||G<0)G=0;if(G>this.length)return"";if(W===void 0||W>this.length)W=this.length;if(W<=0)return"";if(W>>>=0,G>>>=0,W<=G)return"";if(!E)E="utf8";while(!0)switch(E){case"hex":return fQ(this,G,W);case"utf8":case"utf-8":return NI(this,G,W);case"ascii":return wQ(this,G,W);case"latin1":case"binary":return yQ(this,G,W);case"base64":return NQ(this,G,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return cQ(this,G,W);default:if(C)throw new TypeError("Unknown encoding: "+E);E=(E+"").toLowerCase(),C=!0}}function rU(E,G,W){let C=E[G];E[G]=E[W],E[W]=C}function gI(E,G,W,C,H){if(E.length===0)return-1;if(typeof W==="string")C=W,W=0;else if(W>2147483647)W=2147483647;else if(W<-2147483648)W=-2147483648;if(W=+W,Number.isNaN(W))W=H?0:E.length-1;if(W<0)W=E.length+W;if(W>=E.length)if(H)return-1;else W=E.length-1;else if(W<0)if(H)W=0;else return-1;if(typeof G==="string")G=K0.from(G,C);if(K0.isBuffer(G)){if(G.length===0)return-1;return SI(E,G,W,C,H)}else if(typeof G==="number"){if(G=G&255,typeof Uint8Array.prototype.indexOf==="function")if(H)return Uint8Array.prototype.indexOf.call(E,G,W);else return Uint8Array.prototype.lastIndexOf.call(E,G,W);return SI(E,[G],W,C,H)}throw new TypeError("val must be string, number or Buffer")}function SI(E,G,W,C,H){let z=1,V=E.length,P=G.length;if(C!==void 0){if(C=String(C).toLowerCase(),C==="ucs2"||C==="ucs-2"||C==="utf16le"||C==="utf-16le"){if(E.length<2||G.length<2)return-1;z=2,V/=2,P/=2,W/=2}}function k(S,D){if(z===1)return S[D];else return S.readUInt16BE(D*z)}let R;if(H){let S=-1;for(R=W;R<V;R++)if(k(E,R)===k(G,S===-1?0:R-S)){if(S===-1)S=R;if(R-S+1===P)return S*z}else{if(S!==-1)R-=R-S;S=-1}}else{if(W+P>V)W=V-P;for(R=W;R>=0;R--){let S=!0;for(let D=0;D<P;D++)if(k(E,R+D)!==k(G,D)){S=!1;break}if(S)return R}}return-1}function kQ(E,G,W,C){W=Number(W)||0;let H=E.length-W;if(!C)C=H;else if(C=Number(C),C>H)C=H;let z=G.length;if(C>z/2)C=z/2;let V;for(V=0;V<C;++V){let P=parseInt(G.substr(V*2,2),16);if(numberIsNaN(P))return V;E[W+V]=P}return V}function jQ(E,G,W,C){return zX(dX(G,E.length-W),E,W,C)}function BQ(E,G,W,C){return zX(lQ(G),E,W,C)}function xQ(E,G,W,C){return zX(hI(G),E,W,C)}function gQ(E,G,W,C){return zX(dQ(G,E.length-W),E,W,C)}function NQ(E,G,W){if(G===0&&W===E.length)return MI(E);else return MI(E.slice(G,W))}function NI(E,G,W){W=Math.min(E.length,W);let C=[],H=G;while(H<W){let z=E[H],V=null,P=z>239?4:z>223?3:z>191?2:1;if(H+P<=W){let k,R,S,D;switch(P){case 1:if(z<128)V=z;break;case 2:if(k=E[H+1],(k&192)===128){if(D=(z&31)<<6|k&63,D>127)V=D}break;case 3:if(k=E[H+1],R=E[H+2],(k&192)===128&&(R&192)===128){if(D=(z&15)<<12|(k&63)<<6|R&63,D>2047&&(D<55296||D>57343))V=D}break;case 4:if(k=E[H+1],R=E[H+2],S=E[H+3],(k&192)===128&&(R&192)===128&&(S&192)===128){if(D=(z&15)<<18|(k&63)<<12|(R&63)<<6|S&63,D>65535&&D<1114112)V=D}}}if(V===null)V=65533,P=1;else if(V>65535)V-=65536,C.push(V>>>10&1023|55296),V=56320|V&1023;C.push(V),H+=P}return _Q(C)}function _Q(E){let G=E.length;if(G<=PI)return String.fromCharCode.apply(String,E);let W="",C=0;while(C<G)W+=String.fromCharCode.apply(String,E.slice(C,C+=PI));return W}function wQ(E,G,W){let C="";W=Math.min(E.length,W);for(let H=G;H<W;++H)C+=String.fromCharCode(E[H]&127);return C}function yQ(E,G,W){let C="";W=Math.min(E.length,W);for(let H=G;H<W;++H)C+=String.fromCharCode(E[H]);return C}function fQ(E,G,W){let C=E.length;if(!G||G<0)G=0;if(!W||W<0||W>C)W=C;let H="";for(let z=G;z<W;++z)H+=bQ[E[z]];return H}function cQ(E,G,W){let C=E.slice(G,W),H="";for(let z=0;z<C.length-1;z+=2)H+=String.fromCharCode(C[z]+C[z+1]*256);return H}function JU(E,G,W){if(E%1!==0||E<0)throw new RangeError("offset is not uint");if(E+G>W)throw new RangeError("Trying to access beyond buffer length")}function RU(E,G,W,C,H,z){if(!K0.isBuffer(E))throw new TypeError('"buffer" argument must be a Buffer instance');if(G>H||G<z)throw new RangeError('"value" argument is out of bounds');if(W+C>E.length)throw new RangeError("Index out of range")}function _I(E,G,W,C,H){pI(G,C,H,E,W,7);let z=Number(G&BigInt(4294967295));E[W++]=z,z=z>>8,E[W++]=z,z=z>>8,E[W++]=z,z=z>>8,E[W++]=z;let V=Number(G>>BigInt(32)&BigInt(4294967295));return E[W++]=V,V=V>>8,E[W++]=V,V=V>>8,E[W++]=V,V=V>>8,E[W++]=V,W}function wI(E,G,W,C,H){pI(G,C,H,E,W,7);let z=Number(G&BigInt(4294967295));E[W+7]=z,z=z>>8,E[W+6]=z,z=z>>8,E[W+5]=z,z=z>>8,E[W+4]=z;let V=Number(G>>BigInt(32)&BigInt(4294967295));return E[W+3]=V,V=V>>8,E[W+2]=V,V=V>>8,E[W+1]=V,V=V>>8,E[W]=V,W+8}function yI(E,G,W,C,H,z){if(W+C>E.length)throw new RangeError("Index out of range");if(W<0)throw new RangeError("Index out of range")}function fI(E,G,W,C,H){if(G=+G,W=W>>>0,!H)yI(E,G,W,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return vI(E,G,W,C,23,4),W+4}function cI(E,G,W,C,H){if(G=+G,W=W>>>0,!H)yI(E,G,W,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return vI(E,G,W,C,52,8),W+8}function qI(E){let G="",W=E.length,C=E[0]==="-"?1:0;for(;W>=C+4;W-=3)G=`_${E.slice(W-3,W)}${G}`;return`${E.slice(0,W)}${G}`}function pQ(E,G,W){if(QX(G,"offset"),E[G]===void 0||E[G+W]===void 0)KX(G,E.length-(W+1))}function pI(E,G,W,C,H,z){if(E>W||E<G){let V=typeof G==="bigint"?"n":"",P;if(z>3)if(G===0||G===BigInt(0))P=`>= 0${V} and < 2${V} ** ${(z+1)*8}${V}`;else P=`>= -(2${V} ** ${(z+1)*8-1}${V}) and < 2 ** ${(z+1)*8-1}${V}`;else P=`>= ${G}${V} and <= ${W}${V}`;throw new hX("value",P,E)}pQ(C,H,z)}function QX(E,G){if(typeof E!=="number")throw new MQ(G,"number",E)}function KX(E,G,W){if(Math.floor(E)!==E)throw QX(E,W),new hX(W||"offset","an integer",E);if(G<0)throw new zQ;throw new hX(W||"offset",`>= ${W?1:0} and <= ${G}`,E)}function uQ(E){if(E=E.split("=")[0],E=E.trim().replace(hQ,""),E.length<2)return"";while(E.length%4!==0)E=E+"=";return E}function dX(E,G){G=G||1/0;let W,C=E.length,H=null,z=[];for(let V=0;V<C;++V){if(W=E.charCodeAt(V),W>55295&&W<57344){if(!H){if(W>56319){if((G-=3)>-1)z.push(239,191,189);continue}else if(V+1===C){if((G-=3)>-1)z.push(239,191,189);continue}H=W;continue}if(W<56320){if((G-=3)>-1)z.push(239,191,189);H=W;continue}W=(H-55296<<10|W-56320)+65536}else if(H){if((G-=3)>-1)z.push(239,191,189)}if(H=null,W<128){if((G-=1)<0)break;z.push(W)}else if(W<2048){if((G-=2)<0)break;z.push(W>>6|192,W&63|128)}else if(W<65536){if((G-=3)<0)break;z.push(W>>12|224,W>>6&63|128,W&63|128)}else if(W<1114112){if((G-=4)<0)break;z.push(W>>18|240,W>>12&63|128,W>>6&63|128,W&63|128)}else throw new Error("Invalid code point")}return z}function lQ(E){let G=[];for(let W=0;W<E.length;++W)G.push(E.charCodeAt(W)&255);return G}function dQ(E,G){let W,C,H,z=[];for(let V=0;V<E.length;++V){if((G-=2)<0)break;W=E.charCodeAt(V),C=W>>8,H=W%256,z.push(H),z.push(C)}return z}function hI(E){return JQ(uQ(E))}function zX(E,G,W,C){let H;for(H=0;H<C;++H){if(H+W>=G.length||H>=E.length)break;G[H+W]=E[H]}return H}function _U(E,G){return E instanceof G||E!=null&&E.constructor!=null&&E.constructor.name!=null&&E.constructor.name===G.name}function bU(E){return typeof BigInt==="undefined"?oQ:E}function oQ(){throw new Error("BigInt not supported")}function sX(E){return()=>{throw new Error(E+" is not implemented for node:buffer browser polyfill")}}var NU,jU,pX="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",tU,zI,RI,AQ=50,GX=2147483647,kI=536870888,EQ,CQ,TQ,DQ,LQ,zQ,MQ,hX,PI=4096,hQ,bQ,nQ,sQ,mQ=(E)=>{for(let G of E)if(G.charCodeAt(0)>127)return!1;return!0},tQ,rQ;var HU=ZX(()=>{NU=[],jU=[];for(tU=0,zI=pX.length;tU<zI;++tU)NU[tU]=pX[tU],jU[pX.charCodeAt(tU)]=tU;jU[45]=62;jU[95]=63;RI=typeof Symbol==="function"&&typeof Symbol.for==="function"?Symbol.for("nodejs.util.inspect.custom"):null,EQ=globalThis.btoa,CQ=globalThis.atob,TQ=globalThis.File,DQ=globalThis.Blob,LQ={MAX_LENGTH:GX,MAX_STRING_LENGTH:kI};zQ=bX("ERR_BUFFER_OUT_OF_BOUNDS",function(E){if(E)return`${E} is outside of buffer bounds`;return"Attempt to access memory outside buffer bounds"},RangeError),MQ=bX("ERR_INVALID_ARG_TYPE",function(E,G){return`The "${E}" argument must be of type number. Received type ${typeof G}`},TypeError),hX=bX("ERR_OUT_OF_RANGE",function(E,G,W){let C=`The value of "${E}" is out of range.`,H=W;if(Number.isInteger(W)&&Math.abs(W)>4294967296)H=qI(String(W));else if(typeof W==="bigint"){if(H=String(W),W>BigInt(2)**BigInt(32)||W<-(BigInt(2)**BigInt(32)))H=qI(H);H+="n"}return C+=` It must be ${G}. Received ${H}`,C},RangeError);Object.defineProperty(K0.prototype,"parent",{enumerable:!0,get:function(){if(!K0.isBuffer(this))return;return this.buffer}});Object.defineProperty(K0.prototype,"offset",{enumerable:!0,get:function(){if(!K0.isBuffer(this))return;return this.byteOffset}});K0.poolSize=8192;K0.from=function(E,G,W){return jI(E,G,W)};Object.setPrototypeOf(K0.prototype,Uint8Array.prototype);Object.setPrototypeOf(K0,Uint8Array);K0.alloc=function(E,G,W){return RQ(E,G,W)};K0.allocUnsafe=function(E){return oX(E)};K0.allocUnsafeSlow=function(E){return oX(E)};K0.isBuffer=function E(G){return G!=null&&G._isBuffer===!0&&G!==K0.prototype};K0.compare=function E(G,W){if(_U(G,Uint8Array))G=K0.from(G,G.offset,G.byteLength);if(_U(W,Uint8Array))W=K0.from(W,W.offset,W.byteLength);if(!K0.isBuffer(G)||!K0.isBuffer(W))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(G===W)return 0;let C=G.length,H=W.length;for(let z=0,V=Math.min(C,H);z<V;++z)if(G[z]!==W[z]){C=G[z],H=W[z];break}if(C<H)return-1;if(H<C)return 1;return 0};K0.isEncoding=function E(G){switch(String(G).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}};K0.concat=function E(G,W){if(!Array.isArray(G))throw new TypeError('"list" argument must be an Array of Buffers');if(G.length===0)return K0.alloc(0);let C;if(W===void 0){W=0;for(C=0;C<G.length;++C)W+=G[C].length}let H=K0.allocUnsafe(W),z=0;for(C=0;C<G.length;++C){let V=G[C];if(_U(V,Uint8Array))if(z+V.length>H.length){if(!K0.isBuffer(V))V=K0.from(V);V.copy(H,z)}else Uint8Array.prototype.set.call(H,V,z);else if(!K0.isBuffer(V))throw new TypeError('"list" argument must be an Array of Buffers');else V.copy(H,z);z+=V.length}return H};K0.byteLength=xI;K0.prototype._isBuffer=!0;K0.prototype.swap16=function E(){let G=this.length;if(G%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let W=0;W<G;W+=2)rU(this,W,W+1);return this};K0.prototype.swap32=function E(){let G=this.length;if(G%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let W=0;W<G;W+=4)rU(this,W,W+3),rU(this,W+1,W+2);return this};K0.prototype.swap64=function E(){let G=this.length;if(G%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let W=0;W<G;W+=8)rU(this,W,W+7),rU(this,W+1,W+6),rU(this,W+2,W+5),rU(this,W+3,W+4);return this};K0.prototype.toString=function E(){let G=this.length;if(G===0)return"";if(arguments.length===0)return NI(this,0,G);return vQ.apply(this,arguments)};K0.prototype.toLocaleString=K0.prototype.toString;K0.prototype.equals=function E(G){if(!K0.isBuffer(G))throw new TypeError("Argument must be a Buffer");if(this===G)return!0;return K0.compare(this,G)===0};K0.prototype.inspect=function E(){let G="",W=exports_buffer.INSPECT_MAX_BYTES;if(G=this.toString("hex",0,W).replace(/(.{2})/g,"$1 ").trim(),this.length>W)G+=" ... ";return"<Buffer "+G+">"};if(RI)K0.prototype[RI]=K0.prototype.inspect;K0.prototype.compare=function E(G,W,C,H,z){if(_U(G,Uint8Array))G=K0.from(G,G.offset,G.byteLength);if(!K0.isBuffer(G))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof G);if(W===void 0)W=0;if(C===void 0)C=G?G.length:0;if(H===void 0)H=0;if(z===void 0)z=this.length;if(W<0||C>G.length||H<0||z>this.length)throw new RangeError("out of range index");if(H>=z&&W>=C)return 0;if(H>=z)return-1;if(W>=C)return 1;if(W>>>=0,C>>>=0,H>>>=0,z>>>=0,this===G)return 0;let V=z-H,P=C-W,k=Math.min(V,P),R=this.slice(H,z),S=G.slice(W,C);for(let D=0;D<k;++D)if(R[D]!==S[D]){V=R[D],P=S[D];break}if(V<P)return-1;if(P<V)return 1;return 0};K0.prototype.includes=function E(G,W,C){return this.indexOf(G,W,C)!==-1};K0.prototype.indexOf=function E(G,W,C){return gI(this,G,W,C,!0)};K0.prototype.lastIndexOf=function E(G,W,C){return gI(this,G,W,C,!1)};K0.prototype.write=function E(G,W,C,H){if(W===void 0)H="utf8",C=this.length,W=0;else if(C===void 0&&typeof W==="string")H=W,C=this.length,W=0;else if(isFinite(W))if(W=W>>>0,isFinite(C)){if(C=C>>>0,H===void 0)H="utf8"}else H=C,C=void 0;else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let z=this.length-W;if(C===void 0||C>z)C=z;if(G.length>0&&(C<0||W<0)||W>this.length)throw new RangeError("Attempt to write outside buffer bounds");if(!H)H="utf8";let V=!1;for(;;)switch(H){case"hex":return kQ(this,G,W,C);case"utf8":case"utf-8":return jQ(this,G,W,C);case"ascii":case"latin1":case"binary":return BQ(this,G,W,C);case"base64":return xQ(this,G,W,C);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return gQ(this,G,W,C);default:if(V)throw new TypeError("Unknown encoding: "+H);H=(""+H).toLowerCase(),V=!0}};K0.prototype.toJSON=function E(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};K0.prototype.slice=function E(G,W){let C=this.length;if(G=~~G,W=W===void 0?C:~~W,G<0){if(G+=C,G<0)G=0}else if(G>C)G=C;if(W<0){if(W+=C,W<0)W=0}else if(W>C)W=C;if(W<G)W=G;let H=this.subarray(G,W);return Object.setPrototypeOf(H,K0.prototype),H};K0.prototype.readUintLE=K0.prototype.readUIntLE=function E(G,W,C){if(G=G>>>0,W=W>>>0,!C)JU(G,W,this.length);let H=this[G],z=1,V=0;while(++V<W&&(z*=256))H+=this[G+V]*z;return H};K0.prototype.readUintBE=K0.prototype.readUIntBE=function E(G,W,C){if(G=G>>>0,W=W>>>0,!C)JU(G,W,this.length);let H=this[G+--W],z=1;while(W>0&&(z*=256))H+=this[G+--W]*z;return H};K0.prototype.readUint8=K0.prototype.readUInt8=function E(G,W){if(G=G>>>0,!W)JU(G,1,this.length);return this[G]};K0.prototype.readUint16LE=K0.prototype.readUInt16LE=function E(G,W){if(G=G>>>0,!W)JU(G,2,this.length);return this[G]|this[G+1]<<8};K0.prototype.readUint16BE=K0.prototype.readUInt16BE=function E(G,W){if(G=G>>>0,!W)JU(G,2,this.length);return this[G]<<8|this[G+1]};K0.prototype.readUint32LE=K0.prototype.readUInt32LE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return(this[G]|this[G+1]<<8|this[G+2]<<16)+this[G+3]*16777216};K0.prototype.readUint32BE=K0.prototype.readUInt32BE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return this[G]*16777216+(this[G+1]<<16|this[G+2]<<8|this[G+3])};K0.prototype.readBigUInt64LE=bU(function E(G){G=G>>>0,QX(G,"offset");let W=this[G],C=this[G+7];if(W===void 0||C===void 0)KX(G,this.length-8);let H=W+this[++G]*256+this[++G]*65536+this[++G]*16777216,z=this[++G]+this[++G]*256+this[++G]*65536+C*16777216;return BigInt(H)+(BigInt(z)<<BigInt(32))});K0.prototype.readBigUInt64BE=bU(function E(G){G=G>>>0,QX(G,"offset");let W=this[G],C=this[G+7];if(W===void 0||C===void 0)KX(G,this.length-8);let H=W*16777216+this[++G]*65536+this[++G]*256+this[++G],z=this[++G]*16777216+this[++G]*65536+this[++G]*256+C;return(BigInt(H)<<BigInt(32))+BigInt(z)});K0.prototype.readIntLE=function E(G,W,C){if(G=G>>>0,W=W>>>0,!C)JU(G,W,this.length);let H=this[G],z=1,V=0;while(++V<W&&(z*=256))H+=this[G+V]*z;if(z*=128,H>=z)H-=Math.pow(2,8*W);return H};K0.prototype.readIntBE=function E(G,W,C){if(G=G>>>0,W=W>>>0,!C)JU(G,W,this.length);let H=W,z=1,V=this[G+--H];while(H>0&&(z*=256))V+=this[G+--H]*z;if(z*=128,V>=z)V-=Math.pow(2,8*W);return V};K0.prototype.readInt8=function E(G,W){if(G=G>>>0,!W)JU(G,1,this.length);if(!(this[G]&128))return this[G];return(255-this[G]+1)*-1};K0.prototype.readInt16LE=function E(G,W){if(G=G>>>0,!W)JU(G,2,this.length);let C=this[G]|this[G+1]<<8;return C&32768?C|4294901760:C};K0.prototype.readInt16BE=function E(G,W){if(G=G>>>0,!W)JU(G,2,this.length);let C=this[G+1]|this[G]<<8;return C&32768?C|4294901760:C};K0.prototype.readInt32LE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return this[G]|this[G+1]<<8|this[G+2]<<16|this[G+3]<<24};K0.prototype.readInt32BE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return this[G]<<24|this[G+1]<<16|this[G+2]<<8|this[G+3]};K0.prototype.readBigInt64LE=bU(function E(G){G=G>>>0,QX(G,"offset");let W=this[G],C=this[G+7];if(W===void 0||C===void 0)KX(G,this.length-8);let H=this[G+4]+this[G+5]*256+this[G+6]*65536+(C<<24);return(BigInt(H)<<BigInt(32))+BigInt(W+this[++G]*256+this[++G]*65536+this[++G]*16777216)});K0.prototype.readBigInt64BE=bU(function E(G){G=G>>>0,QX(G,"offset");let W=this[G],C=this[G+7];if(W===void 0||C===void 0)KX(G,this.length-8);let H=(W<<24)+this[++G]*65536+this[++G]*256+this[++G];return(BigInt(H)<<BigInt(32))+BigInt(this[++G]*16777216+this[++G]*65536+this[++G]*256+C)});K0.prototype.readFloatLE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return LX(this,G,!0,23,4)};K0.prototype.readFloatBE=function E(G,W){if(G=G>>>0,!W)JU(G,4,this.length);return LX(this,G,!1,23,4)};K0.prototype.readDoubleLE=function E(G,W){if(G=G>>>0,!W)JU(G,8,this.length);return LX(this,G,!0,52,8)};K0.prototype.readDoubleBE=function E(G,W){if(G=G>>>0,!W)JU(G,8,this.length);return LX(this,G,!1,52,8)};K0.prototype.writeUintLE=K0.prototype.writeUIntLE=function E(G,W,C,H){if(G=+G,W=W>>>0,C=C>>>0,!H){let P=Math.pow(2,8*C)-1;RU(this,G,W,C,P,0)}let z=1,V=0;this[W]=G&255;while(++V<C&&(z*=256))this[W+V]=G/z&255;return W+C};K0.prototype.writeUintBE=K0.prototype.writeUIntBE=function E(G,W,C,H){if(G=+G,W=W>>>0,C=C>>>0,!H){let P=Math.pow(2,8*C)-1;RU(this,G,W,C,P,0)}let z=C-1,V=1;this[W+z]=G&255;while(--z>=0&&(V*=256))this[W+z]=G/V&255;return W+C};K0.prototype.writeUint8=K0.prototype.writeUInt8=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,1,255,0);return this[W]=G&255,W+1};K0.prototype.writeUint16LE=K0.prototype.writeUInt16LE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,2,65535,0);return this[W]=G&255,this[W+1]=G>>>8,W+2};K0.prototype.writeUint16BE=K0.prototype.writeUInt16BE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,2,65535,0);return this[W]=G>>>8,this[W+1]=G&255,W+2};K0.prototype.writeUint32LE=K0.prototype.writeUInt32LE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,4,4294967295,0);return this[W+3]=G>>>24,this[W+2]=G>>>16,this[W+1]=G>>>8,this[W]=G&255,W+4};K0.prototype.writeUint32BE=K0.prototype.writeUInt32BE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,4,4294967295,0);return this[W]=G>>>24,this[W+1]=G>>>16,this[W+2]=G>>>8,this[W+3]=G&255,W+4};K0.prototype.writeBigUInt64LE=bU(function E(G,W=0){return _I(this,G,W,BigInt(0),BigInt("0xffffffffffffffff"))});K0.prototype.writeBigUInt64BE=bU(function E(G,W=0){return wI(this,G,W,BigInt(0),BigInt("0xffffffffffffffff"))});K0.prototype.writeIntLE=function E(G,W,C,H){if(G=+G,W=W>>>0,!H){let k=Math.pow(2,8*C-1);RU(this,G,W,C,k-1,-k)}let z=0,V=1,P=0;this[W]=G&255;while(++z<C&&(V*=256)){if(G<0&&P===0&&this[W+z-1]!==0)P=1;this[W+z]=(G/V>>0)-P&255}return W+C};K0.prototype.writeIntBE=function E(G,W,C,H){if(G=+G,W=W>>>0,!H){let k=Math.pow(2,8*C-1);RU(this,G,W,C,k-1,-k)}let z=C-1,V=1,P=0;this[W+z]=G&255;while(--z>=0&&(V*=256)){if(G<0&&P===0&&this[W+z+1]!==0)P=1;this[W+z]=(G/V>>0)-P&255}return W+C};K0.prototype.writeInt8=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,1,127,-128);if(G<0)G=255+G+1;return this[W]=G&255,W+1};K0.prototype.writeInt16LE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,2,32767,-32768);return this[W]=G&255,this[W+1]=G>>>8,W+2};K0.prototype.writeInt16BE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,2,32767,-32768);return this[W]=G>>>8,this[W+1]=G&255,W+2};K0.prototype.writeInt32LE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,4,2147483647,-2147483648);return this[W]=G&255,this[W+1]=G>>>8,this[W+2]=G>>>16,this[W+3]=G>>>24,W+4};K0.prototype.writeInt32BE=function E(G,W,C){if(G=+G,W=W>>>0,!C)RU(this,G,W,4,2147483647,-2147483648);if(G<0)G=4294967295+G+1;return this[W]=G>>>24,this[W+1]=G>>>16,this[W+2]=G>>>8,this[W+3]=G&255,W+4};K0.prototype.writeBigInt64LE=bU(function E(G,W=0){return _I(this,G,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});K0.prototype.writeBigInt64BE=bU(function E(G,W=0){return wI(this,G,W,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});K0.prototype.writeFloatLE=function E(G,W,C){return fI(this,G,W,!0,C)};K0.prototype.writeFloatBE=function E(G,W,C){return fI(this,G,W,!1,C)};K0.prototype.writeDoubleLE=function E(G,W,C){return cI(this,G,W,!0,C)};K0.prototype.writeDoubleBE=function E(G,W,C){return cI(this,G,W,!1,C)};K0.prototype.copy=function E(G,W,C,H){if(!K0.isBuffer(G))throw new TypeError("argument should be a Buffer");if(!C)C=0;if(!H&&H!==0)H=this.length;if(W>=G.length)W=G.length;if(!W)W=0;if(H>0&&H<C)H=C;if(H===C)return 0;if(G.length===0||this.length===0)return 0;if(W<0)throw new RangeError("targetStart out of bounds");if(C<0||C>=this.length)throw new RangeError("Index out of range");if(H<0)throw new RangeError("sourceEnd out of bounds");if(H>this.length)H=this.length;if(G.length-W<H-C)H=G.length-W+C;let z=H-C;if(this===G&&typeof Uint8Array.prototype.copyWithin==="function")this.copyWithin(W,C,H);else Uint8Array.prototype.set.call(G,this.subarray(C,H),W);return z};K0.prototype.fill=function E(G,W,C,H){if(typeof G==="string"){if(typeof W==="string")H=W,W=0,C=this.length;else if(typeof C==="string")H=C,C=this.length;if(H!==void 0&&typeof H!=="string")throw new TypeError("encoding must be a string");if(typeof H==="string"&&!K0.isEncoding(H))throw new TypeError("Unknown encoding: "+H);if(G.length===1){let V=G.charCodeAt(0);if(H==="utf8"&&V<128||H==="latin1")G=V}}else if(typeof G==="number")G=G&255;else if(typeof G==="boolean")G=Number(G);if(W<0||this.length<W||this.length<C)throw new RangeError("Out of range index");if(C<=W)return this;if(W=W>>>0,C=C===void 0?this.length:C>>>0,!G)G=0;let z;if(typeof G==="number")for(z=W;z<C;++z)this[z]=G;else{let V=K0.isBuffer(G)?G:K0.from(G,H),P=V.length;if(P===0)throw new TypeError('The value "'+G+'" is invalid for argument "value"');for(z=0;z<C-W;++z)this[z+W]=V[z%P]}return this};hQ=/[^+/0-9A-Za-z-_]/g;bQ=function(){let E=new Array(256);for(let G=0;G<16;++G){let W=G*16;for(let C=0;C<16;++C)E[W+C]="0123456789abcdef"[G]+"0123456789abcdef"[C]}return E}();nQ=sX("resolveObjectURL"),sQ=sX("isUtf8"),tQ=sX("transcode"),rQ=K0});var nI={};IX(nI,{types:()=>Y$,promisify:()=>A$,log:()=>F$,isUndefined:()=>$X,isSymbol:()=>O$,isString:()=>vX,isRegExp:()=>MX,isPrimitive:()=>G$,isObject:()=>YX,isNumber:()=>lI,isNullOrUndefined:()=>V$,isNull:()=>qX,isFunction:()=>SX,isError:()=>RX,isDate:()=>aX,isBuffer:()=>K$,isBoolean:()=>iX,isArray:()=>uI,inspect:()=>aU,inherits:()=>H$,format:()=>eX,deprecate:()=>eQ,debuglog:()=>iQ,callbackifyOnRejected:()=>oI,callbackify:()=>E$,_extend:()=>dI,TextEncoder:()=>C$,TextDecoder:()=>T$});function eX(E,...G){if(!vX(E)){var W=[E];for(var C=0;C<G.length;C++)W.push(aU(G[C]));return W.join(" ")}var C=0,H=G.length,z=String(E).replace(aQ,function(P){if(P==="%%")return"%";if(C>=H)return P;switch(P){case"%s":return String(G[C++]);case"%d":return Number(G[C++]);case"%j":try{return JSON.stringify(G[C++])}catch(k){return"[Circular]"}default:return P}});for(var V=G[C];C<H;V=G[++C])if(qX(V)||!YX(V))z+=" "+V;else z+=" "+aU(V);return z}function eQ(E,G){if(typeof process==="undefined"||process?.noDeprecation===!0)return E;var W=!1;function C(...H){if(!W){if(process.throwDeprecation)throw new Error(G);else if(process.traceDeprecation)console.trace(G);else console.error(G);W=!0}return E.apply(this,...H)}return C}function U$(E,G){var W=aU.styles[G];if(W)return"\x1B["+aU.colors[W][0]+"m"+E+"\x1B["+aU.colors[W][1]+"m";else return E}function X$(E,G){return E}function I$(E){var G={};return E.forEach(function(W,C){G[W]=!0}),G}function PX(E,G,W){if(E.customInspect&&G&&SX(G.inspect)&&G.inspect!==aU&&!(G.constructor&&G.constructor.prototype===G)){var C=G.inspect(W,E);if(!vX(C))C=PX(E,C,W);return C}var H=Z$(E,G);if(H)return H;var z=Object.keys(G),V=I$(z);if(E.showHidden)z=Object.getOwnPropertyNames(G);if(RX(G)&&(z.indexOf("message")>=0||z.indexOf("description")>=0))return mX(G);if(z.length===0){if(SX(G)){var P=G.name?": "+G.name:"";return E.stylize("[Function"+P+"]","special")}if(MX(G))return E.stylize(RegExp.prototype.toString.call(G),"regexp");if(aX(G))return E.stylize(Date.prototype.toString.call(G),"date");if(RX(G))return mX(G)}var k="",R=!1,S=["{","}"];if(uI(G))R=!0,S=["[","]"];if(SX(G)){var D=G.name?": "+G.name:"";k=" [Function"+D+"]"}if(MX(G))k=" "+RegExp.prototype.toString.call(G);if(aX(G))k=" "+Date.prototype.toUTCString.call(G);if(RX(G))k=" "+mX(G);if(z.length===0&&(!R||G.length==0))return S[0]+k+S[1];if(W<0)if(MX(G))return E.stylize(RegExp.prototype.toString.call(G),"regexp");else return E.stylize("[Object]","special");E.seen.push(G);var A;if(R)A=Q$(E,G,W,V,z);else A=z.map(function(L){return rX(E,G,W,V,L,R)});return E.seen.pop(),$$(A,k,S)}function Z$(E,G){if($X(G))return E.stylize("undefined","undefined");if(vX(G)){var W="'"+JSON.stringify(G).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return E.stylize(W,"string")}if(lI(G))return E.stylize(""+G,"number");if(iX(G))return E.stylize(""+G,"boolean");if(qX(G))return E.stylize("null","null")}function mX(E){return"["+Error.prototype.toString.call(E)+"]"}function Q$(E,G,W,C,H){var z=[];for(var V=0,P=G.length;V<P;++V)if(bI(G,String(V)))z.push(rX(E,G,W,C,String(V),!0));else z.push("");return H.forEach(function(k){if(!k.match(/^\d+$/))z.push(rX(E,G,W,C,k,!0))}),z}function rX(E,G,W,C,H,z){var V,P,k;if(k=Object.getOwnPropertyDescriptor(G,H)||{value:G[H]},k.get)if(k.set)P=E.stylize("[Getter/Setter]","special");else P=E.stylize("[Getter]","special");else if(k.set)P=E.stylize("[Setter]","special");if(!bI(C,H))V="["+H+"]";if(!P)if(E.seen.indexOf(k.value)<0){if(qX(W))P=PX(E,k.value,null);else P=PX(E,k.value,W-1);if(P.indexOf(`
2
+ `)>-1)if(z)P=P.split(`
3
+ `).map(function(R){return" "+R}).join(`
4
+ `).slice(2);else P=`
5
+ `+P.split(`
6
+ `).map(function(R){return" "+R}).join(`
7
+ `)}else P=E.stylize("[Circular]","special");if($X(V)){if(z&&H.match(/^\d+$/))return P;if(V=JSON.stringify(""+H),V.match(/^"([a-zA-Z_][a-zA-Z_0-9]*)"$/))V=V.slice(1,-1),V=E.stylize(V,"name");else V=V.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),V=E.stylize(V,"string")}return V+": "+P}function $$(E,G,W){var C=0,H=E.reduce(function(z,V){if(C++,V.indexOf(`
8
+ `)>=0)C++;return z+V.replace(/\u001b\[\d\d?m/g,"").length+1},0);if(H>60)return W[0]+(G===""?"":G+`
9
+ `)+" "+E.join(`,
10
+ `)+" "+W[1];return W[0]+G+" "+E.join(", ")+" "+W[1]}function uI(E){return Array.isArray(E)}function iX(E){return typeof E==="boolean"}function qX(E){return E===null}function V$(E){return E==null}function lI(E){return typeof E==="number"}function vX(E){return typeof E==="string"}function O$(E){return typeof E==="symbol"}function $X(E){return E===void 0}function MX(E){return YX(E)&&UI(E)==="[object RegExp]"}function YX(E){return typeof E==="object"&&E!==null}function aX(E){return YX(E)&&UI(E)==="[object Date]"}function RX(E){return YX(E)&&(UI(E)==="[object Error]"||E instanceof Error)}function SX(E){return typeof E==="function"}function G$(E){return E===null||typeof E==="boolean"||typeof E==="number"||typeof E==="string"||typeof E==="symbol"||typeof E==="undefined"}function K$(E){return E instanceof Buffer}function UI(E){return Object.prototype.toString.call(E)}function tX(E){return E<10?"0"+E.toString(10):E.toString(10)}function J$(){var E=new Date,G=[tX(E.getHours()),tX(E.getMinutes()),tX(E.getSeconds())].join(":");return[E.getDate(),W$[E.getMonth()],G].join(" ")}function F$(...E){console.log("%s - %s",J$(),eX.apply(null,E))}function H$(E,G){if(G)E.super_=G,E.prototype=Object.create(G.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}})}function dI(E,G){if(!G||!YX(G))return E;var W=Object.keys(G),C=W.length;while(C--)E[W[C]]=G[W[C]];return E}function bI(E,G){return Object.prototype.hasOwnProperty.call(E,G)}function oI(E,G){if(!E){var W=new Error("Promise was rejected with a falsy value");W.reason=E,E=W}return G(E)}function E$(E){if(typeof E!=="function")throw new TypeError('The "original" argument must be of type Function');function G(...W){var C=W.pop();if(typeof C!=="function")throw new TypeError("The last argument must be of type Function");var H=this,z=function(...V){return C.apply(H,...V)};E.apply(this,W).then(function(V){process.nextTick(z.bind(null,null,V))},function(V){process.nextTick(oI.bind(null,V,z))})}return Object.setPrototypeOf(G,Object.getPrototypeOf(E)),Object.defineProperties(G,Object.getOwnPropertyDescriptors(E)),G}var aQ,iQ,aU,Y$=()=>{},W$,A$,C$,T$;var sI=ZX(()=>{aQ=/%[sdj%]/g;iQ=((E={},G={},W)=>((W=typeof process!=="undefined"&&process.env.NODE_DEBUG)&&(W=W.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase()),G=new RegExp("^"+W+"$","i"),(C)=>{if(C=C.toUpperCase(),!E[C])if(G.test(C))E[C]=function(...H){console.error("%s: %s",C,pid,eX.apply(null,...H))};else E[C]=function(){};return E[C]}))(),aU=((E)=>(E.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]},E.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},E.custom=Symbol.for("nodejs.util.inspect.custom"),E))(function E(G,W,...C){var H={seen:[],stylize:X$};if(C.length>=1)H.depth=C[0];if(C.length>=2)H.colors=C[1];if(iX(W))H.showHidden=W;else if(W)dI(H,W);if($X(H.showHidden))H.showHidden=!1;if($X(H.depth))H.depth=2;if($X(H.colors))H.colors=!1;if(H.colors)H.stylize=U$;return PX(H,G,H.depth)});W$=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];A$=((E)=>(E.custom=Symbol.for("nodejs.util.promisify.custom"),E))(function E(G){if(typeof G!=="function")throw new TypeError('The "original" argument must be of type Function');if(kCustomPromisifiedSymbol&&G[kCustomPromisifiedSymbol]){var W=G[kCustomPromisifiedSymbol];if(typeof W!=="function")throw new TypeError('The "nodejs.util.promisify.custom" argument must be of type Function');return Object.defineProperty(W,kCustomPromisifiedSymbol,{value:W,enumerable:!1,writable:!1,configurable:!0}),W}function W(...C){var H,z,V=new Promise(function(P,k){H=P,z=k});C.push(function(P,k){if(P)z(P);else H(k)});try{G.apply(this,C)}catch(P){z(P)}return V}if(Object.setPrototypeOf(W,Object.getPrototypeOf(G)),kCustomPromisifiedSymbol)Object.defineProperty(W,kCustomPromisifiedSymbol,{value:W,enumerable:!1,writable:!1,configurable:!0});return Object.defineProperties(W,Object.getOwnPropertyDescriptors(G))});({TextEncoder:C$,TextDecoder:T$}=globalThis)});var JX={};IX(JX,{setMaxListeners:()=>QZ,once:()=>IZ,listenerCount:()=>$Z,init:()=>oU,getMaxListeners:()=>VZ,getEventListeners:()=>ZZ,default:()=>v$,captureRejectionSymbol:()=>eI,addAbortListener:()=>OZ,EventEmitter:()=>oU});function iI(E,G){var{_events:W}=E;if(G[0]??=new Error("Unhandled error."),!W)throw G[0];var C=W[aI];if(C)for(var H of tI.$call(C))H.$apply(E,G);var z=W.error;if(!z)throw G[0];for(var H of tI.$call(z))H.$apply(E,G);return!0}function z$(E,G,W,C){G.then(void 0,function(H){process.nextTick(M$,E,H,W,C)})}function M$(E,G,W,C){if(typeof E[mI]==="function")E[mI](G,W,...C);else try{E[eU]=!1,E.emit("error",G)}finally{E[eU]=!0}}function UZ(E,G,W){W.warned=!0;let C=new Error(`Possible EventEmitter memory leak detected. ${W.length} ${String(G)} listeners added to [${E.constructor.name}]. Use emitter.setMaxListeners() to increase limit`);C.name="MaxListenersExceededWarning",C.emitter=E,C.type=G,C.count=W.length,process.emitWarning(C)}function XZ(E,G,...W){this.removeListener(E,G),G.$apply(this,W)}function IZ(E,G,W){var C=W?.signal;if(YZ(C,"options.signal"),C?.aborted)throw new XI(void 0,{cause:C?.reason});let{resolve:H,reject:z,promise:V}=$newPromiseCapability(Promise),P=(S)=>{if(E.removeListener(G,k),C!=null)kX(C,"abort",R);z(S)},k=(...S)=>{if(typeof E.removeListener==="function")E.removeListener("error",P);if(C!=null)kX(C,"abort",R);H(S)};if(rI(E,G,k,{once:!0}),G!=="error"&&typeof E.once==="function")E.once("error",P);function R(){kX(E,G,k),kX(E,"error",P),z(new XI(void 0,{cause:C?.reason}))}if(C!=null)rI(C,"abort",R,{once:!0});return V}function ZZ(E,G){return E.listeners(G)}function QZ(E,...G){ZI(E,"setMaxListeners",0);var W;if(G&&(W=G.length))for(let C=0;C<W;C++)G[C].setMaxListeners(E);else iU=E}function $Z(E,G){return E.listenerCount(G)}function kX(E,G,W,C){if(typeof E.removeListener==="function")E.removeListener(G,W);else E.removeEventListener(G,W,C)}function rI(E,G,W,C){if(typeof E.on==="function")if(C.once)E.once(G,W);else E.on(G,W);else E.addEventListener(G,W,C)}function VX(E,G,W){let C=new TypeError(`The "${E}" argument must be of type ${G}. Received ${W}`);return C.code="ERR_INVALID_ARG_TYPE",C}function P$(E,G,W){let C=new RangeError(`The "${E}" argument is out of range. It must be ${G}. Received ${W}`);return C.code="ERR_OUT_OF_RANGE",C}function YZ(E,G){if(E!==void 0&&(E===null||typeof E!=="object"||!("aborted"in E)))throw VX(G,"AbortSignal",E)}function ZI(E,G,W,C){if(typeof E!=="number")throw VX(G,"number",E);if(W!=null&&E<W||C!=null&&E>C||(W!=null||C!=null)&&Number.isNaN(E))throw P$(G,`${W!=null?`>= ${W}`:""}${W!=null&&C!=null?" && ":""}${C!=null?`<= ${C}`:""}`,E)}function WX(E){if(typeof E!=="function")throw new TypeError("The listener must be a function")}function q$(E,G){if(typeof E!=="boolean")throw VX(G,"boolean",E)}function VZ(E){return E?._maxListeners??iU}function OZ(E,G){if(E===void 0)throw VX("signal","AbortSignal",E);if(YZ(E,"signal"),typeof G!=="function")throw VX("listener","function",G);let W;if(E.aborted)queueMicrotask(()=>G());else E.addEventListener("abort",G,{__proto__:null,once:!0}),W=()=>{E.removeEventListener("abort",G)};return{__proto__:null,[Symbol.dispose](){W?.()}}}var II,eU,aI,D$,L$,mI,eI,tI,iU=10,oU=function E(G){if(this._events===void 0||this._events===this.__proto__._events)this._events={__proto__:null},this._eventsCount=0;if(this._maxListeners??=void 0,this[eU]=G?.captureRejections?Boolean(G?.captureRejections):n0[eU])this.emit=S$},n0,R$=function E(G,...W){if(G==="error")return iI(this,W);var{_events:C}=this;if(C===void 0)return!1;var H=C[G];if(H===void 0)return!1;let z=H.length>1?H.slice():H;for(let V=0,{length:P}=z;V<P;V++){let k=z[V];switch(W.length){case 0:k.$call(this);break;case 1:k.$call(this,W[0]);break;case 2:k.$call(this,W[0],W[1]);break;case 3:k.$call(this,W[0],W[1],W[2]);break;default:k.$apply(this,W);break}}return!0},S$=function E(G,...W){if(G==="error")return iI(this,W);var{_events:C}=this;if(C===void 0)return!1;var H=C[G];if(H===void 0)return!1;let z=H.length>1?H.slice():H;for(let V=0,{length:P}=z;V<P;V++){let k=z[V],R;switch(W.length){case 0:R=k.$call(this);break;case 1:R=k.$call(this,W[0]);break;case 2:R=k.$call(this,W[0],W[1]);break;case 3:R=k.$call(this,W[0],W[1],W[2]);break;default:R=k.$apply(this,W);break}if(R!==void 0&&$isPromise(R))z$(this,R,G,W)}return!0},XI,v$;var FX=ZX(()=>{II=Symbol.for,eU=Symbol("kCapture"),aI=II("events.errorMonitor"),D$=Symbol("events.maxEventTargetListeners"),L$=Symbol("events.maxEventTargetListenersWarned"),mI=II("nodejs.rejection"),eI=II("nodejs.rejection"),tI=Array.prototype.slice,n0=oU.prototype={};n0._events=void 0;n0._eventsCount=0;n0._maxListeners=void 0;n0.setMaxListeners=function E(G){return ZI(G,"setMaxListeners",0),this._maxListeners=G,this};n0.constructor=oU;n0.getMaxListeners=function E(){return this?._maxListeners??iU};n0.emit=R$;n0.addListener=function E(G,W){WX(W);var C=this._events;if(!C)C=this._events={__proto__:null},this._eventsCount=0;else if(C.newListener)this.emit("newListener",G,W.listener??W);var H=C[G];if(!H)C[G]=[W],this._eventsCount++;else{H.push(W);var z=this._maxListeners??iU;if(z>0&&H.length>z&&!H.warned)UZ(this,G,H)}return this};n0.on=n0.addListener;n0.prependListener=function E(G,W){WX(W);var C=this._events;if(!C)C=this._events={__proto__:null},this._eventsCount=0;else if(C.newListener)this.emit("newListener",G,W.listener??W);var H=C[G];if(!H)C[G]=[W],this._eventsCount++;else{H.unshift(W);var z=this._maxListeners??iU;if(z>0&&H.length>z&&!H.warned)UZ(this,G,H)}return this};n0.once=function E(G,W){WX(W);let C=XZ.bind(this,G,W);return C.listener=W,this.addListener(G,C),this};n0.prependOnceListener=function E(G,W){WX(W);let C=XZ.bind(this,G,W);return C.listener=W,this.prependListener(G,C),this};n0.removeListener=function E(G,W){WX(W);var{_events:C}=this;if(!C)return this;var H=C[G];if(!H)return this;var z=H.length;let V=-1;for(let P=z-1;P>=0;P--)if(H[P]===W||H[P].listener===W){V=P;break}if(V<0)return this;if(V===0)H.shift();else H.splice(V,1);if(H.length===0)delete C[G],this._eventsCount--;return this};n0.off=n0.removeListener;n0.removeAllListeners=function E(G){var{_events:W}=this;if(G&&W){if(W[G])delete W[G],this._eventsCount--}else this._events={__proto__:null};return this};n0.listeners=function E(G){var{_events:W}=this;if(!W)return[];var C=W[G];if(!C)return[];return C.map((H)=>H.listener??H)};n0.rawListeners=function E(G){var{_events:W}=this;if(!W)return[];var C=W[G];if(!C)return[];return C.slice()};n0.listenerCount=function E(G){var{_events:W}=this;if(!W)return 0;return W[G]?.length??0};n0.eventNames=function E(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};n0[eU]=!1;XI=class XI extends Error{constructor(E="The operation was aborted",G=void 0){if(G!==void 0&&typeof G!=="object")throw VX("options","Object",G);super(E,G);this.code="ABORT_ERR",this.name="AbortError"}};Object.defineProperties(oU,{captureRejections:{get(){return n0[eU]},set(E){q$(E,"EventEmitter.captureRejections"),n0[eU]=E},enumerable:!0},defaultMaxListeners:{enumerable:!0,get:()=>{return iU},set:(E)=>{ZI(E,"defaultMaxListeners",0),iU=E}},kMaxEventTargetListeners:{value:D$,enumerable:!1,configurable:!1,writable:!1},kMaxEventTargetListenersWarned:{value:L$,enumerable:!1,configurable:!1,writable:!1}});Object.assign(oU,{once:IZ,getEventListeners:ZZ,getMaxListeners:VZ,setMaxListeners:QZ,EventEmitter:oU,usingDomains:!1,captureRejectionSymbol:eI,errorMonitor:aI,addAbortListener:OZ,init:oU,listenerCount:$Z});v$=oU});var VI={};IX(VI,{wrap:()=>o$,toWeb:()=>b$,pipeline:()=>$Y,isReadable:()=>r$,isErrored:()=>t$,isDisturbed:()=>m$,fromWeb:()=>d$,from:()=>l$,finished:()=>ZY,destroy:()=>QY,default:()=>OY,compose:()=>YY,addAbortSignal:()=>IY,_uint8ArrayToBuffer:()=>n$,_isUint8Array:()=>s$,_fromList:()=>u$,Writable:()=>e$,Transform:()=>UY,Stream:()=>VY,ReadableState:()=>h$,Readable:()=>a$,PassThrough:()=>XY,Duplex:()=>i$});var k$,j$,GZ,B$,x$,g$=(E,G,W)=>{W=E!=null?k$(j$(E)):{};let C=G||!E||!E.__esModule?GZ(W,"default",{value:E,enumerable:!0}):W;for(let H of B$(E))if(!x$.call(C,H))GZ(C,H,{get:()=>E[H],enumerable:!0});return C},d0=(E,G)=>()=>(G||E((G={exports:{}}).exports,G),G.exports),s0,KZ,MU,N$,HX,SU,AX,UX,uU,nU,OX,QI,jX,_$,BX,w$,y$,WZ,xX,$I,f$,hU,JZ,FZ,YI,HZ,c$,AZ,EZ,p$,m0,h$,u$,l$,d$,b$,o$,n$,s$,m$,t$,r$,a$,e$,i$,UY,XY,IY,ZY,QY,$Y,YY,VY,OY;var OI=ZX(()=>{k$=Object.create,{getPrototypeOf:j$,defineProperty:GZ,getOwnPropertyNames:B$}=Object,x$=Object.prototype.hasOwnProperty,s0=d0((E,G)=>{class W extends Error{constructor(C){if(!Array.isArray(C))throw new TypeError(`Expected input to be an Array, got ${typeof C}`);let H="";for(let z=0;z<C.length;z++)H+=` ${C[z].stack}
11
+ `;super(H);this.name="AggregateError",this.errors=C}}G.exports={AggregateError:W,ArrayIsArray(C){return Array.isArray(C)},ArrayPrototypeIncludes(C,H){return C.includes(H)},ArrayPrototypeIndexOf(C,H){return C.indexOf(H)},ArrayPrototypeJoin(C,H){return C.join(H)},ArrayPrototypeMap(C,H){return C.map(H)},ArrayPrototypePop(C,H){return C.pop(H)},ArrayPrototypePush(C,H){return C.push(H)},ArrayPrototypeSlice(C,H,z){return C.slice(H,z)},Error,FunctionPrototypeCall(C,H,...z){return C.call(H,...z)},FunctionPrototypeSymbolHasInstance(C,H){return Function.prototype[Symbol.hasInstance].call(C,H)},MathFloor:Math.floor,Number,NumberIsInteger:Number.isInteger,NumberIsNaN:Number.isNaN,NumberMAX_SAFE_INTEGER:Number.MAX_SAFE_INTEGER,NumberMIN_SAFE_INTEGER:Number.MIN_SAFE_INTEGER,NumberParseInt:Number.parseInt,ObjectDefineProperties(C,H){return Object.defineProperties(C,H)},ObjectDefineProperty(C,H,z){return Object.defineProperty(C,H,z)},ObjectGetOwnPropertyDescriptor(C,H){return Object.getOwnPropertyDescriptor(C,H)},ObjectKeys(C){return Object.keys(C)},ObjectSetPrototypeOf(C,H){return Object.setPrototypeOf(C,H)},Promise,PromisePrototypeCatch(C,H){return C.catch(H)},PromisePrototypeThen(C,H,z){return C.then(H,z)},PromiseReject(C){return Promise.reject(C)},PromiseResolve(C){return Promise.resolve(C)},ReflectApply:Reflect.apply,RegExpPrototypeTest(C,H){return C.test(H)},SafeSet:Set,String,StringPrototypeSlice(C,H,z){return C.slice(H,z)},StringPrototypeToLowerCase(C){return C.toLowerCase()},StringPrototypeToUpperCase(C){return C.toUpperCase()},StringPrototypeTrim(C){return C.trim()},Symbol,SymbolFor:Symbol.for,SymbolAsyncIterator:Symbol.asyncIterator,SymbolHasInstance:Symbol.hasInstance,SymbolIterator:Symbol.iterator,SymbolDispose:Symbol.dispose||Symbol("Symbol.dispose"),SymbolAsyncDispose:Symbol.asyncDispose||Symbol("Symbol.asyncDispose"),TypedArrayPrototypeSet(C,H,z){return C.set(H,z)},Boolean,Uint8Array}}),KZ=d0((E,G)=>{G.exports={format(W,...C){return W.replace(/%([sdifj])/g,function(...[H,z]){let V=C.shift();if(z==="f")return V.toFixed(6);else if(z==="j")return JSON.stringify(V);else if(z==="s"&&typeof V==="object")return`${V.constructor!==Object?V.constructor.name:""} {}`.trim();else return V.toString()})},inspect(W){switch(typeof W){case"string":if(W.includes("'")){if(!W.includes('"'))return`"${W}"`;else if(!W.includes("`")&&!W.includes("${"))return`\`${W}\``}return`'${W}'`;case"number":if(isNaN(W))return"NaN";else if(Object.is(W,-0))return String(W);return W;case"bigint":return`${String(W)}n`;case"boolean":case"undefined":return String(W);case"object":return"{}"}}}}),MU=d0((E,G)=>{var{format:W,inspect:C}=KZ(),{AggregateError:H}=s0(),z=globalThis.AggregateError||H,V=Symbol("kIsNodeError"),P=["string","function","number","object","Function","Object","boolean","bigint","symbol"],k=/^([A-Z][a-z0-9]*)+$/,R={};function S(x,g){if(!x)throw new R.ERR_INTERNAL_ASSERTION(g)}function D(x){let g="",N=x.length,y=x[0]==="-"?1:0;for(;N>=y+4;N-=3)g=`_${x.slice(N-3,N)}${g}`;return`${x.slice(0,N)}${g}`}function A(x,g,N){if(typeof g==="function")return S(g.length<=N.length,`Code: ${x}; The provided arguments length (${N.length}) does not match the required ones (${g.length}).`),g(...N);let y=(g.match(/%[dfijoOs]/g)||[]).length;if(S(y===N.length,`Code: ${x}; The provided arguments length (${N.length}) does not match the required ones (${y}).`),N.length===0)return g;return W(g,...N)}function L(x,g,N){if(!N)N=Error;class y extends N{constructor(...f){super(A(x,g,f))}toString(){return`${this.name} [${x}]: ${this.message}`}}Object.defineProperties(y.prototype,{name:{value:N.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${x}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),y.prototype.code=x,y.prototype[V]=!0,R[x]=y}function M(x){let g="__node_internal_"+x.name;return Object.defineProperty(x,"name",{value:g}),x}function q(x,g){if(x&&g&&x!==g){if(Array.isArray(g.errors))return g.errors.push(x),g;let N=new z([g,x],g.message);return N.code=g.code,N}return x||g}class j extends Error{constructor(x="The operation was aborted",g=void 0){if(g!==void 0&&typeof g!=="object")throw new R.ERR_INVALID_ARG_TYPE("options","Object",g);super(x,g);this.code="ABORT_ERR",this.name="AbortError"}}L("ERR_ASSERTION","%s",Error),L("ERR_INVALID_ARG_TYPE",(x,g,N)=>{if(S(typeof x==="string","'name' must be a string"),!Array.isArray(g))g=[g];let y="The ";if(x.endsWith(" argument"))y+=`${x} `;else y+=`"${x}" ${x.includes(".")?"property":"argument"} `;y+="must be ";let f=[],o=[],r=[];for(let Y0 of g)if(S(typeof Y0==="string","All expected entries have to be of type string"),P.includes(Y0))f.push(Y0.toLowerCase());else if(k.test(Y0))o.push(Y0);else S(Y0!=="object",'The value "object" should be written as "Object"'),r.push(Y0);if(o.length>0){let Y0=f.indexOf("object");if(Y0!==-1)f.splice(f,Y0,1),o.push("Object")}if(f.length>0){switch(f.length){case 1:y+=`of type ${f[0]}`;break;case 2:y+=`one of type ${f[0]} or ${f[1]}`;break;default:{let Y0=f.pop();y+=`one of type ${f.join(", ")}, or ${Y0}`}}if(o.length>0||r.length>0)y+=" or "}if(o.length>0){switch(o.length){case 1:y+=`an instance of ${o[0]}`;break;case 2:y+=`an instance of ${o[0]} or ${o[1]}`;break;default:{let Y0=o.pop();y+=`an instance of ${o.join(", ")}, or ${Y0}`}}if(r.length>0)y+=" or "}switch(r.length){case 0:break;case 1:if(r[0].toLowerCase()!==r[0])y+="an ";y+=`${r[0]}`;break;case 2:y+=`one of ${r[0]} or ${r[1]}`;break;default:{let Y0=r.pop();y+=`one of ${r.join(", ")}, or ${Y0}`}}if(N==null)y+=`. Received ${N}`;else if(typeof N==="function"&&N.name)y+=`. Received function ${N.name}`;else if(typeof N==="object"){var V0;if((V0=N.constructor)!==null&&V0!==void 0&&V0.name)y+=`. Received an instance of ${N.constructor.name}`;else{let Y0=C(N,{depth:-1});y+=`. Received ${Y0}`}}else{let Y0=C(N,{colors:!1});if(Y0.length>25)Y0=`${Y0.slice(0,25)}...`;y+=`. Received type ${typeof N} (${Y0})`}return y},TypeError),L("ERR_INVALID_ARG_VALUE",(x,g,N="is invalid")=>{let y=C(g);if(y.length>128)y=y.slice(0,128)+"...";return`The ${x.includes(".")?"property":"argument"} '${x}' ${N}. Received ${y}`},TypeError),L("ERR_INVALID_RETURN_VALUE",(x,g,N)=>{var y;let f=N!==null&&N!==void 0&&(y=N.constructor)!==null&&y!==void 0&&y.name?`instance of ${N.constructor.name}`:`type ${typeof N}`;return`Expected ${x} to be returned from the "${g}" function but got ${f}.`},TypeError),L("ERR_MISSING_ARGS",(...x)=>{S(x.length>0,"At least one arg needs to be specified");let g,N=x.length;switch(x=(Array.isArray(x)?x:[x]).map((y)=>`"${y}"`).join(" or "),N){case 1:g+=`The ${x[0]} argument`;break;case 2:g+=`The ${x[0]} and ${x[1]} arguments`;break;default:{let y=x.pop();g+=`The ${x.join(", ")}, and ${y} arguments`}break}return`${g} must be specified`},TypeError),L("ERR_OUT_OF_RANGE",(x,g,N)=>{S(g,'Missing "range" argument');let y;if(Number.isInteger(N)&&Math.abs(N)>4294967296)y=D(String(N));else if(typeof N==="bigint"){y=String(N);let f=BigInt(2)**BigInt(32);if(N>f||N<-f)y=D(y);y+="n"}else y=C(N);return`The value of "${x}" is out of range. It must be ${g}. Received ${y}`},RangeError),L("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),L("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),L("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),L("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),L("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),L("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),L("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),L("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),L("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),L("ERR_STREAM_WRITE_AFTER_END","write after end",Error),L("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),G.exports={AbortError:j,aggregateTwoErrors:M(q),hideStackFrames:M,codes:R}}),N$=d0((E,G)=>{Object.defineProperty(E,"__esModule",{value:!0});var W=new WeakMap,C=new WeakMap;function H(u){let a=W.get(u);return console.assert(a!=null,"'this' is expected an Event object, but got",u),a}function z(u){if(u.passiveListener!=null){if(typeof console!=="undefined"&&typeof console.error==="function")console.error("Unable to preventDefault inside passive event listener invocation.",u.passiveListener);return}if(!u.event.cancelable)return;if(u.canceled=!0,typeof u.event.preventDefault==="function")u.event.preventDefault()}function V(u,a){W.set(this,{eventTarget:u,event:a,eventPhase:2,currentTarget:u,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:a.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let F=Object.keys(a);for(let U=0;U<F.length;++U){let Z=F[U];if(!(Z in this))Object.defineProperty(this,Z,P(Z))}}if(V.prototype={get type(){return H(this).event.type},get target(){return H(this).eventTarget},get currentTarget(){return H(this).currentTarget},composedPath(){let u=H(this).currentTarget;if(u==null)return[];return[u]},get NONE(){return 0},get CAPTURING_PHASE(){return 1},get AT_TARGET(){return 2},get BUBBLING_PHASE(){return 3},get eventPhase(){return H(this).eventPhase},stopPropagation(){let u=H(this);if(u.stopped=!0,typeof u.event.stopPropagation==="function")u.event.stopPropagation()},stopImmediatePropagation(){let u=H(this);if(u.stopped=!0,u.immediateStopped=!0,typeof u.event.stopImmediatePropagation==="function")u.event.stopImmediatePropagation()},get bubbles(){return Boolean(H(this).event.bubbles)},get cancelable(){return Boolean(H(this).event.cancelable)},preventDefault(){z(H(this))},get defaultPrevented(){return H(this).canceled},get composed(){return Boolean(H(this).event.composed)},get timeStamp(){return H(this).timeStamp},get srcElement(){return H(this).eventTarget},get cancelBubble(){return H(this).stopped},set cancelBubble(u){if(!u)return;let a=H(this);if(a.stopped=!0,typeof a.event.cancelBubble==="boolean")a.event.cancelBubble=!0},get returnValue(){return!H(this).canceled},set returnValue(u){if(!u)z(H(this))},initEvent(){}},Object.defineProperty(V.prototype,"constructor",{value:V,configurable:!0,writable:!0}),typeof window!=="undefined"&&typeof window.Event!=="undefined")Object.setPrototypeOf(V.prototype,window.Event.prototype),C.set(window.Event.prototype,V);function P(u){return{get(){return H(this).event[u]},set(a){H(this).event[u]=a},configurable:!0,enumerable:!0}}function k(u){return{value(){let a=H(this).event;return a[u].apply(a,arguments)},configurable:!0,enumerable:!0}}function R(u,a){let F=Object.keys(a);if(F.length===0)return u;function U(Z,Q){u.call(this,Z,Q)}U.prototype=Object.create(u.prototype,{constructor:{value:U,configurable:!0,writable:!0}});for(let Z=0;Z<F.length;++Z){let Q=F[Z];if(!(Q in u.prototype)){let I=typeof Object.getOwnPropertyDescriptor(a,Q).value==="function";Object.defineProperty(U.prototype,Q,I?k(Q):P(Q))}}return U}function S(u){if(u==null||u===Object.prototype)return V;let a=C.get(u);if(a==null)a=R(S(Object.getPrototypeOf(u)),u),C.set(u,a);return a}function D(u,a){return new(S(Object.getPrototypeOf(a)))(u,a)}function A(u){return H(u).immediateStopped}function L(u,a){H(u).eventPhase=a}function M(u,a){H(u).currentTarget=a}function q(u,a){H(u).passiveListener=a}var j=new WeakMap,x=1,g=2,N=3;function y(u){return u!==null&&typeof u==="object"}function f(u){let a=j.get(u);if(a==null)throw new TypeError("'this' is expected an EventTarget object, but got another value.");return a}function o(u){return{get(){let a=f(this).get(u);while(a!=null){if(a.listenerType===N)return a.listener;a=a.next}return null},set(a){if(typeof a!=="function"&&!y(a))a=null;let F=f(this),U=null,Z=F.get(u);while(Z!=null){if(Z.listenerType===N)if(U!==null)U.next=Z.next;else if(Z.next!==null)F.set(u,Z.next);else F.delete(u);else U=Z;Z=Z.next}if(a!==null){let Q={listener:a,listenerType:N,passive:!1,once:!1,next:null};if(U===null)F.set(u,Q);else U.next=Q}},configurable:!0,enumerable:!0}}function r(u,a){Object.defineProperty(u,`on${a}`,o(a))}function V0(u){function a(){Y0.call(this)}a.prototype=Object.create(Y0.prototype,{constructor:{value:a,configurable:!0,writable:!0}});for(let F=0;F<u.length;++F)r(a.prototype,u[F]);return a}function Y0(){if(this instanceof Y0){j.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return V0(arguments[0]);if(arguments.length>0){let u=new Array(arguments.length);for(let a=0;a<arguments.length;++a)u[a]=arguments[a];return V0(u)}throw new TypeError("Cannot call a class as a function")}if(Y0.prototype={addEventListener(u,a,F){if(a==null)return;if(typeof a!=="function"&&!y(a))throw new TypeError("'listener' should be a function or an object.");let U=f(this),Z=y(F),Q=(Z?Boolean(F.capture):Boolean(F))?x:g,I={listener:a,listenerType:Q,passive:Z&&Boolean(F.passive),once:Z&&Boolean(F.once),next:null},$=U.get(u);if($===void 0){U.set(u,I);return}let K=null;while($!=null){if($.listener===a&&$.listenerType===Q)return;K=$,$=$.next}K.next=I},removeEventListener(u,a,F){if(a==null)return;let U=f(this),Z=(y(F)?Boolean(F.capture):Boolean(F))?x:g,Q=null,I=U.get(u);while(I!=null){if(I.listener===a&&I.listenerType===Z){if(Q!==null)Q.next=I.next;else if(I.next!==null)U.set(u,I.next);else U.delete(u);return}Q=I,I=I.next}},dispatchEvent(u){if(u==null||typeof u.type!=="string")throw new TypeError('"event.type" should be a string.');let a=f(this),F=u.type,U=a.get(F);if(U==null)return!0;let Z=D(this,u),Q=null;while(U!=null){if(U.once)if(Q!==null)Q.next=U.next;else if(U.next!==null)a.set(F,U.next);else a.delete(F);else Q=U;if(q(Z,U.passive?U.listener:null),typeof U.listener==="function")try{U.listener.call(this,Z)}catch(I){if(typeof console!=="undefined"&&typeof console.error==="function")console.error(I)}else if(U.listenerType!==N&&typeof U.listener.handleEvent==="function")U.listener.handleEvent(Z);if(A(Z))break;U=U.next}return q(Z,null),L(Z,0),M(Z,null),!Z.defaultPrevented}},Object.defineProperty(Y0.prototype,"constructor",{value:Y0,configurable:!0,writable:!0}),typeof window!=="undefined"&&typeof window.EventTarget!=="undefined")Object.setPrototypeOf(Y0.prototype,window.EventTarget.prototype);E.defineEventAttribute=r,E.EventTarget=Y0,E.default=Y0,G.exports=Y0,G.exports.EventTarget=G.exports.default=Y0,G.exports.defineEventAttribute=r}),HX=d0((E,G)=>{Object.defineProperty(E,"__esModule",{value:!0});var W=N$();class C extends W.EventTarget{constructor(){super();throw new TypeError("AbortSignal cannot be constructed directly")}get aborted(){let S=V.get(this);if(typeof S!=="boolean")throw new TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return S}}W.defineEventAttribute(C.prototype,"abort");function H(){let S=Object.create(C.prototype);return W.EventTarget.call(S),V.set(S,!1),S}function z(S){if(V.get(S)!==!1)return;V.set(S,!0),S.dispatchEvent({type:"abort"})}var V=new WeakMap;if(Object.defineProperties(C.prototype,{aborted:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(C.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});class P{constructor(){k.set(this,H())}get signal(){return R(this)}abort(){z(R(this))}}var k=new WeakMap;function R(S){let D=k.get(S);if(D==null)throw new TypeError(`Expected 'this' to be an 'AbortController' object, but got ${S===null?"null":typeof S}`);return D}if(Object.defineProperties(P.prototype,{signal:{enumerable:!0},abort:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(P.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortController"});E.AbortController=P,E.AbortSignal=C,E.default=P,G.exports=P,G.exports.AbortController=G.exports.default=P,G.exports.AbortSignal=C}),SU=d0((E,G)=>{var W=(HU(),y0(FU)),{format:C,inspect:H}=KZ(),{codes:{ERR_INVALID_ARG_TYPE:z}}=MU(),{kResistStopPropagation:V,AggregateError:P,SymbolDispose:k}=s0(),R=globalThis.AbortSignal||HX().AbortSignal,S=globalThis.AbortController||HX().AbortController,D=Object.getPrototypeOf(async function(){}).constructor,A=globalThis.Blob||W.Blob,L=typeof A!=="undefined"?function j(x){return x instanceof A}:function j(x){return!1},M=(j,x)=>{if(j!==void 0&&(j===null||typeof j!=="object"||!("aborted"in j)))throw new z(x,"AbortSignal",j)},q=(j,x)=>{if(typeof j!=="function")throw new z(x,"Function",j)};G.exports={AggregateError:P,kEmptyObject:Object.freeze({}),once(j){let x=!1;return function(...g){if(x)return;x=!0,j.apply(this,g)}},createDeferredPromise:function(){let j,x;return{promise:new Promise((g,N)=>{j=g,x=N}),resolve:j,reject:x}},promisify(j){return new Promise((x,g)=>{j((N,...y)=>{if(N)return g(N);return x(...y)})})},debuglog(){return function(){}},format:C,inspect:H,types:{isAsyncFunction(j){return j instanceof D},isArrayBufferView(j){return ArrayBuffer.isView(j)}},isBlob:L,deprecate(j,x){return j},addAbortListener:(FX(),y0(JX)).addAbortListener||function j(x,g){if(x===void 0)throw new z("signal","AbortSignal",x);M(x,"signal"),q(g,"listener");let N;if(x.aborted)queueMicrotask(()=>g());else x.addEventListener("abort",g,{__proto__:null,once:!0,[V]:!0}),N=()=>{x.removeEventListener("abort",g)};return{__proto__:null,[k](){var y;(y=N)===null||y===void 0||y()}}},AbortSignalAny:R.any||function j(x){if(x.length===1)return x[0];let g=new S,N=()=>g.abort();return x.forEach((y)=>{M(y,"signals"),y.addEventListener("abort",N,{once:!0})}),g.signal.addEventListener("abort",()=>{x.forEach((y)=>y.removeEventListener("abort",N))},{once:!0}),g.signal}},G.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),AX=d0((E,G)=>{var{ArrayIsArray:W,ArrayPrototypeIncludes:C,ArrayPrototypeJoin:H,ArrayPrototypeMap:z,NumberIsInteger:V,NumberIsNaN:P,NumberMAX_SAFE_INTEGER:k,NumberMIN_SAFE_INTEGER:R,NumberParseInt:S,ObjectPrototypeHasOwnProperty:D,RegExpPrototypeExec:A,String:L,StringPrototypeToUpperCase:M,StringPrototypeTrim:q}=s0(),{hideStackFrames:j,codes:{ERR_SOCKET_BAD_PORT:x,ERR_INVALID_ARG_TYPE:g,ERR_INVALID_ARG_VALUE:N,ERR_OUT_OF_RANGE:y,ERR_UNKNOWN_SIGNAL:f}}=MU(),{normalizeEncoding:o}=SU(),{isAsyncFunction:r,isArrayBufferView:V0}=SU().types,Y0={};function u(t){return t===(t|0)}function a(t){return t===t>>>0}var F=/^[0-7]+$/,U="must be a 32-bit unsigned integer or an octal string";function Z(t,n,X0){if(typeof t==="undefined")t=X0;if(typeof t==="string"){if(A(F,t)===null)throw new N(n,t,U);t=S(t,8)}return $(t,n),t}var Q=j((t,n,X0=R,H0=k)=>{if(typeof t!=="number")throw new g(n,"number",t);if(!V(t))throw new y(n,"an integer",t);if(t<X0||t>H0)throw new y(n,`>= ${X0} && <= ${H0}`,t)}),I=j((t,n,X0=-2147483648,H0=2147483647)=>{if(typeof t!=="number")throw new g(n,"number",t);if(!V(t))throw new y(n,"an integer",t);if(t<X0||t>H0)throw new y(n,`>= ${X0} && <= ${H0}`,t)}),$=j((t,n,X0=!1)=>{if(typeof t!=="number")throw new g(n,"number",t);if(!V(t))throw new y(n,"an integer",t);let H0=X0?1:0,Z0=4294967295;if(t<H0||t>Z0)throw new y(n,`>= ${H0} && <= ${Z0}`,t)});function K(t,n){if(typeof t!=="string")throw new g(n,"string",t)}function J(t,n,X0=void 0,H0){if(typeof t!=="number")throw new g(n,"number",t);if(X0!=null&&t<X0||H0!=null&&t>H0||(X0!=null||H0!=null)&&P(t))throw new y(n,`${X0!=null?`>= ${X0}`:""}${X0!=null&&H0!=null?" && ":""}${H0!=null?`<= ${H0}`:""}`,t)}var Y=j((t,n,X0)=>{if(!C(X0,t)){let H0="must be one of: "+H(z(X0,(Z0)=>typeof Z0==="string"?`'${Z0}'`:L(Z0)),", ");throw new N(n,t,H0)}});function X(t,n){if(typeof t!=="boolean")throw new g(n,"boolean",t)}function O(t,n,X0){return t==null||!D(t,n)?X0:t[n]}var v=j((t,n,X0=null)=>{let H0=O(X0,"allowArray",!1),Z0=O(X0,"allowFunction",!1);if(!O(X0,"nullable",!1)&&t===null||!H0&&W(t)||typeof t!=="object"&&(!Z0||typeof t!=="function"))throw new g(n,"Object",t)}),T=j((t,n)=>{if(t!=null&&typeof t!=="object"&&typeof t!=="function")throw new g(n,"a dictionary",t)}),B=j((t,n,X0=0)=>{if(!W(t))throw new g(n,"Array",t);if(t.length<X0){let H0=`must be longer than ${X0}`;throw new N(n,t,H0)}});function c(t,n){B(t,n);for(let X0=0;X0<t.length;X0++)K(t[X0],`${n}[${X0}]`)}function l(t,n){B(t,n);for(let X0=0;X0<t.length;X0++)X(t[X0],`${n}[${X0}]`)}function s(t,n){B(t,n);for(let X0=0;X0<t.length;X0++){let H0=t[X0],Z0=`${n}[${X0}]`;if(H0==null)throw new g(Z0,"AbortSignal",H0);Q0(H0,Z0)}}function O0(t,n="signal"){if(K(t,n),Y0[t]===void 0){if(Y0[M(t)]!==void 0)throw new f(t+" (signals must use all capital letters)");throw new f(t)}}var h=j((t,n="buffer")=>{if(!V0(t))throw new g(n,["Buffer","TypedArray","DataView"],t)});function d(t,n){let X0=o(n),H0=t.length;if(X0==="hex"&&H0%2!==0)throw new N("encoding",n,`is invalid for data of length ${H0}`)}function g0(t,n="Port",X0=!0){if(typeof t!=="number"&&typeof t!=="string"||typeof t==="string"&&q(t).length===0||+t!==+t>>>0||t>65535||t===0&&!X0)throw new x(n,t,X0);return t|0}var Q0=j((t,n)=>{if(t!==void 0&&(t===null||typeof t!=="object"||!("aborted"in t)))throw new g(n,"AbortSignal",t)}),$0=j((t,n)=>{if(typeof t!=="function")throw new g(n,"Function",t)}),m=j((t,n)=>{if(typeof t!=="function"||r(t))throw new g(n,"Function",t)}),p=j((t,n)=>{if(t!==void 0)throw new g(n,"undefined",t)});function b(t,n,X0){if(!C(X0,t))throw new g(n,`('${H(X0,"|")}')`,t)}var N0=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function i(t,n){if(typeof t==="undefined"||!A(N0,t))throw new N(n,t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function e(t){if(typeof t==="string")return i(t,"hints"),t;else if(W(t)){let n=t.length,X0="";if(n===0)return X0;for(let H0=0;H0<n;H0++){let Z0=t[H0];if(i(Z0,"hints"),X0+=Z0,H0!==n-1)X0+=", "}return X0}throw new N("hints",t,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}G.exports={isInt32:u,isUint32:a,parseFileMode:Z,validateArray:B,validateStringArray:c,validateBooleanArray:l,validateAbortSignalArray:s,validateBoolean:X,validateBuffer:h,validateDictionary:T,validateEncoding:d,validateFunction:$0,validateInt32:I,validateInteger:Q,validateNumber:J,validateObject:v,validateOneOf:Y,validatePlainFunction:m,validatePort:g0,validateSignalName:O0,validateString:K,validateUint32:$,validateUndefined:p,validateUnion:b,validateAbortSignal:Q0,validateLinkHeaderValue:e}}),UX=d0((E,G)=>{G.exports=(gU(),y0(xU))}),uU=d0((E,G)=>{var{SymbolAsyncIterator:W,SymbolIterator:C,SymbolFor:H}=s0(),z=H("nodejs.stream.destroyed"),V=H("nodejs.stream.errored"),P=H("nodejs.stream.readable"),k=H("nodejs.stream.writable"),R=H("nodejs.stream.disturbed"),S=H("nodejs.webstream.isClosedPromise"),D=H("nodejs.webstream.controllerErrorFunction");function A(O,v=!1){var T;return!!(O&&typeof O.pipe==="function"&&typeof O.on==="function"&&(!v||typeof O.pause==="function"&&typeof O.resume==="function")&&(!O._writableState||((T=O._readableState)===null||T===void 0?void 0:T.readable)!==!1)&&(!O._writableState||O._readableState))}function L(O){var v;return!!(O&&typeof O.write==="function"&&typeof O.on==="function"&&(!O._readableState||((v=O._writableState)===null||v===void 0?void 0:v.writable)!==!1))}function M(O){return!!(O&&typeof O.pipe==="function"&&O._readableState&&typeof O.on==="function"&&typeof O.write==="function")}function q(O){return O&&(O._readableState||O._writableState||typeof O.write==="function"&&typeof O.on==="function"||typeof O.pipe==="function"&&typeof O.on==="function")}function j(O){return!!(O&&!q(O)&&typeof O.pipeThrough==="function"&&typeof O.getReader==="function"&&typeof O.cancel==="function")}function x(O){return!!(O&&!q(O)&&typeof O.getWriter==="function"&&typeof O.abort==="function")}function g(O){return!!(O&&!q(O)&&typeof O.readable==="object"&&typeof O.writable==="object")}function N(O){return j(O)||x(O)||g(O)}function y(O,v){if(O==null)return!1;if(v===!0)return typeof O[W]==="function";if(v===!1)return typeof O[C]==="function";return typeof O[W]==="function"||typeof O[C]==="function"}function f(O){if(!q(O))return null;let{_writableState:v,_readableState:T}=O,B=v||T;return!!(O.destroyed||O[z]||B!==null&&B!==void 0&&B.destroyed)}function o(O){if(!L(O))return null;if(O.writableEnded===!0)return!0;let v=O._writableState;if(v!==null&&v!==void 0&&v.errored)return!1;if(typeof(v===null||v===void 0?void 0:v.ended)!=="boolean")return null;return v.ended}function r(O,v){if(!L(O))return null;if(O.writableFinished===!0)return!0;let T=O._writableState;if(T!==null&&T!==void 0&&T.errored)return!1;if(typeof(T===null||T===void 0?void 0:T.finished)!=="boolean")return null;return!!(T.finished||v===!1&&T.ended===!0&&T.length===0)}function V0(O){if(!A(O))return null;if(O.readableEnded===!0)return!0;let v=O._readableState;if(!v||v.errored)return!1;if(typeof(v===null||v===void 0?void 0:v.ended)!=="boolean")return null;return v.ended}function Y0(O,v){if(!A(O))return null;let T=O._readableState;if(T!==null&&T!==void 0&&T.errored)return!1;if(typeof(T===null||T===void 0?void 0:T.endEmitted)!=="boolean")return null;return!!(T.endEmitted||v===!1&&T.ended===!0&&T.length===0)}function u(O){if(O&&O[P]!=null)return O[P];if(typeof(O===null||O===void 0?void 0:O.readable)!=="boolean")return null;if(f(O))return!1;return A(O)&&O.readable&&!Y0(O)}function a(O){if(O&&O[k]!=null)return O[k];if(typeof(O===null||O===void 0?void 0:O.writable)!=="boolean")return null;if(f(O))return!1;return L(O)&&O.writable&&!o(O)}function F(O,v){if(!q(O))return null;if(f(O))return!0;if((v===null||v===void 0?void 0:v.readable)!==!1&&u(O))return!1;if((v===null||v===void 0?void 0:v.writable)!==!1&&a(O))return!1;return!0}function U(O){var v,T;if(!q(O))return null;if(O.writableErrored)return O.writableErrored;return(v=(T=O._writableState)===null||T===void 0?void 0:T.errored)!==null&&v!==void 0?v:null}function Z(O){var v,T;if(!q(O))return null;if(O.readableErrored)return O.readableErrored;return(v=(T=O._readableState)===null||T===void 0?void 0:T.errored)!==null&&v!==void 0?v:null}function Q(O){if(!q(O))return null;if(typeof O.closed==="boolean")return O.closed;let{_writableState:v,_readableState:T}=O;if(typeof(v===null||v===void 0?void 0:v.closed)==="boolean"||typeof(T===null||T===void 0?void 0:T.closed)==="boolean")return(v===null||v===void 0?void 0:v.closed)||(T===null||T===void 0?void 0:T.closed);if(typeof O._closed==="boolean"&&I(O))return O._closed;return null}function I(O){return typeof O._closed==="boolean"&&typeof O._defaultKeepAlive==="boolean"&&typeof O._removedConnection==="boolean"&&typeof O._removedContLen==="boolean"}function $(O){return typeof O._sent100==="boolean"&&I(O)}function K(O){var v;return typeof O._consuming==="boolean"&&typeof O._dumped==="boolean"&&((v=O.req)===null||v===void 0?void 0:v.upgradeOrConnect)===void 0}function J(O){if(!q(O))return null;let{_writableState:v,_readableState:T}=O,B=v||T;return!B&&$(O)||!!(B&&B.autoDestroy&&B.emitClose&&B.closed===!1)}function Y(O){var v;return!!(O&&((v=O[R])!==null&&v!==void 0?v:O.readableDidRead||O.readableAborted))}function X(O){var v,T,B,c,l,s,O0,h,d,g0;return!!(O&&((v=(T=(B=(c=(l=(s=O[V])!==null&&s!==void 0?s:O.readableErrored)!==null&&l!==void 0?l:O.writableErrored)!==null&&c!==void 0?c:(O0=O._readableState)===null||O0===void 0?void 0:O0.errorEmitted)!==null&&B!==void 0?B:(h=O._writableState)===null||h===void 0?void 0:h.errorEmitted)!==null&&T!==void 0?T:(d=O._readableState)===null||d===void 0?void 0:d.errored)!==null&&v!==void 0?v:(g0=O._writableState)===null||g0===void 0?void 0:g0.errored))}G.exports={isDestroyed:f,kIsDestroyed:z,isDisturbed:Y,kIsDisturbed:R,isErrored:X,kIsErrored:V,isReadable:u,kIsReadable:P,kIsClosedPromise:S,kControllerErrorFunction:D,kIsWritable:k,isClosed:Q,isDuplexNodeStream:M,isFinished:F,isIterable:y,isReadableNodeStream:A,isReadableStream:j,isReadableEnded:V0,isReadableFinished:Y0,isReadableErrored:Z,isNodeStream:q,isWebStream:N,isWritable:a,isWritableNodeStream:L,isWritableStream:x,isWritableEnded:o,isWritableFinished:r,isWritableErrored:U,isServerRequest:K,isServerResponse:$,willEmitClose:J,isTransformStream:g}}),nU=d0((E,G)=>{var W=UX(),{AbortError:C,codes:H}=MU(),{ERR_INVALID_ARG_TYPE:z,ERR_STREAM_PREMATURE_CLOSE:V}=H,{kEmptyObject:P,once:k}=SU(),{validateAbortSignal:R,validateFunction:S,validateObject:D,validateBoolean:A}=AX(),{Promise:L,PromisePrototypeThen:M,SymbolDispose:q}=s0(),{isClosed:j,isReadable:x,isReadableNodeStream:g,isReadableStream:N,isReadableFinished:y,isReadableErrored:f,isWritable:o,isWritableNodeStream:r,isWritableStream:V0,isWritableFinished:Y0,isWritableErrored:u,isNodeStream:a,willEmitClose:F,kIsClosedPromise:U}=uU(),Z;function Q(Y){return Y.setHeader&&typeof Y.abort==="function"}var I=()=>{};function $(Y,X,O){var v,T;if(arguments.length===2)O=X,X=P;else if(X==null)X=P;else D(X,"options");if(S(O,"callback"),R(X.signal,"options.signal"),O=k(O),N(Y)||V0(Y))return K(Y,X,O);if(!a(Y))throw new z("stream",["ReadableStream","WritableStream","Stream"],Y);let B=(v=X.readable)!==null&&v!==void 0?v:g(Y),c=(T=X.writable)!==null&&T!==void 0?T:r(Y),l=Y._writableState,s=Y._readableState,O0=()=>{if(!Y.writable)g0()},h=F(Y)&&g(Y)===B&&r(Y)===c,d=Y0(Y,!1),g0=()=>{if(d=!0,Y.destroyed)h=!1;if(h&&(!Y.readable||B))return;if(!B||Q0)O.call(Y)},Q0=y(Y,!1),$0=()=>{if(Q0=!0,Y.destroyed)h=!1;if(h&&(!Y.writable||c))return;if(!c||d)O.call(Y)},m=(t)=>{O.call(Y,t)},p=j(Y),b=()=>{p=!0;let t=u(Y)||f(Y);if(t&&typeof t!=="boolean")return O.call(Y,t);if(B&&!Q0&&g(Y,!0)){if(!y(Y,!1))return O.call(Y,new V)}if(c&&!d){if(!Y0(Y,!1))return O.call(Y,new V)}O.call(Y)},N0=()=>{p=!0;let t=u(Y)||f(Y);if(t&&typeof t!=="boolean")return O.call(Y,t);O.call(Y)},i=()=>{Y.req.on("finish",g0)};if(Q(Y)){if(Y.on("complete",g0),!h)Y.on("abort",b);if(Y.req)i();else Y.on("request",i)}else if(c&&!l)Y.on("end",O0),Y.on("close",O0);if(!h&&typeof Y.aborted==="boolean")Y.on("aborted",b);if(Y.on("end",$0),Y.on("finish",g0),X.error!==!1)Y.on("error",m);if(Y.on("close",b),p)W.nextTick(b);else if(l!==null&&l!==void 0&&l.errorEmitted||s!==null&&s!==void 0&&s.errorEmitted){if(!h)W.nextTick(N0)}else if(!B&&(!h||x(Y))&&(d||o(Y)===!1))W.nextTick(N0);else if(!c&&(!h||o(Y))&&(Q0||x(Y)===!1))W.nextTick(N0);else if(s&&Y.req&&Y.aborted)W.nextTick(N0);let e=()=>{if(O=I,Y.removeListener("aborted",b),Y.removeListener("complete",g0),Y.removeListener("abort",b),Y.removeListener("request",i),Y.req)Y.req.removeListener("finish",g0);Y.removeListener("end",O0),Y.removeListener("close",O0),Y.removeListener("finish",g0),Y.removeListener("end",$0),Y.removeListener("error",m),Y.removeListener("close",b)};if(X.signal&&!p){let t=()=>{let n=O;e(),n.call(Y,new C(void 0,{cause:X.signal.reason}))};if(X.signal.aborted)W.nextTick(t);else{Z=Z||SU().addAbortListener;let n=Z(X.signal,t),X0=O;O=k((...H0)=>{n[q](),X0.apply(Y,H0)})}}return e}function K(Y,X,O){let v=!1,T=I;if(X.signal)if(T=()=>{v=!0,O.call(Y,new C(void 0,{cause:X.signal.reason}))},X.signal.aborted)W.nextTick(T);else{Z=Z||SU().addAbortListener;let c=Z(X.signal,T),l=O;O=k((...s)=>{c[q](),l.apply(Y,s)})}let B=(...c)=>{if(!v)W.nextTick(()=>O.apply(Y,c))};return M(Y[U].promise,B,B),I}function J(Y,X){var O;let v=!1;if(X===null)X=P;if((O=X)!==null&&O!==void 0&&O.cleanup)A(X.cleanup,"cleanup"),v=X.cleanup;return new L((T,B)=>{let c=$(Y,X,(l)=>{if(v)c();if(l)B(l);else T()})})}G.exports=$,G.exports.finished=J}),OX=d0((E,G)=>{var W=UX(),{aggregateTwoErrors:C,codes:{ERR_MULTIPLE_CALLBACK:H},AbortError:z}=MU(),{Symbol:V}=s0(),{kIsDestroyed:P,isDestroyed:k,isFinished:R,isServerRequest:S}=uU(),D=V("kDestroy"),A=V("kConstruct");function L(F,U,Z){if(F){if(F.stack,U&&!U.errored)U.errored=F;if(Z&&!Z.errored)Z.errored=F}}function M(F,U){let Z=this._readableState,Q=this._writableState,I=Q||Z;if(Q!==null&&Q!==void 0&&Q.destroyed||Z!==null&&Z!==void 0&&Z.destroyed){if(typeof U==="function")U();return this}if(L(F,Q,Z),Q)Q.destroyed=!0;if(Z)Z.destroyed=!0;if(!I.constructed)this.once(D,function($){q(this,C($,F),U)});else q(this,F,U);return this}function q(F,U,Z){let Q=!1;function I($){if(Q)return;Q=!0;let{_readableState:K,_writableState:J}=F;if(L($,J,K),J)J.closed=!0;if(K)K.closed=!0;if(typeof Z==="function")Z($);if($)W.nextTick(j,F,$);else W.nextTick(x,F)}try{F._destroy(U||null,I)}catch($){I($)}}function j(F,U){g(F,U),x(F)}function x(F){let{_readableState:U,_writableState:Z}=F;if(Z)Z.closeEmitted=!0;if(U)U.closeEmitted=!0;if(Z!==null&&Z!==void 0&&Z.emitClose||U!==null&&U!==void 0&&U.emitClose)F.emit("close")}function g(F,U){let{_readableState:Z,_writableState:Q}=F;if(Q!==null&&Q!==void 0&&Q.errorEmitted||Z!==null&&Z!==void 0&&Z.errorEmitted)return;if(Q)Q.errorEmitted=!0;if(Z)Z.errorEmitted=!0;F.emit("error",U)}function N(){let F=this._readableState,U=this._writableState;if(F)F.constructed=!0,F.closed=!1,F.closeEmitted=!1,F.destroyed=!1,F.errored=null,F.errorEmitted=!1,F.reading=!1,F.ended=F.readable===!1,F.endEmitted=F.readable===!1;if(U)U.constructed=!0,U.destroyed=!1,U.closed=!1,U.closeEmitted=!1,U.errored=null,U.errorEmitted=!1,U.finalCalled=!1,U.prefinished=!1,U.ended=U.writable===!1,U.ending=U.writable===!1,U.finished=U.writable===!1}function y(F,U,Z){let{_readableState:Q,_writableState:I}=F;if(I!==null&&I!==void 0&&I.destroyed||Q!==null&&Q!==void 0&&Q.destroyed)return this;if(Q!==null&&Q!==void 0&&Q.autoDestroy||I!==null&&I!==void 0&&I.autoDestroy)F.destroy(U);else if(U){if(U.stack,I&&!I.errored)I.errored=U;if(Q&&!Q.errored)Q.errored=U;if(Z)W.nextTick(g,F,U);else g(F,U)}}function f(F,U){if(typeof F._construct!=="function")return;let{_readableState:Z,_writableState:Q}=F;if(Z)Z.constructed=!1;if(Q)Q.constructed=!1;if(F.once(A,U),F.listenerCount(A)>1)return;W.nextTick(o,F)}function o(F){let U=!1;function Z(Q){if(U){y(F,Q!==null&&Q!==void 0?Q:new H);return}U=!0;let{_readableState:I,_writableState:$}=F,K=$||I;if(I)I.constructed=!0;if($)$.constructed=!0;if(K.destroyed)F.emit(D,Q);else if(Q)y(F,Q,!0);else W.nextTick(r,F)}try{F._construct((Q)=>{W.nextTick(Z,Q)})}catch(Q){W.nextTick(Z,Q)}}function r(F){F.emit(A)}function V0(F){return(F===null||F===void 0?void 0:F.setHeader)&&typeof F.abort==="function"}function Y0(F){F.emit("close")}function u(F,U){F.emit("error",U),W.nextTick(Y0,F)}function a(F,U){if(!F||k(F))return;if(!U&&!R(F))U=new z;if(S(F))F.socket=null,F.destroy(U);else if(V0(F))F.abort();else if(V0(F.req))F.req.abort();else if(typeof F.destroy==="function")F.destroy(U);else if(typeof F.close==="function")F.close();else if(U)W.nextTick(u,F,U);else W.nextTick(Y0,F);if(!F.destroyed)F[P]=!0}G.exports={construct:f,destroyer:a,destroy:M,undestroy:N,errorOrDestroy:y}}),QI=d0((E,G)=>{var{ArrayIsArray:W,ObjectSetPrototypeOf:C}=s0(),{EventEmitter:H}=(FX(),y0(JX));function z(P){H.call(this,P)}C(z.prototype,H.prototype),C(z,H),z.prototype.pipe=function(P,k){let R=this;function S(x){if(P.writable&&P.write(x)===!1&&R.pause)R.pause()}R.on("data",S);function D(){if(R.readable&&R.resume)R.resume()}if(P.on("drain",D),!P._isStdio&&(!k||k.end!==!1))R.on("end",L),R.on("close",M);let A=!1;function L(){if(A)return;A=!0,P.end()}function M(){if(A)return;if(A=!0,typeof P.destroy==="function")P.destroy()}function q(x){if(j(),H.listenerCount(this,"error")===0)this.emit("error",x)}V(R,"error",q),V(P,"error",q);function j(){R.removeListener("data",S),P.removeListener("drain",D),R.removeListener("end",L),R.removeListener("close",M),R.removeListener("error",q),P.removeListener("error",q),R.removeListener("end",j),R.removeListener("close",j),P.removeListener("close",j)}return R.on("end",j),R.on("close",j),P.on("close",j),P.emit("pipe",R),P};function V(P,k,R){if(typeof P.prependListener==="function")return P.prependListener(k,R);if(!P._events||!P._events[k])P.on(k,R);else if(W(P._events[k]))P._events[k].unshift(R);else P._events[k]=[R,P._events[k]]}G.exports={Stream:z,prependListener:V}}),jX=d0((E,G)=>{var{SymbolDispose:W}=s0(),{AbortError:C,codes:H}=MU(),{isNodeStream:z,isWebStream:V,kControllerErrorFunction:P}=uU(),k=nU(),{ERR_INVALID_ARG_TYPE:R}=H,S,D=(A,L)=>{if(typeof A!=="object"||!("aborted"in A))throw new R(L,"AbortSignal",A)};E.addAbortSignal=function A(L,M){if(D(L,"signal"),!z(M)&&!V(M))throw new R("stream",["ReadableStream","WritableStream","Stream"],M);return E.addAbortSignalNoValidate(L,M)},E.addAbortSignalNoValidate=function(A,L){if(typeof A!=="object"||!("aborted"in A))return L;let M=z(L)?()=>{L.destroy(new C(void 0,{cause:A.reason}))}:()=>{L[P](new C(void 0,{cause:A.reason}))};if(A.aborted)M();else{S=S||SU().addAbortListener;let q=S(A,M);k(L,q[W])}return L}}),_$=d0((E,G)=>{var{StringPrototypeSlice:W,SymbolIterator:C,TypedArrayPrototypeSet:H,Uint8Array:z}=s0(),{Buffer:V}=(HU(),y0(FU)),{inspect:P}=SU();G.exports=class k{constructor(){this.head=null,this.tail=null,this.length=0}push(R){let S={data:R,next:null};if(this.length>0)this.tail.next=S;else this.head=S;this.tail=S,++this.length}unshift(R){let S={data:R,next:this.head};if(this.length===0)this.tail=S;this.head=S,++this.length}shift(){if(this.length===0)return;let R=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;return--this.length,R}clear(){this.head=this.tail=null,this.length=0}join(R){if(this.length===0)return"";let S=this.head,D=""+S.data;while((S=S.next)!==null)D+=R+S.data;return D}concat(R){if(this.length===0)return V.alloc(0);let S=V.allocUnsafe(R>>>0),D=this.head,A=0;while(D)H(S,D.data,A),A+=D.data.length,D=D.next;return S}consume(R,S){let D=this.head.data;if(R<D.length){let A=D.slice(0,R);return this.head.data=D.slice(R),A}if(R===D.length)return this.shift();return S?this._getString(R):this._getBuffer(R)}first(){return this.head.data}*[C](){for(let R=this.head;R;R=R.next)yield R.data}_getString(R){let S="",D=this.head,A=0;do{let L=D.data;if(R>L.length)S+=L,R-=L.length;else{if(R===L.length)if(S+=L,++A,D.next)this.head=D.next;else this.head=this.tail=null;else S+=W(L,0,R),this.head=D,D.data=W(L,R);break}++A}while((D=D.next)!==null);return this.length-=A,S}_getBuffer(R){let S=V.allocUnsafe(R),D=R,A=this.head,L=0;do{let M=A.data;if(R>M.length)H(S,M,D-R),R-=M.length;else{if(R===M.length)if(H(S,M,D-R),++L,A.next)this.head=A.next;else this.head=this.tail=null;else H(S,new z(M.buffer,M.byteOffset,R),D-R),this.head=A,A.data=M.slice(R);break}++L}while((A=A.next)!==null);return this.length-=L,S}[Symbol.for("nodejs.util.inspect.custom")](R,S){return P(this,{...S,depth:0,customInspect:!1})}}}),BX=d0((E,G)=>{var{MathFloor:W,NumberIsInteger:C}=s0(),{validateInteger:H}=AX(),{ERR_INVALID_ARG_VALUE:z}=MU().codes,V=16384,P=16;function k(A,L,M){return A.highWaterMark!=null?A.highWaterMark:L?A[M]:null}function R(A){return A?P:V}function S(A,L){if(H(L,"value",0),A)P=L;else V=L}function D(A,L,M,q){let j=k(L,q,M);if(j!=null){if(!C(j)||j<0){let x=q?`options.${M}`:"options.highWaterMark";throw new z(x,j)}return W(j)}return R(A.objectMode)}G.exports={getHighWaterMark:D,getDefaultHighWaterMark:R,setDefaultHighWaterMark:S}}),w$=d0((E,G)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var W=(HU(),y0(FU)),C=W.Buffer;function H(V,P){for(var k in V)P[k]=V[k]}if(C.from&&C.alloc&&C.allocUnsafe&&C.allocUnsafeSlow)G.exports=W;else H(W,E),E.Buffer=z;function z(V,P,k){return C(V,P,k)}z.prototype=Object.create(C.prototype),H(C,z),z.from=function(V,P,k){if(typeof V==="number")throw new TypeError("Argument must not be a number");return C(V,P,k)},z.alloc=function(V,P,k){if(typeof V!=="number")throw new TypeError("Argument must be a number");var R=C(V);if(P!==void 0)if(typeof k==="string")R.fill(P,k);else R.fill(P);else R.fill(0);return R},z.allocUnsafe=function(V){if(typeof V!=="number")throw new TypeError("Argument must be a number");return C(V)},z.allocUnsafeSlow=function(V){if(typeof V!=="number")throw new TypeError("Argument must be a number");return W.SlowBuffer(V)}}),y$=d0((E)=>{var G=w$().Buffer,W=G.isEncoding||function(g){switch(g=""+g,g&&g.toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":case"raw":return!0;default:return!1}};function C(g){if(!g)return"utf8";var N;while(!0)switch(g){case"utf8":case"utf-8":return"utf8";case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return"utf16le";case"latin1":case"binary":return"latin1";case"base64":case"ascii":case"hex":return g;default:if(N)return;g=(""+g).toLowerCase(),N=!0}}function H(g){var N=C(g);if(typeof N!=="string"&&(G.isEncoding===W||!W(g)))throw new Error("Unknown encoding: "+g);return N||g}E.StringDecoder=z;function z(g){this.encoding=H(g);var N;switch(this.encoding){case"utf16le":this.text=A,this.end=L,N=4;break;case"utf8":this.fillLast=R,N=4;break;case"base64":this.text=M,this.end=q,N=3;break;default:this.write=j,this.end=x;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=G.allocUnsafe(N)}z.prototype.write=function(g){if(g.length===0)return"";var N,y;if(this.lastNeed){if(N=this.fillLast(g),N===void 0)return"";y=this.lastNeed,this.lastNeed=0}else y=0;if(y<g.length)return N?N+this.text(g,y):this.text(g,y);return N||""},z.prototype.end=D,z.prototype.text=S,z.prototype.fillLast=function(g){if(this.lastNeed<=g.length)return g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,this.lastTotal-this.lastNeed,0,g.length),this.lastNeed-=g.length};function V(g){if(g<=127)return 0;else if(g>>5===6)return 2;else if(g>>4===14)return 3;else if(g>>3===30)return 4;return g>>6===2?-1:-2}function P(g,N,y){var f=N.length-1;if(f<y)return 0;var o=V(N[f]);if(o>=0){if(o>0)g.lastNeed=o-1;return o}if(--f<y||o===-2)return 0;if(o=V(N[f]),o>=0){if(o>0)g.lastNeed=o-2;return o}if(--f<y||o===-2)return 0;if(o=V(N[f]),o>=0){if(o>0)if(o===2)o=0;else g.lastNeed=o-3;return o}return 0}function k(g,N,y){if((N[0]&192)!==128)return g.lastNeed=0,"�";if(g.lastNeed>1&&N.length>1){if((N[1]&192)!==128)return g.lastNeed=1,"�";if(g.lastNeed>2&&N.length>2){if((N[2]&192)!==128)return g.lastNeed=2,"�"}}}function R(g){var N=this.lastTotal-this.lastNeed,y=k(this,g,N);if(y!==void 0)return y;if(this.lastNeed<=g.length)return g.copy(this.lastChar,N,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);g.copy(this.lastChar,N,0,g.length),this.lastNeed-=g.length}function S(g,N){var y=P(this,g,N);if(!this.lastNeed)return g.toString("utf8",N);this.lastTotal=y;var f=g.length-(y-this.lastNeed);return g.copy(this.lastChar,0,f),g.toString("utf8",N,f)}function D(g){var N=g&&g.length?this.write(g):"";if(this.lastNeed)return N+"�";return N}function A(g,N){if((g.length-N)%2===0){var y=g.toString("utf16le",N);if(y){var f=y.charCodeAt(y.length-1);if(f>=55296&&f<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1],y.slice(0,-1)}return y}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=g[g.length-1],g.toString("utf16le",N,g.length-1)}function L(g){var N=g&&g.length?this.write(g):"";if(this.lastNeed){var y=this.lastTotal-this.lastNeed;return N+this.lastChar.toString("utf16le",0,y)}return N}function M(g,N){var y=(g.length-N)%3;if(y===0)return g.toString("base64",N);if(this.lastNeed=3-y,this.lastTotal=3,y===1)this.lastChar[0]=g[g.length-1];else this.lastChar[0]=g[g.length-2],this.lastChar[1]=g[g.length-1];return g.toString("base64",N,g.length-y)}function q(g){var N=g&&g.length?this.write(g):"";if(this.lastNeed)return N+this.lastChar.toString("base64",0,3-this.lastNeed);return N}function j(g){return g.toString(this.encoding)}function x(g){return g&&g.length?this.write(g):""}}),WZ=d0((E,G)=>{var W=UX(),{PromisePrototypeThen:C,SymbolAsyncIterator:H,SymbolIterator:z}=s0(),{Buffer:V}=(HU(),y0(FU)),{ERR_INVALID_ARG_TYPE:P,ERR_STREAM_NULL_VALUES:k}=MU().codes;function R(S,D,A){let L;if(typeof D==="string"||D instanceof V)return new S({objectMode:!0,...A,read(){this.push(D),this.push(null)}});let M;if(D&&D[H])M=!0,L=D[H]();else if(D&&D[z])M=!1,L=D[z]();else throw new P("iterable",["Iterable"],D);let q=new S({objectMode:!0,highWaterMark:1,...A}),j=!1;q._read=function(){if(!j)j=!0,g()},q._destroy=function(N,y){C(x(N),()=>W.nextTick(y,N),(f)=>W.nextTick(y,f||N))};async function x(N){let y=N!==void 0&&N!==null,f=typeof L.throw==="function";if(y&&f){let{value:o,done:r}=await L.throw(N);if(await o,r)return}if(typeof L.return==="function"){let{value:o}=await L.return();await o}}async function g(){for(;;){try{let{value:N,done:y}=M?await L.next():L.next();if(y)q.push(null);else{let f=N&&typeof N.then==="function"?await N:N;if(f===null)throw j=!1,new k;else if(q.push(f))continue;else j=!1}}catch(N){q.destroy(N)}break}}return q}G.exports=R}),xX=d0((E,G)=>{var W=UX(),{ArrayPrototypeIndexOf:C,NumberIsInteger:H,NumberIsNaN:z,NumberParseInt:V,ObjectDefineProperties:P,ObjectKeys:k,ObjectSetPrototypeOf:R,Promise:S,SafeSet:D,SymbolAsyncDispose:A,SymbolAsyncIterator:L,Symbol:M}=s0();G.exports=H0,H0.ReadableState=X0;var{EventEmitter:q}=(FX(),y0(JX)),{Stream:j,prependListener:x}=QI(),{Buffer:g}=(HU(),y0(FU)),{addAbortSignal:N}=jX(),y=nU(),f=SU().debuglog("stream",(_)=>{f=_}),o=_$(),r=OX(),{getHighWaterMark:V0,getDefaultHighWaterMark:Y0}=BX(),{aggregateTwoErrors:u,codes:{ERR_INVALID_ARG_TYPE:a,ERR_METHOD_NOT_IMPLEMENTED:F,ERR_OUT_OF_RANGE:U,ERR_STREAM_PUSH_AFTER_EOF:Z,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:Q},AbortError:I}=MU(),{validateObject:$}=AX(),K=M("kPaused"),{StringDecoder:J}=y$(),Y=WZ();R(H0.prototype,j.prototype),R(H0,j);var X=()=>{},{errorOrDestroy:O}=r,v=1,T=2,B=4,c=8,l=16,s=32,O0=64,h=128,d=256,g0=512,Q0=1024,$0=2048,m=4096,p=8192,b=16384,N0=32768,i=65536,e=131072,t=262144;function n(_){return{enumerable:!1,get(){return(this.state&_)!==0},set(w){if(w)this.state|=_;else this.state&=~_}}}P(X0.prototype,{objectMode:n(v),ended:n(T),endEmitted:n(B),reading:n(c),constructed:n(l),sync:n(s),needReadable:n(O0),emittedReadable:n(h),readableListening:n(d),resumeScheduled:n(g0),errorEmitted:n(Q0),emitClose:n($0),autoDestroy:n(m),destroyed:n(p),closed:n(b),closeEmitted:n(N0),multiAwaitDrain:n(i),readingMore:n(e),dataEmitted:n(t)});function X0(_,w,_0){if(typeof _0!=="boolean")_0=w instanceof hU();if(this.state=$0|m|l|s,_&&_.objectMode)this.state|=v;if(_0&&_&&_.readableObjectMode)this.state|=v;if(this.highWaterMark=_?V0(this,_,"readableHighWaterMark",_0):Y0(!1),this.buffer=new o,this.length=0,this.pipes=[],this.flowing=null,this[K]=null,_&&_.emitClose===!1)this.state&=~$0;if(_&&_.autoDestroy===!1)this.state&=~m;if(this.errored=null,this.defaultEncoding=_&&_.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,_&&_.encoding)this.decoder=new J(_.encoding),this.encoding=_.encoding}function H0(_){if(!(this instanceof H0))return new H0(_);let w=this instanceof hU();if(this._readableState=new X0(_,this,w),_){if(typeof _.read==="function")this._read=_.read;if(typeof _.destroy==="function")this._destroy=_.destroy;if(typeof _.construct==="function")this._construct=_.construct;if(_.signal&&!w)N(_.signal,this)}j.call(this,_),r.construct(this,()=>{if(this._readableState.needReadable)r0(this,this._readableState)})}H0.prototype.destroy=r.destroy,H0.prototype._undestroy=r.undestroy,H0.prototype._destroy=function(_,w){w(_)},H0.prototype[q.captureRejectionSymbol]=function(_){this.destroy(_)},H0.prototype[A]=function(){let _;if(!this.destroyed)_=this.readableEnded?null:new I,this.destroy(_);return new S((w,_0)=>y(this,(U0)=>U0&&U0!==_?_0(U0):w(null)))},H0.prototype.push=function(_,w){return Z0(this,_,w,!1)},H0.prototype.unshift=function(_,w){return Z0(this,_,w,!0)};function Z0(_,w,_0,U0){f("readableAddChunk",w);let I0=_._readableState,l0;if((I0.state&v)===0){if(typeof w==="string"){if(_0=_0||I0.defaultEncoding,I0.encoding!==_0)if(U0&&I0.encoding)w=g.from(w,_0).toString(I0.encoding);else w=g.from(w,_0),_0=""}else if(w instanceof g)_0="";else if(j._isUint8Array(w))w=j._uint8ArrayToBuffer(w),_0="";else if(w!=null)l0=new a("chunk",["string","Buffer","Uint8Array"],w)}if(l0)O(_,l0);else if(w===null)I0.state&=~c,u0(_,I0);else if((I0.state&v)!==0||w&&w.length>0)if(U0)if((I0.state&B)!==0)O(_,new Q);else if(I0.destroyed||I0.errored)return!1;else W0(_,I0,w,!0);else if(I0.ended)O(_,new Z);else if(I0.destroyed||I0.errored)return!1;else if(I0.state&=~c,I0.decoder&&!_0)if(w=I0.decoder.write(w),I0.objectMode||w.length!==0)W0(_,I0,w,!1);else r0(_,I0);else W0(_,I0,w,!1);else if(!U0)I0.state&=~c,r0(_,I0);return!I0.ended&&(I0.length<I0.highWaterMark||I0.length===0)}function W0(_,w,_0,U0){if(w.flowing&&w.length===0&&!w.sync&&_.listenerCount("data")>0){if((w.state&i)!==0)w.awaitDrainWriters.clear();else w.awaitDrainWriters=null;w.dataEmitted=!0,_.emit("data",_0)}else{if(w.length+=w.objectMode?1:_0.length,U0)w.buffer.unshift(_0);else w.buffer.push(_0);if((w.state&O0)!==0)J0(_)}r0(_,w)}H0.prototype.isPaused=function(){let _=this._readableState;return _[K]===!0||_.flowing===!1},H0.prototype.setEncoding=function(_){let w=new J(_);this._readableState.decoder=w,this._readableState.encoding=this._readableState.decoder.encoding;let _0=this._readableState.buffer,U0="";for(let I0 of _0)U0+=w.write(I0);if(_0.clear(),U0!=="")_0.push(U0);return this._readableState.length=U0.length,this};var c0=1073741824;function G0(_){if(_>c0)throw new U("size","<= 1GiB",_);else _--,_|=_>>>1,_|=_>>>2,_|=_>>>4,_|=_>>>8,_|=_>>>16,_++;return _}function A0(_,w){if(_<=0||w.length===0&&w.ended)return 0;if((w.state&v)!==0)return 1;if(z(_)){if(w.flowing&&w.length)return w.buffer.first().length;return w.length}if(_<=w.length)return _;return w.ended?w.length:0}H0.prototype.read=function(_){if(f("read",_),_===void 0)_=NaN;else if(!H(_))_=V(_,10);let w=this._readableState,_0=_;if(_>w.highWaterMark)w.highWaterMark=G0(_);if(_!==0)w.state&=~h;if(_===0&&w.needReadable&&((w.highWaterMark!==0?w.length>=w.highWaterMark:w.length>0)||w.ended)){if(f("read: emitReadable",w.length,w.ended),w.length===0&&w.ended)D0(this);else J0(this);return null}if(_=A0(_,w),_===0&&w.ended){if(w.length===0)D0(this);return null}let U0=(w.state&O0)!==0;if(f("need readable",U0),w.length===0||w.length-_<w.highWaterMark)U0=!0,f("length less than watermark",U0);if(w.ended||w.reading||w.destroyed||w.errored||!w.constructed)U0=!1,f("reading, ended or constructing",U0);else if(U0){if(f("do read"),w.state|=c|s,w.length===0)w.state|=O0;try{this._read(w.highWaterMark)}catch(l0){O(this,l0)}if(w.state&=~s,!w.reading)_=A0(_0,w)}let I0;if(_>0)I0=P0(_,w);else I0=null;if(I0===null)w.needReadable=w.length<=w.highWaterMark,_=0;else if(w.length-=_,w.multiAwaitDrain)w.awaitDrainWriters.clear();else w.awaitDrainWriters=null;if(w.length===0){if(!w.ended)w.needReadable=!0;if(_0!==_&&w.ended)D0(this)}if(I0!==null&&!w.errorEmitted&&!w.closeEmitted)w.dataEmitted=!0,this.emit("data",I0);return I0};function u0(_,w){if(f("onEofChunk"),w.ended)return;if(w.decoder){let _0=w.decoder.end();if(_0&&_0.length)w.buffer.push(_0),w.length+=w.objectMode?1:_0.length}if(w.ended=!0,w.sync)J0(_);else w.needReadable=!1,w.emittedReadable=!0,T0(_)}function J0(_){let w=_._readableState;if(f("emitReadable",w.needReadable,w.emittedReadable),w.needReadable=!1,!w.emittedReadable)f("emitReadable",w.flowing),w.emittedReadable=!0,W.nextTick(T0,_)}function T0(_){let w=_._readableState;if(f("emitReadable_",w.destroyed,w.length,w.ended),!w.destroyed&&!w.errored&&(w.length||w.ended))_.emit("readable"),w.emittedReadable=!1;w.needReadable=!w.flowing&&!w.ended&&w.length<=w.highWaterMark,R0(_)}function r0(_,w){if(!w.readingMore&&w.constructed)w.readingMore=!0,W.nextTick(E0,_,w)}function E0(_,w){while(!w.reading&&!w.ended&&(w.length<w.highWaterMark||w.flowing&&w.length===0)){let _0=w.length;if(f("maybeReadMore read 0"),_.read(0),_0===w.length)break}w.readingMore=!1}H0.prototype._read=function(_){throw new F("_read()")},H0.prototype.pipe=function(_,w){let _0=this,U0=this._readableState;if(U0.pipes.length===1){if(!U0.multiAwaitDrain)U0.multiAwaitDrain=!0,U0.awaitDrainWriters=new D(U0.awaitDrainWriters?[U0.awaitDrainWriters]:[])}U0.pipes.push(_),f("pipe count=%d opts=%j",U0.pipes.length,w);let I0=(!w||w.end!==!1)&&_!==W.stdout&&_!==W.stderr?F0:p0;if(U0.endEmitted)W.nextTick(I0);else _0.once("end",I0);_.on("unpipe",l0);function l0(f0,b0){if(f("onunpipe"),f0===_0){if(b0&&b0.hasUnpiped===!1)b0.hasUnpiped=!0,x0()}}function F0(){f("onend"),_.end()}let C0,CU=!1;function x0(){if(f("cleanup"),_.removeListener("close",M0),_.removeListener("finish",t0),C0)_.removeListener("drain",C0);if(_.removeListener("error",z0),_.removeListener("unpipe",l0),_0.removeListener("end",F0),_0.removeListener("end",p0),_0.removeListener("data",TU),CU=!0,C0&&U0.awaitDrainWriters&&(!_._writableState||_._writableState.needDrain))C0()}function q0(){if(!CU){if(U0.pipes.length===1&&U0.pipes[0]===_)f("false write response, pause",0),U0.awaitDrainWriters=_,U0.multiAwaitDrain=!1;else if(U0.pipes.length>1&&U0.pipes.includes(_))f("false write response, pause",U0.awaitDrainWriters.size),U0.awaitDrainWriters.add(_);_0.pause()}if(!C0)C0=v0(_0,_),_.on("drain",C0)}_0.on("data",TU);function TU(f0){f("ondata");let b0=_.write(f0);if(f("dest.write",b0),b0===!1)q0()}function z0(f0){if(f("onerror",f0),p0(),_.removeListener("error",z0),_.listenerCount("error")===0){let b0=_._writableState||_._readableState;if(b0&&!b0.errorEmitted)O(_,f0);else _.emit("error",f0)}}x(_,"error",z0);function M0(){_.removeListener("finish",t0),p0()}_.once("close",M0);function t0(){f("onfinish"),_.removeListener("close",M0),p0()}_.once("finish",t0);function p0(){f("unpipe"),_0.unpipe(_)}if(_.emit("pipe",_0),_.writableNeedDrain===!0)q0();else if(!U0.flowing)f("pipe resume"),_0.resume();return _};function v0(_,w){return function _0(){let U0=_._readableState;if(U0.awaitDrainWriters===w)f("pipeOnDrain",1),U0.awaitDrainWriters=null;else if(U0.multiAwaitDrain)f("pipeOnDrain",U0.awaitDrainWriters.size),U0.awaitDrainWriters.delete(w);if((!U0.awaitDrainWriters||U0.awaitDrainWriters.size===0)&&_.listenerCount("data"))_.resume()}}H0.prototype.unpipe=function(_){let w=this._readableState,_0={hasUnpiped:!1};if(w.pipes.length===0)return this;if(!_){let I0=w.pipes;w.pipes=[],this.pause();for(let l0=0;l0<I0.length;l0++)I0[l0].emit("unpipe",this,{hasUnpiped:!1});return this}let U0=C(w.pipes,_);if(U0===-1)return this;if(w.pipes.splice(U0,1),w.pipes.length===0)this.pause();return _.emit("unpipe",this,_0),this},H0.prototype.on=function(_,w){let _0=j.prototype.on.call(this,_,w),U0=this._readableState;if(_==="data"){if(U0.readableListening=this.listenerCount("readable")>0,U0.flowing!==!1)this.resume()}else if(_==="readable"){if(!U0.endEmitted&&!U0.readableListening){if(U0.readableListening=U0.needReadable=!0,U0.flowing=!1,U0.emittedReadable=!1,f("on readable",U0.length,U0.reading),U0.length)J0(this);else if(!U0.reading)W.nextTick(k0,this)}}return _0},H0.prototype.addListener=H0.prototype.on,H0.prototype.removeListener=function(_,w){let _0=j.prototype.removeListener.call(this,_,w);if(_==="readable")W.nextTick(AU,this);return _0},H0.prototype.off=H0.prototype.removeListener,H0.prototype.removeAllListeners=function(_){let w=j.prototype.removeAllListeners.apply(this,arguments);if(_==="readable"||_===void 0)W.nextTick(AU,this);return w};function AU(_){let w=_._readableState;if(w.readableListening=_.listenerCount("readable")>0,w.resumeScheduled&&w[K]===!1)w.flowing=!0;else if(_.listenerCount("data")>0)_.resume();else if(!w.readableListening)w.flowing=null}function k0(_){f("readable nexttick read 0"),_.read(0)}H0.prototype.resume=function(){let _=this._readableState;if(!_.flowing)f("resume"),_.flowing=!_.readableListening,j0(this,_);return _[K]=!1,this};function j0(_,w){if(!w.resumeScheduled)w.resumeScheduled=!0,W.nextTick(DU,_,w)}function DU(_,w){if(f("resume",w.reading),!w.reading)_.read(0);if(w.resumeScheduled=!1,_.emit("resume"),R0(_),w.flowing&&!w.reading)_.read(0)}H0.prototype.pause=function(){if(f("call pause flowing=%j",this._readableState.flowing),this._readableState.flowing!==!1)f("pause"),this._readableState.flowing=!1,this.emit("pause");return this._readableState[K]=!0,this};function R0(_){let w=_._readableState;f("flow",w.flowing);while(w.flowing&&_.read()!==null);}H0.prototype.wrap=function(_){let w=!1;_.on("data",(U0)=>{if(!this.push(U0)&&_.pause)w=!0,_.pause()}),_.on("end",()=>{this.push(null)}),_.on("error",(U0)=>{O(this,U0)}),_.on("close",()=>{this.destroy()}),_.on("destroy",()=>{this.destroy()}),this._read=()=>{if(w&&_.resume)w=!1,_.resume()};let _0=k(_);for(let U0=1;U0<_0.length;U0++){let I0=_0[U0];if(this[I0]===void 0&&typeof _[I0]==="function")this[I0]=_[I0].bind(_)}return this},H0.prototype[L]=function(){return S0(this)},H0.prototype.iterator=function(_){if(_!==void 0)$(_,"options");return S0(this,_)};function S0(_,w){if(typeof _.read!=="function")_=H0.wrap(_,{objectMode:!0});let _0=LU(_,w);return _0.stream=_,_0}async function*LU(_,w){let _0=X;function U0(F0){if(this===_)_0(),_0=X;else _0=F0}_.on("readable",U0);let I0,l0=y(_,{writable:!1},(F0)=>{I0=F0?u(I0,F0):null,_0(),_0=X});try{while(!0){let F0=_.destroyed?null:_.read();if(F0!==null)yield F0;else if(I0)throw I0;else if(I0===null)return;else await new S(U0)}}catch(F0){throw I0=u(I0,F0),I0}finally{if((I0||(w===null||w===void 0?void 0:w.destroyOnReturn)!==!1)&&(I0===void 0||_._readableState.autoDestroy))r.destroyer(_,null);else _.off("readable",U0),l0()}}P(H0.prototype,{readable:{__proto__:null,get(){let _=this._readableState;return!!_&&_.readable!==!1&&!_.destroyed&&!_.errorEmitted&&!_.endEmitted},set(_){if(this._readableState)this._readableState.readable=!!_}},readableDidRead:{__proto__:null,enumerable:!1,get:function(){return this._readableState.dataEmitted}},readableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._readableState.readable!==!1&&(this._readableState.destroyed||this._readableState.errored)&&!this._readableState.endEmitted)}},readableHighWaterMark:{__proto__:null,enumerable:!1,get:function(){return this._readableState.highWaterMark}},readableBuffer:{__proto__:null,enumerable:!1,get:function(){return this._readableState&&this._readableState.buffer}},readableFlowing:{__proto__:null,enumerable:!1,get:function(){return this._readableState.flowing},set:function(_){if(this._readableState)this._readableState.flowing=_}},readableLength:{__proto__:null,enumerable:!1,get(){return this._readableState.length}},readableObjectMode:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.objectMode:!1}},readableEncoding:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.encoding:null}},errored:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.errored:null}},closed:{__proto__:null,get(){return this._readableState?this._readableState.closed:!1}},destroyed:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.destroyed:!1},set(_){if(!this._readableState)return;this._readableState.destroyed=_}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),P(X0.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[K]!==!1},set(_){this[K]=!!_}}}),H0._fromList=P0;function P0(_,w){if(w.length===0)return null;let _0;if(w.objectMode)_0=w.buffer.shift();else if(!_||_>=w.length){if(w.decoder)_0=w.buffer.join("");else if(w.buffer.length===1)_0=w.buffer.first();else _0=w.buffer.concat(w.length);w.buffer.clear()}else _0=w.buffer.consume(_,w.decoder);return _0}function D0(_){let w=_._readableState;if(f("endReadable",w.endEmitted),!w.endEmitted)w.ended=!0,W.nextTick(zU,w,_)}function zU(_,w){if(f("endReadableNT",_.endEmitted,_.length),!_.errored&&!_.closeEmitted&&!_.endEmitted&&_.length===0){if(_.endEmitted=!0,w.emit("end"),w.writable&&w.allowHalfOpen===!1)W.nextTick(B0,w);else if(_.autoDestroy){let _0=w._writableState;if(!_0||_0.autoDestroy&&(_0.finished||_0.writable===!1))w.destroy()}}}function B0(_){if(_.writable&&!_.writableEnded&&!_.destroyed)_.end()}H0.from=function(_,w){return Y(H0,_,w)};var L0;function EU(){if(L0===void 0)L0={};return L0}H0.fromWeb=function(_,w){return EU().newStreamReadableFromReadableStream(_,w)},H0.toWeb=function(_,w){return EU().newReadableStreamFromStreamReadable(_,w)},H0.wrap=function(_,w){var _0,U0;return new H0({objectMode:(_0=(U0=_.readableObjectMode)!==null&&U0!==void 0?U0:_.objectMode)!==null&&_0!==void 0?_0:!0,...w,destroy(I0,l0){r.destroyer(_,I0),l0(I0)}}).wrap(_)}}),$I=d0((E,G)=>{var W=UX(),{ArrayPrototypeSlice:C,Error:H,FunctionPrototypeSymbolHasInstance:z,ObjectDefineProperty:V,ObjectDefineProperties:P,ObjectSetPrototypeOf:k,StringPrototypeToLowerCase:R,Symbol:S,SymbolHasInstance:D}=s0();G.exports=$,$.WritableState=Q;var{EventEmitter:A}=(FX(),y0(JX)),L=QI().Stream,{Buffer:M}=(HU(),y0(FU)),q=OX(),{addAbortSignal:j}=jX(),{getHighWaterMark:x,getDefaultHighWaterMark:g}=BX(),{ERR_INVALID_ARG_TYPE:N,ERR_METHOD_NOT_IMPLEMENTED:y,ERR_MULTIPLE_CALLBACK:f,ERR_STREAM_CANNOT_PIPE:o,ERR_STREAM_DESTROYED:r,ERR_STREAM_ALREADY_FINISHED:V0,ERR_STREAM_NULL_VALUES:Y0,ERR_STREAM_WRITE_AFTER_END:u,ERR_UNKNOWN_ENCODING:a}=MU().codes,{errorOrDestroy:F}=q;k($.prototype,L.prototype),k($,L);function U(){}var Z=S("kOnFinished");function Q(m,p,b){if(typeof b!=="boolean")b=p instanceof hU();if(this.objectMode=!!(m&&m.objectMode),b)this.objectMode=this.objectMode||!!(m&&m.writableObjectMode);this.highWaterMark=m?x(this,m,"writableHighWaterMark",b):g(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let N0=!!(m&&m.decodeStrings===!1);this.decodeStrings=!N0,this.defaultEncoding=m&&m.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=O.bind(void 0,p),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,I(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!m||m.emitClose!==!1,this.autoDestroy=!m||m.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[Z]=[]}function I(m){m.buffered=[],m.bufferedIndex=0,m.allBuffers=!0,m.allNoop=!0}Q.prototype.getBuffer=function m(){return C(this.buffered,this.bufferedIndex)},V(Q.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function $(m){let p=this instanceof hU();if(!p&&!z($,this))return new $(m);if(this._writableState=new Q(m,this,p),m){if(typeof m.write==="function")this._write=m.write;if(typeof m.writev==="function")this._writev=m.writev;if(typeof m.destroy==="function")this._destroy=m.destroy;if(typeof m.final==="function")this._final=m.final;if(typeof m.construct==="function")this._construct=m.construct;if(m.signal)j(m.signal,this)}L.call(this,m),q.construct(this,()=>{let b=this._writableState;if(!b.writing)c(this,b);h(this,b)})}V($,D,{__proto__:null,value:function(m){if(z(this,m))return!0;if(this!==$)return!1;return m&&m._writableState instanceof Q}}),$.prototype.pipe=function(){F(this,new o)};function K(m,p,b,N0){let i=m._writableState;if(typeof b==="function")N0=b,b=i.defaultEncoding;else{if(!b)b=i.defaultEncoding;else if(b!=="buffer"&&!M.isEncoding(b))throw new a(b);if(typeof N0!=="function")N0=U}if(p===null)throw new Y0;else if(!i.objectMode)if(typeof p==="string"){if(i.decodeStrings!==!1)p=M.from(p,b),b="buffer"}else if(p instanceof M)b="buffer";else if(L._isUint8Array(p))p=L._uint8ArrayToBuffer(p),b="buffer";else throw new N("chunk",["string","Buffer","Uint8Array"],p);let e;if(i.ending)e=new u;else if(i.destroyed)e=new r("write");if(e)return W.nextTick(N0,e),F(m,e,!0),e;return i.pendingcb++,J(m,i,p,b,N0)}$.prototype.write=function(m,p,b){return K(this,m,p,b)===!0},$.prototype.cork=function(){this._writableState.corked++},$.prototype.uncork=function(){let m=this._writableState;if(m.corked){if(m.corked--,!m.writing)c(this,m)}},$.prototype.setDefaultEncoding=function m(p){if(typeof p==="string")p=R(p);if(!M.isEncoding(p))throw new a(p);return this._writableState.defaultEncoding=p,this};function J(m,p,b,N0,i){let e=p.objectMode?1:b.length;p.length+=e;let t=p.length<p.highWaterMark;if(!t)p.needDrain=!0;if(p.writing||p.corked||p.errored||!p.constructed){if(p.buffered.push({chunk:b,encoding:N0,callback:i}),p.allBuffers&&N0!=="buffer")p.allBuffers=!1;if(p.allNoop&&i!==U)p.allNoop=!1}else p.writelen=e,p.writecb=i,p.writing=!0,p.sync=!0,m._write(b,N0,p.onwrite),p.sync=!1;return t&&!p.errored&&!p.destroyed}function Y(m,p,b,N0,i,e,t){if(p.writelen=N0,p.writecb=t,p.writing=!0,p.sync=!0,p.destroyed)p.onwrite(new r("write"));else if(b)m._writev(i,p.onwrite);else m._write(i,e,p.onwrite);p.sync=!1}function X(m,p,b,N0){--p.pendingcb,N0(b),B(p),F(m,b)}function O(m,p){let b=m._writableState,N0=b.sync,i=b.writecb;if(typeof i!=="function"){F(m,new f);return}if(b.writing=!1,b.writecb=null,b.length-=b.writelen,b.writelen=0,p){if(p.stack,!b.errored)b.errored=p;if(m._readableState&&!m._readableState.errored)m._readableState.errored=p;if(N0)W.nextTick(X,m,b,p,i);else X(m,b,p,i)}else{if(b.buffered.length>b.bufferedIndex)c(m,b);if(N0)if(b.afterWriteTickInfo!==null&&b.afterWriteTickInfo.cb===i)b.afterWriteTickInfo.count++;else b.afterWriteTickInfo={count:1,cb:i,stream:m,state:b},W.nextTick(v,b.afterWriteTickInfo);else T(m,b,1,i)}}function v({stream:m,state:p,count:b,cb:N0}){return p.afterWriteTickInfo=null,T(m,p,b,N0)}function T(m,p,b,N0){if(!p.ending&&!m.destroyed&&p.length===0&&p.needDrain)p.needDrain=!1,m.emit("drain");while(b-- >0)p.pendingcb--,N0();if(p.destroyed)B(p);h(m,p)}function B(m){if(m.writing)return;for(let i=m.bufferedIndex;i<m.buffered.length;++i){var p;let{chunk:e,callback:t}=m.buffered[i],n=m.objectMode?1:e.length;m.length-=n,t((p=m.errored)!==null&&p!==void 0?p:new r("write"))}let b=m[Z].splice(0);for(let i=0;i<b.length;i++){var N0;b[i]((N0=m.errored)!==null&&N0!==void 0?N0:new r("end"))}I(m)}function c(m,p){if(p.corked||p.bufferProcessing||p.destroyed||!p.constructed)return;let{buffered:b,bufferedIndex:N0,objectMode:i}=p,e=b.length-N0;if(!e)return;let t=N0;if(p.bufferProcessing=!0,e>1&&m._writev){p.pendingcb-=e-1;let n=p.allNoop?U:(H0)=>{for(let Z0=t;Z0<b.length;++Z0)b[Z0].callback(H0)},X0=p.allNoop&&t===0?b:C(b,t);X0.allBuffers=p.allBuffers,Y(m,p,!0,p.length,X0,"",n),I(p)}else{do{let{chunk:n,encoding:X0,callback:H0}=b[t];b[t++]=null;let Z0=i?1:n.length;Y(m,p,!1,Z0,n,X0,H0)}while(t<b.length&&!p.writing);if(t===b.length)I(p);else if(t>256)b.splice(0,t),p.bufferedIndex=0;else p.bufferedIndex=t}p.bufferProcessing=!1}$.prototype._write=function(m,p,b){if(this._writev)this._writev([{chunk:m,encoding:p}],b);else throw new y("_write()")},$.prototype._writev=null,$.prototype.end=function(m,p,b){let N0=this._writableState;if(typeof m==="function")b=m,m=null,p=null;else if(typeof p==="function")b=p,p=null;let i;if(m!==null&&m!==void 0){let e=K(this,m,p);if(e instanceof H)i=e}if(N0.corked)N0.corked=1,this.uncork();if(i);else if(!N0.errored&&!N0.ending)N0.ending=!0,h(this,N0,!0),N0.ended=!0;else if(N0.finished)i=new V0("end");else if(N0.destroyed)i=new r("end");if(typeof b==="function")if(i||N0.finished)W.nextTick(b,i);else N0[Z].push(b);return this};function l(m){return m.ending&&!m.destroyed&&m.constructed&&m.length===0&&!m.errored&&m.buffered.length===0&&!m.finished&&!m.writing&&!m.errorEmitted&&!m.closeEmitted}function s(m,p){let b=!1;function N0(i){if(b){F(m,i!==null&&i!==void 0?i:f());return}if(b=!0,p.pendingcb--,i){let e=p[Z].splice(0);for(let t=0;t<e.length;t++)e[t](i);F(m,i,p.sync)}else if(l(p))p.prefinished=!0,m.emit("prefinish"),p.pendingcb++,W.nextTick(d,m,p)}p.sync=!0,p.pendingcb++;try{m._final(N0)}catch(i){N0(i)}p.sync=!1}function O0(m,p){if(!p.prefinished&&!p.finalCalled)if(typeof m._final==="function"&&!p.destroyed)p.finalCalled=!0,s(m,p);else p.prefinished=!0,m.emit("prefinish")}function h(m,p,b){if(l(p)){if(O0(m,p),p.pendingcb===0){if(b)p.pendingcb++,W.nextTick((N0,i)=>{if(l(i))d(N0,i);else i.pendingcb--},m,p);else if(l(p))p.pendingcb++,d(m,p)}}}function d(m,p){p.pendingcb--,p.finished=!0;let b=p[Z].splice(0);for(let N0=0;N0<b.length;N0++)b[N0]();if(m.emit("finish"),p.autoDestroy){let N0=m._readableState;if(!N0||N0.autoDestroy&&(N0.endEmitted||N0.readable===!1))m.destroy()}}P($.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(m){if(this._writableState)this._writableState.destroyed=m}},writable:{__proto__:null,get(){let m=this._writableState;return!!m&&m.writable!==!1&&!m.destroyed&&!m.errored&&!m.ending&&!m.ended},set(m){if(this._writableState)this._writableState.writable=!!m}},writableFinished:{__proto__:null,get(){return this._writableState?this._writableState.finished:!1}},writableObjectMode:{__proto__:null,get(){return this._writableState?this._writableState.objectMode:!1}},writableBuffer:{__proto__:null,get(){return this._writableState&&this._writableState.getBuffer()}},writableEnded:{__proto__:null,get(){return this._writableState?this._writableState.ending:!1}},writableNeedDrain:{__proto__:null,get(){let m=this._writableState;if(!m)return!1;return!m.destroyed&&!m.ending&&m.needDrain}},writableHighWaterMark:{__proto__:null,get(){return this._writableState&&this._writableState.highWaterMark}},writableCorked:{__proto__:null,get(){return this._writableState?this._writableState.corked:0}},writableLength:{__proto__:null,get(){return this._writableState&&this._writableState.length}},errored:{__proto__:null,enumerable:!1,get(){return this._writableState?this._writableState.errored:null}},writableAborted:{__proto__:null,enumerable:!1,get:function(){return!!(this._writableState.writable!==!1&&(this._writableState.destroyed||this._writableState.errored)&&!this._writableState.finished)}}});var g0=q.destroy;$.prototype.destroy=function(m,p){let b=this._writableState;if(!b.destroyed&&(b.bufferedIndex<b.buffered.length||b[Z].length))W.nextTick(B,b);return g0.call(this,m,p),this},$.prototype._undestroy=q.undestroy,$.prototype._destroy=function(m,p){p(m)},$.prototype[A.captureRejectionSymbol]=function(m){this.destroy(m)};var Q0;function $0(){if(Q0===void 0)Q0={};return Q0}$.fromWeb=function(m,p){return $0().newStreamWritableFromWritableStream(m,p)},$.toWeb=function(m){return $0().newWritableStreamFromStreamWritable(m)}}),f$=d0((E,G)=>{var W=UX(),C=(HU(),y0(FU)),{isReadable:H,isWritable:z,isIterable:V,isNodeStream:P,isReadableNodeStream:k,isWritableNodeStream:R,isDuplexNodeStream:S,isReadableStream:D,isWritableStream:A}=uU(),L=nU(),{AbortError:M,codes:{ERR_INVALID_ARG_TYPE:q,ERR_INVALID_RETURN_VALUE:j}}=MU(),{destroyer:x}=OX(),g=hU(),N=xX(),y=$I(),{createDeferredPromise:f}=SU(),o=WZ(),r=globalThis.Blob||C.Blob,V0=typeof r!=="undefined"?function Z(Q){return Q instanceof r}:function Z(Q){return!1},Y0=globalThis.AbortController||HX().AbortController,{FunctionPrototypeCall:u}=s0();class a extends g{constructor(Z){super(Z);if((Z===null||Z===void 0?void 0:Z.readable)===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if((Z===null||Z===void 0?void 0:Z.writable)===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}}G.exports=function Z(Q,I){if(S(Q))return Q;if(k(Q))return U({readable:Q});if(R(Q))return U({writable:Q});if(P(Q))return U({writable:!1,readable:!1});if(D(Q))return U({readable:N.fromWeb(Q)});if(A(Q))return U({writable:y.fromWeb(Q)});if(typeof Q==="function"){let{value:K,write:J,final:Y,destroy:X}=F(Q);if(V(K))return o(a,K,{objectMode:!0,write:J,final:Y,destroy:X});let O=K===null||K===void 0?void 0:K.then;if(typeof O==="function"){let v,T=u(O,K,(B)=>{if(B!=null)throw new j("nully","body",B)},(B)=>{x(v,B)});return v=new a({objectMode:!0,readable:!1,write:J,final(B){Y(async()=>{try{await T,W.nextTick(B,null)}catch(c){W.nextTick(B,c)}})},destroy:X})}throw new j("Iterable, AsyncIterable or AsyncFunction",I,K)}if(V0(Q))return Z(Q.arrayBuffer());if(V(Q))return o(a,Q,{objectMode:!0,writable:!1});if(D(Q===null||Q===void 0?void 0:Q.readable)&&A(Q===null||Q===void 0?void 0:Q.writable))return a.fromWeb(Q);if(typeof(Q===null||Q===void 0?void 0:Q.writable)==="object"||typeof(Q===null||Q===void 0?void 0:Q.readable)==="object"){let K=Q!==null&&Q!==void 0&&Q.readable?k(Q===null||Q===void 0?void 0:Q.readable)?Q===null||Q===void 0?void 0:Q.readable:Z(Q.readable):void 0,J=Q!==null&&Q!==void 0&&Q.writable?R(Q===null||Q===void 0?void 0:Q.writable)?Q===null||Q===void 0?void 0:Q.writable:Z(Q.writable):void 0;return U({readable:K,writable:J})}let $=Q===null||Q===void 0?void 0:Q.then;if(typeof $==="function"){let K;return u($,Q,(J)=>{if(J!=null)K.push(J);K.push(null)},(J)=>{x(K,J)}),K=new a({objectMode:!0,writable:!1,read(){}})}throw new q(I,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],Q)};function F(Z){let{promise:Q,resolve:I}=f(),$=new Y0,K=$.signal;return{value:Z(async function*(){while(!0){let J=Q;Q=null;let{chunk:Y,done:X,cb:O}=await J;if(W.nextTick(O),X)return;if(K.aborted)throw new M(void 0,{cause:K.reason});({promise:Q,resolve:I}=f()),yield Y}}(),{signal:K}),write(J,Y,X){let O=I;I=null,O({chunk:J,done:!1,cb:X})},final(J){let Y=I;I=null,Y({done:!0,cb:J})},destroy(J,Y){$.abort(),Y(J)}}}function U(Z){let Q=Z.readable&&typeof Z.readable.read!=="function"?N.wrap(Z.readable):Z.readable,I=Z.writable,$=!!H(Q),K=!!z(I),J,Y,X,O,v;function T(B){let c=O;if(O=null,c)c(B);else if(B)v.destroy(B)}if(v=new a({readableObjectMode:!!(Q!==null&&Q!==void 0&&Q.readableObjectMode),writableObjectMode:!!(I!==null&&I!==void 0&&I.writableObjectMode),readable:$,writable:K}),K)L(I,(B)=>{if(K=!1,B)x(Q,B);T(B)}),v._write=function(B,c,l){if(I.write(B,c))l();else J=l},v._final=function(B){I.end(),Y=B},I.on("drain",function(){if(J){let B=J;J=null,B()}}),I.on("finish",function(){if(Y){let B=Y;Y=null,B()}});if($)L(Q,(B)=>{if($=!1,B)x(Q,B);T(B)}),Q.on("readable",function(){if(X){let B=X;X=null,B()}}),Q.on("end",function(){v.push(null)}),v._read=function(){while(!0){let B=Q.read();if(B===null){X=v._read;return}if(!v.push(B))return}};return v._destroy=function(B,c){if(!B&&O!==null)B=new M;if(X=null,J=null,Y=null,O===null)c(B);else O=c,x(I,B),x(Q,B)},v}}),hU=d0((E,G)=>{var{ObjectDefineProperties:W,ObjectGetOwnPropertyDescriptor:C,ObjectKeys:H,ObjectSetPrototypeOf:z}=s0();G.exports=k;var V=xX(),P=$I();z(k.prototype,V.prototype),z(k,V);{let A=H(P.prototype);for(let L=0;L<A.length;L++){let M=A[L];if(!k.prototype[M])k.prototype[M]=P.prototype[M]}}function k(A){if(!(this instanceof k))return new k(A);if(V.call(this,A),P.call(this,A),A){if(this.allowHalfOpen=A.allowHalfOpen!==!1,A.readable===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if(A.writable===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}else this.allowHalfOpen=!0}W(k.prototype,{writable:{__proto__:null,...C(P.prototype,"writable")},writableHighWaterMark:{__proto__:null,...C(P.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...C(P.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...C(P.prototype,"writableBuffer")},writableLength:{__proto__:null,...C(P.prototype,"writableLength")},writableFinished:{__proto__:null,...C(P.prototype,"writableFinished")},writableCorked:{__proto__:null,...C(P.prototype,"writableCorked")},writableEnded:{__proto__:null,...C(P.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...C(P.prototype,"writableNeedDrain")},destroyed:{__proto__:null,get(){if(this._readableState===void 0||this._writableState===void 0)return!1;return this._readableState.destroyed&&this._writableState.destroyed},set(A){if(this._readableState&&this._writableState)this._readableState.destroyed=A,this._writableState.destroyed=A}}});var R;function S(){if(R===void 0)R={};return R}k.fromWeb=function(A,L){return S().newStreamDuplexFromReadableWritablePair(A,L)},k.toWeb=function(A){return S().newReadableWritablePairFromDuplex(A)};var D;k.from=function(A){if(!D)D=f$();return D(A,"body")}}),JZ=d0((E,G)=>{var{ObjectSetPrototypeOf:W,Symbol:C}=s0();G.exports=k;var{ERR_METHOD_NOT_IMPLEMENTED:H}=MU().codes,z=hU(),{getHighWaterMark:V}=BX();W(k.prototype,z.prototype),W(k,z);var P=C("kCallback");function k(D){if(!(this instanceof k))return new k(D);let A=D?V(this,D,"readableHighWaterMark",!0):null;if(A===0)D={...D,highWaterMark:null,readableHighWaterMark:A,writableHighWaterMark:D.writableHighWaterMark||0};if(z.call(this,D),this._readableState.sync=!1,this[P]=null,D){if(typeof D.transform==="function")this._transform=D.transform;if(typeof D.flush==="function")this._flush=D.flush}this.on("prefinish",S)}function R(D){if(typeof this._flush==="function"&&!this.destroyed)this._flush((A,L)=>{if(A){if(D)D(A);else this.destroy(A);return}if(L!=null)this.push(L);if(this.push(null),D)D()});else if(this.push(null),D)D()}function S(){if(this._final!==R)R.call(this)}k.prototype._final=R,k.prototype._transform=function(D,A,L){throw new H("_transform()")},k.prototype._write=function(D,A,L){let M=this._readableState,q=this._writableState,j=M.length;this._transform(D,A,(x,g)=>{if(x){L(x);return}if(g!=null)this.push(g);if(q.ended||j===M.length||M.length<M.highWaterMark)L();else this[P]=L})},k.prototype._read=function(){if(this[P]){let D=this[P];this[P]=null,D()}}}),FZ=d0((E,G)=>{var{ObjectSetPrototypeOf:W}=s0();G.exports=H;var C=JZ();W(H.prototype,C.prototype),W(H,C);function H(z){if(!(this instanceof H))return new H(z);C.call(this,z)}H.prototype._transform=function(z,V,P){P(null,z)}}),YI=d0((E,G)=>{var W=UX(),{ArrayIsArray:C,Promise:H,SymbolAsyncIterator:z,SymbolDispose:V}=s0(),P=nU(),{once:k}=SU(),R=OX(),S=hU(),{aggregateTwoErrors:D,codes:{ERR_INVALID_ARG_TYPE:A,ERR_INVALID_RETURN_VALUE:L,ERR_MISSING_ARGS:M,ERR_STREAM_DESTROYED:q,ERR_STREAM_PREMATURE_CLOSE:j},AbortError:x}=MU(),{validateFunction:g,validateAbortSignal:N}=AX(),{isIterable:y,isReadable:f,isReadableNodeStream:o,isNodeStream:r,isTransformStream:V0,isWebStream:Y0,isReadableStream:u,isReadableFinished:a}=uU(),F=globalThis.AbortController||HX().AbortController,U,Z,Q;function I(B,c,l){let s=!1;B.on("close",()=>{s=!0});let O0=P(B,{readable:c,writable:l},(h)=>{s=!h});return{destroy:(h)=>{if(s)return;s=!0,R.destroyer(B,h||new q("pipe"))},cleanup:O0}}function $(B){return g(B[B.length-1],"streams[stream.length - 1]"),B.pop()}function K(B){if(y(B))return B;else if(o(B))return J(B);throw new A("val",["Readable","Iterable","AsyncIterable"],B)}async function*J(B){if(!Z)Z=xX();yield*Z.prototype[z].call(B)}async function Y(B,c,l,{end:s}){let O0,h=null,d=($0)=>{if($0)O0=$0;if(h){let m=h;h=null,m()}},g0=()=>new H(($0,m)=>{if(O0)m(O0);else h=()=>{if(O0)m(O0);else $0()}});c.on("drain",d);let Q0=P(c,{readable:!1},d);try{if(c.writableNeedDrain)await g0();for await(let $0 of B)if(!c.write($0))await g0();if(s)c.end(),await g0();l()}catch($0){l(O0!==$0?D(O0,$0):$0)}finally{Q0(),c.off("drain",d)}}async function X(B,c,l,{end:s}){if(V0(c))c=c.writable;let O0=c.getWriter();try{for await(let h of B)await O0.ready,O0.write(h).catch(()=>{});if(await O0.ready,s)await O0.close();l()}catch(h){try{await O0.abort(h),l(h)}catch(d){l(d)}}}function O(...B){return v(B,k($(B)))}function v(B,c,l){if(B.length===1&&C(B[0]))B=B[0];if(B.length<2)throw new M("streams");let s=new F,O0=s.signal,h=l===null||l===void 0?void 0:l.signal,d=[];N(h,"options.signal");function g0(){i(new x)}Q=Q||SU().addAbortListener;let Q0;if(h)Q0=Q(h,g0);let $0,m,p=[],b=0;function N0(H0){i(H0,--b===0)}function i(H0,Z0){var W0;if(H0&&(!$0||$0.code==="ERR_STREAM_PREMATURE_CLOSE"))$0=H0;if(!$0&&!Z0)return;while(p.length)p.shift()($0);if((W0=Q0)===null||W0===void 0||W0[V](),s.abort(),Z0){if(!$0)d.forEach((c0)=>c0());W.nextTick(c,$0,m)}}let e;for(let H0=0;H0<B.length;H0++){let Z0=B[H0],W0=H0<B.length-1,c0=H0>0,G0=W0||(l===null||l===void 0?void 0:l.end)!==!1,A0=H0===B.length-1;if(r(Z0)){let u0=function(J0){if(J0&&J0.name!=="AbortError"&&J0.code!=="ERR_STREAM_PREMATURE_CLOSE")N0(J0)};var t=u0;if(G0){let{destroy:J0,cleanup:T0}=I(Z0,W0,c0);if(p.push(J0),f(Z0)&&A0)d.push(T0)}if(Z0.on("error",u0),f(Z0)&&A0)d.push(()=>{Z0.removeListener("error",u0)})}if(H0===0)if(typeof Z0==="function"){if(e=Z0({signal:O0}),!y(e))throw new L("Iterable, AsyncIterable or Stream","source",e)}else if(y(Z0)||o(Z0)||V0(Z0))e=Z0;else e=S.from(Z0);else if(typeof Z0==="function"){if(V0(e)){var n;e=K((n=e)===null||n===void 0?void 0:n.readable)}else e=K(e);if(e=Z0(e,{signal:O0}),W0){if(!y(e,!0))throw new L("AsyncIterable",`transform[${H0-1}]`,e)}else{var X0;if(!U)U=FZ();let u0=new U({objectMode:!0}),J0=(X0=e)===null||X0===void 0?void 0:X0.then;if(typeof J0==="function")b++,J0.call(e,(E0)=>{if(m=E0,E0!=null)u0.write(E0);if(G0)u0.end();W.nextTick(N0)},(E0)=>{u0.destroy(E0),W.nextTick(N0,E0)});else if(y(e,!0))b++,Y(e,u0,N0,{end:G0});else if(u(e)||V0(e)){let E0=e.readable||e;b++,Y(E0,u0,N0,{end:G0})}else throw new L("AsyncIterable or Promise","destination",e);e=u0;let{destroy:T0,cleanup:r0}=I(e,!1,!0);if(p.push(T0),A0)d.push(r0)}}else if(r(Z0)){if(o(e)){b+=2;let u0=T(e,Z0,N0,{end:G0});if(f(Z0)&&A0)d.push(u0)}else if(V0(e)||u(e)){let u0=e.readable||e;b++,Y(u0,Z0,N0,{end:G0})}else if(y(e))b++,Y(e,Z0,N0,{end:G0});else throw new A("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=Z0}else if(Y0(Z0)){if(o(e))b++,X(K(e),Z0,N0,{end:G0});else if(u(e)||y(e))b++,X(e,Z0,N0,{end:G0});else if(V0(e))b++,X(e.readable,Z0,N0,{end:G0});else throw new A("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],e);e=Z0}else e=S.from(Z0)}if(O0!==null&&O0!==void 0&&O0.aborted||h!==null&&h!==void 0&&h.aborted)W.nextTick(g0);return e}function T(B,c,l,{end:s}){let O0=!1;if(c.on("close",()=>{if(!O0)l(new j)}),B.pipe(c,{end:!1}),s){let d=function(){O0=!0,c.end()};var h=d;if(a(B))W.nextTick(d);else B.once("end",d)}else l();return P(B,{readable:!0,writable:!1},(d)=>{let g0=B._readableState;if(d&&d.code==="ERR_STREAM_PREMATURE_CLOSE"&&g0&&g0.ended&&!g0.errored&&!g0.errorEmitted)B.once("end",l).once("error",l);else l(d)}),P(c,{readable:!1,writable:!0},l)}G.exports={pipelineImpl:v,pipeline:O}}),HZ=d0((E,G)=>{var{pipeline:W}=YI(),C=hU(),{destroyer:H}=OX(),{isNodeStream:z,isReadable:V,isWritable:P,isWebStream:k,isTransformStream:R,isWritableStream:S,isReadableStream:D}=uU(),{AbortError:A,codes:{ERR_INVALID_ARG_VALUE:L,ERR_MISSING_ARGS:M}}=MU(),q=nU();G.exports=function j(...x){if(x.length===0)throw new M("streams");if(x.length===1)return C.from(x[0]);let g=[...x];if(typeof x[0]==="function")x[0]=C.from(x[0]);if(typeof x[x.length-1]==="function"){let U=x.length-1;x[U]=C.from(x[U])}for(let U=0;U<x.length;++U){if(!z(x[U])&&!k(x[U]))continue;if(U<x.length-1&&!(V(x[U])||D(x[U])||R(x[U])))throw new L(`streams[${U}]`,g[U],"must be readable");if(U>0&&!(P(x[U])||S(x[U])||R(x[U])))throw new L(`streams[${U}]`,g[U],"must be writable")}let N,y,f,o,r;function V0(U){let Z=o;if(o=null,Z)Z(U);else if(U)r.destroy(U);else if(!F&&!a)r.destroy()}let Y0=x[0],u=W(x,V0),a=!!(P(Y0)||S(Y0)||R(Y0)),F=!!(V(u)||D(u)||R(u));if(r=new C({writableObjectMode:!!(Y0!==null&&Y0!==void 0&&Y0.writableObjectMode),readableObjectMode:!!(u!==null&&u!==void 0&&u.readableObjectMode),writable:a,readable:F}),a){if(z(Y0))r._write=function(Z,Q,I){if(Y0.write(Z,Q))I();else N=I},r._final=function(Z){Y0.end(),y=Z},Y0.on("drain",function(){if(N){let Z=N;N=null,Z()}});else if(k(Y0)){let Z=(R(Y0)?Y0.writable:Y0).getWriter();r._write=async function(Q,I,$){try{await Z.ready,Z.write(Q).catch(()=>{}),$()}catch(K){$(K)}},r._final=async function(Q){try{await Z.ready,Z.close().catch(()=>{}),y=Q}catch(I){Q(I)}}}let U=R(u)?u.readable:u;q(U,()=>{if(y){let Z=y;y=null,Z()}})}if(F){if(z(u))u.on("readable",function(){if(f){let U=f;f=null,U()}}),u.on("end",function(){r.push(null)}),r._read=function(){while(!0){let U=u.read();if(U===null){f=r._read;return}if(!r.push(U))return}};else if(k(u)){let U=(R(u)?u.readable:u).getReader();r._read=async function(){while(!0)try{let{value:Z,done:Q}=await U.read();if(!r.push(Z))return;if(Q){r.push(null);return}}catch{return}}}}return r._destroy=function(U,Z){if(!U&&o!==null)U=new A;if(f=null,N=null,y=null,o===null)Z(U);else if(o=Z,z(u))H(u,U)},r}}),c$=d0((E,G)=>{var W=globalThis.AbortController||HX().AbortController,{codes:{ERR_INVALID_ARG_VALUE:C,ERR_INVALID_ARG_TYPE:H,ERR_MISSING_ARGS:z,ERR_OUT_OF_RANGE:V},AbortError:P}=MU(),{validateAbortSignal:k,validateInteger:R,validateObject:S}=AX(),D=s0().Symbol("kWeak"),A=s0().Symbol("kResistStopPropagation"),{finished:L}=nU(),M=HZ(),{addAbortSignalNoValidate:q}=jX(),{isWritable:j,isNodeStream:x}=uU(),{deprecate:g}=SU(),{ArrayPrototypePush:N,Boolean:y,MathFloor:f,Number:o,NumberIsNaN:r,Promise:V0,PromiseReject:Y0,PromiseResolve:u,PromisePrototypeThen:a,Symbol:F}=s0(),U=F("kEmpty"),Z=F("kEof");function Q(h,d){if(d!=null)S(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)k(d.signal,"options.signal");if(x(h)&&!j(h))throw new C("stream",h,"must be writable");let g0=M(this,h);if(d!==null&&d!==void 0&&d.signal)q(d.signal,g0);return g0}function I(h,d){if(typeof h!=="function")throw new H("fn",["Function","AsyncFunction"],h);if(d!=null)S(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)k(d.signal,"options.signal");let g0=1;if((d===null||d===void 0?void 0:d.concurrency)!=null)g0=f(d.concurrency);let Q0=g0-1;if((d===null||d===void 0?void 0:d.highWaterMark)!=null)Q0=f(d.highWaterMark);return R(g0,"options.concurrency",1),R(Q0,"options.highWaterMark",0),Q0+=g0,async function*$0(){let m=SU().AbortSignalAny([d===null||d===void 0?void 0:d.signal].filter(y)),p=this,b=[],N0={signal:m},i,e,t=!1,n=0;function X0(){t=!0,H0()}function H0(){n-=1,Z0()}function Z0(){if(e&&!t&&n<g0&&b.length<Q0)e(),e=null}async function W0(){try{for await(let c0 of p){if(t)return;if(m.aborted)throw new P;try{if(c0=h(c0,N0),c0===U)continue;c0=u(c0)}catch(G0){c0=Y0(G0)}if(n+=1,a(c0,H0,X0),b.push(c0),i)i(),i=null;if(!t&&(b.length>=Q0||n>=g0))await new V0((G0)=>{e=G0})}b.push(Z)}catch(c0){let G0=Y0(c0);a(G0,H0,X0),b.push(G0)}finally{if(t=!0,i)i(),i=null}}W0();try{while(!0){while(b.length>0){let c0=await b[0];if(c0===Z)return;if(m.aborted)throw new P;if(c0!==U)yield c0;b.shift(),Z0()}await new V0((c0)=>{i=c0})}}finally{if(t=!0,e)e(),e=null}}.call(this)}function $(h=void 0){if(h!=null)S(h,"options");if((h===null||h===void 0?void 0:h.signal)!=null)k(h.signal,"options.signal");return async function*d(){let g0=0;for await(let $0 of this){var Q0;if(h!==null&&h!==void 0&&(Q0=h.signal)!==null&&Q0!==void 0&&Q0.aborted)throw new P({cause:h.signal.reason});yield[g0++,$0]}}.call(this)}async function K(h,d=void 0){for await(let g0 of O.call(this,h,d))return!0;return!1}async function J(h,d=void 0){if(typeof h!=="function")throw new H("fn",["Function","AsyncFunction"],h);return!await K.call(this,async(...g0)=>{return!await h(...g0)},d)}async function Y(h,d){for await(let g0 of O.call(this,h,d))return g0;return}async function X(h,d){if(typeof h!=="function")throw new H("fn",["Function","AsyncFunction"],h);async function g0(Q0,$0){return await h(Q0,$0),U}for await(let Q0 of I.call(this,g0,d));}function O(h,d){if(typeof h!=="function")throw new H("fn",["Function","AsyncFunction"],h);async function g0(Q0,$0){if(await h(Q0,$0))return Q0;return U}return I.call(this,g0,d)}class v extends z{constructor(){super("reduce");this.message="Reduce of an empty stream requires an initial value"}}async function T(h,d,g0){var Q0;if(typeof h!=="function")throw new H("reducer",["Function","AsyncFunction"],h);if(g0!=null)S(g0,"options");if((g0===null||g0===void 0?void 0:g0.signal)!=null)k(g0.signal,"options.signal");let $0=arguments.length>1;if(g0!==null&&g0!==void 0&&(Q0=g0.signal)!==null&&Q0!==void 0&&Q0.aborted){let i=new P(void 0,{cause:g0.signal.reason});throw this.once("error",()=>{}),await L(this.destroy(i)),i}let m=new W,p=m.signal;if(g0!==null&&g0!==void 0&&g0.signal){let i={once:!0,[D]:this,[A]:!0};g0.signal.addEventListener("abort",()=>m.abort(),i)}let b=!1;try{for await(let i of this){var N0;if(b=!0,g0!==null&&g0!==void 0&&(N0=g0.signal)!==null&&N0!==void 0&&N0.aborted)throw new P;if(!$0)d=i,$0=!0;else d=await h(d,i,{signal:p})}if(!b&&!$0)throw new v}finally{m.abort()}return d}async function B(h){if(h!=null)S(h,"options");if((h===null||h===void 0?void 0:h.signal)!=null)k(h.signal,"options.signal");let d=[];for await(let Q0 of this){var g0;if(h!==null&&h!==void 0&&(g0=h.signal)!==null&&g0!==void 0&&g0.aborted)throw new P(void 0,{cause:h.signal.reason});N(d,Q0)}return d}function c(h,d){let g0=I.call(this,h,d);return async function*Q0(){for await(let $0 of g0)yield*$0}.call(this)}function l(h){if(h=o(h),r(h))return 0;if(h<0)throw new V("number",">= 0",h);return h}function s(h,d=void 0){if(d!=null)S(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)k(d.signal,"options.signal");return h=l(h),async function*g0(){var Q0;if(d!==null&&d!==void 0&&(Q0=d.signal)!==null&&Q0!==void 0&&Q0.aborted)throw new P;for await(let m of this){var $0;if(d!==null&&d!==void 0&&($0=d.signal)!==null&&$0!==void 0&&$0.aborted)throw new P;if(h--<=0)yield m}}.call(this)}function O0(h,d=void 0){if(d!=null)S(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)k(d.signal,"options.signal");return h=l(h),async function*g0(){var Q0;if(d!==null&&d!==void 0&&(Q0=d.signal)!==null&&Q0!==void 0&&Q0.aborted)throw new P;for await(let m of this){var $0;if(d!==null&&d!==void 0&&($0=d.signal)!==null&&$0!==void 0&&$0.aborted)throw new P;if(h-- >0)yield m;if(h<=0)return}}.call(this)}E.streamReturningOperators={asIndexedPairs:g($,"readable.asIndexedPairs will be removed in a future version."),drop:s,filter:O,flatMap:c,map:I,take:O0,compose:Q},E.promiseReturningOperators={every:J,forEach:X,reduce:T,toArray:B,some:K,find:Y}}),AZ=d0((E,G)=>{var{ArrayPrototypePop:W,Promise:C}=s0(),{isIterable:H,isNodeStream:z,isWebStream:V}=uU(),{pipelineImpl:P}=YI(),{finished:k}=nU();EZ();function R(...S){return new C((D,A)=>{let L,M,q=S[S.length-1];if(q&&typeof q==="object"&&!z(q)&&!H(q)&&!V(q)){let j=W(S);L=j.signal,M=j.end}P(S,(j,x)=>{if(j)A(j);else D(x)},{signal:L,end:M})})}G.exports={finished:k,pipeline:R}}),EZ=d0((E,G)=>{var{Buffer:W}=(HU(),y0(FU)),{ObjectDefineProperty:C,ObjectKeys:H,ReflectApply:z}=s0(),{promisify:{custom:V}}=SU(),{streamReturningOperators:P,promiseReturningOperators:k}=c$(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:R}}=MU(),S=HZ(),{setDefaultHighWaterMark:D,getDefaultHighWaterMark:A}=BX(),{pipeline:L}=YI(),{destroyer:M}=OX(),q=nU(),j=AZ(),x=uU(),g=G.exports=QI().Stream;g.isDestroyed=x.isDestroyed,g.isDisturbed=x.isDisturbed,g.isErrored=x.isErrored,g.isReadable=x.isReadable,g.isWritable=x.isWritable,g.Readable=xX();for(let y of H(P)){let f=function(...r){if(new.target)throw R();return g.Readable.from(z(o,this,r))},o=P[y];C(f,"name",{__proto__:null,value:o.name}),C(f,"length",{__proto__:null,value:o.length}),C(g.Readable.prototype,y,{__proto__:null,value:f,enumerable:!1,configurable:!0,writable:!0})}for(let y of H(k)){let f=function(...r){if(new.target)throw R();return z(o,this,r)},o=k[y];C(f,"name",{__proto__:null,value:o.name}),C(f,"length",{__proto__:null,value:o.length}),C(g.Readable.prototype,y,{__proto__:null,value:f,enumerable:!1,configurable:!0,writable:!0})}g.Writable=$I(),g.Duplex=hU(),g.Transform=JZ(),g.PassThrough=FZ(),g.pipeline=L;var{addAbortSignal:N}=jX();g.addAbortSignal=N,g.finished=q,g.destroy=M,g.compose=S,g.setDefaultHighWaterMark=D,g.getDefaultHighWaterMark=A,C(g,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return j}}),C(L,V,{__proto__:null,enumerable:!0,get(){return j.pipeline}}),C(q,V,{__proto__:null,enumerable:!0,get(){return j.finished}}),g.Stream=g,g._isUint8Array=function y(f){return f instanceof Uint8Array},g._uint8ArrayToBuffer=function y(f){return W.from(f.buffer,f.byteOffset,f.byteLength)}}),p$=d0((E,G)=>{var W=(OI(),y0(VI));if(W&&process.env.READABLE_STREAM==="disable"){let C=W.promises;G.exports._uint8ArrayToBuffer=W._uint8ArrayToBuffer,G.exports._isUint8Array=W._isUint8Array,G.exports.isDisturbed=W.isDisturbed,G.exports.isErrored=W.isErrored,G.exports.isReadable=W.isReadable,G.exports.Readable=W.Readable,G.exports.Writable=W.Writable,G.exports.Duplex=W.Duplex,G.exports.Transform=W.Transform,G.exports.PassThrough=W.PassThrough,G.exports.addAbortSignal=W.addAbortSignal,G.exports.finished=W.finished,G.exports.destroy=W.destroy,G.exports.pipeline=W.pipeline,G.exports.compose=W.compose,Object.defineProperty(W,"promises",{configurable:!0,enumerable:!0,get(){return C}}),G.exports.Stream=W.Stream}else{let C=EZ(),H=AZ(),z=C.Readable.destroy;G.exports=C.Readable,G.exports._uint8ArrayToBuffer=C._uint8ArrayToBuffer,G.exports._isUint8Array=C._isUint8Array,G.exports.isDisturbed=C.isDisturbed,G.exports.isErrored=C.isErrored,G.exports.isReadable=C.isReadable,G.exports.Readable=C.Readable,G.exports.Writable=C.Writable,G.exports.Duplex=C.Duplex,G.exports.Transform=C.Transform,G.exports.PassThrough=C.PassThrough,G.exports.addAbortSignal=C.addAbortSignal,G.exports.finished=C.finished,G.exports.destroy=C.destroy,G.exports.destroy=z,G.exports.pipeline=C.pipeline,G.exports.compose=C.compose,Object.defineProperty(C,"promises",{configurable:!0,enumerable:!0,get(){return H}}),G.exports.Stream=C.Stream}G.exports.default=G.exports}),m0=g$(p$(),1),h$=m0.default.ReadableState,u$=m0.default._fromList,l$=m0.default.from,d$=m0.default.fromWeb,b$=m0.default.toWeb,o$=m0.default.wrap,n$=m0.default._uint8ArrayToBuffer,s$=m0.default._isUint8Array,m$=m0.default.isDisturbed,t$=m0.default.isErrored,r$=m0.default.isReadable,a$=m0.default.Readable,e$=m0.default.Writable,i$=m0.default.Duplex,UY=m0.default.Transform,XY=m0.default.PassThrough,IY=m0.default.addAbortSignal,ZY=m0.default.finished,QY=m0.default.destroy,$Y=m0.default.pipeline,YY=m0.default.compose,VY=m0.default.Stream,OY=m0.default});var qU={};IX(qU,{webcrypto:()=>aV,rng:()=>FV,randomUUID:()=>mV,randomFillSync:()=>dV,randomFill:()=>lV,randomBytes:()=>wX,publicEncrypt:()=>cV,publicDecrypt:()=>hV,pseudoRandomBytes:()=>JV,prng:()=>WV,privateEncrypt:()=>pV,privateDecrypt:()=>uV,pbkdf2Sync:()=>DV,pbkdf2:()=>EI,listCiphers:()=>vV,getRandomValues:()=>sV,getHashes:()=>TV,getDiffieHellman:()=>BV,getCurves:()=>rV,getCiphers:()=>qV,createVerify:()=>wV,createSign:()=>NV,createHmac:()=>CV,createHash:()=>AV,createECDH:()=>fV,createDiffieHellmanGroup:()=>jV,createDiffieHellman:()=>xV,createDecipheriv:()=>TI,createDecipher:()=>SV,createCredentials:()=>bV,createCipheriv:()=>CI,createCipher:()=>zV,constants:()=>oV,Verify:()=>yV,Sign:()=>_V,Hmac:()=>EV,Hash:()=>HV,DiffieHellmanGroup:()=>kV,DiffieHellman:()=>gV,Decipheriv:()=>PV,Decipher:()=>RV,DEFAULT_ENCODING:()=>nV,Cipheriv:()=>MV,Cipher:()=>LV});function rV(){return tV}var GY,KY,CZ,WY,JY,FY=(E,G,W)=>{W=E!=null?GY(KY(E)):{};let C=G||!E||!E.__esModule?CZ(W,"default",{value:E,enumerable:!0}):W;for(let H of WY(E))if(!JY.call(C,H))CZ(C,H,{get:()=>E[H],enumerable:!0});return C},w0=(E,G)=>()=>(G||E((G={exports:{}}).exports,G),G.exports),gX,NX,DZ,HY,KI,WI,PU,JI,LZ,AY,zZ,EY,CY,TY,DY,lU,sU,MZ,BU,RZ,_X,LY,kU,zY,MY,RY,SZ,yU,CX,PZ,SY,qZ,PY,vZ,qY,vY,kY,jY,FI,BY,HI,xY,gY,NY,_Y,wY,yY,fY,cY,pY,hY,uY,lY,dY,bY,TZ,oY,EX,nY,kZ,jZ,sY,mY,BZ,tY,rY,TX,aY,eY,iY,UV,XV,IV,xZ,ZV,gZ,NZ,_Z,AI,wZ,QV,yZ,$V,YV,GI,VV,OV,GV,KV,h0,WV,JV,FV,wX,HV,AV,EV,CV,TV,EI,DV,LV,zV,MV,CI,RV,SV,PV,TI,qV,vV,kV,jV,BV,xV,gV,NV,_V,wV,yV,fV,cV,pV,hV,uV,lV,dV,bV,oV,nV="buffer",sV=(E)=>{return crypto.getRandomValues(E)},mV=()=>{return crypto.randomUUID()},tV,aV;var vU=ZX(()=>{GY=Object.create,{getPrototypeOf:KY,defineProperty:CZ,getOwnPropertyNames:WY}=Object,JY=Object.prototype.hasOwnProperty,gX=w0((E,G)=>{G.exports=(vU(),y0(qU)).randomBytes}),NX=w0((E,G)=>{G.exports=(vU(),y0(qU)).createHash}),DZ=w0((E,G)=>{G.exports=(vU(),y0(qU)).createHmac}),HY=w0((E,G)=>{G.exports={sha224WithRSAEncryption:{sign:"rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},"RSA-SHA224":{sign:"ecdsa/rsa",hash:"sha224",id:"302d300d06096086480165030402040500041c"},sha256WithRSAEncryption:{sign:"rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},"RSA-SHA256":{sign:"ecdsa/rsa",hash:"sha256",id:"3031300d060960864801650304020105000420"},sha384WithRSAEncryption:{sign:"rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},"RSA-SHA384":{sign:"ecdsa/rsa",hash:"sha384",id:"3041300d060960864801650304020205000430"},sha512WithRSAEncryption:{sign:"rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA512":{sign:"ecdsa/rsa",hash:"sha512",id:"3051300d060960864801650304020305000440"},"RSA-SHA1":{sign:"rsa",hash:"sha1",id:"3021300906052b0e03021a05000414"},"ecdsa-with-SHA1":{sign:"ecdsa",hash:"sha1",id:""},sha256:{sign:"ecdsa",hash:"sha256",id:""},sha224:{sign:"ecdsa",hash:"sha224",id:""},sha384:{sign:"ecdsa",hash:"sha384",id:""},sha512:{sign:"ecdsa",hash:"sha512",id:""},"DSA-SHA":{sign:"dsa",hash:"sha1",id:""},"DSA-SHA1":{sign:"dsa",hash:"sha1",id:""},DSA:{sign:"dsa",hash:"sha1",id:""},"DSA-WITH-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-SHA224":{sign:"dsa",hash:"sha224",id:""},"DSA-WITH-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-SHA256":{sign:"dsa",hash:"sha256",id:""},"DSA-WITH-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-SHA384":{sign:"dsa",hash:"sha384",id:""},"DSA-WITH-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-SHA512":{sign:"dsa",hash:"sha512",id:""},"DSA-RIPEMD160":{sign:"dsa",hash:"rmd160",id:""},ripemd160WithRSA:{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},"RSA-RIPEMD160":{sign:"rsa",hash:"rmd160",id:"3021300906052b2403020105000414"},md5WithRSAEncryption:{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"},"RSA-MD5":{sign:"rsa",hash:"md5",id:"3020300c06082a864886f70d020505000410"}}}),KI=w0((E,G)=>{var W=Math.pow(2,30)-1;G.exports=function(C,H){if(typeof C!=="number")throw new TypeError("Iterations not a number");if(C<0)throw new TypeError("Bad iterations");if(typeof H!=="number")throw new TypeError("Key length not a number");if(H<0||H>W||H!==H)throw new TypeError("Bad key length")}}),WI=w0((E,G)=>{var W;if((gU(),y0(xU))&&(gU(),y0(xU)).browser)W="utf-8";else if((gU(),y0(xU))&&(gU(),y0(xU)).version)C=parseInt(process.version.split(".")[0].slice(1),10),W=C>=6?"utf-8":"binary";else W="utf-8";var C;G.exports=W}),PU=w0((E,G)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var W=(HU(),y0(FU)),C=W.Buffer;function H(V,P){for(var k in V)P[k]=V[k]}if(C.from&&C.alloc&&C.allocUnsafe&&C.allocUnsafeSlow)G.exports=W;else H(W,E),E.Buffer=z;function z(V,P,k){return C(V,P,k)}z.prototype=Object.create(C.prototype),H(C,z),z.from=function(V,P,k){if(typeof V==="number")throw new TypeError("Argument must not be a number");return C(V,P,k)},z.alloc=function(V,P,k){if(typeof V!=="number")throw new TypeError("Argument must be a number");var R=C(V);if(P!==void 0)if(typeof k==="string")R.fill(P,k);else R.fill(P);else R.fill(0);return R},z.allocUnsafe=function(V){if(typeof V!=="number")throw new TypeError("Argument must be a number");return C(V)},z.allocUnsafeSlow=function(V){if(typeof V!=="number")throw new TypeError("Argument must be a number");return W.SlowBuffer(V)}}),JI=w0((E,G)=>{var W=PU().Buffer;G.exports=function(C,H,z){if(W.isBuffer(C))return C;else if(typeof C==="string")return W.from(C,H);else if(ArrayBuffer.isView(C))return W.from(C.buffer);else throw new TypeError(z+" must be a string, a Buffer, a typed array or a DataView")}}),LZ=w0((E,G)=>{var W={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20},C=DZ(),H=PU().Buffer,z=KI(),V=WI(),P=JI();function k(R,S,D,A,L){z(D,A),R=P(R,V,"Password"),S=P(S,V,"Salt"),L=L||"sha1";var M=H.allocUnsafe(A),q=H.allocUnsafe(S.length+4);S.copy(q,0,0,S.length);var j=0,x=W[L],g=Math.ceil(A/x);for(var N=1;N<=g;N++){q.writeUInt32BE(N,S.length);var y=C(L,R).update(q).digest(),f=y;for(var o=1;o<D;o++){f=C(L,R).update(f).digest();for(var r=0;r<x;r++)y[r]^=f[r]}y.copy(M,j),j+=x}return M}G.exports=k}),AY=w0((E,G)=>{var W=PU().Buffer,C=KI(),H=WI(),z=LZ(),V=JI(),P,k=global.crypto&&global.crypto.subtle,R={sha:"SHA-1","sha-1":"SHA-1",sha1:"SHA-1",sha256:"SHA-256","sha-256":"SHA-256",sha384:"SHA-384","sha-384":"SHA-384","sha-512":"SHA-512",sha512:"SHA-512"},S=[];function D(j){if((gU(),y0(xU))&&!(gU(),y0(xU)).browser)return Promise.resolve(!1);if(!k||!k.importKey||!k.deriveBits)return Promise.resolve(!1);if(S[j]!==void 0)return S[j];P=P||W.alloc(8);var x=M(P,P,10,128,j).then(function(){return!0}).catch(function(){return!1});return S[j]=x,x}var A;function L(){if(A)return A;if((gU(),y0(xU))&&(gU(),y0(xU)).nextTick)A=(gU(),y0(xU)).nextTick;else if(global.queueMicrotask)A=global.queueMicrotask;else if(global.setImmediate)A=global.setImmediate;else A=global.setTimeout;return A}function M(j,x,g,N,y){return k.importKey("raw",j,{name:"PBKDF2"},!1,["deriveBits"]).then(function(f){return k.deriveBits({name:"PBKDF2",salt:x,iterations:g,hash:{name:y}},f,N<<3)}).then(function(f){return W.from(f)})}function q(j,x){j.then(function(g){L()(function(){x(null,g)})},function(g){L()(function(){x(g)})})}G.exports=function(j,x,g,N,y,f){if(typeof y==="function")f=y,y=void 0;y=y||"sha1";var o=R[y.toLowerCase()];if(!o||typeof global.Promise!=="function"){L()(function(){var r;try{r=z(j,x,g,N,y)}catch(V0){return f(V0)}f(null,r)});return}if(C(g,N),j=V(j,H,"Password"),x=V(x,H,"Salt"),typeof f!=="function")throw new Error("No callback provided to pbkdf2");q(D(o).then(function(r){if(r)return M(j,x,g,N,o);return z(j,x,g,N,y)}),f)}}),zZ=w0((E)=>{var G=(vU(),y0(qU)),W=KI(),C=WI(),H=JI();function z(P,k,R,S,D,A){if(W(R,S),P=H(P,C,"Password"),k=H(k,C,"Salt"),typeof D==="function")A=D,D="sha1";if(typeof A!=="function")throw new Error("No callback provided to pbkdf2");return G.pbkdf2(P,k,R,S,D,A)}function V(P,k,R,S,D){return W(R,S),P=H(P,C,"Password"),k=H(k,C,"Salt"),D=D||"sha1",G.pbkdf2Sync(P,k,R,S,D)}if(!G.pbkdf2Sync||G.pbkdf2Sync.toString().indexOf("keylen, digest")===-1)E.pbkdf2Sync=LZ(),E.pbkdf2=AY();else E.pbkdf2Sync=V,E.pbkdf2=z}),EY=w0((E)=>{var G=(vU(),y0(qU));E.createCipher=E.Cipher=G.createCipher,E.createCipheriv=E.Cipheriv=G.createCipheriv,E.createDecipher=E.Decipher=G.createDecipher,E.createDecipheriv=E.Decipheriv=G.createDecipheriv,E.listCiphers=E.getCiphers=G.getCiphers}),CY=w0((E)=>{var G=(vU(),y0(qU));E.DiffieHellmanGroup=G.DiffieHellmanGroup,E.createDiffieHellmanGroup=G.createDiffieHellmanGroup,E.getDiffieHellman=G.getDiffieHellman,E.createDiffieHellman=G.createDiffieHellman,E.DiffieHellman=G.DiffieHellman}),TY=w0((E)=>{var G=(vU(),y0(qU));E.createSign=G.createSign,E.Sign=G.Sign,E.createVerify=G.createVerify,E.Verify=G.Verify}),DY=w0((E,G)=>{G.exports={name:"elliptic",version:"6.6.1",description:"EC cryptography",main:"lib/elliptic.js",files:["lib"],scripts:{lint:"eslint lib test","lint:fix":"npm run lint -- --fix",unit:"istanbul test _mocha --reporter=spec test/index.js",test:"npm run lint && npm run unit",version:"grunt dist && git add dist/"},repository:{type:"git",url:"git@github.com:indutny/elliptic"},keywords:["EC","Elliptic","curve","Cryptography"],author:"Fedor Indutny <fedor@indutny.com>",license:"MIT",bugs:{url:"https://github.com/indutny/elliptic/issues"},homepage:"https://github.com/indutny/elliptic",devDependencies:{brfs:"^2.0.2",coveralls:"^3.1.0",eslint:"^7.6.0",grunt:"^1.2.1","grunt-browserify":"^5.3.0","grunt-cli":"^1.3.2","grunt-contrib-connect":"^3.0.0","grunt-contrib-copy":"^1.0.0","grunt-contrib-uglify":"^5.0.0","grunt-mocha-istanbul":"^5.0.2","grunt-saucelabs":"^9.0.1",istanbul:"^0.4.5",mocha:"^8.0.1"},dependencies:{"bn.js":"^4.11.9",brorand:"^1.1.0","hash.js":"^1.0.0","hmac-drbg":"^1.0.1",inherits:"^2.0.4","minimalistic-assert":"^1.0.1","minimalistic-crypto-utils":"^1.0.1"}}}),lU=w0((E,G)=>{(function(W,C){function H(F,U){if(!F)throw new Error(U||"Assertion failed")}function z(F,U){F.super_=U;var Z=function(){};Z.prototype=U.prototype,F.prototype=new Z,F.prototype.constructor=F}function V(F,U,Z){if(V.isBN(F))return F;if(this.negative=0,this.words=null,this.length=0,this.red=null,F!==null){if(U==="le"||U==="be")Z=U,U=10;this._init(F||0,U||10,Z||"be")}}if(typeof W==="object")W.exports=V;else C.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window!=="undefined"&&typeof window.Buffer!=="undefined")P=window.Buffer;else P=(HU(),y0(FU)).Buffer}catch(F){}V.isBN=function F(U){if(U instanceof V)return!0;return U!==null&&typeof U==="object"&&U.constructor.wordSize===V.wordSize&&Array.isArray(U.words)},V.max=function F(U,Z){if(U.cmp(Z)>0)return U;return Z},V.min=function F(U,Z){if(U.cmp(Z)<0)return U;return Z},V.prototype._init=function F(U,Z,Q){if(typeof U==="number")return this._initNumber(U,Z,Q);if(typeof U==="object")return this._initArray(U,Z,Q);if(Z==="hex")Z=16;H(Z===(Z|0)&&Z>=2&&Z<=36),U=U.toString().replace(/\s+/g,"");var I=0;if(U[0]==="-")I++,this.negative=1;if(I<U.length){if(Z===16)this._parseHex(U,I,Q);else if(this._parseBase(U,Z,I),Q==="le")this._initArray(this.toArray(),Z,Q)}},V.prototype._initNumber=function F(U,Z,Q){if(U<0)this.negative=1,U=-U;if(U<67108864)this.words=[U&67108863],this.length=1;else if(U<4503599627370496)this.words=[U&67108863,U/67108864&67108863],this.length=2;else H(U<9007199254740992),this.words=[U&67108863,U/67108864&67108863,1],this.length=3;if(Q!=="le")return;this._initArray(this.toArray(),Z,Q)},V.prototype._initArray=function F(U,Z,Q){if(H(typeof U.length==="number"),U.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(U.length/3),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $,K,J=0;if(Q==="be"){for(I=U.length-1,$=0;I>=0;I-=3)if(K=U[I]|U[I-1]<<8|U[I-2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}else if(Q==="le"){for(I=0,$=0;I<U.length;I+=3)if(K=U[I]|U[I+1]<<8|U[I+2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}return this.strip()};function k(F,U){var Z=F.charCodeAt(U);if(Z>=65&&Z<=70)return Z-55;else if(Z>=97&&Z<=102)return Z-87;else return Z-48&15}function R(F,U,Z){var Q=k(F,Z);if(Z-1>=U)Q|=k(F,Z-1)<<4;return Q}V.prototype._parseHex=function F(U,Z,Q){this.length=Math.ceil((U.length-Z)/6),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $=0,K=0,J;if(Q==="be")for(I=U.length-1;I>=Z;I-=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8;else{var Y=U.length-Z;for(I=Y%2===0?Z+1:Z;I<U.length;I+=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8}this.strip()};function S(F,U,Z,Q){var I=0,$=Math.min(F.length,Z);for(var K=U;K<$;K++){var J=F.charCodeAt(K)-48;if(I*=Q,J>=49)I+=J-49+10;else if(J>=17)I+=J-17+10;else I+=J}return I}V.prototype._parseBase=function F(U,Z,Q){this.words=[0],this.length=1;for(var I=0,$=1;$<=67108863;$*=Z)I++;I--,$=$/Z|0;var K=U.length-Q,J=K%I,Y=Math.min(K,K-J)+Q,X=0;for(var O=Q;O<Y;O+=I)if(X=S(U,O,O+I,Z),this.imuln($),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(J!==0){var v=1;X=S(U,O,U.length,Z);for(O=0;O<J;O++)v*=Z;if(this.imuln(v),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function F(U){U.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)U.words[Z]=this.words[Z];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function F(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function F(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function F(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function F(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function F(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],L=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];if(V.prototype.toString=function F(U,Z){U=U||10,Z=Z|0||1;var Q;if(U===16||U==="hex"){Q="";var I=0,$=0;for(var K=0;K<this.length;K++){var J=this.words[K],Y=((J<<I|$)&16777215).toString(16);if($=J>>>24-I&16777215,I+=2,I>=26)I-=26,K--;if($!==0||K!==this.length-1)Q=D[6-Y.length]+Y+Q;else Q=Y+Q}if($!==0)Q=$.toString(16)+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}if(U===(U|0)&&U>=2&&U<=36){var X=A[U],O=L[U];Q="";var v=this.clone();v.negative=0;while(!v.isZero()){var T=v.modn(O).toString(U);if(v=v.idivn(O),!v.isZero())Q=D[X-T.length]+T+Q;else Q=T+Q}if(this.isZero())Q="0"+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function F(){var U=this.words[0];if(this.length===2)U+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)U+=4503599627370496+this.words[1]*67108864;else if(this.length>2)H(!1,"Number can only safely store up to 53 bits");return this.negative!==0?-U:U},V.prototype.toJSON=function F(){return this.toString(16)},V.prototype.toBuffer=function F(U,Z){return H(typeof P!=="undefined"),this.toArrayLike(P,U,Z)},V.prototype.toArray=function F(U,Z){return this.toArrayLike(Array,U,Z)},V.prototype.toArrayLike=function F(U,Z,Q){var I=this.byteLength(),$=Q||Math.max(1,I);H(I<=$,"byte array longer than desired length"),H($>0,"Requested array length <= 0"),this.strip();var K=Z==="le",J=new U($),Y,X,O=this.clone();if(!K){for(X=0;X<$-I;X++)J[X]=0;for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[$-X-1]=Y}else{for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[X]=Y;for(;X<$;X++)J[X]=0}return J},Math.clz32)V.prototype._countBits=function F(U){return 32-Math.clz32(U)};else V.prototype._countBits=function F(U){var Z=U,Q=0;if(Z>=4096)Q+=13,Z>>>=13;if(Z>=64)Q+=7,Z>>>=7;if(Z>=8)Q+=4,Z>>>=4;if(Z>=2)Q+=2,Z>>>=2;return Q+Z};V.prototype._zeroBits=function F(U){if(U===0)return 26;var Z=U,Q=0;if((Z&8191)===0)Q+=13,Z>>>=13;if((Z&127)===0)Q+=7,Z>>>=7;if((Z&15)===0)Q+=4,Z>>>=4;if((Z&3)===0)Q+=2,Z>>>=2;if((Z&1)===0)Q++;return Q},V.prototype.bitLength=function F(){var U=this.words[this.length-1],Z=this._countBits(U);return(this.length-1)*26+Z};function M(F){var U=new Array(F.bitLength());for(var Z=0;Z<U.length;Z++){var Q=Z/26|0,I=Z%26;U[Z]=(F.words[Q]&1<<I)>>>I}return U}V.prototype.zeroBits=function F(){if(this.isZero())return 0;var U=0;for(var Z=0;Z<this.length;Z++){var Q=this._zeroBits(this.words[Z]);if(U+=Q,Q!==26)break}return U},V.prototype.byteLength=function F(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function F(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function F(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function F(){return this.negative!==0},V.prototype.neg=function F(){return this.clone().ineg()},V.prototype.ineg=function F(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function F(U){while(this.length<U.length)this.words[this.length++]=0;for(var Z=0;Z<U.length;Z++)this.words[Z]=this.words[Z]|U.words[Z];return this.strip()},V.prototype.ior=function F(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function F(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function F(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function F(U){var Z;if(this.length>U.length)Z=U;else Z=this;for(var Q=0;Q<Z.length;Q++)this.words[Q]=this.words[Q]&U.words[Q];return this.length=Z.length,this.strip()},V.prototype.iand=function F(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function F(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function F(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function F(U){var Z,Q;if(this.length>U.length)Z=this,Q=U;else Z=U,Q=this;for(var I=0;I<Q.length;I++)this.words[I]=Z.words[I]^Q.words[I];if(this!==Z)for(;I<Z.length;I++)this.words[I]=Z.words[I];return this.length=Z.length,this.strip()},V.prototype.ixor=function F(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function F(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function F(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function F(U){H(typeof U==="number"&&U>=0);var Z=Math.ceil(U/26)|0,Q=U%26;if(this._expand(Z),Q>0)Z--;for(var I=0;I<Z;I++)this.words[I]=~this.words[I]&67108863;if(Q>0)this.words[I]=~this.words[I]&67108863>>26-Q;return this.strip()},V.prototype.notn=function F(U){return this.clone().inotn(U)},V.prototype.setn=function F(U,Z){H(typeof U==="number"&&U>=0);var Q=U/26|0,I=U%26;if(this._expand(Q+1),Z)this.words[Q]=this.words[Q]|1<<I;else this.words[Q]=this.words[Q]&~(1<<I);return this.strip()},V.prototype.iadd=function F(U){var Z;if(this.negative!==0&&U.negative===0)return this.negative=0,Z=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Z=this.isub(U),U.negative=1,Z._normSign();var Q,I;if(this.length>U.length)Q=this,I=U;else Q=U,I=this;var $=0;for(var K=0;K<I.length;K++)Z=(Q.words[K]|0)+(I.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;for(;$!==0&&K<Q.length;K++)Z=(Q.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;if(this.length=Q.length,$!==0)this.words[this.length]=$,this.length++;else if(Q!==this)for(;K<Q.length;K++)this.words[K]=Q.words[K];return this},V.prototype.add=function F(U){var Z;if(U.negative!==0&&this.negative===0)return U.negative=0,Z=this.sub(U),U.negative^=1,Z;else if(U.negative===0&&this.negative!==0)return this.negative=0,Z=U.sub(this),this.negative=1,Z;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function F(U){if(U.negative!==0){U.negative=0;var Z=this.iadd(U);return U.negative=1,Z._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var Q=this.cmp(U);if(Q===0)return this.negative=0,this.length=1,this.words[0]=0,this;var I,$;if(Q>0)I=this,$=U;else I=U,$=this;var K=0;for(var J=0;J<$.length;J++)Z=(I.words[J]|0)-($.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;for(;K!==0&&J<I.length;J++)Z=(I.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;if(K===0&&J<I.length&&I!==this)for(;J<I.length;J++)this.words[J]=I.words[J];if(this.length=Math.max(this.length,J),I!==this)this.negative=1;return this.strip()},V.prototype.sub=function F(U){return this.clone().isub(U)};function q(F,U,Z){Z.negative=U.negative^F.negative;var Q=F.length+U.length|0;Z.length=Q,Q=Q-1|0;var I=F.words[0]|0,$=U.words[0]|0,K=I*$,J=K&67108863,Y=K/67108864|0;Z.words[0]=J;for(var X=1;X<Q;X++){var O=Y>>>26,v=Y&67108863,T=Math.min(X,U.length-1);for(var B=Math.max(0,X-F.length+1);B<=T;B++){var c=X-B|0;I=F.words[c]|0,$=U.words[B]|0,K=I*$+v,O+=K/67108864|0,v=K&67108863}Z.words[X]=v|0,Y=O|0}if(Y!==0)Z.words[X]=Y|0;else Z.length--;return Z.strip()}var j=function F(U,Z,Q){var I=U.words,$=Z.words,K=Q.words,J=0,Y,X,O,v=I[0]|0,T=v&8191,B=v>>>13,c=I[1]|0,l=c&8191,s=c>>>13,O0=I[2]|0,h=O0&8191,d=O0>>>13,g0=I[3]|0,Q0=g0&8191,$0=g0>>>13,m=I[4]|0,p=m&8191,b=m>>>13,N0=I[5]|0,i=N0&8191,e=N0>>>13,t=I[6]|0,n=t&8191,X0=t>>>13,H0=I[7]|0,Z0=H0&8191,W0=H0>>>13,c0=I[8]|0,G0=c0&8191,A0=c0>>>13,u0=I[9]|0,J0=u0&8191,T0=u0>>>13,r0=$[0]|0,E0=r0&8191,v0=r0>>>13,AU=$[1]|0,k0=AU&8191,j0=AU>>>13,DU=$[2]|0,R0=DU&8191,S0=DU>>>13,LU=$[3]|0,P0=LU&8191,D0=LU>>>13,zU=$[4]|0,B0=zU&8191,L0=zU>>>13,EU=$[5]|0,_=EU&8191,w=EU>>>13,_0=$[6]|0,U0=_0&8191,I0=_0>>>13,l0=$[7]|0,F0=l0&8191,C0=l0>>>13,CU=$[8]|0,x0=CU&8191,q0=CU>>>13,TU=$[9]|0,z0=TU&8191,M0=TU>>>13;Q.negative=U.negative^Z.negative,Q.length=19,Y=Math.imul(T,E0),X=Math.imul(T,v0),X=X+Math.imul(B,E0)|0,O=Math.imul(B,v0);var t0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(t0>>>26)|0,t0&=67108863,Y=Math.imul(l,E0),X=Math.imul(l,v0),X=X+Math.imul(s,E0)|0,O=Math.imul(s,v0),Y=Y+Math.imul(T,k0)|0,X=X+Math.imul(T,j0)|0,X=X+Math.imul(B,k0)|0,O=O+Math.imul(B,j0)|0;var p0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(p0>>>26)|0,p0&=67108863,Y=Math.imul(h,E0),X=Math.imul(h,v0),X=X+Math.imul(d,E0)|0,O=Math.imul(d,v0),Y=Y+Math.imul(l,k0)|0,X=X+Math.imul(l,j0)|0,X=X+Math.imul(s,k0)|0,O=O+Math.imul(s,j0)|0,Y=Y+Math.imul(T,R0)|0,X=X+Math.imul(T,S0)|0,X=X+Math.imul(B,R0)|0,O=O+Math.imul(B,S0)|0;var f0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(f0>>>26)|0,f0&=67108863,Y=Math.imul(Q0,E0),X=Math.imul(Q0,v0),X=X+Math.imul($0,E0)|0,O=Math.imul($0,v0),Y=Y+Math.imul(h,k0)|0,X=X+Math.imul(h,j0)|0,X=X+Math.imul(d,k0)|0,O=O+Math.imul(d,j0)|0,Y=Y+Math.imul(l,R0)|0,X=X+Math.imul(l,S0)|0,X=X+Math.imul(s,R0)|0,O=O+Math.imul(s,S0)|0,Y=Y+Math.imul(T,P0)|0,X=X+Math.imul(T,D0)|0,X=X+Math.imul(B,P0)|0,O=O+Math.imul(B,D0)|0;var b0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,Y=Math.imul(p,E0),X=Math.imul(p,v0),X=X+Math.imul(b,E0)|0,O=Math.imul(b,v0),Y=Y+Math.imul(Q0,k0)|0,X=X+Math.imul(Q0,j0)|0,X=X+Math.imul($0,k0)|0,O=O+Math.imul($0,j0)|0,Y=Y+Math.imul(h,R0)|0,X=X+Math.imul(h,S0)|0,X=X+Math.imul(d,R0)|0,O=O+Math.imul(d,S0)|0,Y=Y+Math.imul(l,P0)|0,X=X+Math.imul(l,D0)|0,X=X+Math.imul(s,P0)|0,O=O+Math.imul(s,D0)|0,Y=Y+Math.imul(T,B0)|0,X=X+Math.imul(T,L0)|0,X=X+Math.imul(B,B0)|0,O=O+Math.imul(B,L0)|0;var a0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,Y=Math.imul(i,E0),X=Math.imul(i,v0),X=X+Math.imul(e,E0)|0,O=Math.imul(e,v0),Y=Y+Math.imul(p,k0)|0,X=X+Math.imul(p,j0)|0,X=X+Math.imul(b,k0)|0,O=O+Math.imul(b,j0)|0,Y=Y+Math.imul(Q0,R0)|0,X=X+Math.imul(Q0,S0)|0,X=X+Math.imul($0,R0)|0,O=O+Math.imul($0,S0)|0,Y=Y+Math.imul(h,P0)|0,X=X+Math.imul(h,D0)|0,X=X+Math.imul(d,P0)|0,O=O+Math.imul(d,D0)|0,Y=Y+Math.imul(l,B0)|0,X=X+Math.imul(l,L0)|0,X=X+Math.imul(s,B0)|0,O=O+Math.imul(s,L0)|0,Y=Y+Math.imul(T,_)|0,X=X+Math.imul(T,w)|0,X=X+Math.imul(B,_)|0,O=O+Math.imul(B,w)|0;var e0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,Y=Math.imul(n,E0),X=Math.imul(n,v0),X=X+Math.imul(X0,E0)|0,O=Math.imul(X0,v0),Y=Y+Math.imul(i,k0)|0,X=X+Math.imul(i,j0)|0,X=X+Math.imul(e,k0)|0,O=O+Math.imul(e,j0)|0,Y=Y+Math.imul(p,R0)|0,X=X+Math.imul(p,S0)|0,X=X+Math.imul(b,R0)|0,O=O+Math.imul(b,S0)|0,Y=Y+Math.imul(Q0,P0)|0,X=X+Math.imul(Q0,D0)|0,X=X+Math.imul($0,P0)|0,O=O+Math.imul($0,D0)|0,Y=Y+Math.imul(h,B0)|0,X=X+Math.imul(h,L0)|0,X=X+Math.imul(d,B0)|0,O=O+Math.imul(d,L0)|0,Y=Y+Math.imul(l,_)|0,X=X+Math.imul(l,w)|0,X=X+Math.imul(s,_)|0,O=O+Math.imul(s,w)|0,Y=Y+Math.imul(T,U0)|0,X=X+Math.imul(T,I0)|0,X=X+Math.imul(B,U0)|0,O=O+Math.imul(B,I0)|0;var i0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,Y=Math.imul(Z0,E0),X=Math.imul(Z0,v0),X=X+Math.imul(W0,E0)|0,O=Math.imul(W0,v0),Y=Y+Math.imul(n,k0)|0,X=X+Math.imul(n,j0)|0,X=X+Math.imul(X0,k0)|0,O=O+Math.imul(X0,j0)|0,Y=Y+Math.imul(i,R0)|0,X=X+Math.imul(i,S0)|0,X=X+Math.imul(e,R0)|0,O=O+Math.imul(e,S0)|0,Y=Y+Math.imul(p,P0)|0,X=X+Math.imul(p,D0)|0,X=X+Math.imul(b,P0)|0,O=O+Math.imul(b,D0)|0,Y=Y+Math.imul(Q0,B0)|0,X=X+Math.imul(Q0,L0)|0,X=X+Math.imul($0,B0)|0,O=O+Math.imul($0,L0)|0,Y=Y+Math.imul(h,_)|0,X=X+Math.imul(h,w)|0,X=X+Math.imul(d,_)|0,O=O+Math.imul(d,w)|0,Y=Y+Math.imul(l,U0)|0,X=X+Math.imul(l,I0)|0,X=X+Math.imul(s,U0)|0,O=O+Math.imul(s,I0)|0,Y=Y+Math.imul(T,F0)|0,X=X+Math.imul(T,C0)|0,X=X+Math.imul(B,F0)|0,O=O+Math.imul(B,C0)|0;var UU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,Y=Math.imul(G0,E0),X=Math.imul(G0,v0),X=X+Math.imul(A0,E0)|0,O=Math.imul(A0,v0),Y=Y+Math.imul(Z0,k0)|0,X=X+Math.imul(Z0,j0)|0,X=X+Math.imul(W0,k0)|0,O=O+Math.imul(W0,j0)|0,Y=Y+Math.imul(n,R0)|0,X=X+Math.imul(n,S0)|0,X=X+Math.imul(X0,R0)|0,O=O+Math.imul(X0,S0)|0,Y=Y+Math.imul(i,P0)|0,X=X+Math.imul(i,D0)|0,X=X+Math.imul(e,P0)|0,O=O+Math.imul(e,D0)|0,Y=Y+Math.imul(p,B0)|0,X=X+Math.imul(p,L0)|0,X=X+Math.imul(b,B0)|0,O=O+Math.imul(b,L0)|0,Y=Y+Math.imul(Q0,_)|0,X=X+Math.imul(Q0,w)|0,X=X+Math.imul($0,_)|0,O=O+Math.imul($0,w)|0,Y=Y+Math.imul(h,U0)|0,X=X+Math.imul(h,I0)|0,X=X+Math.imul(d,U0)|0,O=O+Math.imul(d,I0)|0,Y=Y+Math.imul(l,F0)|0,X=X+Math.imul(l,C0)|0,X=X+Math.imul(s,F0)|0,O=O+Math.imul(s,C0)|0,Y=Y+Math.imul(T,x0)|0,X=X+Math.imul(T,q0)|0,X=X+Math.imul(B,x0)|0,O=O+Math.imul(B,q0)|0;var XU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,Y=Math.imul(J0,E0),X=Math.imul(J0,v0),X=X+Math.imul(T0,E0)|0,O=Math.imul(T0,v0),Y=Y+Math.imul(G0,k0)|0,X=X+Math.imul(G0,j0)|0,X=X+Math.imul(A0,k0)|0,O=O+Math.imul(A0,j0)|0,Y=Y+Math.imul(Z0,R0)|0,X=X+Math.imul(Z0,S0)|0,X=X+Math.imul(W0,R0)|0,O=O+Math.imul(W0,S0)|0,Y=Y+Math.imul(n,P0)|0,X=X+Math.imul(n,D0)|0,X=X+Math.imul(X0,P0)|0,O=O+Math.imul(X0,D0)|0,Y=Y+Math.imul(i,B0)|0,X=X+Math.imul(i,L0)|0,X=X+Math.imul(e,B0)|0,O=O+Math.imul(e,L0)|0,Y=Y+Math.imul(p,_)|0,X=X+Math.imul(p,w)|0,X=X+Math.imul(b,_)|0,O=O+Math.imul(b,w)|0,Y=Y+Math.imul(Q0,U0)|0,X=X+Math.imul(Q0,I0)|0,X=X+Math.imul($0,U0)|0,O=O+Math.imul($0,I0)|0,Y=Y+Math.imul(h,F0)|0,X=X+Math.imul(h,C0)|0,X=X+Math.imul(d,F0)|0,O=O+Math.imul(d,C0)|0,Y=Y+Math.imul(l,x0)|0,X=X+Math.imul(l,q0)|0,X=X+Math.imul(s,x0)|0,O=O+Math.imul(s,q0)|0,Y=Y+Math.imul(T,z0)|0,X=X+Math.imul(T,M0)|0,X=X+Math.imul(B,z0)|0,O=O+Math.imul(B,M0)|0;var IU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,Y=Math.imul(J0,k0),X=Math.imul(J0,j0),X=X+Math.imul(T0,k0)|0,O=Math.imul(T0,j0),Y=Y+Math.imul(G0,R0)|0,X=X+Math.imul(G0,S0)|0,X=X+Math.imul(A0,R0)|0,O=O+Math.imul(A0,S0)|0,Y=Y+Math.imul(Z0,P0)|0,X=X+Math.imul(Z0,D0)|0,X=X+Math.imul(W0,P0)|0,O=O+Math.imul(W0,D0)|0,Y=Y+Math.imul(n,B0)|0,X=X+Math.imul(n,L0)|0,X=X+Math.imul(X0,B0)|0,O=O+Math.imul(X0,L0)|0,Y=Y+Math.imul(i,_)|0,X=X+Math.imul(i,w)|0,X=X+Math.imul(e,_)|0,O=O+Math.imul(e,w)|0,Y=Y+Math.imul(p,U0)|0,X=X+Math.imul(p,I0)|0,X=X+Math.imul(b,U0)|0,O=O+Math.imul(b,I0)|0,Y=Y+Math.imul(Q0,F0)|0,X=X+Math.imul(Q0,C0)|0,X=X+Math.imul($0,F0)|0,O=O+Math.imul($0,C0)|0,Y=Y+Math.imul(h,x0)|0,X=X+Math.imul(h,q0)|0,X=X+Math.imul(d,x0)|0,O=O+Math.imul(d,q0)|0,Y=Y+Math.imul(l,z0)|0,X=X+Math.imul(l,M0)|0,X=X+Math.imul(s,z0)|0,O=O+Math.imul(s,M0)|0;var ZU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,Y=Math.imul(J0,R0),X=Math.imul(J0,S0),X=X+Math.imul(T0,R0)|0,O=Math.imul(T0,S0),Y=Y+Math.imul(G0,P0)|0,X=X+Math.imul(G0,D0)|0,X=X+Math.imul(A0,P0)|0,O=O+Math.imul(A0,D0)|0,Y=Y+Math.imul(Z0,B0)|0,X=X+Math.imul(Z0,L0)|0,X=X+Math.imul(W0,B0)|0,O=O+Math.imul(W0,L0)|0,Y=Y+Math.imul(n,_)|0,X=X+Math.imul(n,w)|0,X=X+Math.imul(X0,_)|0,O=O+Math.imul(X0,w)|0,Y=Y+Math.imul(i,U0)|0,X=X+Math.imul(i,I0)|0,X=X+Math.imul(e,U0)|0,O=O+Math.imul(e,I0)|0,Y=Y+Math.imul(p,F0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(b,F0)|0,O=O+Math.imul(b,C0)|0,Y=Y+Math.imul(Q0,x0)|0,X=X+Math.imul(Q0,q0)|0,X=X+Math.imul($0,x0)|0,O=O+Math.imul($0,q0)|0,Y=Y+Math.imul(h,z0)|0,X=X+Math.imul(h,M0)|0,X=X+Math.imul(d,z0)|0,O=O+Math.imul(d,M0)|0;var QU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,Y=Math.imul(J0,P0),X=Math.imul(J0,D0),X=X+Math.imul(T0,P0)|0,O=Math.imul(T0,D0),Y=Y+Math.imul(G0,B0)|0,X=X+Math.imul(G0,L0)|0,X=X+Math.imul(A0,B0)|0,O=O+Math.imul(A0,L0)|0,Y=Y+Math.imul(Z0,_)|0,X=X+Math.imul(Z0,w)|0,X=X+Math.imul(W0,_)|0,O=O+Math.imul(W0,w)|0,Y=Y+Math.imul(n,U0)|0,X=X+Math.imul(n,I0)|0,X=X+Math.imul(X0,U0)|0,O=O+Math.imul(X0,I0)|0,Y=Y+Math.imul(i,F0)|0,X=X+Math.imul(i,C0)|0,X=X+Math.imul(e,F0)|0,O=O+Math.imul(e,C0)|0,Y=Y+Math.imul(p,x0)|0,X=X+Math.imul(p,q0)|0,X=X+Math.imul(b,x0)|0,O=O+Math.imul(b,q0)|0,Y=Y+Math.imul(Q0,z0)|0,X=X+Math.imul(Q0,M0)|0,X=X+Math.imul($0,z0)|0,O=O+Math.imul($0,M0)|0;var $U=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,Y=Math.imul(J0,B0),X=Math.imul(J0,L0),X=X+Math.imul(T0,B0)|0,O=Math.imul(T0,L0),Y=Y+Math.imul(G0,_)|0,X=X+Math.imul(G0,w)|0,X=X+Math.imul(A0,_)|0,O=O+Math.imul(A0,w)|0,Y=Y+Math.imul(Z0,U0)|0,X=X+Math.imul(Z0,I0)|0,X=X+Math.imul(W0,U0)|0,O=O+Math.imul(W0,I0)|0,Y=Y+Math.imul(n,F0)|0,X=X+Math.imul(n,C0)|0,X=X+Math.imul(X0,F0)|0,O=O+Math.imul(X0,C0)|0,Y=Y+Math.imul(i,x0)|0,X=X+Math.imul(i,q0)|0,X=X+Math.imul(e,x0)|0,O=O+Math.imul(e,q0)|0,Y=Y+Math.imul(p,z0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(b,z0)|0,O=O+Math.imul(b,M0)|0;var YU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,Y=Math.imul(J0,_),X=Math.imul(J0,w),X=X+Math.imul(T0,_)|0,O=Math.imul(T0,w),Y=Y+Math.imul(G0,U0)|0,X=X+Math.imul(G0,I0)|0,X=X+Math.imul(A0,U0)|0,O=O+Math.imul(A0,I0)|0,Y=Y+Math.imul(Z0,F0)|0,X=X+Math.imul(Z0,C0)|0,X=X+Math.imul(W0,F0)|0,O=O+Math.imul(W0,C0)|0,Y=Y+Math.imul(n,x0)|0,X=X+Math.imul(n,q0)|0,X=X+Math.imul(X0,x0)|0,O=O+Math.imul(X0,q0)|0,Y=Y+Math.imul(i,z0)|0,X=X+Math.imul(i,M0)|0,X=X+Math.imul(e,z0)|0,O=O+Math.imul(e,M0)|0;var VU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,Y=Math.imul(J0,U0),X=Math.imul(J0,I0),X=X+Math.imul(T0,U0)|0,O=Math.imul(T0,I0),Y=Y+Math.imul(G0,F0)|0,X=X+Math.imul(G0,C0)|0,X=X+Math.imul(A0,F0)|0,O=O+Math.imul(A0,C0)|0,Y=Y+Math.imul(Z0,x0)|0,X=X+Math.imul(Z0,q0)|0,X=X+Math.imul(W0,x0)|0,O=O+Math.imul(W0,q0)|0,Y=Y+Math.imul(n,z0)|0,X=X+Math.imul(n,M0)|0,X=X+Math.imul(X0,z0)|0,O=O+Math.imul(X0,M0)|0;var OU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(OU>>>26)|0,OU&=67108863,Y=Math.imul(J0,F0),X=Math.imul(J0,C0),X=X+Math.imul(T0,F0)|0,O=Math.imul(T0,C0),Y=Y+Math.imul(G0,x0)|0,X=X+Math.imul(G0,q0)|0,X=X+Math.imul(A0,x0)|0,O=O+Math.imul(A0,q0)|0,Y=Y+Math.imul(Z0,z0)|0,X=X+Math.imul(Z0,M0)|0,X=X+Math.imul(W0,z0)|0,O=O+Math.imul(W0,M0)|0;var GU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,Y=Math.imul(J0,x0),X=Math.imul(J0,q0),X=X+Math.imul(T0,x0)|0,O=Math.imul(T0,q0),Y=Y+Math.imul(G0,z0)|0,X=X+Math.imul(G0,M0)|0,X=X+Math.imul(A0,z0)|0,O=O+Math.imul(A0,M0)|0;var KU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(KU>>>26)|0,KU&=67108863,Y=Math.imul(J0,z0),X=Math.imul(J0,M0),X=X+Math.imul(T0,z0)|0,O=Math.imul(T0,M0);var WU=(J+Y|0)+((X&8191)<<13)|0;if(J=(O+(X>>>13)|0)+(WU>>>26)|0,WU&=67108863,K[0]=t0,K[1]=p0,K[2]=f0,K[3]=b0,K[4]=a0,K[5]=e0,K[6]=i0,K[7]=UU,K[8]=XU,K[9]=IU,K[10]=ZU,K[11]=QU,K[12]=$U,K[13]=YU,K[14]=VU,K[15]=OU,K[16]=GU,K[17]=KU,K[18]=WU,J!==0)K[19]=J,Q.length++;return Q};if(!Math.imul)j=q;function x(F,U,Z){Z.negative=U.negative^F.negative,Z.length=F.length+U.length;var Q=0,I=0;for(var $=0;$<Z.length-1;$++){var K=I;I=0;var J=Q&67108863,Y=Math.min($,U.length-1);for(var X=Math.max(0,$-F.length+1);X<=Y;X++){var O=$-X,v=F.words[O]|0,T=U.words[X]|0,B=v*T,c=B&67108863;K=K+(B/67108864|0)|0,c=c+J|0,J=c&67108863,K=K+(c>>>26)|0,I+=K>>>26,K&=67108863}Z.words[$]=J,Q=K,K=I}if(Q!==0)Z.words[$]=Q;else Z.length--;return Z.strip()}function g(F,U,Z){var Q=new N;return Q.mulp(F,U,Z)}V.prototype.mulTo=function F(U,Z){var Q,I=this.length+U.length;if(this.length===10&&U.length===10)Q=j(this,U,Z);else if(I<63)Q=q(this,U,Z);else if(I<1024)Q=x(this,U,Z);else Q=g(this,U,Z);return Q};function N(F,U){this.x=F,this.y=U}N.prototype.makeRBT=function F(U){var Z=new Array(U),Q=V.prototype._countBits(U)-1;for(var I=0;I<U;I++)Z[I]=this.revBin(I,Q,U);return Z},N.prototype.revBin=function F(U,Z,Q){if(U===0||U===Q-1)return U;var I=0;for(var $=0;$<Z;$++)I|=(U&1)<<Z-$-1,U>>=1;return I},N.prototype.permute=function F(U,Z,Q,I,$,K){for(var J=0;J<K;J++)I[J]=Z[U[J]],$[J]=Q[U[J]]},N.prototype.transform=function F(U,Z,Q,I,$,K){this.permute(K,U,Z,Q,I,$);for(var J=1;J<$;J<<=1){var Y=J<<1,X=Math.cos(2*Math.PI/Y),O=Math.sin(2*Math.PI/Y);for(var v=0;v<$;v+=Y){var T=X,B=O;for(var c=0;c<J;c++){var l=Q[v+c],s=I[v+c],O0=Q[v+c+J],h=I[v+c+J],d=T*O0-B*h;if(h=T*h+B*O0,O0=d,Q[v+c]=l+O0,I[v+c]=s+h,Q[v+c+J]=l-O0,I[v+c+J]=s-h,c!==Y)d=X*T-O*B,B=X*B+O*T,T=d}}}},N.prototype.guessLen13b=function F(U,Z){var Q=Math.max(Z,U)|1,I=Q&1,$=0;for(Q=Q/2|0;Q;Q=Q>>>1)$++;return 1<<$+1+I},N.prototype.conjugate=function F(U,Z,Q){if(Q<=1)return;for(var I=0;I<Q/2;I++){var $=U[I];U[I]=U[Q-I-1],U[Q-I-1]=$,$=Z[I],Z[I]=-Z[Q-I-1],Z[Q-I-1]=-$}},N.prototype.normalize13b=function F(U,Z){var Q=0;for(var I=0;I<Z/2;I++){var $=Math.round(U[2*I+1]/Z)*8192+Math.round(U[2*I]/Z)+Q;if(U[I]=$&67108863,$<67108864)Q=0;else Q=$/67108864|0}return U},N.prototype.convert13b=function F(U,Z,Q,I){var $=0;for(var K=0;K<Z;K++)$=$+(U[K]|0),Q[2*K]=$&8191,$=$>>>13,Q[2*K+1]=$&8191,$=$>>>13;for(K=2*Z;K<I;++K)Q[K]=0;H($===0),H(($&-8192)===0)},N.prototype.stub=function F(U){var Z=new Array(U);for(var Q=0;Q<U;Q++)Z[Q]=0;return Z},N.prototype.mulp=function F(U,Z,Q){var I=2*this.guessLen13b(U.length,Z.length),$=this.makeRBT(I),K=this.stub(I),J=new Array(I),Y=new Array(I),X=new Array(I),O=new Array(I),v=new Array(I),T=new Array(I),B=Q.words;B.length=I,this.convert13b(U.words,U.length,J,I),this.convert13b(Z.words,Z.length,O,I),this.transform(J,K,Y,X,I,$),this.transform(O,K,v,T,I,$);for(var c=0;c<I;c++){var l=Y[c]*v[c]-X[c]*T[c];X[c]=Y[c]*T[c]+X[c]*v[c],Y[c]=l}return this.conjugate(Y,X,I),this.transform(Y,X,B,K,I,$),this.conjugate(B,K,I),this.normalize13b(B,I),Q.negative=U.negative^Z.negative,Q.length=U.length+Z.length,Q.strip()},V.prototype.mul=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),this.mulTo(U,Z)},V.prototype.mulf=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),g(this,U,Z)},V.prototype.imul=function F(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function F(U){H(typeof U==="number"),H(U<67108864);var Z=0;for(var Q=0;Q<this.length;Q++){var I=(this.words[Q]|0)*U,$=(I&67108863)+(Z&67108863);Z>>=26,Z+=I/67108864|0,Z+=$>>>26,this.words[Q]=$&67108863}if(Z!==0)this.words[Q]=Z,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function F(U){return this.clone().imuln(U)},V.prototype.sqr=function F(){return this.mul(this)},V.prototype.isqr=function F(){return this.imul(this.clone())},V.prototype.pow=function F(U){var Z=M(U);if(Z.length===0)return new V(1);var Q=this;for(var I=0;I<Z.length;I++,Q=Q.sqr())if(Z[I]!==0)break;if(++I<Z.length)for(var $=Q.sqr();I<Z.length;I++,$=$.sqr()){if(Z[I]===0)continue;Q=Q.mul($)}return Q},V.prototype.iushln=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=67108863>>>26-Z<<26-Z,$;if(Z!==0){var K=0;for($=0;$<this.length;$++){var J=this.words[$]&I,Y=(this.words[$]|0)-J<<Z;this.words[$]=Y|K,K=J>>>26-Z}if(K)this.words[$]=K,this.length++}if(Q!==0){for($=this.length-1;$>=0;$--)this.words[$+Q]=this.words[$];for($=0;$<Q;$++)this.words[$]=0;this.length+=Q}return this.strip()},V.prototype.ishln=function F(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function F(U,Z,Q){H(typeof U==="number"&&U>=0);var I;if(Z)I=(Z-Z%26)/26;else I=0;var $=U%26,K=Math.min((U-$)/26,this.length),J=67108863^67108863>>>$<<$,Y=Q;if(I-=K,I=Math.max(0,I),Y){for(var X=0;X<K;X++)Y.words[X]=this.words[X];Y.length=K}if(K===0);else if(this.length>K){this.length-=K;for(X=0;X<this.length;X++)this.words[X]=this.words[X+K]}else this.words[0]=0,this.length=1;var O=0;for(X=this.length-1;X>=0&&(O!==0||X>=I);X--){var v=this.words[X]|0;this.words[X]=O<<26-$|v>>>$,O=v&J}if(Y&&O!==0)Y.words[Y.length++]=O;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function F(U,Z,Q){return H(this.negative===0),this.iushrn(U,Z,Q)},V.prototype.shln=function F(U){return this.clone().ishln(U)},V.prototype.ushln=function F(U){return this.clone().iushln(U)},V.prototype.shrn=function F(U){return this.clone().ishrn(U)},V.prototype.ushrn=function F(U){return this.clone().iushrn(U)},V.prototype.testn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return!1;var $=this.words[Q];return!!($&I)},V.prototype.imaskn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=Q)return this;if(Z!==0)Q++;if(this.length=Math.min(Q,this.length),Z!==0){var I=67108863^67108863>>>Z<<Z;this.words[this.length-1]&=I}return this.strip()},V.prototype.maskn=function F(U){return this.clone().imaskn(U)},V.prototype.iaddn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.isubn(-U);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<U)return this.words[0]=U-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(U),this.negative=1,this}return this._iaddn(U)},V.prototype._iaddn=function F(U){this.words[0]+=U;for(var Z=0;Z<this.length&&this.words[Z]>=67108864;Z++)if(this.words[Z]-=67108864,Z===this.length-1)this.words[Z+1]=1;else this.words[Z+1]++;return this.length=Math.max(this.length,Z+1),this},V.prototype.isubn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.iaddn(-U);if(this.negative!==0)return this.negative=0,this.iaddn(U),this.negative=1,this;if(this.words[0]-=U,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Z=0;Z<this.length&&this.words[Z]<0;Z++)this.words[Z]+=67108864,this.words[Z+1]-=1;return this.strip()},V.prototype.addn=function F(U){return this.clone().iaddn(U)},V.prototype.subn=function F(U){return this.clone().isubn(U)},V.prototype.iabs=function F(){return this.negative=0,this},V.prototype.abs=function F(){return this.clone().iabs()},V.prototype._ishlnsubmul=function F(U,Z,Q){var I=U.length+Q,$;this._expand(I);var K,J=0;for($=0;$<U.length;$++){K=(this.words[$+Q]|0)+J;var Y=(U.words[$]|0)*Z;K-=Y&67108863,J=(K>>26)-(Y/67108864|0),this.words[$+Q]=K&67108863}for(;$<this.length-Q;$++)K=(this.words[$+Q]|0)+J,J=K>>26,this.words[$+Q]=K&67108863;if(J===0)return this.strip();H(J===-1),J=0;for($=0;$<this.length;$++)K=-(this.words[$]|0)+J,J=K>>26,this.words[$]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function F(U,Z){var Q=this.length-U.length,I=this.clone(),$=U,K=$.words[$.length-1]|0,J=this._countBits(K);if(Q=26-J,Q!==0)$=$.ushln(Q),I.iushln(Q),K=$.words[$.length-1]|0;var Y=I.length-$.length,X;if(Z!=="mod"){X=new V(null),X.length=Y+1,X.words=new Array(X.length);for(var O=0;O<X.length;O++)X.words[O]=0}var v=I.clone()._ishlnsubmul($,1,Y);if(v.negative===0){if(I=v,X)X.words[Y]=1}for(var T=Y-1;T>=0;T--){var B=(I.words[$.length+T]|0)*67108864+(I.words[$.length+T-1]|0);B=Math.min(B/K|0,67108863),I._ishlnsubmul($,B,T);while(I.negative!==0)if(B--,I.negative=0,I._ishlnsubmul($,1,T),!I.isZero())I.negative^=1;if(X)X.words[T]=B}if(X)X.strip();if(I.strip(),Z!=="div"&&Q!==0)I.iushrn(Q);return{div:X||null,mod:I}},V.prototype.divmod=function F(U,Z,Q){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var I,$,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Z),Z!=="mod")I=K.div.neg();if(Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.iadd(U)}return{div:I,mod:$}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Z),Z!=="mod")I=K.div.neg();return{div:I,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Z),Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.isub(U)}return{div:K.div,mod:$}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Z==="div")return{div:this.divn(U.words[0]),mod:null};if(Z==="mod")return{div:null,mod:new V(this.modn(U.words[0]))};return{div:this.divn(U.words[0]),mod:new V(this.modn(U.words[0]))}}return this._wordDiv(U,Z)},V.prototype.div=function F(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function F(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function F(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function F(U){var Z=this.divmod(U);if(Z.mod.isZero())return Z.div;var Q=Z.div.negative!==0?Z.mod.isub(U):Z.mod,I=U.ushrn(1),$=U.andln(1),K=Q.cmp(I);if(K<0||$===1&&K===0)return Z.div;return Z.div.negative!==0?Z.div.isubn(1):Z.div.iaddn(1)},V.prototype.modn=function F(U){H(U<=67108863);var Z=67108864%U,Q=0;for(var I=this.length-1;I>=0;I--)Q=(Z*Q+(this.words[I]|0))%U;return Q},V.prototype.idivn=function F(U){H(U<=67108863);var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=(this.words[Q]|0)+Z*67108864;this.words[Q]=I/U|0,Z=I%U}return this.strip()},V.prototype.divn=function F(U){return this.clone().idivn(U)},V.prototype.egcd=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=new V(0),J=new V(1),Y=0;while(Z.isEven()&&Q.isEven())Z.iushrn(1),Q.iushrn(1),++Y;var X=Q.clone(),O=Z.clone();while(!Z.isZero()){for(var v=0,T=1;(Z.words[0]&T)===0&&v<26;++v,T<<=1);if(v>0){Z.iushrn(v);while(v-- >0){if(I.isOdd()||$.isOdd())I.iadd(X),$.isub(O);I.iushrn(1),$.iushrn(1)}}for(var B=0,c=1;(Q.words[0]&c)===0&&B<26;++B,c<<=1);if(B>0){Q.iushrn(B);while(B-- >0){if(K.isOdd()||J.isOdd())K.iadd(X),J.isub(O);K.iushrn(1),J.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub(K),$.isub(J);else Q.isub(Z),K.isub(I),J.isub($)}return{a:K,b:J,gcd:Q.iushln(Y)}},V.prototype._invmp=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=Q.clone();while(Z.cmpn(1)>0&&Q.cmpn(1)>0){for(var J=0,Y=1;(Z.words[0]&Y)===0&&J<26;++J,Y<<=1);if(J>0){Z.iushrn(J);while(J-- >0){if(I.isOdd())I.iadd(K);I.iushrn(1)}}for(var X=0,O=1;(Q.words[0]&O)===0&&X<26;++X,O<<=1);if(X>0){Q.iushrn(X);while(X-- >0){if($.isOdd())$.iadd(K);$.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub($);else Q.isub(Z),$.isub(I)}var v;if(Z.cmpn(1)===0)v=I;else v=$;if(v.cmpn(0)<0)v.iadd(U);return v},V.prototype.gcd=function F(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Z=this.clone(),Q=U.clone();Z.negative=0,Q.negative=0;for(var I=0;Z.isEven()&&Q.isEven();I++)Z.iushrn(1),Q.iushrn(1);do{while(Z.isEven())Z.iushrn(1);while(Q.isEven())Q.iushrn(1);var $=Z.cmp(Q);if($<0){var K=Z;Z=Q,Q=K}else if($===0||Q.cmpn(1)===0)break;Z.isub(Q)}while(!0);return Q.iushln(I)},V.prototype.invm=function F(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function F(){return(this.words[0]&1)===0},V.prototype.isOdd=function F(){return(this.words[0]&1)===1},V.prototype.andln=function F(U){return this.words[0]&U},V.prototype.bincn=function F(U){H(typeof U==="number");var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return this._expand(Q+1),this.words[Q]|=I,this;var $=I;for(var K=Q;$!==0&&K<this.length;K++){var J=this.words[K]|0;J+=$,$=J>>>26,J&=67108863,this.words[K]=J}if($!==0)this.words[K]=$,this.length++;return this},V.prototype.isZero=function F(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function F(U){var Z=U<0;if(this.negative!==0&&!Z)return-1;if(this.negative===0&&Z)return 1;this.strip();var Q;if(this.length>1)Q=1;else{if(Z)U=-U;H(U<=67108863,"Number is too big");var I=this.words[0]|0;Q=I===U?0:I<U?-1:1}if(this.negative!==0)return-Q|0;return Q},V.prototype.cmp=function F(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Z=this.ucmp(U);if(this.negative!==0)return-Z|0;return Z},V.prototype.ucmp=function F(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=this.words[Q]|0,$=U.words[Q]|0;if(I===$)continue;if(I<$)Z=-1;else if(I>$)Z=1;break}return Z},V.prototype.gtn=function F(U){return this.cmpn(U)===1},V.prototype.gt=function F(U){return this.cmp(U)===1},V.prototype.gten=function F(U){return this.cmpn(U)>=0},V.prototype.gte=function F(U){return this.cmp(U)>=0},V.prototype.ltn=function F(U){return this.cmpn(U)===-1},V.prototype.lt=function F(U){return this.cmp(U)===-1},V.prototype.lten=function F(U){return this.cmpn(U)<=0},V.prototype.lte=function F(U){return this.cmp(U)<=0},V.prototype.eqn=function F(U){return this.cmpn(U)===0},V.prototype.eq=function F(U){return this.cmp(U)===0},V.red=function F(U){return new u(U)},V.prototype.toRed=function F(U){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),U.convertTo(this)._forceRed(U)},V.prototype.fromRed=function F(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function F(U){return this.red=U,this},V.prototype.forceRed=function F(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function F(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function F(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function F(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function F(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function F(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.mul(this,U)},V.prototype.redIMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.imul(this,U)},V.prototype.redSqr=function F(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function F(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function F(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function F(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function F(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function F(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var y={k256:null,p224:null,p192:null,p25519:null};function f(F,U){this.name=F,this.p=new V(U,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}f.prototype._tmp=function F(){var U=new V(null);return U.words=new Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function F(U){var Z=U,Q;do this.split(Z,this.tmp),Z=this.imulK(Z),Z=Z.iadd(this.tmp),Q=Z.bitLength();while(Q>this.n);var I=Q<this.n?-1:Z.ucmp(this.p);if(I===0)Z.words[0]=0,Z.length=1;else if(I>0)Z.isub(this.p);else if(Z.strip!==void 0)Z.strip();else Z._strip();return Z},f.prototype.split=function F(U,Z){U.iushrn(this.n,0,Z)},f.prototype.imulK=function F(U){return U.imul(this.k)};function o(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}z(o,f),o.prototype.split=function F(U,Z){var Q=4194303,I=Math.min(U.length,9);for(var $=0;$<I;$++)Z.words[$]=U.words[$];if(Z.length=I,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Z.words[Z.length++]=K&Q;for($=10;$<U.length;$++){var J=U.words[$]|0;U.words[$-10]=(J&Q)<<4|K>>>22,K=J}if(K>>>=22,U.words[$-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},o.prototype.imulK=function F(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Z=0;for(var Q=0;Q<U.length;Q++){var I=U.words[Q]|0;Z+=I*977,U.words[Q]=Z&67108863,Z=I*64+(Z/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function r(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}z(r,f);function V0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}z(V0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}z(Y0,f),Y0.prototype.imulK=function F(U){var Z=0;for(var Q=0;Q<U.length;Q++){var I=(U.words[Q]|0)*19+Z,$=I&67108863;I>>>=26,U.words[Q]=$,Z=I}if(Z!==0)U.words[U.length++]=Z;return U},V._prime=function F(U){if(y[U])return y[U];var Z;if(U==="k256")Z=new o;else if(U==="p224")Z=new r;else if(U==="p192")Z=new V0;else if(U==="p25519")Z=new Y0;else throw new Error("Unknown prime "+U);return y[U]=Z,Z};function u(F){if(typeof F==="string"){var U=V._prime(F);this.m=U.p,this.prime=U}else H(F.gtn(1),"modulus must be greater than 1"),this.m=F,this.prime=null}u.prototype._verify1=function F(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function F(U,Z){H((U.negative|Z.negative)===0,"red works only with positives"),H(U.red&&U.red===Z.red,"red works only with red numbers")},u.prototype.imod=function F(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function F(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function F(U,Z){this._verify2(U,Z);var Q=U.add(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q._forceRed(this)},u.prototype.iadd=function F(U,Z){this._verify2(U,Z);var Q=U.iadd(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q},u.prototype.sub=function F(U,Z){this._verify2(U,Z);var Q=U.sub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q._forceRed(this)},u.prototype.isub=function F(U,Z){this._verify2(U,Z);var Q=U.isub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q},u.prototype.shl=function F(U,Z){return this._verify1(U),this.imod(U.ushln(Z))},u.prototype.imul=function F(U,Z){return this._verify2(U,Z),this.imod(U.imul(Z))},u.prototype.mul=function F(U,Z){return this._verify2(U,Z),this.imod(U.mul(Z))},u.prototype.isqr=function F(U){return this.imul(U,U.clone())},u.prototype.sqr=function F(U){return this.mul(U,U)},u.prototype.sqrt=function F(U){if(U.isZero())return U.clone();var Z=this.m.andln(3);if(H(Z%2===1),Z===3){var Q=this.m.add(new V(1)).iushrn(2);return this.pow(U,Q)}var I=this.m.subn(1),$=0;while(!I.isZero()&&I.andln(1)===0)$++,I.iushrn(1);H(!I.isZero());var K=new V(1).toRed(this),J=K.redNeg(),Y=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,Y).cmp(J)!==0)X.redIAdd(J);var O=this.pow(X,I),v=this.pow(U,I.addn(1).iushrn(1)),T=this.pow(U,I),B=$;while(T.cmp(K)!==0){var c=T;for(var l=0;c.cmp(K)!==0;l++)c=c.redSqr();H(l<B);var s=this.pow(O,new V(1).iushln(B-l-1));v=v.redMul(s),O=s.redSqr(),T=T.redMul(O),B=l}return v},u.prototype.invm=function F(U){var Z=U._invmp(this.m);if(Z.negative!==0)return Z.negative=0,this.imod(Z).redNeg();else return this.imod(Z)},u.prototype.pow=function F(U,Z){if(Z.isZero())return new V(1).toRed(this);if(Z.cmpn(1)===0)return U.clone();var Q=4,I=new Array(1<<Q);I[0]=new V(1).toRed(this),I[1]=U;for(var $=2;$<I.length;$++)I[$]=this.mul(I[$-1],U);var K=I[0],J=0,Y=0,X=Z.bitLength()%26;if(X===0)X=26;for($=Z.length-1;$>=0;$--){var O=Z.words[$];for(var v=X-1;v>=0;v--){var T=O>>v&1;if(K!==I[0])K=this.sqr(K);if(T===0&&J===0){Y=0;continue}if(J<<=1,J|=T,Y++,Y!==Q&&($!==0||v!==0))continue;K=this.mul(K,I[J]),Y=0,J=0}X=26}return K},u.prototype.convertTo=function F(U){var Z=U.umod(this.m);return Z===U?Z.clone():Z},u.prototype.convertFrom=function F(U){var Z=U.clone();return Z.red=null,Z},V.mont=function F(U){return new a(U)};function a(F){if(u.call(this,F),this.shift=this.m.bitLength(),this.shift%26!==0)this.shift+=26-this.shift%26;this.r=new V(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}z(a,u),a.prototype.convertTo=function F(U){return this.imod(U.ushln(this.shift))},a.prototype.convertFrom=function F(U){var Z=this.imod(U.mul(this.rinv));return Z.red=null,Z},a.prototype.imul=function F(U,Z){if(U.isZero()||Z.isZero())return U.words[0]=0,U.length=1,U;var Q=U.imul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.mul=function F(U,Z){if(U.isZero()||Z.isZero())return new V(0)._forceRed(this);var Q=U.mul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.invm=function F(U){var Z=this.imod(U._invmp(this.m).mul(this.r2));return Z._forceRed(this)}})(typeof G==="undefined"||G,E)}),sU=w0((E,G)=>{G.exports=W;function W(C,H){if(!C)throw new Error(H||"Assertion failed")}W.equal=function C(H,z,V){if(H!=z)throw new Error(V||"Assertion failed: "+H+" != "+z)}}),MZ=w0((E)=>{var G=E;function W(z,V){if(Array.isArray(z))return z.slice();if(!z)return[];var P=[];if(typeof z!=="string"){for(var k=0;k<z.length;k++)P[k]=z[k]|0;return P}if(V==="hex"){if(z=z.replace(/[^a-z0-9]+/ig,""),z.length%2!==0)z="0"+z;for(var k=0;k<z.length;k+=2)P.push(parseInt(z[k]+z[k+1],16))}else for(var k=0;k<z.length;k++){var R=z.charCodeAt(k),S=R>>8,D=R&255;if(S)P.push(S,D);else P.push(D)}return P}G.toArray=W;function C(z){if(z.length===1)return"0"+z;else return z}G.zero2=C;function H(z){var V="";for(var P=0;P<z.length;P++)V+=C(z[P].toString(16));return V}G.toHex=H,G.encode=function z(V,P){if(P==="hex")return H(V);else return V}}),BU=w0((E)=>{var G=E,W=lU(),C=sU(),H=MZ();G.assert=C,G.toArray=H.toArray,G.zero2=H.zero2,G.toHex=H.toHex,G.encode=H.encode;function z(S,D,A){var L=new Array(Math.max(S.bitLength(),A)+1),M;for(M=0;M<L.length;M+=1)L[M]=0;var q=1<<D+1,j=S.clone();for(M=0;M<L.length;M++){var x,g=j.andln(q-1);if(j.isOdd()){if(g>(q>>1)-1)x=(q>>1)-g;else x=g;j.isubn(x)}else x=0;L[M]=x,j.iushrn(1)}return L}G.getNAF=z;function V(S,D){var A=[[],[]];S=S.clone(),D=D.clone();var L=0,M=0,q;while(S.cmpn(-L)>0||D.cmpn(-M)>0){var j=S.andln(3)+L&3,x=D.andln(3)+M&3;if(j===3)j=-1;if(x===3)x=-1;var g;if((j&1)===0)g=0;else if(q=S.andln(7)+L&7,(q===3||q===5)&&x===2)g=-j;else g=j;A[0].push(g);var N;if((x&1)===0)N=0;else if(q=D.andln(7)+M&7,(q===3||q===5)&&j===2)N=-x;else N=x;if(A[1].push(N),2*L===g+1)L=1-L;if(2*M===N+1)M=1-M;S.iushrn(1),D.iushrn(1)}return A}G.getJSF=V;function P(S,D,A){var L="_"+D;S.prototype[D]=function M(){return this[L]!==void 0?this[L]:this[L]=A.call(this)}}G.cachedProperty=P;function k(S){return typeof S==="string"?G.toArray(S,"hex"):S}G.parseBytes=k;function R(S){return new W(S,"hex","le")}G.intFromLE=R}),RZ=w0((E,G)=>{var W;G.exports=function z(V){if(!W)W=new C(null);return W.generate(V)};function C(z){this.rand=z}if(G.exports.Rand=C,C.prototype.generate=function z(V){return this._rand(V)},C.prototype._rand=function z(V){if(this.rand.getBytes)return this.rand.getBytes(V);var P=new Uint8Array(V);for(var k=0;k<P.length;k++)P[k]=this.rand.getByte();return P},typeof self==="object"){if(self.crypto&&self.crypto.getRandomValues)C.prototype._rand=function z(V){var P=new Uint8Array(V);return self.crypto.getRandomValues(P),P};else if(self.msCrypto&&self.msCrypto.getRandomValues)C.prototype._rand=function z(V){var P=new Uint8Array(V);return self.msCrypto.getRandomValues(P),P};else if(typeof window==="object")C.prototype._rand=function(){throw new Error("Not implemented yet")}}else try{if(H=(vU(),y0(qU)),typeof H.randomBytes!=="function")throw new Error("Not supported");C.prototype._rand=function z(V){return H.randomBytes(V)}}catch(z){}var H}),_X=w0((E,G)=>{var W=lU(),C=BU(),H=C.getNAF,z=C.getJSF,V=C.assert;function P(R,S){this.type=R,this.p=new W(S.p,16),this.red=S.prime?W.red(S.prime):W.mont(this.p),this.zero=new W(0).toRed(this.red),this.one=new W(1).toRed(this.red),this.two=new W(2).toRed(this.red),this.n=S.n&&new W(S.n,16),this.g=S.g&&this.pointFromJSON(S.g,S.gRed),this._wnafT1=new Array(4),this._wnafT2=new Array(4),this._wnafT3=new Array(4),this._wnafT4=new Array(4),this._bitLength=this.n?this.n.bitLength():0;var D=this.n&&this.p.div(this.n);if(!D||D.cmpn(100)>0)this.redN=null;else this._maxwellTrick=!0,this.redN=this.n.toRed(this.red)}G.exports=P,P.prototype.point=function R(){throw new Error("Not implemented")},P.prototype.validate=function R(){throw new Error("Not implemented")},P.prototype._fixedNafMul=function R(S,D){V(S.precomputed);var A=S._getDoubles(),L=H(D,1,this._bitLength),M=(1<<A.step+1)-(A.step%2===0?2:1);M/=3;var q=[],j,x;for(j=0;j<L.length;j+=A.step){x=0;for(var g=j+A.step-1;g>=j;g--)x=(x<<1)+L[g];q.push(x)}var N=this.jpoint(null,null,null),y=this.jpoint(null,null,null);for(var f=M;f>0;f--){for(j=0;j<q.length;j++)if(x=q[j],x===f)y=y.mixedAdd(A.points[j]);else if(x===-f)y=y.mixedAdd(A.points[j].neg());N=N.add(y)}return N.toP()},P.prototype._wnafMul=function R(S,D){var A=4,L=S._getNAFPoints(A);A=L.wnd;var M=L.points,q=H(D,A,this._bitLength),j=this.jpoint(null,null,null);for(var x=q.length-1;x>=0;x--){for(var g=0;x>=0&&q[x]===0;x--)g++;if(x>=0)g++;if(j=j.dblp(g),x<0)break;var N=q[x];if(V(N!==0),S.type==="affine")if(N>0)j=j.mixedAdd(M[N-1>>1]);else j=j.mixedAdd(M[-N-1>>1].neg());else if(N>0)j=j.add(M[N-1>>1]);else j=j.add(M[-N-1>>1].neg())}return S.type==="affine"?j.toP():j},P.prototype._wnafMulAdd=function R(S,D,A,L,M){var q=this._wnafT1,j=this._wnafT2,x=this._wnafT3,g=0,N,y,f;for(N=0;N<L;N++){f=D[N];var o=f._getNAFPoints(S);q[N]=o.wnd,j[N]=o.points}for(N=L-1;N>=1;N-=2){var r=N-1,V0=N;if(q[r]!==1||q[V0]!==1){x[r]=H(A[r],q[r],this._bitLength),x[V0]=H(A[V0],q[V0],this._bitLength),g=Math.max(x[r].length,g),g=Math.max(x[V0].length,g);continue}var Y0=[D[r],null,null,D[V0]];if(D[r].y.cmp(D[V0].y)===0)Y0[1]=D[r].add(D[V0]),Y0[2]=D[r].toJ().mixedAdd(D[V0].neg());else if(D[r].y.cmp(D[V0].y.redNeg())===0)Y0[1]=D[r].toJ().mixedAdd(D[V0]),Y0[2]=D[r].add(D[V0].neg());else Y0[1]=D[r].toJ().mixedAdd(D[V0]),Y0[2]=D[r].toJ().mixedAdd(D[V0].neg());var u=[-3,-1,-5,-7,0,7,5,1,3],a=z(A[r],A[V0]);g=Math.max(a[0].length,g),x[r]=new Array(g),x[V0]=new Array(g);for(y=0;y<g;y++){var F=a[0][y]|0,U=a[1][y]|0;x[r][y]=u[(F+1)*3+(U+1)],x[V0][y]=0,j[r]=Y0}}var Z=this.jpoint(null,null,null),Q=this._wnafT4;for(N=g;N>=0;N--){var I=0;while(N>=0){var $=!0;for(y=0;y<L;y++)if(Q[y]=x[y][N]|0,Q[y]!==0)$=!1;if(!$)break;I++,N--}if(N>=0)I++;if(Z=Z.dblp(I),N<0)break;for(y=0;y<L;y++){var K=Q[y];if(K===0)continue;else if(K>0)f=j[y][K-1>>1];else if(K<0)f=j[y][-K-1>>1].neg();if(f.type==="affine")Z=Z.mixedAdd(f);else Z=Z.add(f)}}for(N=0;N<L;N++)j[N]=null;if(M)return Z;else return Z.toP()};function k(R,S){this.curve=R,this.type=S,this.precomputed=null}P.BasePoint=k,k.prototype.eq=function R(){throw new Error("Not implemented")},k.prototype.validate=function R(){return this.curve.validate(this)},P.prototype.decodePoint=function R(S,D){S=C.toArray(S,D);var A=this.p.byteLength();if((S[0]===4||S[0]===6||S[0]===7)&&S.length-1===2*A){if(S[0]===6)V(S[S.length-1]%2===0);else if(S[0]===7)V(S[S.length-1]%2===1);var L=this.point(S.slice(1,1+A),S.slice(1+A,1+2*A));return L}else if((S[0]===2||S[0]===3)&&S.length-1===A)return this.pointFromX(S.slice(1,1+A),S[0]===3);throw new Error("Unknown point format")},k.prototype.encodeCompressed=function R(S){return this.encode(S,!0)},k.prototype._encode=function R(S){var D=this.curve.p.byteLength(),A=this.getX().toArray("be",D);if(S)return[this.getY().isEven()?2:3].concat(A);return[4].concat(A,this.getY().toArray("be",D))},k.prototype.encode=function R(S,D){return C.encode(this._encode(D),S)},k.prototype.precompute=function R(S){if(this.precomputed)return this;var D={doubles:null,naf:null,beta:null};return D.naf=this._getNAFPoints(8),D.doubles=this._getDoubles(4,S),D.beta=this._getBeta(),this.precomputed=D,this},k.prototype._hasDoubles=function R(S){if(!this.precomputed)return!1;var D=this.precomputed.doubles;if(!D)return!1;return D.points.length>=Math.ceil((S.bitLength()+1)/D.step)},k.prototype._getDoubles=function R(S,D){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;var A=[this],L=this;for(var M=0;M<D;M+=S){for(var q=0;q<S;q++)L=L.dbl();A.push(L)}return{step:S,points:A}},k.prototype._getNAFPoints=function R(S){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;var D=[this],A=(1<<S)-1,L=A===1?null:this.dbl();for(var M=1;M<A;M++)D[M]=D[M-1].add(L);return{wnd:S,points:D}},k.prototype._getBeta=function R(){return null},k.prototype.dblp=function R(S){var D=this;for(var A=0;A<S;A++)D=D.dbl();return D}}),LY=w0((E,G)=>{if(typeof Object.create==="function")G.exports=function W(C,H){if(H)C.super_=H,C.prototype=Object.create(H.prototype,{constructor:{value:C,enumerable:!1,writable:!0,configurable:!0}})};else G.exports=function W(C,H){if(H){C.super_=H;var z=function(){};z.prototype=H.prototype,C.prototype=new z,C.prototype.constructor=C}}}),kU=w0((E,G)=>{try{if(W=(sI(),y0(nI)),typeof W.inherits!=="function")throw"";G.exports=W.inherits}catch(C){G.exports=LY()}var W}),zY=w0((E,G)=>{var W=BU(),C=lU(),H=kU(),z=_X(),V=W.assert;function P(S){z.call(this,"short",S),this.a=new C(S.a,16).toRed(this.red),this.b=new C(S.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=this.a.fromRed().cmpn(0)===0,this.threeA=this.a.fromRed().sub(this.p).cmpn(-3)===0,this.endo=this._getEndomorphism(S),this._endoWnafT1=new Array(4),this._endoWnafT2=new Array(4)}H(P,z),G.exports=P,P.prototype._getEndomorphism=function S(D){if(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)return;var A,L;if(D.beta)A=new C(D.beta,16).toRed(this.red);else{var M=this._getEndoRoots(this.p);A=M[0].cmp(M[1])<0?M[0]:M[1],A=A.toRed(this.red)}if(D.lambda)L=new C(D.lambda,16);else{var q=this._getEndoRoots(this.n);if(this.g.mul(q[0]).x.cmp(this.g.x.redMul(A))===0)L=q[0];else L=q[1],V(this.g.mul(L).x.cmp(this.g.x.redMul(A))===0)}var j;if(D.basis)j=D.basis.map(function(x){return{a:new C(x.a,16),b:new C(x.b,16)}});else j=this._getEndoBasis(L);return{beta:A,lambda:L,basis:j}},P.prototype._getEndoRoots=function S(D){var A=D===this.p?this.red:C.mont(D),L=new C(2).toRed(A).redInvm(),M=L.redNeg(),q=new C(3).toRed(A).redNeg().redSqrt().redMul(L),j=M.redAdd(q).fromRed(),x=M.redSub(q).fromRed();return[j,x]},P.prototype._getEndoBasis=function S(D){var A=this.n.ushrn(Math.floor(this.n.bitLength()/2)),L=D,M=this.n.clone(),q=new C(1),j=new C(0),x=new C(0),g=new C(1),N,y,f,o,r,V0,Y0,u=0,a,F;while(L.cmpn(0)!==0){var U=M.div(L);a=M.sub(U.mul(L)),F=x.sub(U.mul(q));var Z=g.sub(U.mul(j));if(!f&&a.cmp(A)<0)N=Y0.neg(),y=q,f=a.neg(),o=F;else if(f&&++u===2)break;Y0=a,M=L,L=a,x=q,q=F,g=j,j=Z}r=a.neg(),V0=F;var Q=f.sqr().add(o.sqr()),I=r.sqr().add(V0.sqr());if(I.cmp(Q)>=0)r=N,V0=y;if(f.negative)f=f.neg(),o=o.neg();if(r.negative)r=r.neg(),V0=V0.neg();return[{a:f,b:o},{a:r,b:V0}]},P.prototype._endoSplit=function S(D){var A=this.endo.basis,L=A[0],M=A[1],q=M.b.mul(D).divRound(this.n),j=L.b.neg().mul(D).divRound(this.n),x=q.mul(L.a),g=j.mul(M.a),N=q.mul(L.b),y=j.mul(M.b),f=D.sub(x).sub(g),o=N.add(y).neg();return{k1:f,k2:o}},P.prototype.pointFromX=function S(D,A){if(D=new C(D,16),!D.red)D=D.toRed(this.red);var L=D.redSqr().redMul(D).redIAdd(D.redMul(this.a)).redIAdd(this.b),M=L.redSqrt();if(M.redSqr().redSub(L).cmp(this.zero)!==0)throw new Error("invalid point");var q=M.fromRed().isOdd();if(A&&!q||!A&&q)M=M.redNeg();return this.point(D,M)},P.prototype.validate=function S(D){if(D.inf)return!0;var{x:A,y:L}=D,M=this.a.redMul(A),q=A.redSqr().redMul(A).redIAdd(M).redIAdd(this.b);return L.redSqr().redISub(q).cmpn(0)===0},P.prototype._endoWnafMulAdd=function S(D,A,L){var M=this._endoWnafT1,q=this._endoWnafT2;for(var j=0;j<D.length;j++){var x=this._endoSplit(A[j]),g=D[j],N=g._getBeta();if(x.k1.negative)x.k1.ineg(),g=g.neg(!0);if(x.k2.negative)x.k2.ineg(),N=N.neg(!0);M[j*2]=g,M[j*2+1]=N,q[j*2]=x.k1,q[j*2+1]=x.k2}var y=this._wnafMulAdd(1,M,q,j*2,L);for(var f=0;f<j*2;f++)M[f]=null,q[f]=null;return y};function k(S,D,A,L){if(z.BasePoint.call(this,S,"affine"),D===null&&A===null)this.x=null,this.y=null,this.inf=!0;else{if(this.x=new C(D,16),this.y=new C(A,16),L)this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red);if(!this.x.red)this.x=this.x.toRed(this.curve.red);if(!this.y.red)this.y=this.y.toRed(this.curve.red);this.inf=!1}}H(k,z.BasePoint),P.prototype.point=function S(D,A,L){return new k(this,D,A,L)},P.prototype.pointFromJSON=function S(D,A){return k.fromJSON(this,D,A)},k.prototype._getBeta=function S(){if(!this.curve.endo)return;var D=this.precomputed;if(D&&D.beta)return D.beta;var A=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(D){var L=this.curve,M=function(q){return L.point(q.x.redMul(L.endo.beta),q.y)};D.beta=A,A.precomputed={beta:null,naf:D.naf&&{wnd:D.naf.wnd,points:D.naf.points.map(M)},doubles:D.doubles&&{step:D.doubles.step,points:D.doubles.points.map(M)}}}return A},k.prototype.toJSON=function S(){if(!this.precomputed)return[this.x,this.y];return[this.x,this.y,this.precomputed&&{doubles:this.precomputed.doubles&&{step:this.precomputed.doubles.step,points:this.precomputed.doubles.points.slice(1)},naf:this.precomputed.naf&&{wnd:this.precomputed.naf.wnd,points:this.precomputed.naf.points.slice(1)}}]},k.fromJSON=function S(D,A,L){if(typeof A==="string")A=JSON.parse(A);var M=D.point(A[0],A[1],L);if(!A[2])return M;function q(x){return D.point(x[0],x[1],L)}var j=A[2];return M.precomputed={beta:null,doubles:j.doubles&&{step:j.doubles.step,points:[M].concat(j.doubles.points.map(q))},naf:j.naf&&{wnd:j.naf.wnd,points:[M].concat(j.naf.points.map(q))}},M},k.prototype.inspect=function S(){if(this.isInfinity())return"<EC Point Infinity>";return"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},k.prototype.isInfinity=function S(){return this.inf},k.prototype.add=function S(D){if(this.inf)return D;if(D.inf)return this;if(this.eq(D))return this.dbl();if(this.neg().eq(D))return this.curve.point(null,null);if(this.x.cmp(D.x)===0)return this.curve.point(null,null);var A=this.y.redSub(D.y);if(A.cmpn(0)!==0)A=A.redMul(this.x.redSub(D.x).redInvm());var L=A.redSqr().redISub(this.x).redISub(D.x),M=A.redMul(this.x.redSub(L)).redISub(this.y);return this.curve.point(L,M)},k.prototype.dbl=function S(){if(this.inf)return this;var D=this.y.redAdd(this.y);if(D.cmpn(0)===0)return this.curve.point(null,null);var A=this.curve.a,L=this.x.redSqr(),M=D.redInvm(),q=L.redAdd(L).redIAdd(L).redIAdd(A).redMul(M),j=q.redSqr().redISub(this.x.redAdd(this.x)),x=q.redMul(this.x.redSub(j)).redISub(this.y);return this.curve.point(j,x)},k.prototype.getX=function S(){return this.x.fromRed()},k.prototype.getY=function S(){return this.y.fromRed()},k.prototype.mul=function S(D){if(D=new C(D,16),this.isInfinity())return this;else if(this._hasDoubles(D))return this.curve._fixedNafMul(this,D);else if(this.curve.endo)return this.curve._endoWnafMulAdd([this],[D]);else return this.curve._wnafMul(this,D)},k.prototype.mulAdd=function S(D,A,L){var M=[this,A],q=[D,L];if(this.curve.endo)return this.curve._endoWnafMulAdd(M,q);else return this.curve._wnafMulAdd(1,M,q,2)},k.prototype.jmulAdd=function S(D,A,L){var M=[this,A],q=[D,L];if(this.curve.endo)return this.curve._endoWnafMulAdd(M,q,!0);else return this.curve._wnafMulAdd(1,M,q,2,!0)},k.prototype.eq=function S(D){return this===D||this.inf===D.inf&&(this.inf||this.x.cmp(D.x)===0&&this.y.cmp(D.y)===0)},k.prototype.neg=function S(D){if(this.inf)return this;var A=this.curve.point(this.x,this.y.redNeg());if(D&&this.precomputed){var L=this.precomputed,M=function(q){return q.neg()};A.precomputed={naf:L.naf&&{wnd:L.naf.wnd,points:L.naf.points.map(M)},doubles:L.doubles&&{step:L.doubles.step,points:L.doubles.points.map(M)}}}return A},k.prototype.toJ=function S(){if(this.inf)return this.curve.jpoint(null,null,null);var D=this.curve.jpoint(this.x,this.y,this.curve.one);return D};function R(S,D,A,L){if(z.BasePoint.call(this,S,"jacobian"),D===null&&A===null&&L===null)this.x=this.curve.one,this.y=this.curve.one,this.z=new C(0);else this.x=new C(D,16),this.y=new C(A,16),this.z=new C(L,16);if(!this.x.red)this.x=this.x.toRed(this.curve.red);if(!this.y.red)this.y=this.y.toRed(this.curve.red);if(!this.z.red)this.z=this.z.toRed(this.curve.red);this.zOne=this.z===this.curve.one}H(R,z.BasePoint),P.prototype.jpoint=function S(D,A,L){return new R(this,D,A,L)},R.prototype.toP=function S(){if(this.isInfinity())return this.curve.point(null,null);var D=this.z.redInvm(),A=D.redSqr(),L=this.x.redMul(A),M=this.y.redMul(A).redMul(D);return this.curve.point(L,M)},R.prototype.neg=function S(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},R.prototype.add=function S(D){if(this.isInfinity())return D;if(D.isInfinity())return this;var A=D.z.redSqr(),L=this.z.redSqr(),M=this.x.redMul(A),q=D.x.redMul(L),j=this.y.redMul(A.redMul(D.z)),x=D.y.redMul(L.redMul(this.z)),g=M.redSub(q),N=j.redSub(x);if(g.cmpn(0)===0)if(N.cmpn(0)!==0)return this.curve.jpoint(null,null,null);else return this.dbl();var y=g.redSqr(),f=y.redMul(g),o=M.redMul(y),r=N.redSqr().redIAdd(f).redISub(o).redISub(o),V0=N.redMul(o.redISub(r)).redISub(j.redMul(f)),Y0=this.z.redMul(D.z).redMul(g);return this.curve.jpoint(r,V0,Y0)},R.prototype.mixedAdd=function S(D){if(this.isInfinity())return D.toJ();if(D.isInfinity())return this;var A=this.z.redSqr(),L=this.x,M=D.x.redMul(A),q=this.y,j=D.y.redMul(A).redMul(this.z),x=L.redSub(M),g=q.redSub(j);if(x.cmpn(0)===0)if(g.cmpn(0)!==0)return this.curve.jpoint(null,null,null);else return this.dbl();var N=x.redSqr(),y=N.redMul(x),f=L.redMul(N),o=g.redSqr().redIAdd(y).redISub(f).redISub(f),r=g.redMul(f.redISub(o)).redISub(q.redMul(y)),V0=this.z.redMul(x);return this.curve.jpoint(o,r,V0)},R.prototype.dblp=function S(D){if(D===0)return this;if(this.isInfinity())return this;if(!D)return this.dbl();var A;if(this.curve.zeroA||this.curve.threeA){var L=this;for(A=0;A<D;A++)L=L.dbl();return L}var M=this.curve.a,q=this.curve.tinv,j=this.x,x=this.y,g=this.z,N=g.redSqr().redSqr(),y=x.redAdd(x);for(A=0;A<D;A++){var f=j.redSqr(),o=y.redSqr(),r=o.redSqr(),V0=f.redAdd(f).redIAdd(f).redIAdd(M.redMul(N)),Y0=j.redMul(o),u=V0.redSqr().redISub(Y0.redAdd(Y0)),a=Y0.redISub(u),F=V0.redMul(a);F=F.redIAdd(F).redISub(r);var U=y.redMul(g);if(A+1<D)N=N.redMul(r);j=u,g=U,y=F}return this.curve.jpoint(j,y.redMul(q),g)},R.prototype.dbl=function S(){if(this.isInfinity())return this;if(this.curve.zeroA)return this._zeroDbl();else if(this.curve.threeA)return this._threeDbl();else return this._dbl()},R.prototype._zeroDbl=function S(){var D,A,L;if(this.zOne){var M=this.x.redSqr(),q=this.y.redSqr(),j=q.redSqr(),x=this.x.redAdd(q).redSqr().redISub(M).redISub(j);x=x.redIAdd(x);var g=M.redAdd(M).redIAdd(M),N=g.redSqr().redISub(x).redISub(x),y=j.redIAdd(j);y=y.redIAdd(y),y=y.redIAdd(y),D=N,A=g.redMul(x.redISub(N)).redISub(y),L=this.y.redAdd(this.y)}else{var f=this.x.redSqr(),o=this.y.redSqr(),r=o.redSqr(),V0=this.x.redAdd(o).redSqr().redISub(f).redISub(r);V0=V0.redIAdd(V0);var Y0=f.redAdd(f).redIAdd(f),u=Y0.redSqr(),a=r.redIAdd(r);a=a.redIAdd(a),a=a.redIAdd(a),D=u.redISub(V0).redISub(V0),A=Y0.redMul(V0.redISub(D)).redISub(a),L=this.y.redMul(this.z),L=L.redIAdd(L)}return this.curve.jpoint(D,A,L)},R.prototype._threeDbl=function S(){var D,A,L;if(this.zOne){var M=this.x.redSqr(),q=this.y.redSqr(),j=q.redSqr(),x=this.x.redAdd(q).redSqr().redISub(M).redISub(j);x=x.redIAdd(x);var g=M.redAdd(M).redIAdd(M).redIAdd(this.curve.a),N=g.redSqr().redISub(x).redISub(x);D=N;var y=j.redIAdd(j);y=y.redIAdd(y),y=y.redIAdd(y),A=g.redMul(x.redISub(N)).redISub(y),L=this.y.redAdd(this.y)}else{var f=this.z.redSqr(),o=this.y.redSqr(),r=this.x.redMul(o),V0=this.x.redSub(f).redMul(this.x.redAdd(f));V0=V0.redAdd(V0).redIAdd(V0);var Y0=r.redIAdd(r);Y0=Y0.redIAdd(Y0);var u=Y0.redAdd(Y0);D=V0.redSqr().redISub(u),L=this.y.redAdd(this.z).redSqr().redISub(o).redISub(f);var a=o.redSqr();a=a.redIAdd(a),a=a.redIAdd(a),a=a.redIAdd(a),A=V0.redMul(Y0.redISub(D)).redISub(a)}return this.curve.jpoint(D,A,L)},R.prototype._dbl=function S(){var D=this.curve.a,A=this.x,L=this.y,M=this.z,q=M.redSqr().redSqr(),j=A.redSqr(),x=L.redSqr(),g=j.redAdd(j).redIAdd(j).redIAdd(D.redMul(q)),N=A.redAdd(A);N=N.redIAdd(N);var y=N.redMul(x),f=g.redSqr().redISub(y.redAdd(y)),o=y.redISub(f),r=x.redSqr();r=r.redIAdd(r),r=r.redIAdd(r),r=r.redIAdd(r);var V0=g.redMul(o).redISub(r),Y0=L.redAdd(L).redMul(M);return this.curve.jpoint(f,V0,Y0)},R.prototype.trpl=function S(){if(!this.curve.zeroA)return this.dbl().add(this);var D=this.x.redSqr(),A=this.y.redSqr(),L=this.z.redSqr(),M=A.redSqr(),q=D.redAdd(D).redIAdd(D),j=q.redSqr(),x=this.x.redAdd(A).redSqr().redISub(D).redISub(M);x=x.redIAdd(x),x=x.redAdd(x).redIAdd(x),x=x.redISub(j);var g=x.redSqr(),N=M.redIAdd(M);N=N.redIAdd(N),N=N.redIAdd(N),N=N.redIAdd(N);var y=q.redIAdd(x).redSqr().redISub(j).redISub(g).redISub(N),f=A.redMul(y);f=f.redIAdd(f),f=f.redIAdd(f);var o=this.x.redMul(g).redISub(f);o=o.redIAdd(o),o=o.redIAdd(o);var r=this.y.redMul(y.redMul(N.redISub(y)).redISub(x.redMul(g)));r=r.redIAdd(r),r=r.redIAdd(r),r=r.redIAdd(r);var V0=this.z.redAdd(x).redSqr().redISub(L).redISub(g);return this.curve.jpoint(o,r,V0)},R.prototype.mul=function S(D,A){return D=new C(D,A),this.curve._wnafMul(this,D)},R.prototype.eq=function S(D){if(D.type==="affine")return this.eq(D.toJ());if(this===D)return!0;var A=this.z.redSqr(),L=D.z.redSqr();if(this.x.redMul(L).redISub(D.x.redMul(A)).cmpn(0)!==0)return!1;var M=A.redMul(this.z),q=L.redMul(D.z);return this.y.redMul(q).redISub(D.y.redMul(M)).cmpn(0)===0},R.prototype.eqXToP=function S(D){var A=this.z.redSqr(),L=D.toRed(this.curve.red).redMul(A);if(this.x.cmp(L)===0)return!0;var M=D.clone(),q=this.curve.redN.redMul(A);for(;;){if(M.iadd(this.curve.n),M.cmp(this.curve.p)>=0)return!1;if(L.redIAdd(q),this.x.cmp(L)===0)return!0}},R.prototype.inspect=function S(){if(this.isInfinity())return"<EC JPoint Infinity>";return"<EC JPoint x: "+this.x.toString(16,2)+" y: "+this.y.toString(16,2)+" z: "+this.z.toString(16,2)+">"},R.prototype.isInfinity=function S(){return this.z.cmpn(0)===0}}),MY=w0((E,G)=>{var W=lU(),C=kU(),H=_X(),z=BU();function V(k){H.call(this,"mont",k),this.a=new W(k.a,16).toRed(this.red),this.b=new W(k.b,16).toRed(this.red),this.i4=new W(4).toRed(this.red).redInvm(),this.two=new W(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}C(V,H),G.exports=V,V.prototype.validate=function k(R){var S=R.normalize().x,D=S.redSqr(),A=D.redMul(S).redAdd(D.redMul(this.a)).redAdd(S),L=A.redSqrt();return L.redSqr().cmp(A)===0};function P(k,R,S){if(H.BasePoint.call(this,k,"projective"),R===null&&S===null)this.x=this.curve.one,this.z=this.curve.zero;else{if(this.x=new W(R,16),this.z=new W(S,16),!this.x.red)this.x=this.x.toRed(this.curve.red);if(!this.z.red)this.z=this.z.toRed(this.curve.red)}}C(P,H.BasePoint),V.prototype.decodePoint=function k(R,S){return this.point(z.toArray(R,S),1)},V.prototype.point=function k(R,S){return new P(this,R,S)},V.prototype.pointFromJSON=function k(R){return P.fromJSON(this,R)},P.prototype.precompute=function k(){},P.prototype._encode=function k(){return this.getX().toArray("be",this.curve.p.byteLength())},P.fromJSON=function k(R,S){return new P(R,S[0],S[1]||R.one)},P.prototype.inspect=function k(){if(this.isInfinity())return"<EC Point Infinity>";return"<EC Point x: "+this.x.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},P.prototype.isInfinity=function k(){return this.z.cmpn(0)===0},P.prototype.dbl=function k(){var R=this.x.redAdd(this.z),S=R.redSqr(),D=this.x.redSub(this.z),A=D.redSqr(),L=S.redSub(A),M=S.redMul(A),q=L.redMul(A.redAdd(this.curve.a24.redMul(L)));return this.curve.point(M,q)},P.prototype.add=function k(){throw new Error("Not supported on Montgomery curve")},P.prototype.diffAdd=function k(R,S){var D=this.x.redAdd(this.z),A=this.x.redSub(this.z),L=R.x.redAdd(R.z),M=R.x.redSub(R.z),q=M.redMul(D),j=L.redMul(A),x=S.z.redMul(q.redAdd(j).redSqr()),g=S.x.redMul(q.redISub(j).redSqr());return this.curve.point(x,g)},P.prototype.mul=function k(R){var S=R.clone(),D=this,A=this.curve.point(null,null),L=this;for(var M=[];S.cmpn(0)!==0;S.iushrn(1))M.push(S.andln(1));for(var q=M.length-1;q>=0;q--)if(M[q]===0)D=D.diffAdd(A,L),A=A.dbl();else A=D.diffAdd(A,L),D=D.dbl();return A},P.prototype.mulAdd=function k(){throw new Error("Not supported on Montgomery curve")},P.prototype.jumlAdd=function k(){throw new Error("Not supported on Montgomery curve")},P.prototype.eq=function k(R){return this.getX().cmp(R.getX())===0},P.prototype.normalize=function k(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},P.prototype.getX=function k(){return this.normalize(),this.x.fromRed()}}),RY=w0((E,G)=>{var W=BU(),C=lU(),H=kU(),z=_X(),V=W.assert;function P(R){this.twisted=(R.a|0)!==1,this.mOneA=this.twisted&&(R.a|0)===-1,this.extended=this.mOneA,z.call(this,"edwards",R),this.a=new C(R.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new C(R.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new C(R.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),V(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(R.c|0)===1}H(P,z),G.exports=P,P.prototype._mulA=function R(S){if(this.mOneA)return S.redNeg();else return this.a.redMul(S)},P.prototype._mulC=function R(S){if(this.oneC)return S;else return this.c.redMul(S)},P.prototype.jpoint=function R(S,D,A,L){return this.point(S,D,A,L)},P.prototype.pointFromX=function R(S,D){if(S=new C(S,16),!S.red)S=S.toRed(this.red);var A=S.redSqr(),L=this.c2.redSub(this.a.redMul(A)),M=this.one.redSub(this.c2.redMul(this.d).redMul(A)),q=L.redMul(M.redInvm()),j=q.redSqrt();if(j.redSqr().redSub(q).cmp(this.zero)!==0)throw new Error("invalid point");var x=j.fromRed().isOdd();if(D&&!x||!D&&x)j=j.redNeg();return this.point(S,j)},P.prototype.pointFromY=function R(S,D){if(S=new C(S,16),!S.red)S=S.toRed(this.red);var A=S.redSqr(),L=A.redSub(this.c2),M=A.redMul(this.d).redMul(this.c2).redSub(this.a),q=L.redMul(M.redInvm());if(q.cmp(this.zero)===0)if(D)throw new Error("invalid point");else return this.point(this.zero,S);var j=q.redSqrt();if(j.redSqr().redSub(q).cmp(this.zero)!==0)throw new Error("invalid point");if(j.fromRed().isOdd()!==D)j=j.redNeg();return this.point(j,S)},P.prototype.validate=function R(S){if(S.isInfinity())return!0;S.normalize();var D=S.x.redSqr(),A=S.y.redSqr(),L=D.redMul(this.a).redAdd(A),M=this.c2.redMul(this.one.redAdd(this.d.redMul(D).redMul(A)));return L.cmp(M)===0};function k(R,S,D,A,L){if(z.BasePoint.call(this,R,"projective"),S===null&&D===null&&A===null)this.x=this.curve.zero,this.y=this.curve.one,this.z=this.curve.one,this.t=this.curve.zero,this.zOne=!0;else{if(this.x=new C(S,16),this.y=new C(D,16),this.z=A?new C(A,16):this.curve.one,this.t=L&&new C(L,16),!this.x.red)this.x=this.x.toRed(this.curve.red);if(!this.y.red)this.y=this.y.toRed(this.curve.red);if(!this.z.red)this.z=this.z.toRed(this.curve.red);if(this.t&&!this.t.red)this.t=this.t.toRed(this.curve.red);if(this.zOne=this.z===this.curve.one,this.curve.extended&&!this.t){if(this.t=this.x.redMul(this.y),!this.zOne)this.t=this.t.redMul(this.z.redInvm())}}}H(k,z.BasePoint),P.prototype.pointFromJSON=function R(S){return k.fromJSON(this,S)},P.prototype.point=function R(S,D,A,L){return new k(this,S,D,A,L)},k.fromJSON=function R(S,D){return new k(S,D[0],D[1],D[2])},k.prototype.inspect=function R(){if(this.isInfinity())return"<EC Point Infinity>";return"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+" z: "+this.z.fromRed().toString(16,2)+">"},k.prototype.isInfinity=function R(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},k.prototype._extDbl=function R(){var S=this.x.redSqr(),D=this.y.redSqr(),A=this.z.redSqr();A=A.redIAdd(A);var L=this.curve._mulA(S),M=this.x.redAdd(this.y).redSqr().redISub(S).redISub(D),q=L.redAdd(D),j=q.redSub(A),x=L.redSub(D),g=M.redMul(j),N=q.redMul(x),y=M.redMul(x),f=j.redMul(q);return this.curve.point(g,N,f,y)},k.prototype._projDbl=function R(){var S=this.x.redAdd(this.y).redSqr(),D=this.x.redSqr(),A=this.y.redSqr(),L,M,q,j,x,g;if(this.curve.twisted){j=this.curve._mulA(D);var N=j.redAdd(A);if(this.zOne)L=S.redSub(D).redSub(A).redMul(N.redSub(this.curve.two)),M=N.redMul(j.redSub(A)),q=N.redSqr().redSub(N).redSub(N);else x=this.z.redSqr(),g=N.redSub(x).redISub(x),L=S.redSub(D).redISub(A).redMul(g),M=N.redMul(j.redSub(A)),q=N.redMul(g)}else j=D.redAdd(A),x=this.curve._mulC(this.z).redSqr(),g=j.redSub(x).redSub(x),L=this.curve._mulC(S.redISub(j)).redMul(g),M=this.curve._mulC(j).redMul(D.redISub(A)),q=j.redMul(g);return this.curve.point(L,M,q)},k.prototype.dbl=function R(){if(this.isInfinity())return this;if(this.curve.extended)return this._extDbl();else return this._projDbl()},k.prototype._extAdd=function R(S){var D=this.y.redSub(this.x).redMul(S.y.redSub(S.x)),A=this.y.redAdd(this.x).redMul(S.y.redAdd(S.x)),L=this.t.redMul(this.curve.dd).redMul(S.t),M=this.z.redMul(S.z.redAdd(S.z)),q=A.redSub(D),j=M.redSub(L),x=M.redAdd(L),g=A.redAdd(D),N=q.redMul(j),y=x.redMul(g),f=q.redMul(g),o=j.redMul(x);return this.curve.point(N,y,o,f)},k.prototype._projAdd=function R(S){var D=this.z.redMul(S.z),A=D.redSqr(),L=this.x.redMul(S.x),M=this.y.redMul(S.y),q=this.curve.d.redMul(L).redMul(M),j=A.redSub(q),x=A.redAdd(q),g=this.x.redAdd(this.y).redMul(S.x.redAdd(S.y)).redISub(L).redISub(M),N=D.redMul(j).redMul(g),y,f;if(this.curve.twisted)y=D.redMul(x).redMul(M.redSub(this.curve._mulA(L))),f=j.redMul(x);else y=D.redMul(x).redMul(M.redSub(L)),f=this.curve._mulC(j).redMul(x);return this.curve.point(N,y,f)},k.prototype.add=function R(S){if(this.isInfinity())return S;if(S.isInfinity())return this;if(this.curve.extended)return this._extAdd(S);else return this._projAdd(S)},k.prototype.mul=function R(S){if(this._hasDoubles(S))return this.curve._fixedNafMul(this,S);else return this.curve._wnafMul(this,S)},k.prototype.mulAdd=function R(S,D,A){return this.curve._wnafMulAdd(1,[this,D],[S,A],2,!1)},k.prototype.jmulAdd=function R(S,D,A){return this.curve._wnafMulAdd(1,[this,D],[S,A],2,!0)},k.prototype.normalize=function R(){if(this.zOne)return this;var S=this.z.redInvm();if(this.x=this.x.redMul(S),this.y=this.y.redMul(S),this.t)this.t=this.t.redMul(S);return this.z=this.curve.one,this.zOne=!0,this},k.prototype.neg=function R(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},k.prototype.getX=function R(){return this.normalize(),this.x.fromRed()},k.prototype.getY=function R(){return this.normalize(),this.y.fromRed()},k.prototype.eq=function R(S){return this===S||this.getX().cmp(S.getX())===0&&this.getY().cmp(S.getY())===0},k.prototype.eqXToP=function R(S){var D=S.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(D)===0)return!0;var A=S.clone(),L=this.curve.redN.redMul(this.z);for(;;){if(A.iadd(this.curve.n),A.cmp(this.curve.p)>=0)return!1;if(D.redIAdd(L),this.x.cmp(D)===0)return!0}},k.prototype.toP=k.prototype.normalize,k.prototype.mixedAdd=k.prototype.add}),SZ=w0((E)=>{var G=E;G.base=_X(),G.short=zY(),G.mont=MY(),G.edwards=RY()}),yU=w0((E)=>{var G=sU(),W=kU();E.inherits=W;function C(U,Z){if((U.charCodeAt(Z)&64512)!==55296)return!1;if(Z<0||Z+1>=U.length)return!1;return(U.charCodeAt(Z+1)&64512)===56320}function H(U,Z){if(Array.isArray(U))return U.slice();if(!U)return[];var Q=[];if(typeof U==="string"){if(!Z){var I=0;for(var $=0;$<U.length;$++){var K=U.charCodeAt($);if(K<128)Q[I++]=K;else if(K<2048)Q[I++]=K>>6|192,Q[I++]=K&63|128;else if(C(U,$))K=65536+((K&1023)<<10)+(U.charCodeAt(++$)&1023),Q[I++]=K>>18|240,Q[I++]=K>>12&63|128,Q[I++]=K>>6&63|128,Q[I++]=K&63|128;else Q[I++]=K>>12|224,Q[I++]=K>>6&63|128,Q[I++]=K&63|128}}else if(Z==="hex"){if(U=U.replace(/[^a-z0-9]+/ig,""),U.length%2!==0)U="0"+U;for($=0;$<U.length;$+=2)Q.push(parseInt(U[$]+U[$+1],16))}}else for($=0;$<U.length;$++)Q[$]=U[$]|0;return Q}E.toArray=H;function z(U){var Z="";for(var Q=0;Q<U.length;Q++)Z+=k(U[Q].toString(16));return Z}E.toHex=z;function V(U){var Z=U>>>24|U>>>8&65280|U<<8&16711680|(U&255)<<24;return Z>>>0}E.htonl=V;function P(U,Z){var Q="";for(var I=0;I<U.length;I++){var $=U[I];if(Z==="little")$=V($);Q+=R($.toString(16))}return Q}E.toHex32=P;function k(U){if(U.length===1)return"0"+U;else return U}E.zero2=k;function R(U){if(U.length===7)return"0"+U;else if(U.length===6)return"00"+U;else if(U.length===5)return"000"+U;else if(U.length===4)return"0000"+U;else if(U.length===3)return"00000"+U;else if(U.length===2)return"000000"+U;else if(U.length===1)return"0000000"+U;else return U}E.zero8=R;function S(U,Z,Q,I){var $=Q-Z;G($%4===0);var K=new Array($/4);for(var J=0,Y=Z;J<K.length;J++,Y+=4){var X;if(I==="big")X=U[Y]<<24|U[Y+1]<<16|U[Y+2]<<8|U[Y+3];else X=U[Y+3]<<24|U[Y+2]<<16|U[Y+1]<<8|U[Y];K[J]=X>>>0}return K}E.join32=S;function D(U,Z){var Q=new Array(U.length*4);for(var I=0,$=0;I<U.length;I++,$+=4){var K=U[I];if(Z==="big")Q[$]=K>>>24,Q[$+1]=K>>>16&255,Q[$+2]=K>>>8&255,Q[$+3]=K&255;else Q[$+3]=K>>>24,Q[$+2]=K>>>16&255,Q[$+1]=K>>>8&255,Q[$]=K&255}return Q}E.split32=D;function A(U,Z){return U>>>Z|U<<32-Z}E.rotr32=A;function L(U,Z){return U<<Z|U>>>32-Z}E.rotl32=L;function M(U,Z){return U+Z>>>0}E.sum32=M;function q(U,Z,Q){return U+Z+Q>>>0}E.sum32_3=q;function j(U,Z,Q,I){return U+Z+Q+I>>>0}E.sum32_4=j;function x(U,Z,Q,I,$){return U+Z+Q+I+$>>>0}E.sum32_5=x;function g(U,Z,Q,I){var $=U[Z],K=U[Z+1],J=I+K>>>0,Y=(J<I?1:0)+Q+$;U[Z]=Y>>>0,U[Z+1]=J}E.sum64=g;function N(U,Z,Q,I){var $=Z+I>>>0,K=($<Z?1:0)+U+Q;return K>>>0}E.sum64_hi=N;function y(U,Z,Q,I){var $=Z+I;return $>>>0}E.sum64_lo=y;function f(U,Z,Q,I,$,K,J,Y){var X=0,O=Z;O=O+I>>>0,X+=O<Z?1:0,O=O+K>>>0,X+=O<K?1:0,O=O+Y>>>0,X+=O<Y?1:0;var v=U+Q+$+J+X;return v>>>0}E.sum64_4_hi=f;function o(U,Z,Q,I,$,K,J,Y){var X=Z+I+K+Y;return X>>>0}E.sum64_4_lo=o;function r(U,Z,Q,I,$,K,J,Y,X,O){var v=0,T=Z;T=T+I>>>0,v+=T<Z?1:0,T=T+K>>>0,v+=T<K?1:0,T=T+Y>>>0,v+=T<Y?1:0,T=T+O>>>0,v+=T<O?1:0;var B=U+Q+$+J+X+v;return B>>>0}E.sum64_5_hi=r;function V0(U,Z,Q,I,$,K,J,Y,X,O){var v=Z+I+K+Y+O;return v>>>0}E.sum64_5_lo=V0;function Y0(U,Z,Q){var I=Z<<32-Q|U>>>Q;return I>>>0}E.rotr64_hi=Y0;function u(U,Z,Q){var I=U<<32-Q|Z>>>Q;return I>>>0}E.rotr64_lo=u;function a(U,Z,Q){return U>>>Q}E.shr64_hi=a;function F(U,Z,Q){var I=U<<32-Q|Z>>>Q;return I>>>0}E.shr64_lo=F}),CX=w0((E)=>{var G=yU(),W=sU();function C(){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}E.BlockHash=C,C.prototype.update=function H(z,V){if(z=G.toArray(z,V),!this.pending)this.pending=z;else this.pending=this.pending.concat(z);if(this.pendingTotal+=z.length,this.pending.length>=this._delta8){z=this.pending;var P=z.length%this._delta8;if(this.pending=z.slice(z.length-P,z.length),this.pending.length===0)this.pending=null;z=G.join32(z,0,z.length-P,this.endian);for(var k=0;k<z.length;k+=this._delta32)this._update(z,k,k+this._delta32)}return this},C.prototype.digest=function H(z){return this.update(this._pad()),W(this.pending===null),this._digest(z)},C.prototype._pad=function H(){var z=this.pendingTotal,V=this._delta8,P=V-(z+this.padLength)%V,k=new Array(P+this.padLength);k[0]=128;for(var R=1;R<P;R++)k[R]=0;if(z<<=3,this.endian==="big"){for(var S=8;S<this.padLength;S++)k[R++]=0;k[R++]=0,k[R++]=0,k[R++]=0,k[R++]=0,k[R++]=z>>>24&255,k[R++]=z>>>16&255,k[R++]=z>>>8&255,k[R++]=z&255}else{k[R++]=z&255,k[R++]=z>>>8&255,k[R++]=z>>>16&255,k[R++]=z>>>24&255,k[R++]=0,k[R++]=0,k[R++]=0,k[R++]=0;for(S=8;S<this.padLength;S++)k[R++]=0}return k}}),PZ=w0((E)=>{var G=yU(),W=G.rotr32;function C(D,A,L,M){if(D===0)return H(A,L,M);if(D===1||D===3)return V(A,L,M);if(D===2)return z(A,L,M)}E.ft_1=C;function H(D,A,L){return D&A^~D&L}E.ch32=H;function z(D,A,L){return D&A^D&L^A&L}E.maj32=z;function V(D,A,L){return D^A^L}E.p32=V;function P(D){return W(D,2)^W(D,13)^W(D,22)}E.s0_256=P;function k(D){return W(D,6)^W(D,11)^W(D,25)}E.s1_256=k;function R(D){return W(D,7)^W(D,18)^D>>>3}E.g0_256=R;function S(D){return W(D,17)^W(D,19)^D>>>10}E.g1_256=S}),SY=w0((E,G)=>{var W=yU(),C=CX(),H=PZ(),z=W.rotl32,V=W.sum32,P=W.sum32_5,k=H.ft_1,R=C.BlockHash,S=[1518500249,1859775393,2400959708,3395469782];function D(){if(!(this instanceof D))return new D;R.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=new Array(80)}W.inherits(D,R),G.exports=D,D.blockSize=512,D.outSize=160,D.hmacStrength=80,D.padLength=64,D.prototype._update=function A(L,M){var q=this.W;for(var j=0;j<16;j++)q[j]=L[M+j];for(;j<q.length;j++)q[j]=z(q[j-3]^q[j-8]^q[j-14]^q[j-16],1);var x=this.h[0],g=this.h[1],N=this.h[2],y=this.h[3],f=this.h[4];for(j=0;j<q.length;j++){var o=~~(j/20),r=P(z(x,5),k(o,g,N,y),f,q[j],S[o]);f=y,y=N,N=z(g,30),g=x,x=r}this.h[0]=V(this.h[0],x),this.h[1]=V(this.h[1],g),this.h[2]=V(this.h[2],N),this.h[3]=V(this.h[3],y),this.h[4]=V(this.h[4],f)},D.prototype._digest=function A(L){if(L==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")}}),qZ=w0((E,G)=>{var W=yU(),C=CX(),H=PZ(),z=sU(),V=W.sum32,P=W.sum32_4,k=W.sum32_5,R=H.ch32,S=H.maj32,D=H.s0_256,A=H.s1_256,L=H.g0_256,M=H.g1_256,q=C.BlockHash,j=[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 x(){if(!(this instanceof x))return new x;q.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=j,this.W=new Array(64)}W.inherits(x,q),G.exports=x,x.blockSize=512,x.outSize=256,x.hmacStrength=192,x.padLength=64,x.prototype._update=function g(N,y){var f=this.W;for(var o=0;o<16;o++)f[o]=N[y+o];for(;o<f.length;o++)f[o]=P(M(f[o-2]),f[o-7],L(f[o-15]),f[o-16]);var r=this.h[0],V0=this.h[1],Y0=this.h[2],u=this.h[3],a=this.h[4],F=this.h[5],U=this.h[6],Z=this.h[7];z(this.k.length===f.length);for(o=0;o<f.length;o++){var Q=k(Z,A(a),R(a,F,U),this.k[o],f[o]),I=V(D(r),S(r,V0,Y0));Z=U,U=F,F=a,a=V(u,Q),u=Y0,Y0=V0,V0=r,r=V(Q,I)}this.h[0]=V(this.h[0],r),this.h[1]=V(this.h[1],V0),this.h[2]=V(this.h[2],Y0),this.h[3]=V(this.h[3],u),this.h[4]=V(this.h[4],a),this.h[5]=V(this.h[5],F),this.h[6]=V(this.h[6],U),this.h[7]=V(this.h[7],Z)},x.prototype._digest=function g(N){if(N==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")}}),PY=w0((E,G)=>{var W=yU(),C=qZ();function H(){if(!(this instanceof H))return new H;C.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}W.inherits(H,C),G.exports=H,H.blockSize=512,H.outSize=224,H.hmacStrength=192,H.padLength=64,H.prototype._digest=function z(V){if(V==="hex")return W.toHex32(this.h.slice(0,7),"big");else return W.split32(this.h.slice(0,7),"big")}}),vZ=w0((E,G)=>{var W=yU(),C=CX(),H=sU(),z=W.rotr64_hi,V=W.rotr64_lo,P=W.shr64_hi,k=W.shr64_lo,R=W.sum64,S=W.sum64_hi,D=W.sum64_lo,A=W.sum64_4_hi,L=W.sum64_4_lo,M=W.sum64_5_hi,q=W.sum64_5_lo,j=C.BlockHash,x=[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 g(){if(!(this instanceof g))return new g;j.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=x,this.W=new Array(160)}W.inherits(g,j),G.exports=g,g.blockSize=1024,g.outSize=512,g.hmacStrength=192,g.padLength=128,g.prototype._prepareBlock=function Q(I,$){var K=this.W;for(var J=0;J<32;J++)K[J]=I[$+J];for(;J<K.length;J+=2){var Y=U(K[J-4],K[J-3]),X=Z(K[J-4],K[J-3]),O=K[J-14],v=K[J-13],T=a(K[J-30],K[J-29]),B=F(K[J-30],K[J-29]),c=K[J-32],l=K[J-31];K[J]=A(Y,X,O,v,T,B,c,l),K[J+1]=L(Y,X,O,v,T,B,c,l)}},g.prototype._update=function Q(I,$){this._prepareBlock(I,$);var K=this.W,J=this.h[0],Y=this.h[1],X=this.h[2],O=this.h[3],v=this.h[4],T=this.h[5],B=this.h[6],c=this.h[7],l=this.h[8],s=this.h[9],O0=this.h[10],h=this.h[11],d=this.h[12],g0=this.h[13],Q0=this.h[14],$0=this.h[15];H(this.k.length===K.length);for(var m=0;m<K.length;m+=2){var p=Q0,b=$0,N0=Y0(l,s),i=u(l,s),e=N(l,s,O0,h,d,g0),t=y(l,s,O0,h,d,g0),n=this.k[m],X0=this.k[m+1],H0=K[m],Z0=K[m+1],W0=M(p,b,N0,i,e,t,n,X0,H0,Z0),c0=q(p,b,N0,i,e,t,n,X0,H0,Z0);p=r(J,Y),b=V0(J,Y),N0=f(J,Y,X,O,v,T),i=o(J,Y,X,O,v,T);var G0=S(p,b,N0,i),A0=D(p,b,N0,i);Q0=d,$0=g0,d=O0,g0=h,O0=l,h=s,l=S(B,c,W0,c0),s=D(c,c,W0,c0),B=v,c=T,v=X,T=O,X=J,O=Y,J=S(W0,c0,G0,A0),Y=D(W0,c0,G0,A0)}R(this.h,0,J,Y),R(this.h,2,X,O),R(this.h,4,v,T),R(this.h,6,B,c),R(this.h,8,l,s),R(this.h,10,O0,h),R(this.h,12,d,g0),R(this.h,14,Q0,$0)},g.prototype._digest=function Q(I){if(I==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")};function N(Q,I,$,K,J){var Y=Q&$^~Q&J;if(Y<0)Y+=4294967296;return Y}function y(Q,I,$,K,J,Y){var X=I&K^~I&Y;if(X<0)X+=4294967296;return X}function f(Q,I,$,K,J){var Y=Q&$^Q&J^$&J;if(Y<0)Y+=4294967296;return Y}function o(Q,I,$,K,J,Y){var X=I&K^I&Y^K&Y;if(X<0)X+=4294967296;return X}function r(Q,I){var $=z(Q,I,28),K=z(I,Q,2),J=z(I,Q,7),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function V0(Q,I){var $=V(Q,I,28),K=V(I,Q,2),J=V(I,Q,7),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function Y0(Q,I){var $=z(Q,I,14),K=z(Q,I,18),J=z(I,Q,9),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function u(Q,I){var $=V(Q,I,14),K=V(Q,I,18),J=V(I,Q,9),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function a(Q,I){var $=z(Q,I,1),K=z(Q,I,8),J=P(Q,I,7),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function F(Q,I){var $=V(Q,I,1),K=V(Q,I,8),J=k(Q,I,7),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function U(Q,I){var $=z(Q,I,19),K=z(I,Q,29),J=P(Q,I,6),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}function Z(Q,I){var $=V(Q,I,19),K=V(I,Q,29),J=k(Q,I,6),Y=$^K^J;if(Y<0)Y+=4294967296;return Y}}),qY=w0((E,G)=>{var W=yU(),C=vZ();function H(){if(!(this instanceof H))return new H;C.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}W.inherits(H,C),G.exports=H,H.blockSize=1024,H.outSize=384,H.hmacStrength=192,H.padLength=128,H.prototype._digest=function z(V){if(V==="hex")return W.toHex32(this.h.slice(0,12),"big");else return W.split32(this.h.slice(0,12),"big")}}),vY=w0((E)=>{E.sha1=SY(),E.sha224=PY(),E.sha256=qZ(),E.sha384=qY(),E.sha512=vZ()}),kY=w0((E)=>{var G=yU(),W=CX(),C=G.rotl32,H=G.sum32,z=G.sum32_3,V=G.sum32_4,P=W.BlockHash;function k(){if(!(this instanceof k))return new k;P.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}G.inherits(k,P),E.ripemd160=k,k.blockSize=512,k.outSize=160,k.hmacStrength=192,k.padLength=64,k.prototype._update=function j(x,g){var N=this.h[0],y=this.h[1],f=this.h[2],o=this.h[3],r=this.h[4],V0=N,Y0=y,u=f,a=o,F=r;for(var U=0;U<80;U++){var Z=H(C(V(N,R(U,y,f,o),x[A[U]+g],S(U)),M[U]),r);N=r,r=o,o=C(f,10),f=y,y=Z,Z=H(C(V(V0,R(79-U,Y0,u,a),x[L[U]+g],D(U)),q[U]),F),V0=F,F=a,a=C(u,10),u=Y0,Y0=Z}Z=z(this.h[1],f,a),this.h[1]=z(this.h[2],o,F),this.h[2]=z(this.h[3],r,V0),this.h[3]=z(this.h[4],N,Y0),this.h[4]=z(this.h[0],y,u),this.h[0]=Z},k.prototype._digest=function j(x){if(x==="hex")return G.toHex32(this.h,"little");else return G.split32(this.h,"little")};function R(j,x,g,N){if(j<=15)return x^g^N;else if(j<=31)return x&g|~x&N;else if(j<=47)return(x|~g)^N;else if(j<=63)return x&N|g&~N;else return x^(g|~N)}function S(j){if(j<=15)return 0;else if(j<=31)return 1518500249;else if(j<=47)return 1859775393;else if(j<=63)return 2400959708;else return 2840853838}function D(j){if(j<=15)return 1352829926;else if(j<=31)return 1548603684;else if(j<=47)return 1836072691;else if(j<=63)return 2053994217;else return 0}var A=[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],L=[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],M=[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],q=[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]}),jY=w0((E,G)=>{var W=yU(),C=sU();function H(z,V,P){if(!(this instanceof H))return new H(z,V,P);this.Hash=z,this.blockSize=z.blockSize/8,this.outSize=z.outSize/8,this.inner=null,this.outer=null,this._init(W.toArray(V,P))}G.exports=H,H.prototype._init=function z(V){if(V.length>this.blockSize)V=new this.Hash().update(V).digest();C(V.length<=this.blockSize);for(var P=V.length;P<this.blockSize;P++)V.push(0);for(P=0;P<V.length;P++)V[P]^=54;this.inner=new this.Hash().update(V);for(P=0;P<V.length;P++)V[P]^=106;this.outer=new this.Hash().update(V)},H.prototype.update=function z(V,P){return this.inner.update(V,P),this},H.prototype.digest=function z(V){return this.outer.update(this.inner.digest()),this.outer.digest(V)}}),FI=w0((E)=>{var G=E;G.utils=yU(),G.common=CX(),G.sha=vY(),G.ripemd=kY(),G.hmac=jY(),G.sha1=G.sha.sha1,G.sha256=G.sha.sha256,G.sha224=G.sha.sha224,G.sha384=G.sha.sha384,G.sha512=G.sha.sha512,G.ripemd160=G.ripemd.ripemd160}),BY=w0((E,G)=>{G.exports={doubles:{step:4,points:[["e60fce93b59e9ec53011aabc21c23e97b2a31369b87a5ae9c44ee89e2a6dec0a","f7e3507399e595929db99f34f57937101296891e44d23f0be1f32cce69616821"],["8282263212c609d9ea2a6e3e172de238d8c39cabd5ac1ca10646e23fd5f51508","11f8a8098557dfe45e8256e830b60ace62d613ac2f7b17bed31b6eaff6e26caf"],["175e159f728b865a72f99cc6c6fc846de0b93833fd2222ed73fce5b551e5b739","d3506e0d9e3c79eba4ef97a51ff71f5eacb5955add24345c6efa6ffee9fed695"],["363d90d447b00c9c99ceac05b6262ee053441c7e55552ffe526bad8f83ff4640","4e273adfc732221953b445397f3363145b9a89008199ecb62003c7f3bee9de9"],["8b4b5f165df3c2be8c6244b5b745638843e4a781a15bcd1b69f79a55dffdf80c","4aad0a6f68d308b4b3fbd7813ab0da04f9e336546162ee56b3eff0c65fd4fd36"],["723cbaa6e5db996d6bf771c00bd548c7b700dbffa6c0e77bcb6115925232fcda","96e867b5595cc498a921137488824d6e2660a0653779494801dc069d9eb39f5f"],["eebfa4d493bebf98ba5feec812c2d3b50947961237a919839a533eca0e7dd7fa","5d9a8ca3970ef0f269ee7edaf178089d9ae4cdc3a711f712ddfd4fdae1de8999"],["100f44da696e71672791d0a09b7bde459f1215a29b3c03bfefd7835b39a48db0","cdd9e13192a00b772ec8f3300c090666b7ff4a18ff5195ac0fbd5cd62bc65a09"],["e1031be262c7ed1b1dc9227a4a04c017a77f8d4464f3b3852c8acde6e534fd2d","9d7061928940405e6bb6a4176597535af292dd419e1ced79a44f18f29456a00d"],["feea6cae46d55b530ac2839f143bd7ec5cf8b266a41d6af52d5e688d9094696d","e57c6b6c97dce1bab06e4e12bf3ecd5c981c8957cc41442d3155debf18090088"],["da67a91d91049cdcb367be4be6ffca3cfeed657d808583de33fa978bc1ec6cb1","9bacaa35481642bc41f463f7ec9780e5dec7adc508f740a17e9ea8e27a68be1d"],["53904faa0b334cdda6e000935ef22151ec08d0f7bb11069f57545ccc1a37b7c0","5bc087d0bc80106d88c9eccac20d3c1c13999981e14434699dcb096b022771c8"],["8e7bcd0bd35983a7719cca7764ca906779b53a043a9b8bcaeff959f43ad86047","10b7770b2a3da4b3940310420ca9514579e88e2e47fd68b3ea10047e8460372a"],["385eed34c1cdff21e6d0818689b81bde71a7f4f18397e6690a841e1599c43862","283bebc3e8ea23f56701de19e9ebf4576b304eec2086dc8cc0458fe5542e5453"],["6f9d9b803ecf191637c73a4413dfa180fddf84a5947fbc9c606ed86c3fac3a7","7c80c68e603059ba69b8e2a30e45c4d47ea4dd2f5c281002d86890603a842160"],["3322d401243c4e2582a2147c104d6ecbf774d163db0f5e5313b7e0e742d0e6bd","56e70797e9664ef5bfb019bc4ddaf9b72805f63ea2873af624f3a2e96c28b2a0"],["85672c7d2de0b7da2bd1770d89665868741b3f9af7643397721d74d28134ab83","7c481b9b5b43b2eb6374049bfa62c2e5e77f17fcc5298f44c8e3094f790313a6"],["948bf809b1988a46b06c9f1919413b10f9226c60f668832ffd959af60c82a0a","53a562856dcb6646dc6b74c5d1c3418c6d4dff08c97cd2bed4cb7f88d8c8e589"],["6260ce7f461801c34f067ce0f02873a8f1b0e44dfc69752accecd819f38fd8e8","bc2da82b6fa5b571a7f09049776a1ef7ecd292238051c198c1a84e95b2b4ae17"],["e5037de0afc1d8d43d8348414bbf4103043ec8f575bfdc432953cc8d2037fa2d","4571534baa94d3b5f9f98d09fb990bddbd5f5b03ec481f10e0e5dc841d755bda"],["e06372b0f4a207adf5ea905e8f1771b4e7e8dbd1c6a6c5b725866a0ae4fce725","7a908974bce18cfe12a27bb2ad5a488cd7484a7787104870b27034f94eee31dd"],["213c7a715cd5d45358d0bbf9dc0ce02204b10bdde2a3f58540ad6908d0559754","4b6dad0b5ae462507013ad06245ba190bb4850f5f36a7eeddff2c27534b458f2"],["4e7c272a7af4b34e8dbb9352a5419a87e2838c70adc62cddf0cc3a3b08fbd53c","17749c766c9d0b18e16fd09f6def681b530b9614bff7dd33e0b3941817dcaae6"],["fea74e3dbe778b1b10f238ad61686aa5c76e3db2be43057632427e2840fb27b6","6e0568db9b0b13297cf674deccb6af93126b596b973f7b77701d3db7f23cb96f"],["76e64113f677cf0e10a2570d599968d31544e179b760432952c02a4417bdde39","c90ddf8dee4e95cf577066d70681f0d35e2a33d2b56d2032b4b1752d1901ac01"],["c738c56b03b2abe1e8281baa743f8f9a8f7cc643df26cbee3ab150242bcbb891","893fb578951ad2537f718f2eacbfbbbb82314eef7880cfe917e735d9699a84c3"],["d895626548b65b81e264c7637c972877d1d72e5f3a925014372e9f6588f6c14b","febfaa38f2bc7eae728ec60818c340eb03428d632bb067e179363ed75d7d991f"],["b8da94032a957518eb0f6433571e8761ceffc73693e84edd49150a564f676e03","2804dfa44805a1e4d7c99cc9762808b092cc584d95ff3b511488e4e74efdf6e7"],["e80fea14441fb33a7d8adab9475d7fab2019effb5156a792f1a11778e3c0df5d","eed1de7f638e00771e89768ca3ca94472d155e80af322ea9fcb4291b6ac9ec78"],["a301697bdfcd704313ba48e51d567543f2a182031efd6915ddc07bbcc4e16070","7370f91cfb67e4f5081809fa25d40f9b1735dbf7c0a11a130c0d1a041e177ea1"],["90ad85b389d6b936463f9d0512678de208cc330b11307fffab7ac63e3fb04ed4","e507a3620a38261affdcbd9427222b839aefabe1582894d991d4d48cb6ef150"],["8f68b9d2f63b5f339239c1ad981f162ee88c5678723ea3351b7b444c9ec4c0da","662a9f2dba063986de1d90c2b6be215dbbea2cfe95510bfdf23cbf79501fff82"],["e4f3fb0176af85d65ff99ff9198c36091f48e86503681e3e6686fd5053231e11","1e63633ad0ef4f1c1661a6d0ea02b7286cc7e74ec951d1c9822c38576feb73bc"],["8c00fa9b18ebf331eb961537a45a4266c7034f2f0d4e1d0716fb6eae20eae29e","efa47267fea521a1a9dc343a3736c974c2fadafa81e36c54e7d2a4c66702414b"],["e7a26ce69dd4829f3e10cec0a9e98ed3143d084f308b92c0997fddfc60cb3e41","2a758e300fa7984b471b006a1aafbb18d0a6b2c0420e83e20e8a9421cf2cfd51"],["b6459e0ee3662ec8d23540c223bcbdc571cbcb967d79424f3cf29eb3de6b80ef","67c876d06f3e06de1dadf16e5661db3c4b3ae6d48e35b2ff30bf0b61a71ba45"],["d68a80c8280bb840793234aa118f06231d6f1fc67e73c5a5deda0f5b496943e8","db8ba9fff4b586d00c4b1f9177b0e28b5b0e7b8f7845295a294c84266b133120"],["324aed7df65c804252dc0270907a30b09612aeb973449cea4095980fc28d3d5d","648a365774b61f2ff130c0c35aec1f4f19213b0c7e332843967224af96ab7c84"],["4df9c14919cde61f6d51dfdbe5fee5dceec4143ba8d1ca888e8bd373fd054c96","35ec51092d8728050974c23a1d85d4b5d506cdc288490192ebac06cad10d5d"],["9c3919a84a474870faed8a9c1cc66021523489054d7f0308cbfc99c8ac1f98cd","ddb84f0f4a4ddd57584f044bf260e641905326f76c64c8e6be7e5e03d4fc599d"],["6057170b1dd12fdf8de05f281d8e06bb91e1493a8b91d4cc5a21382120a959e5","9a1af0b26a6a4807add9a2daf71df262465152bc3ee24c65e899be932385a2a8"],["a576df8e23a08411421439a4518da31880cef0fba7d4df12b1a6973eecb94266","40a6bf20e76640b2c92b97afe58cd82c432e10a7f514d9f3ee8be11ae1b28ec8"],["7778a78c28dec3e30a05fe9629de8c38bb30d1f5cf9a3a208f763889be58ad71","34626d9ab5a5b22ff7098e12f2ff580087b38411ff24ac563b513fc1fd9f43ac"],["928955ee637a84463729fd30e7afd2ed5f96274e5ad7e5cb09eda9c06d903ac","c25621003d3f42a827b78a13093a95eeac3d26efa8a8d83fc5180e935bcd091f"],["85d0fef3ec6db109399064f3a0e3b2855645b4a907ad354527aae75163d82751","1f03648413a38c0be29d496e582cf5663e8751e96877331582c237a24eb1f962"],["ff2b0dce97eece97c1c9b6041798b85dfdfb6d8882da20308f5404824526087e","493d13fef524ba188af4c4dc54d07936c7b7ed6fb90e2ceb2c951e01f0c29907"],["827fbbe4b1e880ea9ed2b2e6301b212b57f1ee148cd6dd28780e5e2cf856e241","c60f9c923c727b0b71bef2c67d1d12687ff7a63186903166d605b68baec293ec"],["eaa649f21f51bdbae7be4ae34ce6e5217a58fdce7f47f9aa7f3b58fa2120e2b3","be3279ed5bbbb03ac69a80f89879aa5a01a6b965f13f7e59d47a5305ba5ad93d"],["e4a42d43c5cf169d9391df6decf42ee541b6d8f0c9a137401e23632dda34d24f","4d9f92e716d1c73526fc99ccfb8ad34ce886eedfa8d8e4f13a7f7131deba9414"],["1ec80fef360cbdd954160fadab352b6b92b53576a88fea4947173b9d4300bf19","aeefe93756b5340d2f3a4958a7abbf5e0146e77f6295a07b671cdc1cc107cefd"],["146a778c04670c2f91b00af4680dfa8bce3490717d58ba889ddb5928366642be","b318e0ec3354028add669827f9d4b2870aaa971d2f7e5ed1d0b297483d83efd0"],["fa50c0f61d22e5f07e3acebb1aa07b128d0012209a28b9776d76a8793180eef9","6b84c6922397eba9b72cd2872281a68a5e683293a57a213b38cd8d7d3f4f2811"],["da1d61d0ca721a11b1a5bf6b7d88e8421a288ab5d5bba5220e53d32b5f067ec2","8157f55a7c99306c79c0766161c91e2966a73899d279b48a655fba0f1ad836f1"],["a8e282ff0c9706907215ff98e8fd416615311de0446f1e062a73b0610d064e13","7f97355b8db81c09abfb7f3c5b2515888b679a3e50dd6bd6cef7c73111f4cc0c"],["174a53b9c9a285872d39e56e6913cab15d59b1fa512508c022f382de8319497c","ccc9dc37abfc9c1657b4155f2c47f9e6646b3a1d8cb9854383da13ac079afa73"],["959396981943785c3d3e57edf5018cdbe039e730e4918b3d884fdff09475b7ba","2e7e552888c331dd8ba0386a4b9cd6849c653f64c8709385e9b8abf87524f2fd"],["d2a63a50ae401e56d645a1153b109a8fcca0a43d561fba2dbb51340c9d82b151","e82d86fb6443fcb7565aee58b2948220a70f750af484ca52d4142174dcf89405"],["64587e2335471eb890ee7896d7cfdc866bacbdbd3839317b3436f9b45617e073","d99fcdd5bf6902e2ae96dd6447c299a185b90a39133aeab358299e5e9faf6589"],["8481bde0e4e4d885b3a546d3e549de042f0aa6cea250e7fd358d6c86dd45e458","38ee7b8cba5404dd84a25bf39cecb2ca900a79c42b262e556d64b1b59779057e"],["13464a57a78102aa62b6979ae817f4637ffcfed3c4b1ce30bcd6303f6caf666b","69be159004614580ef7e433453ccb0ca48f300a81d0942e13f495a907f6ecc27"],["bc4a9df5b713fe2e9aef430bcc1dc97a0cd9ccede2f28588cada3a0d2d83f366","d3a81ca6e785c06383937adf4b798caa6e8a9fbfa547b16d758d666581f33c1"],["8c28a97bf8298bc0d23d8c749452a32e694b65e30a9472a3954ab30fe5324caa","40a30463a3305193378fedf31f7cc0eb7ae784f0451cb9459e71dc73cbef9482"],["8ea9666139527a8c1dd94ce4f071fd23c8b350c5a4bb33748c4ba111faccae0","620efabbc8ee2782e24e7c0cfb95c5d735b783be9cf0f8e955af34a30e62b945"],["dd3625faef5ba06074669716bbd3788d89bdde815959968092f76cc4eb9a9787","7a188fa3520e30d461da2501045731ca941461982883395937f68d00c644a573"],["f710d79d9eb962297e4f6232b40e8f7feb2bc63814614d692c12de752408221e","ea98e67232d3b3295d3b535532115ccac8612c721851617526ae47a9c77bfc82"]]},naf:{wnd:7,points:[["f9308a019258c31049344f85f89d5229b531c845836f99b08601f113bce036f9","388f7b0f632de8140fe337e62a37f3566500a99934c2231b6cb9fd7584b8e672"],["2f8bde4d1a07209355b4a7250a5c5128e88b84bddc619ab7cba8d569b240efe4","d8ac222636e5e3d6d4dba9dda6c9c426f788271bab0d6840dca87d3aa6ac62d6"],["5cbdf0646e5db4eaa398f365f2ea7a0e3d419b7e0330e39ce92bddedcac4f9bc","6aebca40ba255960a3178d6d861a54dba813d0b813fde7b5a5082628087264da"],["acd484e2f0c7f65309ad178a9f559abde09796974c57e714c35f110dfc27ccbe","cc338921b0a7d9fd64380971763b61e9add888a4375f8e0f05cc262ac64f9c37"],["774ae7f858a9411e5ef4246b70c65aac5649980be5c17891bbec17895da008cb","d984a032eb6b5e190243dd56d7b7b365372db1e2dff9d6a8301d74c9c953c61b"],["f28773c2d975288bc7d1d205c3748651b075fbc6610e58cddeeddf8f19405aa8","ab0902e8d880a89758212eb65cdaf473a1a06da521fa91f29b5cb52db03ed81"],["d7924d4f7d43ea965a465ae3095ff41131e5946f3c85f79e44adbcf8e27e080e","581e2872a86c72a683842ec228cc6defea40af2bd896d3a5c504dc9ff6a26b58"],["defdea4cdb677750a420fee807eacf21eb9898ae79b9768766e4faa04a2d4a34","4211ab0694635168e997b0ead2a93daeced1f4a04a95c0f6cfb199f69e56eb77"],["2b4ea0a797a443d293ef5cff444f4979f06acfebd7e86d277475656138385b6c","85e89bc037945d93b343083b5a1c86131a01f60c50269763b570c854e5c09b7a"],["352bbf4a4cdd12564f93fa332ce333301d9ad40271f8107181340aef25be59d5","321eb4075348f534d59c18259dda3e1f4a1b3b2e71b1039c67bd3d8bcf81998c"],["2fa2104d6b38d11b0230010559879124e42ab8dfeff5ff29dc9cdadd4ecacc3f","2de1068295dd865b64569335bd5dd80181d70ecfc882648423ba76b532b7d67"],["9248279b09b4d68dab21a9b066edda83263c3d84e09572e269ca0cd7f5453714","73016f7bf234aade5d1aa71bdea2b1ff3fc0de2a887912ffe54a32ce97cb3402"],["daed4f2be3a8bf278e70132fb0beb7522f570e144bf615c07e996d443dee8729","a69dce4a7d6c98e8d4a1aca87ef8d7003f83c230f3afa726ab40e52290be1c55"],["c44d12c7065d812e8acf28d7cbb19f9011ecd9e9fdf281b0e6a3b5e87d22e7db","2119a460ce326cdc76c45926c982fdac0e106e861edf61c5a039063f0e0e6482"],["6a245bf6dc698504c89a20cfded60853152b695336c28063b61c65cbd269e6b4","e022cf42c2bd4a708b3f5126f16a24ad8b33ba48d0423b6efd5e6348100d8a82"],["1697ffa6fd9de627c077e3d2fe541084ce13300b0bec1146f95ae57f0d0bd6a5","b9c398f186806f5d27561506e4557433a2cf15009e498ae7adee9d63d01b2396"],["605bdb019981718b986d0f07e834cb0d9deb8360ffb7f61df982345ef27a7479","2972d2de4f8d20681a78d93ec96fe23c26bfae84fb14db43b01e1e9056b8c49"],["62d14dab4150bf497402fdc45a215e10dcb01c354959b10cfe31c7e9d87ff33d","80fc06bd8cc5b01098088a1950eed0db01aa132967ab472235f5642483b25eaf"],["80c60ad0040f27dade5b4b06c408e56b2c50e9f56b9b8b425e555c2f86308b6f","1c38303f1cc5c30f26e66bad7fe72f70a65eed4cbe7024eb1aa01f56430bd57a"],["7a9375ad6167ad54aa74c6348cc54d344cc5dc9487d847049d5eabb0fa03c8fb","d0e3fa9eca8726909559e0d79269046bdc59ea10c70ce2b02d499ec224dc7f7"],["d528ecd9b696b54c907a9ed045447a79bb408ec39b68df504bb51f459bc3ffc9","eecf41253136e5f99966f21881fd656ebc4345405c520dbc063465b521409933"],["49370a4b5f43412ea25f514e8ecdad05266115e4a7ecb1387231808f8b45963","758f3f41afd6ed428b3081b0512fd62a54c3f3afbb5b6764b653052a12949c9a"],["77f230936ee88cbbd73df930d64702ef881d811e0e1498e2f1c13eb1fc345d74","958ef42a7886b6400a08266e9ba1b37896c95330d97077cbbe8eb3c7671c60d6"],["f2dac991cc4ce4b9ea44887e5c7c0bce58c80074ab9d4dbaeb28531b7739f530","e0dedc9b3b2f8dad4da1f32dec2531df9eb5fbeb0598e4fd1a117dba703a3c37"],["463b3d9f662621fb1b4be8fbbe2520125a216cdfc9dae3debcba4850c690d45b","5ed430d78c296c3543114306dd8622d7c622e27c970a1de31cb377b01af7307e"],["f16f804244e46e2a09232d4aff3b59976b98fac14328a2d1a32496b49998f247","cedabd9b82203f7e13d206fcdf4e33d92a6c53c26e5cce26d6579962c4e31df6"],["caf754272dc84563b0352b7a14311af55d245315ace27c65369e15f7151d41d1","cb474660ef35f5f2a41b643fa5e460575f4fa9b7962232a5c32f908318a04476"],["2600ca4b282cb986f85d0f1709979d8b44a09c07cb86d7c124497bc86f082120","4119b88753c15bd6a693b03fcddbb45d5ac6be74ab5f0ef44b0be9475a7e4b40"],["7635ca72d7e8432c338ec53cd12220bc01c48685e24f7dc8c602a7746998e435","91b649609489d613d1d5e590f78e6d74ecfc061d57048bad9e76f302c5b9c61"],["754e3239f325570cdbbf4a87deee8a66b7f2b33479d468fbc1a50743bf56cc18","673fb86e5bda30fb3cd0ed304ea49a023ee33d0197a695d0c5d98093c536683"],["e3e6bd1071a1e96aff57859c82d570f0330800661d1c952f9fe2694691d9b9e8","59c9e0bba394e76f40c0aa58379a3cb6a5a2283993e90c4167002af4920e37f5"],["186b483d056a033826ae73d88f732985c4ccb1f32ba35f4b4cc47fdcf04aa6eb","3b952d32c67cf77e2e17446e204180ab21fb8090895138b4a4a797f86e80888b"],["df9d70a6b9876ce544c98561f4be4f725442e6d2b737d9c91a8321724ce0963f","55eb2dafd84d6ccd5f862b785dc39d4ab157222720ef9da217b8c45cf2ba2417"],["5edd5cc23c51e87a497ca815d5dce0f8ab52554f849ed8995de64c5f34ce7143","efae9c8dbc14130661e8cec030c89ad0c13c66c0d17a2905cdc706ab7399a868"],["290798c2b6476830da12fe02287e9e777aa3fba1c355b17a722d362f84614fba","e38da76dcd440621988d00bcf79af25d5b29c094db2a23146d003afd41943e7a"],["af3c423a95d9f5b3054754efa150ac39cd29552fe360257362dfdecef4053b45","f98a3fd831eb2b749a93b0e6f35cfb40c8cd5aa667a15581bc2feded498fd9c6"],["766dbb24d134e745cccaa28c99bf274906bb66b26dcf98df8d2fed50d884249a","744b1152eacbe5e38dcc887980da38b897584a65fa06cedd2c924f97cbac5996"],["59dbf46f8c94759ba21277c33784f41645f7b44f6c596a58ce92e666191abe3e","c534ad44175fbc300f4ea6ce648309a042ce739a7919798cd85e216c4a307f6e"],["f13ada95103c4537305e691e74e9a4a8dd647e711a95e73cb62dc6018cfd87b8","e13817b44ee14de663bf4bc808341f326949e21a6a75c2570778419bdaf5733d"],["7754b4fa0e8aced06d4167a2c59cca4cda1869c06ebadfb6488550015a88522c","30e93e864e669d82224b967c3020b8fa8d1e4e350b6cbcc537a48b57841163a2"],["948dcadf5990e048aa3874d46abef9d701858f95de8041d2a6828c99e2262519","e491a42537f6e597d5d28a3224b1bc25df9154efbd2ef1d2cbba2cae5347d57e"],["7962414450c76c1689c7b48f8202ec37fb224cf5ac0bfa1570328a8a3d7c77ab","100b610ec4ffb4760d5c1fc133ef6f6b12507a051f04ac5760afa5b29db83437"],["3514087834964b54b15b160644d915485a16977225b8847bb0dd085137ec47ca","ef0afbb2056205448e1652c48e8127fc6039e77c15c2378b7e7d15a0de293311"],["d3cc30ad6b483e4bc79ce2c9dd8bc54993e947eb8df787b442943d3f7b527eaf","8b378a22d827278d89c5e9be8f9508ae3c2ad46290358630afb34db04eede0a4"],["1624d84780732860ce1c78fcbfefe08b2b29823db913f6493975ba0ff4847610","68651cf9b6da903e0914448c6cd9d4ca896878f5282be4c8cc06e2a404078575"],["733ce80da955a8a26902c95633e62a985192474b5af207da6df7b4fd5fc61cd4","f5435a2bd2badf7d485a4d8b8db9fcce3e1ef8e0201e4578c54673bc1dc5ea1d"],["15d9441254945064cf1a1c33bbd3b49f8966c5092171e699ef258dfab81c045c","d56eb30b69463e7234f5137b73b84177434800bacebfc685fc37bbe9efe4070d"],["a1d0fcf2ec9de675b612136e5ce70d271c21417c9d2b8aaaac138599d0717940","edd77f50bcb5a3cab2e90737309667f2641462a54070f3d519212d39c197a629"],["e22fbe15c0af8ccc5780c0735f84dbe9a790badee8245c06c7ca37331cb36980","a855babad5cd60c88b430a69f53a1a7a38289154964799be43d06d77d31da06"],["311091dd9860e8e20ee13473c1155f5f69635e394704eaa74009452246cfa9b3","66db656f87d1f04fffd1f04788c06830871ec5a64feee685bd80f0b1286d8374"],["34c1fd04d301be89b31c0442d3e6ac24883928b45a9340781867d4232ec2dbdf","9414685e97b1b5954bd46f730174136d57f1ceeb487443dc5321857ba73abee"],["f219ea5d6b54701c1c14de5b557eb42a8d13f3abbcd08affcc2a5e6b049b8d63","4cb95957e83d40b0f73af4544cccf6b1f4b08d3c07b27fb8d8c2962a400766d1"],["d7b8740f74a8fbaab1f683db8f45de26543a5490bca627087236912469a0b448","fa77968128d9c92ee1010f337ad4717eff15db5ed3c049b3411e0315eaa4593b"],["32d31c222f8f6f0ef86f7c98d3a3335ead5bcd32abdd94289fe4d3091aa824bf","5f3032f5892156e39ccd3d7915b9e1da2e6dac9e6f26e961118d14b8462e1661"],["7461f371914ab32671045a155d9831ea8793d77cd59592c4340f86cbc18347b5","8ec0ba238b96bec0cbdddcae0aa442542eee1ff50c986ea6b39847b3cc092ff6"],["ee079adb1df1860074356a25aa38206a6d716b2c3e67453d287698bad7b2b2d6","8dc2412aafe3be5c4c5f37e0ecc5f9f6a446989af04c4e25ebaac479ec1c8c1e"],["16ec93e447ec83f0467b18302ee620f7e65de331874c9dc72bfd8616ba9da6b5","5e4631150e62fb40d0e8c2a7ca5804a39d58186a50e497139626778e25b0674d"],["eaa5f980c245f6f038978290afa70b6bd8855897f98b6aa485b96065d537bd99","f65f5d3e292c2e0819a528391c994624d784869d7e6ea67fb18041024edc07dc"],["78c9407544ac132692ee1910a02439958ae04877151342ea96c4b6b35a49f51","f3e0319169eb9b85d5404795539a5e68fa1fbd583c064d2462b675f194a3ddb4"],["494f4be219a1a77016dcd838431aea0001cdc8ae7a6fc688726578d9702857a5","42242a969283a5f339ba7f075e36ba2af925ce30d767ed6e55f4b031880d562c"],["a598a8030da6d86c6bc7f2f5144ea549d28211ea58faa70ebf4c1e665c1fe9b5","204b5d6f84822c307e4b4a7140737aec23fc63b65b35f86a10026dbd2d864e6b"],["c41916365abb2b5d09192f5f2dbeafec208f020f12570a184dbadc3e58595997","4f14351d0087efa49d245b328984989d5caf9450f34bfc0ed16e96b58fa9913"],["841d6063a586fa475a724604da03bc5b92a2e0d2e0a36acfe4c73a5514742881","73867f59c0659e81904f9a1c7543698e62562d6744c169ce7a36de01a8d6154"],["5e95bb399a6971d376026947f89bde2f282b33810928be4ded112ac4d70e20d5","39f23f366809085beebfc71181313775a99c9aed7d8ba38b161384c746012865"],["36e4641a53948fd476c39f8a99fd974e5ec07564b5315d8bf99471bca0ef2f66","d2424b1b1abe4eb8164227b085c9aa9456ea13493fd563e06fd51cf5694c78fc"],["336581ea7bfbbb290c191a2f507a41cf5643842170e914faeab27c2c579f726","ead12168595fe1be99252129b6e56b3391f7ab1410cd1e0ef3dcdcabd2fda224"],["8ab89816dadfd6b6a1f2634fcf00ec8403781025ed6890c4849742706bd43ede","6fdcef09f2f6d0a044e654aef624136f503d459c3e89845858a47a9129cdd24e"],["1e33f1a746c9c5778133344d9299fcaa20b0938e8acff2544bb40284b8c5fb94","60660257dd11b3aa9c8ed618d24edff2306d320f1d03010e33a7d2057f3b3b6"],["85b7c1dcb3cec1b7ee7f30ded79dd20a0ed1f4cc18cbcfcfa410361fd8f08f31","3d98a9cdd026dd43f39048f25a8847f4fcafad1895d7a633c6fed3c35e999511"],["29df9fbd8d9e46509275f4b125d6d45d7fbe9a3b878a7af872a2800661ac5f51","b4c4fe99c775a606e2d8862179139ffda61dc861c019e55cd2876eb2a27d84b"],["a0b1cae06b0a847a3fea6e671aaf8adfdfe58ca2f768105c8082b2e449fce252","ae434102edde0958ec4b19d917a6a28e6b72da1834aff0e650f049503a296cf2"],["4e8ceafb9b3e9a136dc7ff67e840295b499dfb3b2133e4ba113f2e4c0e121e5","cf2174118c8b6d7a4b48f6d534ce5c79422c086a63460502b827ce62a326683c"],["d24a44e047e19b6f5afb81c7ca2f69080a5076689a010919f42725c2b789a33b","6fb8d5591b466f8fc63db50f1c0f1c69013f996887b8244d2cdec417afea8fa3"],["ea01606a7a6c9cdd249fdfcfacb99584001edd28abbab77b5104e98e8e3b35d4","322af4908c7312b0cfbfe369f7a7b3cdb7d4494bc2823700cfd652188a3ea98d"],["af8addbf2b661c8a6c6328655eb96651252007d8c5ea31be4ad196de8ce2131f","6749e67c029b85f52a034eafd096836b2520818680e26ac8f3dfbcdb71749700"],["e3ae1974566ca06cc516d47e0fb165a674a3dabcfca15e722f0e3450f45889","2aeabe7e4531510116217f07bf4d07300de97e4874f81f533420a72eeb0bd6a4"],["591ee355313d99721cf6993ffed1e3e301993ff3ed258802075ea8ced397e246","b0ea558a113c30bea60fc4775460c7901ff0b053d25ca2bdeee98f1a4be5d196"],["11396d55fda54c49f19aa97318d8da61fa8584e47b084945077cf03255b52984","998c74a8cd45ac01289d5833a7beb4744ff536b01b257be4c5767bea93ea57a4"],["3c5d2a1ba39c5a1790000738c9e0c40b8dcdfd5468754b6405540157e017aa7a","b2284279995a34e2f9d4de7396fc18b80f9b8b9fdd270f6661f79ca4c81bd257"],["cc8704b8a60a0defa3a99a7299f2e9c3fbc395afb04ac078425ef8a1793cc030","bdd46039feed17881d1e0862db347f8cf395b74fc4bcdc4e940b74e3ac1f1b13"],["c533e4f7ea8555aacd9777ac5cad29b97dd4defccc53ee7ea204119b2889b197","6f0a256bc5efdf429a2fb6242f1a43a2d9b925bb4a4b3a26bb8e0f45eb596096"],["c14f8f2ccb27d6f109f6d08d03cc96a69ba8c34eec07bbcf566d48e33da6593","c359d6923bb398f7fd4473e16fe1c28475b740dd098075e6c0e8649113dc3a38"],["a6cbc3046bc6a450bac24789fa17115a4c9739ed75f8f21ce441f72e0b90e6ef","21ae7f4680e889bb130619e2c0f95a360ceb573c70603139862afd617fa9b9f"],["347d6d9a02c48927ebfb86c1359b1caf130a3c0267d11ce6344b39f99d43cc38","60ea7f61a353524d1c987f6ecec92f086d565ab687870cb12689ff1e31c74448"],["da6545d2181db8d983f7dcb375ef5866d47c67b1bf31c8cf855ef7437b72656a","49b96715ab6878a79e78f07ce5680c5d6673051b4935bd897fea824b77dc208a"],["c40747cc9d012cb1a13b8148309c6de7ec25d6945d657146b9d5994b8feb1111","5ca560753be2a12fc6de6caf2cb489565db936156b9514e1bb5e83037e0fa2d4"],["4e42c8ec82c99798ccf3a610be870e78338c7f713348bd34c8203ef4037f3502","7571d74ee5e0fb92a7a8b33a07783341a5492144cc54bcc40a94473693606437"],["3775ab7089bc6af823aba2e1af70b236d251cadb0c86743287522a1b3b0dedea","be52d107bcfa09d8bcb9736a828cfa7fac8db17bf7a76a2c42ad961409018cf7"],["cee31cbf7e34ec379d94fb814d3d775ad954595d1314ba8846959e3e82f74e26","8fd64a14c06b589c26b947ae2bcf6bfa0149ef0be14ed4d80f448a01c43b1c6d"],["b4f9eaea09b6917619f6ea6a4eb5464efddb58fd45b1ebefcdc1a01d08b47986","39e5c9925b5a54b07433a4f18c61726f8bb131c012ca542eb24a8ac07200682a"],["d4263dfc3d2df923a0179a48966d30ce84e2515afc3dccc1b77907792ebcc60e","62dfaf07a0f78feb30e30d6295853ce189e127760ad6cf7fae164e122a208d54"],["48457524820fa65a4f8d35eb6930857c0032acc0a4a2de422233eeda897612c4","25a748ab367979d98733c38a1fa1c2e7dc6cc07db2d60a9ae7a76aaa49bd0f77"],["dfeeef1881101f2cb11644f3a2afdfc2045e19919152923f367a1767c11cceda","ecfb7056cf1de042f9420bab396793c0c390bde74b4bbdff16a83ae09a9a7517"],["6d7ef6b17543f8373c573f44e1f389835d89bcbc6062ced36c82df83b8fae859","cd450ec335438986dfefa10c57fea9bcc521a0959b2d80bbf74b190dca712d10"],["e75605d59102a5a2684500d3b991f2e3f3c88b93225547035af25af66e04541f","f5c54754a8f71ee540b9b48728473e314f729ac5308b06938360990e2bfad125"],["eb98660f4c4dfaa06a2be453d5020bc99a0c2e60abe388457dd43fefb1ed620c","6cb9a8876d9cb8520609af3add26cd20a0a7cd8a9411131ce85f44100099223e"],["13e87b027d8514d35939f2e6892b19922154596941888336dc3563e3b8dba942","fef5a3c68059a6dec5d624114bf1e91aac2b9da568d6abeb2570d55646b8adf1"],["ee163026e9fd6fe017c38f06a5be6fc125424b371ce2708e7bf4491691e5764a","1acb250f255dd61c43d94ccc670d0f58f49ae3fa15b96623e5430da0ad6c62b2"],["b268f5ef9ad51e4d78de3a750c2dc89b1e626d43505867999932e5db33af3d80","5f310d4b3c99b9ebb19f77d41c1dee018cf0d34fd4191614003e945a1216e423"],["ff07f3118a9df035e9fad85eb6c7bfe42b02f01ca99ceea3bf7ffdba93c4750d","438136d603e858a3a5c440c38eccbaddc1d2942114e2eddd4740d098ced1f0d8"],["8d8b9855c7c052a34146fd20ffb658bea4b9f69e0d825ebec16e8c3ce2b526a1","cdb559eedc2d79f926baf44fb84ea4d44bcf50fee51d7ceb30e2e7f463036758"],["52db0b5384dfbf05bfa9d472d7ae26dfe4b851ceca91b1eba54263180da32b63","c3b997d050ee5d423ebaf66a6db9f57b3180c902875679de924b69d84a7b375"],["e62f9490d3d51da6395efd24e80919cc7d0f29c3f3fa48c6fff543becbd43352","6d89ad7ba4876b0b22c2ca280c682862f342c8591f1daf5170e07bfd9ccafa7d"],["7f30ea2476b399b4957509c88f77d0191afa2ff5cb7b14fd6d8e7d65aaab1193","ca5ef7d4b231c94c3b15389a5f6311e9daff7bb67b103e9880ef4bff637acaec"],["5098ff1e1d9f14fb46a210fada6c903fef0fb7b4a1dd1d9ac60a0361800b7a00","9731141d81fc8f8084d37c6e7542006b3ee1b40d60dfe5362a5b132fd17ddc0"],["32b78c7de9ee512a72895be6b9cbefa6e2f3c4ccce445c96b9f2c81e2778ad58","ee1849f513df71e32efc3896ee28260c73bb80547ae2275ba497237794c8753c"],["e2cb74fddc8e9fbcd076eef2a7c72b0ce37d50f08269dfc074b581550547a4f7","d3aa2ed71c9dd2247a62df062736eb0baddea9e36122d2be8641abcb005cc4a4"],["8438447566d4d7bedadc299496ab357426009a35f235cb141be0d99cd10ae3a8","c4e1020916980a4da5d01ac5e6ad330734ef0d7906631c4f2390426b2edd791f"],["4162d488b89402039b584c6fc6c308870587d9c46f660b878ab65c82c711d67e","67163e903236289f776f22c25fb8a3afc1732f2b84b4e95dbda47ae5a0852649"],["3fad3fa84caf0f34f0f89bfd2dcf54fc175d767aec3e50684f3ba4a4bf5f683d","cd1bc7cb6cc407bb2f0ca647c718a730cf71872e7d0d2a53fa20efcdfe61826"],["674f2600a3007a00568c1a7ce05d0816c1fb84bf1370798f1c69532faeb1a86b","299d21f9413f33b3edf43b257004580b70db57da0b182259e09eecc69e0d38a5"],["d32f4da54ade74abb81b815ad1fb3b263d82d6c692714bcff87d29bd5ee9f08f","f9429e738b8e53b968e99016c059707782e14f4535359d582fc416910b3eea87"],["30e4e670435385556e593657135845d36fbb6931f72b08cb1ed954f1e3ce3ff6","462f9bce619898638499350113bbc9b10a878d35da70740dc695a559eb88db7b"],["be2062003c51cc3004682904330e4dee7f3dcd10b01e580bf1971b04d4cad297","62188bc49d61e5428573d48a74e1c655b1c61090905682a0d5558ed72dccb9bc"],["93144423ace3451ed29e0fb9ac2af211cb6e84a601df5993c419859fff5df04a","7c10dfb164c3425f5c71a3f9d7992038f1065224f72bb9d1d902a6d13037b47c"],["b015f8044f5fcbdcf21ca26d6c34fb8197829205c7b7d2a7cb66418c157b112c","ab8c1e086d04e813744a655b2df8d5f83b3cdc6faa3088c1d3aea1454e3a1d5f"],["d5e9e1da649d97d89e4868117a465a3a4f8a18de57a140d36b3f2af341a21b52","4cb04437f391ed73111a13cc1d4dd0db1693465c2240480d8955e8592f27447a"],["d3ae41047dd7ca065dbf8ed77b992439983005cd72e16d6f996a5316d36966bb","bd1aeb21ad22ebb22a10f0303417c6d964f8cdd7df0aca614b10dc14d125ac46"],["463e2763d885f958fc66cdd22800f0a487197d0a82e377b49f80af87c897b065","bfefacdb0e5d0fd7df3a311a94de062b26b80c61fbc97508b79992671ef7ca7f"],["7985fdfd127c0567c6f53ec1bb63ec3158e597c40bfe747c83cddfc910641917","603c12daf3d9862ef2b25fe1de289aed24ed291e0ec6708703a5bd567f32ed03"],["74a1ad6b5f76e39db2dd249410eac7f99e74c59cb83d2d0ed5ff1543da7703e9","cc6157ef18c9c63cd6193d83631bbea0093e0968942e8c33d5737fd790e0db08"],["30682a50703375f602d416664ba19b7fc9bab42c72747463a71d0896b22f6da3","553e04f6b018b4fa6c8f39e7f311d3176290d0e0f19ca73f17714d9977a22ff8"],["9e2158f0d7c0d5f26c3791efefa79597654e7a2b2464f52b1ee6c1347769ef57","712fcdd1b9053f09003a3481fa7762e9ffd7c8ef35a38509e2fbf2629008373"],["176e26989a43c9cfeba4029c202538c28172e566e3c4fce7322857f3be327d66","ed8cc9d04b29eb877d270b4878dc43c19aefd31f4eee09ee7b47834c1fa4b1c3"],["75d46efea3771e6e68abb89a13ad747ecf1892393dfc4f1b7004788c50374da8","9852390a99507679fd0b86fd2b39a868d7efc22151346e1a3ca4726586a6bed8"],["809a20c67d64900ffb698c4c825f6d5f2310fb0451c869345b7319f645605721","9e994980d9917e22b76b061927fa04143d096ccc54963e6a5ebfa5f3f8e286c1"],["1b38903a43f7f114ed4500b4eac7083fdefece1cf29c63528d563446f972c180","4036edc931a60ae889353f77fd53de4a2708b26b6f5da72ad3394119daf408f9"]]}}}),HI=w0((E)=>{var G=E,W=FI(),C=SZ(),H=BU(),z=H.assert;function V(R){if(R.type==="short")this.curve=new C.short(R);else if(R.type==="edwards")this.curve=new C.edwards(R);else this.curve=new C.mont(R);this.g=this.curve.g,this.n=this.curve.n,this.hash=R.hash,z(this.g.validate(),"Invalid curve"),z(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}G.PresetCurve=V;function P(R,S){Object.defineProperty(G,R,{configurable:!0,enumerable:!0,get:function(){var D=new V(S);return Object.defineProperty(G,R,{configurable:!0,enumerable:!0,value:D}),D}})}P("p192",{type:"short",prime:"p192",p:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff",a:"ffffffff ffffffff ffffffff fffffffe ffffffff fffffffc",b:"64210519 e59c80e7 0fa7e9ab 72243049 feb8deec c146b9b1",n:"ffffffff ffffffff ffffffff 99def836 146bc9b1 b4d22831",hash:W.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),P("p224",{type:"short",prime:"p224",p:"ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001",a:"ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff fffffffe",b:"b4050a85 0c04b3ab f5413256 5044b0b7 d7bfd8ba 270b3943 2355ffb4",n:"ffffffff ffffffff ffffffff ffff16a2 e0b8f03e 13dd2945 5c5c2a3d",hash:W.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),P("p256",{type:"short",prime:null,p:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff ffffffff",a:"ffffffff 00000001 00000000 00000000 00000000 ffffffff ffffffff fffffffc",b:"5ac635d8 aa3a93e7 b3ebbd55 769886bc 651d06b0 cc53b0f6 3bce3c3e 27d2604b",n:"ffffffff 00000000 ffffffff ffffffff bce6faad a7179e84 f3b9cac2 fc632551",hash:W.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),P("p384",{type:"short",prime:null,p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 ffffffff",a:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe ffffffff 00000000 00000000 fffffffc",b:"b3312fa7 e23ee7e4 988e056b e3f82d19 181d9c6e fe814112 0314088f 5013875a c656398d 8a2ed19d 2a85c8ed d3ec2aef",n:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff c7634d81 f4372ddf 581a0db2 48b0a77a ecec196a ccc52973",hash:W.sha384,gRed:!1,g:["aa87ca22 be8b0537 8eb1c71e f320ad74 6e1d3b62 8ba79b98 59f741e0 82542a38 5502f25d bf55296c 3a545e38 72760ab7","3617de4a 96262c6f 5d9e98bf 9292dc29 f8f41dbd 289a147c e9da3113 b5f0b8c0 0a60b1ce 1d7e819d 7a431d7c 90ea0e5f"]}),P("p521",{type:"short",prime:null,p:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff",a:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffc",b:"00000051 953eb961 8e1c9a1f 929a21a0 b68540ee a2da725b 99b315f3 b8b48991 8ef109e1 56193951 ec7e937b 1652c0bd 3bb1bf07 3573df88 3d2c34f1 ef451fd4 6b503f00",n:"000001ff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffa 51868783 bf2f966b 7fcc0148 f709a5d0 3bb5c9b8 899c47ae bb6fb71e 91386409",hash:W.sha512,gRed:!1,g:["000000c6 858e06b7 0404e9cd 9e3ecb66 2395b442 9c648139 053fb521 f828af60 6b4d3dba a14b5e77 efe75928 fe1dc127 a2ffa8de 3348b3c1 856a429b f97e7e31 c2e5bd66","00000118 39296a78 9a3bc004 5c8a5fb4 2c7d1bd9 98f54449 579b4468 17afbd17 273e662c 97ee7299 5ef42640 c550b901 3fad0761 353c7086 a272c240 88be9476 9fd16650"]}),P("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:W.sha256,gRed:!1,g:["9"]}),P("ed25519",{type:"edwards",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"-1",c:"1",d:"52036cee2b6ffe73 8cc740797779e898 00700a4d4141d8ab 75eb4dca135978a3",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:W.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});var k;try{k=BY()}catch(R){k=void 0}P("secp256k1",{type:"short",prime:"k256",p:"ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f",a:"0",b:"7",n:"ffffffff ffffffff ffffffff fffffffe baaedce6 af48a03b bfd25e8c d0364141",h:"1",hash:W.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",k]})}),xY=w0((E,G)=>{var W=FI(),C=MZ(),H=sU();function z(V){if(!(this instanceof z))return new z(V);this.hash=V.hash,this.predResist=!!V.predResist,this.outLen=this.hash.outSize,this.minEntropy=V.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var P=C.toArray(V.entropy,V.entropyEnc||"hex"),k=C.toArray(V.nonce,V.nonceEnc||"hex"),R=C.toArray(V.pers,V.persEnc||"hex");H(P.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(P,k,R)}G.exports=z,z.prototype._init=function V(P,k,R){var S=P.concat(k).concat(R);this.K=new Array(this.outLen/8),this.V=new Array(this.outLen/8);for(var D=0;D<this.V.length;D++)this.K[D]=0,this.V[D]=1;this._update(S),this._reseed=1,this.reseedInterval=281474976710656},z.prototype._hmac=function V(){return new W.hmac(this.hash,this.K)},z.prototype._update=function V(P){var k=this._hmac().update(this.V).update([0]);if(P)k=k.update(P);if(this.K=k.digest(),this.V=this._hmac().update(this.V).digest(),!P)return;this.K=this._hmac().update(this.V).update([1]).update(P).digest(),this.V=this._hmac().update(this.V).digest()},z.prototype.reseed=function V(P,k,R,S){if(typeof k!=="string")S=R,R=k,k=null;P=C.toArray(P,k),R=C.toArray(R,S),H(P.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(P.concat(R||[])),this._reseed=1},z.prototype.generate=function V(P,k,R,S){if(this._reseed>this.reseedInterval)throw new Error("Reseed is required");if(typeof k!=="string")S=R,R=k,k=null;if(R)R=C.toArray(R,S||"hex"),this._update(R);var D=[];while(D.length<P)this.V=this._hmac().update(this.V).digest(),D=D.concat(this.V);var A=D.slice(0,P);return this._update(R),this._reseed++,C.encode(A,k)}}),gY=w0((E,G)=>{var W=lU(),C=BU(),H=C.assert;function z(V,P){if(this.ec=V,this.priv=null,this.pub=null,P.priv)this._importPrivate(P.priv,P.privEnc);if(P.pub)this._importPublic(P.pub,P.pubEnc)}G.exports=z,z.fromPublic=function V(P,k,R){if(k instanceof z)return k;return new z(P,{pub:k,pubEnc:R})},z.fromPrivate=function V(P,k,R){if(k instanceof z)return k;return new z(P,{priv:k,privEnc:R})},z.prototype.validate=function V(){var P=this.getPublic();if(P.isInfinity())return{result:!1,reason:"Invalid public key"};if(!P.validate())return{result:!1,reason:"Public key is not a point"};if(!P.mul(this.ec.curve.n).isInfinity())return{result:!1,reason:"Public key * N != O"};return{result:!0,reason:null}},z.prototype.getPublic=function V(P,k){if(typeof P==="string")k=P,P=null;if(!this.pub)this.pub=this.ec.g.mul(this.priv);if(!k)return this.pub;return this.pub.encode(k,P)},z.prototype.getPrivate=function V(P){if(P==="hex")return this.priv.toString(16,2);else return this.priv},z.prototype._importPrivate=function V(P,k){this.priv=new W(P,k||16),this.priv=this.priv.umod(this.ec.curve.n)},z.prototype._importPublic=function V(P,k){if(P.x||P.y){if(this.ec.curve.type==="mont")H(P.x,"Need x coordinate");else if(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")H(P.x&&P.y,"Need both x and y coordinate");this.pub=this.ec.curve.point(P.x,P.y);return}this.pub=this.ec.curve.decodePoint(P,k)},z.prototype.derive=function V(P){if(!P.validate())H(P.validate(),"public point not validated");return P.mul(this.priv).getX()},z.prototype.sign=function V(P,k,R){return this.ec.sign(P,this,k,R)},z.prototype.verify=function V(P,k,R){return this.ec.verify(P,k,this,void 0,R)},z.prototype.inspect=function V(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}}),NY=w0((E,G)=>{var W=lU(),C=BU(),H=C.assert;function z(S,D){if(S instanceof z)return S;if(this._importDER(S,D))return;if(H(S.r&&S.s,"Signature without r or s"),this.r=new W(S.r,16),this.s=new W(S.s,16),S.recoveryParam===void 0)this.recoveryParam=null;else this.recoveryParam=S.recoveryParam}G.exports=z;function V(){this.place=0}function P(S,D){var A=S[D.place++];if(!(A&128))return A;var L=A&15;if(L===0||L>4)return!1;if(S[D.place]===0)return!1;var M=0;for(var q=0,j=D.place;q<L;q++,j++)M<<=8,M|=S[j],M>>>=0;if(M<=127)return!1;return D.place=j,M}function k(S){var D=0,A=S.length-1;while(!S[D]&&!(S[D+1]&128)&&D<A)D++;if(D===0)return S;return S.slice(D)}z.prototype._importDER=function S(D,A){D=C.toArray(D,A);var L=new V;if(D[L.place++]!==48)return!1;var M=P(D,L);if(M===!1)return!1;if(M+L.place!==D.length)return!1;if(D[L.place++]!==2)return!1;var q=P(D,L);if(q===!1)return!1;if((D[L.place]&128)!==0)return!1;var j=D.slice(L.place,q+L.place);if(L.place+=q,D[L.place++]!==2)return!1;var x=P(D,L);if(x===!1)return!1;if(D.length!==x+L.place)return!1;if((D[L.place]&128)!==0)return!1;var g=D.slice(L.place,x+L.place);if(j[0]===0)if(j[1]&128)j=j.slice(1);else return!1;if(g[0]===0)if(g[1]&128)g=g.slice(1);else return!1;return this.r=new W(j),this.s=new W(g),this.recoveryParam=null,!0};function R(S,D){if(D<128){S.push(D);return}var A=1+(Math.log(D)/Math.LN2>>>3);S.push(A|128);while(--A)S.push(D>>>(A<<3)&255);S.push(D)}z.prototype.toDER=function S(D){var A=this.r.toArray(),L=this.s.toArray();if(A[0]&128)A=[0].concat(A);if(L[0]&128)L=[0].concat(L);A=k(A),L=k(L);while(!L[0]&&!(L[1]&128))L=L.slice(1);var M=[2];R(M,A.length),M=M.concat(A),M.push(2),R(M,L.length);var q=M.concat(L),j=[48];return R(j,q.length),j=j.concat(q),C.encode(j,D)}}),_Y=w0((E,G)=>{var W=lU(),C=xY(),H=BU(),z=HI(),V=RZ(),P=H.assert,k=gY(),R=NY();function S(D){if(!(this instanceof S))return new S(D);if(typeof D==="string")P(Object.prototype.hasOwnProperty.call(z,D),"Unknown curve "+D),D=z[D];if(D instanceof z.PresetCurve)D={curve:D};this.curve=D.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=D.curve.g,this.g.precompute(D.curve.n.bitLength()+1),this.hash=D.hash||D.curve.hash}G.exports=S,S.prototype.keyPair=function D(A){return new k(this,A)},S.prototype.keyFromPrivate=function D(A,L){return k.fromPrivate(this,A,L)},S.prototype.keyFromPublic=function D(A,L){return k.fromPublic(this,A,L)},S.prototype.genKeyPair=function D(A){if(!A)A={};var L=new C({hash:this.hash,pers:A.pers,persEnc:A.persEnc||"utf8",entropy:A.entropy||V(this.hash.hmacStrength),entropyEnc:A.entropy&&A.entropyEnc||"utf8",nonce:this.n.toArray()}),M=this.n.byteLength(),q=this.n.sub(new W(2));for(;;){var j=new W(L.generate(M));if(j.cmp(q)>0)continue;return j.iaddn(1),this.keyFromPrivate(j)}},S.prototype._truncateToN=function D(A,L,M){var q;if(W.isBN(A)||typeof A==="number")A=new W(A,16),q=A.byteLength();else if(typeof A==="object")q=A.length,A=new W(A,16);else{var j=A.toString();q=j.length+1>>>1,A=new W(j,16)}if(typeof M!=="number")M=q*8;var x=M-this.n.bitLength();if(x>0)A=A.ushrn(x);if(!L&&A.cmp(this.n)>=0)return A.sub(this.n);else return A},S.prototype.sign=function D(A,L,M,q){if(typeof M==="object")q=M,M=null;if(!q)q={};if(typeof A!=="string"&&typeof A!=="number"&&!W.isBN(A)){P(typeof A==="object"&&A&&typeof A.length==="number","Expected message to be an array-like, a hex string, or a BN instance"),P(A.length>>>0===A.length);for(var j=0;j<A.length;j++)P((A[j]&255)===A[j])}L=this.keyFromPrivate(L,M),A=this._truncateToN(A,!1,q.msgBitLength),P(!A.isNeg(),"Can not sign a negative message");var x=this.n.byteLength(),g=L.getPrivate().toArray("be",x),N=A.toArray("be",x);P(new W(N).eq(A),"Can not sign message");var y=new C({hash:this.hash,entropy:g,nonce:N,pers:q.pers,persEnc:q.persEnc||"utf8"}),f=this.n.sub(new W(1));for(var o=0;;o++){var r=q.k?q.k(o):new W(y.generate(this.n.byteLength()));if(r=this._truncateToN(r,!0),r.cmpn(1)<=0||r.cmp(f)>=0)continue;var V0=this.g.mul(r);if(V0.isInfinity())continue;var Y0=V0.getX(),u=Y0.umod(this.n);if(u.cmpn(0)===0)continue;var a=r.invm(this.n).mul(u.mul(L.getPrivate()).iadd(A));if(a=a.umod(this.n),a.cmpn(0)===0)continue;var F=(V0.getY().isOdd()?1:0)|(Y0.cmp(u)!==0?2:0);if(q.canonical&&a.cmp(this.nh)>0)a=this.n.sub(a),F^=1;return new R({r:u,s:a,recoveryParam:F})}},S.prototype.verify=function D(A,L,M,q,j){if(!j)j={};A=this._truncateToN(A,!1,j.msgBitLength),M=this.keyFromPublic(M,q),L=new R(L,"hex");var{r:x,s:g}=L;if(x.cmpn(1)<0||x.cmp(this.n)>=0)return!1;if(g.cmpn(1)<0||g.cmp(this.n)>=0)return!1;var N=g.invm(this.n),y=N.mul(A).umod(this.n),f=N.mul(x).umod(this.n),o;if(!this.curve._maxwellTrick){if(o=this.g.mulAdd(y,M.getPublic(),f),o.isInfinity())return!1;return o.getX().umod(this.n).cmp(x)===0}if(o=this.g.jmulAdd(y,M.getPublic(),f),o.isInfinity())return!1;return o.eqXToP(x)},S.prototype.recoverPubKey=function(D,A,L,M){P((3&L)===L,"The recovery param is more than two bits"),A=new R(A,M);var q=this.n,j=new W(D),x=A.r,g=A.s,N=L&1,y=L>>1;if(x.cmp(this.curve.p.umod(this.curve.n))>=0&&y)throw new Error("Unable to find sencond key candinate");if(y)x=this.curve.pointFromX(x.add(this.curve.n),N);else x=this.curve.pointFromX(x,N);var f=A.r.invm(q),o=q.sub(j).mul(f).umod(q),r=g.mul(f).umod(q);return this.g.mulAdd(o,x,r)},S.prototype.getKeyRecoveryParam=function(D,A,L,M){if(A=new R(A,M),A.recoveryParam!==null)return A.recoveryParam;for(var q=0;q<4;q++){var j;try{j=this.recoverPubKey(D,A,q)}catch(x){continue}if(j.eq(L))return q}throw new Error("Unable to find valid recovery factor")}}),wY=w0((E,G)=>{var W=BU(),C=W.assert,H=W.parseBytes,z=W.cachedProperty;function V(P,k){if(this.eddsa=P,this._secret=H(k.secret),P.isPoint(k.pub))this._pub=k.pub;else this._pubBytes=H(k.pub)}V.fromPublic=function P(k,R){if(R instanceof V)return R;return new V(k,{pub:R})},V.fromSecret=function P(k,R){if(R instanceof V)return R;return new V(k,{secret:R})},V.prototype.secret=function P(){return this._secret},z(V,"pubBytes",function P(){return this.eddsa.encodePoint(this.pub())}),z(V,"pub",function P(){if(this._pubBytes)return this.eddsa.decodePoint(this._pubBytes);return this.eddsa.g.mul(this.priv())}),z(V,"privBytes",function P(){var k=this.eddsa,R=this.hash(),S=k.encodingLength-1,D=R.slice(0,k.encodingLength);return D[0]&=248,D[S]&=127,D[S]|=64,D}),z(V,"priv",function P(){return this.eddsa.decodeInt(this.privBytes())}),z(V,"hash",function P(){return this.eddsa.hash().update(this.secret()).digest()}),z(V,"messagePrefix",function P(){return this.hash().slice(this.eddsa.encodingLength)}),V.prototype.sign=function P(k){return C(this._secret,"KeyPair can only verify"),this.eddsa.sign(k,this)},V.prototype.verify=function P(k,R){return this.eddsa.verify(k,R,this)},V.prototype.getSecret=function P(k){return C(this._secret,"KeyPair is public only"),W.encode(this.secret(),k)},V.prototype.getPublic=function P(k){return W.encode(this.pubBytes(),k)},G.exports=V}),yY=w0((E,G)=>{var W=lU(),C=BU(),H=C.assert,z=C.cachedProperty,V=C.parseBytes;function P(k,R){if(this.eddsa=k,typeof R!=="object")R=V(R);if(Array.isArray(R))H(R.length===k.encodingLength*2,"Signature has invalid size"),R={R:R.slice(0,k.encodingLength),S:R.slice(k.encodingLength)};if(H(R.R&&R.S,"Signature without R or S"),k.isPoint(R.R))this._R=R.R;if(R.S instanceof W)this._S=R.S;this._Rencoded=Array.isArray(R.R)?R.R:R.Rencoded,this._Sencoded=Array.isArray(R.S)?R.S:R.Sencoded}z(P,"S",function k(){return this.eddsa.decodeInt(this.Sencoded())}),z(P,"R",function k(){return this.eddsa.decodePoint(this.Rencoded())}),z(P,"Rencoded",function k(){return this.eddsa.encodePoint(this.R())}),z(P,"Sencoded",function k(){return this.eddsa.encodeInt(this.S())}),P.prototype.toBytes=function k(){return this.Rencoded().concat(this.Sencoded())},P.prototype.toHex=function k(){return C.encode(this.toBytes(),"hex").toUpperCase()},G.exports=P}),fY=w0((E,G)=>{var W=FI(),C=HI(),H=BU(),z=H.assert,V=H.parseBytes,P=wY(),k=yY();function R(S){if(z(S==="ed25519","only tested with ed25519 so far"),!(this instanceof R))return new R(S);S=C[S].curve,this.curve=S,this.g=S.g,this.g.precompute(S.n.bitLength()+1),this.pointClass=S.point().constructor,this.encodingLength=Math.ceil(S.n.bitLength()/8),this.hash=W.sha512}G.exports=R,R.prototype.sign=function S(D,A){D=V(D);var L=this.keyFromSecret(A),M=this.hashInt(L.messagePrefix(),D),q=this.g.mul(M),j=this.encodePoint(q),x=this.hashInt(j,L.pubBytes(),D).mul(L.priv()),g=M.add(x).umod(this.curve.n);return this.makeSignature({R:q,S:g,Rencoded:j})},R.prototype.verify=function S(D,A,L){if(D=V(D),A=this.makeSignature(A),A.S().gte(A.eddsa.curve.n)||A.S().isNeg())return!1;var M=this.keyFromPublic(L),q=this.hashInt(A.Rencoded(),M.pubBytes(),D),j=this.g.mul(A.S()),x=A.R().add(M.pub().mul(q));return x.eq(j)},R.prototype.hashInt=function S(){var D=this.hash();for(var A=0;A<arguments.length;A++)D.update(arguments[A]);return H.intFromLE(D.digest()).umod(this.curve.n)},R.prototype.keyFromPublic=function S(D){return P.fromPublic(this,D)},R.prototype.keyFromSecret=function S(D){return P.fromSecret(this,D)},R.prototype.makeSignature=function S(D){if(D instanceof k)return D;return new k(this,D)},R.prototype.encodePoint=function S(D){var A=D.getY().toArray("le",this.encodingLength);return A[this.encodingLength-1]|=D.getX().isOdd()?128:0,A},R.prototype.decodePoint=function S(D){D=H.parseBytes(D);var A=D.length-1,L=D.slice(0,A).concat(D[A]&-129),M=(D[A]&128)!==0,q=H.intFromLE(L);return this.curve.pointFromY(q,M)},R.prototype.encodeInt=function S(D){return D.toArray("le",this.encodingLength)},R.prototype.decodeInt=function S(D){return H.intFromLE(D)},R.prototype.isPoint=function S(D){return D instanceof this.pointClass}}),cY=w0((E)=>{var G=E;G.version=DY().version,G.utils=BU(),G.rand=RZ(),G.curve=SZ(),G.curves=HI(),G.ec=_Y(),G.eddsa=fY()}),pY=w0((E,G)=>{(function(W,C){function H(F,U){if(!F)throw new Error(U||"Assertion failed")}function z(F,U){F.super_=U;var Z=function(){};Z.prototype=U.prototype,F.prototype=new Z,F.prototype.constructor=F}function V(F,U,Z){if(V.isBN(F))return F;if(this.negative=0,this.words=null,this.length=0,this.red=null,F!==null){if(U==="le"||U==="be")Z=U,U=10;this._init(F||0,U||10,Z||"be")}}if(typeof W==="object")W.exports=V;else C.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window!=="undefined"&&typeof window.Buffer!=="undefined")P=window.Buffer;else P=(HU(),y0(FU)).Buffer}catch(F){}V.isBN=function F(U){if(U instanceof V)return!0;return U!==null&&typeof U==="object"&&U.constructor.wordSize===V.wordSize&&Array.isArray(U.words)},V.max=function F(U,Z){if(U.cmp(Z)>0)return U;return Z},V.min=function F(U,Z){if(U.cmp(Z)<0)return U;return Z},V.prototype._init=function F(U,Z,Q){if(typeof U==="number")return this._initNumber(U,Z,Q);if(typeof U==="object")return this._initArray(U,Z,Q);if(Z==="hex")Z=16;H(Z===(Z|0)&&Z>=2&&Z<=36),U=U.toString().replace(/\s+/g,"");var I=0;if(U[0]==="-")I++,this.negative=1;if(I<U.length){if(Z===16)this._parseHex(U,I,Q);else if(this._parseBase(U,Z,I),Q==="le")this._initArray(this.toArray(),Z,Q)}},V.prototype._initNumber=function F(U,Z,Q){if(U<0)this.negative=1,U=-U;if(U<67108864)this.words=[U&67108863],this.length=1;else if(U<4503599627370496)this.words=[U&67108863,U/67108864&67108863],this.length=2;else H(U<9007199254740992),this.words=[U&67108863,U/67108864&67108863,1],this.length=3;if(Q!=="le")return;this._initArray(this.toArray(),Z,Q)},V.prototype._initArray=function F(U,Z,Q){if(H(typeof U.length==="number"),U.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(U.length/3),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $,K,J=0;if(Q==="be"){for(I=U.length-1,$=0;I>=0;I-=3)if(K=U[I]|U[I-1]<<8|U[I-2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}else if(Q==="le"){for(I=0,$=0;I<U.length;I+=3)if(K=U[I]|U[I+1]<<8|U[I+2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}return this.strip()};function k(F,U){var Z=F.charCodeAt(U);if(Z>=65&&Z<=70)return Z-55;else if(Z>=97&&Z<=102)return Z-87;else return Z-48&15}function R(F,U,Z){var Q=k(F,Z);if(Z-1>=U)Q|=k(F,Z-1)<<4;return Q}V.prototype._parseHex=function F(U,Z,Q){this.length=Math.ceil((U.length-Z)/6),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $=0,K=0,J;if(Q==="be")for(I=U.length-1;I>=Z;I-=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8;else{var Y=U.length-Z;for(I=Y%2===0?Z+1:Z;I<U.length;I+=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8}this.strip()};function S(F,U,Z,Q){var I=0,$=Math.min(F.length,Z);for(var K=U;K<$;K++){var J=F.charCodeAt(K)-48;if(I*=Q,J>=49)I+=J-49+10;else if(J>=17)I+=J-17+10;else I+=J}return I}V.prototype._parseBase=function F(U,Z,Q){this.words=[0],this.length=1;for(var I=0,$=1;$<=67108863;$*=Z)I++;I--,$=$/Z|0;var K=U.length-Q,J=K%I,Y=Math.min(K,K-J)+Q,X=0;for(var O=Q;O<Y;O+=I)if(X=S(U,O,O+I,Z),this.imuln($),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(J!==0){var v=1;X=S(U,O,U.length,Z);for(O=0;O<J;O++)v*=Z;if(this.imuln(v),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function F(U){U.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)U.words[Z]=this.words[Z];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function F(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function F(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function F(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function F(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function F(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],L=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];if(V.prototype.toString=function F(U,Z){U=U||10,Z=Z|0||1;var Q;if(U===16||U==="hex"){Q="";var I=0,$=0;for(var K=0;K<this.length;K++){var J=this.words[K],Y=((J<<I|$)&16777215).toString(16);if($=J>>>24-I&16777215,I+=2,I>=26)I-=26,K--;if($!==0||K!==this.length-1)Q=D[6-Y.length]+Y+Q;else Q=Y+Q}if($!==0)Q=$.toString(16)+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}if(U===(U|0)&&U>=2&&U<=36){var X=A[U],O=L[U];Q="";var v=this.clone();v.negative=0;while(!v.isZero()){var T=v.modn(O).toString(U);if(v=v.idivn(O),!v.isZero())Q=D[X-T.length]+T+Q;else Q=T+Q}if(this.isZero())Q="0"+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function F(){var U=this.words[0];if(this.length===2)U+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)U+=4503599627370496+this.words[1]*67108864;else if(this.length>2)H(!1,"Number can only safely store up to 53 bits");return this.negative!==0?-U:U},V.prototype.toJSON=function F(){return this.toString(16)},V.prototype.toBuffer=function F(U,Z){return H(typeof P!=="undefined"),this.toArrayLike(P,U,Z)},V.prototype.toArray=function F(U,Z){return this.toArrayLike(Array,U,Z)},V.prototype.toArrayLike=function F(U,Z,Q){var I=this.byteLength(),$=Q||Math.max(1,I);H(I<=$,"byte array longer than desired length"),H($>0,"Requested array length <= 0"),this.strip();var K=Z==="le",J=new U($),Y,X,O=this.clone();if(!K){for(X=0;X<$-I;X++)J[X]=0;for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[$-X-1]=Y}else{for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[X]=Y;for(;X<$;X++)J[X]=0}return J},Math.clz32)V.prototype._countBits=function F(U){return 32-Math.clz32(U)};else V.prototype._countBits=function F(U){var Z=U,Q=0;if(Z>=4096)Q+=13,Z>>>=13;if(Z>=64)Q+=7,Z>>>=7;if(Z>=8)Q+=4,Z>>>=4;if(Z>=2)Q+=2,Z>>>=2;return Q+Z};V.prototype._zeroBits=function F(U){if(U===0)return 26;var Z=U,Q=0;if((Z&8191)===0)Q+=13,Z>>>=13;if((Z&127)===0)Q+=7,Z>>>=7;if((Z&15)===0)Q+=4,Z>>>=4;if((Z&3)===0)Q+=2,Z>>>=2;if((Z&1)===0)Q++;return Q},V.prototype.bitLength=function F(){var U=this.words[this.length-1],Z=this._countBits(U);return(this.length-1)*26+Z};function M(F){var U=new Array(F.bitLength());for(var Z=0;Z<U.length;Z++){var Q=Z/26|0,I=Z%26;U[Z]=(F.words[Q]&1<<I)>>>I}return U}V.prototype.zeroBits=function F(){if(this.isZero())return 0;var U=0;for(var Z=0;Z<this.length;Z++){var Q=this._zeroBits(this.words[Z]);if(U+=Q,Q!==26)break}return U},V.prototype.byteLength=function F(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function F(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function F(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function F(){return this.negative!==0},V.prototype.neg=function F(){return this.clone().ineg()},V.prototype.ineg=function F(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function F(U){while(this.length<U.length)this.words[this.length++]=0;for(var Z=0;Z<U.length;Z++)this.words[Z]=this.words[Z]|U.words[Z];return this.strip()},V.prototype.ior=function F(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function F(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function F(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function F(U){var Z;if(this.length>U.length)Z=U;else Z=this;for(var Q=0;Q<Z.length;Q++)this.words[Q]=this.words[Q]&U.words[Q];return this.length=Z.length,this.strip()},V.prototype.iand=function F(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function F(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function F(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function F(U){var Z,Q;if(this.length>U.length)Z=this,Q=U;else Z=U,Q=this;for(var I=0;I<Q.length;I++)this.words[I]=Z.words[I]^Q.words[I];if(this!==Z)for(;I<Z.length;I++)this.words[I]=Z.words[I];return this.length=Z.length,this.strip()},V.prototype.ixor=function F(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function F(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function F(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function F(U){H(typeof U==="number"&&U>=0);var Z=Math.ceil(U/26)|0,Q=U%26;if(this._expand(Z),Q>0)Z--;for(var I=0;I<Z;I++)this.words[I]=~this.words[I]&67108863;if(Q>0)this.words[I]=~this.words[I]&67108863>>26-Q;return this.strip()},V.prototype.notn=function F(U){return this.clone().inotn(U)},V.prototype.setn=function F(U,Z){H(typeof U==="number"&&U>=0);var Q=U/26|0,I=U%26;if(this._expand(Q+1),Z)this.words[Q]=this.words[Q]|1<<I;else this.words[Q]=this.words[Q]&~(1<<I);return this.strip()},V.prototype.iadd=function F(U){var Z;if(this.negative!==0&&U.negative===0)return this.negative=0,Z=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Z=this.isub(U),U.negative=1,Z._normSign();var Q,I;if(this.length>U.length)Q=this,I=U;else Q=U,I=this;var $=0;for(var K=0;K<I.length;K++)Z=(Q.words[K]|0)+(I.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;for(;$!==0&&K<Q.length;K++)Z=(Q.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;if(this.length=Q.length,$!==0)this.words[this.length]=$,this.length++;else if(Q!==this)for(;K<Q.length;K++)this.words[K]=Q.words[K];return this},V.prototype.add=function F(U){var Z;if(U.negative!==0&&this.negative===0)return U.negative=0,Z=this.sub(U),U.negative^=1,Z;else if(U.negative===0&&this.negative!==0)return this.negative=0,Z=U.sub(this),this.negative=1,Z;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function F(U){if(U.negative!==0){U.negative=0;var Z=this.iadd(U);return U.negative=1,Z._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var Q=this.cmp(U);if(Q===0)return this.negative=0,this.length=1,this.words[0]=0,this;var I,$;if(Q>0)I=this,$=U;else I=U,$=this;var K=0;for(var J=0;J<$.length;J++)Z=(I.words[J]|0)-($.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;for(;K!==0&&J<I.length;J++)Z=(I.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;if(K===0&&J<I.length&&I!==this)for(;J<I.length;J++)this.words[J]=I.words[J];if(this.length=Math.max(this.length,J),I!==this)this.negative=1;return this.strip()},V.prototype.sub=function F(U){return this.clone().isub(U)};function q(F,U,Z){Z.negative=U.negative^F.negative;var Q=F.length+U.length|0;Z.length=Q,Q=Q-1|0;var I=F.words[0]|0,$=U.words[0]|0,K=I*$,J=K&67108863,Y=K/67108864|0;Z.words[0]=J;for(var X=1;X<Q;X++){var O=Y>>>26,v=Y&67108863,T=Math.min(X,U.length-1);for(var B=Math.max(0,X-F.length+1);B<=T;B++){var c=X-B|0;I=F.words[c]|0,$=U.words[B]|0,K=I*$+v,O+=K/67108864|0,v=K&67108863}Z.words[X]=v|0,Y=O|0}if(Y!==0)Z.words[X]=Y|0;else Z.length--;return Z.strip()}var j=function F(U,Z,Q){var I=U.words,$=Z.words,K=Q.words,J=0,Y,X,O,v=I[0]|0,T=v&8191,B=v>>>13,c=I[1]|0,l=c&8191,s=c>>>13,O0=I[2]|0,h=O0&8191,d=O0>>>13,g0=I[3]|0,Q0=g0&8191,$0=g0>>>13,m=I[4]|0,p=m&8191,b=m>>>13,N0=I[5]|0,i=N0&8191,e=N0>>>13,t=I[6]|0,n=t&8191,X0=t>>>13,H0=I[7]|0,Z0=H0&8191,W0=H0>>>13,c0=I[8]|0,G0=c0&8191,A0=c0>>>13,u0=I[9]|0,J0=u0&8191,T0=u0>>>13,r0=$[0]|0,E0=r0&8191,v0=r0>>>13,AU=$[1]|0,k0=AU&8191,j0=AU>>>13,DU=$[2]|0,R0=DU&8191,S0=DU>>>13,LU=$[3]|0,P0=LU&8191,D0=LU>>>13,zU=$[4]|0,B0=zU&8191,L0=zU>>>13,EU=$[5]|0,_=EU&8191,w=EU>>>13,_0=$[6]|0,U0=_0&8191,I0=_0>>>13,l0=$[7]|0,F0=l0&8191,C0=l0>>>13,CU=$[8]|0,x0=CU&8191,q0=CU>>>13,TU=$[9]|0,z0=TU&8191,M0=TU>>>13;Q.negative=U.negative^Z.negative,Q.length=19,Y=Math.imul(T,E0),X=Math.imul(T,v0),X=X+Math.imul(B,E0)|0,O=Math.imul(B,v0);var t0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(t0>>>26)|0,t0&=67108863,Y=Math.imul(l,E0),X=Math.imul(l,v0),X=X+Math.imul(s,E0)|0,O=Math.imul(s,v0),Y=Y+Math.imul(T,k0)|0,X=X+Math.imul(T,j0)|0,X=X+Math.imul(B,k0)|0,O=O+Math.imul(B,j0)|0;var p0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(p0>>>26)|0,p0&=67108863,Y=Math.imul(h,E0),X=Math.imul(h,v0),X=X+Math.imul(d,E0)|0,O=Math.imul(d,v0),Y=Y+Math.imul(l,k0)|0,X=X+Math.imul(l,j0)|0,X=X+Math.imul(s,k0)|0,O=O+Math.imul(s,j0)|0,Y=Y+Math.imul(T,R0)|0,X=X+Math.imul(T,S0)|0,X=X+Math.imul(B,R0)|0,O=O+Math.imul(B,S0)|0;var f0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(f0>>>26)|0,f0&=67108863,Y=Math.imul(Q0,E0),X=Math.imul(Q0,v0),X=X+Math.imul($0,E0)|0,O=Math.imul($0,v0),Y=Y+Math.imul(h,k0)|0,X=X+Math.imul(h,j0)|0,X=X+Math.imul(d,k0)|0,O=O+Math.imul(d,j0)|0,Y=Y+Math.imul(l,R0)|0,X=X+Math.imul(l,S0)|0,X=X+Math.imul(s,R0)|0,O=O+Math.imul(s,S0)|0,Y=Y+Math.imul(T,P0)|0,X=X+Math.imul(T,D0)|0,X=X+Math.imul(B,P0)|0,O=O+Math.imul(B,D0)|0;var b0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,Y=Math.imul(p,E0),X=Math.imul(p,v0),X=X+Math.imul(b,E0)|0,O=Math.imul(b,v0),Y=Y+Math.imul(Q0,k0)|0,X=X+Math.imul(Q0,j0)|0,X=X+Math.imul($0,k0)|0,O=O+Math.imul($0,j0)|0,Y=Y+Math.imul(h,R0)|0,X=X+Math.imul(h,S0)|0,X=X+Math.imul(d,R0)|0,O=O+Math.imul(d,S0)|0,Y=Y+Math.imul(l,P0)|0,X=X+Math.imul(l,D0)|0,X=X+Math.imul(s,P0)|0,O=O+Math.imul(s,D0)|0,Y=Y+Math.imul(T,B0)|0,X=X+Math.imul(T,L0)|0,X=X+Math.imul(B,B0)|0,O=O+Math.imul(B,L0)|0;var a0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,Y=Math.imul(i,E0),X=Math.imul(i,v0),X=X+Math.imul(e,E0)|0,O=Math.imul(e,v0),Y=Y+Math.imul(p,k0)|0,X=X+Math.imul(p,j0)|0,X=X+Math.imul(b,k0)|0,O=O+Math.imul(b,j0)|0,Y=Y+Math.imul(Q0,R0)|0,X=X+Math.imul(Q0,S0)|0,X=X+Math.imul($0,R0)|0,O=O+Math.imul($0,S0)|0,Y=Y+Math.imul(h,P0)|0,X=X+Math.imul(h,D0)|0,X=X+Math.imul(d,P0)|0,O=O+Math.imul(d,D0)|0,Y=Y+Math.imul(l,B0)|0,X=X+Math.imul(l,L0)|0,X=X+Math.imul(s,B0)|0,O=O+Math.imul(s,L0)|0,Y=Y+Math.imul(T,_)|0,X=X+Math.imul(T,w)|0,X=X+Math.imul(B,_)|0,O=O+Math.imul(B,w)|0;var e0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,Y=Math.imul(n,E0),X=Math.imul(n,v0),X=X+Math.imul(X0,E0)|0,O=Math.imul(X0,v0),Y=Y+Math.imul(i,k0)|0,X=X+Math.imul(i,j0)|0,X=X+Math.imul(e,k0)|0,O=O+Math.imul(e,j0)|0,Y=Y+Math.imul(p,R0)|0,X=X+Math.imul(p,S0)|0,X=X+Math.imul(b,R0)|0,O=O+Math.imul(b,S0)|0,Y=Y+Math.imul(Q0,P0)|0,X=X+Math.imul(Q0,D0)|0,X=X+Math.imul($0,P0)|0,O=O+Math.imul($0,D0)|0,Y=Y+Math.imul(h,B0)|0,X=X+Math.imul(h,L0)|0,X=X+Math.imul(d,B0)|0,O=O+Math.imul(d,L0)|0,Y=Y+Math.imul(l,_)|0,X=X+Math.imul(l,w)|0,X=X+Math.imul(s,_)|0,O=O+Math.imul(s,w)|0,Y=Y+Math.imul(T,U0)|0,X=X+Math.imul(T,I0)|0,X=X+Math.imul(B,U0)|0,O=O+Math.imul(B,I0)|0;var i0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,Y=Math.imul(Z0,E0),X=Math.imul(Z0,v0),X=X+Math.imul(W0,E0)|0,O=Math.imul(W0,v0),Y=Y+Math.imul(n,k0)|0,X=X+Math.imul(n,j0)|0,X=X+Math.imul(X0,k0)|0,O=O+Math.imul(X0,j0)|0,Y=Y+Math.imul(i,R0)|0,X=X+Math.imul(i,S0)|0,X=X+Math.imul(e,R0)|0,O=O+Math.imul(e,S0)|0,Y=Y+Math.imul(p,P0)|0,X=X+Math.imul(p,D0)|0,X=X+Math.imul(b,P0)|0,O=O+Math.imul(b,D0)|0,Y=Y+Math.imul(Q0,B0)|0,X=X+Math.imul(Q0,L0)|0,X=X+Math.imul($0,B0)|0,O=O+Math.imul($0,L0)|0,Y=Y+Math.imul(h,_)|0,X=X+Math.imul(h,w)|0,X=X+Math.imul(d,_)|0,O=O+Math.imul(d,w)|0,Y=Y+Math.imul(l,U0)|0,X=X+Math.imul(l,I0)|0,X=X+Math.imul(s,U0)|0,O=O+Math.imul(s,I0)|0,Y=Y+Math.imul(T,F0)|0,X=X+Math.imul(T,C0)|0,X=X+Math.imul(B,F0)|0,O=O+Math.imul(B,C0)|0;var UU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,Y=Math.imul(G0,E0),X=Math.imul(G0,v0),X=X+Math.imul(A0,E0)|0,O=Math.imul(A0,v0),Y=Y+Math.imul(Z0,k0)|0,X=X+Math.imul(Z0,j0)|0,X=X+Math.imul(W0,k0)|0,O=O+Math.imul(W0,j0)|0,Y=Y+Math.imul(n,R0)|0,X=X+Math.imul(n,S0)|0,X=X+Math.imul(X0,R0)|0,O=O+Math.imul(X0,S0)|0,Y=Y+Math.imul(i,P0)|0,X=X+Math.imul(i,D0)|0,X=X+Math.imul(e,P0)|0,O=O+Math.imul(e,D0)|0,Y=Y+Math.imul(p,B0)|0,X=X+Math.imul(p,L0)|0,X=X+Math.imul(b,B0)|0,O=O+Math.imul(b,L0)|0,Y=Y+Math.imul(Q0,_)|0,X=X+Math.imul(Q0,w)|0,X=X+Math.imul($0,_)|0,O=O+Math.imul($0,w)|0,Y=Y+Math.imul(h,U0)|0,X=X+Math.imul(h,I0)|0,X=X+Math.imul(d,U0)|0,O=O+Math.imul(d,I0)|0,Y=Y+Math.imul(l,F0)|0,X=X+Math.imul(l,C0)|0,X=X+Math.imul(s,F0)|0,O=O+Math.imul(s,C0)|0,Y=Y+Math.imul(T,x0)|0,X=X+Math.imul(T,q0)|0,X=X+Math.imul(B,x0)|0,O=O+Math.imul(B,q0)|0;var XU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,Y=Math.imul(J0,E0),X=Math.imul(J0,v0),X=X+Math.imul(T0,E0)|0,O=Math.imul(T0,v0),Y=Y+Math.imul(G0,k0)|0,X=X+Math.imul(G0,j0)|0,X=X+Math.imul(A0,k0)|0,O=O+Math.imul(A0,j0)|0,Y=Y+Math.imul(Z0,R0)|0,X=X+Math.imul(Z0,S0)|0,X=X+Math.imul(W0,R0)|0,O=O+Math.imul(W0,S0)|0,Y=Y+Math.imul(n,P0)|0,X=X+Math.imul(n,D0)|0,X=X+Math.imul(X0,P0)|0,O=O+Math.imul(X0,D0)|0,Y=Y+Math.imul(i,B0)|0,X=X+Math.imul(i,L0)|0,X=X+Math.imul(e,B0)|0,O=O+Math.imul(e,L0)|0,Y=Y+Math.imul(p,_)|0,X=X+Math.imul(p,w)|0,X=X+Math.imul(b,_)|0,O=O+Math.imul(b,w)|0,Y=Y+Math.imul(Q0,U0)|0,X=X+Math.imul(Q0,I0)|0,X=X+Math.imul($0,U0)|0,O=O+Math.imul($0,I0)|0,Y=Y+Math.imul(h,F0)|0,X=X+Math.imul(h,C0)|0,X=X+Math.imul(d,F0)|0,O=O+Math.imul(d,C0)|0,Y=Y+Math.imul(l,x0)|0,X=X+Math.imul(l,q0)|0,X=X+Math.imul(s,x0)|0,O=O+Math.imul(s,q0)|0,Y=Y+Math.imul(T,z0)|0,X=X+Math.imul(T,M0)|0,X=X+Math.imul(B,z0)|0,O=O+Math.imul(B,M0)|0;var IU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,Y=Math.imul(J0,k0),X=Math.imul(J0,j0),X=X+Math.imul(T0,k0)|0,O=Math.imul(T0,j0),Y=Y+Math.imul(G0,R0)|0,X=X+Math.imul(G0,S0)|0,X=X+Math.imul(A0,R0)|0,O=O+Math.imul(A0,S0)|0,Y=Y+Math.imul(Z0,P0)|0,X=X+Math.imul(Z0,D0)|0,X=X+Math.imul(W0,P0)|0,O=O+Math.imul(W0,D0)|0,Y=Y+Math.imul(n,B0)|0,X=X+Math.imul(n,L0)|0,X=X+Math.imul(X0,B0)|0,O=O+Math.imul(X0,L0)|0,Y=Y+Math.imul(i,_)|0,X=X+Math.imul(i,w)|0,X=X+Math.imul(e,_)|0,O=O+Math.imul(e,w)|0,Y=Y+Math.imul(p,U0)|0,X=X+Math.imul(p,I0)|0,X=X+Math.imul(b,U0)|0,O=O+Math.imul(b,I0)|0,Y=Y+Math.imul(Q0,F0)|0,X=X+Math.imul(Q0,C0)|0,X=X+Math.imul($0,F0)|0,O=O+Math.imul($0,C0)|0,Y=Y+Math.imul(h,x0)|0,X=X+Math.imul(h,q0)|0,X=X+Math.imul(d,x0)|0,O=O+Math.imul(d,q0)|0,Y=Y+Math.imul(l,z0)|0,X=X+Math.imul(l,M0)|0,X=X+Math.imul(s,z0)|0,O=O+Math.imul(s,M0)|0;var ZU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,Y=Math.imul(J0,R0),X=Math.imul(J0,S0),X=X+Math.imul(T0,R0)|0,O=Math.imul(T0,S0),Y=Y+Math.imul(G0,P0)|0,X=X+Math.imul(G0,D0)|0,X=X+Math.imul(A0,P0)|0,O=O+Math.imul(A0,D0)|0,Y=Y+Math.imul(Z0,B0)|0,X=X+Math.imul(Z0,L0)|0,X=X+Math.imul(W0,B0)|0,O=O+Math.imul(W0,L0)|0,Y=Y+Math.imul(n,_)|0,X=X+Math.imul(n,w)|0,X=X+Math.imul(X0,_)|0,O=O+Math.imul(X0,w)|0,Y=Y+Math.imul(i,U0)|0,X=X+Math.imul(i,I0)|0,X=X+Math.imul(e,U0)|0,O=O+Math.imul(e,I0)|0,Y=Y+Math.imul(p,F0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(b,F0)|0,O=O+Math.imul(b,C0)|0,Y=Y+Math.imul(Q0,x0)|0,X=X+Math.imul(Q0,q0)|0,X=X+Math.imul($0,x0)|0,O=O+Math.imul($0,q0)|0,Y=Y+Math.imul(h,z0)|0,X=X+Math.imul(h,M0)|0,X=X+Math.imul(d,z0)|0,O=O+Math.imul(d,M0)|0;var QU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,Y=Math.imul(J0,P0),X=Math.imul(J0,D0),X=X+Math.imul(T0,P0)|0,O=Math.imul(T0,D0),Y=Y+Math.imul(G0,B0)|0,X=X+Math.imul(G0,L0)|0,X=X+Math.imul(A0,B0)|0,O=O+Math.imul(A0,L0)|0,Y=Y+Math.imul(Z0,_)|0,X=X+Math.imul(Z0,w)|0,X=X+Math.imul(W0,_)|0,O=O+Math.imul(W0,w)|0,Y=Y+Math.imul(n,U0)|0,X=X+Math.imul(n,I0)|0,X=X+Math.imul(X0,U0)|0,O=O+Math.imul(X0,I0)|0,Y=Y+Math.imul(i,F0)|0,X=X+Math.imul(i,C0)|0,X=X+Math.imul(e,F0)|0,O=O+Math.imul(e,C0)|0,Y=Y+Math.imul(p,x0)|0,X=X+Math.imul(p,q0)|0,X=X+Math.imul(b,x0)|0,O=O+Math.imul(b,q0)|0,Y=Y+Math.imul(Q0,z0)|0,X=X+Math.imul(Q0,M0)|0,X=X+Math.imul($0,z0)|0,O=O+Math.imul($0,M0)|0;var $U=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,Y=Math.imul(J0,B0),X=Math.imul(J0,L0),X=X+Math.imul(T0,B0)|0,O=Math.imul(T0,L0),Y=Y+Math.imul(G0,_)|0,X=X+Math.imul(G0,w)|0,X=X+Math.imul(A0,_)|0,O=O+Math.imul(A0,w)|0,Y=Y+Math.imul(Z0,U0)|0,X=X+Math.imul(Z0,I0)|0,X=X+Math.imul(W0,U0)|0,O=O+Math.imul(W0,I0)|0,Y=Y+Math.imul(n,F0)|0,X=X+Math.imul(n,C0)|0,X=X+Math.imul(X0,F0)|0,O=O+Math.imul(X0,C0)|0,Y=Y+Math.imul(i,x0)|0,X=X+Math.imul(i,q0)|0,X=X+Math.imul(e,x0)|0,O=O+Math.imul(e,q0)|0,Y=Y+Math.imul(p,z0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(b,z0)|0,O=O+Math.imul(b,M0)|0;var YU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,Y=Math.imul(J0,_),X=Math.imul(J0,w),X=X+Math.imul(T0,_)|0,O=Math.imul(T0,w),Y=Y+Math.imul(G0,U0)|0,X=X+Math.imul(G0,I0)|0,X=X+Math.imul(A0,U0)|0,O=O+Math.imul(A0,I0)|0,Y=Y+Math.imul(Z0,F0)|0,X=X+Math.imul(Z0,C0)|0,X=X+Math.imul(W0,F0)|0,O=O+Math.imul(W0,C0)|0,Y=Y+Math.imul(n,x0)|0,X=X+Math.imul(n,q0)|0,X=X+Math.imul(X0,x0)|0,O=O+Math.imul(X0,q0)|0,Y=Y+Math.imul(i,z0)|0,X=X+Math.imul(i,M0)|0,X=X+Math.imul(e,z0)|0,O=O+Math.imul(e,M0)|0;var VU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,Y=Math.imul(J0,U0),X=Math.imul(J0,I0),X=X+Math.imul(T0,U0)|0,O=Math.imul(T0,I0),Y=Y+Math.imul(G0,F0)|0,X=X+Math.imul(G0,C0)|0,X=X+Math.imul(A0,F0)|0,O=O+Math.imul(A0,C0)|0,Y=Y+Math.imul(Z0,x0)|0,X=X+Math.imul(Z0,q0)|0,X=X+Math.imul(W0,x0)|0,O=O+Math.imul(W0,q0)|0,Y=Y+Math.imul(n,z0)|0,X=X+Math.imul(n,M0)|0,X=X+Math.imul(X0,z0)|0,O=O+Math.imul(X0,M0)|0;var OU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(OU>>>26)|0,OU&=67108863,Y=Math.imul(J0,F0),X=Math.imul(J0,C0),X=X+Math.imul(T0,F0)|0,O=Math.imul(T0,C0),Y=Y+Math.imul(G0,x0)|0,X=X+Math.imul(G0,q0)|0,X=X+Math.imul(A0,x0)|0,O=O+Math.imul(A0,q0)|0,Y=Y+Math.imul(Z0,z0)|0,X=X+Math.imul(Z0,M0)|0,X=X+Math.imul(W0,z0)|0,O=O+Math.imul(W0,M0)|0;var GU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,Y=Math.imul(J0,x0),X=Math.imul(J0,q0),X=X+Math.imul(T0,x0)|0,O=Math.imul(T0,q0),Y=Y+Math.imul(G0,z0)|0,X=X+Math.imul(G0,M0)|0,X=X+Math.imul(A0,z0)|0,O=O+Math.imul(A0,M0)|0;var KU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(KU>>>26)|0,KU&=67108863,Y=Math.imul(J0,z0),X=Math.imul(J0,M0),X=X+Math.imul(T0,z0)|0,O=Math.imul(T0,M0);var WU=(J+Y|0)+((X&8191)<<13)|0;if(J=(O+(X>>>13)|0)+(WU>>>26)|0,WU&=67108863,K[0]=t0,K[1]=p0,K[2]=f0,K[3]=b0,K[4]=a0,K[5]=e0,K[6]=i0,K[7]=UU,K[8]=XU,K[9]=IU,K[10]=ZU,K[11]=QU,K[12]=$U,K[13]=YU,K[14]=VU,K[15]=OU,K[16]=GU,K[17]=KU,K[18]=WU,J!==0)K[19]=J,Q.length++;return Q};if(!Math.imul)j=q;function x(F,U,Z){Z.negative=U.negative^F.negative,Z.length=F.length+U.length;var Q=0,I=0;for(var $=0;$<Z.length-1;$++){var K=I;I=0;var J=Q&67108863,Y=Math.min($,U.length-1);for(var X=Math.max(0,$-F.length+1);X<=Y;X++){var O=$-X,v=F.words[O]|0,T=U.words[X]|0,B=v*T,c=B&67108863;K=K+(B/67108864|0)|0,c=c+J|0,J=c&67108863,K=K+(c>>>26)|0,I+=K>>>26,K&=67108863}Z.words[$]=J,Q=K,K=I}if(Q!==0)Z.words[$]=Q;else Z.length--;return Z.strip()}function g(F,U,Z){var Q=new N;return Q.mulp(F,U,Z)}V.prototype.mulTo=function F(U,Z){var Q,I=this.length+U.length;if(this.length===10&&U.length===10)Q=j(this,U,Z);else if(I<63)Q=q(this,U,Z);else if(I<1024)Q=x(this,U,Z);else Q=g(this,U,Z);return Q};function N(F,U){this.x=F,this.y=U}N.prototype.makeRBT=function F(U){var Z=new Array(U),Q=V.prototype._countBits(U)-1;for(var I=0;I<U;I++)Z[I]=this.revBin(I,Q,U);return Z},N.prototype.revBin=function F(U,Z,Q){if(U===0||U===Q-1)return U;var I=0;for(var $=0;$<Z;$++)I|=(U&1)<<Z-$-1,U>>=1;return I},N.prototype.permute=function F(U,Z,Q,I,$,K){for(var J=0;J<K;J++)I[J]=Z[U[J]],$[J]=Q[U[J]]},N.prototype.transform=function F(U,Z,Q,I,$,K){this.permute(K,U,Z,Q,I,$);for(var J=1;J<$;J<<=1){var Y=J<<1,X=Math.cos(2*Math.PI/Y),O=Math.sin(2*Math.PI/Y);for(var v=0;v<$;v+=Y){var T=X,B=O;for(var c=0;c<J;c++){var l=Q[v+c],s=I[v+c],O0=Q[v+c+J],h=I[v+c+J],d=T*O0-B*h;if(h=T*h+B*O0,O0=d,Q[v+c]=l+O0,I[v+c]=s+h,Q[v+c+J]=l-O0,I[v+c+J]=s-h,c!==Y)d=X*T-O*B,B=X*B+O*T,T=d}}}},N.prototype.guessLen13b=function F(U,Z){var Q=Math.max(Z,U)|1,I=Q&1,$=0;for(Q=Q/2|0;Q;Q=Q>>>1)$++;return 1<<$+1+I},N.prototype.conjugate=function F(U,Z,Q){if(Q<=1)return;for(var I=0;I<Q/2;I++){var $=U[I];U[I]=U[Q-I-1],U[Q-I-1]=$,$=Z[I],Z[I]=-Z[Q-I-1],Z[Q-I-1]=-$}},N.prototype.normalize13b=function F(U,Z){var Q=0;for(var I=0;I<Z/2;I++){var $=Math.round(U[2*I+1]/Z)*8192+Math.round(U[2*I]/Z)+Q;if(U[I]=$&67108863,$<67108864)Q=0;else Q=$/67108864|0}return U},N.prototype.convert13b=function F(U,Z,Q,I){var $=0;for(var K=0;K<Z;K++)$=$+(U[K]|0),Q[2*K]=$&8191,$=$>>>13,Q[2*K+1]=$&8191,$=$>>>13;for(K=2*Z;K<I;++K)Q[K]=0;H($===0),H(($&-8192)===0)},N.prototype.stub=function F(U){var Z=new Array(U);for(var Q=0;Q<U;Q++)Z[Q]=0;return Z},N.prototype.mulp=function F(U,Z,Q){var I=2*this.guessLen13b(U.length,Z.length),$=this.makeRBT(I),K=this.stub(I),J=new Array(I),Y=new Array(I),X=new Array(I),O=new Array(I),v=new Array(I),T=new Array(I),B=Q.words;B.length=I,this.convert13b(U.words,U.length,J,I),this.convert13b(Z.words,Z.length,O,I),this.transform(J,K,Y,X,I,$),this.transform(O,K,v,T,I,$);for(var c=0;c<I;c++){var l=Y[c]*v[c]-X[c]*T[c];X[c]=Y[c]*T[c]+X[c]*v[c],Y[c]=l}return this.conjugate(Y,X,I),this.transform(Y,X,B,K,I,$),this.conjugate(B,K,I),this.normalize13b(B,I),Q.negative=U.negative^Z.negative,Q.length=U.length+Z.length,Q.strip()},V.prototype.mul=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),this.mulTo(U,Z)},V.prototype.mulf=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),g(this,U,Z)},V.prototype.imul=function F(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function F(U){H(typeof U==="number"),H(U<67108864);var Z=0;for(var Q=0;Q<this.length;Q++){var I=(this.words[Q]|0)*U,$=(I&67108863)+(Z&67108863);Z>>=26,Z+=I/67108864|0,Z+=$>>>26,this.words[Q]=$&67108863}if(Z!==0)this.words[Q]=Z,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function F(U){return this.clone().imuln(U)},V.prototype.sqr=function F(){return this.mul(this)},V.prototype.isqr=function F(){return this.imul(this.clone())},V.prototype.pow=function F(U){var Z=M(U);if(Z.length===0)return new V(1);var Q=this;for(var I=0;I<Z.length;I++,Q=Q.sqr())if(Z[I]!==0)break;if(++I<Z.length)for(var $=Q.sqr();I<Z.length;I++,$=$.sqr()){if(Z[I]===0)continue;Q=Q.mul($)}return Q},V.prototype.iushln=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=67108863>>>26-Z<<26-Z,$;if(Z!==0){var K=0;for($=0;$<this.length;$++){var J=this.words[$]&I,Y=(this.words[$]|0)-J<<Z;this.words[$]=Y|K,K=J>>>26-Z}if(K)this.words[$]=K,this.length++}if(Q!==0){for($=this.length-1;$>=0;$--)this.words[$+Q]=this.words[$];for($=0;$<Q;$++)this.words[$]=0;this.length+=Q}return this.strip()},V.prototype.ishln=function F(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function F(U,Z,Q){H(typeof U==="number"&&U>=0);var I;if(Z)I=(Z-Z%26)/26;else I=0;var $=U%26,K=Math.min((U-$)/26,this.length),J=67108863^67108863>>>$<<$,Y=Q;if(I-=K,I=Math.max(0,I),Y){for(var X=0;X<K;X++)Y.words[X]=this.words[X];Y.length=K}if(K===0);else if(this.length>K){this.length-=K;for(X=0;X<this.length;X++)this.words[X]=this.words[X+K]}else this.words[0]=0,this.length=1;var O=0;for(X=this.length-1;X>=0&&(O!==0||X>=I);X--){var v=this.words[X]|0;this.words[X]=O<<26-$|v>>>$,O=v&J}if(Y&&O!==0)Y.words[Y.length++]=O;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function F(U,Z,Q){return H(this.negative===0),this.iushrn(U,Z,Q)},V.prototype.shln=function F(U){return this.clone().ishln(U)},V.prototype.ushln=function F(U){return this.clone().iushln(U)},V.prototype.shrn=function F(U){return this.clone().ishrn(U)},V.prototype.ushrn=function F(U){return this.clone().iushrn(U)},V.prototype.testn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return!1;var $=this.words[Q];return!!($&I)},V.prototype.imaskn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=Q)return this;if(Z!==0)Q++;if(this.length=Math.min(Q,this.length),Z!==0){var I=67108863^67108863>>>Z<<Z;this.words[this.length-1]&=I}return this.strip()},V.prototype.maskn=function F(U){return this.clone().imaskn(U)},V.prototype.iaddn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.isubn(-U);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<U)return this.words[0]=U-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(U),this.negative=1,this}return this._iaddn(U)},V.prototype._iaddn=function F(U){this.words[0]+=U;for(var Z=0;Z<this.length&&this.words[Z]>=67108864;Z++)if(this.words[Z]-=67108864,Z===this.length-1)this.words[Z+1]=1;else this.words[Z+1]++;return this.length=Math.max(this.length,Z+1),this},V.prototype.isubn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.iaddn(-U);if(this.negative!==0)return this.negative=0,this.iaddn(U),this.negative=1,this;if(this.words[0]-=U,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Z=0;Z<this.length&&this.words[Z]<0;Z++)this.words[Z]+=67108864,this.words[Z+1]-=1;return this.strip()},V.prototype.addn=function F(U){return this.clone().iaddn(U)},V.prototype.subn=function F(U){return this.clone().isubn(U)},V.prototype.iabs=function F(){return this.negative=0,this},V.prototype.abs=function F(){return this.clone().iabs()},V.prototype._ishlnsubmul=function F(U,Z,Q){var I=U.length+Q,$;this._expand(I);var K,J=0;for($=0;$<U.length;$++){K=(this.words[$+Q]|0)+J;var Y=(U.words[$]|0)*Z;K-=Y&67108863,J=(K>>26)-(Y/67108864|0),this.words[$+Q]=K&67108863}for(;$<this.length-Q;$++)K=(this.words[$+Q]|0)+J,J=K>>26,this.words[$+Q]=K&67108863;if(J===0)return this.strip();H(J===-1),J=0;for($=0;$<this.length;$++)K=-(this.words[$]|0)+J,J=K>>26,this.words[$]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function F(U,Z){var Q=this.length-U.length,I=this.clone(),$=U,K=$.words[$.length-1]|0,J=this._countBits(K);if(Q=26-J,Q!==0)$=$.ushln(Q),I.iushln(Q),K=$.words[$.length-1]|0;var Y=I.length-$.length,X;if(Z!=="mod"){X=new V(null),X.length=Y+1,X.words=new Array(X.length);for(var O=0;O<X.length;O++)X.words[O]=0}var v=I.clone()._ishlnsubmul($,1,Y);if(v.negative===0){if(I=v,X)X.words[Y]=1}for(var T=Y-1;T>=0;T--){var B=(I.words[$.length+T]|0)*67108864+(I.words[$.length+T-1]|0);B=Math.min(B/K|0,67108863),I._ishlnsubmul($,B,T);while(I.negative!==0)if(B--,I.negative=0,I._ishlnsubmul($,1,T),!I.isZero())I.negative^=1;if(X)X.words[T]=B}if(X)X.strip();if(I.strip(),Z!=="div"&&Q!==0)I.iushrn(Q);return{div:X||null,mod:I}},V.prototype.divmod=function F(U,Z,Q){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var I,$,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Z),Z!=="mod")I=K.div.neg();if(Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.iadd(U)}return{div:I,mod:$}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Z),Z!=="mod")I=K.div.neg();return{div:I,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Z),Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.isub(U)}return{div:K.div,mod:$}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Z==="div")return{div:this.divn(U.words[0]),mod:null};if(Z==="mod")return{div:null,mod:new V(this.modn(U.words[0]))};return{div:this.divn(U.words[0]),mod:new V(this.modn(U.words[0]))}}return this._wordDiv(U,Z)},V.prototype.div=function F(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function F(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function F(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function F(U){var Z=this.divmod(U);if(Z.mod.isZero())return Z.div;var Q=Z.div.negative!==0?Z.mod.isub(U):Z.mod,I=U.ushrn(1),$=U.andln(1),K=Q.cmp(I);if(K<0||$===1&&K===0)return Z.div;return Z.div.negative!==0?Z.div.isubn(1):Z.div.iaddn(1)},V.prototype.modn=function F(U){H(U<=67108863);var Z=67108864%U,Q=0;for(var I=this.length-1;I>=0;I--)Q=(Z*Q+(this.words[I]|0))%U;return Q},V.prototype.idivn=function F(U){H(U<=67108863);var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=(this.words[Q]|0)+Z*67108864;this.words[Q]=I/U|0,Z=I%U}return this.strip()},V.prototype.divn=function F(U){return this.clone().idivn(U)},V.prototype.egcd=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=new V(0),J=new V(1),Y=0;while(Z.isEven()&&Q.isEven())Z.iushrn(1),Q.iushrn(1),++Y;var X=Q.clone(),O=Z.clone();while(!Z.isZero()){for(var v=0,T=1;(Z.words[0]&T)===0&&v<26;++v,T<<=1);if(v>0){Z.iushrn(v);while(v-- >0){if(I.isOdd()||$.isOdd())I.iadd(X),$.isub(O);I.iushrn(1),$.iushrn(1)}}for(var B=0,c=1;(Q.words[0]&c)===0&&B<26;++B,c<<=1);if(B>0){Q.iushrn(B);while(B-- >0){if(K.isOdd()||J.isOdd())K.iadd(X),J.isub(O);K.iushrn(1),J.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub(K),$.isub(J);else Q.isub(Z),K.isub(I),J.isub($)}return{a:K,b:J,gcd:Q.iushln(Y)}},V.prototype._invmp=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=Q.clone();while(Z.cmpn(1)>0&&Q.cmpn(1)>0){for(var J=0,Y=1;(Z.words[0]&Y)===0&&J<26;++J,Y<<=1);if(J>0){Z.iushrn(J);while(J-- >0){if(I.isOdd())I.iadd(K);I.iushrn(1)}}for(var X=0,O=1;(Q.words[0]&O)===0&&X<26;++X,O<<=1);if(X>0){Q.iushrn(X);while(X-- >0){if($.isOdd())$.iadd(K);$.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub($);else Q.isub(Z),$.isub(I)}var v;if(Z.cmpn(1)===0)v=I;else v=$;if(v.cmpn(0)<0)v.iadd(U);return v},V.prototype.gcd=function F(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Z=this.clone(),Q=U.clone();Z.negative=0,Q.negative=0;for(var I=0;Z.isEven()&&Q.isEven();I++)Z.iushrn(1),Q.iushrn(1);do{while(Z.isEven())Z.iushrn(1);while(Q.isEven())Q.iushrn(1);var $=Z.cmp(Q);if($<0){var K=Z;Z=Q,Q=K}else if($===0||Q.cmpn(1)===0)break;Z.isub(Q)}while(!0);return Q.iushln(I)},V.prototype.invm=function F(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function F(){return(this.words[0]&1)===0},V.prototype.isOdd=function F(){return(this.words[0]&1)===1},V.prototype.andln=function F(U){return this.words[0]&U},V.prototype.bincn=function F(U){H(typeof U==="number");var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return this._expand(Q+1),this.words[Q]|=I,this;var $=I;for(var K=Q;$!==0&&K<this.length;K++){var J=this.words[K]|0;J+=$,$=J>>>26,J&=67108863,this.words[K]=J}if($!==0)this.words[K]=$,this.length++;return this},V.prototype.isZero=function F(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function F(U){var Z=U<0;if(this.negative!==0&&!Z)return-1;if(this.negative===0&&Z)return 1;this.strip();var Q;if(this.length>1)Q=1;else{if(Z)U=-U;H(U<=67108863,"Number is too big");var I=this.words[0]|0;Q=I===U?0:I<U?-1:1}if(this.negative!==0)return-Q|0;return Q},V.prototype.cmp=function F(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Z=this.ucmp(U);if(this.negative!==0)return-Z|0;return Z},V.prototype.ucmp=function F(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=this.words[Q]|0,$=U.words[Q]|0;if(I===$)continue;if(I<$)Z=-1;else if(I>$)Z=1;break}return Z},V.prototype.gtn=function F(U){return this.cmpn(U)===1},V.prototype.gt=function F(U){return this.cmp(U)===1},V.prototype.gten=function F(U){return this.cmpn(U)>=0},V.prototype.gte=function F(U){return this.cmp(U)>=0},V.prototype.ltn=function F(U){return this.cmpn(U)===-1},V.prototype.lt=function F(U){return this.cmp(U)===-1},V.prototype.lten=function F(U){return this.cmpn(U)<=0},V.prototype.lte=function F(U){return this.cmp(U)<=0},V.prototype.eqn=function F(U){return this.cmpn(U)===0},V.prototype.eq=function F(U){return this.cmp(U)===0},V.red=function F(U){return new u(U)},V.prototype.toRed=function F(U){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),U.convertTo(this)._forceRed(U)},V.prototype.fromRed=function F(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function F(U){return this.red=U,this},V.prototype.forceRed=function F(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function F(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function F(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function F(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function F(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function F(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.mul(this,U)},V.prototype.redIMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.imul(this,U)},V.prototype.redSqr=function F(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function F(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function F(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function F(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function F(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function F(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var y={k256:null,p224:null,p192:null,p25519:null};function f(F,U){this.name=F,this.p=new V(U,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}f.prototype._tmp=function F(){var U=new V(null);return U.words=new Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function F(U){var Z=U,Q;do this.split(Z,this.tmp),Z=this.imulK(Z),Z=Z.iadd(this.tmp),Q=Z.bitLength();while(Q>this.n);var I=Q<this.n?-1:Z.ucmp(this.p);if(I===0)Z.words[0]=0,Z.length=1;else if(I>0)Z.isub(this.p);else if(Z.strip!==void 0)Z.strip();else Z._strip();return Z},f.prototype.split=function F(U,Z){U.iushrn(this.n,0,Z)},f.prototype.imulK=function F(U){return U.imul(this.k)};function o(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}z(o,f),o.prototype.split=function F(U,Z){var Q=4194303,I=Math.min(U.length,9);for(var $=0;$<I;$++)Z.words[$]=U.words[$];if(Z.length=I,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Z.words[Z.length++]=K&Q;for($=10;$<U.length;$++){var J=U.words[$]|0;U.words[$-10]=(J&Q)<<4|K>>>22,K=J}if(K>>>=22,U.words[$-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},o.prototype.imulK=function F(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Z=0;for(var Q=0;Q<U.length;Q++){var I=U.words[Q]|0;Z+=I*977,U.words[Q]=Z&67108863,Z=I*64+(Z/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function r(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}z(r,f);function V0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}z(V0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}z(Y0,f),Y0.prototype.imulK=function F(U){var Z=0;for(var Q=0;Q<U.length;Q++){var I=(U.words[Q]|0)*19+Z,$=I&67108863;I>>>=26,U.words[Q]=$,Z=I}if(Z!==0)U.words[U.length++]=Z;return U},V._prime=function F(U){if(y[U])return y[U];var Z;if(U==="k256")Z=new o;else if(U==="p224")Z=new r;else if(U==="p192")Z=new V0;else if(U==="p25519")Z=new Y0;else throw new Error("Unknown prime "+U);return y[U]=Z,Z};function u(F){if(typeof F==="string"){var U=V._prime(F);this.m=U.p,this.prime=U}else H(F.gtn(1),"modulus must be greater than 1"),this.m=F,this.prime=null}u.prototype._verify1=function F(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function F(U,Z){H((U.negative|Z.negative)===0,"red works only with positives"),H(U.red&&U.red===Z.red,"red works only with red numbers")},u.prototype.imod=function F(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function F(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function F(U,Z){this._verify2(U,Z);var Q=U.add(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q._forceRed(this)},u.prototype.iadd=function F(U,Z){this._verify2(U,Z);var Q=U.iadd(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q},u.prototype.sub=function F(U,Z){this._verify2(U,Z);var Q=U.sub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q._forceRed(this)},u.prototype.isub=function F(U,Z){this._verify2(U,Z);var Q=U.isub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q},u.prototype.shl=function F(U,Z){return this._verify1(U),this.imod(U.ushln(Z))},u.prototype.imul=function F(U,Z){return this._verify2(U,Z),this.imod(U.imul(Z))},u.prototype.mul=function F(U,Z){return this._verify2(U,Z),this.imod(U.mul(Z))},u.prototype.isqr=function F(U){return this.imul(U,U.clone())},u.prototype.sqr=function F(U){return this.mul(U,U)},u.prototype.sqrt=function F(U){if(U.isZero())return U.clone();var Z=this.m.andln(3);if(H(Z%2===1),Z===3){var Q=this.m.add(new V(1)).iushrn(2);return this.pow(U,Q)}var I=this.m.subn(1),$=0;while(!I.isZero()&&I.andln(1)===0)$++,I.iushrn(1);H(!I.isZero());var K=new V(1).toRed(this),J=K.redNeg(),Y=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,Y).cmp(J)!==0)X.redIAdd(J);var O=this.pow(X,I),v=this.pow(U,I.addn(1).iushrn(1)),T=this.pow(U,I),B=$;while(T.cmp(K)!==0){var c=T;for(var l=0;c.cmp(K)!==0;l++)c=c.redSqr();H(l<B);var s=this.pow(O,new V(1).iushln(B-l-1));v=v.redMul(s),O=s.redSqr(),T=T.redMul(O),B=l}return v},u.prototype.invm=function F(U){var Z=U._invmp(this.m);if(Z.negative!==0)return Z.negative=0,this.imod(Z).redNeg();else return this.imod(Z)},u.prototype.pow=function F(U,Z){if(Z.isZero())return new V(1).toRed(this);if(Z.cmpn(1)===0)return U.clone();var Q=4,I=new Array(1<<Q);I[0]=new V(1).toRed(this),I[1]=U;for(var $=2;$<I.length;$++)I[$]=this.mul(I[$-1],U);var K=I[0],J=0,Y=0,X=Z.bitLength()%26;if(X===0)X=26;for($=Z.length-1;$>=0;$--){var O=Z.words[$];for(var v=X-1;v>=0;v--){var T=O>>v&1;if(K!==I[0])K=this.sqr(K);if(T===0&&J===0){Y=0;continue}if(J<<=1,J|=T,Y++,Y!==Q&&($!==0||v!==0))continue;K=this.mul(K,I[J]),Y=0,J=0}X=26}return K},u.prototype.convertTo=function F(U){var Z=U.umod(this.m);return Z===U?Z.clone():Z},u.prototype.convertFrom=function F(U){var Z=U.clone();return Z.red=null,Z},V.mont=function F(U){return new a(U)};function a(F){if(u.call(this,F),this.shift=this.m.bitLength(),this.shift%26!==0)this.shift+=26-this.shift%26;this.r=new V(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}z(a,u),a.prototype.convertTo=function F(U){return this.imod(U.ushln(this.shift))},a.prototype.convertFrom=function F(U){var Z=this.imod(U.mul(this.rinv));return Z.red=null,Z},a.prototype.imul=function F(U,Z){if(U.isZero()||Z.isZero())return U.words[0]=0,U.length=1,U;var Q=U.imul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.mul=function F(U,Z){if(U.isZero()||Z.isZero())return new V(0)._forceRed(this);var Q=U.mul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.invm=function F(U){var Z=this.imod(U._invmp(this.m).mul(this.r2));return Z._forceRed(this)}})(typeof G==="undefined"||G,E)}),hY=w0((E,G)=>{var W=cY(),C=pY();G.exports=function P(k){return new z(k)};var H={secp256k1:{name:"secp256k1",byteLength:32},secp224r1:{name:"p224",byteLength:28},prime256v1:{name:"p256",byteLength:32},prime192v1:{name:"p192",byteLength:24},ed25519:{name:"ed25519",byteLength:32},secp384r1:{name:"p384",byteLength:48},secp521r1:{name:"p521",byteLength:66}};H.p224=H.secp224r1,H.p256=H.secp256r1=H.prime256v1,H.p192=H.secp192r1=H.prime192v1,H.p384=H.secp384r1,H.p521=H.secp521r1;function z(P){if(this.curveType=H[P],!this.curveType)this.curveType={name:P};this.curve=new W.ec(this.curveType.name),this.keys=void 0}z.prototype.generateKeys=function(P,k){return this.keys=this.curve.genKeyPair(),this.getPublicKey(P,k)},z.prototype.computeSecret=function(P,k,R){if(k=k||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,k);var S=this.curve.keyFromPublic(P).getPublic(),D=S.mul(this.keys.getPrivate()).getX();return V(D,R,this.curveType.byteLength)},z.prototype.getPublicKey=function(P,k){var R=this.keys.getPublic(k==="compressed",!0);if(k==="hybrid")if(R[R.length-1]%2)R[0]=7;else R[0]=6;return V(R,P)},z.prototype.getPrivateKey=function(P){return V(this.keys.getPrivate(),P)},z.prototype.setPublicKey=function(P,k){if(k=k||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,k);return this.keys._importPublic(P),this},z.prototype.setPrivateKey=function(P,k){if(k=k||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,k);var R=new C(P);return R=R.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(R),this};function V(P,k,R){if(!Array.isArray(P))P=P.toArray();var S=new Buffer(P);if(R&&S.length<R){var D=new Buffer(R-S.length);D.fill(0),S=Buffer.concat([D,S])}if(!k)return S;else return S.toString(k)}}),uY=w0((E,G)=>{var W=(vU(),y0(qU)).createECDH;G.exports=W||hY()}),lY=w0((E,G)=>{(function(W,C){function H(F,U){if(!F)throw new Error(U||"Assertion failed")}function z(F,U){F.super_=U;var Z=function(){};Z.prototype=U.prototype,F.prototype=new Z,F.prototype.constructor=F}function V(F,U,Z){if(V.isBN(F))return F;if(this.negative=0,this.words=null,this.length=0,this.red=null,F!==null){if(U==="le"||U==="be")Z=U,U=10;this._init(F||0,U||10,Z||"be")}}if(typeof W==="object")W.exports=V;else C.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window!=="undefined"&&typeof window.Buffer!=="undefined")P=window.Buffer;else P=(HU(),y0(FU)).Buffer}catch(F){}V.isBN=function F(U){if(U instanceof V)return!0;return U!==null&&typeof U==="object"&&U.constructor.wordSize===V.wordSize&&Array.isArray(U.words)},V.max=function F(U,Z){if(U.cmp(Z)>0)return U;return Z},V.min=function F(U,Z){if(U.cmp(Z)<0)return U;return Z},V.prototype._init=function F(U,Z,Q){if(typeof U==="number")return this._initNumber(U,Z,Q);if(typeof U==="object")return this._initArray(U,Z,Q);if(Z==="hex")Z=16;H(Z===(Z|0)&&Z>=2&&Z<=36),U=U.toString().replace(/\s+/g,"");var I=0;if(U[0]==="-")I++,this.negative=1;if(I<U.length){if(Z===16)this._parseHex(U,I,Q);else if(this._parseBase(U,Z,I),Q==="le")this._initArray(this.toArray(),Z,Q)}},V.prototype._initNumber=function F(U,Z,Q){if(U<0)this.negative=1,U=-U;if(U<67108864)this.words=[U&67108863],this.length=1;else if(U<4503599627370496)this.words=[U&67108863,U/67108864&67108863],this.length=2;else H(U<9007199254740992),this.words=[U&67108863,U/67108864&67108863,1],this.length=3;if(Q!=="le")return;this._initArray(this.toArray(),Z,Q)},V.prototype._initArray=function F(U,Z,Q){if(H(typeof U.length==="number"),U.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(U.length/3),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $,K,J=0;if(Q==="be"){for(I=U.length-1,$=0;I>=0;I-=3)if(K=U[I]|U[I-1]<<8|U[I-2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}else if(Q==="le"){for(I=0,$=0;I<U.length;I+=3)if(K=U[I]|U[I+1]<<8|U[I+2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}return this.strip()};function k(F,U){var Z=F.charCodeAt(U);if(Z>=65&&Z<=70)return Z-55;else if(Z>=97&&Z<=102)return Z-87;else return Z-48&15}function R(F,U,Z){var Q=k(F,Z);if(Z-1>=U)Q|=k(F,Z-1)<<4;return Q}V.prototype._parseHex=function F(U,Z,Q){this.length=Math.ceil((U.length-Z)/6),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $=0,K=0,J;if(Q==="be")for(I=U.length-1;I>=Z;I-=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8;else{var Y=U.length-Z;for(I=Y%2===0?Z+1:Z;I<U.length;I+=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8}this.strip()};function S(F,U,Z,Q){var I=0,$=Math.min(F.length,Z);for(var K=U;K<$;K++){var J=F.charCodeAt(K)-48;if(I*=Q,J>=49)I+=J-49+10;else if(J>=17)I+=J-17+10;else I+=J}return I}V.prototype._parseBase=function F(U,Z,Q){this.words=[0],this.length=1;for(var I=0,$=1;$<=67108863;$*=Z)I++;I--,$=$/Z|0;var K=U.length-Q,J=K%I,Y=Math.min(K,K-J)+Q,X=0;for(var O=Q;O<Y;O+=I)if(X=S(U,O,O+I,Z),this.imuln($),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(J!==0){var v=1;X=S(U,O,U.length,Z);for(O=0;O<J;O++)v*=Z;if(this.imuln(v),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function F(U){U.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)U.words[Z]=this.words[Z];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function F(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function F(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function F(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function F(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function F(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],L=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];if(V.prototype.toString=function F(U,Z){U=U||10,Z=Z|0||1;var Q;if(U===16||U==="hex"){Q="";var I=0,$=0;for(var K=0;K<this.length;K++){var J=this.words[K],Y=((J<<I|$)&16777215).toString(16);if($=J>>>24-I&16777215,I+=2,I>=26)I-=26,K--;if($!==0||K!==this.length-1)Q=D[6-Y.length]+Y+Q;else Q=Y+Q}if($!==0)Q=$.toString(16)+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}if(U===(U|0)&&U>=2&&U<=36){var X=A[U],O=L[U];Q="";var v=this.clone();v.negative=0;while(!v.isZero()){var T=v.modn(O).toString(U);if(v=v.idivn(O),!v.isZero())Q=D[X-T.length]+T+Q;else Q=T+Q}if(this.isZero())Q="0"+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function F(){var U=this.words[0];if(this.length===2)U+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)U+=4503599627370496+this.words[1]*67108864;else if(this.length>2)H(!1,"Number can only safely store up to 53 bits");return this.negative!==0?-U:U},V.prototype.toJSON=function F(){return this.toString(16)},V.prototype.toBuffer=function F(U,Z){return H(typeof P!=="undefined"),this.toArrayLike(P,U,Z)},V.prototype.toArray=function F(U,Z){return this.toArrayLike(Array,U,Z)},V.prototype.toArrayLike=function F(U,Z,Q){var I=this.byteLength(),$=Q||Math.max(1,I);H(I<=$,"byte array longer than desired length"),H($>0,"Requested array length <= 0"),this.strip();var K=Z==="le",J=new U($),Y,X,O=this.clone();if(!K){for(X=0;X<$-I;X++)J[X]=0;for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[$-X-1]=Y}else{for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[X]=Y;for(;X<$;X++)J[X]=0}return J},Math.clz32)V.prototype._countBits=function F(U){return 32-Math.clz32(U)};else V.prototype._countBits=function F(U){var Z=U,Q=0;if(Z>=4096)Q+=13,Z>>>=13;if(Z>=64)Q+=7,Z>>>=7;if(Z>=8)Q+=4,Z>>>=4;if(Z>=2)Q+=2,Z>>>=2;return Q+Z};V.prototype._zeroBits=function F(U){if(U===0)return 26;var Z=U,Q=0;if((Z&8191)===0)Q+=13,Z>>>=13;if((Z&127)===0)Q+=7,Z>>>=7;if((Z&15)===0)Q+=4,Z>>>=4;if((Z&3)===0)Q+=2,Z>>>=2;if((Z&1)===0)Q++;return Q},V.prototype.bitLength=function F(){var U=this.words[this.length-1],Z=this._countBits(U);return(this.length-1)*26+Z};function M(F){var U=new Array(F.bitLength());for(var Z=0;Z<U.length;Z++){var Q=Z/26|0,I=Z%26;U[Z]=(F.words[Q]&1<<I)>>>I}return U}V.prototype.zeroBits=function F(){if(this.isZero())return 0;var U=0;for(var Z=0;Z<this.length;Z++){var Q=this._zeroBits(this.words[Z]);if(U+=Q,Q!==26)break}return U},V.prototype.byteLength=function F(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function F(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function F(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function F(){return this.negative!==0},V.prototype.neg=function F(){return this.clone().ineg()},V.prototype.ineg=function F(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function F(U){while(this.length<U.length)this.words[this.length++]=0;for(var Z=0;Z<U.length;Z++)this.words[Z]=this.words[Z]|U.words[Z];return this.strip()},V.prototype.ior=function F(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function F(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function F(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function F(U){var Z;if(this.length>U.length)Z=U;else Z=this;for(var Q=0;Q<Z.length;Q++)this.words[Q]=this.words[Q]&U.words[Q];return this.length=Z.length,this.strip()},V.prototype.iand=function F(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function F(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function F(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function F(U){var Z,Q;if(this.length>U.length)Z=this,Q=U;else Z=U,Q=this;for(var I=0;I<Q.length;I++)this.words[I]=Z.words[I]^Q.words[I];if(this!==Z)for(;I<Z.length;I++)this.words[I]=Z.words[I];return this.length=Z.length,this.strip()},V.prototype.ixor=function F(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function F(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function F(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function F(U){H(typeof U==="number"&&U>=0);var Z=Math.ceil(U/26)|0,Q=U%26;if(this._expand(Z),Q>0)Z--;for(var I=0;I<Z;I++)this.words[I]=~this.words[I]&67108863;if(Q>0)this.words[I]=~this.words[I]&67108863>>26-Q;return this.strip()},V.prototype.notn=function F(U){return this.clone().inotn(U)},V.prototype.setn=function F(U,Z){H(typeof U==="number"&&U>=0);var Q=U/26|0,I=U%26;if(this._expand(Q+1),Z)this.words[Q]=this.words[Q]|1<<I;else this.words[Q]=this.words[Q]&~(1<<I);return this.strip()},V.prototype.iadd=function F(U){var Z;if(this.negative!==0&&U.negative===0)return this.negative=0,Z=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Z=this.isub(U),U.negative=1,Z._normSign();var Q,I;if(this.length>U.length)Q=this,I=U;else Q=U,I=this;var $=0;for(var K=0;K<I.length;K++)Z=(Q.words[K]|0)+(I.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;for(;$!==0&&K<Q.length;K++)Z=(Q.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;if(this.length=Q.length,$!==0)this.words[this.length]=$,this.length++;else if(Q!==this)for(;K<Q.length;K++)this.words[K]=Q.words[K];return this},V.prototype.add=function F(U){var Z;if(U.negative!==0&&this.negative===0)return U.negative=0,Z=this.sub(U),U.negative^=1,Z;else if(U.negative===0&&this.negative!==0)return this.negative=0,Z=U.sub(this),this.negative=1,Z;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function F(U){if(U.negative!==0){U.negative=0;var Z=this.iadd(U);return U.negative=1,Z._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var Q=this.cmp(U);if(Q===0)return this.negative=0,this.length=1,this.words[0]=0,this;var I,$;if(Q>0)I=this,$=U;else I=U,$=this;var K=0;for(var J=0;J<$.length;J++)Z=(I.words[J]|0)-($.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;for(;K!==0&&J<I.length;J++)Z=(I.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;if(K===0&&J<I.length&&I!==this)for(;J<I.length;J++)this.words[J]=I.words[J];if(this.length=Math.max(this.length,J),I!==this)this.negative=1;return this.strip()},V.prototype.sub=function F(U){return this.clone().isub(U)};function q(F,U,Z){Z.negative=U.negative^F.negative;var Q=F.length+U.length|0;Z.length=Q,Q=Q-1|0;var I=F.words[0]|0,$=U.words[0]|0,K=I*$,J=K&67108863,Y=K/67108864|0;Z.words[0]=J;for(var X=1;X<Q;X++){var O=Y>>>26,v=Y&67108863,T=Math.min(X,U.length-1);for(var B=Math.max(0,X-F.length+1);B<=T;B++){var c=X-B|0;I=F.words[c]|0,$=U.words[B]|0,K=I*$+v,O+=K/67108864|0,v=K&67108863}Z.words[X]=v|0,Y=O|0}if(Y!==0)Z.words[X]=Y|0;else Z.length--;return Z.strip()}var j=function F(U,Z,Q){var I=U.words,$=Z.words,K=Q.words,J=0,Y,X,O,v=I[0]|0,T=v&8191,B=v>>>13,c=I[1]|0,l=c&8191,s=c>>>13,O0=I[2]|0,h=O0&8191,d=O0>>>13,g0=I[3]|0,Q0=g0&8191,$0=g0>>>13,m=I[4]|0,p=m&8191,b=m>>>13,N0=I[5]|0,i=N0&8191,e=N0>>>13,t=I[6]|0,n=t&8191,X0=t>>>13,H0=I[7]|0,Z0=H0&8191,W0=H0>>>13,c0=I[8]|0,G0=c0&8191,A0=c0>>>13,u0=I[9]|0,J0=u0&8191,T0=u0>>>13,r0=$[0]|0,E0=r0&8191,v0=r0>>>13,AU=$[1]|0,k0=AU&8191,j0=AU>>>13,DU=$[2]|0,R0=DU&8191,S0=DU>>>13,LU=$[3]|0,P0=LU&8191,D0=LU>>>13,zU=$[4]|0,B0=zU&8191,L0=zU>>>13,EU=$[5]|0,_=EU&8191,w=EU>>>13,_0=$[6]|0,U0=_0&8191,I0=_0>>>13,l0=$[7]|0,F0=l0&8191,C0=l0>>>13,CU=$[8]|0,x0=CU&8191,q0=CU>>>13,TU=$[9]|0,z0=TU&8191,M0=TU>>>13;Q.negative=U.negative^Z.negative,Q.length=19,Y=Math.imul(T,E0),X=Math.imul(T,v0),X=X+Math.imul(B,E0)|0,O=Math.imul(B,v0);var t0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(t0>>>26)|0,t0&=67108863,Y=Math.imul(l,E0),X=Math.imul(l,v0),X=X+Math.imul(s,E0)|0,O=Math.imul(s,v0),Y=Y+Math.imul(T,k0)|0,X=X+Math.imul(T,j0)|0,X=X+Math.imul(B,k0)|0,O=O+Math.imul(B,j0)|0;var p0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(p0>>>26)|0,p0&=67108863,Y=Math.imul(h,E0),X=Math.imul(h,v0),X=X+Math.imul(d,E0)|0,O=Math.imul(d,v0),Y=Y+Math.imul(l,k0)|0,X=X+Math.imul(l,j0)|0,X=X+Math.imul(s,k0)|0,O=O+Math.imul(s,j0)|0,Y=Y+Math.imul(T,R0)|0,X=X+Math.imul(T,S0)|0,X=X+Math.imul(B,R0)|0,O=O+Math.imul(B,S0)|0;var f0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(f0>>>26)|0,f0&=67108863,Y=Math.imul(Q0,E0),X=Math.imul(Q0,v0),X=X+Math.imul($0,E0)|0,O=Math.imul($0,v0),Y=Y+Math.imul(h,k0)|0,X=X+Math.imul(h,j0)|0,X=X+Math.imul(d,k0)|0,O=O+Math.imul(d,j0)|0,Y=Y+Math.imul(l,R0)|0,X=X+Math.imul(l,S0)|0,X=X+Math.imul(s,R0)|0,O=O+Math.imul(s,S0)|0,Y=Y+Math.imul(T,P0)|0,X=X+Math.imul(T,D0)|0,X=X+Math.imul(B,P0)|0,O=O+Math.imul(B,D0)|0;var b0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,Y=Math.imul(p,E0),X=Math.imul(p,v0),X=X+Math.imul(b,E0)|0,O=Math.imul(b,v0),Y=Y+Math.imul(Q0,k0)|0,X=X+Math.imul(Q0,j0)|0,X=X+Math.imul($0,k0)|0,O=O+Math.imul($0,j0)|0,Y=Y+Math.imul(h,R0)|0,X=X+Math.imul(h,S0)|0,X=X+Math.imul(d,R0)|0,O=O+Math.imul(d,S0)|0,Y=Y+Math.imul(l,P0)|0,X=X+Math.imul(l,D0)|0,X=X+Math.imul(s,P0)|0,O=O+Math.imul(s,D0)|0,Y=Y+Math.imul(T,B0)|0,X=X+Math.imul(T,L0)|0,X=X+Math.imul(B,B0)|0,O=O+Math.imul(B,L0)|0;var a0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,Y=Math.imul(i,E0),X=Math.imul(i,v0),X=X+Math.imul(e,E0)|0,O=Math.imul(e,v0),Y=Y+Math.imul(p,k0)|0,X=X+Math.imul(p,j0)|0,X=X+Math.imul(b,k0)|0,O=O+Math.imul(b,j0)|0,Y=Y+Math.imul(Q0,R0)|0,X=X+Math.imul(Q0,S0)|0,X=X+Math.imul($0,R0)|0,O=O+Math.imul($0,S0)|0,Y=Y+Math.imul(h,P0)|0,X=X+Math.imul(h,D0)|0,X=X+Math.imul(d,P0)|0,O=O+Math.imul(d,D0)|0,Y=Y+Math.imul(l,B0)|0,X=X+Math.imul(l,L0)|0,X=X+Math.imul(s,B0)|0,O=O+Math.imul(s,L0)|0,Y=Y+Math.imul(T,_)|0,X=X+Math.imul(T,w)|0,X=X+Math.imul(B,_)|0,O=O+Math.imul(B,w)|0;var e0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,Y=Math.imul(n,E0),X=Math.imul(n,v0),X=X+Math.imul(X0,E0)|0,O=Math.imul(X0,v0),Y=Y+Math.imul(i,k0)|0,X=X+Math.imul(i,j0)|0,X=X+Math.imul(e,k0)|0,O=O+Math.imul(e,j0)|0,Y=Y+Math.imul(p,R0)|0,X=X+Math.imul(p,S0)|0,X=X+Math.imul(b,R0)|0,O=O+Math.imul(b,S0)|0,Y=Y+Math.imul(Q0,P0)|0,X=X+Math.imul(Q0,D0)|0,X=X+Math.imul($0,P0)|0,O=O+Math.imul($0,D0)|0,Y=Y+Math.imul(h,B0)|0,X=X+Math.imul(h,L0)|0,X=X+Math.imul(d,B0)|0,O=O+Math.imul(d,L0)|0,Y=Y+Math.imul(l,_)|0,X=X+Math.imul(l,w)|0,X=X+Math.imul(s,_)|0,O=O+Math.imul(s,w)|0,Y=Y+Math.imul(T,U0)|0,X=X+Math.imul(T,I0)|0,X=X+Math.imul(B,U0)|0,O=O+Math.imul(B,I0)|0;var i0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,Y=Math.imul(Z0,E0),X=Math.imul(Z0,v0),X=X+Math.imul(W0,E0)|0,O=Math.imul(W0,v0),Y=Y+Math.imul(n,k0)|0,X=X+Math.imul(n,j0)|0,X=X+Math.imul(X0,k0)|0,O=O+Math.imul(X0,j0)|0,Y=Y+Math.imul(i,R0)|0,X=X+Math.imul(i,S0)|0,X=X+Math.imul(e,R0)|0,O=O+Math.imul(e,S0)|0,Y=Y+Math.imul(p,P0)|0,X=X+Math.imul(p,D0)|0,X=X+Math.imul(b,P0)|0,O=O+Math.imul(b,D0)|0,Y=Y+Math.imul(Q0,B0)|0,X=X+Math.imul(Q0,L0)|0,X=X+Math.imul($0,B0)|0,O=O+Math.imul($0,L0)|0,Y=Y+Math.imul(h,_)|0,X=X+Math.imul(h,w)|0,X=X+Math.imul(d,_)|0,O=O+Math.imul(d,w)|0,Y=Y+Math.imul(l,U0)|0,X=X+Math.imul(l,I0)|0,X=X+Math.imul(s,U0)|0,O=O+Math.imul(s,I0)|0,Y=Y+Math.imul(T,F0)|0,X=X+Math.imul(T,C0)|0,X=X+Math.imul(B,F0)|0,O=O+Math.imul(B,C0)|0;var UU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,Y=Math.imul(G0,E0),X=Math.imul(G0,v0),X=X+Math.imul(A0,E0)|0,O=Math.imul(A0,v0),Y=Y+Math.imul(Z0,k0)|0,X=X+Math.imul(Z0,j0)|0,X=X+Math.imul(W0,k0)|0,O=O+Math.imul(W0,j0)|0,Y=Y+Math.imul(n,R0)|0,X=X+Math.imul(n,S0)|0,X=X+Math.imul(X0,R0)|0,O=O+Math.imul(X0,S0)|0,Y=Y+Math.imul(i,P0)|0,X=X+Math.imul(i,D0)|0,X=X+Math.imul(e,P0)|0,O=O+Math.imul(e,D0)|0,Y=Y+Math.imul(p,B0)|0,X=X+Math.imul(p,L0)|0,X=X+Math.imul(b,B0)|0,O=O+Math.imul(b,L0)|0,Y=Y+Math.imul(Q0,_)|0,X=X+Math.imul(Q0,w)|0,X=X+Math.imul($0,_)|0,O=O+Math.imul($0,w)|0,Y=Y+Math.imul(h,U0)|0,X=X+Math.imul(h,I0)|0,X=X+Math.imul(d,U0)|0,O=O+Math.imul(d,I0)|0,Y=Y+Math.imul(l,F0)|0,X=X+Math.imul(l,C0)|0,X=X+Math.imul(s,F0)|0,O=O+Math.imul(s,C0)|0,Y=Y+Math.imul(T,x0)|0,X=X+Math.imul(T,q0)|0,X=X+Math.imul(B,x0)|0,O=O+Math.imul(B,q0)|0;var XU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,Y=Math.imul(J0,E0),X=Math.imul(J0,v0),X=X+Math.imul(T0,E0)|0,O=Math.imul(T0,v0),Y=Y+Math.imul(G0,k0)|0,X=X+Math.imul(G0,j0)|0,X=X+Math.imul(A0,k0)|0,O=O+Math.imul(A0,j0)|0,Y=Y+Math.imul(Z0,R0)|0,X=X+Math.imul(Z0,S0)|0,X=X+Math.imul(W0,R0)|0,O=O+Math.imul(W0,S0)|0,Y=Y+Math.imul(n,P0)|0,X=X+Math.imul(n,D0)|0,X=X+Math.imul(X0,P0)|0,O=O+Math.imul(X0,D0)|0,Y=Y+Math.imul(i,B0)|0,X=X+Math.imul(i,L0)|0,X=X+Math.imul(e,B0)|0,O=O+Math.imul(e,L0)|0,Y=Y+Math.imul(p,_)|0,X=X+Math.imul(p,w)|0,X=X+Math.imul(b,_)|0,O=O+Math.imul(b,w)|0,Y=Y+Math.imul(Q0,U0)|0,X=X+Math.imul(Q0,I0)|0,X=X+Math.imul($0,U0)|0,O=O+Math.imul($0,I0)|0,Y=Y+Math.imul(h,F0)|0,X=X+Math.imul(h,C0)|0,X=X+Math.imul(d,F0)|0,O=O+Math.imul(d,C0)|0,Y=Y+Math.imul(l,x0)|0,X=X+Math.imul(l,q0)|0,X=X+Math.imul(s,x0)|0,O=O+Math.imul(s,q0)|0,Y=Y+Math.imul(T,z0)|0,X=X+Math.imul(T,M0)|0,X=X+Math.imul(B,z0)|0,O=O+Math.imul(B,M0)|0;var IU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,Y=Math.imul(J0,k0),X=Math.imul(J0,j0),X=X+Math.imul(T0,k0)|0,O=Math.imul(T0,j0),Y=Y+Math.imul(G0,R0)|0,X=X+Math.imul(G0,S0)|0,X=X+Math.imul(A0,R0)|0,O=O+Math.imul(A0,S0)|0,Y=Y+Math.imul(Z0,P0)|0,X=X+Math.imul(Z0,D0)|0,X=X+Math.imul(W0,P0)|0,O=O+Math.imul(W0,D0)|0,Y=Y+Math.imul(n,B0)|0,X=X+Math.imul(n,L0)|0,X=X+Math.imul(X0,B0)|0,O=O+Math.imul(X0,L0)|0,Y=Y+Math.imul(i,_)|0,X=X+Math.imul(i,w)|0,X=X+Math.imul(e,_)|0,O=O+Math.imul(e,w)|0,Y=Y+Math.imul(p,U0)|0,X=X+Math.imul(p,I0)|0,X=X+Math.imul(b,U0)|0,O=O+Math.imul(b,I0)|0,Y=Y+Math.imul(Q0,F0)|0,X=X+Math.imul(Q0,C0)|0,X=X+Math.imul($0,F0)|0,O=O+Math.imul($0,C0)|0,Y=Y+Math.imul(h,x0)|0,X=X+Math.imul(h,q0)|0,X=X+Math.imul(d,x0)|0,O=O+Math.imul(d,q0)|0,Y=Y+Math.imul(l,z0)|0,X=X+Math.imul(l,M0)|0,X=X+Math.imul(s,z0)|0,O=O+Math.imul(s,M0)|0;var ZU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,Y=Math.imul(J0,R0),X=Math.imul(J0,S0),X=X+Math.imul(T0,R0)|0,O=Math.imul(T0,S0),Y=Y+Math.imul(G0,P0)|0,X=X+Math.imul(G0,D0)|0,X=X+Math.imul(A0,P0)|0,O=O+Math.imul(A0,D0)|0,Y=Y+Math.imul(Z0,B0)|0,X=X+Math.imul(Z0,L0)|0,X=X+Math.imul(W0,B0)|0,O=O+Math.imul(W0,L0)|0,Y=Y+Math.imul(n,_)|0,X=X+Math.imul(n,w)|0,X=X+Math.imul(X0,_)|0,O=O+Math.imul(X0,w)|0,Y=Y+Math.imul(i,U0)|0,X=X+Math.imul(i,I0)|0,X=X+Math.imul(e,U0)|0,O=O+Math.imul(e,I0)|0,Y=Y+Math.imul(p,F0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(b,F0)|0,O=O+Math.imul(b,C0)|0,Y=Y+Math.imul(Q0,x0)|0,X=X+Math.imul(Q0,q0)|0,X=X+Math.imul($0,x0)|0,O=O+Math.imul($0,q0)|0,Y=Y+Math.imul(h,z0)|0,X=X+Math.imul(h,M0)|0,X=X+Math.imul(d,z0)|0,O=O+Math.imul(d,M0)|0;var QU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,Y=Math.imul(J0,P0),X=Math.imul(J0,D0),X=X+Math.imul(T0,P0)|0,O=Math.imul(T0,D0),Y=Y+Math.imul(G0,B0)|0,X=X+Math.imul(G0,L0)|0,X=X+Math.imul(A0,B0)|0,O=O+Math.imul(A0,L0)|0,Y=Y+Math.imul(Z0,_)|0,X=X+Math.imul(Z0,w)|0,X=X+Math.imul(W0,_)|0,O=O+Math.imul(W0,w)|0,Y=Y+Math.imul(n,U0)|0,X=X+Math.imul(n,I0)|0,X=X+Math.imul(X0,U0)|0,O=O+Math.imul(X0,I0)|0,Y=Y+Math.imul(i,F0)|0,X=X+Math.imul(i,C0)|0,X=X+Math.imul(e,F0)|0,O=O+Math.imul(e,C0)|0,Y=Y+Math.imul(p,x0)|0,X=X+Math.imul(p,q0)|0,X=X+Math.imul(b,x0)|0,O=O+Math.imul(b,q0)|0,Y=Y+Math.imul(Q0,z0)|0,X=X+Math.imul(Q0,M0)|0,X=X+Math.imul($0,z0)|0,O=O+Math.imul($0,M0)|0;var $U=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,Y=Math.imul(J0,B0),X=Math.imul(J0,L0),X=X+Math.imul(T0,B0)|0,O=Math.imul(T0,L0),Y=Y+Math.imul(G0,_)|0,X=X+Math.imul(G0,w)|0,X=X+Math.imul(A0,_)|0,O=O+Math.imul(A0,w)|0,Y=Y+Math.imul(Z0,U0)|0,X=X+Math.imul(Z0,I0)|0,X=X+Math.imul(W0,U0)|0,O=O+Math.imul(W0,I0)|0,Y=Y+Math.imul(n,F0)|0,X=X+Math.imul(n,C0)|0,X=X+Math.imul(X0,F0)|0,O=O+Math.imul(X0,C0)|0,Y=Y+Math.imul(i,x0)|0,X=X+Math.imul(i,q0)|0,X=X+Math.imul(e,x0)|0,O=O+Math.imul(e,q0)|0,Y=Y+Math.imul(p,z0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(b,z0)|0,O=O+Math.imul(b,M0)|0;var YU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,Y=Math.imul(J0,_),X=Math.imul(J0,w),X=X+Math.imul(T0,_)|0,O=Math.imul(T0,w),Y=Y+Math.imul(G0,U0)|0,X=X+Math.imul(G0,I0)|0,X=X+Math.imul(A0,U0)|0,O=O+Math.imul(A0,I0)|0,Y=Y+Math.imul(Z0,F0)|0,X=X+Math.imul(Z0,C0)|0,X=X+Math.imul(W0,F0)|0,O=O+Math.imul(W0,C0)|0,Y=Y+Math.imul(n,x0)|0,X=X+Math.imul(n,q0)|0,X=X+Math.imul(X0,x0)|0,O=O+Math.imul(X0,q0)|0,Y=Y+Math.imul(i,z0)|0,X=X+Math.imul(i,M0)|0,X=X+Math.imul(e,z0)|0,O=O+Math.imul(e,M0)|0;var VU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,Y=Math.imul(J0,U0),X=Math.imul(J0,I0),X=X+Math.imul(T0,U0)|0,O=Math.imul(T0,I0),Y=Y+Math.imul(G0,F0)|0,X=X+Math.imul(G0,C0)|0,X=X+Math.imul(A0,F0)|0,O=O+Math.imul(A0,C0)|0,Y=Y+Math.imul(Z0,x0)|0,X=X+Math.imul(Z0,q0)|0,X=X+Math.imul(W0,x0)|0,O=O+Math.imul(W0,q0)|0,Y=Y+Math.imul(n,z0)|0,X=X+Math.imul(n,M0)|0,X=X+Math.imul(X0,z0)|0,O=O+Math.imul(X0,M0)|0;var OU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(OU>>>26)|0,OU&=67108863,Y=Math.imul(J0,F0),X=Math.imul(J0,C0),X=X+Math.imul(T0,F0)|0,O=Math.imul(T0,C0),Y=Y+Math.imul(G0,x0)|0,X=X+Math.imul(G0,q0)|0,X=X+Math.imul(A0,x0)|0,O=O+Math.imul(A0,q0)|0,Y=Y+Math.imul(Z0,z0)|0,X=X+Math.imul(Z0,M0)|0,X=X+Math.imul(W0,z0)|0,O=O+Math.imul(W0,M0)|0;var GU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,Y=Math.imul(J0,x0),X=Math.imul(J0,q0),X=X+Math.imul(T0,x0)|0,O=Math.imul(T0,q0),Y=Y+Math.imul(G0,z0)|0,X=X+Math.imul(G0,M0)|0,X=X+Math.imul(A0,z0)|0,O=O+Math.imul(A0,M0)|0;var KU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(KU>>>26)|0,KU&=67108863,Y=Math.imul(J0,z0),X=Math.imul(J0,M0),X=X+Math.imul(T0,z0)|0,O=Math.imul(T0,M0);var WU=(J+Y|0)+((X&8191)<<13)|0;if(J=(O+(X>>>13)|0)+(WU>>>26)|0,WU&=67108863,K[0]=t0,K[1]=p0,K[2]=f0,K[3]=b0,K[4]=a0,K[5]=e0,K[6]=i0,K[7]=UU,K[8]=XU,K[9]=IU,K[10]=ZU,K[11]=QU,K[12]=$U,K[13]=YU,K[14]=VU,K[15]=OU,K[16]=GU,K[17]=KU,K[18]=WU,J!==0)K[19]=J,Q.length++;return Q};if(!Math.imul)j=q;function x(F,U,Z){Z.negative=U.negative^F.negative,Z.length=F.length+U.length;var Q=0,I=0;for(var $=0;$<Z.length-1;$++){var K=I;I=0;var J=Q&67108863,Y=Math.min($,U.length-1);for(var X=Math.max(0,$-F.length+1);X<=Y;X++){var O=$-X,v=F.words[O]|0,T=U.words[X]|0,B=v*T,c=B&67108863;K=K+(B/67108864|0)|0,c=c+J|0,J=c&67108863,K=K+(c>>>26)|0,I+=K>>>26,K&=67108863}Z.words[$]=J,Q=K,K=I}if(Q!==0)Z.words[$]=Q;else Z.length--;return Z.strip()}function g(F,U,Z){var Q=new N;return Q.mulp(F,U,Z)}V.prototype.mulTo=function F(U,Z){var Q,I=this.length+U.length;if(this.length===10&&U.length===10)Q=j(this,U,Z);else if(I<63)Q=q(this,U,Z);else if(I<1024)Q=x(this,U,Z);else Q=g(this,U,Z);return Q};function N(F,U){this.x=F,this.y=U}N.prototype.makeRBT=function F(U){var Z=new Array(U),Q=V.prototype._countBits(U)-1;for(var I=0;I<U;I++)Z[I]=this.revBin(I,Q,U);return Z},N.prototype.revBin=function F(U,Z,Q){if(U===0||U===Q-1)return U;var I=0;for(var $=0;$<Z;$++)I|=(U&1)<<Z-$-1,U>>=1;return I},N.prototype.permute=function F(U,Z,Q,I,$,K){for(var J=0;J<K;J++)I[J]=Z[U[J]],$[J]=Q[U[J]]},N.prototype.transform=function F(U,Z,Q,I,$,K){this.permute(K,U,Z,Q,I,$);for(var J=1;J<$;J<<=1){var Y=J<<1,X=Math.cos(2*Math.PI/Y),O=Math.sin(2*Math.PI/Y);for(var v=0;v<$;v+=Y){var T=X,B=O;for(var c=0;c<J;c++){var l=Q[v+c],s=I[v+c],O0=Q[v+c+J],h=I[v+c+J],d=T*O0-B*h;if(h=T*h+B*O0,O0=d,Q[v+c]=l+O0,I[v+c]=s+h,Q[v+c+J]=l-O0,I[v+c+J]=s-h,c!==Y)d=X*T-O*B,B=X*B+O*T,T=d}}}},N.prototype.guessLen13b=function F(U,Z){var Q=Math.max(Z,U)|1,I=Q&1,$=0;for(Q=Q/2|0;Q;Q=Q>>>1)$++;return 1<<$+1+I},N.prototype.conjugate=function F(U,Z,Q){if(Q<=1)return;for(var I=0;I<Q/2;I++){var $=U[I];U[I]=U[Q-I-1],U[Q-I-1]=$,$=Z[I],Z[I]=-Z[Q-I-1],Z[Q-I-1]=-$}},N.prototype.normalize13b=function F(U,Z){var Q=0;for(var I=0;I<Z/2;I++){var $=Math.round(U[2*I+1]/Z)*8192+Math.round(U[2*I]/Z)+Q;if(U[I]=$&67108863,$<67108864)Q=0;else Q=$/67108864|0}return U},N.prototype.convert13b=function F(U,Z,Q,I){var $=0;for(var K=0;K<Z;K++)$=$+(U[K]|0),Q[2*K]=$&8191,$=$>>>13,Q[2*K+1]=$&8191,$=$>>>13;for(K=2*Z;K<I;++K)Q[K]=0;H($===0),H(($&-8192)===0)},N.prototype.stub=function F(U){var Z=new Array(U);for(var Q=0;Q<U;Q++)Z[Q]=0;return Z},N.prototype.mulp=function F(U,Z,Q){var I=2*this.guessLen13b(U.length,Z.length),$=this.makeRBT(I),K=this.stub(I),J=new Array(I),Y=new Array(I),X=new Array(I),O=new Array(I),v=new Array(I),T=new Array(I),B=Q.words;B.length=I,this.convert13b(U.words,U.length,J,I),this.convert13b(Z.words,Z.length,O,I),this.transform(J,K,Y,X,I,$),this.transform(O,K,v,T,I,$);for(var c=0;c<I;c++){var l=Y[c]*v[c]-X[c]*T[c];X[c]=Y[c]*T[c]+X[c]*v[c],Y[c]=l}return this.conjugate(Y,X,I),this.transform(Y,X,B,K,I,$),this.conjugate(B,K,I),this.normalize13b(B,I),Q.negative=U.negative^Z.negative,Q.length=U.length+Z.length,Q.strip()},V.prototype.mul=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),this.mulTo(U,Z)},V.prototype.mulf=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),g(this,U,Z)},V.prototype.imul=function F(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function F(U){H(typeof U==="number"),H(U<67108864);var Z=0;for(var Q=0;Q<this.length;Q++){var I=(this.words[Q]|0)*U,$=(I&67108863)+(Z&67108863);Z>>=26,Z+=I/67108864|0,Z+=$>>>26,this.words[Q]=$&67108863}if(Z!==0)this.words[Q]=Z,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function F(U){return this.clone().imuln(U)},V.prototype.sqr=function F(){return this.mul(this)},V.prototype.isqr=function F(){return this.imul(this.clone())},V.prototype.pow=function F(U){var Z=M(U);if(Z.length===0)return new V(1);var Q=this;for(var I=0;I<Z.length;I++,Q=Q.sqr())if(Z[I]!==0)break;if(++I<Z.length)for(var $=Q.sqr();I<Z.length;I++,$=$.sqr()){if(Z[I]===0)continue;Q=Q.mul($)}return Q},V.prototype.iushln=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=67108863>>>26-Z<<26-Z,$;if(Z!==0){var K=0;for($=0;$<this.length;$++){var J=this.words[$]&I,Y=(this.words[$]|0)-J<<Z;this.words[$]=Y|K,K=J>>>26-Z}if(K)this.words[$]=K,this.length++}if(Q!==0){for($=this.length-1;$>=0;$--)this.words[$+Q]=this.words[$];for($=0;$<Q;$++)this.words[$]=0;this.length+=Q}return this.strip()},V.prototype.ishln=function F(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function F(U,Z,Q){H(typeof U==="number"&&U>=0);var I;if(Z)I=(Z-Z%26)/26;else I=0;var $=U%26,K=Math.min((U-$)/26,this.length),J=67108863^67108863>>>$<<$,Y=Q;if(I-=K,I=Math.max(0,I),Y){for(var X=0;X<K;X++)Y.words[X]=this.words[X];Y.length=K}if(K===0);else if(this.length>K){this.length-=K;for(X=0;X<this.length;X++)this.words[X]=this.words[X+K]}else this.words[0]=0,this.length=1;var O=0;for(X=this.length-1;X>=0&&(O!==0||X>=I);X--){var v=this.words[X]|0;this.words[X]=O<<26-$|v>>>$,O=v&J}if(Y&&O!==0)Y.words[Y.length++]=O;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function F(U,Z,Q){return H(this.negative===0),this.iushrn(U,Z,Q)},V.prototype.shln=function F(U){return this.clone().ishln(U)},V.prototype.ushln=function F(U){return this.clone().iushln(U)},V.prototype.shrn=function F(U){return this.clone().ishrn(U)},V.prototype.ushrn=function F(U){return this.clone().iushrn(U)},V.prototype.testn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return!1;var $=this.words[Q];return!!($&I)},V.prototype.imaskn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=Q)return this;if(Z!==0)Q++;if(this.length=Math.min(Q,this.length),Z!==0){var I=67108863^67108863>>>Z<<Z;this.words[this.length-1]&=I}return this.strip()},V.prototype.maskn=function F(U){return this.clone().imaskn(U)},V.prototype.iaddn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.isubn(-U);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<U)return this.words[0]=U-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(U),this.negative=1,this}return this._iaddn(U)},V.prototype._iaddn=function F(U){this.words[0]+=U;for(var Z=0;Z<this.length&&this.words[Z]>=67108864;Z++)if(this.words[Z]-=67108864,Z===this.length-1)this.words[Z+1]=1;else this.words[Z+1]++;return this.length=Math.max(this.length,Z+1),this},V.prototype.isubn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.iaddn(-U);if(this.negative!==0)return this.negative=0,this.iaddn(U),this.negative=1,this;if(this.words[0]-=U,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Z=0;Z<this.length&&this.words[Z]<0;Z++)this.words[Z]+=67108864,this.words[Z+1]-=1;return this.strip()},V.prototype.addn=function F(U){return this.clone().iaddn(U)},V.prototype.subn=function F(U){return this.clone().isubn(U)},V.prototype.iabs=function F(){return this.negative=0,this},V.prototype.abs=function F(){return this.clone().iabs()},V.prototype._ishlnsubmul=function F(U,Z,Q){var I=U.length+Q,$;this._expand(I);var K,J=0;for($=0;$<U.length;$++){K=(this.words[$+Q]|0)+J;var Y=(U.words[$]|0)*Z;K-=Y&67108863,J=(K>>26)-(Y/67108864|0),this.words[$+Q]=K&67108863}for(;$<this.length-Q;$++)K=(this.words[$+Q]|0)+J,J=K>>26,this.words[$+Q]=K&67108863;if(J===0)return this.strip();H(J===-1),J=0;for($=0;$<this.length;$++)K=-(this.words[$]|0)+J,J=K>>26,this.words[$]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function F(U,Z){var Q=this.length-U.length,I=this.clone(),$=U,K=$.words[$.length-1]|0,J=this._countBits(K);if(Q=26-J,Q!==0)$=$.ushln(Q),I.iushln(Q),K=$.words[$.length-1]|0;var Y=I.length-$.length,X;if(Z!=="mod"){X=new V(null),X.length=Y+1,X.words=new Array(X.length);for(var O=0;O<X.length;O++)X.words[O]=0}var v=I.clone()._ishlnsubmul($,1,Y);if(v.negative===0){if(I=v,X)X.words[Y]=1}for(var T=Y-1;T>=0;T--){var B=(I.words[$.length+T]|0)*67108864+(I.words[$.length+T-1]|0);B=Math.min(B/K|0,67108863),I._ishlnsubmul($,B,T);while(I.negative!==0)if(B--,I.negative=0,I._ishlnsubmul($,1,T),!I.isZero())I.negative^=1;if(X)X.words[T]=B}if(X)X.strip();if(I.strip(),Z!=="div"&&Q!==0)I.iushrn(Q);return{div:X||null,mod:I}},V.prototype.divmod=function F(U,Z,Q){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var I,$,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Z),Z!=="mod")I=K.div.neg();if(Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.iadd(U)}return{div:I,mod:$}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Z),Z!=="mod")I=K.div.neg();return{div:I,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Z),Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.isub(U)}return{div:K.div,mod:$}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Z==="div")return{div:this.divn(U.words[0]),mod:null};if(Z==="mod")return{div:null,mod:new V(this.modn(U.words[0]))};return{div:this.divn(U.words[0]),mod:new V(this.modn(U.words[0]))}}return this._wordDiv(U,Z)},V.prototype.div=function F(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function F(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function F(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function F(U){var Z=this.divmod(U);if(Z.mod.isZero())return Z.div;var Q=Z.div.negative!==0?Z.mod.isub(U):Z.mod,I=U.ushrn(1),$=U.andln(1),K=Q.cmp(I);if(K<0||$===1&&K===0)return Z.div;return Z.div.negative!==0?Z.div.isubn(1):Z.div.iaddn(1)},V.prototype.modn=function F(U){H(U<=67108863);var Z=67108864%U,Q=0;for(var I=this.length-1;I>=0;I--)Q=(Z*Q+(this.words[I]|0))%U;return Q},V.prototype.idivn=function F(U){H(U<=67108863);var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=(this.words[Q]|0)+Z*67108864;this.words[Q]=I/U|0,Z=I%U}return this.strip()},V.prototype.divn=function F(U){return this.clone().idivn(U)},V.prototype.egcd=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=new V(0),J=new V(1),Y=0;while(Z.isEven()&&Q.isEven())Z.iushrn(1),Q.iushrn(1),++Y;var X=Q.clone(),O=Z.clone();while(!Z.isZero()){for(var v=0,T=1;(Z.words[0]&T)===0&&v<26;++v,T<<=1);if(v>0){Z.iushrn(v);while(v-- >0){if(I.isOdd()||$.isOdd())I.iadd(X),$.isub(O);I.iushrn(1),$.iushrn(1)}}for(var B=0,c=1;(Q.words[0]&c)===0&&B<26;++B,c<<=1);if(B>0){Q.iushrn(B);while(B-- >0){if(K.isOdd()||J.isOdd())K.iadd(X),J.isub(O);K.iushrn(1),J.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub(K),$.isub(J);else Q.isub(Z),K.isub(I),J.isub($)}return{a:K,b:J,gcd:Q.iushln(Y)}},V.prototype._invmp=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=Q.clone();while(Z.cmpn(1)>0&&Q.cmpn(1)>0){for(var J=0,Y=1;(Z.words[0]&Y)===0&&J<26;++J,Y<<=1);if(J>0){Z.iushrn(J);while(J-- >0){if(I.isOdd())I.iadd(K);I.iushrn(1)}}for(var X=0,O=1;(Q.words[0]&O)===0&&X<26;++X,O<<=1);if(X>0){Q.iushrn(X);while(X-- >0){if($.isOdd())$.iadd(K);$.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub($);else Q.isub(Z),$.isub(I)}var v;if(Z.cmpn(1)===0)v=I;else v=$;if(v.cmpn(0)<0)v.iadd(U);return v},V.prototype.gcd=function F(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Z=this.clone(),Q=U.clone();Z.negative=0,Q.negative=0;for(var I=0;Z.isEven()&&Q.isEven();I++)Z.iushrn(1),Q.iushrn(1);do{while(Z.isEven())Z.iushrn(1);while(Q.isEven())Q.iushrn(1);var $=Z.cmp(Q);if($<0){var K=Z;Z=Q,Q=K}else if($===0||Q.cmpn(1)===0)break;Z.isub(Q)}while(!0);return Q.iushln(I)},V.prototype.invm=function F(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function F(){return(this.words[0]&1)===0},V.prototype.isOdd=function F(){return(this.words[0]&1)===1},V.prototype.andln=function F(U){return this.words[0]&U},V.prototype.bincn=function F(U){H(typeof U==="number");var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return this._expand(Q+1),this.words[Q]|=I,this;var $=I;for(var K=Q;$!==0&&K<this.length;K++){var J=this.words[K]|0;J+=$,$=J>>>26,J&=67108863,this.words[K]=J}if($!==0)this.words[K]=$,this.length++;return this},V.prototype.isZero=function F(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function F(U){var Z=U<0;if(this.negative!==0&&!Z)return-1;if(this.negative===0&&Z)return 1;this.strip();var Q;if(this.length>1)Q=1;else{if(Z)U=-U;H(U<=67108863,"Number is too big");var I=this.words[0]|0;Q=I===U?0:I<U?-1:1}if(this.negative!==0)return-Q|0;return Q},V.prototype.cmp=function F(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Z=this.ucmp(U);if(this.negative!==0)return-Z|0;return Z},V.prototype.ucmp=function F(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=this.words[Q]|0,$=U.words[Q]|0;if(I===$)continue;if(I<$)Z=-1;else if(I>$)Z=1;break}return Z},V.prototype.gtn=function F(U){return this.cmpn(U)===1},V.prototype.gt=function F(U){return this.cmp(U)===1},V.prototype.gten=function F(U){return this.cmpn(U)>=0},V.prototype.gte=function F(U){return this.cmp(U)>=0},V.prototype.ltn=function F(U){return this.cmpn(U)===-1},V.prototype.lt=function F(U){return this.cmp(U)===-1},V.prototype.lten=function F(U){return this.cmpn(U)<=0},V.prototype.lte=function F(U){return this.cmp(U)<=0},V.prototype.eqn=function F(U){return this.cmpn(U)===0},V.prototype.eq=function F(U){return this.cmp(U)===0},V.red=function F(U){return new u(U)},V.prototype.toRed=function F(U){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),U.convertTo(this)._forceRed(U)},V.prototype.fromRed=function F(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function F(U){return this.red=U,this},V.prototype.forceRed=function F(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function F(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function F(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function F(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function F(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function F(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.mul(this,U)},V.prototype.redIMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.imul(this,U)},V.prototype.redSqr=function F(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function F(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function F(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function F(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function F(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function F(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var y={k256:null,p224:null,p192:null,p25519:null};function f(F,U){this.name=F,this.p=new V(U,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}f.prototype._tmp=function F(){var U=new V(null);return U.words=new Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function F(U){var Z=U,Q;do this.split(Z,this.tmp),Z=this.imulK(Z),Z=Z.iadd(this.tmp),Q=Z.bitLength();while(Q>this.n);var I=Q<this.n?-1:Z.ucmp(this.p);if(I===0)Z.words[0]=0,Z.length=1;else if(I>0)Z.isub(this.p);else if(Z.strip!==void 0)Z.strip();else Z._strip();return Z},f.prototype.split=function F(U,Z){U.iushrn(this.n,0,Z)},f.prototype.imulK=function F(U){return U.imul(this.k)};function o(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}z(o,f),o.prototype.split=function F(U,Z){var Q=4194303,I=Math.min(U.length,9);for(var $=0;$<I;$++)Z.words[$]=U.words[$];if(Z.length=I,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Z.words[Z.length++]=K&Q;for($=10;$<U.length;$++){var J=U.words[$]|0;U.words[$-10]=(J&Q)<<4|K>>>22,K=J}if(K>>>=22,U.words[$-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},o.prototype.imulK=function F(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Z=0;for(var Q=0;Q<U.length;Q++){var I=U.words[Q]|0;Z+=I*977,U.words[Q]=Z&67108863,Z=I*64+(Z/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function r(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}z(r,f);function V0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}z(V0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}z(Y0,f),Y0.prototype.imulK=function F(U){var Z=0;for(var Q=0;Q<U.length;Q++){var I=(U.words[Q]|0)*19+Z,$=I&67108863;I>>>=26,U.words[Q]=$,Z=I}if(Z!==0)U.words[U.length++]=Z;return U},V._prime=function F(U){if(y[U])return y[U];var Z;if(U==="k256")Z=new o;else if(U==="p224")Z=new r;else if(U==="p192")Z=new V0;else if(U==="p25519")Z=new Y0;else throw new Error("Unknown prime "+U);return y[U]=Z,Z};function u(F){if(typeof F==="string"){var U=V._prime(F);this.m=U.p,this.prime=U}else H(F.gtn(1),"modulus must be greater than 1"),this.m=F,this.prime=null}u.prototype._verify1=function F(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function F(U,Z){H((U.negative|Z.negative)===0,"red works only with positives"),H(U.red&&U.red===Z.red,"red works only with red numbers")},u.prototype.imod=function F(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function F(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function F(U,Z){this._verify2(U,Z);var Q=U.add(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q._forceRed(this)},u.prototype.iadd=function F(U,Z){this._verify2(U,Z);var Q=U.iadd(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q},u.prototype.sub=function F(U,Z){this._verify2(U,Z);var Q=U.sub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q._forceRed(this)},u.prototype.isub=function F(U,Z){this._verify2(U,Z);var Q=U.isub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q},u.prototype.shl=function F(U,Z){return this._verify1(U),this.imod(U.ushln(Z))},u.prototype.imul=function F(U,Z){return this._verify2(U,Z),this.imod(U.imul(Z))},u.prototype.mul=function F(U,Z){return this._verify2(U,Z),this.imod(U.mul(Z))},u.prototype.isqr=function F(U){return this.imul(U,U.clone())},u.prototype.sqr=function F(U){return this.mul(U,U)},u.prototype.sqrt=function F(U){if(U.isZero())return U.clone();var Z=this.m.andln(3);if(H(Z%2===1),Z===3){var Q=this.m.add(new V(1)).iushrn(2);return this.pow(U,Q)}var I=this.m.subn(1),$=0;while(!I.isZero()&&I.andln(1)===0)$++,I.iushrn(1);H(!I.isZero());var K=new V(1).toRed(this),J=K.redNeg(),Y=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,Y).cmp(J)!==0)X.redIAdd(J);var O=this.pow(X,I),v=this.pow(U,I.addn(1).iushrn(1)),T=this.pow(U,I),B=$;while(T.cmp(K)!==0){var c=T;for(var l=0;c.cmp(K)!==0;l++)c=c.redSqr();H(l<B);var s=this.pow(O,new V(1).iushln(B-l-1));v=v.redMul(s),O=s.redSqr(),T=T.redMul(O),B=l}return v},u.prototype.invm=function F(U){var Z=U._invmp(this.m);if(Z.negative!==0)return Z.negative=0,this.imod(Z).redNeg();else return this.imod(Z)},u.prototype.pow=function F(U,Z){if(Z.isZero())return new V(1).toRed(this);if(Z.cmpn(1)===0)return U.clone();var Q=4,I=new Array(1<<Q);I[0]=new V(1).toRed(this),I[1]=U;for(var $=2;$<I.length;$++)I[$]=this.mul(I[$-1],U);var K=I[0],J=0,Y=0,X=Z.bitLength()%26;if(X===0)X=26;for($=Z.length-1;$>=0;$--){var O=Z.words[$];for(var v=X-1;v>=0;v--){var T=O>>v&1;if(K!==I[0])K=this.sqr(K);if(T===0&&J===0){Y=0;continue}if(J<<=1,J|=T,Y++,Y!==Q&&($!==0||v!==0))continue;K=this.mul(K,I[J]),Y=0,J=0}X=26}return K},u.prototype.convertTo=function F(U){var Z=U.umod(this.m);return Z===U?Z.clone():Z},u.prototype.convertFrom=function F(U){var Z=U.clone();return Z.red=null,Z},V.mont=function F(U){return new a(U)};function a(F){if(u.call(this,F),this.shift=this.m.bitLength(),this.shift%26!==0)this.shift+=26-this.shift%26;this.r=new V(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}z(a,u),a.prototype.convertTo=function F(U){return this.imod(U.ushln(this.shift))},a.prototype.convertFrom=function F(U){var Z=this.imod(U.mul(this.rinv));return Z.red=null,Z},a.prototype.imul=function F(U,Z){if(U.isZero()||Z.isZero())return U.words[0]=0,U.length=1,U;var Q=U.imul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.mul=function F(U,Z){if(U.isZero()||Z.isZero())return new V(0)._forceRed(this);var Q=U.mul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.invm=function F(U){var Z=this.imod(U._invmp(this.m).mul(this.r2));return Z._forceRed(this)}})(typeof G==="undefined"||G,E)}),dY=w0((E)=>{var G=TX(),W=kU(),C=E;C.define=function z(V,P){return new H(V,P)};function H(z,V){this.name=z,this.body=V,this.decoders={},this.encoders={}}H.prototype._createNamed=function z(V){var P;try{P=(()=>{throw new Error("Cannot require module "+"vm");})().runInThisContext("(function "+this.name+`(entity) {
12
+ this._initNamed(entity);
13
+ })`)}catch(k){P=function(R){this._initNamed(R)}}return W(P,V),P.prototype._initNamed=function k(R){V.call(this,R)},new P(this)},H.prototype._getDecoder=function z(V){if(V=V||"der",!this.decoders.hasOwnProperty(V))this.decoders[V]=this._createNamed(G.decoders[V]);return this.decoders[V]},H.prototype.decode=function z(V,P,k){return this._getDecoder(P).decode(V,k)},H.prototype._getEncoder=function z(V){if(V=V||"der",!this.encoders.hasOwnProperty(V))this.encoders[V]=this._createNamed(G.encoders[V]);return this.encoders[V]},H.prototype.encode=function z(V,P,k){return this._getEncoder(P).encode(V,k)}}),bY=w0((E)=>{var G=kU();function W(H){this._reporterState={obj:null,path:[],options:H||{},errors:[]}}E.Reporter=W,W.prototype.isError=function H(z){return z instanceof C},W.prototype.save=function H(){var z=this._reporterState;return{obj:z.obj,pathLen:z.path.length}},W.prototype.restore=function H(z){var V=this._reporterState;V.obj=z.obj,V.path=V.path.slice(0,z.pathLen)},W.prototype.enterKey=function H(z){return this._reporterState.path.push(z)},W.prototype.exitKey=function H(z){var V=this._reporterState;V.path=V.path.slice(0,z-1)},W.prototype.leaveKey=function H(z,V,P){var k=this._reporterState;if(this.exitKey(z),k.obj!==null)k.obj[V]=P},W.prototype.path=function H(){return this._reporterState.path.join("/")},W.prototype.enterObject=function H(){var z=this._reporterState,V=z.obj;return z.obj={},V},W.prototype.leaveObject=function H(z){var V=this._reporterState,P=V.obj;return V.obj=z,P},W.prototype.error=function H(z){var V,P=this._reporterState,k=z instanceof C;if(k)V=z;else V=new C(P.path.map(function(R){return"["+JSON.stringify(R)+"]"}).join(""),z.message||z,z.stack);if(!P.options.partial)throw V;if(!k)P.errors.push(V);return V},W.prototype.wrapResult=function H(z){var V=this._reporterState;if(!V.options.partial)return z;return{result:this.isError(z)?null:z,errors:V.errors}};function C(H,z){this.path=H,this.rethrow(z)}G(C,Error),C.prototype.rethrow=function H(z){if(this.message=z+" at: "+(this.path||"(shallow)"),Error.captureStackTrace)Error.captureStackTrace(this,C);if(!this.stack)try{throw new Error(this.message)}catch(V){this.stack=V.stack}return this}}),TZ=w0((E)=>{var G=kU(),W=EX().Reporter,C=(HU(),y0(FU)).Buffer;function H(V,P){if(W.call(this,P),!C.isBuffer(V)){this.error("Input not Buffer");return}this.base=V,this.offset=0,this.length=V.length}G(H,W),E.DecoderBuffer=H,H.prototype.save=function V(){return{offset:this.offset,reporter:W.prototype.save.call(this)}},H.prototype.restore=function V(P){var k=new H(this.base);return k.offset=P.offset,k.length=this.offset,this.offset=P.offset,W.prototype.restore.call(this,P.reporter),k},H.prototype.isEmpty=function V(){return this.offset===this.length},H.prototype.readUInt8=function V(P){if(this.offset+1<=this.length)return this.base.readUInt8(this.offset++,!0);else return this.error(P||"DecoderBuffer overrun")},H.prototype.skip=function V(P,k){if(!(this.offset+P<=this.length))return this.error(k||"DecoderBuffer overrun");var R=new H(this.base);return R._reporterState=this._reporterState,R.offset=this.offset,R.length=this.offset+P,this.offset+=P,R},H.prototype.raw=function V(P){return this.base.slice(P?P.offset:this.offset,this.length)};function z(V,P){if(Array.isArray(V))this.length=0,this.value=V.map(function(k){if(!(k instanceof z))k=new z(k,P);return this.length+=k.length,k},this);else if(typeof V==="number"){if(!(0<=V&&V<=255))return P.error("non-byte EncoderBuffer value");this.value=V,this.length=1}else if(typeof V==="string")this.value=V,this.length=C.byteLength(V);else if(C.isBuffer(V))this.value=V,this.length=V.length;else return P.error("Unsupported type: "+typeof V)}E.EncoderBuffer=z,z.prototype.join=function V(P,k){if(!P)P=new C(this.length);if(!k)k=0;if(this.length===0)return P;if(Array.isArray(this.value))this.value.forEach(function(R){R.join(P,k),k+=R.length});else{if(typeof this.value==="number")P[k]=this.value;else if(typeof this.value==="string")P.write(this.value,k);else if(C.isBuffer(this.value))this.value.copy(P,k);k+=this.length}return P}}),oY=w0((E,G)=>{var W=EX().Reporter,C=EX().EncoderBuffer,H=EX().DecoderBuffer,z=sU(),V=["seq","seqof","set","setof","objid","bool","gentime","utctime","null_","enum","int","objDesc","bitstr","bmpstr","charstr","genstr","graphstr","ia5str","iso646str","numstr","octstr","printstr","t61str","unistr","utf8str","videostr"],P=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(V),k=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function R(D,A){var L={};if(this._baseState=L,L.enc=D,L.parent=A||null,L.children=null,L.tag=null,L.args=null,L.reverseArgs=null,L.choice=null,L.optional=!1,L.any=!1,L.obj=!1,L.use=null,L.useDecoder=null,L.key=null,L.default=null,L.explicit=null,L.implicit=null,L.contains=null,!L.parent)L.children=[],this._wrap()}G.exports=R;var S=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];R.prototype.clone=function D(){var A=this._baseState,L={};S.forEach(function(q){L[q]=A[q]});var M=new this.constructor(L.parent);return M._baseState=L,M},R.prototype._wrap=function D(){var A=this._baseState;P.forEach(function(L){this[L]=function M(){var q=new this.constructor(this);return A.children.push(q),q[L].apply(q,arguments)}},this)},R.prototype._init=function D(A){var L=this._baseState;z(L.parent===null),A.call(this),L.children=L.children.filter(function(M){return M._baseState.parent===this},this),z.equal(L.children.length,1,"Root node can have only one child")},R.prototype._useArgs=function D(A){var L=this._baseState,M=A.filter(function(q){return q instanceof this.constructor},this);if(A=A.filter(function(q){return!(q instanceof this.constructor)},this),M.length!==0)z(L.children===null),L.children=M,M.forEach(function(q){q._baseState.parent=this},this);if(A.length!==0)z(L.args===null),L.args=A,L.reverseArgs=A.map(function(q){if(typeof q!=="object"||q.constructor!==Object)return q;var j={};return Object.keys(q).forEach(function(x){if(x==(x|0))x|=0;var g=q[x];j[g]=x}),j})},k.forEach(function(D){R.prototype[D]=function A(){var L=this._baseState;throw new Error(D+" not implemented for encoding: "+L.enc)}}),V.forEach(function(D){R.prototype[D]=function A(){var L=this._baseState,M=Array.prototype.slice.call(arguments);return z(L.tag===null),L.tag=D,this._useArgs(M),this}}),R.prototype.use=function D(A){z(A);var L=this._baseState;return z(L.use===null),L.use=A,this},R.prototype.optional=function D(){var A=this._baseState;return A.optional=!0,this},R.prototype.def=function D(A){var L=this._baseState;return z(L.default===null),L.default=A,L.optional=!0,this},R.prototype.explicit=function D(A){var L=this._baseState;return z(L.explicit===null&&L.implicit===null),L.explicit=A,this},R.prototype.implicit=function D(A){var L=this._baseState;return z(L.explicit===null&&L.implicit===null),L.implicit=A,this},R.prototype.obj=function D(){var A=this._baseState,L=Array.prototype.slice.call(arguments);if(A.obj=!0,L.length!==0)this._useArgs(L);return this},R.prototype.key=function D(A){var L=this._baseState;return z(L.key===null),L.key=A,this},R.prototype.any=function D(){var A=this._baseState;return A.any=!0,this},R.prototype.choice=function D(A){var L=this._baseState;return z(L.choice===null),L.choice=A,this._useArgs(Object.keys(A).map(function(M){return A[M]})),this},R.prototype.contains=function D(A){var L=this._baseState;return z(L.use===null),L.contains=A,this},R.prototype._decode=function D(A,L){var M=this._baseState;if(M.parent===null)return A.wrapResult(M.children[0]._decode(A,L));var q=M.default,j=!0,x=null;if(M.key!==null)x=A.enterKey(M.key);if(M.optional){var g=null;if(M.explicit!==null)g=M.explicit;else if(M.implicit!==null)g=M.implicit;else if(M.tag!==null)g=M.tag;if(g===null&&!M.any){var N=A.save();try{if(M.choice===null)this._decodeGeneric(M.tag,A,L);else this._decodeChoice(A,L);j=!0}catch(Y0){j=!1}A.restore(N)}else if(j=this._peekTag(A,g,M.any),A.isError(j))return j}var y;if(M.obj&&j)y=A.enterObject();if(j){if(M.explicit!==null){var f=this._decodeTag(A,M.explicit);if(A.isError(f))return f;A=f}var o=A.offset;if(M.use===null&&M.choice===null){if(M.any)var N=A.save();var r=this._decodeTag(A,M.implicit!==null?M.implicit:M.tag,M.any);if(A.isError(r))return r;if(M.any)q=A.raw(N);else A=r}if(L&&L.track&&M.tag!==null)L.track(A.path(),o,A.length,"tagged");if(L&&L.track&&M.tag!==null)L.track(A.path(),A.offset,A.length,"content");if(M.any)q=q;else if(M.choice===null)q=this._decodeGeneric(M.tag,A,L);else q=this._decodeChoice(A,L);if(A.isError(q))return q;if(!M.any&&M.choice===null&&M.children!==null)M.children.forEach(function Y0(u){u._decode(A,L)});if(M.contains&&(M.tag==="octstr"||M.tag==="bitstr")){var V0=new H(q);q=this._getUse(M.contains,A._reporterState.obj)._decode(V0,L)}}if(M.obj&&j)q=A.leaveObject(y);if(M.key!==null&&(q!==null||j===!0))A.leaveKey(x,M.key,q);else if(x!==null)A.exitKey(x);return q},R.prototype._decodeGeneric=function D(A,L,M){var q=this._baseState;if(A==="seq"||A==="set")return null;if(A==="seqof"||A==="setof")return this._decodeList(L,A,q.args[0],M);else if(/str$/.test(A))return this._decodeStr(L,A,M);else if(A==="objid"&&q.args)return this._decodeObjid(L,q.args[0],q.args[1],M);else if(A==="objid")return this._decodeObjid(L,null,null,M);else if(A==="gentime"||A==="utctime")return this._decodeTime(L,A,M);else if(A==="null_")return this._decodeNull(L,M);else if(A==="bool")return this._decodeBool(L,M);else if(A==="objDesc")return this._decodeStr(L,A,M);else if(A==="int"||A==="enum")return this._decodeInt(L,q.args&&q.args[0],M);if(q.use!==null)return this._getUse(q.use,L._reporterState.obj)._decode(L,M);else return L.error("unknown tag: "+A)},R.prototype._getUse=function D(A,L){var M=this._baseState;if(M.useDecoder=this._use(A,L),z(M.useDecoder._baseState.parent===null),M.useDecoder=M.useDecoder._baseState.children[0],M.implicit!==M.useDecoder._baseState.implicit)M.useDecoder=M.useDecoder.clone(),M.useDecoder._baseState.implicit=M.implicit;return M.useDecoder},R.prototype._decodeChoice=function D(A,L){var M=this._baseState,q=null,j=!1;if(Object.keys(M.choice).some(function(x){var g=A.save(),N=M.choice[x];try{var y=N._decode(A,L);if(A.isError(y))return!1;q={type:x,value:y},j=!0}catch(f){return A.restore(g),!1}return!0},this),!j)return A.error("Choice not matched");return q},R.prototype._createEncoderBuffer=function D(A){return new C(A,this.reporter)},R.prototype._encode=function D(A,L,M){var q=this._baseState;if(q.default!==null&&q.default===A)return;var j=this._encodeValue(A,L,M);if(j===void 0)return;if(this._skipDefault(j,L,M))return;return j},R.prototype._encodeValue=function D(A,L,M){var q=this._baseState;if(q.parent===null)return q.children[0]._encode(A,L||new W);var N=null;if(this.reporter=L,q.optional&&A===void 0)if(q.default!==null)A=q.default;else return;var j=null,x=!1;if(q.any)N=this._createEncoderBuffer(A);else if(q.choice)N=this._encodeChoice(A,L);else if(q.contains)j=this._getUse(q.contains,M)._encode(A,L),x=!0;else if(q.children)j=q.children.map(function(o){if(o._baseState.tag==="null_")return o._encode(null,L,A);if(o._baseState.key===null)return L.error("Child should have a key");var r=L.enterKey(o._baseState.key);if(typeof A!=="object")return L.error("Child expected, but input is not object");var V0=o._encode(A[o._baseState.key],L,A);return L.leaveKey(r),V0},this).filter(function(o){return o}),j=this._createEncoderBuffer(j);else if(q.tag==="seqof"||q.tag==="setof"){if(!(q.args&&q.args.length===1))return L.error("Too many args for : "+q.tag);if(!Array.isArray(A))return L.error("seqof/setof, but data is not Array");var g=this.clone();g._baseState.implicit=null,j=this._createEncoderBuffer(A.map(function(o){var r=this._baseState;return this._getUse(r.args[0],A)._encode(o,L)},g))}else if(q.use!==null)N=this._getUse(q.use,M)._encode(A,L);else j=this._encodePrimitive(q.tag,A),x=!0;var N;if(!q.any&&q.choice===null){var y=q.implicit!==null?q.implicit:q.tag,f=q.implicit===null?"universal":"context";if(y===null){if(q.use===null)L.error("Tag could be omitted only for .use()")}else if(q.use===null)N=this._encodeComposite(y,x,f,j)}if(q.explicit!==null)N=this._encodeComposite(q.explicit,!1,"context",N);return N},R.prototype._encodeChoice=function D(A,L){var M=this._baseState,q=M.choice[A.type];if(!q)z(!1,A.type+" not found in "+JSON.stringify(Object.keys(M.choice)));return q._encode(A.value,L)},R.prototype._encodePrimitive=function D(A,L){var M=this._baseState;if(/str$/.test(A))return this._encodeStr(L,A);else if(A==="objid"&&M.args)return this._encodeObjid(L,M.reverseArgs[0],M.args[1]);else if(A==="objid")return this._encodeObjid(L,null,null);else if(A==="gentime"||A==="utctime")return this._encodeTime(L,A);else if(A==="null_")return this._encodeNull();else if(A==="int"||A==="enum")return this._encodeInt(L,M.args&&M.reverseArgs[0]);else if(A==="bool")return this._encodeBool(L);else if(A==="objDesc")return this._encodeStr(L,A);else throw new Error("Unsupported tag: "+A)},R.prototype._isNumstr=function D(A){return/^[0-9 ]*$/.test(A)},R.prototype._isPrintstr=function D(A){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(A)}}),EX=w0((E)=>{var G=E;G.Reporter=bY().Reporter,G.DecoderBuffer=TZ().DecoderBuffer,G.EncoderBuffer=TZ().EncoderBuffer,G.Node=oY()}),nY=w0((E)=>{var G=kZ();E.tagClass={0:"universal",1:"application",2:"context",3:"private"},E.tagClassByName=G._reverse(E.tagClass),E.tag={0:"end",1:"bool",2:"int",3:"bitstr",4:"octstr",5:"null_",6:"objid",7:"objDesc",8:"external",9:"real",10:"enum",11:"embed",12:"utf8str",13:"relativeOid",16:"seq",17:"set",18:"numstr",19:"printstr",20:"t61str",21:"videostr",22:"ia5str",23:"utctime",24:"gentime",25:"graphstr",26:"iso646str",27:"genstr",28:"unistr",29:"charstr",30:"bmpstr"},E.tagByName=G._reverse(E.tag)}),kZ=w0((E)=>{var G=E;G._reverse=function W(C){var H={};return Object.keys(C).forEach(function(z){if((z|0)==z)z=z|0;var V=C[z];H[V]=z}),H},G.der=nY()}),jZ=w0((E,G)=>{var W=kU(),C=TX(),H=C.base,z=C.bignum,V=C.constants.der;function P(D){this.enc="der",this.name=D.name,this.entity=D,this.tree=new k,this.tree._init(D.body)}G.exports=P,P.prototype.decode=function D(A,L){if(!(A instanceof H.DecoderBuffer))A=new H.DecoderBuffer(A,L);return this.tree._decode(A,L)};function k(D){H.Node.call(this,"der",D)}W(k,H.Node),k.prototype._peekTag=function D(A,L,M){if(A.isEmpty())return!1;var q=A.save(),j=R(A,'Failed to peek tag: "'+L+'"');if(A.isError(j))return j;return A.restore(q),j.tag===L||j.tagStr===L||j.tagStr+"of"===L||M},k.prototype._decodeTag=function D(A,L,M){var q=R(A,'Failed to decode tag of "'+L+'"');if(A.isError(q))return q;var j=S(A,q.primitive,'Failed to get length of "'+L+'"');if(A.isError(j))return j;if(!M&&q.tag!==L&&q.tagStr!==L&&q.tagStr+"of"!==L)return A.error('Failed to match tag: "'+L+'"');if(q.primitive||j!==null)return A.skip(j,'Failed to match body of: "'+L+'"');var x=A.save(),g=this._skipUntilEnd(A,'Failed to skip indefinite length body: "'+this.tag+'"');if(A.isError(g))return g;return j=A.offset-x.offset,A.restore(x),A.skip(j,'Failed to match body of: "'+L+'"')},k.prototype._skipUntilEnd=function D(A,L){while(!0){var M=R(A,L);if(A.isError(M))return M;var q=S(A,M.primitive,L);if(A.isError(q))return q;var j;if(M.primitive||q!==null)j=A.skip(q);else j=this._skipUntilEnd(A,L);if(A.isError(j))return j;if(M.tagStr==="end")break}},k.prototype._decodeList=function D(A,L,M,q){var j=[];while(!A.isEmpty()){var x=this._peekTag(A,"end");if(A.isError(x))return x;var g=M.decode(A,"der",q);if(A.isError(g)&&x)break;j.push(g)}return j},k.prototype._decodeStr=function D(A,L){if(L==="bitstr"){var M=A.readUInt8();if(A.isError(M))return M;return{unused:M,data:A.raw()}}else if(L==="bmpstr"){var q=A.raw();if(q.length%2===1)return A.error("Decoding of string type: bmpstr length mismatch");var j="";for(var x=0;x<q.length/2;x++)j+=String.fromCharCode(q.readUInt16BE(x*2));return j}else if(L==="numstr"){var g=A.raw().toString("ascii");if(!this._isNumstr(g))return A.error("Decoding of string type: numstr unsupported characters");return g}else if(L==="octstr")return A.raw();else if(L==="objDesc")return A.raw();else if(L==="printstr"){var N=A.raw().toString("ascii");if(!this._isPrintstr(N))return A.error("Decoding of string type: printstr unsupported characters");return N}else if(/str$/.test(L))return A.raw().toString();else return A.error("Decoding of string type: "+L+" unsupported")},k.prototype._decodeObjid=function D(A,L,M){var q,j=[],x=0;while(!A.isEmpty()){var g=A.readUInt8();if(x<<=7,x|=g&127,(g&128)===0)j.push(x),x=0}if(g&128)j.push(x);var N=j[0]/40|0,y=j[0]%40;if(M)q=j;else q=[N,y].concat(j.slice(1));if(L){var f=L[q.join(" ")];if(f===void 0)f=L[q.join(".")];if(f!==void 0)q=f}return q},k.prototype._decodeTime=function D(A,L){var M=A.raw().toString();if(L==="gentime")var q=M.slice(0,4)|0,j=M.slice(4,6)|0,x=M.slice(6,8)|0,g=M.slice(8,10)|0,N=M.slice(10,12)|0,y=M.slice(12,14)|0;else if(L==="utctime"){var q=M.slice(0,2)|0,j=M.slice(2,4)|0,x=M.slice(4,6)|0,g=M.slice(6,8)|0,N=M.slice(8,10)|0,y=M.slice(10,12)|0;if(q<70)q=2000+q;else q=1900+q}else return A.error("Decoding "+L+" time is not supported yet");return Date.UTC(q,j-1,x,g,N,y,0)},k.prototype._decodeNull=function D(A){return null},k.prototype._decodeBool=function D(A){var L=A.readUInt8();if(A.isError(L))return L;else return L!==0},k.prototype._decodeInt=function D(A,L){var M=A.raw(),q=new z(M);if(L)q=L[q.toString(10)]||q;return q},k.prototype._use=function D(A,L){if(typeof A==="function")A=A(L);return A._getDecoder("der").tree};function R(D,A){var L=D.readUInt8(A);if(D.isError(L))return L;var M=V.tagClass[L>>6],q=(L&32)===0;if((L&31)===31){var j=L;L=0;while((j&128)===128){if(j=D.readUInt8(A),D.isError(j))return j;L<<=7,L|=j&127}}else L&=31;var x=V.tag[L];return{cls:M,primitive:q,tag:L,tagStr:x}}function S(D,A,L){var M=D.readUInt8(L);if(D.isError(M))return M;if(!A&&M===128)return null;if((M&128)===0)return M;var q=M&127;if(q>4)return D.error("length octect is too long");M=0;for(var j=0;j<q;j++){M<<=8;var x=D.readUInt8(L);if(D.isError(x))return x;M|=x}return M}}),sY=w0((E,G)=>{var W=kU(),C=(HU(),y0(FU)).Buffer,H=jZ();function z(V){H.call(this,V),this.enc="pem"}W(z,H),G.exports=z,z.prototype.decode=function V(P,k){var R=P.toString().split(/[\r\n]+/g),S=k.label.toUpperCase(),D=/^-----(BEGIN|END) ([^-]+)-----$/,A=-1,L=-1;for(var M=0;M<R.length;M++){var q=R[M].match(D);if(q===null)continue;if(q[2]!==S)continue;if(A===-1){if(q[1]!=="BEGIN")break;A=M}else{if(q[1]!=="END")break;L=M;break}}if(A===-1||L===-1)throw new Error("PEM section not found for: "+S);var j=R.slice(A+1,L).join("");j.replace(/[^a-z0-9\+\/=]+/gi,"");var x=new C(j,"base64");return H.prototype.decode.call(this,x,k)}}),mY=w0((E)=>{var G=E;G.der=jZ(),G.pem=sY()}),BZ=w0((E,G)=>{var W=kU(),C=(HU(),y0(FU)).Buffer,H=TX(),z=H.base,V=H.constants.der;function P(D){this.enc="der",this.name=D.name,this.entity=D,this.tree=new k,this.tree._init(D.body)}G.exports=P,P.prototype.encode=function D(A,L){return this.tree._encode(A,L).join()};function k(D){z.Node.call(this,"der",D)}W(k,z.Node),k.prototype._encodeComposite=function D(A,L,M,q){var j=S(A,L,M,this.reporter);if(q.length<128){var N=new C(2);return N[0]=j,N[1]=q.length,this._createEncoderBuffer([N,q])}var x=1;for(var g=q.length;g>=256;g>>=8)x++;var N=new C(2+x);N[0]=j,N[1]=128|x;for(var g=1+x,y=q.length;y>0;g--,y>>=8)N[g]=y&255;return this._createEncoderBuffer([N,q])},k.prototype._encodeStr=function D(A,L){if(L==="bitstr")return this._createEncoderBuffer([A.unused|0,A.data]);else if(L==="bmpstr"){var M=new C(A.length*2);for(var q=0;q<A.length;q++)M.writeUInt16BE(A.charCodeAt(q),q*2);return this._createEncoderBuffer(M)}else if(L==="numstr"){if(!this._isNumstr(A))return this.reporter.error("Encoding of string type: numstr supports only digits and space");return this._createEncoderBuffer(A)}else if(L==="printstr"){if(!this._isPrintstr(A))return this.reporter.error("Encoding of string type: printstr supports only latin upper and lower case letters, digits, space, apostrophe, left and rigth parenthesis, plus sign, comma, hyphen, dot, slash, colon, equal sign, question mark");return this._createEncoderBuffer(A)}else if(/str$/.test(L))return this._createEncoderBuffer(A);else if(L==="objDesc")return this._createEncoderBuffer(A);else return this.reporter.error("Encoding of string type: "+L+" unsupported")},k.prototype._encodeObjid=function D(A,L,M){if(typeof A==="string"){if(!L)return this.reporter.error("string objid given, but no values map found");if(!L.hasOwnProperty(A))return this.reporter.error("objid not found in values map");A=L[A].split(/[\s\.]+/g);for(var q=0;q<A.length;q++)A[q]|=0}else if(Array.isArray(A)){A=A.slice();for(var q=0;q<A.length;q++)A[q]|=0}if(!Array.isArray(A))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(A));if(!M){if(A[1]>=40)return this.reporter.error("Second objid identifier OOB");A.splice(0,2,A[0]*40+A[1])}var j=0;for(var q=0;q<A.length;q++){var x=A[q];for(j++;x>=128;x>>=7)j++}var g=new C(j),N=g.length-1;for(var q=A.length-1;q>=0;q--){var x=A[q];g[N--]=x&127;while((x>>=7)>0)g[N--]=128|x&127}return this._createEncoderBuffer(g)};function R(D){if(D<10)return"0"+D;else return D}k.prototype._encodeTime=function D(A,L){var M,q=new Date(A);if(L==="gentime")M=[R(q.getFullYear()),R(q.getUTCMonth()+1),R(q.getUTCDate()),R(q.getUTCHours()),R(q.getUTCMinutes()),R(q.getUTCSeconds()),"Z"].join("");else if(L==="utctime")M=[R(q.getFullYear()%100),R(q.getUTCMonth()+1),R(q.getUTCDate()),R(q.getUTCHours()),R(q.getUTCMinutes()),R(q.getUTCSeconds()),"Z"].join("");else this.reporter.error("Encoding "+L+" time is not supported yet");return this._encodeStr(M,"octstr")},k.prototype._encodeNull=function D(){return this._createEncoderBuffer("")},k.prototype._encodeInt=function D(A,L){if(typeof A==="string"){if(!L)return this.reporter.error("String int or enum given, but no values map");if(!L.hasOwnProperty(A))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(A));A=L[A]}if(typeof A!=="number"&&!C.isBuffer(A)){var M=A.toArray();if(!A.sign&&M[0]&128)M.unshift(0);A=new C(M)}if(C.isBuffer(A)){var q=A.length;if(A.length===0)q++;var x=new C(q);if(A.copy(x),A.length===0)x[0]=0;return this._createEncoderBuffer(x)}if(A<128)return this._createEncoderBuffer(A);if(A<256)return this._createEncoderBuffer([0,A]);var q=1;for(var j=A;j>=256;j>>=8)q++;var x=new Array(q);for(var j=x.length-1;j>=0;j--)x[j]=A&255,A>>=8;if(x[0]&128)x.unshift(0);return this._createEncoderBuffer(new C(x))},k.prototype._encodeBool=function D(A){return this._createEncoderBuffer(A?255:0)},k.prototype._use=function D(A,L){if(typeof A==="function")A=A(L);return A._getEncoder("der").tree},k.prototype._skipDefault=function D(A,L,M){var q=this._baseState,j;if(q.default===null)return!1;var x=A.join();if(q.defaultBuffer===void 0)q.defaultBuffer=this._encodeValue(q.default,L,M).join();if(x.length!==q.defaultBuffer.length)return!1;for(j=0;j<x.length;j++)if(x[j]!==q.defaultBuffer[j])return!1;return!0};function S(D,A,L,M){var q;if(D==="seqof")D="seq";else if(D==="setof")D="set";if(V.tagByName.hasOwnProperty(D))q=V.tagByName[D];else if(typeof D==="number"&&(D|0)===D)q=D;else return M.error("Unknown tag: "+D);if(q>=31)return M.error("Multi-octet tag encoding unsupported");if(!A)q|=32;return q|=V.tagClassByName[L||"universal"]<<6,q}}),tY=w0((E,G)=>{var W=kU(),C=BZ();function H(z){C.call(this,z),this.enc="pem"}W(H,C),G.exports=H,H.prototype.encode=function z(V,P){var k=C.prototype.encode.call(this,V),R=k.toString("base64"),S=["-----BEGIN "+P.label+"-----"];for(var D=0;D<R.length;D+=64)S.push(R.slice(D,D+64));return S.push("-----END "+P.label+"-----"),S.join(`
14
+ `)}}),rY=w0((E)=>{var G=E;G.der=BZ(),G.pem=tY()}),TX=w0((E)=>{var G=E;G.bignum=lY(),G.define=dY().define,G.base=EX(),G.constants=kZ(),G.decoders=mY(),G.encoders=rY()}),aY=w0((E,G)=>{var W=TX(),C=W.define("Time",function(){this.choice({utcTime:this.utctime(),generalTime:this.gentime()})}),H=W.define("AttributeTypeValue",function(){this.seq().obj(this.key("type").objid(),this.key("value").any())}),z=W.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("parameters").optional(),this.key("curve").objid().optional())}),V=W.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(z),this.key("subjectPublicKey").bitstr())}),P=W.define("RelativeDistinguishedName",function(){this.setof(H)}),k=W.define("RDNSequence",function(){this.seqof(P)}),R=W.define("Name",function(){this.choice({rdnSequence:this.use(k)})}),S=W.define("Validity",function(){this.seq().obj(this.key("notBefore").use(C),this.key("notAfter").use(C))}),D=W.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),A=W.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(z),this.key("issuer").use(R),this.key("validity").use(S),this.key("subject").use(R),this.key("subjectPublicKeyInfo").use(V),this.key("issuerUniqueID").implicit(1).bitstr().optional(),this.key("subjectUniqueID").implicit(2).bitstr().optional(),this.key("extensions").explicit(3).seqof(D).optional())}),L=W.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(A),this.key("signatureAlgorithm").use(z),this.key("signatureValue").bitstr())});G.exports=L}),eY=w0((E)=>{var G=TX();E.certificate=aY();var W=G.define("RSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("modulus").int(),this.key("publicExponent").int(),this.key("privateExponent").int(),this.key("prime1").int(),this.key("prime2").int(),this.key("exponent1").int(),this.key("exponent2").int(),this.key("coefficient").int())});E.RSAPrivateKey=W;var C=G.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});E.RSAPublicKey=C;var H=G.define("AlgorithmIdentifier",function(){this.seq().obj(this.key("algorithm").objid(),this.key("none").null_().optional(),this.key("curve").objid().optional(),this.key("params").seq().obj(this.key("p").int(),this.key("q").int(),this.key("g").int()).optional())}),z=G.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(H),this.key("subjectPublicKey").bitstr())});E.PublicKey=z;var V=G.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(H),this.key("subjectPrivateKey").octstr())});E.PrivateKey=V;var P=G.define("EncryptedPrivateKeyInfo",function(){this.seq().obj(this.key("algorithm").seq().obj(this.key("id").objid(),this.key("decrypt").seq().obj(this.key("kde").seq().obj(this.key("id").objid(),this.key("kdeparams").seq().obj(this.key("salt").octstr(),this.key("iters").int())),this.key("cipher").seq().obj(this.key("algo").objid(),this.key("iv").octstr()))),this.key("subjectPrivateKey").octstr())});E.EncryptedPrivateKey=P;var k=G.define("DSAPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("p").int(),this.key("q").int(),this.key("g").int(),this.key("pub_key").int(),this.key("priv_key").int())});E.DSAPrivateKey=k,E.DSAparam=G.define("DSAparam",function(){this.int()});var R=G.define("ECParameters",function(){this.choice({namedCurve:this.objid()})}),S=G.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(R),this.key("publicKey").optional().explicit(1).bitstr())});E.ECPrivateKey=S,E.signature=G.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})}),iY=w0((E,G)=>{G.exports={"2.16.840.1.101.3.4.1.1":"aes-128-ecb","2.16.840.1.101.3.4.1.2":"aes-128-cbc","2.16.840.1.101.3.4.1.3":"aes-128-ofb","2.16.840.1.101.3.4.1.4":"aes-128-cfb","2.16.840.1.101.3.4.1.21":"aes-192-ecb","2.16.840.1.101.3.4.1.22":"aes-192-cbc","2.16.840.1.101.3.4.1.23":"aes-192-ofb","2.16.840.1.101.3.4.1.24":"aes-192-cfb","2.16.840.1.101.3.4.1.41":"aes-256-ecb","2.16.840.1.101.3.4.1.42":"aes-256-cbc","2.16.840.1.101.3.4.1.43":"aes-256-ofb","2.16.840.1.101.3.4.1.44":"aes-256-cfb"}}),UV=w0((E,G)=>{var W=PU().Buffer,C=(OI(),y0(VI)).Transform,H=kU();function z(R){C.call(this),this._block=W.allocUnsafe(R),this._blockSize=R,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}H(z,C),z.prototype._transform=function(R,S,D){var A=null;try{this.update(R,S)}catch(L){A=L}D(A)},z.prototype._flush=function(R){var S=null;try{this.push(this.digest())}catch(D){S=D}R(S)};var V=typeof Uint8Array!=="undefined",P=typeof ArrayBuffer!=="undefined"&&typeof Uint8Array!=="undefined"&&ArrayBuffer.isView&&(W.prototype instanceof Uint8Array||W.TYPED_ARRAY_SUPPORT);function k(R,S){if(R instanceof W)return R;if(typeof R==="string")return W.from(R,S);if(P&&ArrayBuffer.isView(R)){if(R.byteLength===0)return W.alloc(0);var D=W.from(R.buffer,R.byteOffset,R.byteLength);if(D.byteLength===R.byteLength)return D}if(V&&R instanceof Uint8Array)return W.from(R);if(W.isBuffer(R)&&R.constructor&&typeof R.constructor.isBuffer==="function"&&R.constructor.isBuffer(R))return W.from(R);throw new TypeError('The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView.')}z.prototype.update=function(R,S){if(this._finalized)throw new Error("Digest already called");R=k(R,S);var D=this._block,A=0;while(this._blockOffset+R.length-A>=this._blockSize){for(var L=this._blockOffset;L<this._blockSize;)D[L++]=R[A++];this._update(),this._blockOffset=0}while(A<R.length)D[this._blockOffset++]=R[A++];for(var M=0,q=R.length*8;q>0;++M)if(this._length[M]+=q,q=this._length[M]/4294967296|0,q>0)this._length[M]-=4294967296*q;return this},z.prototype._update=function(){throw new Error("_update is not implemented")},z.prototype.digest=function(R){if(this._finalized)throw new Error("Digest already called");this._finalized=!0;var S=this._digest();if(R!==void 0)S=S.toString(R);this._block.fill(0),this._blockOffset=0;for(var D=0;D<4;++D)this._length[D]=0;return S},z.prototype._digest=function(){throw new Error("_digest is not implemented")},G.exports=z}),XV=w0((E,G)=>{var W=kU(),C=UV(),H=PU().Buffer,z=new Array(16);function V(){C.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}W(V,C),V.prototype._update=function(){var A=z;for(var L=0;L<16;++L)A[L]=this._block.readInt32LE(L*4);var M=this._a,q=this._b,j=this._c,x=this._d;M=k(M,q,j,x,A[0],3614090360,7),x=k(x,M,q,j,A[1],3905402710,12),j=k(j,x,M,q,A[2],606105819,17),q=k(q,j,x,M,A[3],3250441966,22),M=k(M,q,j,x,A[4],4118548399,7),x=k(x,M,q,j,A[5],1200080426,12),j=k(j,x,M,q,A[6],2821735955,17),q=k(q,j,x,M,A[7],4249261313,22),M=k(M,q,j,x,A[8],1770035416,7),x=k(x,M,q,j,A[9],2336552879,12),j=k(j,x,M,q,A[10],4294925233,17),q=k(q,j,x,M,A[11],2304563134,22),M=k(M,q,j,x,A[12],1804603682,7),x=k(x,M,q,j,A[13],4254626195,12),j=k(j,x,M,q,A[14],2792965006,17),q=k(q,j,x,M,A[15],1236535329,22),M=R(M,q,j,x,A[1],4129170786,5),x=R(x,M,q,j,A[6],3225465664,9),j=R(j,x,M,q,A[11],643717713,14),q=R(q,j,x,M,A[0],3921069994,20),M=R(M,q,j,x,A[5],3593408605,5),x=R(x,M,q,j,A[10],38016083,9),j=R(j,x,M,q,A[15],3634488961,14),q=R(q,j,x,M,A[4],3889429448,20),M=R(M,q,j,x,A[9],568446438,5),x=R(x,M,q,j,A[14],3275163606,9),j=R(j,x,M,q,A[3],4107603335,14),q=R(q,j,x,M,A[8],1163531501,20),M=R(M,q,j,x,A[13],2850285829,5),x=R(x,M,q,j,A[2],4243563512,9),j=R(j,x,M,q,A[7],1735328473,14),q=R(q,j,x,M,A[12],2368359562,20),M=S(M,q,j,x,A[5],4294588738,4),x=S(x,M,q,j,A[8],2272392833,11),j=S(j,x,M,q,A[11],1839030562,16),q=S(q,j,x,M,A[14],4259657740,23),M=S(M,q,j,x,A[1],2763975236,4),x=S(x,M,q,j,A[4],1272893353,11),j=S(j,x,M,q,A[7],4139469664,16),q=S(q,j,x,M,A[10],3200236656,23),M=S(M,q,j,x,A[13],681279174,4),x=S(x,M,q,j,A[0],3936430074,11),j=S(j,x,M,q,A[3],3572445317,16),q=S(q,j,x,M,A[6],76029189,23),M=S(M,q,j,x,A[9],3654602809,4),x=S(x,M,q,j,A[12],3873151461,11),j=S(j,x,M,q,A[15],530742520,16),q=S(q,j,x,M,A[2],3299628645,23),M=D(M,q,j,x,A[0],4096336452,6),x=D(x,M,q,j,A[7],1126891415,10),j=D(j,x,M,q,A[14],2878612391,15),q=D(q,j,x,M,A[5],4237533241,21),M=D(M,q,j,x,A[12],1700485571,6),x=D(x,M,q,j,A[3],2399980690,10),j=D(j,x,M,q,A[10],4293915773,15),q=D(q,j,x,M,A[1],2240044497,21),M=D(M,q,j,x,A[8],1873313359,6),x=D(x,M,q,j,A[15],4264355552,10),j=D(j,x,M,q,A[6],2734768916,15),q=D(q,j,x,M,A[13],1309151649,21),M=D(M,q,j,x,A[4],4149444226,6),x=D(x,M,q,j,A[11],3174756917,10),j=D(j,x,M,q,A[2],718787259,15),q=D(q,j,x,M,A[9],3951481745,21),this._a=this._a+M|0,this._b=this._b+q|0,this._c=this._c+j|0,this._d=this._d+x|0},V.prototype._digest=function(){if(this._block[this._blockOffset++]=128,this._blockOffset>56)this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0;this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var A=H.allocUnsafe(16);return A.writeInt32LE(this._a,0),A.writeInt32LE(this._b,4),A.writeInt32LE(this._c,8),A.writeInt32LE(this._d,12),A};function P(A,L){return A<<L|A>>>32-L}function k(A,L,M,q,j,x,g){return P(A+(L&M|~L&q)+j+x|0,g)+L|0}function R(A,L,M,q,j,x,g){return P(A+(L&q|M&~q)+j+x|0,g)+L|0}function S(A,L,M,q,j,x,g){return P(A+(L^M^q)+j+x|0,g)+L|0}function D(A,L,M,q,j,x,g){return P(A+(M^(L|~q))+j+x|0,g)+L|0}G.exports=V}),IV=w0((E,G)=>{var W=PU().Buffer,C=XV();function H(z,V,P,k){if(!W.isBuffer(z))z=W.from(z,"binary");if(V){if(!W.isBuffer(V))V=W.from(V,"binary");if(V.length!==8)throw new RangeError("salt should be Buffer with 8 byte length")}var R=P/8,S=W.alloc(R),D=W.alloc(k||0),A=W.alloc(0);while(R>0||k>0){var L=new C;if(L.update(A),L.update(z),V)L.update(V);A=L.digest();var M=0;if(R>0){var q=S.length-R;M=Math.min(R,A.length),A.copy(S,q,0,M),R-=M}if(M<A.length&&k>0){var j=D.length-k,x=Math.min(k,A.length-M);A.copy(D,j,M,M+x),k-=x}}return A.fill(0),{key:S,iv:D}}G.exports=H}),xZ=w0((E)=>{var G=(vU(),y0(qU));E.createCipher=E.Cipher=G.createCipher,E.createCipheriv=E.Cipheriv=G.createCipheriv,E.createDecipher=E.Decipher=G.createDecipher,E.createDecipheriv=E.Decipheriv=G.createDecipheriv,E.listCiphers=E.getCiphers=G.getCiphers}),ZV=w0((E,G)=>{var W=/Proc-Type: 4,ENCRYPTED[\n\r]+DEK-Info: AES-((?:128)|(?:192)|(?:256))-CBC,([0-9A-H]+)[\n\r]+([0-9A-z\n\r+/=]+)[\n\r]+/m,C=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,H=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,z=IV(),V=xZ(),P=PU().Buffer;G.exports=function(k,R){var S=k.toString(),D=S.match(W),A;if(!D){var L=S.match(H);A=P.from(L[2].replace(/[\r\n]/g,""),"base64")}else{var M="aes"+D[1],q=P.from(D[2],"hex"),j=P.from(D[3].replace(/[\r\n]/g,""),"base64"),x=z(R,q.slice(0,8),parseInt(D[1],10)).key,g=[],N=V.createDecipheriv(M,x,q);g.push(N.update(j)),g.push(N.final()),A=P.concat(g)}var y=S.match(C)[1];return{tag:y,data:A}}}),gZ=w0((E,G)=>{var W=eY(),C=iY(),H=ZV(),z=xZ(),V=zZ(),P=PU().Buffer;function k(S,D){var A=S.algorithm.decrypt.kde.kdeparams.salt,L=parseInt(S.algorithm.decrypt.kde.kdeparams.iters.toString(),10),M=C[S.algorithm.decrypt.cipher.algo.join(".")],q=S.algorithm.decrypt.cipher.iv,j=S.subjectPrivateKey,x=parseInt(M.split("-")[1],10)/8,g=V.pbkdf2Sync(D,A,L,x,"sha1"),N=z.createDecipheriv(M,g,q),y=[];return y.push(N.update(j)),y.push(N.final()),P.concat(y)}function R(S){var D;if(typeof S==="object"&&!P.isBuffer(S))D=S.passphrase,S=S.key;if(typeof S==="string")S=P.from(S);var A=H(S,D),L=A.tag,M=A.data,q,j;switch(L){case"CERTIFICATE":j=W.certificate.decode(M,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":if(!j)j=W.PublicKey.decode(M,"der");switch(q=j.algorithm.algorithm.join("."),q){case"1.2.840.113549.1.1.1":return W.RSAPublicKey.decode(j.subjectPublicKey.data,"der");case"1.2.840.10045.2.1":return j.subjectPrivateKey=j.subjectPublicKey,{type:"ec",data:j};case"1.2.840.10040.4.1":return j.algorithm.params.pub_key=W.DSAparam.decode(j.subjectPublicKey.data,"der"),{type:"dsa",data:j.algorithm.params};default:throw new Error("unknown key id "+q)}case"ENCRYPTED PRIVATE KEY":M=W.EncryptedPrivateKey.decode(M,"der"),M=k(M,D);case"PRIVATE KEY":switch(j=W.PrivateKey.decode(M,"der"),q=j.algorithm.algorithm.join("."),q){case"1.2.840.113549.1.1.1":return W.RSAPrivateKey.decode(j.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:j.algorithm.curve,privateKey:W.ECPrivateKey.decode(j.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return j.algorithm.params.priv_key=W.DSAparam.decode(j.subjectPrivateKey,"der"),{type:"dsa",params:j.algorithm.params};default:throw new Error("unknown key id "+q)}case"RSA PUBLIC KEY":return W.RSAPublicKey.decode(M,"der");case"RSA PRIVATE KEY":return W.RSAPrivateKey.decode(M,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:W.DSAPrivateKey.decode(M,"der")};case"EC PRIVATE KEY":return M=W.ECPrivateKey.decode(M,"der"),{curve:M.parameters.value,privateKey:M.privateKey};default:throw new Error("unknown key type "+L)}}R.signature=W.signature,G.exports=R}),NZ=w0((E,G)=>{var W=NX(),C=PU().Buffer;G.exports=function(z,V){var P=C.alloc(0),k=0,R;while(P.length<V)R=H(k++),P=C.concat([P,W("sha1").update(z).update(R).digest()]);return P.slice(0,V)};function H(z){var V=C.allocUnsafe(4);return V.writeUInt32BE(z,0),V}}),_Z=w0((E,G)=>{G.exports=function W(C,H){var z=C.length,V=-1;while(++V<z)C[V]^=H[V];return C}}),AI=w0((E,G)=>{(function(W,C){function H(F,U){if(!F)throw new Error(U||"Assertion failed")}function z(F,U){F.super_=U;var Z=function(){};Z.prototype=U.prototype,F.prototype=new Z,F.prototype.constructor=F}function V(F,U,Z){if(V.isBN(F))return F;if(this.negative=0,this.words=null,this.length=0,this.red=null,F!==null){if(U==="le"||U==="be")Z=U,U=10;this._init(F||0,U||10,Z||"be")}}if(typeof W==="object")W.exports=V;else C.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window!=="undefined"&&typeof window.Buffer!=="undefined")P=window.Buffer;else P=(HU(),y0(FU)).Buffer}catch(F){}V.isBN=function F(U){if(U instanceof V)return!0;return U!==null&&typeof U==="object"&&U.constructor.wordSize===V.wordSize&&Array.isArray(U.words)},V.max=function F(U,Z){if(U.cmp(Z)>0)return U;return Z},V.min=function F(U,Z){if(U.cmp(Z)<0)return U;return Z},V.prototype._init=function F(U,Z,Q){if(typeof U==="number")return this._initNumber(U,Z,Q);if(typeof U==="object")return this._initArray(U,Z,Q);if(Z==="hex")Z=16;H(Z===(Z|0)&&Z>=2&&Z<=36),U=U.toString().replace(/\s+/g,"");var I=0;if(U[0]==="-")I++,this.negative=1;if(I<U.length){if(Z===16)this._parseHex(U,I,Q);else if(this._parseBase(U,Z,I),Q==="le")this._initArray(this.toArray(),Z,Q)}},V.prototype._initNumber=function F(U,Z,Q){if(U<0)this.negative=1,U=-U;if(U<67108864)this.words=[U&67108863],this.length=1;else if(U<4503599627370496)this.words=[U&67108863,U/67108864&67108863],this.length=2;else H(U<9007199254740992),this.words=[U&67108863,U/67108864&67108863,1],this.length=3;if(Q!=="le")return;this._initArray(this.toArray(),Z,Q)},V.prototype._initArray=function F(U,Z,Q){if(H(typeof U.length==="number"),U.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(U.length/3),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $,K,J=0;if(Q==="be"){for(I=U.length-1,$=0;I>=0;I-=3)if(K=U[I]|U[I-1]<<8|U[I-2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}else if(Q==="le"){for(I=0,$=0;I<U.length;I+=3)if(K=U[I]|U[I+1]<<8|U[I+2]<<16,this.words[$]|=K<<J&67108863,this.words[$+1]=K>>>26-J&67108863,J+=24,J>=26)J-=26,$++}return this.strip()};function k(F,U){var Z=F.charCodeAt(U);if(Z>=65&&Z<=70)return Z-55;else if(Z>=97&&Z<=102)return Z-87;else return Z-48&15}function R(F,U,Z){var Q=k(F,Z);if(Z-1>=U)Q|=k(F,Z-1)<<4;return Q}V.prototype._parseHex=function F(U,Z,Q){this.length=Math.ceil((U.length-Z)/6),this.words=new Array(this.length);for(var I=0;I<this.length;I++)this.words[I]=0;var $=0,K=0,J;if(Q==="be")for(I=U.length-1;I>=Z;I-=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8;else{var Y=U.length-Z;for(I=Y%2===0?Z+1:Z;I<U.length;I+=2)if(J=R(U,Z,I)<<$,this.words[K]|=J&67108863,$>=18)$-=18,K+=1,this.words[K]|=J>>>26;else $+=8}this.strip()};function S(F,U,Z,Q){var I=0,$=Math.min(F.length,Z);for(var K=U;K<$;K++){var J=F.charCodeAt(K)-48;if(I*=Q,J>=49)I+=J-49+10;else if(J>=17)I+=J-17+10;else I+=J}return I}V.prototype._parseBase=function F(U,Z,Q){this.words=[0],this.length=1;for(var I=0,$=1;$<=67108863;$*=Z)I++;I--,$=$/Z|0;var K=U.length-Q,J=K%I,Y=Math.min(K,K-J)+Q,X=0;for(var O=Q;O<Y;O+=I)if(X=S(U,O,O+I,Z),this.imuln($),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(J!==0){var v=1;X=S(U,O,U.length,Z);for(O=0;O<J;O++)v*=Z;if(this.imuln(v),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function F(U){U.words=new Array(this.length);for(var Z=0;Z<this.length;Z++)U.words[Z]=this.words[Z];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function F(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function F(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function F(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function F(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function F(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var D=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],A=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],L=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];if(V.prototype.toString=function F(U,Z){U=U||10,Z=Z|0||1;var Q;if(U===16||U==="hex"){Q="";var I=0,$=0;for(var K=0;K<this.length;K++){var J=this.words[K],Y=((J<<I|$)&16777215).toString(16);if($=J>>>24-I&16777215,I+=2,I>=26)I-=26,K--;if($!==0||K!==this.length-1)Q=D[6-Y.length]+Y+Q;else Q=Y+Q}if($!==0)Q=$.toString(16)+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}if(U===(U|0)&&U>=2&&U<=36){var X=A[U],O=L[U];Q="";var v=this.clone();v.negative=0;while(!v.isZero()){var T=v.modn(O).toString(U);if(v=v.idivn(O),!v.isZero())Q=D[X-T.length]+T+Q;else Q=T+Q}if(this.isZero())Q="0"+Q;while(Q.length%Z!==0)Q="0"+Q;if(this.negative!==0)Q="-"+Q;return Q}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function F(){var U=this.words[0];if(this.length===2)U+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)U+=4503599627370496+this.words[1]*67108864;else if(this.length>2)H(!1,"Number can only safely store up to 53 bits");return this.negative!==0?-U:U},V.prototype.toJSON=function F(){return this.toString(16)},V.prototype.toBuffer=function F(U,Z){return H(typeof P!=="undefined"),this.toArrayLike(P,U,Z)},V.prototype.toArray=function F(U,Z){return this.toArrayLike(Array,U,Z)},V.prototype.toArrayLike=function F(U,Z,Q){var I=this.byteLength(),$=Q||Math.max(1,I);H(I<=$,"byte array longer than desired length"),H($>0,"Requested array length <= 0"),this.strip();var K=Z==="le",J=new U($),Y,X,O=this.clone();if(!K){for(X=0;X<$-I;X++)J[X]=0;for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[$-X-1]=Y}else{for(X=0;!O.isZero();X++)Y=O.andln(255),O.iushrn(8),J[X]=Y;for(;X<$;X++)J[X]=0}return J},Math.clz32)V.prototype._countBits=function F(U){return 32-Math.clz32(U)};else V.prototype._countBits=function F(U){var Z=U,Q=0;if(Z>=4096)Q+=13,Z>>>=13;if(Z>=64)Q+=7,Z>>>=7;if(Z>=8)Q+=4,Z>>>=4;if(Z>=2)Q+=2,Z>>>=2;return Q+Z};V.prototype._zeroBits=function F(U){if(U===0)return 26;var Z=U,Q=0;if((Z&8191)===0)Q+=13,Z>>>=13;if((Z&127)===0)Q+=7,Z>>>=7;if((Z&15)===0)Q+=4,Z>>>=4;if((Z&3)===0)Q+=2,Z>>>=2;if((Z&1)===0)Q++;return Q},V.prototype.bitLength=function F(){var U=this.words[this.length-1],Z=this._countBits(U);return(this.length-1)*26+Z};function M(F){var U=new Array(F.bitLength());for(var Z=0;Z<U.length;Z++){var Q=Z/26|0,I=Z%26;U[Z]=(F.words[Q]&1<<I)>>>I}return U}V.prototype.zeroBits=function F(){if(this.isZero())return 0;var U=0;for(var Z=0;Z<this.length;Z++){var Q=this._zeroBits(this.words[Z]);if(U+=Q,Q!==26)break}return U},V.prototype.byteLength=function F(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function F(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function F(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function F(){return this.negative!==0},V.prototype.neg=function F(){return this.clone().ineg()},V.prototype.ineg=function F(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function F(U){while(this.length<U.length)this.words[this.length++]=0;for(var Z=0;Z<U.length;Z++)this.words[Z]=this.words[Z]|U.words[Z];return this.strip()},V.prototype.ior=function F(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function F(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function F(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function F(U){var Z;if(this.length>U.length)Z=U;else Z=this;for(var Q=0;Q<Z.length;Q++)this.words[Q]=this.words[Q]&U.words[Q];return this.length=Z.length,this.strip()},V.prototype.iand=function F(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function F(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function F(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function F(U){var Z,Q;if(this.length>U.length)Z=this,Q=U;else Z=U,Q=this;for(var I=0;I<Q.length;I++)this.words[I]=Z.words[I]^Q.words[I];if(this!==Z)for(;I<Z.length;I++)this.words[I]=Z.words[I];return this.length=Z.length,this.strip()},V.prototype.ixor=function F(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function F(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function F(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function F(U){H(typeof U==="number"&&U>=0);var Z=Math.ceil(U/26)|0,Q=U%26;if(this._expand(Z),Q>0)Z--;for(var I=0;I<Z;I++)this.words[I]=~this.words[I]&67108863;if(Q>0)this.words[I]=~this.words[I]&67108863>>26-Q;return this.strip()},V.prototype.notn=function F(U){return this.clone().inotn(U)},V.prototype.setn=function F(U,Z){H(typeof U==="number"&&U>=0);var Q=U/26|0,I=U%26;if(this._expand(Q+1),Z)this.words[Q]=this.words[Q]|1<<I;else this.words[Q]=this.words[Q]&~(1<<I);return this.strip()},V.prototype.iadd=function F(U){var Z;if(this.negative!==0&&U.negative===0)return this.negative=0,Z=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Z=this.isub(U),U.negative=1,Z._normSign();var Q,I;if(this.length>U.length)Q=this,I=U;else Q=U,I=this;var $=0;for(var K=0;K<I.length;K++)Z=(Q.words[K]|0)+(I.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;for(;$!==0&&K<Q.length;K++)Z=(Q.words[K]|0)+$,this.words[K]=Z&67108863,$=Z>>>26;if(this.length=Q.length,$!==0)this.words[this.length]=$,this.length++;else if(Q!==this)for(;K<Q.length;K++)this.words[K]=Q.words[K];return this},V.prototype.add=function F(U){var Z;if(U.negative!==0&&this.negative===0)return U.negative=0,Z=this.sub(U),U.negative^=1,Z;else if(U.negative===0&&this.negative!==0)return this.negative=0,Z=U.sub(this),this.negative=1,Z;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function F(U){if(U.negative!==0){U.negative=0;var Z=this.iadd(U);return U.negative=1,Z._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var Q=this.cmp(U);if(Q===0)return this.negative=0,this.length=1,this.words[0]=0,this;var I,$;if(Q>0)I=this,$=U;else I=U,$=this;var K=0;for(var J=0;J<$.length;J++)Z=(I.words[J]|0)-($.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;for(;K!==0&&J<I.length;J++)Z=(I.words[J]|0)+K,K=Z>>26,this.words[J]=Z&67108863;if(K===0&&J<I.length&&I!==this)for(;J<I.length;J++)this.words[J]=I.words[J];if(this.length=Math.max(this.length,J),I!==this)this.negative=1;return this.strip()},V.prototype.sub=function F(U){return this.clone().isub(U)};function q(F,U,Z){Z.negative=U.negative^F.negative;var Q=F.length+U.length|0;Z.length=Q,Q=Q-1|0;var I=F.words[0]|0,$=U.words[0]|0,K=I*$,J=K&67108863,Y=K/67108864|0;Z.words[0]=J;for(var X=1;X<Q;X++){var O=Y>>>26,v=Y&67108863,T=Math.min(X,U.length-1);for(var B=Math.max(0,X-F.length+1);B<=T;B++){var c=X-B|0;I=F.words[c]|0,$=U.words[B]|0,K=I*$+v,O+=K/67108864|0,v=K&67108863}Z.words[X]=v|0,Y=O|0}if(Y!==0)Z.words[X]=Y|0;else Z.length--;return Z.strip()}var j=function F(U,Z,Q){var I=U.words,$=Z.words,K=Q.words,J=0,Y,X,O,v=I[0]|0,T=v&8191,B=v>>>13,c=I[1]|0,l=c&8191,s=c>>>13,O0=I[2]|0,h=O0&8191,d=O0>>>13,g0=I[3]|0,Q0=g0&8191,$0=g0>>>13,m=I[4]|0,p=m&8191,b=m>>>13,N0=I[5]|0,i=N0&8191,e=N0>>>13,t=I[6]|0,n=t&8191,X0=t>>>13,H0=I[7]|0,Z0=H0&8191,W0=H0>>>13,c0=I[8]|0,G0=c0&8191,A0=c0>>>13,u0=I[9]|0,J0=u0&8191,T0=u0>>>13,r0=$[0]|0,E0=r0&8191,v0=r0>>>13,AU=$[1]|0,k0=AU&8191,j0=AU>>>13,DU=$[2]|0,R0=DU&8191,S0=DU>>>13,LU=$[3]|0,P0=LU&8191,D0=LU>>>13,zU=$[4]|0,B0=zU&8191,L0=zU>>>13,EU=$[5]|0,_=EU&8191,w=EU>>>13,_0=$[6]|0,U0=_0&8191,I0=_0>>>13,l0=$[7]|0,F0=l0&8191,C0=l0>>>13,CU=$[8]|0,x0=CU&8191,q0=CU>>>13,TU=$[9]|0,z0=TU&8191,M0=TU>>>13;Q.negative=U.negative^Z.negative,Q.length=19,Y=Math.imul(T,E0),X=Math.imul(T,v0),X=X+Math.imul(B,E0)|0,O=Math.imul(B,v0);var t0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(t0>>>26)|0,t0&=67108863,Y=Math.imul(l,E0),X=Math.imul(l,v0),X=X+Math.imul(s,E0)|0,O=Math.imul(s,v0),Y=Y+Math.imul(T,k0)|0,X=X+Math.imul(T,j0)|0,X=X+Math.imul(B,k0)|0,O=O+Math.imul(B,j0)|0;var p0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(p0>>>26)|0,p0&=67108863,Y=Math.imul(h,E0),X=Math.imul(h,v0),X=X+Math.imul(d,E0)|0,O=Math.imul(d,v0),Y=Y+Math.imul(l,k0)|0,X=X+Math.imul(l,j0)|0,X=X+Math.imul(s,k0)|0,O=O+Math.imul(s,j0)|0,Y=Y+Math.imul(T,R0)|0,X=X+Math.imul(T,S0)|0,X=X+Math.imul(B,R0)|0,O=O+Math.imul(B,S0)|0;var f0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(f0>>>26)|0,f0&=67108863,Y=Math.imul(Q0,E0),X=Math.imul(Q0,v0),X=X+Math.imul($0,E0)|0,O=Math.imul($0,v0),Y=Y+Math.imul(h,k0)|0,X=X+Math.imul(h,j0)|0,X=X+Math.imul(d,k0)|0,O=O+Math.imul(d,j0)|0,Y=Y+Math.imul(l,R0)|0,X=X+Math.imul(l,S0)|0,X=X+Math.imul(s,R0)|0,O=O+Math.imul(s,S0)|0,Y=Y+Math.imul(T,P0)|0,X=X+Math.imul(T,D0)|0,X=X+Math.imul(B,P0)|0,O=O+Math.imul(B,D0)|0;var b0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,Y=Math.imul(p,E0),X=Math.imul(p,v0),X=X+Math.imul(b,E0)|0,O=Math.imul(b,v0),Y=Y+Math.imul(Q0,k0)|0,X=X+Math.imul(Q0,j0)|0,X=X+Math.imul($0,k0)|0,O=O+Math.imul($0,j0)|0,Y=Y+Math.imul(h,R0)|0,X=X+Math.imul(h,S0)|0,X=X+Math.imul(d,R0)|0,O=O+Math.imul(d,S0)|0,Y=Y+Math.imul(l,P0)|0,X=X+Math.imul(l,D0)|0,X=X+Math.imul(s,P0)|0,O=O+Math.imul(s,D0)|0,Y=Y+Math.imul(T,B0)|0,X=X+Math.imul(T,L0)|0,X=X+Math.imul(B,B0)|0,O=O+Math.imul(B,L0)|0;var a0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,Y=Math.imul(i,E0),X=Math.imul(i,v0),X=X+Math.imul(e,E0)|0,O=Math.imul(e,v0),Y=Y+Math.imul(p,k0)|0,X=X+Math.imul(p,j0)|0,X=X+Math.imul(b,k0)|0,O=O+Math.imul(b,j0)|0,Y=Y+Math.imul(Q0,R0)|0,X=X+Math.imul(Q0,S0)|0,X=X+Math.imul($0,R0)|0,O=O+Math.imul($0,S0)|0,Y=Y+Math.imul(h,P0)|0,X=X+Math.imul(h,D0)|0,X=X+Math.imul(d,P0)|0,O=O+Math.imul(d,D0)|0,Y=Y+Math.imul(l,B0)|0,X=X+Math.imul(l,L0)|0,X=X+Math.imul(s,B0)|0,O=O+Math.imul(s,L0)|0,Y=Y+Math.imul(T,_)|0,X=X+Math.imul(T,w)|0,X=X+Math.imul(B,_)|0,O=O+Math.imul(B,w)|0;var e0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,Y=Math.imul(n,E0),X=Math.imul(n,v0),X=X+Math.imul(X0,E0)|0,O=Math.imul(X0,v0),Y=Y+Math.imul(i,k0)|0,X=X+Math.imul(i,j0)|0,X=X+Math.imul(e,k0)|0,O=O+Math.imul(e,j0)|0,Y=Y+Math.imul(p,R0)|0,X=X+Math.imul(p,S0)|0,X=X+Math.imul(b,R0)|0,O=O+Math.imul(b,S0)|0,Y=Y+Math.imul(Q0,P0)|0,X=X+Math.imul(Q0,D0)|0,X=X+Math.imul($0,P0)|0,O=O+Math.imul($0,D0)|0,Y=Y+Math.imul(h,B0)|0,X=X+Math.imul(h,L0)|0,X=X+Math.imul(d,B0)|0,O=O+Math.imul(d,L0)|0,Y=Y+Math.imul(l,_)|0,X=X+Math.imul(l,w)|0,X=X+Math.imul(s,_)|0,O=O+Math.imul(s,w)|0,Y=Y+Math.imul(T,U0)|0,X=X+Math.imul(T,I0)|0,X=X+Math.imul(B,U0)|0,O=O+Math.imul(B,I0)|0;var i0=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,Y=Math.imul(Z0,E0),X=Math.imul(Z0,v0),X=X+Math.imul(W0,E0)|0,O=Math.imul(W0,v0),Y=Y+Math.imul(n,k0)|0,X=X+Math.imul(n,j0)|0,X=X+Math.imul(X0,k0)|0,O=O+Math.imul(X0,j0)|0,Y=Y+Math.imul(i,R0)|0,X=X+Math.imul(i,S0)|0,X=X+Math.imul(e,R0)|0,O=O+Math.imul(e,S0)|0,Y=Y+Math.imul(p,P0)|0,X=X+Math.imul(p,D0)|0,X=X+Math.imul(b,P0)|0,O=O+Math.imul(b,D0)|0,Y=Y+Math.imul(Q0,B0)|0,X=X+Math.imul(Q0,L0)|0,X=X+Math.imul($0,B0)|0,O=O+Math.imul($0,L0)|0,Y=Y+Math.imul(h,_)|0,X=X+Math.imul(h,w)|0,X=X+Math.imul(d,_)|0,O=O+Math.imul(d,w)|0,Y=Y+Math.imul(l,U0)|0,X=X+Math.imul(l,I0)|0,X=X+Math.imul(s,U0)|0,O=O+Math.imul(s,I0)|0,Y=Y+Math.imul(T,F0)|0,X=X+Math.imul(T,C0)|0,X=X+Math.imul(B,F0)|0,O=O+Math.imul(B,C0)|0;var UU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,Y=Math.imul(G0,E0),X=Math.imul(G0,v0),X=X+Math.imul(A0,E0)|0,O=Math.imul(A0,v0),Y=Y+Math.imul(Z0,k0)|0,X=X+Math.imul(Z0,j0)|0,X=X+Math.imul(W0,k0)|0,O=O+Math.imul(W0,j0)|0,Y=Y+Math.imul(n,R0)|0,X=X+Math.imul(n,S0)|0,X=X+Math.imul(X0,R0)|0,O=O+Math.imul(X0,S0)|0,Y=Y+Math.imul(i,P0)|0,X=X+Math.imul(i,D0)|0,X=X+Math.imul(e,P0)|0,O=O+Math.imul(e,D0)|0,Y=Y+Math.imul(p,B0)|0,X=X+Math.imul(p,L0)|0,X=X+Math.imul(b,B0)|0,O=O+Math.imul(b,L0)|0,Y=Y+Math.imul(Q0,_)|0,X=X+Math.imul(Q0,w)|0,X=X+Math.imul($0,_)|0,O=O+Math.imul($0,w)|0,Y=Y+Math.imul(h,U0)|0,X=X+Math.imul(h,I0)|0,X=X+Math.imul(d,U0)|0,O=O+Math.imul(d,I0)|0,Y=Y+Math.imul(l,F0)|0,X=X+Math.imul(l,C0)|0,X=X+Math.imul(s,F0)|0,O=O+Math.imul(s,C0)|0,Y=Y+Math.imul(T,x0)|0,X=X+Math.imul(T,q0)|0,X=X+Math.imul(B,x0)|0,O=O+Math.imul(B,q0)|0;var XU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,Y=Math.imul(J0,E0),X=Math.imul(J0,v0),X=X+Math.imul(T0,E0)|0,O=Math.imul(T0,v0),Y=Y+Math.imul(G0,k0)|0,X=X+Math.imul(G0,j0)|0,X=X+Math.imul(A0,k0)|0,O=O+Math.imul(A0,j0)|0,Y=Y+Math.imul(Z0,R0)|0,X=X+Math.imul(Z0,S0)|0,X=X+Math.imul(W0,R0)|0,O=O+Math.imul(W0,S0)|0,Y=Y+Math.imul(n,P0)|0,X=X+Math.imul(n,D0)|0,X=X+Math.imul(X0,P0)|0,O=O+Math.imul(X0,D0)|0,Y=Y+Math.imul(i,B0)|0,X=X+Math.imul(i,L0)|0,X=X+Math.imul(e,B0)|0,O=O+Math.imul(e,L0)|0,Y=Y+Math.imul(p,_)|0,X=X+Math.imul(p,w)|0,X=X+Math.imul(b,_)|0,O=O+Math.imul(b,w)|0,Y=Y+Math.imul(Q0,U0)|0,X=X+Math.imul(Q0,I0)|0,X=X+Math.imul($0,U0)|0,O=O+Math.imul($0,I0)|0,Y=Y+Math.imul(h,F0)|0,X=X+Math.imul(h,C0)|0,X=X+Math.imul(d,F0)|0,O=O+Math.imul(d,C0)|0,Y=Y+Math.imul(l,x0)|0,X=X+Math.imul(l,q0)|0,X=X+Math.imul(s,x0)|0,O=O+Math.imul(s,q0)|0,Y=Y+Math.imul(T,z0)|0,X=X+Math.imul(T,M0)|0,X=X+Math.imul(B,z0)|0,O=O+Math.imul(B,M0)|0;var IU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,Y=Math.imul(J0,k0),X=Math.imul(J0,j0),X=X+Math.imul(T0,k0)|0,O=Math.imul(T0,j0),Y=Y+Math.imul(G0,R0)|0,X=X+Math.imul(G0,S0)|0,X=X+Math.imul(A0,R0)|0,O=O+Math.imul(A0,S0)|0,Y=Y+Math.imul(Z0,P0)|0,X=X+Math.imul(Z0,D0)|0,X=X+Math.imul(W0,P0)|0,O=O+Math.imul(W0,D0)|0,Y=Y+Math.imul(n,B0)|0,X=X+Math.imul(n,L0)|0,X=X+Math.imul(X0,B0)|0,O=O+Math.imul(X0,L0)|0,Y=Y+Math.imul(i,_)|0,X=X+Math.imul(i,w)|0,X=X+Math.imul(e,_)|0,O=O+Math.imul(e,w)|0,Y=Y+Math.imul(p,U0)|0,X=X+Math.imul(p,I0)|0,X=X+Math.imul(b,U0)|0,O=O+Math.imul(b,I0)|0,Y=Y+Math.imul(Q0,F0)|0,X=X+Math.imul(Q0,C0)|0,X=X+Math.imul($0,F0)|0,O=O+Math.imul($0,C0)|0,Y=Y+Math.imul(h,x0)|0,X=X+Math.imul(h,q0)|0,X=X+Math.imul(d,x0)|0,O=O+Math.imul(d,q0)|0,Y=Y+Math.imul(l,z0)|0,X=X+Math.imul(l,M0)|0,X=X+Math.imul(s,z0)|0,O=O+Math.imul(s,M0)|0;var ZU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,Y=Math.imul(J0,R0),X=Math.imul(J0,S0),X=X+Math.imul(T0,R0)|0,O=Math.imul(T0,S0),Y=Y+Math.imul(G0,P0)|0,X=X+Math.imul(G0,D0)|0,X=X+Math.imul(A0,P0)|0,O=O+Math.imul(A0,D0)|0,Y=Y+Math.imul(Z0,B0)|0,X=X+Math.imul(Z0,L0)|0,X=X+Math.imul(W0,B0)|0,O=O+Math.imul(W0,L0)|0,Y=Y+Math.imul(n,_)|0,X=X+Math.imul(n,w)|0,X=X+Math.imul(X0,_)|0,O=O+Math.imul(X0,w)|0,Y=Y+Math.imul(i,U0)|0,X=X+Math.imul(i,I0)|0,X=X+Math.imul(e,U0)|0,O=O+Math.imul(e,I0)|0,Y=Y+Math.imul(p,F0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(b,F0)|0,O=O+Math.imul(b,C0)|0,Y=Y+Math.imul(Q0,x0)|0,X=X+Math.imul(Q0,q0)|0,X=X+Math.imul($0,x0)|0,O=O+Math.imul($0,q0)|0,Y=Y+Math.imul(h,z0)|0,X=X+Math.imul(h,M0)|0,X=X+Math.imul(d,z0)|0,O=O+Math.imul(d,M0)|0;var QU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,Y=Math.imul(J0,P0),X=Math.imul(J0,D0),X=X+Math.imul(T0,P0)|0,O=Math.imul(T0,D0),Y=Y+Math.imul(G0,B0)|0,X=X+Math.imul(G0,L0)|0,X=X+Math.imul(A0,B0)|0,O=O+Math.imul(A0,L0)|0,Y=Y+Math.imul(Z0,_)|0,X=X+Math.imul(Z0,w)|0,X=X+Math.imul(W0,_)|0,O=O+Math.imul(W0,w)|0,Y=Y+Math.imul(n,U0)|0,X=X+Math.imul(n,I0)|0,X=X+Math.imul(X0,U0)|0,O=O+Math.imul(X0,I0)|0,Y=Y+Math.imul(i,F0)|0,X=X+Math.imul(i,C0)|0,X=X+Math.imul(e,F0)|0,O=O+Math.imul(e,C0)|0,Y=Y+Math.imul(p,x0)|0,X=X+Math.imul(p,q0)|0,X=X+Math.imul(b,x0)|0,O=O+Math.imul(b,q0)|0,Y=Y+Math.imul(Q0,z0)|0,X=X+Math.imul(Q0,M0)|0,X=X+Math.imul($0,z0)|0,O=O+Math.imul($0,M0)|0;var $U=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,Y=Math.imul(J0,B0),X=Math.imul(J0,L0),X=X+Math.imul(T0,B0)|0,O=Math.imul(T0,L0),Y=Y+Math.imul(G0,_)|0,X=X+Math.imul(G0,w)|0,X=X+Math.imul(A0,_)|0,O=O+Math.imul(A0,w)|0,Y=Y+Math.imul(Z0,U0)|0,X=X+Math.imul(Z0,I0)|0,X=X+Math.imul(W0,U0)|0,O=O+Math.imul(W0,I0)|0,Y=Y+Math.imul(n,F0)|0,X=X+Math.imul(n,C0)|0,X=X+Math.imul(X0,F0)|0,O=O+Math.imul(X0,C0)|0,Y=Y+Math.imul(i,x0)|0,X=X+Math.imul(i,q0)|0,X=X+Math.imul(e,x0)|0,O=O+Math.imul(e,q0)|0,Y=Y+Math.imul(p,z0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(b,z0)|0,O=O+Math.imul(b,M0)|0;var YU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,Y=Math.imul(J0,_),X=Math.imul(J0,w),X=X+Math.imul(T0,_)|0,O=Math.imul(T0,w),Y=Y+Math.imul(G0,U0)|0,X=X+Math.imul(G0,I0)|0,X=X+Math.imul(A0,U0)|0,O=O+Math.imul(A0,I0)|0,Y=Y+Math.imul(Z0,F0)|0,X=X+Math.imul(Z0,C0)|0,X=X+Math.imul(W0,F0)|0,O=O+Math.imul(W0,C0)|0,Y=Y+Math.imul(n,x0)|0,X=X+Math.imul(n,q0)|0,X=X+Math.imul(X0,x0)|0,O=O+Math.imul(X0,q0)|0,Y=Y+Math.imul(i,z0)|0,X=X+Math.imul(i,M0)|0,X=X+Math.imul(e,z0)|0,O=O+Math.imul(e,M0)|0;var VU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,Y=Math.imul(J0,U0),X=Math.imul(J0,I0),X=X+Math.imul(T0,U0)|0,O=Math.imul(T0,I0),Y=Y+Math.imul(G0,F0)|0,X=X+Math.imul(G0,C0)|0,X=X+Math.imul(A0,F0)|0,O=O+Math.imul(A0,C0)|0,Y=Y+Math.imul(Z0,x0)|0,X=X+Math.imul(Z0,q0)|0,X=X+Math.imul(W0,x0)|0,O=O+Math.imul(W0,q0)|0,Y=Y+Math.imul(n,z0)|0,X=X+Math.imul(n,M0)|0,X=X+Math.imul(X0,z0)|0,O=O+Math.imul(X0,M0)|0;var OU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(OU>>>26)|0,OU&=67108863,Y=Math.imul(J0,F0),X=Math.imul(J0,C0),X=X+Math.imul(T0,F0)|0,O=Math.imul(T0,C0),Y=Y+Math.imul(G0,x0)|0,X=X+Math.imul(G0,q0)|0,X=X+Math.imul(A0,x0)|0,O=O+Math.imul(A0,q0)|0,Y=Y+Math.imul(Z0,z0)|0,X=X+Math.imul(Z0,M0)|0,X=X+Math.imul(W0,z0)|0,O=O+Math.imul(W0,M0)|0;var GU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,Y=Math.imul(J0,x0),X=Math.imul(J0,q0),X=X+Math.imul(T0,x0)|0,O=Math.imul(T0,q0),Y=Y+Math.imul(G0,z0)|0,X=X+Math.imul(G0,M0)|0,X=X+Math.imul(A0,z0)|0,O=O+Math.imul(A0,M0)|0;var KU=(J+Y|0)+((X&8191)<<13)|0;J=(O+(X>>>13)|0)+(KU>>>26)|0,KU&=67108863,Y=Math.imul(J0,z0),X=Math.imul(J0,M0),X=X+Math.imul(T0,z0)|0,O=Math.imul(T0,M0);var WU=(J+Y|0)+((X&8191)<<13)|0;if(J=(O+(X>>>13)|0)+(WU>>>26)|0,WU&=67108863,K[0]=t0,K[1]=p0,K[2]=f0,K[3]=b0,K[4]=a0,K[5]=e0,K[6]=i0,K[7]=UU,K[8]=XU,K[9]=IU,K[10]=ZU,K[11]=QU,K[12]=$U,K[13]=YU,K[14]=VU,K[15]=OU,K[16]=GU,K[17]=KU,K[18]=WU,J!==0)K[19]=J,Q.length++;return Q};if(!Math.imul)j=q;function x(F,U,Z){Z.negative=U.negative^F.negative,Z.length=F.length+U.length;var Q=0,I=0;for(var $=0;$<Z.length-1;$++){var K=I;I=0;var J=Q&67108863,Y=Math.min($,U.length-1);for(var X=Math.max(0,$-F.length+1);X<=Y;X++){var O=$-X,v=F.words[O]|0,T=U.words[X]|0,B=v*T,c=B&67108863;K=K+(B/67108864|0)|0,c=c+J|0,J=c&67108863,K=K+(c>>>26)|0,I+=K>>>26,K&=67108863}Z.words[$]=J,Q=K,K=I}if(Q!==0)Z.words[$]=Q;else Z.length--;return Z.strip()}function g(F,U,Z){var Q=new N;return Q.mulp(F,U,Z)}V.prototype.mulTo=function F(U,Z){var Q,I=this.length+U.length;if(this.length===10&&U.length===10)Q=j(this,U,Z);else if(I<63)Q=q(this,U,Z);else if(I<1024)Q=x(this,U,Z);else Q=g(this,U,Z);return Q};function N(F,U){this.x=F,this.y=U}N.prototype.makeRBT=function F(U){var Z=new Array(U),Q=V.prototype._countBits(U)-1;for(var I=0;I<U;I++)Z[I]=this.revBin(I,Q,U);return Z},N.prototype.revBin=function F(U,Z,Q){if(U===0||U===Q-1)return U;var I=0;for(var $=0;$<Z;$++)I|=(U&1)<<Z-$-1,U>>=1;return I},N.prototype.permute=function F(U,Z,Q,I,$,K){for(var J=0;J<K;J++)I[J]=Z[U[J]],$[J]=Q[U[J]]},N.prototype.transform=function F(U,Z,Q,I,$,K){this.permute(K,U,Z,Q,I,$);for(var J=1;J<$;J<<=1){var Y=J<<1,X=Math.cos(2*Math.PI/Y),O=Math.sin(2*Math.PI/Y);for(var v=0;v<$;v+=Y){var T=X,B=O;for(var c=0;c<J;c++){var l=Q[v+c],s=I[v+c],O0=Q[v+c+J],h=I[v+c+J],d=T*O0-B*h;if(h=T*h+B*O0,O0=d,Q[v+c]=l+O0,I[v+c]=s+h,Q[v+c+J]=l-O0,I[v+c+J]=s-h,c!==Y)d=X*T-O*B,B=X*B+O*T,T=d}}}},N.prototype.guessLen13b=function F(U,Z){var Q=Math.max(Z,U)|1,I=Q&1,$=0;for(Q=Q/2|0;Q;Q=Q>>>1)$++;return 1<<$+1+I},N.prototype.conjugate=function F(U,Z,Q){if(Q<=1)return;for(var I=0;I<Q/2;I++){var $=U[I];U[I]=U[Q-I-1],U[Q-I-1]=$,$=Z[I],Z[I]=-Z[Q-I-1],Z[Q-I-1]=-$}},N.prototype.normalize13b=function F(U,Z){var Q=0;for(var I=0;I<Z/2;I++){var $=Math.round(U[2*I+1]/Z)*8192+Math.round(U[2*I]/Z)+Q;if(U[I]=$&67108863,$<67108864)Q=0;else Q=$/67108864|0}return U},N.prototype.convert13b=function F(U,Z,Q,I){var $=0;for(var K=0;K<Z;K++)$=$+(U[K]|0),Q[2*K]=$&8191,$=$>>>13,Q[2*K+1]=$&8191,$=$>>>13;for(K=2*Z;K<I;++K)Q[K]=0;H($===0),H(($&-8192)===0)},N.prototype.stub=function F(U){var Z=new Array(U);for(var Q=0;Q<U;Q++)Z[Q]=0;return Z},N.prototype.mulp=function F(U,Z,Q){var I=2*this.guessLen13b(U.length,Z.length),$=this.makeRBT(I),K=this.stub(I),J=new Array(I),Y=new Array(I),X=new Array(I),O=new Array(I),v=new Array(I),T=new Array(I),B=Q.words;B.length=I,this.convert13b(U.words,U.length,J,I),this.convert13b(Z.words,Z.length,O,I),this.transform(J,K,Y,X,I,$),this.transform(O,K,v,T,I,$);for(var c=0;c<I;c++){var l=Y[c]*v[c]-X[c]*T[c];X[c]=Y[c]*T[c]+X[c]*v[c],Y[c]=l}return this.conjugate(Y,X,I),this.transform(Y,X,B,K,I,$),this.conjugate(B,K,I),this.normalize13b(B,I),Q.negative=U.negative^Z.negative,Q.length=U.length+Z.length,Q.strip()},V.prototype.mul=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),this.mulTo(U,Z)},V.prototype.mulf=function F(U){var Z=new V(null);return Z.words=new Array(this.length+U.length),g(this,U,Z)},V.prototype.imul=function F(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function F(U){H(typeof U==="number"),H(U<67108864);var Z=0;for(var Q=0;Q<this.length;Q++){var I=(this.words[Q]|0)*U,$=(I&67108863)+(Z&67108863);Z>>=26,Z+=I/67108864|0,Z+=$>>>26,this.words[Q]=$&67108863}if(Z!==0)this.words[Q]=Z,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function F(U){return this.clone().imuln(U)},V.prototype.sqr=function F(){return this.mul(this)},V.prototype.isqr=function F(){return this.imul(this.clone())},V.prototype.pow=function F(U){var Z=M(U);if(Z.length===0)return new V(1);var Q=this;for(var I=0;I<Z.length;I++,Q=Q.sqr())if(Z[I]!==0)break;if(++I<Z.length)for(var $=Q.sqr();I<Z.length;I++,$=$.sqr()){if(Z[I]===0)continue;Q=Q.mul($)}return Q},V.prototype.iushln=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=67108863>>>26-Z<<26-Z,$;if(Z!==0){var K=0;for($=0;$<this.length;$++){var J=this.words[$]&I,Y=(this.words[$]|0)-J<<Z;this.words[$]=Y|K,K=J>>>26-Z}if(K)this.words[$]=K,this.length++}if(Q!==0){for($=this.length-1;$>=0;$--)this.words[$+Q]=this.words[$];for($=0;$<Q;$++)this.words[$]=0;this.length+=Q}return this.strip()},V.prototype.ishln=function F(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function F(U,Z,Q){H(typeof U==="number"&&U>=0);var I;if(Z)I=(Z-Z%26)/26;else I=0;var $=U%26,K=Math.min((U-$)/26,this.length),J=67108863^67108863>>>$<<$,Y=Q;if(I-=K,I=Math.max(0,I),Y){for(var X=0;X<K;X++)Y.words[X]=this.words[X];Y.length=K}if(K===0);else if(this.length>K){this.length-=K;for(X=0;X<this.length;X++)this.words[X]=this.words[X+K]}else this.words[0]=0,this.length=1;var O=0;for(X=this.length-1;X>=0&&(O!==0||X>=I);X--){var v=this.words[X]|0;this.words[X]=O<<26-$|v>>>$,O=v&J}if(Y&&O!==0)Y.words[Y.length++]=O;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function F(U,Z,Q){return H(this.negative===0),this.iushrn(U,Z,Q)},V.prototype.shln=function F(U){return this.clone().ishln(U)},V.prototype.ushln=function F(U){return this.clone().iushln(U)},V.prototype.shrn=function F(U){return this.clone().ishrn(U)},V.prototype.ushrn=function F(U){return this.clone().iushrn(U)},V.prototype.testn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return!1;var $=this.words[Q];return!!($&I)},V.prototype.imaskn=function F(U){H(typeof U==="number"&&U>=0);var Z=U%26,Q=(U-Z)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=Q)return this;if(Z!==0)Q++;if(this.length=Math.min(Q,this.length),Z!==0){var I=67108863^67108863>>>Z<<Z;this.words[this.length-1]&=I}return this.strip()},V.prototype.maskn=function F(U){return this.clone().imaskn(U)},V.prototype.iaddn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.isubn(-U);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<U)return this.words[0]=U-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(U),this.negative=1,this}return this._iaddn(U)},V.prototype._iaddn=function F(U){this.words[0]+=U;for(var Z=0;Z<this.length&&this.words[Z]>=67108864;Z++)if(this.words[Z]-=67108864,Z===this.length-1)this.words[Z+1]=1;else this.words[Z+1]++;return this.length=Math.max(this.length,Z+1),this},V.prototype.isubn=function F(U){if(H(typeof U==="number"),H(U<67108864),U<0)return this.iaddn(-U);if(this.negative!==0)return this.negative=0,this.iaddn(U),this.negative=1,this;if(this.words[0]-=U,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Z=0;Z<this.length&&this.words[Z]<0;Z++)this.words[Z]+=67108864,this.words[Z+1]-=1;return this.strip()},V.prototype.addn=function F(U){return this.clone().iaddn(U)},V.prototype.subn=function F(U){return this.clone().isubn(U)},V.prototype.iabs=function F(){return this.negative=0,this},V.prototype.abs=function F(){return this.clone().iabs()},V.prototype._ishlnsubmul=function F(U,Z,Q){var I=U.length+Q,$;this._expand(I);var K,J=0;for($=0;$<U.length;$++){K=(this.words[$+Q]|0)+J;var Y=(U.words[$]|0)*Z;K-=Y&67108863,J=(K>>26)-(Y/67108864|0),this.words[$+Q]=K&67108863}for(;$<this.length-Q;$++)K=(this.words[$+Q]|0)+J,J=K>>26,this.words[$+Q]=K&67108863;if(J===0)return this.strip();H(J===-1),J=0;for($=0;$<this.length;$++)K=-(this.words[$]|0)+J,J=K>>26,this.words[$]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function F(U,Z){var Q=this.length-U.length,I=this.clone(),$=U,K=$.words[$.length-1]|0,J=this._countBits(K);if(Q=26-J,Q!==0)$=$.ushln(Q),I.iushln(Q),K=$.words[$.length-1]|0;var Y=I.length-$.length,X;if(Z!=="mod"){X=new V(null),X.length=Y+1,X.words=new Array(X.length);for(var O=0;O<X.length;O++)X.words[O]=0}var v=I.clone()._ishlnsubmul($,1,Y);if(v.negative===0){if(I=v,X)X.words[Y]=1}for(var T=Y-1;T>=0;T--){var B=(I.words[$.length+T]|0)*67108864+(I.words[$.length+T-1]|0);B=Math.min(B/K|0,67108863),I._ishlnsubmul($,B,T);while(I.negative!==0)if(B--,I.negative=0,I._ishlnsubmul($,1,T),!I.isZero())I.negative^=1;if(X)X.words[T]=B}if(X)X.strip();if(I.strip(),Z!=="div"&&Q!==0)I.iushrn(Q);return{div:X||null,mod:I}},V.prototype.divmod=function F(U,Z,Q){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var I,$,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Z),Z!=="mod")I=K.div.neg();if(Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.iadd(U)}return{div:I,mod:$}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Z),Z!=="mod")I=K.div.neg();return{div:I,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Z),Z!=="div"){if($=K.mod.neg(),Q&&$.negative!==0)$.isub(U)}return{div:K.div,mod:$}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Z==="div")return{div:this.divn(U.words[0]),mod:null};if(Z==="mod")return{div:null,mod:new V(this.modn(U.words[0]))};return{div:this.divn(U.words[0]),mod:new V(this.modn(U.words[0]))}}return this._wordDiv(U,Z)},V.prototype.div=function F(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function F(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function F(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function F(U){var Z=this.divmod(U);if(Z.mod.isZero())return Z.div;var Q=Z.div.negative!==0?Z.mod.isub(U):Z.mod,I=U.ushrn(1),$=U.andln(1),K=Q.cmp(I);if(K<0||$===1&&K===0)return Z.div;return Z.div.negative!==0?Z.div.isubn(1):Z.div.iaddn(1)},V.prototype.modn=function F(U){H(U<=67108863);var Z=67108864%U,Q=0;for(var I=this.length-1;I>=0;I--)Q=(Z*Q+(this.words[I]|0))%U;return Q},V.prototype.idivn=function F(U){H(U<=67108863);var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=(this.words[Q]|0)+Z*67108864;this.words[Q]=I/U|0,Z=I%U}return this.strip()},V.prototype.divn=function F(U){return this.clone().idivn(U)},V.prototype.egcd=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=new V(0),J=new V(1),Y=0;while(Z.isEven()&&Q.isEven())Z.iushrn(1),Q.iushrn(1),++Y;var X=Q.clone(),O=Z.clone();while(!Z.isZero()){for(var v=0,T=1;(Z.words[0]&T)===0&&v<26;++v,T<<=1);if(v>0){Z.iushrn(v);while(v-- >0){if(I.isOdd()||$.isOdd())I.iadd(X),$.isub(O);I.iushrn(1),$.iushrn(1)}}for(var B=0,c=1;(Q.words[0]&c)===0&&B<26;++B,c<<=1);if(B>0){Q.iushrn(B);while(B-- >0){if(K.isOdd()||J.isOdd())K.iadd(X),J.isub(O);K.iushrn(1),J.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub(K),$.isub(J);else Q.isub(Z),K.isub(I),J.isub($)}return{a:K,b:J,gcd:Q.iushln(Y)}},V.prototype._invmp=function F(U){H(U.negative===0),H(!U.isZero());var Z=this,Q=U.clone();if(Z.negative!==0)Z=Z.umod(U);else Z=Z.clone();var I=new V(1),$=new V(0),K=Q.clone();while(Z.cmpn(1)>0&&Q.cmpn(1)>0){for(var J=0,Y=1;(Z.words[0]&Y)===0&&J<26;++J,Y<<=1);if(J>0){Z.iushrn(J);while(J-- >0){if(I.isOdd())I.iadd(K);I.iushrn(1)}}for(var X=0,O=1;(Q.words[0]&O)===0&&X<26;++X,O<<=1);if(X>0){Q.iushrn(X);while(X-- >0){if($.isOdd())$.iadd(K);$.iushrn(1)}}if(Z.cmp(Q)>=0)Z.isub(Q),I.isub($);else Q.isub(Z),$.isub(I)}var v;if(Z.cmpn(1)===0)v=I;else v=$;if(v.cmpn(0)<0)v.iadd(U);return v},V.prototype.gcd=function F(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Z=this.clone(),Q=U.clone();Z.negative=0,Q.negative=0;for(var I=0;Z.isEven()&&Q.isEven();I++)Z.iushrn(1),Q.iushrn(1);do{while(Z.isEven())Z.iushrn(1);while(Q.isEven())Q.iushrn(1);var $=Z.cmp(Q);if($<0){var K=Z;Z=Q,Q=K}else if($===0||Q.cmpn(1)===0)break;Z.isub(Q)}while(!0);return Q.iushln(I)},V.prototype.invm=function F(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function F(){return(this.words[0]&1)===0},V.prototype.isOdd=function F(){return(this.words[0]&1)===1},V.prototype.andln=function F(U){return this.words[0]&U},V.prototype.bincn=function F(U){H(typeof U==="number");var Z=U%26,Q=(U-Z)/26,I=1<<Z;if(this.length<=Q)return this._expand(Q+1),this.words[Q]|=I,this;var $=I;for(var K=Q;$!==0&&K<this.length;K++){var J=this.words[K]|0;J+=$,$=J>>>26,J&=67108863,this.words[K]=J}if($!==0)this.words[K]=$,this.length++;return this},V.prototype.isZero=function F(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function F(U){var Z=U<0;if(this.negative!==0&&!Z)return-1;if(this.negative===0&&Z)return 1;this.strip();var Q;if(this.length>1)Q=1;else{if(Z)U=-U;H(U<=67108863,"Number is too big");var I=this.words[0]|0;Q=I===U?0:I<U?-1:1}if(this.negative!==0)return-Q|0;return Q},V.prototype.cmp=function F(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Z=this.ucmp(U);if(this.negative!==0)return-Z|0;return Z},V.prototype.ucmp=function F(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Z=0;for(var Q=this.length-1;Q>=0;Q--){var I=this.words[Q]|0,$=U.words[Q]|0;if(I===$)continue;if(I<$)Z=-1;else if(I>$)Z=1;break}return Z},V.prototype.gtn=function F(U){return this.cmpn(U)===1},V.prototype.gt=function F(U){return this.cmp(U)===1},V.prototype.gten=function F(U){return this.cmpn(U)>=0},V.prototype.gte=function F(U){return this.cmp(U)>=0},V.prototype.ltn=function F(U){return this.cmpn(U)===-1},V.prototype.lt=function F(U){return this.cmp(U)===-1},V.prototype.lten=function F(U){return this.cmpn(U)<=0},V.prototype.lte=function F(U){return this.cmp(U)<=0},V.prototype.eqn=function F(U){return this.cmpn(U)===0},V.prototype.eq=function F(U){return this.cmp(U)===0},V.red=function F(U){return new u(U)},V.prototype.toRed=function F(U){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),U.convertTo(this)._forceRed(U)},V.prototype.fromRed=function F(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function F(U){return this.red=U,this},V.prototype.forceRed=function F(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function F(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function F(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function F(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function F(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function F(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.mul(this,U)},V.prototype.redIMul=function F(U){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,U),this.red.imul(this,U)},V.prototype.redSqr=function F(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function F(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function F(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function F(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function F(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function F(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var y={k256:null,p224:null,p192:null,p25519:null};function f(F,U){this.name=F,this.p=new V(U,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}f.prototype._tmp=function F(){var U=new V(null);return U.words=new Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function F(U){var Z=U,Q;do this.split(Z,this.tmp),Z=this.imulK(Z),Z=Z.iadd(this.tmp),Q=Z.bitLength();while(Q>this.n);var I=Q<this.n?-1:Z.ucmp(this.p);if(I===0)Z.words[0]=0,Z.length=1;else if(I>0)Z.isub(this.p);else if(Z.strip!==void 0)Z.strip();else Z._strip();return Z},f.prototype.split=function F(U,Z){U.iushrn(this.n,0,Z)},f.prototype.imulK=function F(U){return U.imul(this.k)};function o(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}z(o,f),o.prototype.split=function F(U,Z){var Q=4194303,I=Math.min(U.length,9);for(var $=0;$<I;$++)Z.words[$]=U.words[$];if(Z.length=I,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Z.words[Z.length++]=K&Q;for($=10;$<U.length;$++){var J=U.words[$]|0;U.words[$-10]=(J&Q)<<4|K>>>22,K=J}if(K>>>=22,U.words[$-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},o.prototype.imulK=function F(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Z=0;for(var Q=0;Q<U.length;Q++){var I=U.words[Q]|0;Z+=I*977,U.words[Q]=Z&67108863,Z=I*64+(Z/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function r(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}z(r,f);function V0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}z(V0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}z(Y0,f),Y0.prototype.imulK=function F(U){var Z=0;for(var Q=0;Q<U.length;Q++){var I=(U.words[Q]|0)*19+Z,$=I&67108863;I>>>=26,U.words[Q]=$,Z=I}if(Z!==0)U.words[U.length++]=Z;return U},V._prime=function F(U){if(y[U])return y[U];var Z;if(U==="k256")Z=new o;else if(U==="p224")Z=new r;else if(U==="p192")Z=new V0;else if(U==="p25519")Z=new Y0;else throw new Error("Unknown prime "+U);return y[U]=Z,Z};function u(F){if(typeof F==="string"){var U=V._prime(F);this.m=U.p,this.prime=U}else H(F.gtn(1),"modulus must be greater than 1"),this.m=F,this.prime=null}u.prototype._verify1=function F(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function F(U,Z){H((U.negative|Z.negative)===0,"red works only with positives"),H(U.red&&U.red===Z.red,"red works only with red numbers")},u.prototype.imod=function F(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function F(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function F(U,Z){this._verify2(U,Z);var Q=U.add(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q._forceRed(this)},u.prototype.iadd=function F(U,Z){this._verify2(U,Z);var Q=U.iadd(Z);if(Q.cmp(this.m)>=0)Q.isub(this.m);return Q},u.prototype.sub=function F(U,Z){this._verify2(U,Z);var Q=U.sub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q._forceRed(this)},u.prototype.isub=function F(U,Z){this._verify2(U,Z);var Q=U.isub(Z);if(Q.cmpn(0)<0)Q.iadd(this.m);return Q},u.prototype.shl=function F(U,Z){return this._verify1(U),this.imod(U.ushln(Z))},u.prototype.imul=function F(U,Z){return this._verify2(U,Z),this.imod(U.imul(Z))},u.prototype.mul=function F(U,Z){return this._verify2(U,Z),this.imod(U.mul(Z))},u.prototype.isqr=function F(U){return this.imul(U,U.clone())},u.prototype.sqr=function F(U){return this.mul(U,U)},u.prototype.sqrt=function F(U){if(U.isZero())return U.clone();var Z=this.m.andln(3);if(H(Z%2===1),Z===3){var Q=this.m.add(new V(1)).iushrn(2);return this.pow(U,Q)}var I=this.m.subn(1),$=0;while(!I.isZero()&&I.andln(1)===0)$++,I.iushrn(1);H(!I.isZero());var K=new V(1).toRed(this),J=K.redNeg(),Y=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,Y).cmp(J)!==0)X.redIAdd(J);var O=this.pow(X,I),v=this.pow(U,I.addn(1).iushrn(1)),T=this.pow(U,I),B=$;while(T.cmp(K)!==0){var c=T;for(var l=0;c.cmp(K)!==0;l++)c=c.redSqr();H(l<B);var s=this.pow(O,new V(1).iushln(B-l-1));v=v.redMul(s),O=s.redSqr(),T=T.redMul(O),B=l}return v},u.prototype.invm=function F(U){var Z=U._invmp(this.m);if(Z.negative!==0)return Z.negative=0,this.imod(Z).redNeg();else return this.imod(Z)},u.prototype.pow=function F(U,Z){if(Z.isZero())return new V(1).toRed(this);if(Z.cmpn(1)===0)return U.clone();var Q=4,I=new Array(1<<Q);I[0]=new V(1).toRed(this),I[1]=U;for(var $=2;$<I.length;$++)I[$]=this.mul(I[$-1],U);var K=I[0],J=0,Y=0,X=Z.bitLength()%26;if(X===0)X=26;for($=Z.length-1;$>=0;$--){var O=Z.words[$];for(var v=X-1;v>=0;v--){var T=O>>v&1;if(K!==I[0])K=this.sqr(K);if(T===0&&J===0){Y=0;continue}if(J<<=1,J|=T,Y++,Y!==Q&&($!==0||v!==0))continue;K=this.mul(K,I[J]),Y=0,J=0}X=26}return K},u.prototype.convertTo=function F(U){var Z=U.umod(this.m);return Z===U?Z.clone():Z},u.prototype.convertFrom=function F(U){var Z=U.clone();return Z.red=null,Z},V.mont=function F(U){return new a(U)};function a(F){if(u.call(this,F),this.shift=this.m.bitLength(),this.shift%26!==0)this.shift+=26-this.shift%26;this.r=new V(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}z(a,u),a.prototype.convertTo=function F(U){return this.imod(U.ushln(this.shift))},a.prototype.convertFrom=function F(U){var Z=this.imod(U.mul(this.rinv));return Z.red=null,Z},a.prototype.imul=function F(U,Z){if(U.isZero()||Z.isZero())return U.words[0]=0,U.length=1,U;var Q=U.imul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.mul=function F(U,Z){if(U.isZero()||Z.isZero())return new V(0)._forceRed(this);var Q=U.mul(Z),I=Q.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),$=Q.isub(I).iushrn(this.shift),K=$;if($.cmp(this.m)>=0)K=$.isub(this.m);else if($.cmpn(0)<0)K=$.iadd(this.m);return K._forceRed(this)},a.prototype.invm=function F(U){var Z=this.imod(U._invmp(this.m).mul(this.r2));return Z._forceRed(this)}})(typeof G==="undefined"||G,E)}),wZ=w0((E,G)=>{var W=AI(),C=PU().Buffer;function H(z,V){return C.from(z.toRed(W.mont(V.modulus)).redPow(new W(V.publicExponent)).fromRed().toArray())}G.exports=H}),QV=w0((E,G)=>{(function(W,C){function H(Q,I){if(!Q)throw new Error(I||"Assertion failed")}function z(Q,I){Q.super_=I;var $=function(){};$.prototype=I.prototype,Q.prototype=new $,Q.prototype.constructor=Q}function V(Q,I,$){if(V.isBN(Q))return Q;if(this.negative=0,this.words=null,this.length=0,this.red=null,Q!==null){if(I==="le"||I==="be")$=I,I=10;this._init(Q||0,I||10,$||"be")}}if(typeof W==="object")W.exports=V;else C.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window!=="undefined"&&typeof window.Buffer!=="undefined")P=window.Buffer;else P=(HU(),y0(FU)).Buffer}catch(Q){}V.isBN=function Q(I){if(I instanceof V)return!0;return I!==null&&typeof I==="object"&&I.constructor.wordSize===V.wordSize&&Array.isArray(I.words)},V.max=function Q(I,$){if(I.cmp($)>0)return I;return $},V.min=function Q(I,$){if(I.cmp($)<0)return I;return $},V.prototype._init=function Q(I,$,K){if(typeof I==="number")return this._initNumber(I,$,K);if(typeof I==="object")return this._initArray(I,$,K);if($==="hex")$=16;H($===($|0)&&$>=2&&$<=36),I=I.toString().replace(/\s+/g,"");var J=0;if(I[0]==="-")J++,this.negative=1;if(J<I.length){if($===16)this._parseHex(I,J,K);else if(this._parseBase(I,$,J),K==="le")this._initArray(this.toArray(),$,K)}},V.prototype._initNumber=function Q(I,$,K){if(I<0)this.negative=1,I=-I;if(I<67108864)this.words=[I&67108863],this.length=1;else if(I<4503599627370496)this.words=[I&67108863,I/67108864&67108863],this.length=2;else H(I<9007199254740992),this.words=[I&67108863,I/67108864&67108863,1],this.length=3;if(K!=="le")return;this._initArray(this.toArray(),$,K)},V.prototype._initArray=function Q(I,$,K){if(H(typeof I.length==="number"),I.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(I.length/3),this.words=new Array(this.length);for(var J=0;J<this.length;J++)this.words[J]=0;var Y,X,O=0;if(K==="be"){for(J=I.length-1,Y=0;J>=0;J-=3)if(X=I[J]|I[J-1]<<8|I[J-2]<<16,this.words[Y]|=X<<O&67108863,this.words[Y+1]=X>>>26-O&67108863,O+=24,O>=26)O-=26,Y++}else if(K==="le"){for(J=0,Y=0;J<I.length;J+=3)if(X=I[J]|I[J+1]<<8|I[J+2]<<16,this.words[Y]|=X<<O&67108863,this.words[Y+1]=X>>>26-O&67108863,O+=24,O>=26)O-=26,Y++}return this._strip()};function k(Q,I){var $=Q.charCodeAt(I);if($>=48&&$<=57)return $-48;else if($>=65&&$<=70)return $-55;else if($>=97&&$<=102)return $-87;else H(!1,"Invalid character in "+Q)}function R(Q,I,$){var K=k(Q,$);if($-1>=I)K|=k(Q,$-1)<<4;return K}V.prototype._parseHex=function Q(I,$,K){this.length=Math.ceil((I.length-$)/6),this.words=new Array(this.length);for(var J=0;J<this.length;J++)this.words[J]=0;var Y=0,X=0,O;if(K==="be")for(J=I.length-1;J>=$;J-=2)if(O=R(I,$,J)<<Y,this.words[X]|=O&67108863,Y>=18)Y-=18,X+=1,this.words[X]|=O>>>26;else Y+=8;else{var v=I.length-$;for(J=v%2===0?$+1:$;J<I.length;J+=2)if(O=R(I,$,J)<<Y,this.words[X]|=O&67108863,Y>=18)Y-=18,X+=1,this.words[X]|=O>>>26;else Y+=8}this._strip()};function S(Q,I,$,K){var J=0,Y=0,X=Math.min(Q.length,$);for(var O=I;O<X;O++){var v=Q.charCodeAt(O)-48;if(J*=K,v>=49)Y=v-49+10;else if(v>=17)Y=v-17+10;else Y=v;H(v>=0&&Y<K,"Invalid character"),J+=Y}return J}V.prototype._parseBase=function Q(I,$,K){this.words=[0],this.length=1;for(var J=0,Y=1;Y<=67108863;Y*=$)J++;J--,Y=Y/$|0;var X=I.length-K,O=X%J,v=Math.min(X,X-O)+K,T=0;for(var B=K;B<v;B+=J)if(T=S(I,B,B+J,$),this.imuln(Y),this.words[0]+T<67108864)this.words[0]+=T;else this._iaddn(T);if(O!==0){var c=1;T=S(I,B,I.length,$);for(B=0;B<O;B++)c*=$;if(this.imuln(c),this.words[0]+T<67108864)this.words[0]+=T;else this._iaddn(T)}this._strip()},V.prototype.copy=function Q(I){I.words=new Array(this.length);for(var $=0;$<this.length;$++)I.words[$]=this.words[$];I.length=this.length,I.negative=this.negative,I.red=this.red};function D(Q,I){Q.words=I.words,Q.length=I.length,Q.negative=I.negative,Q.red=I.red}if(V.prototype._move=function Q(I){D(I,this)},V.prototype.clone=function Q(){var I=new V(null);return this.copy(I),I},V.prototype._expand=function Q(I){while(this.length<I)this.words[this.length++]=0;return this},V.prototype._strip=function Q(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function Q(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},typeof Symbol!=="undefined"&&typeof Symbol.for==="function")try{V.prototype[Symbol.for("nodejs.util.inspect.custom")]=A}catch(Q){V.prototype.inspect=A}else V.prototype.inspect=A;function A(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var L=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],M=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],q=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64000000,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,24300000,28629151,33554432,39135393,45435424,52521875,60466176];if(V.prototype.toString=function Q(I,$){I=I||10,$=$|0||1;var K;if(I===16||I==="hex"){K="";var J=0,Y=0;for(var X=0;X<this.length;X++){var O=this.words[X],v=((O<<J|Y)&16777215).toString(16);if(Y=O>>>24-J&16777215,J+=2,J>=26)J-=26,X--;if(Y!==0||X!==this.length-1)K=L[6-v.length]+v+K;else K=v+K}if(Y!==0)K=Y.toString(16)+K;while(K.length%$!==0)K="0"+K;if(this.negative!==0)K="-"+K;return K}if(I===(I|0)&&I>=2&&I<=36){var T=M[I],B=q[I];K="";var c=this.clone();c.negative=0;while(!c.isZero()){var l=c.modrn(B).toString(I);if(c=c.idivn(B),!c.isZero())K=L[T-l.length]+l+K;else K=l+K}if(this.isZero())K="0"+K;while(K.length%$!==0)K="0"+K;if(this.negative!==0)K="-"+K;return K}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function Q(){var I=this.words[0];if(this.length===2)I+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)I+=4503599627370496+this.words[1]*67108864;else if(this.length>2)H(!1,"Number can only safely store up to 53 bits");return this.negative!==0?-I:I},V.prototype.toJSON=function Q(){return this.toString(16,2)},P)V.prototype.toBuffer=function Q(I,$){return this.toArrayLike(P,I,$)};V.prototype.toArray=function Q(I,$){return this.toArrayLike(Array,I,$)};var j=function Q(I,$){if(I.allocUnsafe)return I.allocUnsafe($);return new I($)};if(V.prototype.toArrayLike=function Q(I,$,K){this._strip();var J=this.byteLength(),Y=K||Math.max(1,J);H(J<=Y,"byte array longer than desired length"),H(Y>0,"Requested array length <= 0");var X=j(I,Y),O=$==="le"?"LE":"BE";return this["_toArrayLike"+O](X,J),X},V.prototype._toArrayLikeLE=function Q(I,$){var K=0,J=0;for(var Y=0,X=0;Y<this.length;Y++){var O=this.words[Y]<<X|J;if(I[K++]=O&255,K<I.length)I[K++]=O>>8&255;if(K<I.length)I[K++]=O>>16&255;if(X===6){if(K<I.length)I[K++]=O>>24&255;J=0,X=0}else J=O>>>24,X+=2}if(K<I.length){I[K++]=J;while(K<I.length)I[K++]=0}},V.prototype._toArrayLikeBE=function Q(I,$){var K=I.length-1,J=0;for(var Y=0,X=0;Y<this.length;Y++){var O=this.words[Y]<<X|J;if(I[K--]=O&255,K>=0)I[K--]=O>>8&255;if(K>=0)I[K--]=O>>16&255;if(X===6){if(K>=0)I[K--]=O>>24&255;J=0,X=0}else J=O>>>24,X+=2}if(K>=0){I[K--]=J;while(K>=0)I[K--]=0}},Math.clz32)V.prototype._countBits=function Q(I){return 32-Math.clz32(I)};else V.prototype._countBits=function Q(I){var $=I,K=0;if($>=4096)K+=13,$>>>=13;if($>=64)K+=7,$>>>=7;if($>=8)K+=4,$>>>=4;if($>=2)K+=2,$>>>=2;return K+$};V.prototype._zeroBits=function Q(I){if(I===0)return 26;var $=I,K=0;if(($&8191)===0)K+=13,$>>>=13;if(($&127)===0)K+=7,$>>>=7;if(($&15)===0)K+=4,$>>>=4;if(($&3)===0)K+=2,$>>>=2;if(($&1)===0)K++;return K},V.prototype.bitLength=function Q(){var I=this.words[this.length-1],$=this._countBits(I);return(this.length-1)*26+$};function x(Q){var I=new Array(Q.bitLength());for(var $=0;$<I.length;$++){var K=$/26|0,J=$%26;I[$]=Q.words[K]>>>J&1}return I}V.prototype.zeroBits=function Q(){if(this.isZero())return 0;var I=0;for(var $=0;$<this.length;$++){var K=this._zeroBits(this.words[$]);if(I+=K,K!==26)break}return I},V.prototype.byteLength=function Q(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function Q(I){if(this.negative!==0)return this.abs().inotn(I).iaddn(1);return this.clone()},V.prototype.fromTwos=function Q(I){if(this.testn(I-1))return this.notn(I).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function Q(){return this.negative!==0},V.prototype.neg=function Q(){return this.clone().ineg()},V.prototype.ineg=function Q(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function Q(I){while(this.length<I.length)this.words[this.length++]=0;for(var $=0;$<I.length;$++)this.words[$]=this.words[$]|I.words[$];return this._strip()},V.prototype.ior=function Q(I){return H((this.negative|I.negative)===0),this.iuor(I)},V.prototype.or=function Q(I){if(this.length>I.length)return this.clone().ior(I);return I.clone().ior(this)},V.prototype.uor=function Q(I){if(this.length>I.length)return this.clone().iuor(I);return I.clone().iuor(this)},V.prototype.iuand=function Q(I){var $;if(this.length>I.length)$=I;else $=this;for(var K=0;K<$.length;K++)this.words[K]=this.words[K]&I.words[K];return this.length=$.length,this._strip()},V.prototype.iand=function Q(I){return H((this.negative|I.negative)===0),this.iuand(I)},V.prototype.and=function Q(I){if(this.length>I.length)return this.clone().iand(I);return I.clone().iand(this)},V.prototype.uand=function Q(I){if(this.length>I.length)return this.clone().iuand(I);return I.clone().iuand(this)},V.prototype.iuxor=function Q(I){var $,K;if(this.length>I.length)$=this,K=I;else $=I,K=this;for(var J=0;J<K.length;J++)this.words[J]=$.words[J]^K.words[J];if(this!==$)for(;J<$.length;J++)this.words[J]=$.words[J];return this.length=$.length,this._strip()},V.prototype.ixor=function Q(I){return H((this.negative|I.negative)===0),this.iuxor(I)},V.prototype.xor=function Q(I){if(this.length>I.length)return this.clone().ixor(I);return I.clone().ixor(this)},V.prototype.uxor=function Q(I){if(this.length>I.length)return this.clone().iuxor(I);return I.clone().iuxor(this)},V.prototype.inotn=function Q(I){H(typeof I==="number"&&I>=0);var $=Math.ceil(I/26)|0,K=I%26;if(this._expand($),K>0)$--;for(var J=0;J<$;J++)this.words[J]=~this.words[J]&67108863;if(K>0)this.words[J]=~this.words[J]&67108863>>26-K;return this._strip()},V.prototype.notn=function Q(I){return this.clone().inotn(I)},V.prototype.setn=function Q(I,$){H(typeof I==="number"&&I>=0);var K=I/26|0,J=I%26;if(this._expand(K+1),$)this.words[K]=this.words[K]|1<<J;else this.words[K]=this.words[K]&~(1<<J);return this._strip()},V.prototype.iadd=function Q(I){var $;if(this.negative!==0&&I.negative===0)return this.negative=0,$=this.isub(I),this.negative^=1,this._normSign();else if(this.negative===0&&I.negative!==0)return I.negative=0,$=this.isub(I),I.negative=1,$._normSign();var K,J;if(this.length>I.length)K=this,J=I;else K=I,J=this;var Y=0;for(var X=0;X<J.length;X++)$=(K.words[X]|0)+(J.words[X]|0)+Y,this.words[X]=$&67108863,Y=$>>>26;for(;Y!==0&&X<K.length;X++)$=(K.words[X]|0)+Y,this.words[X]=$&67108863,Y=$>>>26;if(this.length=K.length,Y!==0)this.words[this.length]=Y,this.length++;else if(K!==this)for(;X<K.length;X++)this.words[X]=K.words[X];return this},V.prototype.add=function Q(I){var $;if(I.negative!==0&&this.negative===0)return I.negative=0,$=this.sub(I),I.negative^=1,$;else if(I.negative===0&&this.negative!==0)return this.negative=0,$=I.sub(this),this.negative=1,$;if(this.length>I.length)return this.clone().iadd(I);return I.clone().iadd(this)},V.prototype.isub=function Q(I){if(I.negative!==0){I.negative=0;var $=this.iadd(I);return I.negative=1,$._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(I),this.negative=1,this._normSign();var K=this.cmp(I);if(K===0)return this.negative=0,this.length=1,this.words[0]=0,this;var J,Y;if(K>0)J=this,Y=I;else J=I,Y=this;var X=0;for(var O=0;O<Y.length;O++)$=(J.words[O]|0)-(Y.words[O]|0)+X,X=$>>26,this.words[O]=$&67108863;for(;X!==0&&O<J.length;O++)$=(J.words[O]|0)+X,X=$>>26,this.words[O]=$&67108863;if(X===0&&O<J.length&&J!==this)for(;O<J.length;O++)this.words[O]=J.words[O];if(this.length=Math.max(this.length,O),J!==this)this.negative=1;return this._strip()},V.prototype.sub=function Q(I){return this.clone().isub(I)};function g(Q,I,$){$.negative=I.negative^Q.negative;var K=Q.length+I.length|0;$.length=K,K=K-1|0;var J=Q.words[0]|0,Y=I.words[0]|0,X=J*Y,O=X&67108863,v=X/67108864|0;$.words[0]=O;for(var T=1;T<K;T++){var B=v>>>26,c=v&67108863,l=Math.min(T,I.length-1);for(var s=Math.max(0,T-Q.length+1);s<=l;s++){var O0=T-s|0;J=Q.words[O0]|0,Y=I.words[s]|0,X=J*Y+c,B+=X/67108864|0,c=X&67108863}$.words[T]=c|0,v=B|0}if(v!==0)$.words[T]=v|0;else $.length--;return $._strip()}var N=function Q(I,$,K){var J=I.words,Y=$.words,X=K.words,O=0,v,T,B,c=J[0]|0,l=c&8191,s=c>>>13,O0=J[1]|0,h=O0&8191,d=O0>>>13,g0=J[2]|0,Q0=g0&8191,$0=g0>>>13,m=J[3]|0,p=m&8191,b=m>>>13,N0=J[4]|0,i=N0&8191,e=N0>>>13,t=J[5]|0,n=t&8191,X0=t>>>13,H0=J[6]|0,Z0=H0&8191,W0=H0>>>13,c0=J[7]|0,G0=c0&8191,A0=c0>>>13,u0=J[8]|0,J0=u0&8191,T0=u0>>>13,r0=J[9]|0,E0=r0&8191,v0=r0>>>13,AU=Y[0]|0,k0=AU&8191,j0=AU>>>13,DU=Y[1]|0,R0=DU&8191,S0=DU>>>13,LU=Y[2]|0,P0=LU&8191,D0=LU>>>13,zU=Y[3]|0,B0=zU&8191,L0=zU>>>13,EU=Y[4]|0,_=EU&8191,w=EU>>>13,_0=Y[5]|0,U0=_0&8191,I0=_0>>>13,l0=Y[6]|0,F0=l0&8191,C0=l0>>>13,CU=Y[7]|0,x0=CU&8191,q0=CU>>>13,TU=Y[8]|0,z0=TU&8191,M0=TU>>>13,t0=Y[9]|0,p0=t0&8191,f0=t0>>>13;K.negative=I.negative^$.negative,K.length=19,v=Math.imul(l,k0),T=Math.imul(l,j0),T=T+Math.imul(s,k0)|0,B=Math.imul(s,j0);var b0=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(b0>>>26)|0,b0&=67108863,v=Math.imul(h,k0),T=Math.imul(h,j0),T=T+Math.imul(d,k0)|0,B=Math.imul(d,j0),v=v+Math.imul(l,R0)|0,T=T+Math.imul(l,S0)|0,T=T+Math.imul(s,R0)|0,B=B+Math.imul(s,S0)|0;var a0=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(a0>>>26)|0,a0&=67108863,v=Math.imul(Q0,k0),T=Math.imul(Q0,j0),T=T+Math.imul($0,k0)|0,B=Math.imul($0,j0),v=v+Math.imul(h,R0)|0,T=T+Math.imul(h,S0)|0,T=T+Math.imul(d,R0)|0,B=B+Math.imul(d,S0)|0,v=v+Math.imul(l,P0)|0,T=T+Math.imul(l,D0)|0,T=T+Math.imul(s,P0)|0,B=B+Math.imul(s,D0)|0;var e0=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(e0>>>26)|0,e0&=67108863,v=Math.imul(p,k0),T=Math.imul(p,j0),T=T+Math.imul(b,k0)|0,B=Math.imul(b,j0),v=v+Math.imul(Q0,R0)|0,T=T+Math.imul(Q0,S0)|0,T=T+Math.imul($0,R0)|0,B=B+Math.imul($0,S0)|0,v=v+Math.imul(h,P0)|0,T=T+Math.imul(h,D0)|0,T=T+Math.imul(d,P0)|0,B=B+Math.imul(d,D0)|0,v=v+Math.imul(l,B0)|0,T=T+Math.imul(l,L0)|0,T=T+Math.imul(s,B0)|0,B=B+Math.imul(s,L0)|0;var i0=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(i0>>>26)|0,i0&=67108863,v=Math.imul(i,k0),T=Math.imul(i,j0),T=T+Math.imul(e,k0)|0,B=Math.imul(e,j0),v=v+Math.imul(p,R0)|0,T=T+Math.imul(p,S0)|0,T=T+Math.imul(b,R0)|0,B=B+Math.imul(b,S0)|0,v=v+Math.imul(Q0,P0)|0,T=T+Math.imul(Q0,D0)|0,T=T+Math.imul($0,P0)|0,B=B+Math.imul($0,D0)|0,v=v+Math.imul(h,B0)|0,T=T+Math.imul(h,L0)|0,T=T+Math.imul(d,B0)|0,B=B+Math.imul(d,L0)|0,v=v+Math.imul(l,_)|0,T=T+Math.imul(l,w)|0,T=T+Math.imul(s,_)|0,B=B+Math.imul(s,w)|0;var UU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(UU>>>26)|0,UU&=67108863,v=Math.imul(n,k0),T=Math.imul(n,j0),T=T+Math.imul(X0,k0)|0,B=Math.imul(X0,j0),v=v+Math.imul(i,R0)|0,T=T+Math.imul(i,S0)|0,T=T+Math.imul(e,R0)|0,B=B+Math.imul(e,S0)|0,v=v+Math.imul(p,P0)|0,T=T+Math.imul(p,D0)|0,T=T+Math.imul(b,P0)|0,B=B+Math.imul(b,D0)|0,v=v+Math.imul(Q0,B0)|0,T=T+Math.imul(Q0,L0)|0,T=T+Math.imul($0,B0)|0,B=B+Math.imul($0,L0)|0,v=v+Math.imul(h,_)|0,T=T+Math.imul(h,w)|0,T=T+Math.imul(d,_)|0,B=B+Math.imul(d,w)|0,v=v+Math.imul(l,U0)|0,T=T+Math.imul(l,I0)|0,T=T+Math.imul(s,U0)|0,B=B+Math.imul(s,I0)|0;var XU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(XU>>>26)|0,XU&=67108863,v=Math.imul(Z0,k0),T=Math.imul(Z0,j0),T=T+Math.imul(W0,k0)|0,B=Math.imul(W0,j0),v=v+Math.imul(n,R0)|0,T=T+Math.imul(n,S0)|0,T=T+Math.imul(X0,R0)|0,B=B+Math.imul(X0,S0)|0,v=v+Math.imul(i,P0)|0,T=T+Math.imul(i,D0)|0,T=T+Math.imul(e,P0)|0,B=B+Math.imul(e,D0)|0,v=v+Math.imul(p,B0)|0,T=T+Math.imul(p,L0)|0,T=T+Math.imul(b,B0)|0,B=B+Math.imul(b,L0)|0,v=v+Math.imul(Q0,_)|0,T=T+Math.imul(Q0,w)|0,T=T+Math.imul($0,_)|0,B=B+Math.imul($0,w)|0,v=v+Math.imul(h,U0)|0,T=T+Math.imul(h,I0)|0,T=T+Math.imul(d,U0)|0,B=B+Math.imul(d,I0)|0,v=v+Math.imul(l,F0)|0,T=T+Math.imul(l,C0)|0,T=T+Math.imul(s,F0)|0,B=B+Math.imul(s,C0)|0;var IU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(IU>>>26)|0,IU&=67108863,v=Math.imul(G0,k0),T=Math.imul(G0,j0),T=T+Math.imul(A0,k0)|0,B=Math.imul(A0,j0),v=v+Math.imul(Z0,R0)|0,T=T+Math.imul(Z0,S0)|0,T=T+Math.imul(W0,R0)|0,B=B+Math.imul(W0,S0)|0,v=v+Math.imul(n,P0)|0,T=T+Math.imul(n,D0)|0,T=T+Math.imul(X0,P0)|0,B=B+Math.imul(X0,D0)|0,v=v+Math.imul(i,B0)|0,T=T+Math.imul(i,L0)|0,T=T+Math.imul(e,B0)|0,B=B+Math.imul(e,L0)|0,v=v+Math.imul(p,_)|0,T=T+Math.imul(p,w)|0,T=T+Math.imul(b,_)|0,B=B+Math.imul(b,w)|0,v=v+Math.imul(Q0,U0)|0,T=T+Math.imul(Q0,I0)|0,T=T+Math.imul($0,U0)|0,B=B+Math.imul($0,I0)|0,v=v+Math.imul(h,F0)|0,T=T+Math.imul(h,C0)|0,T=T+Math.imul(d,F0)|0,B=B+Math.imul(d,C0)|0,v=v+Math.imul(l,x0)|0,T=T+Math.imul(l,q0)|0,T=T+Math.imul(s,x0)|0,B=B+Math.imul(s,q0)|0;var ZU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,v=Math.imul(J0,k0),T=Math.imul(J0,j0),T=T+Math.imul(T0,k0)|0,B=Math.imul(T0,j0),v=v+Math.imul(G0,R0)|0,T=T+Math.imul(G0,S0)|0,T=T+Math.imul(A0,R0)|0,B=B+Math.imul(A0,S0)|0,v=v+Math.imul(Z0,P0)|0,T=T+Math.imul(Z0,D0)|0,T=T+Math.imul(W0,P0)|0,B=B+Math.imul(W0,D0)|0,v=v+Math.imul(n,B0)|0,T=T+Math.imul(n,L0)|0,T=T+Math.imul(X0,B0)|0,B=B+Math.imul(X0,L0)|0,v=v+Math.imul(i,_)|0,T=T+Math.imul(i,w)|0,T=T+Math.imul(e,_)|0,B=B+Math.imul(e,w)|0,v=v+Math.imul(p,U0)|0,T=T+Math.imul(p,I0)|0,T=T+Math.imul(b,U0)|0,B=B+Math.imul(b,I0)|0,v=v+Math.imul(Q0,F0)|0,T=T+Math.imul(Q0,C0)|0,T=T+Math.imul($0,F0)|0,B=B+Math.imul($0,C0)|0,v=v+Math.imul(h,x0)|0,T=T+Math.imul(h,q0)|0,T=T+Math.imul(d,x0)|0,B=B+Math.imul(d,q0)|0,v=v+Math.imul(l,z0)|0,T=T+Math.imul(l,M0)|0,T=T+Math.imul(s,z0)|0,B=B+Math.imul(s,M0)|0;var QU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(QU>>>26)|0,QU&=67108863,v=Math.imul(E0,k0),T=Math.imul(E0,j0),T=T+Math.imul(v0,k0)|0,B=Math.imul(v0,j0),v=v+Math.imul(J0,R0)|0,T=T+Math.imul(J0,S0)|0,T=T+Math.imul(T0,R0)|0,B=B+Math.imul(T0,S0)|0,v=v+Math.imul(G0,P0)|0,T=T+Math.imul(G0,D0)|0,T=T+Math.imul(A0,P0)|0,B=B+Math.imul(A0,D0)|0,v=v+Math.imul(Z0,B0)|0,T=T+Math.imul(Z0,L0)|0,T=T+Math.imul(W0,B0)|0,B=B+Math.imul(W0,L0)|0,v=v+Math.imul(n,_)|0,T=T+Math.imul(n,w)|0,T=T+Math.imul(X0,_)|0,B=B+Math.imul(X0,w)|0,v=v+Math.imul(i,U0)|0,T=T+Math.imul(i,I0)|0,T=T+Math.imul(e,U0)|0,B=B+Math.imul(e,I0)|0,v=v+Math.imul(p,F0)|0,T=T+Math.imul(p,C0)|0,T=T+Math.imul(b,F0)|0,B=B+Math.imul(b,C0)|0,v=v+Math.imul(Q0,x0)|0,T=T+Math.imul(Q0,q0)|0,T=T+Math.imul($0,x0)|0,B=B+Math.imul($0,q0)|0,v=v+Math.imul(h,z0)|0,T=T+Math.imul(h,M0)|0,T=T+Math.imul(d,z0)|0,B=B+Math.imul(d,M0)|0,v=v+Math.imul(l,p0)|0,T=T+Math.imul(l,f0)|0,T=T+Math.imul(s,p0)|0,B=B+Math.imul(s,f0)|0;var $U=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+($U>>>26)|0,$U&=67108863,v=Math.imul(E0,R0),T=Math.imul(E0,S0),T=T+Math.imul(v0,R0)|0,B=Math.imul(v0,S0),v=v+Math.imul(J0,P0)|0,T=T+Math.imul(J0,D0)|0,T=T+Math.imul(T0,P0)|0,B=B+Math.imul(T0,D0)|0,v=v+Math.imul(G0,B0)|0,T=T+Math.imul(G0,L0)|0,T=T+Math.imul(A0,B0)|0,B=B+Math.imul(A0,L0)|0,v=v+Math.imul(Z0,_)|0,T=T+Math.imul(Z0,w)|0,T=T+Math.imul(W0,_)|0,B=B+Math.imul(W0,w)|0,v=v+Math.imul(n,U0)|0,T=T+Math.imul(n,I0)|0,T=T+Math.imul(X0,U0)|0,B=B+Math.imul(X0,I0)|0,v=v+Math.imul(i,F0)|0,T=T+Math.imul(i,C0)|0,T=T+Math.imul(e,F0)|0,B=B+Math.imul(e,C0)|0,v=v+Math.imul(p,x0)|0,T=T+Math.imul(p,q0)|0,T=T+Math.imul(b,x0)|0,B=B+Math.imul(b,q0)|0,v=v+Math.imul(Q0,z0)|0,T=T+Math.imul(Q0,M0)|0,T=T+Math.imul($0,z0)|0,B=B+Math.imul($0,M0)|0,v=v+Math.imul(h,p0)|0,T=T+Math.imul(h,f0)|0,T=T+Math.imul(d,p0)|0,B=B+Math.imul(d,f0)|0;var YU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(YU>>>26)|0,YU&=67108863,v=Math.imul(E0,P0),T=Math.imul(E0,D0),T=T+Math.imul(v0,P0)|0,B=Math.imul(v0,D0),v=v+Math.imul(J0,B0)|0,T=T+Math.imul(J0,L0)|0,T=T+Math.imul(T0,B0)|0,B=B+Math.imul(T0,L0)|0,v=v+Math.imul(G0,_)|0,T=T+Math.imul(G0,w)|0,T=T+Math.imul(A0,_)|0,B=B+Math.imul(A0,w)|0,v=v+Math.imul(Z0,U0)|0,T=T+Math.imul(Z0,I0)|0,T=T+Math.imul(W0,U0)|0,B=B+Math.imul(W0,I0)|0,v=v+Math.imul(n,F0)|0,T=T+Math.imul(n,C0)|0,T=T+Math.imul(X0,F0)|0,B=B+Math.imul(X0,C0)|0,v=v+Math.imul(i,x0)|0,T=T+Math.imul(i,q0)|0,T=T+Math.imul(e,x0)|0,B=B+Math.imul(e,q0)|0,v=v+Math.imul(p,z0)|0,T=T+Math.imul(p,M0)|0,T=T+Math.imul(b,z0)|0,B=B+Math.imul(b,M0)|0,v=v+Math.imul(Q0,p0)|0,T=T+Math.imul(Q0,f0)|0,T=T+Math.imul($0,p0)|0,B=B+Math.imul($0,f0)|0;var VU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(VU>>>26)|0,VU&=67108863,v=Math.imul(E0,B0),T=Math.imul(E0,L0),T=T+Math.imul(v0,B0)|0,B=Math.imul(v0,L0),v=v+Math.imul(J0,_)|0,T=T+Math.imul(J0,w)|0,T=T+Math.imul(T0,_)|0,B=B+Math.imul(T0,w)|0,v=v+Math.imul(G0,U0)|0,T=T+Math.imul(G0,I0)|0,T=T+Math.imul(A0,U0)|0,B=B+Math.imul(A0,I0)|0,v=v+Math.imul(Z0,F0)|0,T=T+Math.imul(Z0,C0)|0,T=T+Math.imul(W0,F0)|0,B=B+Math.imul(W0,C0)|0,v=v+Math.imul(n,x0)|0,T=T+Math.imul(n,q0)|0,T=T+Math.imul(X0,x0)|0,B=B+Math.imul(X0,q0)|0,v=v+Math.imul(i,z0)|0,T=T+Math.imul(i,M0)|0,T=T+Math.imul(e,z0)|0,B=B+Math.imul(e,M0)|0,v=v+Math.imul(p,p0)|0,T=T+Math.imul(p,f0)|0,T=T+Math.imul(b,p0)|0,B=B+Math.imul(b,f0)|0;var OU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(OU>>>26)|0,OU&=67108863,v=Math.imul(E0,_),T=Math.imul(E0,w),T=T+Math.imul(v0,_)|0,B=Math.imul(v0,w),v=v+Math.imul(J0,U0)|0,T=T+Math.imul(J0,I0)|0,T=T+Math.imul(T0,U0)|0,B=B+Math.imul(T0,I0)|0,v=v+Math.imul(G0,F0)|0,T=T+Math.imul(G0,C0)|0,T=T+Math.imul(A0,F0)|0,B=B+Math.imul(A0,C0)|0,v=v+Math.imul(Z0,x0)|0,T=T+Math.imul(Z0,q0)|0,T=T+Math.imul(W0,x0)|0,B=B+Math.imul(W0,q0)|0,v=v+Math.imul(n,z0)|0,T=T+Math.imul(n,M0)|0,T=T+Math.imul(X0,z0)|0,B=B+Math.imul(X0,M0)|0,v=v+Math.imul(i,p0)|0,T=T+Math.imul(i,f0)|0,T=T+Math.imul(e,p0)|0,B=B+Math.imul(e,f0)|0;var GU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(GU>>>26)|0,GU&=67108863,v=Math.imul(E0,U0),T=Math.imul(E0,I0),T=T+Math.imul(v0,U0)|0,B=Math.imul(v0,I0),v=v+Math.imul(J0,F0)|0,T=T+Math.imul(J0,C0)|0,T=T+Math.imul(T0,F0)|0,B=B+Math.imul(T0,C0)|0,v=v+Math.imul(G0,x0)|0,T=T+Math.imul(G0,q0)|0,T=T+Math.imul(A0,x0)|0,B=B+Math.imul(A0,q0)|0,v=v+Math.imul(Z0,z0)|0,T=T+Math.imul(Z0,M0)|0,T=T+Math.imul(W0,z0)|0,B=B+Math.imul(W0,M0)|0,v=v+Math.imul(n,p0)|0,T=T+Math.imul(n,f0)|0,T=T+Math.imul(X0,p0)|0,B=B+Math.imul(X0,f0)|0;var KU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(KU>>>26)|0,KU&=67108863,v=Math.imul(E0,F0),T=Math.imul(E0,C0),T=T+Math.imul(v0,F0)|0,B=Math.imul(v0,C0),v=v+Math.imul(J0,x0)|0,T=T+Math.imul(J0,q0)|0,T=T+Math.imul(T0,x0)|0,B=B+Math.imul(T0,q0)|0,v=v+Math.imul(G0,z0)|0,T=T+Math.imul(G0,M0)|0,T=T+Math.imul(A0,z0)|0,B=B+Math.imul(A0,M0)|0,v=v+Math.imul(Z0,p0)|0,T=T+Math.imul(Z0,f0)|0,T=T+Math.imul(W0,p0)|0,B=B+Math.imul(W0,f0)|0;var WU=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(WU>>>26)|0,WU&=67108863,v=Math.imul(E0,x0),T=Math.imul(E0,q0),T=T+Math.imul(v0,x0)|0,B=Math.imul(v0,q0),v=v+Math.imul(J0,z0)|0,T=T+Math.imul(J0,M0)|0,T=T+Math.imul(T0,z0)|0,B=B+Math.imul(T0,M0)|0,v=v+Math.imul(G0,p0)|0,T=T+Math.imul(G0,f0)|0,T=T+Math.imul(A0,p0)|0,B=B+Math.imul(A0,f0)|0;var yX=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(yX>>>26)|0,yX&=67108863,v=Math.imul(E0,z0),T=Math.imul(E0,M0),T=T+Math.imul(v0,z0)|0,B=Math.imul(v0,M0),v=v+Math.imul(J0,p0)|0,T=T+Math.imul(J0,f0)|0,T=T+Math.imul(T0,p0)|0,B=B+Math.imul(T0,f0)|0;var fX=(O+v|0)+((T&8191)<<13)|0;O=(B+(T>>>13)|0)+(fX>>>26)|0,fX&=67108863,v=Math.imul(E0,p0),T=Math.imul(E0,f0),T=T+Math.imul(v0,p0)|0,B=Math.imul(v0,f0);var cX=(O+v|0)+((T&8191)<<13)|0;if(O=(B+(T>>>13)|0)+(cX>>>26)|0,cX&=67108863,X[0]=b0,X[1]=a0,X[2]=e0,X[3]=i0,X[4]=UU,X[5]=XU,X[6]=IU,X[7]=ZU,X[8]=QU,X[9]=$U,X[10]=YU,X[11]=VU,X[12]=OU,X[13]=GU,X[14]=KU,X[15]=WU,X[16]=yX,X[17]=fX,X[18]=cX,O!==0)X[19]=O,K.length++;return K};if(!Math.imul)N=g;function y(Q,I,$){$.negative=I.negative^Q.negative,$.length=Q.length+I.length;var K=0,J=0;for(var Y=0;Y<$.length-1;Y++){var X=J;J=0;var O=K&67108863,v=Math.min(Y,I.length-1);for(var T=Math.max(0,Y-Q.length+1);T<=v;T++){var B=Y-T,c=Q.words[B]|0,l=I.words[T]|0,s=c*l,O0=s&67108863;X=X+(s/67108864|0)|0,O0=O0+O|0,O=O0&67108863,X=X+(O0>>>26)|0,J+=X>>>26,X&=67108863}$.words[Y]=O,K=X,X=J}if(K!==0)$.words[Y]=K;else $.length--;return $._strip()}function f(Q,I,$){return y(Q,I,$)}V.prototype.mulTo=function Q(I,$){var K,J=this.length+I.length;if(this.length===10&&I.length===10)K=N(this,I,$);else if(J<63)K=g(this,I,$);else if(J<1024)K=y(this,I,$);else K=f(this,I,$);return K};function o(Q,I){this.x=Q,this.y=I}o.prototype.makeRBT=function Q(I){var $=new Array(I),K=V.prototype._countBits(I)-1;for(var J=0;J<I;J++)$[J]=this.revBin(J,K,I);return $},o.prototype.revBin=function Q(I,$,K){if(I===0||I===K-1)return I;var J=0;for(var Y=0;Y<$;Y++)J|=(I&1)<<$-Y-1,I>>=1;return J},o.prototype.permute=function Q(I,$,K,J,Y,X){for(var O=0;O<X;O++)J[O]=$[I[O]],Y[O]=K[I[O]]},o.prototype.transform=function Q(I,$,K,J,Y,X){this.permute(X,I,$,K,J,Y);for(var O=1;O<Y;O<<=1){var v=O<<1,T=Math.cos(2*Math.PI/v),B=Math.sin(2*Math.PI/v);for(var c=0;c<Y;c+=v){var l=T,s=B;for(var O0=0;O0<O;O0++){var h=K[c+O0],d=J[c+O0],g0=K[c+O0+O],Q0=J[c+O0+O],$0=l*g0-s*Q0;if(Q0=l*Q0+s*g0,g0=$0,K[c+O0]=h+g0,J[c+O0]=d+Q0,K[c+O0+O]=h-g0,J[c+O0+O]=d-Q0,O0!==v)$0=T*l-B*s,s=T*s+B*l,l=$0}}}},o.prototype.guessLen13b=function Q(I,$){var K=Math.max($,I)|1,J=K&1,Y=0;for(K=K/2|0;K;K=K>>>1)Y++;return 1<<Y+1+J},o.prototype.conjugate=function Q(I,$,K){if(K<=1)return;for(var J=0;J<K/2;J++){var Y=I[J];I[J]=I[K-J-1],I[K-J-1]=Y,Y=$[J],$[J]=-$[K-J-1],$[K-J-1]=-Y}},o.prototype.normalize13b=function Q(I,$){var K=0;for(var J=0;J<$/2;J++){var Y=Math.round(I[2*J+1]/$)*8192+Math.round(I[2*J]/$)+K;if(I[J]=Y&67108863,Y<67108864)K=0;else K=Y/67108864|0}return I},o.prototype.convert13b=function Q(I,$,K,J){var Y=0;for(var X=0;X<$;X++)Y=Y+(I[X]|0),K[2*X]=Y&8191,Y=Y>>>13,K[2*X+1]=Y&8191,Y=Y>>>13;for(X=2*$;X<J;++X)K[X]=0;H(Y===0),H((Y&-8192)===0)},o.prototype.stub=function Q(I){var $=new Array(I);for(var K=0;K<I;K++)$[K]=0;return $},o.prototype.mulp=function Q(I,$,K){var J=2*this.guessLen13b(I.length,$.length),Y=this.makeRBT(J),X=this.stub(J),O=new Array(J),v=new Array(J),T=new Array(J),B=new Array(J),c=new Array(J),l=new Array(J),s=K.words;s.length=J,this.convert13b(I.words,I.length,O,J),this.convert13b($.words,$.length,B,J),this.transform(O,X,v,T,J,Y),this.transform(B,X,c,l,J,Y);for(var O0=0;O0<J;O0++){var h=v[O0]*c[O0]-T[O0]*l[O0];T[O0]=v[O0]*l[O0]+T[O0]*c[O0],v[O0]=h}return this.conjugate(v,T,J),this.transform(v,T,s,X,J,Y),this.conjugate(s,X,J),this.normalize13b(s,J),K.negative=I.negative^$.negative,K.length=I.length+$.length,K._strip()},V.prototype.mul=function Q(I){var $=new V(null);return $.words=new Array(this.length+I.length),this.mulTo(I,$)},V.prototype.mulf=function Q(I){var $=new V(null);return $.words=new Array(this.length+I.length),f(this,I,$)},V.prototype.imul=function Q(I){return this.clone().mulTo(I,this)},V.prototype.imuln=function Q(I){var $=I<0;if($)I=-I;H(typeof I==="number"),H(I<67108864);var K=0;for(var J=0;J<this.length;J++){var Y=(this.words[J]|0)*I,X=(Y&67108863)+(K&67108863);K>>=26,K+=Y/67108864|0,K+=X>>>26,this.words[J]=X&67108863}if(K!==0)this.words[J]=K,this.length++;return this.length=I===0?1:this.length,$?this.ineg():this},V.prototype.muln=function Q(I){return this.clone().imuln(I)},V.prototype.sqr=function Q(){return this.mul(this)},V.prototype.isqr=function Q(){return this.imul(this.clone())},V.prototype.pow=function Q(I){var $=x(I);if($.length===0)return new V(1);var K=this;for(var J=0;J<$.length;J++,K=K.sqr())if($[J]!==0)break;if(++J<$.length)for(var Y=K.sqr();J<$.length;J++,Y=Y.sqr()){if($[J]===0)continue;K=K.mul(Y)}return K},V.prototype.iushln=function Q(I){H(typeof I==="number"&&I>=0);var $=I%26,K=(I-$)/26,J=67108863>>>26-$<<26-$,Y;if($!==0){var X=0;for(Y=0;Y<this.length;Y++){var O=this.words[Y]&J,v=(this.words[Y]|0)-O<<$;this.words[Y]=v|X,X=O>>>26-$}if(X)this.words[Y]=X,this.length++}if(K!==0){for(Y=this.length-1;Y>=0;Y--)this.words[Y+K]=this.words[Y];for(Y=0;Y<K;Y++)this.words[Y]=0;this.length+=K}return this._strip()},V.prototype.ishln=function Q(I){return H(this.negative===0),this.iushln(I)},V.prototype.iushrn=function Q(I,$,K){H(typeof I==="number"&&I>=0);var J;if($)J=($-$%26)/26;else J=0;var Y=I%26,X=Math.min((I-Y)/26,this.length),O=67108863^67108863>>>Y<<Y,v=K;if(J-=X,J=Math.max(0,J),v){for(var T=0;T<X;T++)v.words[T]=this.words[T];v.length=X}if(X===0);else if(this.length>X){this.length-=X;for(T=0;T<this.length;T++)this.words[T]=this.words[T+X]}else this.words[0]=0,this.length=1;var B=0;for(T=this.length-1;T>=0&&(B!==0||T>=J);T--){var c=this.words[T]|0;this.words[T]=B<<26-Y|c>>>Y,B=c&O}if(v&&B!==0)v.words[v.length++]=B;if(this.length===0)this.words[0]=0,this.length=1;return this._strip()},V.prototype.ishrn=function Q(I,$,K){return H(this.negative===0),this.iushrn(I,$,K)},V.prototype.shln=function Q(I){return this.clone().ishln(I)},V.prototype.ushln=function Q(I){return this.clone().iushln(I)},V.prototype.shrn=function Q(I){return this.clone().ishrn(I)},V.prototype.ushrn=function Q(I){return this.clone().iushrn(I)},V.prototype.testn=function Q(I){H(typeof I==="number"&&I>=0);var $=I%26,K=(I-$)/26,J=1<<$;if(this.length<=K)return!1;var Y=this.words[K];return!!(Y&J)},V.prototype.imaskn=function Q(I){H(typeof I==="number"&&I>=0);var $=I%26,K=(I-$)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=K)return this;if($!==0)K++;if(this.length=Math.min(K,this.length),$!==0){var J=67108863^67108863>>>$<<$;this.words[this.length-1]&=J}return this._strip()},V.prototype.maskn=function Q(I){return this.clone().imaskn(I)},V.prototype.iaddn=function Q(I){if(H(typeof I==="number"),H(I<67108864),I<0)return this.isubn(-I);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<=I)return this.words[0]=I-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(I),this.negative=1,this}return this._iaddn(I)},V.prototype._iaddn=function Q(I){this.words[0]+=I;for(var $=0;$<this.length&&this.words[$]>=67108864;$++)if(this.words[$]-=67108864,$===this.length-1)this.words[$+1]=1;else this.words[$+1]++;return this.length=Math.max(this.length,$+1),this},V.prototype.isubn=function Q(I){if(H(typeof I==="number"),H(I<67108864),I<0)return this.iaddn(-I);if(this.negative!==0)return this.negative=0,this.iaddn(I),this.negative=1,this;if(this.words[0]-=I,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var $=0;$<this.length&&this.words[$]<0;$++)this.words[$]+=67108864,this.words[$+1]-=1;return this._strip()},V.prototype.addn=function Q(I){return this.clone().iaddn(I)},V.prototype.subn=function Q(I){return this.clone().isubn(I)},V.prototype.iabs=function Q(){return this.negative=0,this},V.prototype.abs=function Q(){return this.clone().iabs()},V.prototype._ishlnsubmul=function Q(I,$,K){var J=I.length+K,Y;this._expand(J);var X,O=0;for(Y=0;Y<I.length;Y++){X=(this.words[Y+K]|0)+O;var v=(I.words[Y]|0)*$;X-=v&67108863,O=(X>>26)-(v/67108864|0),this.words[Y+K]=X&67108863}for(;Y<this.length-K;Y++)X=(this.words[Y+K]|0)+O,O=X>>26,this.words[Y+K]=X&67108863;if(O===0)return this._strip();H(O===-1),O=0;for(Y=0;Y<this.length;Y++)X=-(this.words[Y]|0)+O,O=X>>26,this.words[Y]=X&67108863;return this.negative=1,this._strip()},V.prototype._wordDiv=function Q(I,$){var K=this.length-I.length,J=this.clone(),Y=I,X=Y.words[Y.length-1]|0,O=this._countBits(X);if(K=26-O,K!==0)Y=Y.ushln(K),J.iushln(K),X=Y.words[Y.length-1]|0;var v=J.length-Y.length,T;if($!=="mod"){T=new V(null),T.length=v+1,T.words=new Array(T.length);for(var B=0;B<T.length;B++)T.words[B]=0}var c=J.clone()._ishlnsubmul(Y,1,v);if(c.negative===0){if(J=c,T)T.words[v]=1}for(var l=v-1;l>=0;l--){var s=(J.words[Y.length+l]|0)*67108864+(J.words[Y.length+l-1]|0);s=Math.min(s/X|0,67108863),J._ishlnsubmul(Y,s,l);while(J.negative!==0)if(s--,J.negative=0,J._ishlnsubmul(Y,1,l),!J.isZero())J.negative^=1;if(T)T.words[l]=s}if(T)T._strip();if(J._strip(),$!=="div"&&K!==0)J.iushrn(K);return{div:T||null,mod:J}},V.prototype.divmod=function Q(I,$,K){if(H(!I.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var J,Y,X;if(this.negative!==0&&I.negative===0){if(X=this.neg().divmod(I,$),$!=="mod")J=X.div.neg();if($!=="div"){if(Y=X.mod.neg(),K&&Y.negative!==0)Y.iadd(I)}return{div:J,mod:Y}}if(this.negative===0&&I.negative!==0){if(X=this.divmod(I.neg(),$),$!=="mod")J=X.div.neg();return{div:J,mod:X.mod}}if((this.negative&I.negative)!==0){if(X=this.neg().divmod(I.neg(),$),$!=="div"){if(Y=X.mod.neg(),K&&Y.negative!==0)Y.isub(I)}return{div:X.div,mod:Y}}if(I.length>this.length||this.cmp(I)<0)return{div:new V(0),mod:this};if(I.length===1){if($==="div")return{div:this.divn(I.words[0]),mod:null};if($==="mod")return{div:null,mod:new V(this.modrn(I.words[0]))};return{div:this.divn(I.words[0]),mod:new V(this.modrn(I.words[0]))}}return this._wordDiv(I,$)},V.prototype.div=function Q(I){return this.divmod(I,"div",!1).div},V.prototype.mod=function Q(I){return this.divmod(I,"mod",!1).mod},V.prototype.umod=function Q(I){return this.divmod(I,"mod",!0).mod},V.prototype.divRound=function Q(I){var $=this.divmod(I);if($.mod.isZero())return $.div;var K=$.div.negative!==0?$.mod.isub(I):$.mod,J=I.ushrn(1),Y=I.andln(1),X=K.cmp(J);if(X<0||Y===1&&X===0)return $.div;return $.div.negative!==0?$.div.isubn(1):$.div.iaddn(1)},V.prototype.modrn=function Q(I){var $=I<0;if($)I=-I;H(I<=67108863);var K=67108864%I,J=0;for(var Y=this.length-1;Y>=0;Y--)J=(K*J+(this.words[Y]|0))%I;return $?-J:J},V.prototype.modn=function Q(I){return this.modrn(I)},V.prototype.idivn=function Q(I){var $=I<0;if($)I=-I;H(I<=67108863);var K=0;for(var J=this.length-1;J>=0;J--){var Y=(this.words[J]|0)+K*67108864;this.words[J]=Y/I|0,K=Y%I}return this._strip(),$?this.ineg():this},V.prototype.divn=function Q(I){return this.clone().idivn(I)},V.prototype.egcd=function Q(I){H(I.negative===0),H(!I.isZero());var $=this,K=I.clone();if($.negative!==0)$=$.umod(I);else $=$.clone();var J=new V(1),Y=new V(0),X=new V(0),O=new V(1),v=0;while($.isEven()&&K.isEven())$.iushrn(1),K.iushrn(1),++v;var T=K.clone(),B=$.clone();while(!$.isZero()){for(var c=0,l=1;($.words[0]&l)===0&&c<26;++c,l<<=1);if(c>0){$.iushrn(c);while(c-- >0){if(J.isOdd()||Y.isOdd())J.iadd(T),Y.isub(B);J.iushrn(1),Y.iushrn(1)}}for(var s=0,O0=1;(K.words[0]&O0)===0&&s<26;++s,O0<<=1);if(s>0){K.iushrn(s);while(s-- >0){if(X.isOdd()||O.isOdd())X.iadd(T),O.isub(B);X.iushrn(1),O.iushrn(1)}}if($.cmp(K)>=0)$.isub(K),J.isub(X),Y.isub(O);else K.isub($),X.isub(J),O.isub(Y)}return{a:X,b:O,gcd:K.iushln(v)}},V.prototype._invmp=function Q(I){H(I.negative===0),H(!I.isZero());var $=this,K=I.clone();if($.negative!==0)$=$.umod(I);else $=$.clone();var J=new V(1),Y=new V(0),X=K.clone();while($.cmpn(1)>0&&K.cmpn(1)>0){for(var O=0,v=1;($.words[0]&v)===0&&O<26;++O,v<<=1);if(O>0){$.iushrn(O);while(O-- >0){if(J.isOdd())J.iadd(X);J.iushrn(1)}}for(var T=0,B=1;(K.words[0]&B)===0&&T<26;++T,B<<=1);if(T>0){K.iushrn(T);while(T-- >0){if(Y.isOdd())Y.iadd(X);Y.iushrn(1)}}if($.cmp(K)>=0)$.isub(K),J.isub(Y);else K.isub($),Y.isub(J)}var c;if($.cmpn(1)===0)c=J;else c=Y;if(c.cmpn(0)<0)c.iadd(I);return c},V.prototype.gcd=function Q(I){if(this.isZero())return I.abs();if(I.isZero())return this.abs();var $=this.clone(),K=I.clone();$.negative=0,K.negative=0;for(var J=0;$.isEven()&&K.isEven();J++)$.iushrn(1),K.iushrn(1);do{while($.isEven())$.iushrn(1);while(K.isEven())K.iushrn(1);var Y=$.cmp(K);if(Y<0){var X=$;$=K,K=X}else if(Y===0||K.cmpn(1)===0)break;$.isub(K)}while(!0);return K.iushln(J)},V.prototype.invm=function Q(I){return this.egcd(I).a.umod(I)},V.prototype.isEven=function Q(){return(this.words[0]&1)===0},V.prototype.isOdd=function Q(){return(this.words[0]&1)===1},V.prototype.andln=function Q(I){return this.words[0]&I},V.prototype.bincn=function Q(I){H(typeof I==="number");var $=I%26,K=(I-$)/26,J=1<<$;if(this.length<=K)return this._expand(K+1),this.words[K]|=J,this;var Y=J;for(var X=K;Y!==0&&X<this.length;X++){var O=this.words[X]|0;O+=Y,Y=O>>>26,O&=67108863,this.words[X]=O}if(Y!==0)this.words[X]=Y,this.length++;return this},V.prototype.isZero=function Q(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function Q(I){var $=I<0;if(this.negative!==0&&!$)return-1;if(this.negative===0&&$)return 1;this._strip();var K;if(this.length>1)K=1;else{if($)I=-I;H(I<=67108863,"Number is too big");var J=this.words[0]|0;K=J===I?0:J<I?-1:1}if(this.negative!==0)return-K|0;return K},V.prototype.cmp=function Q(I){if(this.negative!==0&&I.negative===0)return-1;if(this.negative===0&&I.negative!==0)return 1;var $=this.ucmp(I);if(this.negative!==0)return-$|0;return $},V.prototype.ucmp=function Q(I){if(this.length>I.length)return 1;if(this.length<I.length)return-1;var $=0;for(var K=this.length-1;K>=0;K--){var J=this.words[K]|0,Y=I.words[K]|0;if(J===Y)continue;if(J<Y)$=-1;else if(J>Y)$=1;break}return $},V.prototype.gtn=function Q(I){return this.cmpn(I)===1},V.prototype.gt=function Q(I){return this.cmp(I)===1},V.prototype.gten=function Q(I){return this.cmpn(I)>=0},V.prototype.gte=function Q(I){return this.cmp(I)>=0},V.prototype.ltn=function Q(I){return this.cmpn(I)===-1},V.prototype.lt=function Q(I){return this.cmp(I)===-1},V.prototype.lten=function Q(I){return this.cmpn(I)<=0},V.prototype.lte=function Q(I){return this.cmp(I)<=0},V.prototype.eqn=function Q(I){return this.cmpn(I)===0},V.prototype.eq=function Q(I){return this.cmp(I)===0},V.red=function Q(I){return new U(I)},V.prototype.toRed=function Q(I){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),I.convertTo(this)._forceRed(I)},V.prototype.fromRed=function Q(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function Q(I){return this.red=I,this},V.prototype.forceRed=function Q(I){return H(!this.red,"Already a number in reduction context"),this._forceRed(I)},V.prototype.redAdd=function Q(I){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,I)},V.prototype.redIAdd=function Q(I){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,I)},V.prototype.redSub=function Q(I){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,I)},V.prototype.redISub=function Q(I){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,I)},V.prototype.redShl=function Q(I){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,I)},V.prototype.redMul=function Q(I){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,I),this.red.mul(this,I)},V.prototype.redIMul=function Q(I){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,I),this.red.imul(this,I)},V.prototype.redSqr=function Q(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function Q(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function Q(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function Q(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function Q(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function Q(I){return H(this.red&&!I.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,I)};var r={k256:null,p224:null,p192:null,p25519:null};function V0(Q,I){this.name=Q,this.p=new V(I,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}V0.prototype._tmp=function Q(){var I=new V(null);return I.words=new Array(Math.ceil(this.n/13)),I},V0.prototype.ireduce=function Q(I){var $=I,K;do this.split($,this.tmp),$=this.imulK($),$=$.iadd(this.tmp),K=$.bitLength();while(K>this.n);var J=K<this.n?-1:$.ucmp(this.p);if(J===0)$.words[0]=0,$.length=1;else if(J>0)$.isub(this.p);else if($.strip!==void 0)$.strip();else $._strip();return $},V0.prototype.split=function Q(I,$){I.iushrn(this.n,0,$)},V0.prototype.imulK=function Q(I){return I.imul(this.k)};function Y0(){V0.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}z(Y0,V0),Y0.prototype.split=function Q(I,$){var K=4194303,J=Math.min(I.length,9);for(var Y=0;Y<J;Y++)$.words[Y]=I.words[Y];if($.length=J,I.length<=9){I.words[0]=0,I.length=1;return}var X=I.words[9];$.words[$.length++]=X&K;for(Y=10;Y<I.length;Y++){var O=I.words[Y]|0;I.words[Y-10]=(O&K)<<4|X>>>22,X=O}if(X>>>=22,I.words[Y-10]=X,X===0&&I.length>10)I.length-=10;else I.length-=9},Y0.prototype.imulK=function Q(I){I.words[I.length]=0,I.words[I.length+1]=0,I.length+=2;var $=0;for(var K=0;K<I.length;K++){var J=I.words[K]|0;$+=J*977,I.words[K]=$&67108863,$=J*64+($/67108864|0)}if(I.words[I.length-1]===0){if(I.length--,I.words[I.length-1]===0)I.length--}return I};function u(){V0.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}z(u,V0);function a(){V0.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}z(a,V0);function F(){V0.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}z(F,V0),F.prototype.imulK=function Q(I){var $=0;for(var K=0;K<I.length;K++){var J=(I.words[K]|0)*19+$,Y=J&67108863;J>>>=26,I.words[K]=Y,$=J}if($!==0)I.words[I.length++]=$;return I},V._prime=function Q(I){if(r[I])return r[I];var $;if(I==="k256")$=new Y0;else if(I==="p224")$=new u;else if(I==="p192")$=new a;else if(I==="p25519")$=new F;else throw new Error("Unknown prime "+I);return r[I]=$,$};function U(Q){if(typeof Q==="string"){var I=V._prime(Q);this.m=I.p,this.prime=I}else H(Q.gtn(1),"modulus must be greater than 1"),this.m=Q,this.prime=null}U.prototype._verify1=function Q(I){H(I.negative===0,"red works only with positives"),H(I.red,"red works only with red numbers")},U.prototype._verify2=function Q(I,$){H((I.negative|$.negative)===0,"red works only with positives"),H(I.red&&I.red===$.red,"red works only with red numbers")},U.prototype.imod=function Q(I){if(this.prime)return this.prime.ireduce(I)._forceRed(this);return D(I,I.umod(this.m)._forceRed(this)),I},U.prototype.neg=function Q(I){if(I.isZero())return I.clone();return this.m.sub(I)._forceRed(this)},U.prototype.add=function Q(I,$){this._verify2(I,$);var K=I.add($);if(K.cmp(this.m)>=0)K.isub(this.m);return K._forceRed(this)},U.prototype.iadd=function Q(I,$){this._verify2(I,$);var K=I.iadd($);if(K.cmp(this.m)>=0)K.isub(this.m);return K},U.prototype.sub=function Q(I,$){this._verify2(I,$);var K=I.sub($);if(K.cmpn(0)<0)K.iadd(this.m);return K._forceRed(this)},U.prototype.isub=function Q(I,$){this._verify2(I,$);var K=I.isub($);if(K.cmpn(0)<0)K.iadd(this.m);return K},U.prototype.shl=function Q(I,$){return this._verify1(I),this.imod(I.ushln($))},U.prototype.imul=function Q(I,$){return this._verify2(I,$),this.imod(I.imul($))},U.prototype.mul=function Q(I,$){return this._verify2(I,$),this.imod(I.mul($))},U.prototype.isqr=function Q(I){return this.imul(I,I.clone())},U.prototype.sqr=function Q(I){return this.mul(I,I)},U.prototype.sqrt=function Q(I){if(I.isZero())return I.clone();var $=this.m.andln(3);if(H($%2===1),$===3){var K=this.m.add(new V(1)).iushrn(2);return this.pow(I,K)}var J=this.m.subn(1),Y=0;while(!J.isZero()&&J.andln(1)===0)Y++,J.iushrn(1);H(!J.isZero());var X=new V(1).toRed(this),O=X.redNeg(),v=this.m.subn(1).iushrn(1),T=this.m.bitLength();T=new V(2*T*T).toRed(this);while(this.pow(T,v).cmp(O)!==0)T.redIAdd(O);var B=this.pow(T,J),c=this.pow(I,J.addn(1).iushrn(1)),l=this.pow(I,J),s=Y;while(l.cmp(X)!==0){var O0=l;for(var h=0;O0.cmp(X)!==0;h++)O0=O0.redSqr();H(h<s);var d=this.pow(B,new V(1).iushln(s-h-1));c=c.redMul(d),B=d.redSqr(),l=l.redMul(B),s=h}return c},U.prototype.invm=function Q(I){var $=I._invmp(this.m);if($.negative!==0)return $.negative=0,this.imod($).redNeg();else return this.imod($)},U.prototype.pow=function Q(I,$){if($.isZero())return new V(1).toRed(this);if($.cmpn(1)===0)return I.clone();var K=4,J=new Array(1<<K);J[0]=new V(1).toRed(this),J[1]=I;for(var Y=2;Y<J.length;Y++)J[Y]=this.mul(J[Y-1],I);var X=J[0],O=0,v=0,T=$.bitLength()%26;if(T===0)T=26;for(Y=$.length-1;Y>=0;Y--){var B=$.words[Y];for(var c=T-1;c>=0;c--){var l=B>>c&1;if(X!==J[0])X=this.sqr(X);if(l===0&&O===0){v=0;continue}if(O<<=1,O|=l,v++,v!==K&&(Y!==0||c!==0))continue;X=this.mul(X,J[O]),v=0,O=0}T=26}return X},U.prototype.convertTo=function Q(I){var $=I.umod(this.m);return $===I?$.clone():$},U.prototype.convertFrom=function Q(I){var $=I.clone();return $.red=null,$},V.mont=function Q(I){return new Z(I)};function Z(Q){if(U.call(this,Q),this.shift=this.m.bitLength(),this.shift%26!==0)this.shift+=26-this.shift%26;this.r=new V(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}z(Z,U),Z.prototype.convertTo=function Q(I){return this.imod(I.ushln(this.shift))},Z.prototype.convertFrom=function Q(I){var $=this.imod(I.mul(this.rinv));return $.red=null,$},Z.prototype.imul=function Q(I,$){if(I.isZero()||$.isZero())return I.words[0]=0,I.length=1,I;var K=I.imul($),J=K.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=K.isub(J).iushrn(this.shift),X=Y;if(Y.cmp(this.m)>=0)X=Y.isub(this.m);else if(Y.cmpn(0)<0)X=Y.iadd(this.m);return X._forceRed(this)},Z.prototype.mul=function Q(I,$){if(I.isZero()||$.isZero())return new V(0)._forceRed(this);var K=I.mul($),J=K.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=K.isub(J).iushrn(this.shift),X=Y;if(Y.cmp(this.m)>=0)X=Y.isub(this.m);else if(Y.cmpn(0)<0)X=Y.iadd(this.m);return X._forceRed(this)},Z.prototype.invm=function Q(I){var $=this.imod(I._invmp(this.m).mul(this.r2));return $._forceRed(this)}})(typeof G==="undefined"||G,E)}),yZ=w0((E,G)=>{var W=QV(),C=gX(),H=PU().Buffer;function z(k){var R=k.modulus.byteLength(),S;do S=new W(C(R));while(S.cmp(k.modulus)>=0||!S.umod(k.prime1)||!S.umod(k.prime2));return S}function V(k){var R=z(k),S=R.toRed(W.mont(k.modulus)).redPow(new W(k.publicExponent)).fromRed();return{blinder:S,unblinder:R.invm(k.modulus)}}function P(k,R){var S=V(R),D=R.modulus.byteLength(),A=new W(k).mul(S.blinder).umod(R.modulus),L=A.toRed(W.mont(R.prime1)),M=A.toRed(W.mont(R.prime2)),q=R.coefficient,j=R.prime1,x=R.prime2,g=L.redPow(R.exponent1).fromRed(),N=M.redPow(R.exponent2).fromRed(),y=g.isub(N).imul(q).umod(j).imul(x);return N.iadd(y).imul(S.unblinder).umod(R.modulus).toArrayLike(H,"be",D)}P.getr=z,G.exports=P}),$V=w0((E,G)=>{var W=gZ(),C=gX(),H=NX(),z=NZ(),V=_Z(),P=AI(),k=wZ(),R=yZ(),S=PU().Buffer;G.exports=function M(q,j,x){var g;if(q.padding)g=q.padding;else if(x)g=1;else g=4;var N=W(q),y;if(g===4)y=D(N,j);else if(g===1)y=A(N,j,x);else if(g===3){if(y=new P(j),y.cmp(N.modulus)>=0)throw new Error("data too long for modulus")}else throw new Error("unknown padding");if(x)return R(y,N);else return k(y,N)};function D(M,q){var j=M.modulus.byteLength(),x=q.length,g=H("sha1").update(S.alloc(0)).digest(),N=g.length,y=2*N;if(x>j-y-2)throw new Error("message too long");var f=S.alloc(j-x-y-2),o=j-N-1,r=C(N),V0=V(S.concat([g,f,S.alloc(1,1),q],o),z(r,o)),Y0=V(r,z(V0,N));return new P(S.concat([S.alloc(1),Y0,V0],j))}function A(M,q,j){var x=q.length,g=M.modulus.byteLength();if(x>g-11)throw new Error("message too long");var N;if(j)N=S.alloc(g-x-3,255);else N=L(g-x-3);return new P(S.concat([S.from([0,j?1:2]),N,S.alloc(1),q],g))}function L(M){var q=S.allocUnsafe(M),j=0,x=C(M*2),g=0,N;while(j<M){if(g===x.length)x=C(M*2),g=0;if(N=x[g++],N)q[j++]=N}return q}}),YV=w0((E,G)=>{var W=gZ(),C=NZ(),H=_Z(),z=AI(),V=yZ(),P=NX(),k=wZ(),R=PU().Buffer;G.exports=function L(M,q,j){var x;if(M.padding)x=M.padding;else if(j)x=1;else x=4;var g=W(M),N=g.modulus.byteLength();if(q.length>N||new z(q).cmp(g.modulus)>=0)throw new Error("decryption error");var y;if(j)y=k(new z(q),g);else y=V(q,g);var f=R.alloc(N-y.length);if(y=R.concat([f,y],N),x===4)return S(g,y);else if(x===1)return D(g,y,j);else if(x===3)return y;else throw new Error("unknown padding")};function S(L,M){var q=L.modulus.byteLength(),j=P("sha1").update(R.alloc(0)).digest(),x=j.length;if(M[0]!==0)throw new Error("decryption error");var g=M.slice(1,x+1),N=M.slice(x+1),y=H(g,C(N,x)),f=H(N,C(y,q-x-1));if(A(j,f.slice(0,x)))throw new Error("decryption error");var o=x;while(f[o]===0)o++;if(f[o++]!==1)throw new Error("decryption error");return f.slice(o)}function D(L,M,q){var j=M.slice(0,2),x=2,g=0;while(M[x++]!==0)if(x>=M.length){g++;break}var N=M.slice(2,x-1);if(j.toString("hex")!=="0002"&&!q||j.toString("hex")!=="0001"&&q)g++;if(N.length<8)g++;if(g)throw new Error("decryption error");return M.slice(x)}function A(L,M){L=R.from(L),M=R.from(M);var q=0,j=L.length;if(L.length!==M.length)q++,j=Math.min(L.length,M.length);var x=-1;while(++x<j)q+=L[x]^M[x];return q}}),GI=w0((E)=>{E.publicEncrypt=$V(),E.privateDecrypt=YV(),E.privateEncrypt=function G(W,C){return E.publicEncrypt(W,C,!0)},E.publicDecrypt=function G(W,C){return E.privateDecrypt(W,C,!0)}}),VV=w0((E)=>{var G=(vU(),y0(qU));if(typeof G.publicEncrypt!=="function")G=GI();if(E.publicEncrypt=G.publicEncrypt,E.privateDecrypt=G.privateDecrypt,typeof G.privateEncrypt!=="function")E.privateEncrypt=GI().privateEncrypt;else E.privateEncrypt=G.privateEncrypt;if(typeof G.publicDecrypt!=="function")E.publicDecrypt=GI().publicDecrypt;else E.publicDecrypt=G.publicDecrypt}),OV=w0((E)=>{var G=PU(),W=gX(),C=G.Buffer,H=G.kMaxLength,z=global.crypto||global.msCrypto,V=Math.pow(2,32)-1;function P(A,L){if(typeof A!=="number"||A!==A)throw new TypeError("offset must be a number");if(A>V||A<0)throw new TypeError("offset must be a uint32");if(A>H||A>L)throw new RangeError("offset out of range")}function k(A,L,M){if(typeof A!=="number"||A!==A)throw new TypeError("size must be a number");if(A>V||A<0)throw new TypeError("size must be a uint32");if(A+L>M||A>H)throw new RangeError("buffer too small")}z&&z.getRandomValues,E.randomFill=R,E.randomFillSync=D;function R(A,L,M,q){if(!C.isBuffer(A)&&!(A instanceof global.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof L==="function")q=L,L=0,M=A.length;else if(typeof M==="function")q=M,M=A.length-L;else if(typeof q!=="function")throw new TypeError('"cb" argument must be a function');return P(L,A.length),k(M,L,A.length),S(A,L,M,q)}function S(A,L,M,q){if(!1)var j,x;if(q){W(M,function(N,y){if(N)return q(N);y.copy(A,L),q(null,A)});return}var g=W(M);return g.copy(A,L),A}function D(A,L,M){if(typeof L==="undefined")L=0;if(!C.isBuffer(A)&&!(A instanceof global.Uint8Array))throw new TypeError('"buf" argument must be a Buffer or Uint8Array');if(P(L,A.length),M===void 0)M=A.length-L;return k(M,L,A.length),S(A,L,M)}}),GV=w0((E,G)=>{var W=(vU(),y0(qU));if(typeof W.randomFill==="function"&&typeof W.randomFillSync==="function")E.randomFill=W.randomFill,E.randomFillSync=W.randomFillSync;else G.exports=OV()}),KV=w0((E)=>{E.randomBytes=E.rng=E.pseudoRandomBytes=E.prng=gX(),E.createHash=E.Hash=NX(),E.createHmac=E.Hmac=DZ();var G=HY(),W=Object.keys(G),C=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(W);E.getHashes=function(){return C};var H=zZ();E.pbkdf2=H.pbkdf2,E.pbkdf2Sync=H.pbkdf2Sync;var z=EY();E.Cipher=z.Cipher,E.createCipher=z.createCipher,E.Cipheriv=z.Cipheriv,E.createCipheriv=z.createCipheriv,E.Decipher=z.Decipher,E.createDecipher=z.createDecipher,E.Decipheriv=z.Decipheriv,E.createDecipheriv=z.createDecipheriv,E.getCiphers=z.getCiphers,E.listCiphers=z.listCiphers;var V=CY();E.DiffieHellmanGroup=V.DiffieHellmanGroup,E.createDiffieHellmanGroup=V.createDiffieHellmanGroup,E.getDiffieHellman=V.getDiffieHellman,E.createDiffieHellman=V.createDiffieHellman,E.DiffieHellman=V.DiffieHellman;var P=TY();E.createSign=P.createSign,E.Sign=P.Sign,E.createVerify=P.createVerify,E.Verify=P.Verify,E.createECDH=uY();var k=VV();E.publicEncrypt=k.publicEncrypt,E.privateEncrypt=k.privateEncrypt,E.publicDecrypt=k.publicDecrypt,E.privateDecrypt=k.privateDecrypt;var R=GV();E.randomFill=R.randomFill,E.randomFillSync=R.randomFillSync,E.createCredentials=function(){throw new Error(`sorry, createCredentials is not implemented yet
15
+ we accept pull requests
16
+ https://github.com/browserify/crypto-browserify`)},E.constants={DH_CHECK_P_NOT_SAFE_PRIME:2,DH_CHECK_P_NOT_PRIME:1,DH_UNABLE_TO_CHECK_GENERATOR:4,DH_NOT_SUITABLE_GENERATOR:8,NPN_ENABLED:1,ALPN_ENABLED:1,RSA_PKCS1_PADDING:1,RSA_SSLV23_PADDING:2,RSA_NO_PADDING:3,RSA_PKCS1_OAEP_PADDING:4,RSA_X931_PADDING:5,RSA_PKCS1_PSS_PADDING:6,POINT_CONVERSION_COMPRESSED:2,POINT_CONVERSION_UNCOMPRESSED:4,POINT_CONVERSION_HYBRID:6}}),h0=FY(KV(),1),WV=h0.default.prng,JV=h0.default.pseudoRandomBytes,FV=h0.default.rng,wX=h0.default.randomBytes,HV=h0.default.Hash,AV=h0.default.createHash,EV=h0.default.Hmac,CV=h0.default.createHmac,TV=h0.default.getHashes,EI=h0.default.pbkdf2,DV=h0.default.pbkdf2Sync,LV=h0.default.Cipher,zV=h0.default.createCipher,MV=h0.default.Cipheriv,CI=h0.default.createCipheriv,RV=h0.default.Decipher,SV=h0.default.createDecipher,PV=h0.default.Decipheriv,TI=h0.default.createDecipheriv,qV=h0.default.getCiphers,vV=h0.default.listCiphers,kV=h0.default.DiffieHellmanGroup,jV=h0.default.createDiffieHellmanGroup,BV=h0.default.getDiffieHellman,xV=h0.default.createDiffieHellman,gV=h0.default.DiffieHellman,NV=h0.default.createSign,_V=h0.default.Sign,wV=h0.default.createVerify,yV=h0.default.Verify,fV=h0.default.createECDH,cV=h0.default.publicEncrypt,pV=h0.default.privateEncrypt,hV=h0.default.publicDecrypt,uV=h0.default.privateDecrypt,lV=h0.default.randomFill,dV=h0.default.randomFillSync,bV=h0.default.createCredentials,oV=h0.default.constants,tV=["p192","p224","p256","p384","p521","curve25519","ed25519","secp256k1","secp224r1","prime256v1","prime192v1","ed25519","secp384r1","secp521r1"];aV=crypto});vU();import{generateMnemonic as eV,validateMnemonic as iV}from"@scure/bip39";import{wordlist as fZ}from"@scure/bip39/wordlists/english";import DI from"blakejs";var cZ=(E)=>{let G=E;if(!(G instanceof Buffer))G=Buffer.from(G,"hex");let W=DI.blake2bInit(32);return DI.blake2bUpdate(W,G),Array.from(DI.blake2bFinal(W)).map((C)=>C<16?`0${C.toString(16)}`:C.toString(16)).join("")},pZ=(E,G,W,C,H)=>new Promise((z,V)=>{EI(E,G,W,C,H,(P,k)=>{if(P)V(P);else z(k)})}),EO=async(E,G)=>{let W=wX(32),C=wX(16),H={c:262144,prf:"hmac-sha256",dklen:32,salt:W.toString("hex")},z="aes-128-ctr",V=await pZ(Buffer.from(G),W,H.c,H.dklen,"sha256"),P=CI("aes-128-ctr",V.subarray(0,16),C),k=Buffer.concat([P.update(Buffer.from(E,"utf8")),P.final()]);return{meta:"xchain-keystore",version:1,crypto:{cipher:"aes-128-ctr",cipherparams:{iv:C.toString("hex")},ciphertext:k.toString("hex"),kdf:"pbkdf2",kdfparams:H,mac:cZ(Buffer.concat([V.subarray(16,32),Buffer.from(k)]))}}},CO=(E=12)=>{return eV(fZ,E===12?128:256)},TO=(E)=>{return iV(E,fZ)},DO=async(E,G)=>{switch(E.version){case 1:{let W=E.crypto.kdfparams,C=await pZ(Buffer.from(G),Buffer.from(W.salt,"hex"),W.c,W.dklen,"sha256"),H=Buffer.from(E.crypto.ciphertext,"hex");if(cZ(Buffer.concat([C.subarray(16,32),H]))!==E.crypto.mac)throw new Error("Invalid password");let V=TI(E.crypto.cipher,C.subarray(0,16),Buffer.from(E.crypto.cipherparams.iv,"hex"));return Buffer.concat([V.update(H),V.final()]).toString("utf8")}default:throw new Error("Unsupported keystore version")}};import{Chain as o0,CosmosChains as UO,EVMChains as XO,NetworkDerivationPath as IO,UTXOChains as ZO,WalletOption as hZ,derivationPathToString as QO,filterSupportedChains as $O,getRPCUrl as uZ,pickEvmApiKey as YO,setRequestClientConfig as VO,updatedLastIndex as OO}from"@swapkit/helpers";var GO=[...XO,...ZO,...UO,o0.Polkadot,o0.Chainflip,o0.Solana,o0.Ripple],KO=async({apis:E,rpcUrl:G,chain:W,phrase:C,ethplorerApiKey:H,covalentApiKey:z,blockchairApiKey:V,swapkitApiKey:P,derivationPath:k,stagenet:R})=>{switch(W){case o0.Arbitrum:case o0.Avalanche:case o0.Base:case o0.BinanceSmartChain:case o0.Ethereum:case o0.Optimism:case o0.Polygon:{let{getProvider:S,getToolboxByChain:D}=await import("@swapkit/toolbox-evm"),{HDNodeWallet:A}=await import("./chunk-54v0n09z.js"),L=E?.[W],M=YO({chain:W,nonEthApiKey:z,ethApiKey:H}),q=S(W,G),j=A.fromPhrase(C).connect(q),x={api:L,apiKey:M,provider:q,signer:j};return{address:j.address,walletMethods:D(W)(x)}}case o0.BitcoinCash:{let q=function({builder:x,utxos:g}){return g.forEach((N,y)=>{x.sign(y,L,void 0,65,N.witnessUtxo.value)}),x.build()},{BCHToolbox:S}=await import("@swapkit/toolbox-utxo"),D=E?.[W],A=S({rpcUrl:G,apiKey:V,apiClient:D}),L=await A.createKeysForPath({phrase:C,derivationPath:k}),M=A.getAddressFromKeys(L),j={...A,transfer:(x)=>A.transfer({...x,from:M,signTransaction:q})};return{address:M,walletMethods:j}}case o0.Bitcoin:case o0.Dash:case o0.Dogecoin:case o0.Litecoin:{let{getToolboxByChain:S}=await import("@swapkit/toolbox-utxo"),D=E?.[W],A=S(W)({rpcUrl:G,apiKey:V,apiClient:D}),L=A.createKeysForPath({phrase:C,derivationPath:k}),M=A.getAddressFromKeys(L);return{address:M,walletMethods:{...A,transfer:(q)=>A.transfer({...q,from:M,signTransaction:(j)=>j.signAllInputs(L)})}}}case o0.Cosmos:case o0.Kujira:{let{getToolboxByChain:S}=await import("@swapkit/toolbox-cosmos"),D=E?.[W],A=S(W)({server:D,stagenet:R,swapkitApiKey:P}),L=await A.getAddressFromMnemonic(C),M=await A.getSigner(C);return{address:L,walletMethods:{...A,transfer:(j)=>A.transfer({...j,signer:M})}}}case o0.Maya:case o0.THORChain:{let{getToolboxByChain:S}=await import("@swapkit/toolbox-cosmos"),D=E?.[W],A=S(W)({server:D,stagenet:R}),L=await A.getSigner(C),M=await A.getAddressFromMnemonic(C);return{address:M,walletMethods:{...A,deposit:({assetValue:q,memo:j})=>A.deposit({assetValue:q,memo:j,from:M,signer:L}),transfer:(q)=>A.transfer({...q,from:M,signer:L}),signMessage:async(q)=>{let j=await A.createPrivateKeyFromPhrase(C);return A.signWithPrivateKey({privateKey:j,message:q})}}}}case o0.Polkadot:case o0.Chainflip:{let{Network:S,getToolboxByChain:D,createKeyring:A}=await import("@swapkit/toolbox-substrate"),L=await A(C,S[W].prefix),M=await D(W,{signer:L,providerUrl:W===o0.Polkadot?uZ(o0.Polkadot):uZ(o0.Chainflip)});return{address:L.address,walletMethods:M}}case o0.Solana:{let{SOLToolbox:S,createKeysForPath:D}=await import("@swapkit/toolbox-solana"),A=D({phrase:C,derivationPath:k}),L=S({rpcUrl:G,signer:A});return{address:L.getAddressFromKeys(A),walletMethods:{...L}}}case o0.Ripple:{let{XRPToolbox:S,createSigner:D}=await import("@swapkit/toolbox-ripple"),A=D(C),L=S({rpcUrl:G,signer:A});return{address:A.address,walletMethods:{...L}}}default:throw new Error(`Unsupported chain ${W}`)}};function WO({addChain:E,apis:G,rpcUrls:W,config:{thorswapApiKey:C,covalentApiKey:H,ethplorerApiKey:z,blockchairApiKey:V,stagenet:P,swapkitApiKey:k}}){return async function R(S,D,A){VO({apiKey:C});let M=$O(S,GO,hZ.KEYSTORE).map(async(q)=>{let j=typeof A==="number"?A:0,x=A&&typeof A==="object"?A[q]:void 0,[g,N,y,f,o]=IO[q],r=x||OO(q===o0.Solana?[g,N,y,f]:[g,N,y,f,o],j),V0=QO(r),{address:Y0,walletMethods:u}=await KO({derivationPath:V0,chain:q,apis:G,rpcUrl:W[q],covalentApiKey:H,ethplorerApiKey:z,phrase:D,blockchairApiKey:V,swapkitApiKey:k,stagenet:P});E({...u,chain:q,address:Y0,balance:[],walletType:hZ.KEYSTORE})});return await Promise.all(M),!0}}var JO={connectKeystore:WO};export{TO as validatePhrase,JO as keystoreWallet,CO as generatePhrase,EO as encryptToKeyStore,DO as decryptFromKeystore};
12
17
 
13
- //# debugId=A37ADB500479B93F64756E2164756E21
18
+ //# debugId=6227B5F88C8CEE6364756E2164756E21