@swapkit/wallet-hardware 5.0.1 → 6.0.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/THIRD_PARTY_LICENSES.md +2344 -0
- package/dist/chunk-09e51wma.js +4 -0
- package/dist/chunk-09e51wma.js.map +167 -0
- package/dist/chunk-0arpsm5f.js +4 -0
- package/dist/chunk-0arpsm5f.js.map +10 -0
- package/dist/chunk-1amf58aq.js +4 -0
- package/dist/{chunk-xkh15edk.js.map → chunk-1amf58aq.js.map} +2 -2
- package/dist/chunk-3t17wpjg.js +17 -0
- package/dist/chunk-3t17wpjg.js.map +29 -0
- package/dist/chunk-5c7b7z2d.js +4 -0
- package/dist/{chunk-20wx60bn.js.map → chunk-5c7b7z2d.js.map} +2 -2
- package/dist/chunk-5p3ttw6y.js +4 -0
- package/dist/{chunk-1jpcb30j.js.map → chunk-5p3ttw6y.js.map} +1 -1
- package/dist/chunk-dptbnkzm.js +64 -0
- package/dist/chunk-dptbnkzm.js.map +260 -0
- package/dist/chunk-ds2m83jp.js +5 -0
- package/dist/chunk-ds2m83jp.js.map +11 -0
- package/dist/chunk-eenx3cv6.js +4 -0
- package/dist/chunk-eenx3cv6.js.map +33 -0
- package/dist/chunk-gr3eswf1.js +4 -0
- package/dist/chunk-gr3eswf1.js.map +73 -0
- package/dist/{chunk-7fsaymh4.js → chunk-hg71hp4m.js} +3 -3
- package/dist/{chunk-7fsaymh4.js.map → chunk-hg71hp4m.js.map} +1 -1
- package/dist/chunk-jewm2ag3.js +5 -0
- package/dist/{chunk-4tbtxdxa.js.map → chunk-jewm2ag3.js.map} +2 -2
- package/dist/chunk-jzrytcrf.js +4 -0
- package/dist/chunk-jzrytcrf.js.map +12 -0
- package/dist/chunk-k3thje6a.js +4 -0
- package/dist/chunk-k3thje6a.js.map +9 -0
- package/dist/chunk-nhva847d.js +5 -0
- package/dist/chunk-nhva847d.js.map +9 -0
- package/dist/chunk-tm47brht.js +4 -0
- package/dist/chunk-tm47brht.js.map +140 -0
- package/dist/chunk-xmvg4cds.js +4 -0
- package/dist/chunk-xmvg4cds.js.map +127 -0
- package/dist/chunk-xx7cwpzq.js +4 -0
- package/dist/chunk-xx7cwpzq.js.map +9 -0
- package/dist/chunk-yrxe491r.js +20 -0
- package/dist/chunk-yrxe491r.js.map +17 -0
- package/dist/index.cjs +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/keepkey/index.cjs +2 -2
- package/dist/keepkey/index.cjs.map +2 -2
- package/dist/keepkey/index.js +2 -2
- package/dist/keepkey/index.js.map +2 -2
- package/dist/ledger/index.cjs +90 -2
- package/dist/ledger/index.cjs.map +830 -24
- package/dist/ledger/index.js +2 -2
- package/dist/ledger/index.js.map +21 -19
- package/dist/trezor/index.cjs +2 -2
- package/dist/trezor/index.cjs.map +5 -5
- package/dist/trezor/index.js +2 -2
- package/dist/trezor/index.js.map +3 -3
- package/dist/types/ledger/clients/bitcoin.d.ts +36 -0
- package/dist/types/ledger/clients/bitcoin.d.ts.map +1 -0
- package/dist/types/ledger/clients/cosmos.d.ts +38 -10
- package/dist/types/ledger/clients/cosmos.d.ts.map +1 -1
- package/dist/types/ledger/clients/evm.d.ts +37 -46
- package/dist/types/ledger/clients/evm.d.ts.map +1 -1
- package/dist/types/ledger/clients/near.d.ts +5 -2
- package/dist/types/ledger/clients/near.d.ts.map +1 -1
- package/dist/types/ledger/clients/sui.d.ts +8 -12
- package/dist/types/ledger/clients/sui.d.ts.map +1 -1
- package/dist/types/ledger/clients/thorchain/index.d.ts +34 -8
- package/dist/types/ledger/clients/thorchain/index.d.ts.map +1 -1
- package/dist/types/ledger/clients/thorchain/protocol.d.ts +58 -0
- package/dist/types/ledger/clients/thorchain/protocol.d.ts.map +1 -0
- package/dist/types/ledger/clients/tron.d.ts +11 -8
- package/dist/types/ledger/clients/tron.d.ts.map +1 -1
- package/dist/types/ledger/clients/utxo-legacy-adapter.d.ts +3 -2
- package/dist/types/ledger/clients/utxo-legacy-adapter.d.ts.map +1 -1
- package/dist/types/ledger/clients/utxo-legacy-outputs.d.ts +18 -0
- package/dist/types/ledger/clients/utxo-legacy-outputs.d.ts.map +1 -0
- package/dist/types/ledger/clients/utxo.d.ts +10 -13
- package/dist/types/ledger/clients/utxo.d.ts.map +1 -1
- package/dist/types/ledger/clients/xrp.d.ts +4 -1
- package/dist/types/ledger/clients/xrp.d.ts.map +1 -1
- package/dist/types/ledger/clients/zcash.d.ts +53 -0
- package/dist/types/ledger/clients/zcash.d.ts.map +1 -0
- package/dist/types/ledger/helpers/dmk.d.ts +24 -0
- package/dist/types/ledger/helpers/dmk.d.ts.map +1 -0
- package/dist/types/ledger/helpers/executeDeviceAction.d.ts +34 -0
- package/dist/types/ledger/helpers/executeDeviceAction.d.ts.map +1 -0
- package/dist/types/ledger/helpers/getLedgerAddress.d.ts +1 -1
- package/dist/types/ledger/helpers/getLedgerAddress.d.ts.map +1 -1
- package/dist/types/ledger/helpers/getLedgerClient.d.ts +10 -3
- package/dist/types/ledger/helpers/getLedgerClient.d.ts.map +1 -1
- package/dist/types/ledger/helpers/index.d.ts +2 -1
- package/dist/types/ledger/helpers/index.d.ts.map +1 -1
- package/dist/types/ledger/helpers/ledgerJsDmkBridge.d.ts +26 -0
- package/dist/types/ledger/helpers/ledgerJsDmkBridge.d.ts.map +1 -0
- package/dist/types/ledger/helpers/ledgerJsDmkTransport.d.ts +13 -0
- package/dist/types/ledger/helpers/ledgerJsDmkTransport.d.ts.map +1 -0
- package/dist/types/ledger/helpers/lowS.d.ts +6 -0
- package/dist/types/ledger/helpers/lowS.d.ts.map +1 -0
- package/dist/types/ledger/helpers/rawTx.d.ts +2 -0
- package/dist/types/ledger/helpers/rawTx.d.ts.map +1 -0
- package/dist/types/ledger/index.d.ts +19 -7
- package/dist/types/ledger/index.d.ts.map +1 -1
- package/dist/types/ledger/types.d.ts +6 -10
- package/dist/types/ledger/types.d.ts.map +1 -1
- package/dist/types/trezor/index.d.ts +2 -2
- package/dist/types/trezor/index.d.ts.map +1 -1
- package/package.json +36 -36
- package/src/ledger/clients/bitcoin.ts +575 -0
- package/src/ledger/clients/cosmos.ts +180 -51
- package/src/ledger/clients/evm.ts +238 -195
- package/src/ledger/clients/near.ts +43 -13
- package/src/ledger/clients/sui.ts +55 -68
- package/src/ledger/clients/thorchain/index.ts +210 -86
- package/src/ledger/clients/thorchain/protocol.ts +166 -0
- package/src/ledger/clients/tron.ts +49 -37
- package/src/ledger/clients/utxo-legacy-adapter.ts +35 -32
- package/src/ledger/clients/utxo-legacy-outputs.ts +122 -0
- package/src/ledger/clients/utxo.ts +108 -206
- package/src/ledger/clients/xrp.ts +39 -23
- package/src/ledger/clients/zcash.ts +440 -0
- package/src/ledger/helpers/dmk.ts +231 -0
- package/src/ledger/helpers/executeDeviceAction.ts +201 -0
- package/src/ledger/helpers/getLedgerClient.ts +101 -72
- package/src/ledger/helpers/index.ts +6 -1
- package/src/ledger/helpers/ledgerJsDmkBridge.ts +109 -0
- package/src/ledger/helpers/ledgerJsDmkTransport.ts +88 -0
- package/src/ledger/helpers/lowS.ts +30 -0
- package/src/ledger/helpers/rawTx.ts +12 -0
- package/src/ledger/index.ts +564 -369
- package/src/ledger/types.ts +15 -10
- package/src/trezor/index.ts +115 -27
- package/dist/chunk-1jpcb30j.js +0 -5
- package/dist/chunk-20wx60bn.js +0 -4
- package/dist/chunk-4tbtxdxa.js +0 -5
- package/dist/chunk-7v7cgm69.js +0 -4
- package/dist/chunk-7v7cgm69.js.map +0 -10
- package/dist/chunk-83g13ck6.js +0 -5
- package/dist/chunk-83g13ck6.js.map +0 -10
- package/dist/chunk-h2r568rz.js +0 -4
- package/dist/chunk-h2r568rz.js.map +0 -10
- package/dist/chunk-xkh15edk.js +0 -4
- package/dist/types/ledger/clients/thorchain/common.d.ts +0 -28
- package/dist/types/ledger/clients/thorchain/common.d.ts.map +0 -1
- package/dist/types/ledger/clients/thorchain/helpers.d.ts +0 -7
- package/dist/types/ledger/clients/thorchain/helpers.d.ts.map +0 -1
- package/dist/types/ledger/clients/thorchain/lib.d.ts +0 -22
- package/dist/types/ledger/clients/thorchain/lib.d.ts.map +0 -1
- package/dist/types/ledger/clients/thorchain/utils.d.ts +0 -2
- package/dist/types/ledger/clients/thorchain/utils.d.ts.map +0 -1
- package/dist/types/ledger/clients/utxo-psbt.d.ts +0 -18
- package/dist/types/ledger/clients/utxo-psbt.d.ts.map +0 -1
- package/dist/types/ledger/cosmosTypes.d.ts +0 -40
- package/dist/types/ledger/cosmosTypes.d.ts.map +0 -1
- package/dist/types/ledger/helpers/getLedgerTransport.d.ts +0 -3
- package/dist/types/ledger/helpers/getLedgerTransport.d.ts.map +0 -1
- package/dist/types/ledger/helpers/ledgerNetworkInfo.d.ts +0 -14
- package/dist/types/ledger/helpers/ledgerNetworkInfo.d.ts.map +0 -1
- package/dist/types/ledger/interfaces/CosmosLedgerInterface.d.ts +0 -14
- package/dist/types/ledger/interfaces/CosmosLedgerInterface.d.ts.map +0 -1
- package/src/ledger/clients/thorchain/common.ts +0 -93
- package/src/ledger/clients/thorchain/helpers.ts +0 -120
- package/src/ledger/clients/thorchain/lib.ts +0 -258
- package/src/ledger/clients/thorchain/utils.ts +0 -69
- package/src/ledger/clients/utxo-psbt.ts +0 -204
- package/src/ledger/cosmosTypes.ts +0 -98
- package/src/ledger/helpers/getLedgerTransport.ts +0 -102
- package/src/ledger/helpers/ledgerNetworkInfo.ts +0 -127
- package/src/ledger/interfaces/CosmosLedgerInterface.ts +0 -67
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import{$d as CQ,Xd as h0,Yd as EX,Zd as $X,_d as KX}from"./chunk-nhva847d.js";var WU={};$X(WU,{transcode:()=>wY,resolveObjectURL:()=>xY,kStringMaxLength:()=>qZ,kMaxLength:()=>rU,isUtf8:()=>NY,isAscii:()=>gY,default:()=>fY,constants:()=>VY,btoa:()=>ZY,atob:()=>QY,INSPECT_MAX_BYTES:()=>RZ,File:()=>YY,Buffer:()=>$0,Blob:()=>JY});function aQ(I){var O=I.length;if(O%4>0)throw Error("Invalid string. Length must be a multiple of 4");var W=I.indexOf("=");if(W===-1)W=O;var T=W===O?0:4-W%4;return[W,T]}function eQ(I,O){return(I+O)*3/4-O}function iQ(I){var O,W=aQ(I),T=W[0],H=W[1],L=new Uint8Array(eQ(T,H)),V=0,P=H>0?T-4:T,S;for(S=0;S<P;S+=4)O=PU[I.charCodeAt(S)]<<18|PU[I.charCodeAt(S+1)]<<12|PU[I.charCodeAt(S+2)]<<6|PU[I.charCodeAt(S+3)],L[V++]=O>>16&255,L[V++]=O>>8&255,L[V++]=O&255;if(H===2)O=PU[I.charCodeAt(S)]<<2|PU[I.charCodeAt(S+1)]>>4,L[V++]=O&255;if(H===1)O=PU[I.charCodeAt(S)]<<10|PU[I.charCodeAt(S+1)]<<4|PU[I.charCodeAt(S+2)]>>2,L[V++]=O>>8&255,L[V++]=O&255;return L}function UY(I){return jU[I>>18&63]+jU[I>>12&63]+jU[I>>6&63]+jU[I&63]}function XY(I,O,W){var T,H=[];for(var L=O;L<W;L+=3)T=(I[L]<<16&16711680)+(I[L+1]<<8&65280)+(I[L+2]&255),H.push(UY(T));return H.join("")}function AZ(I){var O,W=I.length,T=W%3,H=[],L=16383;for(var V=0,P=W-T;V<P;V+=L)H.push(XY(I,V,V+L>P?P:V+L));if(T===1)O=I[W-1],H.push(jU[O>>2]+jU[O<<4&63]+"==");else if(T===2)O=(I[W-2]<<8)+I[W-1],H.push(jU[O>>10]+jU[O>>4&63]+jU[O<<2&63]+"=");return H.join("")}function OX(I,O,W,T,H){var L,V,P=H*8-T-1,S=(1<<P)-1,E=S>>1,C=-7,D=W?H-1:0,z=W?-1:1,R=I[O+D];D+=z,L=R&(1<<-C)-1,R>>=-C,C+=P;for(;C>0;L=L*256+I[O+D],D+=z,C-=8);V=L&(1<<-C)-1,L>>=-C,C+=T;for(;C>0;V=V*256+I[O+D],D+=z,C-=8);if(L===0)L=1-E;else if(L===S)return V?NaN:(R?-1:1)*(1/0);else V=V+Math.pow(2,T),L=L-E;return(R?-1:1)*V*Math.pow(2,L-T)}function MZ(I,O,W,T,H,L){var V,P,S,E=L*8-H-1,C=(1<<E)-1,D=C>>1,z=H===23?Math.pow(2,-24)-Math.pow(2,-77):0,R=T?0:L-1,q=T?1:-1,_=O<0||O===0&&1/O<0?1:0;if(O=Math.abs(O),isNaN(O)||O===1/0)P=isNaN(O)?1:0,V=C;else{if(V=Math.floor(Math.log(O)/Math.LN2),O*(S=Math.pow(2,-V))<1)V--,S*=2;if(V+D>=1)O+=z/S;else O+=z*Math.pow(2,1-D);if(O*S>=2)V++,S/=2;if(V+D>=C)P=0,V=C;else if(V+D>=1)P=(O*S-1)*Math.pow(2,H),V=V+D;else P=O*Math.pow(2,D-1)*Math.pow(2,H),V=0}for(;H>=8;I[W+R]=P&255,R+=q,P/=256,H-=8);V=V<<H|P,E+=H;for(;E>0;I[W+R]=V&255,R+=q,V/=256,E-=8);I[W+R-q]|=_*128}function BU(I){if(I>rU)throw RangeError('The value "'+I+'" is invalid for option "size"');let O=new Uint8Array(I);return Object.setPrototypeOf(O,$0.prototype),O}function pX(I,O,W){return class extends W{constructor(){super();Object.defineProperty(this,"message",{value:O.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${I}]`,this.stack,delete this.name}get code(){return I}set code(T){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:T,writable:!0})}toString(){return`${this.name} [${I}]: ${this.message}`}}}function $0(I,O,W){if(typeof I==="number"){if(typeof O==="string")throw TypeError('The "string" argument must be of type string. Received type number');return hX(I)}return SZ(I,O,W)}function SZ(I,O,W){if(typeof I==="string")return KY(I,O);if(ArrayBuffer.isView(I))return OY(I);if(I==null)throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof I);if(vU(I,ArrayBuffer)||I&&vU(I.buffer,ArrayBuffer))return yX(I,O,W);if(typeof SharedArrayBuffer<"u"&&(vU(I,SharedArrayBuffer)||I&&vU(I.buffer,SharedArrayBuffer)))return yX(I,O,W);if(typeof I==="number")throw TypeError('The "value" argument must not be of type number. Received type number');let T=I.valueOf&&I.valueOf();if(T!=null&&T!==I)return $0.from(T,O,W);let H=FY(I);if(H)return H;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof I[Symbol.toPrimitive]==="function")return $0.from(I[Symbol.toPrimitive]("string"),O,W);throw TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof I)}function PZ(I){if(typeof I!=="number")throw TypeError('"size" argument must be of type number');else if(I<0)throw RangeError('The value "'+I+'" is invalid for option "size"')}function $Y(I,O,W){if(PZ(I),I<=0)return BU(I);if(O!==void 0)return typeof W==="string"?BU(I).fill(O,W):BU(I).fill(O);return BU(I)}function hX(I){return PZ(I),BU(I<0?0:uX(I)|0)}function KY(I,O){if(typeof O!=="string"||O==="")O="utf8";if(!$0.isEncoding(O))throw TypeError("Unknown encoding: "+O);let W=kZ(I,O)|0,T=BU(W),H=T.write(I,O);if(H!==W)T=T.slice(0,H);return T}function fX(I){let O=I.length<0?0:uX(I.length)|0,W=BU(O);for(let T=0;T<O;T+=1)W[T]=I[T]&255;return W}function OY(I){if(vU(I,Uint8Array)){let O=new Uint8Array(I);return yX(O.buffer,O.byteOffset,O.byteLength)}return fX(I)}function yX(I,O,W){if(O<0||I.byteLength<O)throw RangeError('"offset" is outside of buffer bounds');if(I.byteLength<O+(W||0))throw RangeError('"length" is outside of buffer bounds');let T;if(O===void 0&&W===void 0)T=new Uint8Array(I);else if(W===void 0)T=new Uint8Array(I,O);else T=new Uint8Array(I,O,W);return Object.setPrototypeOf(T,$0.prototype),T}function FY(I){if($0.isBuffer(I)){let O=uX(I.length)|0,W=BU(O);if(W.length===0)return W;return I.copy(W,0,0,O),W}if(I.length!==void 0){if(typeof I.length!=="number"||Number.isNaN(I.length))return BU(0);return fX(I)}if(I.type==="Buffer"&&Array.isArray(I.data))return fX(I.data)}function uX(I){if(I>=rU)throw RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+rU.toString(16)+" bytes");return I|0}function kZ(I,O){if($0.isBuffer(I))return I.length;if(ArrayBuffer.isView(I)||vU(I,ArrayBuffer))return I.byteLength;if(typeof I!=="string")throw TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof I);let W=I.length,T=arguments.length>2&&arguments[2]===!0;if(!T&&W===0)return 0;let H=!1;for(;;)switch(O){case"ascii":case"latin1":case"binary":return W;case"utf8":case"utf-8":return cX(I).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return W*2;case"hex":return W>>>1;case"base64":return fZ(I).length;default:if(H)return T?-1:cX(I).length;O=(""+O).toLowerCase(),H=!0}}function WY(I,O,W){let T=!1;if(O===void 0||O<0)O=0;if(O>this.length)return"";if(W===void 0||W>this.length)W=this.length;if(W<=0)return"";if(W>>>=0,O>>>=0,W<=O)return"";if(!I)I="utf8";while(!0)switch(I){case"hex":return RY(this,O,W);case"utf8":case"utf-8":return vZ(this,O,W);case"ascii":return LY(this,O,W);case"latin1":case"binary":return MY(this,O,W);case"base64":return CY(this,O,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return qY(this,O,W);default:if(T)throw TypeError("Unknown encoding: "+I);I=(I+"").toLowerCase(),T=!0}}function hU(I,O,W){let T=I[O];I[O]=I[W],I[W]=T}function jZ(I,O,W,T,H){if(I.length===0)return-1;if(typeof W==="string")T=W,W=0;else if(W>2147483647)W=2147483647;else if(W<-2147483648)W=-2147483648;if(W=+W,Number.isNaN(W))W=H?0:I.length-1;if(W<0)W=I.length+W;if(W>=I.length)if(H)return-1;else W=I.length-1;else if(W<0)if(H)W=0;else return-1;if(typeof O==="string")O=$0.from(O,T);if($0.isBuffer(O)){if(O.length===0)return-1;return CZ(I,O,W,T,H)}else if(typeof O==="number"){if(O=O&255,typeof Uint8Array.prototype.indexOf==="function")if(H)return Uint8Array.prototype.indexOf.call(I,O,W);else return Uint8Array.prototype.lastIndexOf.call(I,O,W);return CZ(I,[O],W,T,H)}throw TypeError("val must be string, number or Buffer")}function CZ(I,O,W,T,H){let L=1,V=I.length,P=O.length;if(T!==void 0){if(T=String(T).toLowerCase(),T==="ucs2"||T==="ucs-2"||T==="utf16le"||T==="utf-16le"){if(I.length<2||O.length<2)return-1;L=2,V/=2,P/=2,W/=2}}function S(C,D){if(L===1)return C[D];else return C.readUInt16BE(D*L)}let E;if(H){let C=-1;for(E=W;E<V;E++)if(S(I,E)===S(O,C===-1?0:E-C)){if(C===-1)C=E;if(E-C+1===P)return C*L}else{if(C!==-1)E-=E-C;C=-1}}else{if(W+P>V)W=V-P;for(E=W;E>=0;E--){let C=!0;for(let D=0;D<P;D++)if(S(I,E+D)!==S(O,D)){C=!1;break}if(C)return E}}return-1}function HY(I,O,W,T){W=Number(W)||0;let H=I.length-W;if(!T)T=H;else if(T=Number(T),T>H)T=H;let L=O.length;if(T>L/2)T=L/2;let V;for(V=0;V<T;++V){let P=parseInt(O.substr(V*2,2),16);if(Number.isNaN(P))return V;I[W+V]=P}return V}function DY(I,O,W,T){return FX(cX(O,I.length-W),I,W,T)}function TY(I,O,W,T){return FX(jY(O),I,W,T)}function AY(I,O,W,T){return FX(fZ(O),I,W,T)}function zY(I,O,W,T){return FX(vY(O,I.length-W),I,W,T)}function CY(I,O,W){if(O===0&&W===I.length)return AZ(I);else return AZ(I.slice(O,W))}function vZ(I,O,W){W=Math.min(I.length,W);let T=[],H=O;while(H<W){let L=I[H],V=null,P=L>239?4:L>223?3:L>191?2:1;if(H+P<=W){let S,E,C,D;switch(P){case 1:if(L<128)V=L;break;case 2:if(S=I[H+1],(S&192)===128){if(D=(L&31)<<6|S&63,D>127)V=D}break;case 3:if(S=I[H+1],E=I[H+2],(S&192)===128&&(E&192)===128){if(D=(L&15)<<12|(S&63)<<6|E&63,D>2047&&(D<55296||D>57343))V=D}break;case 4:if(S=I[H+1],E=I[H+2],C=I[H+3],(S&192)===128&&(E&192)===128&&(C&192)===128){if(D=(L&15)<<18|(S&63)<<12|(E&63)<<6|C&63,D>65535&&D<1114112)V=D}}}if(V===null)V=65533,P=1;else if(V>65535)V-=65536,T.push(V>>>10&1023|55296),V=56320|V&1023;T.push(V),H+=P}return EY(T)}function EY(I){let O=I.length;if(O<=EZ)return String.fromCharCode.apply(String,I);let W="",T=0;while(T<O)W+=String.fromCharCode.apply(String,I.slice(T,T+=EZ));return W}function LY(I,O,W){let T="";W=Math.min(I.length,W);for(let H=O;H<W;++H)T+=String.fromCharCode(I[H]&127);return T}function MY(I,O,W){let T="";W=Math.min(I.length,W);for(let H=O;H<W;++H)T+=String.fromCharCode(I[H]);return T}function RY(I,O,W){let T=I.length;if(!O||O<0)O=0;if(!W||W<0||W>T)W=T;let H="";for(let L=O;L<W;++L)H+=_Y[I[L]];return H}function qY(I,O,W){let T=I.slice(O,W),H="";for(let L=0;L<T.length-1;L+=2)H+=String.fromCharCode(T[L]+T[L+1]*256);return H}function FU(I,O,W){if(I%1!==0||I<0)throw RangeError("offset is not uint");if(I+O>W)throw RangeError("Trying to access beyond buffer length")}function LU(I,O,W,T,H,L){if(!$0.isBuffer(I))throw TypeError('"buffer" argument must be a Buffer instance');if(O>H||O<L)throw RangeError('"value" argument is out of bounds');if(W+T>I.length)throw RangeError("Index out of range")}function _Z(I,O,W,T,H){wZ(O,T,H,I,W,7);let L=Number(O&BigInt(4294967295));I[W++]=L,L=L>>8,I[W++]=L,L=L>>8,I[W++]=L,L=L>>8,I[W++]=L;let V=Number(O>>BigInt(32)&BigInt(4294967295));return I[W++]=V,V=V>>8,I[W++]=V,V=V>>8,I[W++]=V,V=V>>8,I[W++]=V,W}function BZ(I,O,W,T,H){wZ(O,T,H,I,W,7);let L=Number(O&BigInt(4294967295));I[W+7]=L,L=L>>8,I[W+6]=L,L=L>>8,I[W+5]=L,L=L>>8,I[W+4]=L;let V=Number(O>>BigInt(32)&BigInt(4294967295));return I[W+3]=V,V=V>>8,I[W+2]=V,V=V>>8,I[W+1]=V,V=V>>8,I[W]=V,W+8}function xZ(I,O,W,T,H,L){if(W+T>I.length)throw RangeError("Index out of range");if(W<0)throw RangeError("Index out of range")}function NZ(I,O,W,T,H){if(O=+O,W=W>>>0,!H)xZ(I,O,W,4,340282346638528860000000000000000000000,-340282346638528860000000000000000000000);return MZ(I,O,W,T,23,4),W+4}function gZ(I,O,W,T,H){if(O=+O,W=W>>>0,!H)xZ(I,O,W,8,179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000,-179769313486231570000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000);return MZ(I,O,W,T,52,8),W+8}function LZ(I){let O="",W=I.length,T=I[0]==="-"?1:0;for(;W>=T+4;W-=3)O=`_${I.slice(W-3,W)}${O}`;return`${I.slice(0,W)}${O}`}function SY(I,O,W){if(oU(O,"offset"),I[O]===void 0||I[O+W]===void 0)aU(O,I.length-(W+1))}function wZ(I,O,W,T,H,L){if(I>W||I<O){let V=typeof O==="bigint"?"n":"",P;if(L>3)if(O===0||O===BigInt(0))P=`>= 0${V} and < 2${V} ** ${(L+1)*8}${V}`;else P=`>= -(2${V} ** ${(L+1)*8-1}${V}) and < 2 ** ${(L+1)*8-1}${V}`;else P=`>= ${O}${V} and <= ${W}${V}`;throw new wX("value",P,I)}SY(T,H,L)}function oU(I,O){if(typeof I!=="number")throw new IY(O,"number",I)}function aU(I,O,W){if(Math.floor(I)!==I)throw oU(I,W),new wX(W||"offset","an integer",I);if(O<0)throw new GY;throw new wX(W||"offset",`>= ${W?1:0} and <= ${O}`,I)}function kY(I){if(I=I.split("=")[0],I=I.trim().replace(PY,""),I.length<2)return"";while(I.length%4!==0)I=I+"=";return I}function cX(I,O){O=O||1/0;let W,T=I.length,H=null,L=[];for(let V=0;V<T;++V){if(W=I.charCodeAt(V),W>55295&&W<57344){if(!H){if(W>56319){if((O-=3)>-1)L.push(239,191,189);continue}else if(V+1===T){if((O-=3)>-1)L.push(239,191,189);continue}H=W;continue}if(W<56320){if((O-=3)>-1)L.push(239,191,189);H=W;continue}W=(H-55296<<10|W-56320)+65536}else if(H){if((O-=3)>-1)L.push(239,191,189)}if(H=null,W<128){if((O-=1)<0)break;L.push(W)}else if(W<2048){if((O-=2)<0)break;L.push(W>>6|192,W&63|128)}else if(W<65536){if((O-=3)<0)break;L.push(W>>12|224,W>>6&63|128,W&63|128)}else if(W<1114112){if((O-=4)<0)break;L.push(W>>18|240,W>>12&63|128,W>>6&63|128,W&63|128)}else throw Error("Invalid code point")}return L}function jY(I){let O=[];for(let W=0;W<I.length;++W)O.push(I.charCodeAt(W)&255);return O}function vY(I,O){let W,T,H,L=[];for(let V=0;V<I.length;++V){if((O-=2)<0)break;W=I.charCodeAt(V),T=W>>8,H=W%256,L.push(H),L.push(T)}return L}function fZ(I){return iQ(kY(I))}function FX(I,O,W,T){let H;for(H=0;H<T;++H){if(H+W>=O.length||H>=I.length)break;O[H+W]=I[H]}return H}function vU(I,O){return I instanceof O||I!=null&&I.constructor!=null&&I.constructor.name!=null&&I.constructor.name===O.name}function wU(I){return typeof BigInt>"u"?BY:I}function BY(){throw Error("BigInt not supported")}function bX(I){return()=>{throw Error(I+" is not implemented for node:buffer browser polyfill")}}var jU,PU,gX="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",pU,TZ,zZ,RZ=50,rU=2147483647,qZ=536870888,ZY,QY,YY,JY,VY,GY,IY,wX,EZ=4096,PY,_Y,xY,NY,gY=(I)=>{for(let O of I)if(O.charCodeAt(0)>127)return!1;return!0},wY,fY;var HU=KX(()=>{jU=[],PU=[];for(pU=0,TZ=gX.length;pU<TZ;++pU)jU[pU]=gX[pU],PU[gX.charCodeAt(pU)]=pU;PU[45]=62;PU[95]=63;zZ=typeof Symbol==="function"&&typeof Symbol.for==="function"?Symbol.for("nodejs.util.inspect.custom"):null,ZY=globalThis.btoa,QY=globalThis.atob,YY=globalThis.File,JY=globalThis.Blob,VY={MAX_LENGTH:rU,MAX_STRING_LENGTH:qZ};GY=pX("ERR_BUFFER_OUT_OF_BOUNDS",function(I){if(I)return`${I} is outside of buffer bounds`;return"Attempt to access memory outside buffer bounds"},RangeError),IY=pX("ERR_INVALID_ARG_TYPE",function(I,O){return`The "${I}" argument must be of type number. Received type ${typeof O}`},TypeError),wX=pX("ERR_OUT_OF_RANGE",function(I,O,W){let T=`The value of "${I}" is out of range.`,H=W;if(Number.isInteger(W)&&Math.abs(W)>4294967296)H=LZ(String(W));else if(typeof W==="bigint"){if(H=String(W),W>BigInt(2)**BigInt(32)||W<-(BigInt(2)**BigInt(32)))H=LZ(H);H+="n"}return T+=` It must be ${O}. Received ${H}`,T},RangeError);Object.defineProperty($0.prototype,"parent",{enumerable:!0,get:function(){if(!$0.isBuffer(this))return;return this.buffer}});Object.defineProperty($0.prototype,"offset",{enumerable:!0,get:function(){if(!$0.isBuffer(this))return;return this.byteOffset}});$0.poolSize=8192;$0.from=function(I,O,W){return SZ(I,O,W)};Object.setPrototypeOf($0.prototype,Uint8Array.prototype);Object.setPrototypeOf($0,Uint8Array);$0.alloc=function(I,O,W){return $Y(I,O,W)};$0.allocUnsafe=function(I){return hX(I)};$0.allocUnsafeSlow=function(I){return hX(I)};$0.isBuffer=function(I){return I!=null&&I._isBuffer===!0&&I!==$0.prototype};$0.compare=function(I,O){if(vU(I,Uint8Array))I=$0.from(I,I.offset,I.byteLength);if(vU(O,Uint8Array))O=$0.from(O,O.offset,O.byteLength);if(!$0.isBuffer(I)||!$0.isBuffer(O))throw TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(I===O)return 0;let W=I.length,T=O.length;for(let H=0,L=Math.min(W,T);H<L;++H)if(I[H]!==O[H]){W=I[H],T=O[H];break}if(W<T)return-1;if(T<W)return 1;return 0};$0.isEncoding=function(I){switch(String(I).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}};$0.concat=function(I,O){if(!Array.isArray(I))throw TypeError('"list" argument must be an Array of Buffers');if(I.length===0)return $0.alloc(0);let W;if(O===void 0){O=0;for(W=0;W<I.length;++W)O+=I[W].length}let T=$0.allocUnsafe(O),H=0;for(W=0;W<I.length;++W){let L=I[W];if(vU(L,Uint8Array))if(H+L.length>T.length){if(!$0.isBuffer(L))L=$0.from(L);L.copy(T,H)}else Uint8Array.prototype.set.call(T,L,H);else if(!$0.isBuffer(L))throw TypeError('"list" argument must be an Array of Buffers');else L.copy(T,H);H+=L.length}return T};$0.byteLength=kZ;$0.prototype._isBuffer=!0;$0.prototype.swap16=function(){let I=this.length;if(I%2!==0)throw RangeError("Buffer size must be a multiple of 16-bits");for(let O=0;O<I;O+=2)hU(this,O,O+1);return this};$0.prototype.swap32=function(){let I=this.length;if(I%4!==0)throw RangeError("Buffer size must be a multiple of 32-bits");for(let O=0;O<I;O+=4)hU(this,O,O+3),hU(this,O+1,O+2);return this};$0.prototype.swap64=function(){let I=this.length;if(I%8!==0)throw RangeError("Buffer size must be a multiple of 64-bits");for(let O=0;O<I;O+=8)hU(this,O,O+7),hU(this,O+1,O+6),hU(this,O+2,O+5),hU(this,O+3,O+4);return this};$0.prototype.toString=function(){let I=this.length;if(I===0)return"";if(arguments.length===0)return vZ(this,0,I);return WY.apply(this,arguments)};$0.prototype.toLocaleString=$0.prototype.toString;$0.prototype.equals=function(I){if(!$0.isBuffer(I))throw TypeError("Argument must be a Buffer");if(this===I)return!0;return $0.compare(this,I)===0};$0.prototype.inspect=function(){let I="",O=RZ;if(I=this.toString("hex",0,O).replace(/(.{2})/g,"$1 ").trim(),this.length>O)I+=" ... ";return"<Buffer "+I+">"};if(zZ)$0.prototype[zZ]=$0.prototype.inspect;$0.prototype.compare=function(I,O,W,T,H){if(vU(I,Uint8Array))I=$0.from(I,I.offset,I.byteLength);if(!$0.isBuffer(I))throw TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof I);if(O===void 0)O=0;if(W===void 0)W=I?I.length:0;if(T===void 0)T=0;if(H===void 0)H=this.length;if(O<0||W>I.length||T<0||H>this.length)throw RangeError("out of range index");if(T>=H&&O>=W)return 0;if(T>=H)return-1;if(O>=W)return 1;if(O>>>=0,W>>>=0,T>>>=0,H>>>=0,this===I)return 0;let L=H-T,V=W-O,P=Math.min(L,V),S=this.slice(T,H),E=I.slice(O,W);for(let C=0;C<P;++C)if(S[C]!==E[C]){L=S[C],V=E[C];break}if(L<V)return-1;if(V<L)return 1;return 0};$0.prototype.includes=function(I,O,W){return this.indexOf(I,O,W)!==-1};$0.prototype.indexOf=function(I,O,W){return jZ(this,I,O,W,!0)};$0.prototype.lastIndexOf=function(I,O,W){return jZ(this,I,O,W,!1)};$0.prototype.write=function(I,O,W,T){if(O===void 0)T="utf8",W=this.length,O=0;else if(W===void 0&&typeof O==="string")T=O,W=this.length,O=0;else if(isFinite(O))if(O=O>>>0,isFinite(W)){if(W=W>>>0,T===void 0)T="utf8"}else T=W,W=void 0;else throw Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let H=this.length-O;if(W===void 0||W>H)W=H;if(I.length>0&&(W<0||O<0)||O>this.length)throw RangeError("Attempt to write outside buffer bounds");if(!T)T="utf8";let L=!1;for(;;)switch(T){case"hex":return HY(this,I,O,W);case"utf8":case"utf-8":return DY(this,I,O,W);case"ascii":case"latin1":case"binary":return TY(this,I,O,W);case"base64":return AY(this,I,O,W);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return zY(this,I,O,W);default:if(L)throw TypeError("Unknown encoding: "+T);T=(""+T).toLowerCase(),L=!0}};$0.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};$0.prototype.slice=function(I,O){let W=this.length;if(I=~~I,O=O===void 0?W:~~O,I<0){if(I+=W,I<0)I=0}else if(I>W)I=W;if(O<0){if(O+=W,O<0)O=0}else if(O>W)O=W;if(O<I)O=I;let T=this.subarray(I,O);return Object.setPrototypeOf(T,$0.prototype),T};$0.prototype.readUintLE=$0.prototype.readUIntLE=function(I,O,W){if(I=I>>>0,O=O>>>0,!W)FU(I,O,this.length);let T=this[I],H=1,L=0;while(++L<O&&(H*=256))T+=this[I+L]*H;return T};$0.prototype.readUintBE=$0.prototype.readUIntBE=function(I,O,W){if(I=I>>>0,O=O>>>0,!W)FU(I,O,this.length);let T=this[I+--O],H=1;while(O>0&&(H*=256))T+=this[I+--O]*H;return T};$0.prototype.readUint8=$0.prototype.readUInt8=function(I,O){if(I=I>>>0,!O)FU(I,1,this.length);return this[I]};$0.prototype.readUint16LE=$0.prototype.readUInt16LE=function(I,O){if(I=I>>>0,!O)FU(I,2,this.length);return this[I]|this[I+1]<<8};$0.prototype.readUint16BE=$0.prototype.readUInt16BE=function(I,O){if(I=I>>>0,!O)FU(I,2,this.length);return this[I]<<8|this[I+1]};$0.prototype.readUint32LE=$0.prototype.readUInt32LE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return(this[I]|this[I+1]<<8|this[I+2]<<16)+this[I+3]*16777216};$0.prototype.readUint32BE=$0.prototype.readUInt32BE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return this[I]*16777216+(this[I+1]<<16|this[I+2]<<8|this[I+3])};$0.prototype.readBigUInt64LE=wU(function(I){I=I>>>0,oU(I,"offset");let O=this[I],W=this[I+7];if(O===void 0||W===void 0)aU(I,this.length-8);let T=O+this[++I]*256+this[++I]*65536+this[++I]*16777216,H=this[++I]+this[++I]*256+this[++I]*65536+W*16777216;return BigInt(T)+(BigInt(H)<<BigInt(32))});$0.prototype.readBigUInt64BE=wU(function(I){I=I>>>0,oU(I,"offset");let O=this[I],W=this[I+7];if(O===void 0||W===void 0)aU(I,this.length-8);let T=O*16777216+this[++I]*65536+this[++I]*256+this[++I],H=this[++I]*16777216+this[++I]*65536+this[++I]*256+W;return(BigInt(T)<<BigInt(32))+BigInt(H)});$0.prototype.readIntLE=function(I,O,W){if(I=I>>>0,O=O>>>0,!W)FU(I,O,this.length);let T=this[I],H=1,L=0;while(++L<O&&(H*=256))T+=this[I+L]*H;if(H*=128,T>=H)T-=Math.pow(2,8*O);return T};$0.prototype.readIntBE=function(I,O,W){if(I=I>>>0,O=O>>>0,!W)FU(I,O,this.length);let T=O,H=1,L=this[I+--T];while(T>0&&(H*=256))L+=this[I+--T]*H;if(H*=128,L>=H)L-=Math.pow(2,8*O);return L};$0.prototype.readInt8=function(I,O){if(I=I>>>0,!O)FU(I,1,this.length);if(!(this[I]&128))return this[I];return(255-this[I]+1)*-1};$0.prototype.readInt16LE=function(I,O){if(I=I>>>0,!O)FU(I,2,this.length);let W=this[I]|this[I+1]<<8;return W&32768?W|4294901760:W};$0.prototype.readInt16BE=function(I,O){if(I=I>>>0,!O)FU(I,2,this.length);let W=this[I+1]|this[I]<<8;return W&32768?W|4294901760:W};$0.prototype.readInt32LE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return this[I]|this[I+1]<<8|this[I+2]<<16|this[I+3]<<24};$0.prototype.readInt32BE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return this[I]<<24|this[I+1]<<16|this[I+2]<<8|this[I+3]};$0.prototype.readBigInt64LE=wU(function(I){I=I>>>0,oU(I,"offset");let O=this[I],W=this[I+7];if(O===void 0||W===void 0)aU(I,this.length-8);let T=this[I+4]+this[I+5]*256+this[I+6]*65536+(W<<24);return(BigInt(T)<<BigInt(32))+BigInt(O+this[++I]*256+this[++I]*65536+this[++I]*16777216)});$0.prototype.readBigInt64BE=wU(function(I){I=I>>>0,oU(I,"offset");let O=this[I],W=this[I+7];if(O===void 0||W===void 0)aU(I,this.length-8);let T=(O<<24)+this[++I]*65536+this[++I]*256+this[++I];return(BigInt(T)<<BigInt(32))+BigInt(this[++I]*16777216+this[++I]*65536+this[++I]*256+W)});$0.prototype.readFloatLE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return OX(this,I,!0,23,4)};$0.prototype.readFloatBE=function(I,O){if(I=I>>>0,!O)FU(I,4,this.length);return OX(this,I,!1,23,4)};$0.prototype.readDoubleLE=function(I,O){if(I=I>>>0,!O)FU(I,8,this.length);return OX(this,I,!0,52,8)};$0.prototype.readDoubleBE=function(I,O){if(I=I>>>0,!O)FU(I,8,this.length);return OX(this,I,!1,52,8)};$0.prototype.writeUintLE=$0.prototype.writeUIntLE=function(I,O,W,T){if(I=+I,O=O>>>0,W=W>>>0,!T){let V=Math.pow(2,8*W)-1;LU(this,I,O,W,V,0)}let H=1,L=0;this[O]=I&255;while(++L<W&&(H*=256))this[O+L]=I/H&255;return O+W};$0.prototype.writeUintBE=$0.prototype.writeUIntBE=function(I,O,W,T){if(I=+I,O=O>>>0,W=W>>>0,!T){let V=Math.pow(2,8*W)-1;LU(this,I,O,W,V,0)}let H=W-1,L=1;this[O+H]=I&255;while(--H>=0&&(L*=256))this[O+H]=I/L&255;return O+W};$0.prototype.writeUint8=$0.prototype.writeUInt8=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,1,255,0);return this[O]=I&255,O+1};$0.prototype.writeUint16LE=$0.prototype.writeUInt16LE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,2,65535,0);return this[O]=I&255,this[O+1]=I>>>8,O+2};$0.prototype.writeUint16BE=$0.prototype.writeUInt16BE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,2,65535,0);return this[O]=I>>>8,this[O+1]=I&255,O+2};$0.prototype.writeUint32LE=$0.prototype.writeUInt32LE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,4,4294967295,0);return this[O+3]=I>>>24,this[O+2]=I>>>16,this[O+1]=I>>>8,this[O]=I&255,O+4};$0.prototype.writeUint32BE=$0.prototype.writeUInt32BE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,4,4294967295,0);return this[O]=I>>>24,this[O+1]=I>>>16,this[O+2]=I>>>8,this[O+3]=I&255,O+4};$0.prototype.writeBigUInt64LE=wU(function(I,O=0){return _Z(this,I,O,BigInt(0),BigInt("0xffffffffffffffff"))});$0.prototype.writeBigUInt64BE=wU(function(I,O=0){return BZ(this,I,O,BigInt(0),BigInt("0xffffffffffffffff"))});$0.prototype.writeIntLE=function(I,O,W,T){if(I=+I,O=O>>>0,!T){let P=Math.pow(2,8*W-1);LU(this,I,O,W,P-1,-P)}let H=0,L=1,V=0;this[O]=I&255;while(++H<W&&(L*=256)){if(I<0&&V===0&&this[O+H-1]!==0)V=1;this[O+H]=(I/L>>0)-V&255}return O+W};$0.prototype.writeIntBE=function(I,O,W,T){if(I=+I,O=O>>>0,!T){let P=Math.pow(2,8*W-1);LU(this,I,O,W,P-1,-P)}let H=W-1,L=1,V=0;this[O+H]=I&255;while(--H>=0&&(L*=256)){if(I<0&&V===0&&this[O+H+1]!==0)V=1;this[O+H]=(I/L>>0)-V&255}return O+W};$0.prototype.writeInt8=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,1,127,-128);if(I<0)I=255+I+1;return this[O]=I&255,O+1};$0.prototype.writeInt16LE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,2,32767,-32768);return this[O]=I&255,this[O+1]=I>>>8,O+2};$0.prototype.writeInt16BE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,2,32767,-32768);return this[O]=I>>>8,this[O+1]=I&255,O+2};$0.prototype.writeInt32LE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,4,2147483647,-2147483648);return this[O]=I&255,this[O+1]=I>>>8,this[O+2]=I>>>16,this[O+3]=I>>>24,O+4};$0.prototype.writeInt32BE=function(I,O,W){if(I=+I,O=O>>>0,!W)LU(this,I,O,4,2147483647,-2147483648);if(I<0)I=4294967295+I+1;return this[O]=I>>>24,this[O+1]=I>>>16,this[O+2]=I>>>8,this[O+3]=I&255,O+4};$0.prototype.writeBigInt64LE=wU(function(I,O=0){return _Z(this,I,O,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});$0.prototype.writeBigInt64BE=wU(function(I,O=0){return BZ(this,I,O,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});$0.prototype.writeFloatLE=function(I,O,W){return NZ(this,I,O,!0,W)};$0.prototype.writeFloatBE=function(I,O,W){return NZ(this,I,O,!1,W)};$0.prototype.writeDoubleLE=function(I,O,W){return gZ(this,I,O,!0,W)};$0.prototype.writeDoubleBE=function(I,O,W){return gZ(this,I,O,!1,W)};$0.prototype.copy=function(I,O,W,T){if(!$0.isBuffer(I))throw TypeError("argument should be a Buffer");if(!W)W=0;if(!T&&T!==0)T=this.length;if(O>=I.length)O=I.length;if(!O)O=0;if(T>0&&T<W)T=W;if(T===W)return 0;if(I.length===0||this.length===0)return 0;if(O<0)throw RangeError("targetStart out of bounds");if(W<0||W>=this.length)throw RangeError("Index out of range");if(T<0)throw RangeError("sourceEnd out of bounds");if(T>this.length)T=this.length;if(I.length-O<T-W)T=I.length-O+W;let H=T-W;if(this===I&&typeof Uint8Array.prototype.copyWithin==="function")this.copyWithin(O,W,T);else Uint8Array.prototype.set.call(I,this.subarray(W,T),O);return H};$0.prototype.fill=function(I,O,W,T){if(typeof I==="string"){if(typeof O==="string")T=O,O=0,W=this.length;else if(typeof W==="string")T=W,W=this.length;if(T!==void 0&&typeof T!=="string")throw TypeError("encoding must be a string");if(typeof T==="string"&&!$0.isEncoding(T))throw TypeError("Unknown encoding: "+T);if(I.length===1){let L=I.charCodeAt(0);if(T==="utf8"&&L<128||T==="latin1")I=L}}else if(typeof I==="number")I=I&255;else if(typeof I==="boolean")I=Number(I);if(O<0||this.length<O||this.length<W)throw RangeError("Out of range index");if(W<=O)return this;if(O=O>>>0,W=W===void 0?this.length:W>>>0,!I)I=0;let H;if(typeof I==="number")for(H=O;H<W;++H)this[H]=I;else{let L=$0.isBuffer(I)?I:$0.from(I,T),V=L.length;if(V===0)throw TypeError('The value "'+I+'" is invalid for argument "value"');for(H=0;H<W-O;++H)this[H+O]=L[H%V]}return this};PY=/[^+/0-9A-Za-z-_]/g;_Y=function(){let I=Array(256);for(let O=0;O<16;++O){let W=O*16;for(let T=0;T<16;++T)I[W+T]="0123456789abcdef"[O]+"0123456789abcdef"[T]}return I}();xY=bX("resolveObjectURL"),NY=bX("isUtf8"),wY=bX("transcode"),fY=$0});var nZ={};$X(nZ,{types:()=>nY,promisify:()=>bZ,log:()=>pZ,isUndefined:()=>nU,isSymbol:()=>sY,isString:()=>zX,isRegExp:()=>WX,isPrimitive:()=>tY,isObject:()=>mU,isNumber:()=>cZ,isNullOrUndefined:()=>mY,isNull:()=>AX,isFunction:()=>DX,isError:()=>HX,isDate:()=>nX,isBuffer:()=>rY,isBoolean:()=>sX,isArray:()=>yZ,inspect:()=>uU,inherits:()=>hZ,format:()=>mX,deprecate:()=>cY,default:()=>iY,debuglog:()=>pY,callbackifyOnRejected:()=>aX,callbackify:()=>lZ,_extend:()=>rX,TextEncoder:()=>dZ,TextDecoder:()=>oZ});function mX(I,...O){if(!zX(I)){var W=[I];for(var T=0;T<O.length;T++)W.push(uU(O[T]));return W.join(" ")}var T=0,H=O.length,L=String(I).replace(yY,function(P){if(P==="%%")return"%";if(T>=H)return P;switch(P){case"%s":return String(O[T++]);case"%d":return Number(O[T++]);case"%j":try{return JSON.stringify(O[T++])}catch(S){return"[Circular]"}default:return P}});for(var V=O[T];T<H;V=O[++T])if(AX(V)||!mU(V))L+=" "+V;else L+=" "+uU(V);return L}function cY(I,O){if(typeof process>"u"||process?.noDeprecation===!0)return I;var W=!1;function T(...H){if(!W){if(process.throwDeprecation)throw Error(O);else if(process.traceDeprecation)console.trace(O);else console.error(O);W=!0}return I.apply(this,...H)}return T}function hY(I,O){var W=uU.styles[O];if(W)return"\x1B["+uU.colors[W][0]+"m"+I+"\x1B["+uU.colors[W][1]+"m";else return I}function uY(I,O){return I}function bY(I){var O={};return I.forEach(function(W,T){O[W]=!0}),O}function TX(I,O,W){if(I.customInspect&&O&&DX(O.inspect)&&O.inspect!==uU&&!(O.constructor&&O.constructor.prototype===O)){var T=O.inspect(W,I);if(!zX(T))T=TX(I,T,W);return T}var H=lY(I,O);if(H)return H;var L=Object.keys(O),V=bY(L);if(I.showHidden)L=Object.getOwnPropertyNames(O);if(HX(O)&&(L.indexOf("message")>=0||L.indexOf("description")>=0))return lX(O);if(L.length===0){if(DX(O)){var P=O.name?": "+O.name:"";return I.stylize("[Function"+P+"]","special")}if(WX(O))return I.stylize(RegExp.prototype.toString.call(O),"regexp");if(nX(O))return I.stylize(Date.prototype.toString.call(O),"date");if(HX(O))return lX(O)}var S="",E=!1,C=["{","}"];if(yZ(O))E=!0,C=["[","]"];if(DX(O)){var D=O.name?": "+O.name:"";S=" [Function"+D+"]"}if(WX(O))S=" "+RegExp.prototype.toString.call(O);if(nX(O))S=" "+Date.prototype.toUTCString.call(O);if(HX(O))S=" "+lX(O);if(L.length===0&&(!E||O.length==0))return C[0]+S+C[1];if(W<0)if(WX(O))return I.stylize(RegExp.prototype.toString.call(O),"regexp");else return I.stylize("[Object]","special");I.seen.push(O);var z;if(E)z=dY(I,O,W,V,L);else z=L.map(function(R){return oX(I,O,W,V,R,E)});return I.seen.pop(),oY(z,S,C)}function lY(I,O){if(nU(O))return I.stylize("undefined","undefined");if(zX(O)){var W="'"+JSON.stringify(O).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return I.stylize(W,"string")}if(cZ(O))return I.stylize(""+O,"number");if(sX(O))return I.stylize(""+O,"boolean");if(AX(O))return I.stylize("null","null")}function lX(I){return"["+Error.prototype.toString.call(I)+"]"}function dY(I,O,W,T,H){var L=[];for(var V=0,P=O.length;V<P;++V)if(uZ(O,String(V)))L.push(oX(I,O,W,T,String(V),!0));else L.push("");return H.forEach(function(S){if(!S.match(/^\d+$/))L.push(oX(I,O,W,T,S,!0))}),L}function oX(I,O,W,T,H,L){var V,P,S;if(S=Object.getOwnPropertyDescriptor(O,H)||{value:O[H]},S.get)if(S.set)P=I.stylize("[Getter/Setter]","special");else P=I.stylize("[Getter]","special");else if(S.set)P=I.stylize("[Setter]","special");if(!uZ(T,H))V="["+H+"]";if(!P)if(I.seen.indexOf(S.value)<0){if(AX(W))P=TX(I,S.value,null);else P=TX(I,S.value,W-1);if(P.indexOf(`
|
|
2
|
+
`)>-1)if(L)P=P.split(`
|
|
3
|
+
`).map(function(E){return" "+E}).join(`
|
|
4
|
+
`).slice(2);else P=`
|
|
5
|
+
`+P.split(`
|
|
6
|
+
`).map(function(E){return" "+E}).join(`
|
|
7
|
+
`)}else P=I.stylize("[Circular]","special");if(nU(V)){if(L&&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=I.stylize(V,"name");else V=V.replace(/'/g,"\\'").replace(/\\"/g,'"').replace(/(^"|"$)/g,"'"),V=I.stylize(V,"string")}return V+": "+P}function oY(I,O,W){var T=0,H=I.reduce(function(L,V){if(T++,V.indexOf(`
|
|
8
|
+
`)>=0)T++;return L+V.replace(/\u001b\[\d\d?m/g,"").length+1},0);if(H>60)return W[0]+(O===""?"":O+`
|
|
9
|
+
`)+" "+I.join(`,
|
|
10
|
+
`)+" "+W[1];return W[0]+O+" "+I.join(", ")+" "+W[1]}function yZ(I){return Array.isArray(I)}function sX(I){return typeof I==="boolean"}function AX(I){return I===null}function mY(I){return I==null}function cZ(I){return typeof I==="number"}function zX(I){return typeof I==="string"}function sY(I){return typeof I==="symbol"}function nU(I){return I===void 0}function WX(I){return mU(I)&&tX(I)==="[object RegExp]"}function mU(I){return typeof I==="object"&&I!==null}function nX(I){return mU(I)&&tX(I)==="[object Date]"}function HX(I){return mU(I)&&(tX(I)==="[object Error]"||I instanceof Error)}function DX(I){return typeof I==="function"}function tY(I){return I===null||typeof I==="boolean"||typeof I==="number"||typeof I==="string"||typeof I==="symbol"||typeof I>"u"}function rY(I){return I instanceof Buffer}function tX(I){return Object.prototype.toString.call(I)}function dX(I){return I<10?"0"+I.toString(10):I.toString(10)}function eY(){var I=new Date,O=[dX(I.getHours()),dX(I.getMinutes()),dX(I.getSeconds())].join(":");return[I.getDate(),aY[I.getMonth()],O].join(" ")}function pZ(...I){console.log("%s - %s",eY(),mX.apply(null,I))}function hZ(I,O){if(O)I.super_=O,I.prototype=Object.create(O.prototype,{constructor:{value:I,enumerable:!1,writable:!0,configurable:!0}})}function rX(I,O){if(!O||!mU(O))return I;var W=Object.keys(O),T=W.length;while(T--)I[W[T]]=O[W[T]];return I}function uZ(I,O){return Object.prototype.hasOwnProperty.call(I,O)}function aX(I,O){if(!I){var W=Error("Promise was rejected with a falsy value");W.reason=I,I=W}return O(I)}function lZ(I){if(typeof I!=="function")throw TypeError('The "original" argument must be of type Function');function O(...W){var T=W.pop();if(typeof T!=="function")throw TypeError("The last argument must be of type Function");var H=this,L=function(...V){return T.apply(H,...V)};I.apply(this,W).then(function(V){process.nextTick(L.bind(null,null,V))},function(V){process.nextTick(aX.bind(null,V,L))})}return Object.setPrototypeOf(O,Object.getPrototypeOf(I)),Object.defineProperties(O,Object.getOwnPropertyDescriptors(I)),O}var yY,pY,uU,nY=()=>{},aY,bZ,dZ,oZ,iY;var mZ=KX(()=>{yY=/%[sdj%]/g;pY=((I={},O={},W)=>((W=typeof process<"u"&&!1)&&(W=W.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase()),O=new RegExp("^"+W+"$","i"),(T)=>{if(T=T.toUpperCase(),!I[T])if(O.test(T))I[T]=function(...H){console.error("%s: %s",T,pid,mX.apply(null,...H))};else I[T]=function(){};return I[T]}))(),uU=((I)=>(I.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]},I.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"},I.custom=Symbol.for("nodejs.util.inspect.custom"),I))(function(I,O,...W){var T={seen:[],stylize:uY};if(W.length>=1)T.depth=W[0];if(W.length>=2)T.colors=W[1];if(sX(O))T.showHidden=O;else if(O)rX(T,O);if(nU(T.showHidden))T.showHidden=!1;if(nU(T.depth))T.depth=2;if(nU(T.colors))T.colors=!1;if(T.colors)T.stylize=hY;return TX(T,I,T.depth)});aY=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];bZ=((I)=>(I.custom=Symbol.for("nodejs.util.promisify.custom"),I))(function(I){if(typeof I!=="function")throw TypeError('The "original" argument must be of type Function');if(kCustomPromisifiedSymbol&&I[kCustomPromisifiedSymbol]){var O=I[kCustomPromisifiedSymbol];if(typeof O!=="function")throw TypeError('The "nodejs.util.promisify.custom" argument must be of type Function');return Object.defineProperty(O,kCustomPromisifiedSymbol,{value:O,enumerable:!1,writable:!1,configurable:!0}),O}function O(...W){var T,H,L=new Promise(function(V,P){T=V,H=P});W.push(function(V,P){if(V)H(V);else T(P)});try{I.apply(this,W)}catch(V){H(V)}return L}if(Object.setPrototypeOf(O,Object.getPrototypeOf(I)),kCustomPromisifiedSymbol)Object.defineProperty(O,kCustomPromisifiedSymbol,{value:O,enumerable:!1,writable:!1,configurable:!0});return Object.defineProperties(O,Object.getOwnPropertyDescriptors(I))});({TextEncoder:dZ,TextDecoder:oZ}=globalThis),iY={TextEncoder:dZ,TextDecoder:oZ,promisify:bZ,log:pZ,inherits:hZ,_extend:rX,callbackifyOnRejected:aX,callbackify:lZ}});var iU={};$X(iU,{setMaxListeners:()=>YQ,once:()=>ZQ,listenerCount:()=>JQ,init:()=>fU,getMaxListeners:()=>GQ,getEventListeners:()=>QQ,default:()=>IJ,captureRejectionSymbol:()=>eZ,addAbortListener:()=>IQ,EventEmitter:()=>fU});function iZ(I,O){var{_events:W}=I;if(O[0]??=Error("Unhandled error."),!W)throw O[0];var T=W[aZ];if(T)for(var H of tZ.call(T))H.apply(I,O);var L=W.error;if(!L)throw O[0];for(var H of tZ.call(L))H.apply(I,O);return!0}function ZJ(I,O,W,T){O.then(void 0,function(H){queueMicrotask(()=>QJ(I,H,W,T))})}function QJ(I,O,W,T){if(typeof I[sZ]==="function")I[sZ](O,W,...T);else try{I[bU]=!1,I.emit("error",O)}finally{I[bU]=!0}}function UQ(I,O,W){W.warned=!0;let T=Error(`Possible EventEmitter memory leak detected. ${W.length} ${String(O)} listeners added to [${I.constructor.name}]. Use emitter.setMaxListeners() to increase limit`);T.name="MaxListenersExceededWarning",T.emitter=I,T.type=O,T.count=W.length,console.warn(T)}function XQ(I,O,...W){this.removeListener(I,O),O.apply(this,W)}function ZQ(I,O,W){var T=W?.signal;if(VQ(T,"options.signal"),T?.aborted)throw new eX(void 0,{cause:T?.reason});let{resolve:H,reject:L,promise:V}=$newPromiseCapability(Promise),P=(C)=>{if(I.removeListener(O,S),T!=null)CX(T,"abort",E);L(C)},S=(...C)=>{if(typeof I.removeListener==="function")I.removeListener("error",P);if(T!=null)CX(T,"abort",E);H(C)};if(rZ(I,O,S,{once:!0}),O!=="error"&&typeof I.once==="function")I.once("error",P);function E(){CX(I,O,S),CX(I,"error",P),L(new eX(void 0,{cause:T?.reason}))}if(T!=null)rZ(T,"abort",E,{once:!0});return V}function QQ(I,O){return I.listeners(O)}function YQ(I,...O){UZ(I,"setMaxListeners",0);var W;if(O&&(W=O.length))for(let T=0;T<W;T++)O[T].setMaxListeners(I);else lU=I}function JQ(I,O){return I.listenerCount(O)}function CX(I,O,W,T){if(typeof I.removeListener==="function")I.removeListener(O,W);else I.removeEventListener(O,W,T)}function rZ(I,O,W,T){if(typeof I.on==="function")if(T.once)I.once(O,W);else I.on(O,W);else I.addEventListener(O,W,T)}function sU(I,O,W){let T=TypeError(`The "${I}" argument must be of type ${O}. Received ${W}`);return T.code="ERR_INVALID_ARG_TYPE",T}function VJ(I,O,W){let T=RangeError(`The "${I}" argument is out of range. It must be ${O}. Received ${W}`);return T.code="ERR_OUT_OF_RANGE",T}function VQ(I,O){if(I!==void 0&&(I===null||typeof I!=="object"||!("aborted"in I)))throw sU(O,"AbortSignal",I)}function UZ(I,O,W,T){if(typeof I!=="number")throw sU(O,"number",I);if(W!=null&&I<W||T!=null&&I>T||(W!=null||T!=null)&&Number.isNaN(I))throw VJ(O,`${W!=null?`>= ${W}`:""}${W!=null&&T!=null?" && ":""}${T!=null?`<= ${T}`:""}`,I)}function eU(I){if(typeof I!=="function")throw TypeError("The listener must be a function")}function GJ(I,O){if(typeof I!=="boolean")throw sU(O,"boolean",I)}function GQ(I){return I?._maxListeners??lU}function IQ(I,O){if(I===void 0)throw sU("signal","AbortSignal",I);if(VQ(I,"signal"),typeof O!=="function")throw sU("listener","function",O);let W;if(I.aborted)queueMicrotask(()=>O());else I.addEventListener("abort",O,{__proto__:null,once:!0}),W=()=>{I.removeEventListener("abort",O)};return{__proto__:null,[Symbol.dispose](){W?.()}}}var iX,bU,aZ,UJ,XJ,sZ,eZ,tZ,lU=10,fU=function(I){if(this._events===void 0||this._events===this.__proto__._events)this._events={__proto__:null},this._eventsCount=0;if(this._maxListeners??=void 0,this[bU]=I?.captureRejections?Boolean(I?.captureRejections):d0[bU])this.emit=JJ},d0,YJ=function(I,...O){if(I==="error")return iZ(this,O);var{_events:W}=this;if(W===void 0)return!1;var T=W[I];if(T===void 0)return!1;let H=T.length>1?T.slice():T;for(let L=0,{length:V}=H;L<V;L++){let P=H[L];switch(O.length){case 0:P.call(this);break;case 1:P.call(this,O[0]);break;case 2:P.call(this,O[0],O[1]);break;case 3:P.call(this,O[0],O[1],O[2]);break;default:P.apply(this,O);break}}return!0},JJ=function(I,...O){if(I==="error")return iZ(this,O);var{_events:W}=this;if(W===void 0)return!1;var T=W[I];if(T===void 0)return!1;let H=T.length>1?T.slice():T;for(let L=0,{length:V}=H;L<V;L++){let P=H[L],S;switch(O.length){case 0:S=P.call(this);break;case 1:S=P.call(this,O[0]);break;case 2:S=P.call(this,O[0],O[1]);break;case 3:S=P.call(this,O[0],O[1],O[2]);break;default:S=P.apply(this,O);break}if(S!==void 0&&typeof S?.then==="function"&&S.then===Promise.prototype.then)ZJ(this,S,I,O)}return!0},eX,IJ;var UX=KX(()=>{iX=Symbol.for,bU=Symbol("kCapture"),aZ=iX("events.errorMonitor"),UJ=Symbol("events.maxEventTargetListeners"),XJ=Symbol("events.maxEventTargetListenersWarned"),sZ=iX("nodejs.rejection"),eZ=iX("nodejs.rejection"),tZ=Array.prototype.slice,d0=fU.prototype={};d0._events=void 0;d0._eventsCount=0;d0._maxListeners=void 0;d0.setMaxListeners=function(I){return UZ(I,"setMaxListeners",0),this._maxListeners=I,this};d0.constructor=fU;d0.getMaxListeners=function(){return this?._maxListeners??lU};d0.emit=YJ;d0.addListener=function(I,O){eU(O);var W=this._events;if(!W)W=this._events={__proto__:null},this._eventsCount=0;else if(W.newListener)this.emit("newListener",I,O.listener??O);var T=W[I];if(!T)W[I]=[O],this._eventsCount++;else{T.push(O);var H=this._maxListeners??lU;if(H>0&&T.length>H&&!T.warned)UQ(this,I,T)}return this};d0.on=d0.addListener;d0.prependListener=function(I,O){eU(O);var W=this._events;if(!W)W=this._events={__proto__:null},this._eventsCount=0;else if(W.newListener)this.emit("newListener",I,O.listener??O);var T=W[I];if(!T)W[I]=[O],this._eventsCount++;else{T.unshift(O);var H=this._maxListeners??lU;if(H>0&&T.length>H&&!T.warned)UQ(this,I,T)}return this};d0.once=function(I,O){eU(O);let W=XQ.bind(this,I,O);return W.listener=O,this.addListener(I,W),this};d0.prependOnceListener=function(I,O){eU(O);let W=XQ.bind(this,I,O);return W.listener=O,this.prependListener(I,W),this};d0.removeListener=function(I,O){eU(O);var{_events:W}=this;if(!W)return this;var T=W[I];if(!T)return this;var H=T.length;let L=-1;for(let V=H-1;V>=0;V--)if(T[V]===O||T[V].listener===O){L=V;break}if(L<0)return this;if(L===0)T.shift();else T.splice(L,1);if(T.length===0)delete W[I],this._eventsCount--;return this};d0.off=d0.removeListener;d0.removeAllListeners=function(I){var{_events:O}=this;if(I&&O){if(O[I])delete O[I],this._eventsCount--}else this._events={__proto__:null};return this};d0.listeners=function(I){var{_events:O}=this;if(!O)return[];var W=O[I];if(!W)return[];return W.map((T)=>T.listener??T)};d0.rawListeners=function(I){var{_events:O}=this;if(!O)return[];var W=O[I];if(!W)return[];return W.slice()};d0.listenerCount=function(I){var{_events:O}=this;if(!O)return 0;return O[I]?.length??0};d0.eventNames=function(){return this._eventsCount>0?Reflect.ownKeys(this._events):[]};d0[bU]=!1;eX=class eX extends Error{constructor(I="The operation was aborted",O=void 0){if(O!==void 0&&typeof O!=="object")throw sU("options","Object",O);super(I,O);this.code="ABORT_ERR",this.name="AbortError"}};Object.defineProperties(fU,{captureRejections:{get(){return d0[bU]},set(I){GJ(I,"EventEmitter.captureRejections"),d0[bU]=I},enumerable:!0},defaultMaxListeners:{enumerable:!0,get:()=>{return lU},set:(I)=>{UZ(I,"defaultMaxListeners",0),lU=I}},kMaxEventTargetListeners:{value:UJ,enumerable:!1,configurable:!1,writable:!1},kMaxEventTargetListenersWarned:{value:XJ,enumerable:!1,configurable:!1,writable:!1}});Object.assign(fU,{once:ZQ,getEventListeners:QQ,getMaxListeners:GQ,setMaxListeners:YQ,EventEmitter:fU,usingDomains:!1,captureRejectionSymbol:eZ,errorMonitor:aZ,addAbortListener:IQ,init:fU,listenerCount:JQ});IJ=fU});var YZ=EX((nG,TQ)=>{var u0=(I,O)=>()=>(O||I((O={exports:{}}).exports,O),O.exports),o0=u0((I,O)=>{class W extends Error{constructor(T){if(!Array.isArray(T))throw TypeError(`Expected input to be an Array, got ${typeof T}`);let H="";for(let L=0;L<T.length;L++)H+=` ${T[L].stack}
|
|
11
|
+
`;super(H);this.name="AggregateError",this.errors=T}}O.exports={AggregateError:W,ArrayIsArray(T){return Array.isArray(T)},ArrayPrototypeIncludes(T,H){return T.includes(H)},ArrayPrototypeIndexOf(T,H){return T.indexOf(H)},ArrayPrototypeJoin(T,H){return T.join(H)},ArrayPrototypeMap(T,H){return T.map(H)},ArrayPrototypePop(T,H){return T.pop(H)},ArrayPrototypePush(T,H){return T.push(H)},ArrayPrototypeSlice(T,H,L){return T.slice(H,L)},Error,FunctionPrototypeCall(T,H,...L){return T.call(H,...L)},FunctionPrototypeSymbolHasInstance(T,H){return Function.prototype[Symbol.hasInstance].call(T,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(T,H){return Object.defineProperties(T,H)},ObjectDefineProperty(T,H,L){return Object.defineProperty(T,H,L)},ObjectGetOwnPropertyDescriptor(T,H){return Object.getOwnPropertyDescriptor(T,H)},ObjectKeys(T){return Object.keys(T)},ObjectSetPrototypeOf(T,H){return Object.setPrototypeOf(T,H)},Promise,PromisePrototypeCatch(T,H){return T.catch(H)},PromisePrototypeThen(T,H,L){return T.then(H,L)},PromiseReject(T){return Promise.reject(T)},PromiseResolve(T){return Promise.resolve(T)},ReflectApply:Reflect.apply,RegExpPrototypeTest(T,H){return T.test(H)},SafeSet:Set,String,StringPrototypeSlice(T,H,L){return T.slice(H,L)},StringPrototypeToLowerCase(T){return T.toLowerCase()},StringPrototypeToUpperCase(T){return T.toUpperCase()},StringPrototypeTrim(T){return T.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(T,H,L){return T.set(H,L)},Boolean,Uint8Array}}),$Q=u0((I,O)=>{O.exports={format(W,...T){return W.replace(/%([sdifj])/g,function(...[H,L]){let V=T.shift();if(L==="f")return V.toFixed(6);else if(L==="j")return JSON.stringify(V);else if(L==="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"{}"}}}}),CU=u0((I,O)=>{var{format:W,inspect:T}=$Q(),{AggregateError:H}=o0(),L=globalThis.AggregateError||H,V=Symbol("kIsNodeError"),P=["string","function","number","object","Function","Object","boolean","bigint","symbol"],S=/^([A-Z][a-z0-9]*)+$/,E={};function C(j,v){if(!j)throw new E.ERR_INTERNAL_ASSERTION(v)}function D(j){let v="",x=j.length,N=j[0]==="-"?1:0;for(;x>=N+4;x-=3)v=`_${j.slice(x-3,x)}${v}`;return`${j.slice(0,x)}${v}`}function z(j,v,x){if(typeof v==="function")return C(v.length<=x.length,`Code: ${j}; The provided arguments length (${x.length}) does not match the required ones (${v.length}).`),v(...x);let N=(v.match(/%[dfijoOs]/g)||[]).length;if(C(N===x.length,`Code: ${j}; The provided arguments length (${x.length}) does not match the required ones (${N}).`),x.length===0)return v;return W(v,...x)}function R(j,v,x){if(!x)x=Error;class N extends x{constructor(...f){super(z(j,v,f))}toString(){return`${this.name} [${j}]: ${this.message}`}}Object.defineProperties(N.prototype,{name:{value:x.name,writable:!0,enumerable:!1,configurable:!0},toString:{value(){return`${this.name} [${j}]: ${this.message}`},writable:!0,enumerable:!1,configurable:!0}}),N.prototype.code=j,N.prototype[V]=!0,E[j]=N}function q(j){let v="__node_internal_"+j.name;return Object.defineProperty(j,"name",{value:v}),j}function _(j,v){if(j&&v&&j!==v){if(Array.isArray(v.errors))return v.errors.push(j),v;let x=new L([v,j],v.message);return x.code=v.code,x}return j||v}class k extends Error{constructor(j="The operation was aborted",v=void 0){if(v!==void 0&&typeof v!=="object")throw new E.ERR_INVALID_ARG_TYPE("options","Object",v);super(j,v);this.code="ABORT_ERR",this.name="AbortError"}}R("ERR_ASSERTION","%s",Error),R("ERR_INVALID_ARG_TYPE",(j,v,x)=>{if(C(typeof j==="string","'name' must be a string"),!Array.isArray(v))v=[v];let N="The ";if(j.endsWith(" argument"))N+=`${j} `;else N+=`"${j}" ${j.includes(".")?"property":"argument"} `;N+="must be ";let f=[],b=[],Q0=[];for(let Y0 of v)if(C(typeof Y0==="string","All expected entries have to be of type string"),P.includes(Y0))f.push(Y0.toLowerCase());else if(S.test(Y0))b.push(Y0);else C(Y0!=="object",'The value "object" should be written as "Object"'),Q0.push(Y0);if(b.length>0){let Y0=f.indexOf("object");if(Y0!==-1)f.splice(f,Y0,1),b.push("Object")}if(f.length>0){switch(f.length){case 1:N+=`of type ${f[0]}`;break;case 2:N+=`one of type ${f[0]} or ${f[1]}`;break;default:{let Y0=f.pop();N+=`one of type ${f.join(", ")}, or ${Y0}`}}if(b.length>0||Q0.length>0)N+=" or "}if(b.length>0){switch(b.length){case 1:N+=`an instance of ${b[0]}`;break;case 2:N+=`an instance of ${b[0]} or ${b[1]}`;break;default:{let Y0=b.pop();N+=`an instance of ${b.join(", ")}, or ${Y0}`}}if(Q0.length>0)N+=" or "}switch(Q0.length){case 0:break;case 1:if(Q0[0].toLowerCase()!==Q0[0])N+="an ";N+=`${Q0[0]}`;break;case 2:N+=`one of ${Q0[0]} or ${Q0[1]}`;break;default:{let Y0=Q0.pop();N+=`one of ${Q0.join(", ")}, or ${Y0}`}}if(x==null)N+=`. Received ${x}`;else if(typeof x==="function"&&x.name)N+=`. Received function ${x.name}`;else if(typeof x==="object"){var G0;if((G0=x.constructor)!==null&&G0!==void 0&&G0.name)N+=`. Received an instance of ${x.constructor.name}`;else{let Y0=T(x,{depth:-1});N+=`. Received ${Y0}`}}else{let Y0=T(x,{colors:!1});if(Y0.length>25)Y0=`${Y0.slice(0,25)}...`;N+=`. Received type ${typeof x} (${Y0})`}return N},TypeError),R("ERR_INVALID_ARG_VALUE",(j,v,x="is invalid")=>{let N=T(v);if(N.length>128)N=N.slice(0,128)+"...";return`The ${j.includes(".")?"property":"argument"} '${j}' ${x}. Received ${N}`},TypeError),R("ERR_INVALID_RETURN_VALUE",(j,v,x)=>{var N;let f=x!==null&&x!==void 0&&(N=x.constructor)!==null&&N!==void 0&&N.name?`instance of ${x.constructor.name}`:`type ${typeof x}`;return`Expected ${j} to be returned from the "${v}" function but got ${f}.`},TypeError),R("ERR_MISSING_ARGS",(...j)=>{C(j.length>0,"At least one arg needs to be specified");let v,x=j.length;switch(j=(Array.isArray(j)?j:[j]).map((N)=>`"${N}"`).join(" or "),x){case 1:v+=`The ${j[0]} argument`;break;case 2:v+=`The ${j[0]} and ${j[1]} arguments`;break;default:{let N=j.pop();v+=`The ${j.join(", ")}, and ${N} arguments`}break}return`${v} must be specified`},TypeError),R("ERR_OUT_OF_RANGE",(j,v,x)=>{C(v,'Missing "range" argument');let N;if(Number.isInteger(x)&&Math.abs(x)>4294967296)N=D(String(x));else if(typeof x==="bigint"){N=String(x);let f=BigInt(2)**BigInt(32);if(x>f||x<-f)N=D(N);N+="n"}else N=T(x);return`The value of "${j}" is out of range. It must be ${v}. Received ${N}`},RangeError),R("ERR_MULTIPLE_CALLBACK","Callback called multiple times",Error),R("ERR_METHOD_NOT_IMPLEMENTED","The %s method is not implemented",Error),R("ERR_STREAM_ALREADY_FINISHED","Cannot call %s after a stream was finished",Error),R("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable",Error),R("ERR_STREAM_DESTROYED","Cannot call %s after a stream was destroyed",Error),R("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),R("ERR_STREAM_PREMATURE_CLOSE","Premature close",Error),R("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF",Error),R("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event",Error),R("ERR_STREAM_WRITE_AFTER_END","write after end",Error),R("ERR_UNKNOWN_ENCODING","Unknown encoding: %s",TypeError),O.exports={AbortError:k,aggregateTwoErrors:q(_),hideStackFrames:q,codes:E}}),$J=u0((I,O)=>{Object.defineProperty(I,"__esModule",{value:!0});var W=new WeakMap,T=new WeakMap;function H(u){let U0=W.get(u);return console.assert(U0!=null,"'this' is expected an Event object, but got",u),U0}function L(u){if(u.passiveListener!=null){if(typeof console<"u"&&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,U0){W.set(this,{eventTarget:u,event:U0,eventPhase:2,currentTarget:u,canceled:!1,stopped:!1,immediateStopped:!1,passiveListener:null,timeStamp:U0.timeStamp||Date.now()}),Object.defineProperty(this,"isTrusted",{value:!1,enumerable:!0});let U=Object.keys(U0);for(let Q=0;Q<U.length;++Q){let J=U[Q];if(!(J in this))Object.defineProperty(this,J,P(J))}}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(){L(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 U0=H(this);if(U0.stopped=!0,typeof U0.event.cancelBubble==="boolean")U0.event.cancelBubble=!0},get returnValue(){return!H(this).canceled},set returnValue(u){if(!u)L(H(this))},initEvent(){}},Object.defineProperty(V.prototype,"constructor",{value:V,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.Event<"u")Object.setPrototypeOf(V.prototype,window.Event.prototype),T.set(window.Event.prototype,V);function P(u){return{get(){return H(this).event[u]},set(U0){H(this).event[u]=U0},configurable:!0,enumerable:!0}}function S(u){return{value(){let U0=H(this).event;return U0[u].apply(U0,arguments)},configurable:!0,enumerable:!0}}function E(u,U0){let U=Object.keys(U0);if(U.length===0)return u;function Q(J,Z){u.call(this,J,Z)}Q.prototype=Object.create(u.prototype,{constructor:{value:Q,configurable:!0,writable:!0}});for(let J=0;J<U.length;++J){let Z=U[J];if(!(Z in u.prototype)){let Y=typeof Object.getOwnPropertyDescriptor(U0,Z).value==="function";Object.defineProperty(Q.prototype,Z,Y?S(Z):P(Z))}}return Q}function C(u){if(u==null||u===Object.prototype)return V;let U0=T.get(u);if(U0==null)U0=E(C(Object.getPrototypeOf(u)),u),T.set(u,U0);return U0}function D(u,U0){return new(C(Object.getPrototypeOf(U0)))(u,U0)}function z(u){return H(u).immediateStopped}function R(u,U0){H(u).eventPhase=U0}function q(u,U0){H(u).currentTarget=U0}function _(u,U0){H(u).passiveListener=U0}var k=new WeakMap,j=1,v=2,x=3;function N(u){return u!==null&&typeof u==="object"}function f(u){let U0=k.get(u);if(U0==null)throw TypeError("'this' is expected an EventTarget object, but got another value.");return U0}function b(u){return{get(){let U0=f(this).get(u);while(U0!=null){if(U0.listenerType===x)return U0.listener;U0=U0.next}return null},set(U0){if(typeof U0!=="function"&&!N(U0))U0=null;let U=f(this),Q=null,J=U.get(u);while(J!=null){if(J.listenerType===x)if(Q!==null)Q.next=J.next;else if(J.next!==null)U.set(u,J.next);else U.delete(u);else Q=J;J=J.next}if(U0!==null){let Z={listener:U0,listenerType:x,passive:!1,once:!1,next:null};if(Q===null)U.set(u,Z);else Q.next=Z}},configurable:!0,enumerable:!0}}function Q0(u,U0){Object.defineProperty(u,`on${U0}`,b(U0))}function G0(u){function U0(){Y0.call(this)}U0.prototype=Object.create(Y0.prototype,{constructor:{value:U0,configurable:!0,writable:!0}});for(let U=0;U<u.length;++U)Q0(U0.prototype,u[U]);return U0}function Y0(){if(this instanceof Y0){k.set(this,new Map);return}if(arguments.length===1&&Array.isArray(arguments[0]))return G0(arguments[0]);if(arguments.length>0){let u=Array(arguments.length);for(let U0=0;U0<arguments.length;++U0)u[U0]=arguments[U0];return G0(u)}throw TypeError("Cannot call a class as a function")}if(Y0.prototype={addEventListener(u,U0,U){if(U0==null)return;if(typeof U0!=="function"&&!N(U0))throw TypeError("'listener' should be a function or an object.");let Q=f(this),J=N(U),Z=(J?Boolean(U.capture):Boolean(U))?j:v,Y={listener:U0,listenerType:Z,passive:J&&Boolean(U.passive),once:J&&Boolean(U.once),next:null},K=Q.get(u);if(K===void 0){Q.set(u,Y);return}let F=null;while(K!=null){if(K.listener===U0&&K.listenerType===Z)return;F=K,K=K.next}F.next=Y},removeEventListener(u,U0,U){if(U0==null)return;let Q=f(this),J=(N(U)?Boolean(U.capture):Boolean(U))?j:v,Z=null,Y=Q.get(u);while(Y!=null){if(Y.listener===U0&&Y.listenerType===J){if(Z!==null)Z.next=Y.next;else if(Y.next!==null)Q.set(u,Y.next);else Q.delete(u);return}Z=Y,Y=Y.next}},dispatchEvent(u){if(u==null||typeof u.type!=="string")throw TypeError('"event.type" should be a string.');let U0=f(this),U=u.type,Q=U0.get(U);if(Q==null)return!0;let J=D(this,u),Z=null;while(Q!=null){if(Q.once)if(Z!==null)Z.next=Q.next;else if(Q.next!==null)U0.set(U,Q.next);else U0.delete(U);else Z=Q;if(_(J,Q.passive?Q.listener:null),typeof Q.listener==="function")try{Q.listener.call(this,J)}catch(Y){if(typeof console<"u"&&typeof console.error==="function")console.error(Y)}else if(Q.listenerType!==x&&typeof Q.listener.handleEvent==="function")Q.listener.handleEvent(J);if(z(J))break;Q=Q.next}return _(J,null),R(J,0),q(J,null),!J.defaultPrevented}},Object.defineProperty(Y0.prototype,"constructor",{value:Y0,configurable:!0,writable:!0}),typeof window<"u"&&typeof window.EventTarget<"u")Object.setPrototypeOf(Y0.prototype,window.EventTarget.prototype);I.defineEventAttribute=Q0,I.EventTarget=Y0,I.default=Y0,O.exports=Y0,O.exports.EventTarget=O.exports.default=Y0,O.exports.defineEventAttribute=Q0}),XX=u0((I,O)=>{Object.defineProperty(I,"__esModule",{value:!0});var W=$J();class T extends W.EventTarget{constructor(){super();throw TypeError("AbortSignal cannot be constructed directly")}get aborted(){let C=V.get(this);if(typeof C!=="boolean")throw TypeError(`Expected 'this' to be an 'AbortSignal' object, but got ${this===null?"null":typeof this}`);return C}}W.defineEventAttribute(T.prototype,"abort");function H(){let C=Object.create(T.prototype);return W.EventTarget.call(C),V.set(C,!1),C}function L(C){if(V.get(C)!==!1)return;V.set(C,!0),C.dispatchEvent({type:"abort"})}var V=new WeakMap;if(Object.defineProperties(T.prototype,{aborted:{enumerable:!0}}),typeof Symbol==="function"&&typeof Symbol.toStringTag==="symbol")Object.defineProperty(T.prototype,Symbol.toStringTag,{configurable:!0,value:"AbortSignal"});class P{constructor(){S.set(this,H())}get signal(){return E(this)}abort(){L(E(this))}}var S=new WeakMap;function E(C){let D=S.get(C);if(D==null)throw TypeError(`Expected 'this' to be an 'AbortController' object, but got ${C===null?"null":typeof C}`);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"});I.AbortController=P,I.AbortSignal=T,I.default=P,O.exports=P,O.exports.AbortController=O.exports.default=P,O.exports.AbortSignal=T}),MU=u0((I,O)=>{var W=(HU(),h0(WU)),{format:T,inspect:H}=$Q(),{codes:{ERR_INVALID_ARG_TYPE:L}}=CU(),{kResistStopPropagation:V,AggregateError:P,SymbolDispose:S}=o0(),E=globalThis.AbortSignal||XX().AbortSignal,C=globalThis.AbortController||XX().AbortController,D=Object.getPrototypeOf(async function(){}).constructor,z=globalThis.Blob||W.Blob,R=typeof z<"u"?function(k){return k instanceof z}:function(k){return!1},q=(k,j)=>{if(k!==void 0&&(k===null||typeof k!=="object"||!("aborted"in k)))throw new L(j,"AbortSignal",k)},_=(k,j)=>{if(typeof k!=="function")throw new L(j,"Function",k)};O.exports={AggregateError:P,kEmptyObject:Object.freeze({}),once(k){let j=!1;return function(...v){if(j)return;j=!0,k.apply(this,v)}},createDeferredPromise:function(){let k,j;return{promise:new Promise((v,x)=>{k=v,j=x}),resolve:k,reject:j}},promisify(k){return new Promise((j,v)=>{k((x,...N)=>{if(x)return v(x);return j(...N)})})},debuglog(){return function(){}},format:T,inspect:H,types:{isAsyncFunction(k){return k instanceof D},isArrayBufferView(k){return ArrayBuffer.isView(k)}},isBlob:R,deprecate(k,j){return k},addAbortListener:(UX(),h0(iU)).addAbortListener||function(k,j){if(k===void 0)throw new L("signal","AbortSignal",k);q(k,"signal"),_(j,"listener");let v;if(k.aborted)queueMicrotask(()=>j());else k.addEventListener("abort",j,{__proto__:null,once:!0,[V]:!0}),v=()=>{k.removeEventListener("abort",j)};return{__proto__:null,[S](){var x;(x=v)===null||x===void 0||x()}}},AbortSignalAny:E.any||function(k){if(k.length===1)return k[0];let j=new C,v=()=>j.abort();return k.forEach((x)=>{q(x,"signals"),x.addEventListener("abort",v,{once:!0})}),j.signal.addEventListener("abort",()=>{k.forEach((x)=>x.removeEventListener("abort",v))},{once:!0}),j.signal}},O.exports.promisify.custom=Symbol.for("nodejs.util.promisify.custom")}),ZX=u0((I,O)=>{var{ArrayIsArray:W,ArrayPrototypeIncludes:T,ArrayPrototypeJoin:H,ArrayPrototypeMap:L,NumberIsInteger:V,NumberIsNaN:P,NumberMAX_SAFE_INTEGER:S,NumberMIN_SAFE_INTEGER:E,NumberParseInt:C,ObjectPrototypeHasOwnProperty:D,RegExpPrototypeExec:z,String:R,StringPrototypeToUpperCase:q,StringPrototypeTrim:_}=o0(),{hideStackFrames:k,codes:{ERR_SOCKET_BAD_PORT:j,ERR_INVALID_ARG_TYPE:v,ERR_INVALID_ARG_VALUE:x,ERR_OUT_OF_RANGE:N,ERR_UNKNOWN_SIGNAL:f}}=CU(),{normalizeEncoding:b}=MU(),{isAsyncFunction:Q0,isArrayBufferView:G0}=MU().types,Y0={};function u(c){return c===(c|0)}function U0(c){return c===c>>>0}var U=/^[0-7]+$/,Q="must be a 32-bit unsigned integer or an octal string";function J(c,o,N0){if(typeof c>"u")c=N0;if(typeof c==="string"){if(z(U,c)===null)throw new x(o,c,Q);c=C(c,8)}return K(c,o),c}var Z=k((c,o,N0=E,s=S)=>{if(typeof c!=="number")throw new v(o,"number",c);if(!V(c))throw new N(o,"an integer",c);if(c<N0||c>s)throw new N(o,`>= ${N0} && <= ${s}`,c)}),Y=k((c,o,N0=-2147483648,s=2147483647)=>{if(typeof c!=="number")throw new v(o,"number",c);if(!V(c))throw new N(o,"an integer",c);if(c<N0||c>s)throw new N(o,`>= ${N0} && <= ${s}`,c)}),K=k((c,o,N0=!1)=>{if(typeof c!=="number")throw new v(o,"number",c);if(!V(c))throw new N(o,"an integer",c);let s=N0?1:0,Z0=4294967295;if(c<s||c>Z0)throw new N(o,`>= ${s} && <= ${Z0}`,c)});function F(c,o){if(typeof c!=="string")throw new v(o,"string",c)}function G(c,o,N0=void 0,s){if(typeof c!=="number")throw new v(o,"number",c);if(N0!=null&&c<N0||s!=null&&c>s||(N0!=null||s!=null)&&P(c))throw new N(o,`${N0!=null?`>= ${N0}`:""}${N0!=null&&s!=null?" && ":""}${s!=null?`<= ${s}`:""}`,c)}var X=k((c,o,N0)=>{if(!T(N0,c)){let s="must be one of: "+H(L(N0,(Z0)=>typeof Z0==="string"?`'${Z0}'`:R(Z0)),", ");throw new x(o,c,s)}});function $(c,o){if(typeof c!=="boolean")throw new v(o,"boolean",c)}function M(c,o,N0){return c==null||!D(c,o)?N0:c[o]}var A=k((c,o,N0=null)=>{let s=M(N0,"allowArray",!1),Z0=M(N0,"allowFunction",!1);if(!M(N0,"nullable",!1)&&c===null||!s&&W(c)||typeof c!=="object"&&(!Z0||typeof c!=="function"))throw new v(o,"Object",c)}),B=k((c,o)=>{if(c!=null&&typeof c!=="object"&&typeof c!=="function")throw new v(o,"a dictionary",c)}),w=k((c,o,N0=0)=>{if(!W(c))throw new v(o,"Array",c);if(c.length<N0){let s=`must be longer than ${N0}`;throw new x(o,c,s)}});function p(c,o){w(c,o);for(let N0=0;N0<c.length;N0++)F(c[N0],`${o}[${N0}]`)}function n(c,o){w(c,o);for(let N0=0;N0<c.length;N0++)$(c[N0],`${o}[${N0}]`)}function K0(c,o){w(c,o);for(let N0=0;N0<c.length;N0++){let s=c[N0],Z0=`${o}[${N0}]`;if(s==null)throw new v(Z0,"AbortSignal",s);i(s,Z0)}}function r(c,o="signal"){if(F(c,o),Y0[c]===void 0){if(Y0[q(c)]!==void 0)throw new f(c+" (signals must use all capital letters)");throw new f(c)}}var d=k((c,o="buffer")=>{if(!G0(c))throw new v(o,["Buffer","TypedArray","DataView"],c)});function J0(c,o){let N0=b(o),s=c.length;if(N0==="hex"&&s%2!==0)throw new x("encoding",o,`is invalid for data of length ${s}`)}function m(c,o="Port",N0=!0){if(typeof c!=="number"&&typeof c!=="string"||typeof c==="string"&&_(c).length===0||+c!==+c>>>0||c>65535||c===0&&!N0)throw new j(o,c,N0);return c|0}var i=k((c,o)=>{if(c!==void 0&&(c===null||typeof c!=="object"||!("aborted"in c)))throw new v(o,"AbortSignal",c)}),g0=k((c,o)=>{if(typeof c!=="function")throw new v(o,"Function",c)}),y=k((c,o)=>{if(typeof c!=="function"||Q0(c))throw new v(o,"Function",c)}),h=k((c,o)=>{if(c!==void 0)throw new v(o,"undefined",c)});function V0(c,o,N0){if(!T(N0,c))throw new v(o,`('${H(N0,"|")}')`,c)}var t=/^(?:<[^>]*>)(?:\s*;\s*[^;"\s]+(?:=(")?[^;"\s]*\1)?)*$/;function e(c,o){if(typeof c>"u"||!z(t,c))throw new x(o,c,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}function E0(c){if(typeof c==="string")return e(c,"hints"),c;else if(W(c)){let o=c.length,N0="";if(o===0)return N0;for(let s=0;s<o;s++){let Z0=c[s];if(e(Z0,"hints"),N0+=Z0,s!==o-1)N0+=", "}return N0}throw new x("hints",c,'must be an array or string of format "</styles.css>; rel=preload; as=style"')}O.exports={isInt32:u,isUint32:U0,parseFileMode:J,validateArray:w,validateStringArray:p,validateBooleanArray:n,validateAbortSignalArray:K0,validateBoolean:$,validateBuffer:d,validateDictionary:B,validateEncoding:J0,validateFunction:g0,validateInt32:Y,validateInteger:Z,validateNumber:G,validateObject:A,validateOneOf:X,validatePlainFunction:y,validatePort:m,validateSignalName:r,validateString:F,validateUint32:K,validateUndefined:h,validateUnion:V0,validateAbortSignal:i,validateLinkHeaderValue:E0}}),dU=u0((I,O)=>{O.exports=globalThis.process}),NU=u0((I,O)=>{var{SymbolAsyncIterator:W,SymbolIterator:T,SymbolFor:H}=o0(),L=H("nodejs.stream.destroyed"),V=H("nodejs.stream.errored"),P=H("nodejs.stream.readable"),S=H("nodejs.stream.writable"),E=H("nodejs.stream.disturbed"),C=H("nodejs.webstream.isClosedPromise"),D=H("nodejs.webstream.controllerErrorFunction");function z(M,A=!1){var B;return!!(M&&typeof M.pipe==="function"&&typeof M.on==="function"&&(!A||typeof M.pause==="function"&&typeof M.resume==="function")&&(!M._writableState||((B=M._readableState)===null||B===void 0?void 0:B.readable)!==!1)&&(!M._writableState||M._readableState))}function R(M){var A;return!!(M&&typeof M.write==="function"&&typeof M.on==="function"&&(!M._readableState||((A=M._writableState)===null||A===void 0?void 0:A.writable)!==!1))}function q(M){return!!(M&&typeof M.pipe==="function"&&M._readableState&&typeof M.on==="function"&&typeof M.write==="function")}function _(M){return M&&(M._readableState||M._writableState||typeof M.write==="function"&&typeof M.on==="function"||typeof M.pipe==="function"&&typeof M.on==="function")}function k(M){return!!(M&&!_(M)&&typeof M.pipeThrough==="function"&&typeof M.getReader==="function"&&typeof M.cancel==="function")}function j(M){return!!(M&&!_(M)&&typeof M.getWriter==="function"&&typeof M.abort==="function")}function v(M){return!!(M&&!_(M)&&typeof M.readable==="object"&&typeof M.writable==="object")}function x(M){return k(M)||j(M)||v(M)}function N(M,A){if(M==null)return!1;if(A===!0)return typeof M[W]==="function";if(A===!1)return typeof M[T]==="function";return typeof M[W]==="function"||typeof M[T]==="function"}function f(M){if(!_(M))return null;let{_writableState:A,_readableState:B}=M,w=A||B;return!!(M.destroyed||M[L]||w!==null&&w!==void 0&&w.destroyed)}function b(M){if(!R(M))return null;if(M.writableEnded===!0)return!0;let A=M._writableState;if(A!==null&&A!==void 0&&A.errored)return!1;if(typeof(A===null||A===void 0?void 0:A.ended)!=="boolean")return null;return A.ended}function Q0(M,A){if(!R(M))return null;if(M.writableFinished===!0)return!0;let B=M._writableState;if(B!==null&&B!==void 0&&B.errored)return!1;if(typeof(B===null||B===void 0?void 0:B.finished)!=="boolean")return null;return!!(B.finished||A===!1&&B.ended===!0&&B.length===0)}function G0(M){if(!z(M))return null;if(M.readableEnded===!0)return!0;let A=M._readableState;if(!A||A.errored)return!1;if(typeof(A===null||A===void 0?void 0:A.ended)!=="boolean")return null;return A.ended}function Y0(M,A){if(!z(M))return null;let B=M._readableState;if(B!==null&&B!==void 0&&B.errored)return!1;if(typeof(B===null||B===void 0?void 0:B.endEmitted)!=="boolean")return null;return!!(B.endEmitted||A===!1&&B.ended===!0&&B.length===0)}function u(M){if(M&&M[P]!=null)return M[P];if(typeof(M===null||M===void 0?void 0:M.readable)!=="boolean")return null;if(f(M))return!1;return z(M)&&M.readable&&!Y0(M)}function U0(M){if(M&&M[S]!=null)return M[S];if(typeof(M===null||M===void 0?void 0:M.writable)!=="boolean")return null;if(f(M))return!1;return R(M)&&M.writable&&!b(M)}function U(M,A){if(!_(M))return null;if(f(M))return!0;if((A===null||A===void 0?void 0:A.readable)!==!1&&u(M))return!1;if((A===null||A===void 0?void 0:A.writable)!==!1&&U0(M))return!1;return!0}function Q(M){var A,B;if(!_(M))return null;if(M.writableErrored)return M.writableErrored;return(A=(B=M._writableState)===null||B===void 0?void 0:B.errored)!==null&&A!==void 0?A:null}function J(M){var A,B;if(!_(M))return null;if(M.readableErrored)return M.readableErrored;return(A=(B=M._readableState)===null||B===void 0?void 0:B.errored)!==null&&A!==void 0?A:null}function Z(M){if(!_(M))return null;if(typeof M.closed==="boolean")return M.closed;let{_writableState:A,_readableState:B}=M;if(typeof(A===null||A===void 0?void 0:A.closed)==="boolean"||typeof(B===null||B===void 0?void 0:B.closed)==="boolean")return(A===null||A===void 0?void 0:A.closed)||(B===null||B===void 0?void 0:B.closed);if(typeof M._closed==="boolean"&&Y(M))return M._closed;return null}function Y(M){return typeof M._closed==="boolean"&&typeof M._defaultKeepAlive==="boolean"&&typeof M._removedConnection==="boolean"&&typeof M._removedContLen==="boolean"}function K(M){return typeof M._sent100==="boolean"&&Y(M)}function F(M){var A;return typeof M._consuming==="boolean"&&typeof M._dumped==="boolean"&&((A=M.req)===null||A===void 0?void 0:A.upgradeOrConnect)===void 0}function G(M){if(!_(M))return null;let{_writableState:A,_readableState:B}=M,w=A||B;return!w&&K(M)||!!(w&&w.autoDestroy&&w.emitClose&&w.closed===!1)}function X(M){var A;return!!(M&&((A=M[E])!==null&&A!==void 0?A:M.readableDidRead||M.readableAborted))}function $(M){var A,B,w,p,n,K0,r,d,J0,m;return!!(M&&((A=(B=(w=(p=(n=(K0=M[V])!==null&&K0!==void 0?K0:M.readableErrored)!==null&&n!==void 0?n:M.writableErrored)!==null&&p!==void 0?p:(r=M._readableState)===null||r===void 0?void 0:r.errorEmitted)!==null&&w!==void 0?w:(d=M._writableState)===null||d===void 0?void 0:d.errorEmitted)!==null&&B!==void 0?B:(J0=M._readableState)===null||J0===void 0?void 0:J0.errored)!==null&&A!==void 0?A:(m=M._writableState)===null||m===void 0?void 0:m.errored))}O.exports={isDestroyed:f,kIsDestroyed:L,isDisturbed:X,kIsDisturbed:E,isErrored:$,kIsErrored:V,isReadable:u,kIsReadable:P,kIsClosedPromise:C,kControllerErrorFunction:D,kIsWritable:S,isClosed:Z,isDuplexNodeStream:q,isFinished:U,isIterable:N,isReadableNodeStream:z,isReadableStream:k,isReadableEnded:G0,isReadableFinished:Y0,isReadableErrored:J,isNodeStream:_,isWebStream:x,isWritable:U0,isWritableNodeStream:R,isWritableStream:j,isWritableEnded:b,isWritableFinished:Q0,isWritableErrored:Q,isServerRequest:F,isServerResponse:K,willEmitClose:G,isTransformStream:v}}),yU=u0((I,O)=>{var W=dU(),{AbortError:T,codes:H}=CU(),{ERR_INVALID_ARG_TYPE:L,ERR_STREAM_PREMATURE_CLOSE:V}=H,{kEmptyObject:P,once:S}=MU(),{validateAbortSignal:E,validateFunction:C,validateObject:D,validateBoolean:z}=ZX(),{Promise:R,PromisePrototypeThen:q,SymbolDispose:_}=o0(),{isClosed:k,isReadable:j,isReadableNodeStream:v,isReadableStream:x,isReadableFinished:N,isReadableErrored:f,isWritable:b,isWritableNodeStream:Q0,isWritableStream:G0,isWritableFinished:Y0,isWritableErrored:u,isNodeStream:U0,willEmitClose:U,kIsClosedPromise:Q}=NU(),J;function Z(X){return X.setHeader&&typeof X.abort==="function"}var Y=()=>{};function K(X,$,M){var A,B;if(arguments.length===2)M=$,$=P;else if($==null)$=P;else D($,"options");if(C(M,"callback"),E($.signal,"options.signal"),M=S(M),x(X)||G0(X))return F(X,$,M);if(!U0(X))throw new L("stream",["ReadableStream","WritableStream","Stream"],X);let w=(A=$.readable)!==null&&A!==void 0?A:v(X),p=(B=$.writable)!==null&&B!==void 0?B:Q0(X),n=X._writableState,K0=X._readableState,r=()=>{if(!X.writable)m()},d=U(X)&&v(X)===w&&Q0(X)===p,J0=Y0(X,!1),m=()=>{if(J0=!0,X.destroyed)d=!1;if(d&&(!X.readable||w))return;if(!w||i)M.call(X)},i=N(X,!1),g0=()=>{if(i=!0,X.destroyed)d=!1;if(d&&(!X.writable||p))return;if(!p||J0)M.call(X)},y=(c)=>{M.call(X,c)},h=k(X),V0=()=>{h=!0;let c=u(X)||f(X);if(c&&typeof c!=="boolean")return M.call(X,c);if(w&&!i&&v(X,!0)){if(!N(X,!1))return M.call(X,new V)}if(p&&!J0){if(!Y0(X,!1))return M.call(X,new V)}M.call(X)},t=()=>{h=!0;let c=u(X)||f(X);if(c&&typeof c!=="boolean")return M.call(X,c);M.call(X)},e=()=>{X.req.on("finish",m)};if(Z(X)){if(X.on("complete",m),!d)X.on("abort",V0);if(X.req)e();else X.on("request",e)}else if(p&&!n)X.on("end",r),X.on("close",r);if(!d&&typeof X.aborted==="boolean")X.on("aborted",V0);if(X.on("end",g0),X.on("finish",m),$.error!==!1)X.on("error",y);if(X.on("close",V0),h)W.nextTick(V0);else if(n!==null&&n!==void 0&&n.errorEmitted||K0!==null&&K0!==void 0&&K0.errorEmitted){if(!d)W.nextTick(t)}else if(!w&&(!d||j(X))&&(J0||b(X)===!1))W.nextTick(t);else if(!p&&(!d||b(X))&&(i||j(X)===!1))W.nextTick(t);else if(K0&&X.req&&X.aborted)W.nextTick(t);let E0=()=>{if(M=Y,X.removeListener("aborted",V0),X.removeListener("complete",m),X.removeListener("abort",V0),X.removeListener("request",e),X.req)X.req.removeListener("finish",m);X.removeListener("end",r),X.removeListener("close",r),X.removeListener("finish",m),X.removeListener("end",g0),X.removeListener("error",y),X.removeListener("close",V0)};if($.signal&&!h){let c=()=>{let o=M;E0(),o.call(X,new T(void 0,{cause:$.signal.reason}))};if($.signal.aborted)W.nextTick(c);else{J=J||MU().addAbortListener;let o=J($.signal,c),N0=M;M=S((...s)=>{o[_](),N0.apply(X,s)})}}return E0}function F(X,$,M){let A=!1,B=Y;if($.signal)if(B=()=>{A=!0,M.call(X,new T(void 0,{cause:$.signal.reason}))},$.signal.aborted)W.nextTick(B);else{J=J||MU().addAbortListener;let p=J($.signal,B),n=M;M=S((...K0)=>{p[_](),n.apply(X,K0)})}let w=(...p)=>{if(!A)W.nextTick(()=>M.apply(X,p))};return q(X[Q].promise,w,w),Y}function G(X,$){var M;let A=!1;if($===null)$=P;if((M=$)!==null&&M!==void 0&&M.cleanup)z($.cleanup,"cleanup"),A=$.cleanup;return new R((B,w)=>{let p=K(X,$,(n)=>{if(A)p();if(n)w(n);else B()})})}O.exports=K,O.exports.finished=G}),tU=u0((I,O)=>{var W=dU(),{aggregateTwoErrors:T,codes:{ERR_MULTIPLE_CALLBACK:H},AbortError:L}=CU(),{Symbol:V}=o0(),{kIsDestroyed:P,isDestroyed:S,isFinished:E,isServerRequest:C}=NU(),D=V("kDestroy"),z=V("kConstruct");function R(U,Q,J){if(U){if(U.stack,Q&&!Q.errored)Q.errored=U;if(J&&!J.errored)J.errored=U}}function q(U,Q){let J=this._readableState,Z=this._writableState,Y=Z||J;if(Z!==null&&Z!==void 0&&Z.destroyed||J!==null&&J!==void 0&&J.destroyed){if(typeof Q==="function")Q();return this}if(R(U,Z,J),Z)Z.destroyed=!0;if(J)J.destroyed=!0;if(!Y.constructed)this.once(D,function(K){_(this,T(K,U),Q)});else _(this,U,Q);return this}function _(U,Q,J){let Z=!1;function Y(K){if(Z)return;Z=!0;let{_readableState:F,_writableState:G}=U;if(R(K,G,F),G)G.closed=!0;if(F)F.closed=!0;if(typeof J==="function")J(K);if(K)W.nextTick(k,U,K);else W.nextTick(j,U)}try{U._destroy(Q||null,Y)}catch(K){Y(K)}}function k(U,Q){v(U,Q),j(U)}function j(U){let{_readableState:Q,_writableState:J}=U;if(J)J.closeEmitted=!0;if(Q)Q.closeEmitted=!0;if(J!==null&&J!==void 0&&J.emitClose||Q!==null&&Q!==void 0&&Q.emitClose)U.emit("close")}function v(U,Q){let{_readableState:J,_writableState:Z}=U;if(Z!==null&&Z!==void 0&&Z.errorEmitted||J!==null&&J!==void 0&&J.errorEmitted)return;if(Z)Z.errorEmitted=!0;if(J)J.errorEmitted=!0;U.emit("error",Q)}function x(){let U=this._readableState,Q=this._writableState;if(U)U.constructed=!0,U.closed=!1,U.closeEmitted=!1,U.destroyed=!1,U.errored=null,U.errorEmitted=!1,U.reading=!1,U.ended=U.readable===!1,U.endEmitted=U.readable===!1;if(Q)Q.constructed=!0,Q.destroyed=!1,Q.closed=!1,Q.closeEmitted=!1,Q.errored=null,Q.errorEmitted=!1,Q.finalCalled=!1,Q.prefinished=!1,Q.ended=Q.writable===!1,Q.ending=Q.writable===!1,Q.finished=Q.writable===!1}function N(U,Q,J){let{_readableState:Z,_writableState:Y}=U;if(Y!==null&&Y!==void 0&&Y.destroyed||Z!==null&&Z!==void 0&&Z.destroyed)return this;if(Z!==null&&Z!==void 0&&Z.autoDestroy||Y!==null&&Y!==void 0&&Y.autoDestroy)U.destroy(Q);else if(Q){if(Q.stack,Y&&!Y.errored)Y.errored=Q;if(Z&&!Z.errored)Z.errored=Q;if(J)W.nextTick(v,U,Q);else v(U,Q)}}function f(U,Q){if(typeof U._construct!=="function")return;let{_readableState:J,_writableState:Z}=U;if(J)J.constructed=!1;if(Z)Z.constructed=!1;if(U.once(z,Q),U.listenerCount(z)>1)return;W.nextTick(b,U)}function b(U){let Q=!1;function J(Z){if(Q){N(U,Z!==null&&Z!==void 0?Z:new H);return}Q=!0;let{_readableState:Y,_writableState:K}=U,F=K||Y;if(Y)Y.constructed=!0;if(K)K.constructed=!0;if(F.destroyed)U.emit(D,Z);else if(Z)N(U,Z,!0);else W.nextTick(Q0,U)}try{U._construct((Z)=>{W.nextTick(J,Z)})}catch(Z){W.nextTick(J,Z)}}function Q0(U){U.emit(z)}function G0(U){return(U===null||U===void 0?void 0:U.setHeader)&&typeof U.abort==="function"}function Y0(U){U.emit("close")}function u(U,Q){U.emit("error",Q),W.nextTick(Y0,U)}function U0(U,Q){if(!U||S(U))return;if(!Q&&!E(U))Q=new L;if(C(U))U.socket=null,U.destroy(Q);else if(G0(U))U.abort();else if(G0(U.req))U.req.abort();else if(typeof U.destroy==="function")U.destroy(Q);else if(typeof U.close==="function")U.close();else if(Q)W.nextTick(u,U,Q);else W.nextTick(Y0,U);if(!U.destroyed)U[P]=!0}O.exports={construct:f,destroyer:U0,destroy:q,undestroy:x,errorOrDestroy:N}}),XZ=u0((I,O)=>{var{ArrayIsArray:W,ObjectSetPrototypeOf:T}=o0(),{EventEmitter:H}=(UX(),h0(iU));function L(P){H.call(this,P)}T(L.prototype,H.prototype),T(L,H),L.prototype.pipe=function(P,S){let E=this;function C(j){if(P.writable&&P.write(j)===!1&&E.pause)E.pause()}E.on("data",C);function D(){if(E.readable&&E.resume)E.resume()}if(P.on("drain",D),!P._isStdio&&(!S||S.end!==!1))E.on("end",R),E.on("close",q);let z=!1;function R(){if(z)return;z=!0,P.end()}function q(){if(z)return;if(z=!0,typeof P.destroy==="function")P.destroy()}function _(j){if(k(),H.listenerCount(this,"error")===0)this.emit("error",j)}V(E,"error",_),V(P,"error",_);function k(){E.removeListener("data",C),P.removeListener("drain",D),E.removeListener("end",R),E.removeListener("close",q),E.removeListener("error",_),P.removeListener("error",_),E.removeListener("end",k),E.removeListener("close",k),P.removeListener("close",k)}return E.on("end",k),E.on("close",k),P.on("close",k),P.emit("pipe",E),P};function V(P,S,E){if(typeof P.prependListener==="function")return P.prependListener(S,E);if(!P._events||!P._events[S])P.on(S,E);else if(W(P._events[S]))P._events[S].unshift(E);else P._events[S]=[E,P._events[S]]}O.exports={Stream:L,prependListener:V}}),LX=u0((I,O)=>{var{SymbolDispose:W}=o0(),{AbortError:T,codes:H}=CU(),{isNodeStream:L,isWebStream:V,kControllerErrorFunction:P}=NU(),S=yU(),{ERR_INVALID_ARG_TYPE:E}=H,C,D=(z,R)=>{if(typeof z!=="object"||!("aborted"in z))throw new E(R,"AbortSignal",z)};O.exports.addAbortSignal=function(z,R){if(D(z,"signal"),!L(R)&&!V(R))throw new E("stream",["ReadableStream","WritableStream","Stream"],R);return O.exports.addAbortSignalNoValidate(z,R)},O.exports.addAbortSignalNoValidate=function(z,R){if(typeof z!=="object"||!("aborted"in z))return R;let q=L(R)?()=>{R.destroy(new T(void 0,{cause:z.reason}))}:()=>{R[P](new T(void 0,{cause:z.reason}))};if(z.aborted)q();else{C=C||MU().addAbortListener;let _=C(z,q);S(R,_[W])}return R}}),KJ=u0((I,O)=>{var{StringPrototypeSlice:W,SymbolIterator:T,TypedArrayPrototypeSet:H,Uint8Array:L}=o0(),{Buffer:V}=(HU(),h0(WU)),{inspect:P}=MU();O.exports=class{constructor(){this.head=null,this.tail=null,this.length=0}push(S){let E={data:S,next:null};if(this.length>0)this.tail.next=E;else this.head=E;this.tail=E,++this.length}unshift(S){let E={data:S,next:this.head};if(this.length===0)this.tail=E;this.head=E,++this.length}shift(){if(this.length===0)return;let S=this.head.data;if(this.length===1)this.head=this.tail=null;else this.head=this.head.next;return--this.length,S}clear(){this.head=this.tail=null,this.length=0}join(S){if(this.length===0)return"";let E=this.head,C=""+E.data;while((E=E.next)!==null)C+=S+E.data;return C}concat(S){if(this.length===0)return V.alloc(0);let E=V.allocUnsafe(S>>>0),C=this.head,D=0;while(C)H(E,C.data,D),D+=C.data.length,C=C.next;return E}consume(S,E){let C=this.head.data;if(S<C.length){let D=C.slice(0,S);return this.head.data=C.slice(S),D}if(S===C.length)return this.shift();return E?this._getString(S):this._getBuffer(S)}first(){return this.head.data}*[T](){for(let S=this.head;S;S=S.next)yield S.data}_getString(S){let E="",C=this.head,D=0;do{let z=C.data;if(S>z.length)E+=z,S-=z.length;else{if(S===z.length)if(E+=z,++D,C.next)this.head=C.next;else this.head=this.tail=null;else E+=W(z,0,S),this.head=C,C.data=W(z,S);break}++D}while((C=C.next)!==null);return this.length-=D,E}_getBuffer(S){let E=V.allocUnsafe(S),C=S,D=this.head,z=0;do{let R=D.data;if(S>R.length)H(E,R,C-S),S-=R.length;else{if(S===R.length)if(H(E,R,C-S),++z,D.next)this.head=D.next;else this.head=this.tail=null;else H(E,new L(R.buffer,R.byteOffset,S),C-S),this.head=D,D.data=R.slice(S);break}++z}while((D=D.next)!==null);return this.length-=z,E}[Symbol.for("nodejs.util.inspect.custom")](S,E){return P(this,{...E,depth:0,customInspect:!1})}}}),MX=u0((I,O)=>{var{MathFloor:W,NumberIsInteger:T}=o0(),{validateInteger:H}=ZX(),{ERR_INVALID_ARG_VALUE:L}=CU().codes,V=16384,P=16;function S(z,R,q){return z.highWaterMark!=null?z.highWaterMark:R?z[q]:null}function E(z){return z?P:V}function C(z,R){if(H(R,"value",0),z)P=R;else V=R}function D(z,R,q,_){let k=S(R,_,q);if(k!=null){if(!T(k)||k<0){let j=_?`options.${q}`:"options.highWaterMark";throw new L(j,k)}return W(k)}return E(z.objectMode)}O.exports={getHighWaterMark:D,getDefaultHighWaterMark:E,setDefaultHighWaterMark:C}}),OJ=u0((I,O)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var W=(HU(),h0(WU)),T=W.Buffer;function H(V,P){for(var S in V)P[S]=V[S]}if(T.from&&T.alloc&&T.allocUnsafe&&T.allocUnsafeSlow)O.exports=W;else H(W,I),I.Buffer=L;function L(V,P,S){return T(V,P,S)}L.prototype=Object.create(T.prototype),H(T,L),L.from=function(V,P,S){if(typeof V==="number")throw TypeError("Argument must not be a number");return T(V,P,S)},L.alloc=function(V,P,S){if(typeof V!=="number")throw TypeError("Argument must be a number");var E=T(V);if(P!==void 0)if(typeof S==="string")E.fill(P,S);else E.fill(P);else E.fill(0);return E},L.allocUnsafe=function(V){if(typeof V!=="number")throw TypeError("Argument must be a number");return T(V)},L.allocUnsafeSlow=function(V){if(typeof V!=="number")throw TypeError("Argument must be a number");return W.SlowBuffer(V)}}),FJ=u0((I)=>{var O=OJ().Buffer,W=O.isEncoding||function(v){switch(v=""+v,v&&v.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 T(v){if(!v)return"utf8";var x;while(!0)switch(v){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 v;default:if(x)return;v=(""+v).toLowerCase(),x=!0}}function H(v){var x=T(v);if(typeof x!=="string"&&(O.isEncoding===W||!W(v)))throw Error("Unknown encoding: "+v);return x||v}I.StringDecoder=L;function L(v){this.encoding=H(v);var x;switch(this.encoding){case"utf16le":this.text=z,this.end=R,x=4;break;case"utf8":this.fillLast=E,x=4;break;case"base64":this.text=q,this.end=_,x=3;break;default:this.write=k,this.end=j;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=O.allocUnsafe(x)}L.prototype.write=function(v){if(v.length===0)return"";var x,N;if(this.lastNeed){if(x=this.fillLast(v),x===void 0)return"";N=this.lastNeed,this.lastNeed=0}else N=0;if(N<v.length)return x?x+this.text(v,N):this.text(v,N);return x||""},L.prototype.end=D,L.prototype.text=C,L.prototype.fillLast=function(v){if(this.lastNeed<=v.length)return v.copy(this.lastChar,this.lastTotal-this.lastNeed,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);v.copy(this.lastChar,this.lastTotal-this.lastNeed,0,v.length),this.lastNeed-=v.length};function V(v){if(v<=127)return 0;else if(v>>5===6)return 2;else if(v>>4===14)return 3;else if(v>>3===30)return 4;return v>>6===2?-1:-2}function P(v,x,N){var f=x.length-1;if(f<N)return 0;var b=V(x[f]);if(b>=0){if(b>0)v.lastNeed=b-1;return b}if(--f<N||b===-2)return 0;if(b=V(x[f]),b>=0){if(b>0)v.lastNeed=b-2;return b}if(--f<N||b===-2)return 0;if(b=V(x[f]),b>=0){if(b>0)if(b===2)b=0;else v.lastNeed=b-3;return b}return 0}function S(v,x,N){if((x[0]&192)!==128)return v.lastNeed=0,"�";if(v.lastNeed>1&&x.length>1){if((x[1]&192)!==128)return v.lastNeed=1,"�";if(v.lastNeed>2&&x.length>2){if((x[2]&192)!==128)return v.lastNeed=2,"�"}}}function E(v){var x=this.lastTotal-this.lastNeed,N=S(this,v,x);if(N!==void 0)return N;if(this.lastNeed<=v.length)return v.copy(this.lastChar,x,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal);v.copy(this.lastChar,x,0,v.length),this.lastNeed-=v.length}function C(v,x){var N=P(this,v,x);if(!this.lastNeed)return v.toString("utf8",x);this.lastTotal=N;var f=v.length-(N-this.lastNeed);return v.copy(this.lastChar,0,f),v.toString("utf8",x,f)}function D(v){var x=v&&v.length?this.write(v):"";if(this.lastNeed)return x+"�";return x}function z(v,x){if((v.length-x)%2===0){var N=v.toString("utf16le",x);if(N){var f=N.charCodeAt(N.length-1);if(f>=55296&&f<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=v[v.length-2],this.lastChar[1]=v[v.length-1],N.slice(0,-1)}return N}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=v[v.length-1],v.toString("utf16le",x,v.length-1)}function R(v){var x=v&&v.length?this.write(v):"";if(this.lastNeed){var N=this.lastTotal-this.lastNeed;return x+this.lastChar.toString("utf16le",0,N)}return x}function q(v,x){var N=(v.length-x)%3;if(N===0)return v.toString("base64",x);if(this.lastNeed=3-N,this.lastTotal=3,N===1)this.lastChar[0]=v[v.length-1];else this.lastChar[0]=v[v.length-2],this.lastChar[1]=v[v.length-1];return v.toString("base64",x,v.length-N)}function _(v){var x=v&&v.length?this.write(v):"";if(this.lastNeed)return x+this.lastChar.toString("base64",0,3-this.lastNeed);return x}function k(v){return v.toString(this.encoding)}function j(v){return v&&v.length?this.write(v):""}}),KQ=u0((I,O)=>{var W=dU(),{PromisePrototypeThen:T,SymbolAsyncIterator:H,SymbolIterator:L}=o0(),{Buffer:V}=(HU(),h0(WU)),{ERR_INVALID_ARG_TYPE:P,ERR_STREAM_NULL_VALUES:S}=CU().codes;function E(C,D,z){let R;if(typeof D==="string"||D instanceof V)return new C({objectMode:!0,...z,read(){this.push(D),this.push(null)}});let q;if(D&&D[H])q=!0,R=D[H]();else if(D&&D[L])q=!1,R=D[L]();else throw new P("iterable",["Iterable"],D);let _=new C({objectMode:!0,highWaterMark:1,...z}),k=!1;_._read=function(){if(!k)k=!0,v()},_._destroy=function(x,N){T(j(x),()=>W.nextTick(N,x),(f)=>W.nextTick(N,f||x))};async function j(x){let N=x!==void 0&&x!==null,f=typeof R.throw==="function";if(N&&f){let{value:b,done:Q0}=await R.throw(x);if(await b,Q0)return}if(typeof R.return==="function"){let{value:b}=await R.return();await b}}async function v(){for(;;){try{let{value:x,done:N}=q?await R.next():R.next();if(N)_.push(null);else{let f=x&&typeof x.then==="function"?await x:x;if(f===null)throw k=!1,new S;else if(_.push(f))continue;else k=!1}}catch(x){_.destroy(x)}break}}return _}O.exports=E}),RX=u0((I,O)=>{var W=dU(),{ArrayPrototypeIndexOf:T,NumberIsInteger:H,NumberIsNaN:L,NumberParseInt:V,ObjectDefineProperties:P,ObjectKeys:S,ObjectSetPrototypeOf:E,Promise:C,SafeSet:D,SymbolAsyncDispose:z,SymbolAsyncIterator:R,Symbol:q}=o0();O.exports=s,s.ReadableState=N0;var{EventEmitter:_}=(UX(),h0(iU)),{Stream:k,prependListener:j}=XZ(),{Buffer:v}=(HU(),h0(WU)),{addAbortSignal:x}=LX(),N=yU(),f=MU().debuglog("stream",(g)=>{f=g}),b=KJ(),Q0=tU(),{getHighWaterMark:G0,getDefaultHighWaterMark:Y0}=MX(),{aggregateTwoErrors:u,codes:{ERR_INVALID_ARG_TYPE:U0,ERR_METHOD_NOT_IMPLEMENTED:U,ERR_OUT_OF_RANGE:Q,ERR_STREAM_PUSH_AFTER_EOF:J,ERR_STREAM_UNSHIFT_AFTER_END_EVENT:Z},AbortError:Y}=CU(),{validateObject:K}=ZX(),F=q("kPaused"),{StringDecoder:G}=FJ(),X=KQ();E(s.prototype,k.prototype),E(s,k);var $=()=>{},{errorOrDestroy:M}=Q0,A=1,B=2,w=4,p=8,n=16,K0=32,r=64,d=128,J0=256,m=512,i=1024,g0=2048,y=4096,h=8192,V0=16384,t=32768,e=65536,E0=131072,c=262144;function o(g){return{enumerable:!1,get(){return(this.state&g)!==0},set(l){if(l)this.state|=g;else this.state&=~g}}}P(N0.prototype,{objectMode:o(A),ended:o(B),endEmitted:o(w),reading:o(p),constructed:o(n),sync:o(K0),needReadable:o(r),emittedReadable:o(d),readableListening:o(J0),resumeScheduled:o(m),errorEmitted:o(i),emitClose:o(g0),autoDestroy:o(y),destroyed:o(h),closed:o(V0),closeEmitted:o(t),multiAwaitDrain:o(e),readingMore:o(E0),dataEmitted:o(c)});function N0(g,l,a){if(typeof a!=="boolean")a=l instanceof xU();if(this.state=g0|y|n|K0,g&&g.objectMode)this.state|=A;if(a&&g&&g.readableObjectMode)this.state|=A;if(this.highWaterMark=g?G0(this,g,"readableHighWaterMark",a):Y0(!1),this.buffer=new b,this.length=0,this.pipes=[],this.flowing=null,this[F]=null,g&&g.emitClose===!1)this.state&=~g0;if(g&&g.autoDestroy===!1)this.state&=~y;if(this.errored=null,this.defaultEncoding=g&&g.defaultEncoding||"utf8",this.awaitDrainWriters=null,this.decoder=null,this.encoding=null,g&&g.encoding)this.decoder=new G(g.encoding),this.encoding=g.encoding}function s(g){if(!(this instanceof s))return new s(g);let l=this instanceof xU();if(this._readableState=new N0(g,this,l),g){if(typeof g.read==="function")this._read=g.read;if(typeof g.destroy==="function")this._destroy=g.destroy;if(typeof g.construct==="function")this._construct=g.construct;if(g.signal&&!l)x(g.signal,this)}k.call(this,g),Q0.construct(this,()=>{if(this._readableState.needReadable)z0(this,this._readableState)})}s.prototype.destroy=Q0.destroy,s.prototype._undestroy=Q0.undestroy,s.prototype._destroy=function(g,l){l(g)},s.prototype[_.captureRejectionSymbol]=function(g){this.destroy(g)},s.prototype[z]=function(){let g;if(!this.destroyed)g=this.readableEnded?null:new Y,this.destroy(g);return new C((l,a)=>N(this,(X0)=>X0&&X0!==g?a(X0):l(null)))},s.prototype.push=function(g,l){return Z0(this,g,l,!1)},s.prototype.unshift=function(g,l){return Z0(this,g,l,!0)};function Z0(g,l,a,X0){f("readableAddChunk",l);let w0=g._readableState,F0;if((w0.state&A)===0){if(typeof l==="string"){if(a=a||w0.defaultEncoding,w0.encoding!==a)if(X0&&w0.encoding)l=v.from(l,a).toString(w0.encoding);else l=v.from(l,a),a=""}else if(l instanceof v)a="";else if(k._isUint8Array(l))l=k._uint8ArrayToBuffer(l),a="";else if(l!=null)F0=new U0("chunk",["string","Buffer","Uint8Array"],l)}if(F0)M(g,F0);else if(l===null)w0.state&=~p,O0(g,w0);else if((w0.state&A)!==0||l&&l.length>0)if(X0)if((w0.state&w)!==0)M(g,new Z);else if(w0.destroyed||w0.errored)return!1;else f0(g,w0,l,!0);else if(w0.ended)M(g,new J);else if(w0.destroyed||w0.errored)return!1;else if(w0.state&=~p,w0.decoder&&!a)if(l=w0.decoder.write(l),w0.objectMode||l.length!==0)f0(g,w0,l,!1);else z0(g,w0);else f0(g,w0,l,!1);else if(!X0)w0.state&=~p,z0(g,w0);return!w0.ended&&(w0.length<w0.highWaterMark||w0.length===0)}function f0(g,l,a,X0){if(l.flowing&&l.length===0&&!l.sync&&g.listenerCount("data")>0){if((l.state&e)!==0)l.awaitDrainWriters.clear();else l.awaitDrainWriters=null;l.dataEmitted=!0,g.emit("data",a)}else{if(l.length+=l.objectMode?1:a.length,X0)l.buffer.unshift(a);else l.buffer.push(a);if((l.state&r)!==0)D0(g)}z0(g,l)}s.prototype.isPaused=function(){let g=this._readableState;return g[F]===!0||g.flowing===!1},s.prototype.setEncoding=function(g){let l=new G(g);this._readableState.decoder=l,this._readableState.encoding=this._readableState.decoder.encoding;let a=this._readableState.buffer,X0="";for(let w0 of a)X0+=l.write(w0);if(a.clear(),X0!=="")a.push(X0);return this._readableState.length=X0.length,this};var W0=1073741824;function H0(g){if(g>W0)throw new Q("size","<= 1GiB",g);else g--,g|=g>>>1,g|=g>>>2,g|=g>>>4,g|=g>>>8,g|=g>>>16,g++;return g}function n0(g,l){if(g<=0||l.length===0&&l.ended)return 0;if((l.state&A)!==0)return 1;if(L(g)){if(l.flowing&&l.length)return l.buffer.first().length;return l.length}if(g<=l.length)return g;return l.ended?l.length:0}s.prototype.read=function(g){if(f("read",g),g===void 0)g=NaN;else if(!H(g))g=V(g,10);let l=this._readableState,a=g;if(g>l.highWaterMark)l.highWaterMark=H0(g);if(g!==0)l.state&=~d;if(g===0&&l.needReadable&&((l.highWaterMark!==0?l.length>=l.highWaterMark:l.length>0)||l.ended)){if(f("read: emitReadable",l.length,l.ended),l.length===0&&l.ended)KU(this);else D0(this);return null}if(g=n0(g,l),g===0&&l.ended){if(l.length===0)KU(this);return null}let X0=(l.state&r)!==0;if(f("need readable",X0),l.length===0||l.length-g<l.highWaterMark)X0=!0,f("length less than watermark",X0);if(l.ended||l.reading||l.destroyed||l.errored||!l.constructed)X0=!1,f("reading, ended or constructing",X0);else if(X0){if(f("do read"),l.state|=p|K0,l.length===0)l.state|=r;try{this._read(l.highWaterMark)}catch(F0){M(this,F0)}if(l.state&=~K0,!l.reading)g=n0(a,l)}let w0;if(g>0)w0=R0(g,l);else w0=null;if(w0===null)l.needReadable=l.length<=l.highWaterMark,g=0;else if(l.length-=g,l.multiAwaitDrain)l.awaitDrainWriters.clear();else l.awaitDrainWriters=null;if(l.length===0){if(!l.ended)l.needReadable=!0;if(a!==g&&l.ended)KU(this)}if(w0!==null&&!l.errorEmitted&&!l.closeEmitted)l.dataEmitted=!0,this.emit("data",w0);return w0};function O0(g,l){if(f("onEofChunk"),l.ended)return;if(l.decoder){let a=l.decoder.end();if(a&&a.length)l.buffer.push(a),l.length+=l.objectMode?1:a.length}if(l.ended=!0,l.sync)D0(g);else l.needReadable=!1,l.emittedReadable=!0,t0(g)}function D0(g){let l=g._readableState;if(f("emitReadable",l.needReadable,l.emittedReadable),l.needReadable=!1,!l.emittedReadable)f("emitReadable",l.flowing),l.emittedReadable=!0,W.nextTick(t0,g)}function t0(g){let l=g._readableState;if(f("emitReadable_",l.destroyed,l.length,l.ended),!l.destroyed&&!l.errored&&(l.length||l.ended))g.emit("readable"),l.emittedReadable=!1;l.needReadable=!l.flowing&&!l.ended&&l.length<=l.highWaterMark,M0(g)}function z0(g,l){if(!l.readingMore&&l.constructed)l.readingMore=!0,W.nextTick(A0,g,l)}function A0(g,l){while(!l.reading&&!l.ended&&(l.length<l.highWaterMark||l.flowing&&l.length===0)){let a=l.length;if(f("maybeReadMore read 0"),g.read(0),a===l.length)break}l.readingMore=!1}s.prototype._read=function(g){throw new U("_read()")},s.prototype.pipe=function(g,l){let a=this,X0=this._readableState;if(X0.pipes.length===1){if(!X0.multiAwaitDrain)X0.multiAwaitDrain=!0,X0.awaitDrainWriters=new D(X0.awaitDrainWriters?[X0.awaitDrainWriters]:[])}X0.pipes.push(g),f("pipe count=%d opts=%j",X0.pipes.length,l);let w0=(!l||l.end!==!1)&&g!==W.stdout&&g!==W.stderr?T0:y0;if(X0.endEmitted)W.nextTick(w0);else a.once("end",w0);g.on("unpipe",F0);function F0(l0,b0){if(f("onunpipe"),l0===a){if(b0&&b0.hasUnpiped===!1)b0.hasUnpiped=!0,x0()}}function T0(){f("onend"),g.end()}let m0,S0=!1;function x0(){if(f("cleanup"),g.removeListener("close",s0),g.removeListener("finish",c0),m0)g.removeListener("drain",m0);if(g.removeListener("error",C0),g.removeListener("unpipe",F0),a.removeListener("end",T0),a.removeListener("end",y0),a.removeListener("data",P0),S0=!0,m0&&X0.awaitDrainWriters&&(!g._writableState||g._writableState.needDrain))m0()}function TU(){if(!S0){if(X0.pipes.length===1&&X0.pipes[0]===g)f("false write response, pause",0),X0.awaitDrainWriters=g,X0.multiAwaitDrain=!1;else if(X0.pipes.length>1&&X0.pipes.includes(g))f("false write response, pause",X0.awaitDrainWriters.size),X0.awaitDrainWriters.add(g);a.pause()}if(!m0)m0=AU(a,g),g.on("drain",m0)}a.on("data",P0);function P0(l0){f("ondata");let b0=g.write(l0);if(f("dest.write",b0),b0===!1)TU()}function C0(l0){if(f("onerror",l0),y0(),g.removeListener("error",C0),g.listenerCount("error")===0){let b0=g._writableState||g._readableState;if(b0&&!b0.errorEmitted)M(g,l0);else g.emit("error",l0)}}j(g,"error",C0);function s0(){g.removeListener("finish",c0),y0()}g.once("close",s0);function c0(){f("onfinish"),g.removeListener("close",s0),y0()}g.once("finish",c0);function y0(){f("unpipe"),a.unpipe(g)}if(g.emit("pipe",a),g.writableNeedDrain===!0)TU();else if(!X0.flowing)f("pipe resume"),a.resume();return g};function AU(g,l){return function(){let a=g._readableState;if(a.awaitDrainWriters===l)f("pipeOnDrain",1),a.awaitDrainWriters=null;else if(a.multiAwaitDrain)f("pipeOnDrain",a.awaitDrainWriters.size),a.awaitDrainWriters.delete(l);if((!a.awaitDrainWriters||a.awaitDrainWriters.size===0)&&g.listenerCount("data"))g.resume()}}s.prototype.unpipe=function(g){let l=this._readableState,a={hasUnpiped:!1};if(l.pipes.length===0)return this;if(!g){let w0=l.pipes;l.pipes=[],this.pause();for(let F0=0;F0<w0.length;F0++)w0[F0].emit("unpipe",this,{hasUnpiped:!1});return this}let X0=T(l.pipes,g);if(X0===-1)return this;if(l.pipes.splice(X0,1),l.pipes.length===0)this.pause();return g.emit("unpipe",this,a),this},s.prototype.on=function(g,l){let a=k.prototype.on.call(this,g,l),X0=this._readableState;if(g==="data"){if(X0.readableListening=this.listenerCount("readable")>0,X0.flowing!==!1)this.resume()}else if(g==="readable"){if(!X0.endEmitted&&!X0.readableListening){if(X0.readableListening=X0.needReadable=!0,X0.flowing=!1,X0.emittedReadable=!1,f("on readable",X0.length,X0.reading),X0.length)D0(this);else if(!X0.reading)W.nextTick(k0,this)}}return a},s.prototype.addListener=s.prototype.on,s.prototype.removeListener=function(g,l){let a=k.prototype.removeListener.call(this,g,l);if(g==="readable")W.nextTick(L0,this);return a},s.prototype.off=s.prototype.removeListener,s.prototype.removeAllListeners=function(g){let l=k.prototype.removeAllListeners.apply(this,arguments);if(g==="readable"||g===void 0)W.nextTick(L0,this);return l};function L0(g){let l=g._readableState;if(l.readableListening=g.listenerCount("readable")>0,l.resumeScheduled&&l[F]===!1)l.flowing=!0;else if(g.listenerCount("data")>0)g.resume();else if(!l.readableListening)l.flowing=null}function k0(g){f("readable nexttick read 0"),g.read(0)}s.prototype.resume=function(){let g=this._readableState;if(!g.flowing)f("resume"),g.flowing=!g.readableListening,zU(this,g);return g[F]=!1,this};function zU(g,l){if(!l.resumeScheduled)l.resumeScheduled=!0,W.nextTick(j0,g,l)}function j0(g,l){if(f("resume",l.reading),!l.reading)g.read(0);if(l.resumeScheduled=!1,g.emit("resume"),M0(g),l.flowing&&!l.reading)g.read(0)}s.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[F]=!0,this};function M0(g){let l=g._readableState;f("flow",l.flowing);while(l.flowing&&g.read()!==null);}s.prototype.wrap=function(g){let l=!1;g.on("data",(X0)=>{if(!this.push(X0)&&g.pause)l=!0,g.pause()}),g.on("end",()=>{this.push(null)}),g.on("error",(X0)=>{M(this,X0)}),g.on("close",()=>{this.destroy()}),g.on("destroy",()=>{this.destroy()}),this._read=()=>{if(l&&g.resume)l=!1,g.resume()};let a=S(g);for(let X0=1;X0<a.length;X0++){let w0=a[X0];if(this[w0]===void 0&&typeof g[w0]==="function")this[w0]=g[w0].bind(g)}return this},s.prototype[R]=function(){return DU(this)},s.prototype.iterator=function(g){if(g!==void 0)K(g,"options");return DU(this,g)};function DU(g,l){if(typeof g.read!=="function")g=s.wrap(g,{objectMode:!0});let a=v0(g,l);return a.stream=g,a}async function*v0(g,l){let a=$;function X0(T0){if(this===g)a(),a=$;else a=T0}g.on("readable",X0);let w0,F0=N(g,{writable:!1},(T0)=>{w0=T0?u(w0,T0):null,a(),a=$});try{while(!0){let T0=g.destroyed?null:g.read();if(T0!==null)yield T0;else if(w0)throw w0;else if(w0===null)return;else await new C(X0)}}catch(T0){throw w0=u(w0,T0),w0}finally{if((w0||(l===null||l===void 0?void 0:l.destroyOnReturn)!==!1)&&(w0===void 0||g._readableState.autoDestroy))Q0.destroyer(g,null);else g.off("readable",X0),F0()}}P(s.prototype,{readable:{__proto__:null,get(){let g=this._readableState;return!!g&&g.readable!==!1&&!g.destroyed&&!g.errorEmitted&&!g.endEmitted},set(g){if(this._readableState)this._readableState.readable=!!g}},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(g){if(this._readableState)this._readableState.flowing=g}},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(g){if(!this._readableState)return;this._readableState.destroyed=g}},readableEnded:{__proto__:null,enumerable:!1,get(){return this._readableState?this._readableState.endEmitted:!1}}}),P(N0.prototype,{pipesCount:{__proto__:null,get(){return this.pipes.length}},paused:{__proto__:null,get(){return this[F]!==!1},set(g){this[F]=!!g}}}),s._fromList=R0;function R0(g,l){if(l.length===0)return null;let a;if(l.objectMode)a=l.buffer.shift();else if(!g||g>=l.length){if(l.decoder)a=l.buffer.join("");else if(l.buffer.length===1)a=l.buffer.first();else a=l.buffer.concat(l.length);l.buffer.clear()}else a=l.buffer.consume(g,l.decoder);return a}function KU(g){let l=g._readableState;if(f("endReadable",l.endEmitted),!l.endEmitted)l.ended=!0,W.nextTick(_0,l,g)}function _0(g,l){if(f("endReadableNT",g.endEmitted,g.length),!g.errored&&!g.closeEmitted&&!g.endEmitted&&g.length===0){if(g.endEmitted=!0,l.emit("end"),l.writable&&l.allowHalfOpen===!1)W.nextTick(B0,l);else if(g.autoDestroy){let a=l._writableState;if(!a||a.autoDestroy&&(a.finished||a.writable===!1))l.destroy()}}}function B0(g){if(g.writable&&!g.writableEnded&&!g.destroyed)g.end()}s.from=function(g,l){return X(s,g,l)};var OU;function q0(){if(OU===void 0)OU={};return OU}s.fromWeb=function(g,l){return q0().newStreamReadableFromReadableStream(g,l)},s.toWeb=function(g,l){return q0().newReadableStreamFromStreamReadable(g,l)},s.wrap=function(g,l){var a,X0;return new s({objectMode:(a=(X0=g.readableObjectMode)!==null&&X0!==void 0?X0:g.objectMode)!==null&&a!==void 0?a:!0,...l,destroy(w0,F0){Q0.destroyer(g,w0),F0(w0)}}).wrap(g)}}),ZZ=u0((I,O)=>{var W=dU(),{ArrayPrototypeSlice:T,Error:H,FunctionPrototypeSymbolHasInstance:L,ObjectDefineProperty:V,ObjectDefineProperties:P,ObjectSetPrototypeOf:S,StringPrototypeToLowerCase:E,Symbol:C,SymbolHasInstance:D}=o0();O.exports=K,K.WritableState=Z;var{EventEmitter:z}=(UX(),h0(iU)),R=XZ().Stream,{Buffer:q}=(HU(),h0(WU)),_=tU(),{addAbortSignal:k}=LX(),{getHighWaterMark:j,getDefaultHighWaterMark:v}=MX(),{ERR_INVALID_ARG_TYPE:x,ERR_METHOD_NOT_IMPLEMENTED:N,ERR_MULTIPLE_CALLBACK:f,ERR_STREAM_CANNOT_PIPE:b,ERR_STREAM_DESTROYED:Q0,ERR_STREAM_ALREADY_FINISHED:G0,ERR_STREAM_NULL_VALUES:Y0,ERR_STREAM_WRITE_AFTER_END:u,ERR_UNKNOWN_ENCODING:U0}=CU().codes,{errorOrDestroy:U}=_;S(K.prototype,R.prototype),S(K,R);function Q(){}var J=C("kOnFinished");function Z(y,h,V0){if(typeof V0!=="boolean")V0=h instanceof xU();if(this.objectMode=!!(y&&y.objectMode),V0)this.objectMode=this.objectMode||!!(y&&y.writableObjectMode);this.highWaterMark=y?j(this,y,"writableHighWaterMark",V0):v(!1),this.finalCalled=!1,this.needDrain=!1,this.ending=!1,this.ended=!1,this.finished=!1,this.destroyed=!1;let t=!!(y&&y.decodeStrings===!1);this.decodeStrings=!t,this.defaultEncoding=y&&y.defaultEncoding||"utf8",this.length=0,this.writing=!1,this.corked=0,this.sync=!0,this.bufferProcessing=!1,this.onwrite=M.bind(void 0,h),this.writecb=null,this.writelen=0,this.afterWriteTickInfo=null,Y(this),this.pendingcb=0,this.constructed=!0,this.prefinished=!1,this.errorEmitted=!1,this.emitClose=!y||y.emitClose!==!1,this.autoDestroy=!y||y.autoDestroy!==!1,this.errored=null,this.closed=!1,this.closeEmitted=!1,this[J]=[]}function Y(y){y.buffered=[],y.bufferedIndex=0,y.allBuffers=!0,y.allNoop=!0}Z.prototype.getBuffer=function(){return T(this.buffered,this.bufferedIndex)},V(Z.prototype,"bufferedRequestCount",{__proto__:null,get(){return this.buffered.length-this.bufferedIndex}});function K(y){let h=this instanceof xU();if(!h&&!L(K,this))return new K(y);if(this._writableState=new Z(y,this,h),y){if(typeof y.write==="function")this._write=y.write;if(typeof y.writev==="function")this._writev=y.writev;if(typeof y.destroy==="function")this._destroy=y.destroy;if(typeof y.final==="function")this._final=y.final;if(typeof y.construct==="function")this._construct=y.construct;if(y.signal)k(y.signal,this)}R.call(this,y),_.construct(this,()=>{let V0=this._writableState;if(!V0.writing)p(this,V0);d(this,V0)})}V(K,D,{__proto__:null,value:function(y){if(L(this,y))return!0;if(this!==K)return!1;return y&&y._writableState instanceof Z}}),K.prototype.pipe=function(){U(this,new b)};function F(y,h,V0,t){let e=y._writableState;if(typeof V0==="function")t=V0,V0=e.defaultEncoding;else{if(!V0)V0=e.defaultEncoding;else if(V0!=="buffer"&&!q.isEncoding(V0))throw new U0(V0);if(typeof t!=="function")t=Q}if(h===null)throw new Y0;else if(!e.objectMode)if(typeof h==="string"){if(e.decodeStrings!==!1)h=q.from(h,V0),V0="buffer"}else if(h instanceof q)V0="buffer";else if(R._isUint8Array(h))h=R._uint8ArrayToBuffer(h),V0="buffer";else throw new x("chunk",["string","Buffer","Uint8Array"],h);let E0;if(e.ending)E0=new u;else if(e.destroyed)E0=new Q0("write");if(E0)return W.nextTick(t,E0),U(y,E0,!0),E0;return e.pendingcb++,G(y,e,h,V0,t)}K.prototype.write=function(y,h,V0){return F(this,y,h,V0)===!0},K.prototype.cork=function(){this._writableState.corked++},K.prototype.uncork=function(){let y=this._writableState;if(y.corked){if(y.corked--,!y.writing)p(this,y)}},K.prototype.setDefaultEncoding=function(y){if(typeof y==="string")y=E(y);if(!q.isEncoding(y))throw new U0(y);return this._writableState.defaultEncoding=y,this};function G(y,h,V0,t,e){let E0=h.objectMode?1:V0.length;h.length+=E0;let c=h.length<h.highWaterMark;if(!c)h.needDrain=!0;if(h.writing||h.corked||h.errored||!h.constructed){if(h.buffered.push({chunk:V0,encoding:t,callback:e}),h.allBuffers&&t!=="buffer")h.allBuffers=!1;if(h.allNoop&&e!==Q)h.allNoop=!1}else h.writelen=E0,h.writecb=e,h.writing=!0,h.sync=!0,y._write(V0,t,h.onwrite),h.sync=!1;return c&&!h.errored&&!h.destroyed}function X(y,h,V0,t,e,E0,c){if(h.writelen=t,h.writecb=c,h.writing=!0,h.sync=!0,h.destroyed)h.onwrite(new Q0("write"));else if(V0)y._writev(e,h.onwrite);else y._write(e,E0,h.onwrite);h.sync=!1}function $(y,h,V0,t){--h.pendingcb,t(V0),w(h),U(y,V0)}function M(y,h){let V0=y._writableState,t=V0.sync,e=V0.writecb;if(typeof e!=="function"){U(y,new f);return}if(V0.writing=!1,V0.writecb=null,V0.length-=V0.writelen,V0.writelen=0,h){if(h.stack,!V0.errored)V0.errored=h;if(y._readableState&&!y._readableState.errored)y._readableState.errored=h;if(t)W.nextTick($,y,V0,h,e);else $(y,V0,h,e)}else{if(V0.buffered.length>V0.bufferedIndex)p(y,V0);if(t)if(V0.afterWriteTickInfo!==null&&V0.afterWriteTickInfo.cb===e)V0.afterWriteTickInfo.count++;else V0.afterWriteTickInfo={count:1,cb:e,stream:y,state:V0},W.nextTick(A,V0.afterWriteTickInfo);else B(y,V0,1,e)}}function A({stream:y,state:h,count:V0,cb:t}){return h.afterWriteTickInfo=null,B(y,h,V0,t)}function B(y,h,V0,t){if(!h.ending&&!y.destroyed&&h.length===0&&h.needDrain)h.needDrain=!1,y.emit("drain");while(V0-- >0)h.pendingcb--,t();if(h.destroyed)w(h);d(y,h)}function w(y){if(y.writing)return;for(let e=y.bufferedIndex;e<y.buffered.length;++e){var h;let{chunk:E0,callback:c}=y.buffered[e],o=y.objectMode?1:E0.length;y.length-=o,c((h=y.errored)!==null&&h!==void 0?h:new Q0("write"))}let V0=y[J].splice(0);for(let e=0;e<V0.length;e++){var t;V0[e]((t=y.errored)!==null&&t!==void 0?t:new Q0("end"))}Y(y)}function p(y,h){if(h.corked||h.bufferProcessing||h.destroyed||!h.constructed)return;let{buffered:V0,bufferedIndex:t,objectMode:e}=h,E0=V0.length-t;if(!E0)return;let c=t;if(h.bufferProcessing=!0,E0>1&&y._writev){h.pendingcb-=E0-1;let o=h.allNoop?Q:(s)=>{for(let Z0=c;Z0<V0.length;++Z0)V0[Z0].callback(s)},N0=h.allNoop&&c===0?V0:T(V0,c);N0.allBuffers=h.allBuffers,X(y,h,!0,h.length,N0,"",o),Y(h)}else{do{let{chunk:o,encoding:N0,callback:s}=V0[c];V0[c++]=null;let Z0=e?1:o.length;X(y,h,!1,Z0,o,N0,s)}while(c<V0.length&&!h.writing);if(c===V0.length)Y(h);else if(c>256)V0.splice(0,c),h.bufferedIndex=0;else h.bufferedIndex=c}h.bufferProcessing=!1}K.prototype._write=function(y,h,V0){if(this._writev)this._writev([{chunk:y,encoding:h}],V0);else throw new N("_write()")},K.prototype._writev=null,K.prototype.end=function(y,h,V0){let t=this._writableState;if(typeof y==="function")V0=y,y=null,h=null;else if(typeof h==="function")V0=h,h=null;let e;if(y!==null&&y!==void 0){let E0=F(this,y,h);if(E0 instanceof H)e=E0}if(t.corked)t.corked=1,this.uncork();if(e);else if(!t.errored&&!t.ending)t.ending=!0,d(this,t,!0),t.ended=!0;else if(t.finished)e=new G0("end");else if(t.destroyed)e=new Q0("end");if(typeof V0==="function")if(e||t.finished)W.nextTick(V0,e);else t[J].push(V0);return this};function n(y){return y.ending&&!y.destroyed&&y.constructed&&y.length===0&&!y.errored&&y.buffered.length===0&&!y.finished&&!y.writing&&!y.errorEmitted&&!y.closeEmitted}function K0(y,h){let V0=!1;function t(e){if(V0){U(y,e!==null&&e!==void 0?e:f());return}if(V0=!0,h.pendingcb--,e){let E0=h[J].splice(0);for(let c=0;c<E0.length;c++)E0[c](e);U(y,e,h.sync)}else if(n(h))h.prefinished=!0,y.emit("prefinish"),h.pendingcb++,W.nextTick(J0,y,h)}h.sync=!0,h.pendingcb++;try{y._final(t)}catch(e){t(e)}h.sync=!1}function r(y,h){if(!h.prefinished&&!h.finalCalled)if(typeof y._final==="function"&&!h.destroyed)h.finalCalled=!0,K0(y,h);else h.prefinished=!0,y.emit("prefinish")}function d(y,h,V0){if(n(h)){if(r(y,h),h.pendingcb===0){if(V0)h.pendingcb++,W.nextTick((t,e)=>{if(n(e))J0(t,e);else e.pendingcb--},y,h);else if(n(h))h.pendingcb++,J0(y,h)}}}function J0(y,h){h.pendingcb--,h.finished=!0;let V0=h[J].splice(0);for(let t=0;t<V0.length;t++)V0[t]();if(y.emit("finish"),h.autoDestroy){let t=y._readableState;if(!t||t.autoDestroy&&(t.endEmitted||t.readable===!1))y.destroy()}}P(K.prototype,{closed:{__proto__:null,get(){return this._writableState?this._writableState.closed:!1}},destroyed:{__proto__:null,get(){return this._writableState?this._writableState.destroyed:!1},set(y){if(this._writableState)this._writableState.destroyed=y}},writable:{__proto__:null,get(){let y=this._writableState;return!!y&&y.writable!==!1&&!y.destroyed&&!y.errored&&!y.ending&&!y.ended},set(y){if(this._writableState)this._writableState.writable=!!y}},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 y=this._writableState;if(!y)return!1;return!y.destroyed&&!y.ending&&y.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 m=_.destroy;K.prototype.destroy=function(y,h){let V0=this._writableState;if(!V0.destroyed&&(V0.bufferedIndex<V0.buffered.length||V0[J].length))W.nextTick(w,V0);return m.call(this,y,h),this},K.prototype._undestroy=_.undestroy,K.prototype._destroy=function(y,h){h(y)},K.prototype[z.captureRejectionSymbol]=function(y){this.destroy(y)};var i;function g0(){if(i===void 0)i={};return i}K.fromWeb=function(y,h){return g0().newStreamWritableFromWritableStream(y,h)},K.toWeb=function(y){return g0().newWritableStreamFromStreamWritable(y)}}),WJ=u0((I,O)=>{var W=dU(),T=(HU(),h0(WU)),{isReadable:H,isWritable:L,isIterable:V,isNodeStream:P,isReadableNodeStream:S,isWritableNodeStream:E,isDuplexNodeStream:C,isReadableStream:D,isWritableStream:z}=NU(),R=yU(),{AbortError:q,codes:{ERR_INVALID_ARG_TYPE:_,ERR_INVALID_RETURN_VALUE:k}}=CU(),{destroyer:j}=tU(),v=xU(),x=RX(),N=ZZ(),{createDeferredPromise:f}=MU(),b=KQ(),Q0=globalThis.Blob||T.Blob,G0=typeof Q0<"u"?function(J){return J instanceof Q0}:function(J){return!1},Y0=globalThis.AbortController||XX().AbortController,{FunctionPrototypeCall:u}=o0();class U0 extends v{constructor(J){super(J);if((J===null||J===void 0?void 0:J.readable)===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if((J===null||J===void 0?void 0:J.writable)===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}}O.exports=function J(Z,Y){if(C(Z))return Z;if(S(Z))return Q({readable:Z});if(E(Z))return Q({writable:Z});if(P(Z))return Q({writable:!1,readable:!1});if(D(Z))return Q({readable:x.fromWeb(Z)});if(z(Z))return Q({writable:N.fromWeb(Z)});if(typeof Z==="function"){let{value:F,write:G,final:X,destroy:$}=U(Z);if(V(F))return b(U0,F,{objectMode:!0,write:G,final:X,destroy:$});let M=F===null||F===void 0?void 0:F.then;if(typeof M==="function"){let A,B=u(M,F,(w)=>{if(w!=null)throw new k("nully","body",w)},(w)=>{j(A,w)});return A=new U0({objectMode:!0,readable:!1,write:G,final(w){X(async()=>{try{await B,W.nextTick(w,null)}catch(p){W.nextTick(w,p)}})},destroy:$})}throw new k("Iterable, AsyncIterable or AsyncFunction",Y,F)}if(G0(Z))return J(Z.arrayBuffer());if(V(Z))return b(U0,Z,{objectMode:!0,writable:!1});if(D(Z===null||Z===void 0?void 0:Z.readable)&&z(Z===null||Z===void 0?void 0:Z.writable))return U0.fromWeb(Z);if(typeof(Z===null||Z===void 0?void 0:Z.writable)==="object"||typeof(Z===null||Z===void 0?void 0:Z.readable)==="object"){let F=Z!==null&&Z!==void 0&&Z.readable?S(Z===null||Z===void 0?void 0:Z.readable)?Z===null||Z===void 0?void 0:Z.readable:J(Z.readable):void 0,G=Z!==null&&Z!==void 0&&Z.writable?E(Z===null||Z===void 0?void 0:Z.writable)?Z===null||Z===void 0?void 0:Z.writable:J(Z.writable):void 0;return Q({readable:F,writable:G})}let K=Z===null||Z===void 0?void 0:Z.then;if(typeof K==="function"){let F;return u(K,Z,(G)=>{if(G!=null)F.push(G);F.push(null)},(G)=>{j(F,G)}),F=new U0({objectMode:!0,writable:!1,read(){}})}throw new _(Y,["Blob","ReadableStream","WritableStream","Stream","Iterable","AsyncIterable","Function","{ readable, writable } pair","Promise"],Z)};function U(J){let{promise:Z,resolve:Y}=f(),K=new Y0,F=K.signal;return{value:J(async function*(){while(!0){let G=Z;Z=null;let{chunk:X,done:$,cb:M}=await G;if(W.nextTick(M),$)return;if(F.aborted)throw new q(void 0,{cause:F.reason});({promise:Z,resolve:Y}=f()),yield X}}(),{signal:F}),write(G,X,$){let M=Y;Y=null,M({chunk:G,done:!1,cb:$})},final(G){let X=Y;Y=null,X({done:!0,cb:G})},destroy(G,X){K.abort(),X(G)}}}function Q(J){let Z=J.readable&&typeof J.readable.read!=="function"?x.wrap(J.readable):J.readable,Y=J.writable,K=!!H(Z),F=!!L(Y),G,X,$,M,A;function B(w){let p=M;if(M=null,p)p(w);else if(w)A.destroy(w)}if(A=new U0({readableObjectMode:!!(Z!==null&&Z!==void 0&&Z.readableObjectMode),writableObjectMode:!!(Y!==null&&Y!==void 0&&Y.writableObjectMode),readable:K,writable:F}),F)R(Y,(w)=>{if(F=!1,w)j(Z,w);B(w)}),A._write=function(w,p,n){if(Y.write(w,p))n();else G=n},A._final=function(w){Y.end(),X=w},Y.on("drain",function(){if(G){let w=G;G=null,w()}}),Y.on("finish",function(){if(X){let w=X;X=null,w()}});if(K)R(Z,(w)=>{if(K=!1,w)j(Z,w);B(w)}),Z.on("readable",function(){if($){let w=$;$=null,w()}}),Z.on("end",function(){A.push(null)}),A._read=function(){while(!0){let w=Z.read();if(w===null){$=A._read;return}if(!A.push(w))return}};return A._destroy=function(w,p){if(!w&&M!==null)w=new q;if($=null,G=null,X=null,M===null)p(w);else M=p,j(Y,w),j(Z,w)},A}}),xU=u0((I,O)=>{var{ObjectDefineProperties:W,ObjectGetOwnPropertyDescriptor:T,ObjectKeys:H,ObjectSetPrototypeOf:L}=o0();O.exports=S;var V=RX(),P=ZZ();L(S.prototype,V.prototype),L(S,V);{let z=H(P.prototype);for(let R=0;R<z.length;R++){let q=z[R];if(!S.prototype[q])S.prototype[q]=P.prototype[q]}}function S(z){if(!(this instanceof S))return new S(z);if(V.call(this,z),P.call(this,z),z){if(this.allowHalfOpen=z.allowHalfOpen!==!1,z.readable===!1)this._readableState.readable=!1,this._readableState.ended=!0,this._readableState.endEmitted=!0;if(z.writable===!1)this._writableState.writable=!1,this._writableState.ending=!0,this._writableState.ended=!0,this._writableState.finished=!0}else this.allowHalfOpen=!0}W(S.prototype,{writable:{__proto__:null,...T(P.prototype,"writable")},writableHighWaterMark:{__proto__:null,...T(P.prototype,"writableHighWaterMark")},writableObjectMode:{__proto__:null,...T(P.prototype,"writableObjectMode")},writableBuffer:{__proto__:null,...T(P.prototype,"writableBuffer")},writableLength:{__proto__:null,...T(P.prototype,"writableLength")},writableFinished:{__proto__:null,...T(P.prototype,"writableFinished")},writableCorked:{__proto__:null,...T(P.prototype,"writableCorked")},writableEnded:{__proto__:null,...T(P.prototype,"writableEnded")},writableNeedDrain:{__proto__:null,...T(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(z){if(this._readableState&&this._writableState)this._readableState.destroyed=z,this._writableState.destroyed=z}}});var E;function C(){if(E===void 0)E={};return E}S.fromWeb=function(z,R){return C().newStreamDuplexFromReadableWritablePair(z,R)},S.toWeb=function(z){return C().newReadableWritablePairFromDuplex(z)};var D;S.from=function(z){if(!D)D=WJ();return D(z,"body")}}),OQ=u0((I,O)=>{var{ObjectSetPrototypeOf:W,Symbol:T}=o0();O.exports=S;var{ERR_METHOD_NOT_IMPLEMENTED:H}=CU().codes,L=xU(),{getHighWaterMark:V}=MX();W(S.prototype,L.prototype),W(S,L);var P=T("kCallback");function S(D){if(!(this instanceof S))return new S(D);let z=D?V(this,D,"readableHighWaterMark",!0):null;if(z===0)D={...D,highWaterMark:null,readableHighWaterMark:z,writableHighWaterMark:D.writableHighWaterMark||0};if(L.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",C)}function E(D){if(typeof this._flush==="function"&&!this.destroyed)this._flush((z,R)=>{if(z){if(D)D(z);else this.destroy(z);return}if(R!=null)this.push(R);if(this.push(null),D)D()});else if(this.push(null),D)D()}function C(){if(this._final!==E)E.call(this)}S.prototype._final=E,S.prototype._transform=function(D,z,R){throw new H("_transform()")},S.prototype._write=function(D,z,R){let q=this._readableState,_=this._writableState,k=q.length;this._transform(D,z,(j,v)=>{if(j){R(j);return}if(v!=null)this.push(v);if(_.ended||k===q.length||q.length<q.highWaterMark)R();else this[P]=R})},S.prototype._read=function(){if(this[P]){let D=this[P];this[P]=null,D()}}}),FQ=u0((I,O)=>{var{ObjectSetPrototypeOf:W}=o0();O.exports=H;var T=OQ();W(H.prototype,T.prototype),W(H,T);function H(L){if(!(this instanceof H))return new H(L);T.call(this,L)}H.prototype._transform=function(L,V,P){P(null,L)}}),QZ=u0((I,O)=>{var W=dU(),{ArrayIsArray:T,Promise:H,SymbolAsyncIterator:L,SymbolDispose:V}=o0(),P=yU(),{once:S}=MU(),E=tU(),C=xU(),{aggregateTwoErrors:D,codes:{ERR_INVALID_ARG_TYPE:z,ERR_INVALID_RETURN_VALUE:R,ERR_MISSING_ARGS:q,ERR_STREAM_DESTROYED:_,ERR_STREAM_PREMATURE_CLOSE:k},AbortError:j}=CU(),{validateFunction:v,validateAbortSignal:x}=ZX(),{isIterable:N,isReadable:f,isReadableNodeStream:b,isNodeStream:Q0,isTransformStream:G0,isWebStream:Y0,isReadableStream:u,isReadableFinished:U0}=NU(),U=globalThis.AbortController||XX().AbortController,Q,J,Z;function Y(w,p,n){let K0=!1;w.on("close",()=>{K0=!0});let r=P(w,{readable:p,writable:n},(d)=>{K0=!d});return{destroy:(d)=>{if(K0)return;K0=!0,E.destroyer(w,d||new _("pipe"))},cleanup:r}}function K(w){return v(w[w.length-1],"streams[stream.length - 1]"),w.pop()}function F(w){if(N(w))return w;else if(b(w))return G(w);throw new z("val",["Readable","Iterable","AsyncIterable"],w)}async function*G(w){if(!J)J=RX();yield*J.prototype[L].call(w)}async function X(w,p,n,{end:K0}){let r,d=null,J0=(g0)=>{if(g0)r=g0;if(d){let y=d;d=null,y()}},m=()=>new H((g0,y)=>{if(r)y(r);else d=()=>{if(r)y(r);else g0()}});p.on("drain",J0);let i=P(p,{readable:!1},J0);try{if(p.writableNeedDrain)await m();for await(let g0 of w)if(!p.write(g0))await m();if(K0)p.end(),await m();n()}catch(g0){n(r!==g0?D(r,g0):g0)}finally{i(),p.off("drain",J0)}}async function $(w,p,n,{end:K0}){if(G0(p))p=p.writable;let r=p.getWriter();try{for await(let d of w)await r.ready,r.write(d).catch(()=>{});if(await r.ready,K0)await r.close();n()}catch(d){try{await r.abort(d),n(d)}catch(J0){n(J0)}}}function M(...w){return A(w,S(K(w)))}function A(w,p,n){if(w.length===1&&T(w[0]))w=w[0];if(w.length<2)throw new q("streams");let K0=new U,r=K0.signal,d=n===null||n===void 0?void 0:n.signal,J0=[];x(d,"options.signal");function m(){e(new j)}Z=Z||MU().addAbortListener;let i;if(d)i=Z(d,m);let g0,y,h=[],V0=0;function t(s){e(s,--V0===0)}function e(s,Z0){var f0;if(s&&(!g0||g0.code==="ERR_STREAM_PREMATURE_CLOSE"))g0=s;if(!g0&&!Z0)return;while(h.length)h.shift()(g0);if((f0=i)===null||f0===void 0||f0[V](),K0.abort(),Z0){if(!g0)J0.forEach((W0)=>W0());W.nextTick(p,g0,y)}}let E0;for(let s=0;s<w.length;s++){let Z0=w[s],f0=s<w.length-1,W0=s>0,H0=f0||(n===null||n===void 0?void 0:n.end)!==!1,n0=s===w.length-1;if(Q0(Z0)){let O0=function(D0){if(D0&&D0.name!=="AbortError"&&D0.code!=="ERR_STREAM_PREMATURE_CLOSE")t(D0)};var c=O0;if(H0){let{destroy:D0,cleanup:t0}=Y(Z0,f0,W0);if(h.push(D0),f(Z0)&&n0)J0.push(t0)}if(Z0.on("error",O0),f(Z0)&&n0)J0.push(()=>{Z0.removeListener("error",O0)})}if(s===0)if(typeof Z0==="function"){if(E0=Z0({signal:r}),!N(E0))throw new R("Iterable, AsyncIterable or Stream","source",E0)}else if(N(Z0)||b(Z0)||G0(Z0))E0=Z0;else E0=C.from(Z0);else if(typeof Z0==="function"){if(G0(E0)){var o;E0=F((o=E0)===null||o===void 0?void 0:o.readable)}else E0=F(E0);if(E0=Z0(E0,{signal:r}),f0){if(!N(E0,!0))throw new R("AsyncIterable",`transform[${s-1}]`,E0)}else{var N0;if(!Q)Q=FQ();let O0=new Q({objectMode:!0}),D0=(N0=E0)===null||N0===void 0?void 0:N0.then;if(typeof D0==="function")V0++,D0.call(E0,(A0)=>{if(y=A0,A0!=null)O0.write(A0);if(H0)O0.end();W.nextTick(t)},(A0)=>{O0.destroy(A0),W.nextTick(t,A0)});else if(N(E0,!0))V0++,X(E0,O0,t,{end:H0});else if(u(E0)||G0(E0)){let A0=E0.readable||E0;V0++,X(A0,O0,t,{end:H0})}else throw new R("AsyncIterable or Promise","destination",E0);E0=O0;let{destroy:t0,cleanup:z0}=Y(E0,!1,!0);if(h.push(t0),n0)J0.push(z0)}}else if(Q0(Z0)){if(b(E0)){V0+=2;let O0=B(E0,Z0,t,{end:H0});if(f(Z0)&&n0)J0.push(O0)}else if(G0(E0)||u(E0)){let O0=E0.readable||E0;V0++,X(O0,Z0,t,{end:H0})}else if(N(E0))V0++,X(E0,Z0,t,{end:H0});else throw new z("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],E0);E0=Z0}else if(Y0(Z0)){if(b(E0))V0++,$(F(E0),Z0,t,{end:H0});else if(u(E0)||N(E0))V0++,$(E0,Z0,t,{end:H0});else if(G0(E0))V0++,$(E0.readable,Z0,t,{end:H0});else throw new z("val",["Readable","Iterable","AsyncIterable","ReadableStream","TransformStream"],E0);E0=Z0}else E0=C.from(Z0)}if(r!==null&&r!==void 0&&r.aborted||d!==null&&d!==void 0&&d.aborted)W.nextTick(m);return E0}function B(w,p,n,{end:K0}){let r=!1;if(p.on("close",()=>{if(!r)n(new k)}),w.pipe(p,{end:!1}),K0){let J0=function(){r=!0,p.end()};var d=J0;if(U0(w))W.nextTick(J0);else w.once("end",J0)}else n();return P(w,{readable:!0,writable:!1},(J0)=>{let m=w._readableState;if(J0&&J0.code==="ERR_STREAM_PREMATURE_CLOSE"&&m&&m.ended&&!m.errored&&!m.errorEmitted)w.once("end",n).once("error",n);else n(J0)}),P(p,{readable:!1,writable:!0},n)}O.exports={pipelineImpl:A,pipeline:M}}),WQ=u0((I,O)=>{var{pipeline:W}=QZ(),T=xU(),{destroyer:H}=tU(),{isNodeStream:L,isReadable:V,isWritable:P,isWebStream:S,isTransformStream:E,isWritableStream:C,isReadableStream:D}=NU(),{AbortError:z,codes:{ERR_INVALID_ARG_VALUE:R,ERR_MISSING_ARGS:q}}=CU(),_=yU();O.exports=function(...k){if(k.length===0)throw new q("streams");if(k.length===1)return T.from(k[0]);let j=[...k];if(typeof k[0]==="function")k[0]=T.from(k[0]);if(typeof k[k.length-1]==="function"){let U=k.length-1;k[U]=T.from(k[U])}for(let U=0;U<k.length;++U){if(!L(k[U])&&!S(k[U]))continue;if(U<k.length-1&&!(V(k[U])||D(k[U])||E(k[U])))throw new R(`streams[${U}]`,j[U],"must be readable");if(U>0&&!(P(k[U])||C(k[U])||E(k[U])))throw new R(`streams[${U}]`,j[U],"must be writable")}let v,x,N,f,b;function Q0(U){let Q=f;if(f=null,Q)Q(U);else if(U)b.destroy(U);else if(!U0&&!u)b.destroy()}let G0=k[0],Y0=W(k,Q0),u=!!(P(G0)||C(G0)||E(G0)),U0=!!(V(Y0)||D(Y0)||E(Y0));if(b=new T({writableObjectMode:!!(G0!==null&&G0!==void 0&&G0.writableObjectMode),readableObjectMode:!!(Y0!==null&&Y0!==void 0&&Y0.readableObjectMode),writable:u,readable:U0}),u){if(L(G0))b._write=function(Q,J,Z){if(G0.write(Q,J))Z();else v=Z},b._final=function(Q){G0.end(),x=Q},G0.on("drain",function(){if(v){let Q=v;v=null,Q()}});else if(S(G0)){let Q=(E(G0)?G0.writable:G0).getWriter();b._write=async function(J,Z,Y){try{await Q.ready,Q.write(J).catch(()=>{}),Y()}catch(K){Y(K)}},b._final=async function(J){try{await Q.ready,Q.close().catch(()=>{}),x=J}catch(Z){J(Z)}}}let U=E(Y0)?Y0.readable:Y0;_(U,()=>{if(x){let Q=x;x=null,Q()}})}if(U0){if(L(Y0))Y0.on("readable",function(){if(N){let U=N;N=null,U()}}),Y0.on("end",function(){b.push(null)}),b._read=function(){while(!0){let U=Y0.read();if(U===null){N=b._read;return}if(!b.push(U))return}};else if(S(Y0)){let U=(E(Y0)?Y0.readable:Y0).getReader();b._read=async function(){while(!0)try{let{value:Q,done:J}=await U.read();if(!b.push(Q))return;if(J){b.push(null);return}}catch{return}}}}return b._destroy=function(U,Q){if(!U&&f!==null)U=new z;if(N=null,v=null,x=null,f===null)Q(U);else if(f=Q,L(Y0))H(Y0,U)},b}}),HJ=u0((I,O)=>{var W=globalThis.AbortController||XX().AbortController,{codes:{ERR_INVALID_ARG_VALUE:T,ERR_INVALID_ARG_TYPE:H,ERR_MISSING_ARGS:L,ERR_OUT_OF_RANGE:V},AbortError:P}=CU(),{validateAbortSignal:S,validateInteger:E,validateObject:C}=ZX(),D=o0().Symbol("kWeak"),z=o0().Symbol("kResistStopPropagation"),{finished:R}=yU(),q=WQ(),{addAbortSignalNoValidate:_}=LX(),{isWritable:k,isNodeStream:j}=NU(),{deprecate:v}=MU(),{ArrayPrototypePush:x,Boolean:N,MathFloor:f,Number:b,NumberIsNaN:Q0,Promise:G0,PromiseReject:Y0,PromiseResolve:u,PromisePrototypeThen:U0,Symbol:U}=o0(),Q=U("kEmpty"),J=U("kEof");function Z(d,J0){if(J0!=null)C(J0,"options");if((J0===null||J0===void 0?void 0:J0.signal)!=null)S(J0.signal,"options.signal");if(j(d)&&!k(d))throw new T("stream",d,"must be writable");let m=q(this,d);if(J0!==null&&J0!==void 0&&J0.signal)_(J0.signal,m);return m}function Y(d,J0){if(typeof d!=="function")throw new H("fn",["Function","AsyncFunction"],d);if(J0!=null)C(J0,"options");if((J0===null||J0===void 0?void 0:J0.signal)!=null)S(J0.signal,"options.signal");let m=1;if((J0===null||J0===void 0?void 0:J0.concurrency)!=null)m=f(J0.concurrency);let i=m-1;if((J0===null||J0===void 0?void 0:J0.highWaterMark)!=null)i=f(J0.highWaterMark);return E(m,"options.concurrency",1),E(i,"options.highWaterMark",0),i+=m,async function*(){let g0=MU().AbortSignalAny([J0===null||J0===void 0?void 0:J0.signal].filter(N)),y=this,h=[],V0={signal:g0},t,e,E0=!1,c=0;function o(){E0=!0,N0()}function N0(){c-=1,s()}function s(){if(e&&!E0&&c<m&&h.length<i)e(),e=null}async function Z0(){try{for await(let f0 of y){if(E0)return;if(g0.aborted)throw new P;try{if(f0=d(f0,V0),f0===Q)continue;f0=u(f0)}catch(W0){f0=Y0(W0)}if(c+=1,U0(f0,N0,o),h.push(f0),t)t(),t=null;if(!E0&&(h.length>=i||c>=m))await new G0((W0)=>{e=W0})}h.push(J)}catch(f0){let W0=Y0(f0);U0(W0,N0,o),h.push(W0)}finally{if(E0=!0,t)t(),t=null}}Z0();try{while(!0){while(h.length>0){let f0=await h[0];if(f0===J)return;if(g0.aborted)throw new P;if(f0!==Q)yield f0;h.shift(),s()}await new G0((f0)=>{t=f0})}}finally{if(E0=!0,e)e(),e=null}}.call(this)}function K(d=void 0){if(d!=null)C(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)S(d.signal,"options.signal");return async function*(){let J0=0;for await(let i of this){var m;if(d!==null&&d!==void 0&&(m=d.signal)!==null&&m!==void 0&&m.aborted)throw new P({cause:d.signal.reason});yield[J0++,i]}}.call(this)}async function F(d,J0=void 0){for await(let m of M.call(this,d,J0))return!0;return!1}async function G(d,J0=void 0){if(typeof d!=="function")throw new H("fn",["Function","AsyncFunction"],d);return!await F.call(this,async(...m)=>{return!await d(...m)},J0)}async function X(d,J0){for await(let m of M.call(this,d,J0))return m;return}async function $(d,J0){if(typeof d!=="function")throw new H("fn",["Function","AsyncFunction"],d);async function m(i,g0){return await d(i,g0),Q}for await(let i of Y.call(this,m,J0));}function M(d,J0){if(typeof d!=="function")throw new H("fn",["Function","AsyncFunction"],d);async function m(i,g0){if(await d(i,g0))return i;return Q}return Y.call(this,m,J0)}class A extends L{constructor(){super("reduce");this.message="Reduce of an empty stream requires an initial value"}}async function B(d,J0,m){var i;if(typeof d!=="function")throw new H("reducer",["Function","AsyncFunction"],d);if(m!=null)C(m,"options");if((m===null||m===void 0?void 0:m.signal)!=null)S(m.signal,"options.signal");let g0=arguments.length>1;if(m!==null&&m!==void 0&&(i=m.signal)!==null&&i!==void 0&&i.aborted){let e=new P(void 0,{cause:m.signal.reason});throw this.once("error",()=>{}),await R(this.destroy(e)),e}let y=new W,h=y.signal;if(m!==null&&m!==void 0&&m.signal){let e={once:!0,[D]:this,[z]:!0};m.signal.addEventListener("abort",()=>y.abort(),e)}let V0=!1;try{for await(let e of this){var t;if(V0=!0,m!==null&&m!==void 0&&(t=m.signal)!==null&&t!==void 0&&t.aborted)throw new P;if(!g0)J0=e,g0=!0;else J0=await d(J0,e,{signal:h})}if(!V0&&!g0)throw new A}finally{y.abort()}return J0}async function w(d){if(d!=null)C(d,"options");if((d===null||d===void 0?void 0:d.signal)!=null)S(d.signal,"options.signal");let J0=[];for await(let i of this){var m;if(d!==null&&d!==void 0&&(m=d.signal)!==null&&m!==void 0&&m.aborted)throw new P(void 0,{cause:d.signal.reason});x(J0,i)}return J0}function p(d,J0){let m=Y.call(this,d,J0);return async function*(){for await(let i of m)yield*i}.call(this)}function n(d){if(d=b(d),Q0(d))return 0;if(d<0)throw new V("number",">= 0",d);return d}function K0(d,J0=void 0){if(J0!=null)C(J0,"options");if((J0===null||J0===void 0?void 0:J0.signal)!=null)S(J0.signal,"options.signal");return d=n(d),async function*(){var m;if(J0!==null&&J0!==void 0&&(m=J0.signal)!==null&&m!==void 0&&m.aborted)throw new P;for await(let g0 of this){var i;if(J0!==null&&J0!==void 0&&(i=J0.signal)!==null&&i!==void 0&&i.aborted)throw new P;if(d--<=0)yield g0}}.call(this)}function r(d,J0=void 0){if(J0!=null)C(J0,"options");if((J0===null||J0===void 0?void 0:J0.signal)!=null)S(J0.signal,"options.signal");return d=n(d),async function*(){var m;if(J0!==null&&J0!==void 0&&(m=J0.signal)!==null&&m!==void 0&&m.aborted)throw new P;for await(let g0 of this){var i;if(J0!==null&&J0!==void 0&&(i=J0.signal)!==null&&i!==void 0&&i.aborted)throw new P;if(d-- >0)yield g0;if(d<=0)return}}.call(this)}O.exports.streamReturningOperators={asIndexedPairs:v(K,"readable.asIndexedPairs will be removed in a future version."),drop:K0,filter:M,flatMap:p,map:Y,take:r,compose:Z},O.exports.promiseReturningOperators={every:G,forEach:$,reduce:B,toArray:w,some:F,find:X}}),HQ=u0((I,O)=>{var{ArrayPrototypePop:W,Promise:T}=o0(),{isIterable:H,isNodeStream:L,isWebStream:V}=NU(),{pipelineImpl:P}=QZ(),{finished:S}=yU();DQ();function E(...C){return new T((D,z)=>{let R,q,_=C[C.length-1];if(_&&typeof _==="object"&&!L(_)&&!H(_)&&!V(_)){let k=W(C);R=k.signal,q=k.end}P(C,(k,j)=>{if(k)z(k);else D(j)},{signal:R,end:q})})}O.exports={finished:S,pipeline:E}}),DQ=u0((I,O)=>{var{Buffer:W}=(HU(),h0(WU)),{ObjectDefineProperty:T,ObjectKeys:H,ReflectApply:L}=o0(),{promisify:{custom:V}}=MU(),{streamReturningOperators:P,promiseReturningOperators:S}=HJ(),{codes:{ERR_ILLEGAL_CONSTRUCTOR:E}}=CU(),C=WQ(),{setDefaultHighWaterMark:D,getDefaultHighWaterMark:z}=MX(),{pipeline:R}=QZ(),{destroyer:q}=tU(),_=yU(),k=HQ(),j=NU(),v=O.exports=XZ().Stream;v.isDestroyed=j.isDestroyed,v.isDisturbed=j.isDisturbed,v.isErrored=j.isErrored,v.isReadable=j.isReadable,v.isWritable=j.isWritable,v.Readable=RX();for(let N of H(P)){let f=function(...Q0){if(new.target)throw E();return v.Readable.from(L(b,this,Q0))},b=P[N];T(f,"name",{__proto__:null,value:b.name}),T(f,"length",{__proto__:null,value:b.length}),T(v.Readable.prototype,N,{__proto__:null,value:f,enumerable:!1,configurable:!0,writable:!0})}for(let N of H(S)){let f=function(...Q0){if(new.target)throw E();return L(b,this,Q0)},b=S[N];T(f,"name",{__proto__:null,value:b.name}),T(f,"length",{__proto__:null,value:b.length}),T(v.Readable.prototype,N,{__proto__:null,value:f,enumerable:!1,configurable:!0,writable:!0})}v.Writable=ZZ(),v.Duplex=xU(),v.Transform=OQ(),v.PassThrough=FQ(),v.pipeline=R;var{addAbortSignal:x}=LX();v.addAbortSignal=x,v.finished=_,v.destroy=q,v.compose=C,v.setDefaultHighWaterMark=D,v.getDefaultHighWaterMark=z,T(v,"promises",{__proto__:null,configurable:!0,enumerable:!0,get(){return k}}),T(R,V,{__proto__:null,enumerable:!0,get(){return k.pipeline}}),T(_,V,{__proto__:null,enumerable:!0,get(){return k.finished}}),v.Stream=v,v._isUint8Array=function(N){return N instanceof Uint8Array},v._uint8ArrayToBuffer=function(N){return W.from(N.buffer,N.byteOffset,N.byteLength)}}),DJ=u0((I,O)=>{var W=YZ();{let T=DQ(),H=HQ(),L=T.Readable.destroy;O.exports=T.Readable,O.exports._uint8ArrayToBuffer=T._uint8ArrayToBuffer,O.exports._isUint8Array=T._isUint8Array,O.exports.isDisturbed=T.isDisturbed,O.exports.isErrored=T.isErrored,O.exports.isReadable=T.isReadable,O.exports.Readable=T.Readable,O.exports.Writable=T.Writable,O.exports.Duplex=T.Duplex,O.exports.Transform=T.Transform,O.exports.PassThrough=T.PassThrough,O.exports.addAbortSignal=T.addAbortSignal,O.exports.finished=T.finished,O.exports.destroy=T.destroy,O.exports.destroy=L,O.exports.pipeline=T.pipeline,O.exports.compose=T.compose,Object.defineProperty(T,"promises",{configurable:!0,enumerable:!0,get(){return H}}),O.exports.Stream=T.Stream}O.exports.default=O.exports});TQ.exports=DJ()});var RU={};$X(RU,{webcrypto:()=>bG,rng:()=>UG,randomUUID:()=>pG,randomFillSync:()=>gG,randomFill:()=>NG,randomBytes:()=>XG,publicEncrypt:()=>vG,publicDecrypt:()=>BG,pseudoRandomBytes:()=>iV,prng:()=>eV,privateEncrypt:()=>_G,privateDecrypt:()=>xG,pbkdf2Sync:()=>IG,pbkdf2:()=>GG,listCiphers:()=>zG,getRandomValues:()=>cG,getHashes:()=>VG,getDiffieHellman:()=>LG,getCurves:()=>uG,getCiphers:()=>AG,default:()=>lG,createVerify:()=>PG,createSign:()=>qG,createHmac:()=>JG,createHash:()=>QG,createECDH:()=>jG,createDiffieHellmanGroup:()=>EG,createDiffieHellman:()=>MG,createDecipheriv:()=>TG,createDecipher:()=>HG,createCredentials:()=>wG,createCipheriv:()=>FG,createCipher:()=>KG,constants:()=>fG,Verify:()=>kG,Sign:()=>SG,Hmac:()=>YG,Hash:()=>ZG,DiffieHellmanGroup:()=>CG,DiffieHellman:()=>RG,Decipheriv:()=>DG,Decipher:()=>WG,DEFAULT_ENCODING:()=>yG,Cipheriv:()=>OG,Cipher:()=>$G});function uG(){return hG}var TJ,AJ,AQ,zJ,CJ,EJ=(I,O,W)=>{W=I!=null?TJ(AJ(I)):{};let T=O||!I||!I.__esModule?AQ(W,"default",{value:I,enumerable:!0}):W;for(let H of zJ(I))if(!CJ.call(T,H))AQ(T,H,{get:()=>I[H],enumerable:!0});return T},I0=(I,O)=>()=>(O||I((O={exports:{}}).exports,O),O.exports),qX,SX,EQ,LJ,VZ,GZ,EU,MJ,YX,LQ,RJ,qJ,SJ,PJ,MQ,kJ,jJ,vJ,_J,BJ,xJ,NJ,gJ,wJ,fJ,JX,PX,RQ,yJ,qQ,SQ,cJ,VX,IZ,$Z,pJ,PQ,KZ,hJ,kQ,uJ,jQ,vQ,bJ,lJ,dJ,oJ,nJ,mJ,sJ,tJ,rJ,aJ,eJ,iJ,UV,XV,OZ,_Q,ZV,BQ,QV,YV,JV,VV,gU,cU,xQ,kU,NQ,kX,GV,SU,IV,$V,KV,gQ,_U,GX,wQ,OV,fQ,FV,yQ,WV,HV,DV,TV,FZ,AV,WZ,zV,CV,EV,LV,MV,RV,qV,SV,PV,kV,jV,vV,_V,BV,zQ,xV,QX,NV,cQ,pQ,gV,wV,hQ,fV,yV,IX,cV,pV,hV,uV,bV,lV,uQ,dV,bQ,lQ,dQ,HZ,oQ,oV,nQ,nV,mV,JZ,sV,tV,rV,aV,p0,eV,iV,UG,XG,ZG,QG,YG,JG,VG,GG,IG,$G,KG,OG,FG,WG,HG,DG,TG,AG,zG,CG,EG,LG,MG,RG,qG,SG,PG,kG,jG,vG,_G,BG,xG,NG,gG,wG,fG,yG="buffer",cG=(I)=>{return crypto.getRandomValues(I)},pG=()=>{return crypto.randomUUID()},hG,bG,lG;var qU=KX(()=>{TJ=Object.create,{getPrototypeOf:AJ,defineProperty:AQ,getOwnPropertyNames:zJ}=Object,CJ=Object.prototype.hasOwnProperty,qX=I0((I,O)=>{O.exports=(qU(),h0(RU)).randomBytes}),SX=I0((I,O)=>{O.exports=(qU(),h0(RU)).createHash}),EQ=I0((I,O)=>{O.exports=(qU(),h0(RU)).createHmac}),LJ=I0((I,O)=>{O.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"}}}),VZ=I0((I,O)=>{var W=isFinite,T=Math.pow(2,30)-1;O.exports=function(H,L){if(typeof H!=="number")throw TypeError("Iterations not a number");if(H<0||!W(H))throw TypeError("Bad iterations");if(typeof L!=="number")throw TypeError("Key length not a number");if(L<0||L>T||L!==L)throw TypeError("Bad key length")}}),GZ=I0((I,O)=>{var W;if(globalThis.process&&globalThis.process.browser)W="utf-8";else if(globalThis.process&&globalThis.process.version)T=parseInt(process.version.split(".")[0].slice(1),10),W=T>=6?"utf-8":"binary";else W="utf-8";var T;O.exports=W}),EU=I0((I,O)=>{/*! safe-buffer. MIT License. Feross Aboukhadijeh <https://feross.org/opensource> */var W=(HU(),h0(WU)),T=W.Buffer;function H(V,P){for(var S in V)P[S]=V[S]}if(T.from&&T.alloc&&T.allocUnsafe&&T.allocUnsafeSlow)O.exports=W;else H(W,I),I.Buffer=L;function L(V,P,S){return T(V,P,S)}L.prototype=Object.create(T.prototype),H(T,L),L.from=function(V,P,S){if(typeof V==="number")throw TypeError("Argument must not be a number");return T(V,P,S)},L.alloc=function(V,P,S){if(typeof V!=="number")throw TypeError("Argument must be a number");var E=T(V);if(P!==void 0)if(typeof S==="string")E.fill(P,S);else E.fill(P);else E.fill(0);return E},L.allocUnsafe=function(V){if(typeof V!=="number")throw TypeError("Argument must be a number");return T(V)},L.allocUnsafeSlow=function(V){if(typeof V!=="number")throw TypeError("Argument must be a number");return W.SlowBuffer(V)}}),MJ=I0((I,O)=>{var W={}.toString;O.exports=Array.isArray||function(T){return W.call(T)=="[object Array]"}}),YX=I0((I,O)=>{O.exports=TypeError}),LQ=I0((I,O)=>{O.exports=Object}),RJ=I0((I,O)=>{O.exports=Error}),qJ=I0((I,O)=>{O.exports=EvalError}),SJ=I0((I,O)=>{O.exports=RangeError}),PJ=I0((I,O)=>{O.exports=ReferenceError}),MQ=I0((I,O)=>{O.exports=SyntaxError}),kJ=I0((I,O)=>{O.exports=URIError}),jJ=I0((I,O)=>{O.exports=Math.abs}),vJ=I0((I,O)=>{O.exports=Math.floor}),_J=I0((I,O)=>{O.exports=Math.max}),BJ=I0((I,O)=>{O.exports=Math.min}),xJ=I0((I,O)=>{O.exports=Math.pow}),NJ=I0((I,O)=>{O.exports=Math.round}),gJ=I0((I,O)=>{O.exports=Number.isNaN||function(W){return W!==W}}),wJ=I0((I,O)=>{var W=gJ();O.exports=function(T){if(W(T)||T===0)return T;return T<0?-1:1}}),fJ=I0((I,O)=>{O.exports=Object.getOwnPropertyDescriptor}),JX=I0((I,O)=>{var W=fJ();if(W)try{W([],"length")}catch(T){W=null}O.exports=W}),PX=I0((I,O)=>{var W=Object.defineProperty||!1;if(W)try{W({},"a",{value:1})}catch(T){W=!1}O.exports=W}),RQ=I0((I,O)=>{O.exports=function(){if(typeof Symbol!=="function"||typeof Object.getOwnPropertySymbols!=="function")return!1;if(typeof Symbol.iterator==="symbol")return!0;var W={},T=Symbol("test"),H=Object(T);if(typeof T==="string")return!1;if(Object.prototype.toString.call(T)!=="[object Symbol]")return!1;if(Object.prototype.toString.call(H)!=="[object Symbol]")return!1;var L=42;W[T]=L;for(var V in W)return!1;if(typeof Object.keys==="function"&&Object.keys(W).length!==0)return!1;if(typeof Object.getOwnPropertyNames==="function"&&Object.getOwnPropertyNames(W).length!==0)return!1;var P=Object.getOwnPropertySymbols(W);if(P.length!==1||P[0]!==T)return!1;if(!Object.prototype.propertyIsEnumerable.call(W,T))return!1;if(typeof Object.getOwnPropertyDescriptor==="function"){var S=Object.getOwnPropertyDescriptor(W,T);if(S.value!==L||S.enumerable!==!0)return!1}return!0}}),yJ=I0((I,O)=>{var W=typeof Symbol<"u"&&Symbol,T=RQ();O.exports=function(){if(typeof W!=="function")return!1;if(typeof Symbol!=="function")return!1;if(typeof W("foo")!=="symbol")return!1;if(typeof Symbol("bar")!=="symbol")return!1;return T()}}),qQ=I0((I,O)=>{O.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null}),SQ=I0((I,O)=>{var W=LQ();O.exports=W.getPrototypeOf||null}),cJ=I0((I,O)=>{var W="Function.prototype.bind called on incompatible ",T=Object.prototype.toString,H=Math.max,L="[object Function]",V=function(E,C){var D=[];for(var z=0;z<E.length;z+=1)D[z]=E[z];for(var R=0;R<C.length;R+=1)D[R+E.length]=C[R];return D},P=function(E,C){var D=[];for(var z=C||0,R=0;z<E.length;z+=1,R+=1)D[R]=E[z];return D},S=function(E,C){var D="";for(var z=0;z<E.length;z+=1)if(D+=E[z],z+1<E.length)D+=C;return D};O.exports=function(E){var C=this;if(typeof C!=="function"||T.apply(C)!==L)throw TypeError(W+C);var D=P(arguments,1),z,R=function(){if(this instanceof z){var v=C.apply(this,V(D,arguments));if(Object(v)===v)return v;return this}return C.apply(E,V(D,arguments))},q=H(0,C.length-D.length),_=[];for(var k=0;k<q;k++)_[k]="$"+k;if(z=Function("binder","return function ("+S(_,",")+"){ return binder.apply(this,arguments); }")(R),C.prototype){var j=function(){};j.prototype=C.prototype,z.prototype=new j,j.prototype=null}return z}}),VX=I0((I,O)=>{var W=cJ();O.exports=Function.prototype.bind||W}),IZ=I0((I,O)=>{O.exports=Function.prototype.call}),$Z=I0((I,O)=>{O.exports=Function.prototype.apply}),pJ=I0((I,O)=>{O.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply}),PQ=I0((I,O)=>{var W=VX(),T=$Z(),H=IZ(),L=pJ();O.exports=L||W.call(H,T)}),KZ=I0((I,O)=>{var W=VX(),T=YX(),H=IZ(),L=PQ();O.exports=function(V){if(V.length<1||typeof V[0]!=="function")throw new T("a function is required");return L(W,H,V)}}),hJ=I0((I,O)=>{var W=KZ(),T=JX(),H;try{H=[].__proto__===Array.prototype}catch(S){if(!S||typeof S!=="object"||!("code"in S)||S.code!=="ERR_PROTO_ACCESS")throw S}var L=!!H&&T&&T(Object.prototype,"__proto__"),V=Object,P=V.getPrototypeOf;O.exports=L&&typeof L.get==="function"?W([L.get]):typeof P==="function"?function(S){return P(S==null?S:V(S))}:!1}),kQ=I0((I,O)=>{var W=qQ(),T=SQ(),H=hJ();O.exports=W?function(L){return W(L)}:T?function(L){if(!L||typeof L!=="object"&&typeof L!=="function")throw TypeError("getProto: not an object");return T(L)}:H?function(L){return H(L)}:null}),uJ=I0((I,O)=>{var W=Function.prototype.call,T=Object.prototype.hasOwnProperty,H=VX();O.exports=H.call(W,T)}),jQ=I0((I,O)=>{var W,T=LQ(),H=RJ(),L=qJ(),V=SJ(),P=PJ(),S=MQ(),E=YX(),C=kJ(),D=jJ(),z=vJ(),R=_J(),q=BJ(),_=xJ(),k=NJ(),j=wJ(),v=Function,x=function(J0){try{return v('"use strict"; return ('+J0+").constructor;")()}catch(m){}},N=JX(),f=PX(),b=function(){throw new E},Q0=N?function(){try{return arguments.callee,b}catch(J0){try{return N(arguments,"callee").get}catch(m){return b}}}():b,G0=yJ()(),Y0=kQ(),u=SQ(),U0=qQ(),U=$Z(),Q=IZ(),J={},Z=typeof Uint8Array>"u"||!Y0?W:Y0(Uint8Array),Y={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?W:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?W:ArrayBuffer,"%ArrayIteratorPrototype%":G0&&Y0?Y0([][Symbol.iterator]()):W,"%AsyncFromSyncIteratorPrototype%":W,"%AsyncFunction%":J,"%AsyncGenerator%":J,"%AsyncGeneratorFunction%":J,"%AsyncIteratorPrototype%":J,"%Atomics%":typeof Atomics>"u"?W:Atomics,"%BigInt%":typeof BigInt>"u"?W:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?W:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?W:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?W:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":H,"%eval%":eval,"%EvalError%":L,"%Float16Array%":typeof Float16Array>"u"?W:Float16Array,"%Float32Array%":typeof Float32Array>"u"?W:Float32Array,"%Float64Array%":typeof Float64Array>"u"?W:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?W:FinalizationRegistry,"%Function%":v,"%GeneratorFunction%":J,"%Int8Array%":typeof Int8Array>"u"?W:Int8Array,"%Int16Array%":typeof Int16Array>"u"?W:Int16Array,"%Int32Array%":typeof Int32Array>"u"?W:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":G0&&Y0?Y0(Y0([][Symbol.iterator]())):W,"%JSON%":typeof JSON==="object"?JSON:W,"%Map%":typeof Map>"u"?W:Map,"%MapIteratorPrototype%":typeof Map>"u"||!G0||!Y0?W:Y0(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":T,"%Object.getOwnPropertyDescriptor%":N,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?W:Promise,"%Proxy%":typeof Proxy>"u"?W:Proxy,"%RangeError%":V,"%ReferenceError%":P,"%Reflect%":typeof Reflect>"u"?W:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?W:Set,"%SetIteratorPrototype%":typeof Set>"u"||!G0||!Y0?W:Y0(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?W:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":G0&&Y0?Y0(""[Symbol.iterator]()):W,"%Symbol%":G0?Symbol:W,"%SyntaxError%":S,"%ThrowTypeError%":Q0,"%TypedArray%":Z,"%TypeError%":E,"%Uint8Array%":typeof Uint8Array>"u"?W:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?W:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?W:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?W:Uint32Array,"%URIError%":C,"%WeakMap%":typeof WeakMap>"u"?W:WeakMap,"%WeakRef%":typeof WeakRef>"u"?W:WeakRef,"%WeakSet%":typeof WeakSet>"u"?W:WeakSet,"%Function.prototype.call%":Q,"%Function.prototype.apply%":U,"%Object.defineProperty%":f,"%Object.getPrototypeOf%":u,"%Math.abs%":D,"%Math.floor%":z,"%Math.max%":R,"%Math.min%":q,"%Math.pow%":_,"%Math.round%":k,"%Math.sign%":j,"%Reflect.getPrototypeOf%":U0};if(Y0)try{null.error}catch(J0){K=Y0(Y0(J0)),Y["%Error.prototype%"]=K}var K,F=function J0(m){var i;if(m==="%AsyncFunction%")i=x("async function () {}");else if(m==="%GeneratorFunction%")i=x("function* () {}");else if(m==="%AsyncGeneratorFunction%")i=x("async function* () {}");else if(m==="%AsyncGenerator%"){var g0=J0("%AsyncGeneratorFunction%");if(g0)i=g0.prototype}else if(m==="%AsyncIteratorPrototype%"){var y=J0("%AsyncGenerator%");if(y&&Y0)i=Y0(y.prototype)}return Y[m]=i,i},G={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},X=VX(),$=uJ(),M=X.call(Q,Array.prototype.concat),A=X.call(U,Array.prototype.splice),B=X.call(Q,String.prototype.replace),w=X.call(Q,String.prototype.slice),p=X.call(Q,RegExp.prototype.exec),n=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,K0=/\\(\\)?/g,r=function(J0){var m=w(J0,0,1),i=w(J0,-1);if(m==="%"&&i!=="%")throw new S("invalid intrinsic syntax, expected closing `%`");else if(i==="%"&&m!=="%")throw new S("invalid intrinsic syntax, expected opening `%`");var g0=[];return B(J0,n,function(y,h,V0,t){g0[g0.length]=V0?B(t,K0,"$1"):h||y}),g0},d=function(J0,m){var i=J0,g0;if($(G,i))g0=G[i],i="%"+g0[0]+"%";if($(Y,i)){var y=Y[i];if(y===J)y=F(i);if(typeof y>"u"&&!m)throw new E("intrinsic "+J0+" exists, but is not available. Please file an issue!");return{alias:g0,name:i,value:y}}throw new S("intrinsic "+J0+" does not exist!")};O.exports=function(J0,m){if(typeof J0!=="string"||J0.length===0)throw new E("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof m!=="boolean")throw new E('"allowMissing" argument must be a boolean');if(p(/^%?[^%]*%?$/,J0)===null)throw new S("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var i=r(J0),g0=i.length>0?i[0]:"",y=d("%"+g0+"%",m),h=y.name,V0=y.value,t=!1,e=y.alias;if(e)g0=e[0],A(i,M([0,1],e));for(var E0=1,c=!0;E0<i.length;E0+=1){var o=i[E0],N0=w(o,0,1),s=w(o,-1);if((N0==='"'||N0==="'"||N0==="`"||(s==='"'||s==="'"||s==="`"))&&N0!==s)throw new S("property names with quotes must have matching quotes");if(o==="constructor"||!c)t=!0;if(g0+="."+o,h="%"+g0+"%",$(Y,h))V0=Y[h];else if(V0!=null){if(!(o in V0)){if(!m)throw new E("base intrinsic for "+J0+" exists, but the property is not available.");return}if(N&&E0+1>=i.length){var Z0=N(V0,o);if(c=!!Z0,c&&"get"in Z0&&!("originalValue"in Z0.get))V0=Z0.get;else V0=V0[o]}else c=$(V0,o),V0=V0[o];if(c&&!t)Y[h]=V0}}return V0}}),vQ=I0((I,O)=>{var W=jQ(),T=KZ(),H=T([W("%String.prototype.indexOf%")]);O.exports=function(L,V){var P=W(L,!!V);if(typeof P==="function"&&H(L,".prototype.")>-1)return T([P]);return P}}),bJ=I0((I,O)=>{var W=Function.prototype.toString,T=typeof Reflect==="object"&&Reflect!==null&&Reflect.apply,H,L;if(typeof T==="function"&&typeof Object.defineProperty==="function")try{H=Object.defineProperty({},"length",{get:function(){throw L}}),L={},T(function(){throw 42},null,H)}catch(N){if(N!==L)T=null}else T=null;var V=/^\s*class\b/,P=function(N){try{var f=W.call(N);return V.test(f)}catch(b){return!1}},S=function(N){try{if(P(N))return!1;return W.call(N),!0}catch(f){return!1}},E=Object.prototype.toString,C="[object Object]",D="[object Function]",z="[object GeneratorFunction]",R="[object HTMLAllCollection]",q="[object HTML document.all class]",_="[object HTMLCollection]",k=typeof Symbol==="function"&&!!Symbol.toStringTag,j=!(0 in[,]),v=function(){return!1};if(typeof document==="object"){if(x=document.all,E.call(x)===E.call(document.all))v=function(N){if((j||!N)&&(typeof N>"u"||typeof N==="object"))try{var f=E.call(N);return(f===R||f===q||f===_||f===C)&&N("")==null}catch(b){}return!1}}var x;O.exports=T?function(N){if(v(N))return!0;if(!N)return!1;if(typeof N!=="function"&&typeof N!=="object")return!1;try{T(N,null,H)}catch(f){if(f!==L)return!1}return!P(N)&&S(N)}:function(N){if(v(N))return!0;if(!N)return!1;if(typeof N!=="function"&&typeof N!=="object")return!1;if(k)return S(N);if(P(N))return!1;var f=E.call(N);if(f!==D&&f!==z&&!/^\[object HTML/.test(f))return!1;return S(N)}}),lJ=I0((I,O)=>{var W=bJ(),T=Object.prototype.toString,H=Object.prototype.hasOwnProperty,L=function(E,C,D){for(var z=0,R=E.length;z<R;z++)if(H.call(E,z))if(D==null)C(E[z],z,E);else C.call(D,E[z],z,E)},V=function(E,C,D){for(var z=0,R=E.length;z<R;z++)if(D==null)C(E.charAt(z),z,E);else C.call(D,E.charAt(z),z,E)},P=function(E,C,D){for(var z in E)if(H.call(E,z))if(D==null)C(E[z],z,E);else C.call(D,E[z],z,E)};function S(E){return T.call(E)==="[object Array]"}O.exports=function(E,C,D){if(!W(C))throw TypeError("iterator must be a function");var z;if(arguments.length>=3)z=D;if(S(E))L(E,C,z);else if(typeof E==="string")V(E,C,z);else P(E,C,z)}}),dJ=I0((I,O)=>{O.exports=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]}),oJ=I0((I,O)=>{var W=dJ(),T=typeof globalThis>"u"?globalThis:globalThis;O.exports=function(){var H=[];for(var L=0;L<W.length;L++)if(typeof T[W[L]]==="function")H[H.length]=W[L];return H}}),nJ=I0((I,O)=>{var W=PX(),T=MQ(),H=YX(),L=JX();O.exports=function(V,P,S){if(!V||typeof V!=="object"&&typeof V!=="function")throw new H("`obj` must be an object or a function`");if(typeof P!=="string"&&typeof P!=="symbol")throw new H("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!=="boolean"&&arguments[3]!==null)throw new H("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!=="boolean"&&arguments[4]!==null)throw new H("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!=="boolean"&&arguments[5]!==null)throw new H("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!=="boolean")throw new H("`loose`, if provided, must be a boolean");var E=arguments.length>3?arguments[3]:null,C=arguments.length>4?arguments[4]:null,D=arguments.length>5?arguments[5]:null,z=arguments.length>6?arguments[6]:!1,R=!!L&&L(V,P);if(W)W(V,P,{configurable:D===null&&R?R.configurable:!D,enumerable:E===null&&R?R.enumerable:!E,value:S,writable:C===null&&R?R.writable:!C});else if(z||!E&&!C&&!D)V[P]=S;else throw new T("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}}),mJ=I0((I,O)=>{var W=PX(),T=function(){return!!W};T.hasArrayLengthDefineBug=function(){if(!W)return null;try{return W([],"length",{value:1}).length!==1}catch(H){return!0}},O.exports=T}),sJ=I0((I,O)=>{var W=jQ(),T=nJ(),H=mJ()(),L=JX(),V=YX(),P=W("%Math.floor%");O.exports=function(S,E){if(typeof S!=="function")throw new V("`fn` is not a function");if(typeof E!=="number"||E<0||E>4294967295||P(E)!==E)throw new V("`length` must be a positive 32-bit integer");var C=arguments.length>2&&!!arguments[2],D=!0,z=!0;if("length"in S&&L){var R=L(S,"length");if(R&&!R.configurable)D=!1;if(R&&!R.writable)z=!1}if(D||z||!C)if(H)T(S,"length",E,!0,!0);else T(S,"length",E);return S}}),tJ=I0((I,O)=>{var W=VX(),T=$Z(),H=PQ();O.exports=function(){return H(W,T,arguments)}}),rJ=I0((I,O)=>{var W=sJ(),T=PX(),H=KZ(),L=tJ();if(O.exports=function(V){var P=H(arguments),S=V.length-(arguments.length-1);return W(P,1+(S>0?S:0),!0)},T)T(O.exports,"apply",{value:L});else O.exports.apply=L}),aJ=I0((I,O)=>{var W=RQ();O.exports=function(){return W()&&!!Symbol.toStringTag}}),eJ=I0((I,O)=>{var W=lJ(),T=oJ(),H=rJ(),L=vQ(),V=JX(),P=kQ(),S=L("Object.prototype.toString"),E=aJ()(),C=typeof globalThis>"u"?globalThis:globalThis,D=T(),z=L("String.prototype.slice"),R=L("Array.prototype.indexOf",!0)||function(j,v){for(var x=0;x<j.length;x+=1)if(j[x]===v)return x;return-1},q={__proto__:null};if(E&&V&&P)W(D,function(j){var v=new C[j];if(Symbol.toStringTag in v&&P){var x=P(v),N=V(x,Symbol.toStringTag);if(!N&&x){var f=P(x);N=V(f,Symbol.toStringTag)}q["$"+j]=H(N.get)}});else W(D,function(j){var v=new C[j],x=v.slice||v.set;if(x)q["$"+j]=H(x)});var _=function(j){var v=!1;return W(q,function(x,N){if(!v)try{if("$"+x(j)===N)v=z(N,1)}catch(f){}}),v},k=function(j){var v=!1;return W(q,function(x,N){if(!v)try{x(j),v=z(N,1)}catch(f){}}),v};O.exports=function(j){if(!j||typeof j!=="object")return!1;if(!E){var v=z(S(j),8,-1);if(R(D,v)>-1)return v;if(v!=="Object")return!1;return k(j)}if(!V)return null;return _(j)}}),iJ=I0((I,O)=>{var W=eJ();O.exports=function(T){return!!W(T)}}),UV=I0((I,O)=>{var W=YX(),T=vQ(),H=T("TypedArray.prototype.buffer",!0),L=iJ();O.exports=H||function(V){if(!L(V))throw new W("Not a Typed Array");return V.buffer}}),XV=I0((I,O)=>{var W=EU().Buffer,T=MJ(),H=UV(),L=ArrayBuffer.isView||function(E){try{return H(E),!0}catch(C){return!1}},V=typeof Uint8Array<"u",P=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u",S=P&&(W.prototype instanceof Uint8Array||W.TYPED_ARRAY_SUPPORT);O.exports=function(E,C){if(W.isBuffer(E)){if(E.constructor&&!("isBuffer"in E))return W.from(E);return E}if(typeof E==="string")return W.from(E,C);if(P&&L(E)){if(E.byteLength===0)return W.alloc(0);if(S){var D=W.from(E.buffer,E.byteOffset,E.byteLength);if(D.byteLength===E.byteLength)return D}var z=E instanceof Uint8Array?E:new Uint8Array(E.buffer,E.byteOffset,E.byteLength),R=W.from(z);if(R.length===E.byteLength)return R}if(V&&E instanceof Uint8Array)return W.from(E);var q=T(E);if(q)for(var _=0;_<E.length;_+=1){var k=E[_];if(typeof k!=="number"||k<0||k>255||~~k!==k)throw RangeError("Array items must be numbers in the range 0-255.")}if(q||W.isBuffer(E)&&E.constructor&&typeof E.constructor.isBuffer==="function"&&E.constructor.isBuffer(E))return W.from(E);throw TypeError('The "data" argument must be a string, an Array, a Buffer, a Uint8Array, or a DataView.')}}),OZ=I0((I,O)=>{var W=EU().Buffer,T=XV(),H=typeof Uint8Array<"u",L=H&&typeof ArrayBuffer<"u",V=L&&ArrayBuffer.isView;O.exports=function(P,S,E){if(typeof P==="string"||W.isBuffer(P)||H&&P instanceof Uint8Array||V&&V(P))return T(P,S);throw TypeError(E+" must be a string, a Buffer, a Uint8Array, or a DataView")}}),_Q=I0((I,O)=>{var W={__proto__:null,md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,"sha512-256":32,rmd160:20,ripemd160:20},T={__proto__:null,"sha-1":"sha1","sha-224":"sha224","sha-256":"sha256","sha-384":"sha384","sha-512":"sha512","ripemd-160":"ripemd160"},H=EQ(),L=EU().Buffer,V=VZ(),P=GZ(),S=OZ();function E(C,D,z,R,q){V(z,R),C=S(C,P,"Password"),D=S(D,P,"Salt");var _=(q||"sha1").toLowerCase(),k=T[_]||_,j=W[k];if(typeof j!=="number"||!j)throw TypeError("Digest algorithm not supported: "+q);var v=L.allocUnsafe(R),x=L.allocUnsafe(D.length+4);D.copy(x,0,0,D.length);var N=0,f=j,b=Math.ceil(R/f);for(var Q0=1;Q0<=b;Q0++){x.writeUInt32BE(Q0,D.length);var G0=H(k,C).update(x).digest(),Y0=G0;for(var u=1;u<z;u++){Y0=H(k,C).update(Y0).digest();for(var U0=0;U0<f;U0++)G0[U0]^=Y0[U0]}G0.copy(v,N),N+=f}return v}O.exports=E}),ZV=I0((I,O)=>{var W=EU().Buffer,T=VZ(),H=GZ(),L=_Q(),V=OZ(),P,S=globalThis.crypto&&globalThis.crypto.subtle,E={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"},C=[],D;function z(){if(D)return D;if(globalThis.process&&globalThis.process.nextTick)D=globalThis.process.nextTick;else if(globalThis.queueMicrotask)D=globalThis.queueMicrotask;else if(globalThis.setImmediate)D=globalThis.setImmediate;else D=globalThis.setTimeout;return D}function R(k,j,v,x,N){return S.importKey("raw",k,{name:"PBKDF2"},!1,["deriveBits"]).then(function(f){return S.deriveBits({name:"PBKDF2",salt:j,iterations:v,hash:{name:N}},f,x<<3)}).then(function(f){return W.from(f)})}function q(k){if(globalThis.process&&!globalThis.process.browser)return Promise.resolve(!1);if(!S||!S.importKey||!S.deriveBits)return Promise.resolve(!1);if(C[k]!==void 0)return C[k];P=P||W.alloc(8);var j=R(P,P,10,128,k).then(function(){return!0},function(){return!1});return C[k]=j,j}function _(k,j){k.then(function(v){z()(function(){j(null,v)})},function(v){z()(function(){j(v)})})}O.exports=function(k,j,v,x,N,f){if(typeof N==="function")f=N,N=void 0;if(T(v,x),k=V(k,H,"Password"),j=V(j,H,"Salt"),typeof f!=="function")throw Error("No callback provided to pbkdf2");N=N||"sha1";var b=E[N.toLowerCase()];if(!b||typeof globalThis.Promise!=="function"){z()(function(){var Q0;try{Q0=L(k,j,v,x,N)}catch(G0){f(G0);return}f(null,Q0)});return}_(q(b).then(function(Q0){if(Q0)return R(k,j,v,x,b);return L(k,j,v,x,N)}),f)}}),BQ=I0((I)=>{var O=(qU(),h0(RU)),W=VZ(),T=GZ(),H=OZ();function L(P,S,E,C,D,z){if(W(E,C),P=H(P,T,"Password"),S=H(S,T,"Salt"),typeof D==="function")z=D,D="sha1";if(typeof z!=="function")throw Error("No callback provided to pbkdf2");return O.pbkdf2(P,S,E,C,D,z)}function V(P,S,E,C,D){return W(E,C),P=H(P,T,"Password"),S=H(S,T,"Salt"),D=D||"sha1",O.pbkdf2Sync(P,S,E,C,D)}if(!O.pbkdf2Sync||O.pbkdf2Sync.toString().indexOf("keylen, digest")===-1)I.pbkdf2Sync=_Q(),I.pbkdf2=ZV();else I.pbkdf2Sync=V,I.pbkdf2=L}),QV=I0((I)=>{var O=(qU(),h0(RU));I.createCipher=I.Cipher=O.createCipher,I.createCipheriv=I.Cipheriv=O.createCipheriv,I.createDecipher=I.Decipher=O.createDecipher,I.createDecipheriv=I.Decipheriv=O.createDecipheriv,I.listCiphers=I.getCiphers=O.getCiphers}),YV=I0((I)=>{var O=(qU(),h0(RU));I.DiffieHellmanGroup=O.DiffieHellmanGroup,I.createDiffieHellmanGroup=O.createDiffieHellmanGroup,I.getDiffieHellman=O.getDiffieHellman,I.createDiffieHellman=O.createDiffieHellman,I.DiffieHellman=O.DiffieHellman}),JV=I0((I)=>{var O=(qU(),h0(RU));I.createSign=O.createSign,I.Sign=O.Sign,I.createVerify=O.createVerify,I.Verify=O.Verify}),VV=I0((I,O)=>{O.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"}}}),gU=I0((I,O)=>{(function(W,T){function H(U,Q){if(!U)throw Error(Q||"Assertion failed")}function L(U,Q){U.super_=Q;var J=function(){};J.prototype=Q.prototype,U.prototype=new J,U.prototype.constructor=U}function V(U,Q,J){if(V.isBN(U))return U;if(this.negative=0,this.words=null,this.length=0,this.red=null,U!==null){if(Q==="le"||Q==="be")J=Q,Q=10;this._init(U||0,Q||10,J||"be")}}if(typeof W==="object")W.exports=V;else T.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window<"u"&&typeof window.Buffer<"u")P=window.Buffer;else P=(HU(),h0(WU)).Buffer}catch(U){}V.isBN=function(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(U,Q){if(U.cmp(Q)>0)return U;return Q},V.min=function(U,Q){if(U.cmp(Q)<0)return U;return Q},V.prototype._init=function(U,Q,J){if(typeof U==="number")return this._initNumber(U,Q,J);if(typeof U==="object")return this._initArray(U,Q,J);if(Q==="hex")Q=16;H(Q===(Q|0)&&Q>=2&&Q<=36),U=U.toString().replace(/\s+/g,"");var Z=0;if(U[0]==="-")Z++,this.negative=1;if(Z<U.length){if(Q===16)this._parseHex(U,Z,J);else if(this._parseBase(U,Q,Z),J==="le")this._initArray(this.toArray(),Q,J)}},V.prototype._initNumber=function(U,Q,J){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(J!=="le")return;this._initArray(this.toArray(),Q,J)},V.prototype._initArray=function(U,Q,J){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=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y,K,F=0;if(J==="be"){for(Z=U.length-1,Y=0;Z>=0;Z-=3)if(K=U[Z]|U[Z-1]<<8|U[Z-2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}else if(J==="le"){for(Z=0,Y=0;Z<U.length;Z+=3)if(K=U[Z]|U[Z+1]<<8|U[Z+2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}return this.strip()};function S(U,Q){var J=U.charCodeAt(Q);if(J>=65&&J<=70)return J-55;else if(J>=97&&J<=102)return J-87;else return J-48&15}function E(U,Q,J){var Z=S(U,J);if(J-1>=Q)Z|=S(U,J-1)<<4;return Z}V.prototype._parseHex=function(U,Q,J){this.length=Math.ceil((U.length-Q)/6),this.words=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y=0,K=0,F;if(J==="be")for(Z=U.length-1;Z>=Q;Z-=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8;else{var G=U.length-Q;for(Z=G%2===0?Q+1:Q;Z<U.length;Z+=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8}this.strip()};function C(U,Q,J,Z){var Y=0,K=Math.min(U.length,J);for(var F=Q;F<K;F++){var G=U.charCodeAt(F)-48;if(Y*=Z,G>=49)Y+=G-49+10;else if(G>=17)Y+=G-17+10;else Y+=G}return Y}V.prototype._parseBase=function(U,Q,J){this.words=[0],this.length=1;for(var Z=0,Y=1;Y<=67108863;Y*=Q)Z++;Z--,Y=Y/Q|0;var K=U.length-J,F=K%Z,G=Math.min(K,K-F)+J,X=0;for(var $=J;$<G;$+=Z)if(X=C(U,$,$+Z,Q),this.imuln(Y),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(F!==0){var M=1;X=C(U,$,U.length,Q);for($=0;$<F;$++)M*=Q;if(this.imuln(M),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function(U){U.words=Array(this.length);for(var Q=0;Q<this.length;Q++)U.words[Q]=this.words[Q];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function(){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"],z=[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],R=[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(U,Q){U=U||10,Q=Q|0||1;var J;if(U===16||U==="hex"){J="";var Z=0,Y=0;for(var K=0;K<this.length;K++){var F=this.words[K],G=((F<<Z|Y)&16777215).toString(16);if(Y=F>>>24-Z&16777215,Z+=2,Z>=26)Z-=26,K--;if(Y!==0||K!==this.length-1)J=D[6-G.length]+G+J;else J=G+J}if(Y!==0)J=Y.toString(16)+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}if(U===(U|0)&&U>=2&&U<=36){var X=z[U],$=R[U];J="";var M=this.clone();M.negative=0;while(!M.isZero()){var A=M.modn($).toString(U);if(M=M.idivn($),!M.isZero())J=D[X-A.length]+A+J;else J=A+J}if(this.isZero())J="0"+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function(){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(){return this.toString(16)},V.prototype.toBuffer=function(U,Q){return H(typeof P<"u"),this.toArrayLike(P,U,Q)},V.prototype.toArray=function(U,Q){return this.toArrayLike(Array,U,Q)},V.prototype.toArrayLike=function(U,Q,J){var Z=this.byteLength(),Y=J||Math.max(1,Z);H(Z<=Y,"byte array longer than desired length"),H(Y>0,"Requested array length <= 0"),this.strip();var K=Q==="le",F=new U(Y),G,X,$=this.clone();if(!K){for(X=0;X<Y-Z;X++)F[X]=0;for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[Y-X-1]=G}else{for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[X]=G;for(;X<Y;X++)F[X]=0}return F},Math.clz32)V.prototype._countBits=function(U){return 32-Math.clz32(U)};else V.prototype._countBits=function(U){var Q=U,J=0;if(Q>=4096)J+=13,Q>>>=13;if(Q>=64)J+=7,Q>>>=7;if(Q>=8)J+=4,Q>>>=4;if(Q>=2)J+=2,Q>>>=2;return J+Q};V.prototype._zeroBits=function(U){if(U===0)return 26;var Q=U,J=0;if((Q&8191)===0)J+=13,Q>>>=13;if((Q&127)===0)J+=7,Q>>>=7;if((Q&15)===0)J+=4,Q>>>=4;if((Q&3)===0)J+=2,Q>>>=2;if((Q&1)===0)J++;return J},V.prototype.bitLength=function(){var U=this.words[this.length-1],Q=this._countBits(U);return(this.length-1)*26+Q};function q(U){var Q=Array(U.bitLength());for(var J=0;J<Q.length;J++){var Z=J/26|0,Y=J%26;Q[J]=(U.words[Z]&1<<Y)>>>Y}return Q}V.prototype.zeroBits=function(){if(this.isZero())return 0;var U=0;for(var Q=0;Q<this.length;Q++){var J=this._zeroBits(this.words[Q]);if(U+=J,J!==26)break}return U},V.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function(){return this.negative!==0},V.prototype.neg=function(){return this.clone().ineg()},V.prototype.ineg=function(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function(U){while(this.length<U.length)this.words[this.length++]=0;for(var Q=0;Q<U.length;Q++)this.words[Q]=this.words[Q]|U.words[Q];return this.strip()},V.prototype.ior=function(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function(U){var Q;if(this.length>U.length)Q=U;else Q=this;for(var J=0;J<Q.length;J++)this.words[J]=this.words[J]&U.words[J];return this.length=Q.length,this.strip()},V.prototype.iand=function(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function(U){var Q,J;if(this.length>U.length)Q=this,J=U;else Q=U,J=this;for(var Z=0;Z<J.length;Z++)this.words[Z]=Q.words[Z]^J.words[Z];if(this!==Q)for(;Z<Q.length;Z++)this.words[Z]=Q.words[Z];return this.length=Q.length,this.strip()},V.prototype.ixor=function(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function(U){H(typeof U==="number"&&U>=0);var Q=Math.ceil(U/26)|0,J=U%26;if(this._expand(Q),J>0)Q--;for(var Z=0;Z<Q;Z++)this.words[Z]=~this.words[Z]&67108863;if(J>0)this.words[Z]=~this.words[Z]&67108863>>26-J;return this.strip()},V.prototype.notn=function(U){return this.clone().inotn(U)},V.prototype.setn=function(U,Q){H(typeof U==="number"&&U>=0);var J=U/26|0,Z=U%26;if(this._expand(J+1),Q)this.words[J]=this.words[J]|1<<Z;else this.words[J]=this.words[J]&~(1<<Z);return this.strip()},V.prototype.iadd=function(U){var Q;if(this.negative!==0&&U.negative===0)return this.negative=0,Q=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Q=this.isub(U),U.negative=1,Q._normSign();var J,Z;if(this.length>U.length)J=this,Z=U;else J=U,Z=this;var Y=0;for(var K=0;K<Z.length;K++)Q=(J.words[K]|0)+(Z.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;for(;Y!==0&&K<J.length;K++)Q=(J.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;if(this.length=J.length,Y!==0)this.words[this.length]=Y,this.length++;else if(J!==this)for(;K<J.length;K++)this.words[K]=J.words[K];return this},V.prototype.add=function(U){var Q;if(U.negative!==0&&this.negative===0)return U.negative=0,Q=this.sub(U),U.negative^=1,Q;else if(U.negative===0&&this.negative!==0)return this.negative=0,Q=U.sub(this),this.negative=1,Q;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function(U){if(U.negative!==0){U.negative=0;var Q=this.iadd(U);return U.negative=1,Q._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var J=this.cmp(U);if(J===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Z,Y;if(J>0)Z=this,Y=U;else Z=U,Y=this;var K=0;for(var F=0;F<Y.length;F++)Q=(Z.words[F]|0)-(Y.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;for(;K!==0&&F<Z.length;F++)Q=(Z.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;if(K===0&&F<Z.length&&Z!==this)for(;F<Z.length;F++)this.words[F]=Z.words[F];if(this.length=Math.max(this.length,F),Z!==this)this.negative=1;return this.strip()},V.prototype.sub=function(U){return this.clone().isub(U)};function _(U,Q,J){J.negative=Q.negative^U.negative;var Z=U.length+Q.length|0;J.length=Z,Z=Z-1|0;var Y=U.words[0]|0,K=Q.words[0]|0,F=Y*K,G=F&67108863,X=F/67108864|0;J.words[0]=G;for(var $=1;$<Z;$++){var M=X>>>26,A=X&67108863,B=Math.min($,Q.length-1);for(var w=Math.max(0,$-U.length+1);w<=B;w++){var p=$-w|0;Y=U.words[p]|0,K=Q.words[w]|0,F=Y*K+A,M+=F/67108864|0,A=F&67108863}J.words[$]=A|0,X=M|0}if(X!==0)J.words[$]=X|0;else J.length--;return J.strip()}var k=function(U,Q,J){var Z=U.words,Y=Q.words,K=J.words,F=0,G,X,$,M=Z[0]|0,A=M&8191,B=M>>>13,w=Z[1]|0,p=w&8191,n=w>>>13,K0=Z[2]|0,r=K0&8191,d=K0>>>13,J0=Z[3]|0,m=J0&8191,i=J0>>>13,g0=Z[4]|0,y=g0&8191,h=g0>>>13,V0=Z[5]|0,t=V0&8191,e=V0>>>13,E0=Z[6]|0,c=E0&8191,o=E0>>>13,N0=Z[7]|0,s=N0&8191,Z0=N0>>>13,f0=Z[8]|0,W0=f0&8191,H0=f0>>>13,n0=Z[9]|0,O0=n0&8191,D0=n0>>>13,t0=Y[0]|0,z0=t0&8191,A0=t0>>>13,AU=Y[1]|0,L0=AU&8191,k0=AU>>>13,zU=Y[2]|0,j0=zU&8191,M0=zU>>>13,DU=Y[3]|0,v0=DU&8191,R0=DU>>>13,KU=Y[4]|0,_0=KU&8191,B0=KU>>>13,OU=Y[5]|0,q0=OU&8191,g=OU>>>13,l=Y[6]|0,a=l&8191,X0=l>>>13,w0=Y[7]|0,F0=w0&8191,T0=w0>>>13,m0=Y[8]|0,S0=m0&8191,x0=m0>>>13,TU=Y[9]|0,P0=TU&8191,C0=TU>>>13;J.negative=U.negative^Q.negative,J.length=19,G=Math.imul(A,z0),X=Math.imul(A,A0),X=X+Math.imul(B,z0)|0,$=Math.imul(B,A0);var s0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(s0>>>26)|0,s0&=67108863,G=Math.imul(p,z0),X=Math.imul(p,A0),X=X+Math.imul(n,z0)|0,$=Math.imul(n,A0),G=G+Math.imul(A,L0)|0,X=X+Math.imul(A,k0)|0,X=X+Math.imul(B,L0)|0,$=$+Math.imul(B,k0)|0;var c0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(c0>>>26)|0,c0&=67108863,G=Math.imul(r,z0),X=Math.imul(r,A0),X=X+Math.imul(d,z0)|0,$=Math.imul(d,A0),G=G+Math.imul(p,L0)|0,X=X+Math.imul(p,k0)|0,X=X+Math.imul(n,L0)|0,$=$+Math.imul(n,k0)|0,G=G+Math.imul(A,j0)|0,X=X+Math.imul(A,M0)|0,X=X+Math.imul(B,j0)|0,$=$+Math.imul(B,M0)|0;var y0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(y0>>>26)|0,y0&=67108863,G=Math.imul(m,z0),X=Math.imul(m,A0),X=X+Math.imul(i,z0)|0,$=Math.imul(i,A0),G=G+Math.imul(r,L0)|0,X=X+Math.imul(r,k0)|0,X=X+Math.imul(d,L0)|0,$=$+Math.imul(d,k0)|0,G=G+Math.imul(p,j0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(n,j0)|0,$=$+Math.imul(n,M0)|0,G=G+Math.imul(A,v0)|0,X=X+Math.imul(A,R0)|0,X=X+Math.imul(B,v0)|0,$=$+Math.imul(B,R0)|0;var l0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(l0>>>26)|0,l0&=67108863,G=Math.imul(y,z0),X=Math.imul(y,A0),X=X+Math.imul(h,z0)|0,$=Math.imul(h,A0),G=G+Math.imul(m,L0)|0,X=X+Math.imul(m,k0)|0,X=X+Math.imul(i,L0)|0,$=$+Math.imul(i,k0)|0,G=G+Math.imul(r,j0)|0,X=X+Math.imul(r,M0)|0,X=X+Math.imul(d,j0)|0,$=$+Math.imul(d,M0)|0,G=G+Math.imul(p,v0)|0,X=X+Math.imul(p,R0)|0,X=X+Math.imul(n,v0)|0,$=$+Math.imul(n,R0)|0,G=G+Math.imul(A,_0)|0,X=X+Math.imul(A,B0)|0,X=X+Math.imul(B,_0)|0,$=$+Math.imul(B,B0)|0;var b0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,G=Math.imul(t,z0),X=Math.imul(t,A0),X=X+Math.imul(e,z0)|0,$=Math.imul(e,A0),G=G+Math.imul(y,L0)|0,X=X+Math.imul(y,k0)|0,X=X+Math.imul(h,L0)|0,$=$+Math.imul(h,k0)|0,G=G+Math.imul(m,j0)|0,X=X+Math.imul(m,M0)|0,X=X+Math.imul(i,j0)|0,$=$+Math.imul(i,M0)|0,G=G+Math.imul(r,v0)|0,X=X+Math.imul(r,R0)|0,X=X+Math.imul(d,v0)|0,$=$+Math.imul(d,R0)|0,G=G+Math.imul(p,_0)|0,X=X+Math.imul(p,B0)|0,X=X+Math.imul(n,_0)|0,$=$+Math.imul(n,B0)|0,G=G+Math.imul(A,q0)|0,X=X+Math.imul(A,g)|0,X=X+Math.imul(B,q0)|0,$=$+Math.imul(B,g)|0;var r0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(r0>>>26)|0,r0&=67108863,G=Math.imul(c,z0),X=Math.imul(c,A0),X=X+Math.imul(o,z0)|0,$=Math.imul(o,A0),G=G+Math.imul(t,L0)|0,X=X+Math.imul(t,k0)|0,X=X+Math.imul(e,L0)|0,$=$+Math.imul(e,k0)|0,G=G+Math.imul(y,j0)|0,X=X+Math.imul(y,M0)|0,X=X+Math.imul(h,j0)|0,$=$+Math.imul(h,M0)|0,G=G+Math.imul(m,v0)|0,X=X+Math.imul(m,R0)|0,X=X+Math.imul(i,v0)|0,$=$+Math.imul(i,R0)|0,G=G+Math.imul(r,_0)|0,X=X+Math.imul(r,B0)|0,X=X+Math.imul(d,_0)|0,$=$+Math.imul(d,B0)|0,G=G+Math.imul(p,q0)|0,X=X+Math.imul(p,g)|0,X=X+Math.imul(n,q0)|0,$=$+Math.imul(n,g)|0,G=G+Math.imul(A,a)|0,X=X+Math.imul(A,X0)|0,X=X+Math.imul(B,a)|0,$=$+Math.imul(B,X0)|0;var a0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,G=Math.imul(s,z0),X=Math.imul(s,A0),X=X+Math.imul(Z0,z0)|0,$=Math.imul(Z0,A0),G=G+Math.imul(c,L0)|0,X=X+Math.imul(c,k0)|0,X=X+Math.imul(o,L0)|0,$=$+Math.imul(o,k0)|0,G=G+Math.imul(t,j0)|0,X=X+Math.imul(t,M0)|0,X=X+Math.imul(e,j0)|0,$=$+Math.imul(e,M0)|0,G=G+Math.imul(y,v0)|0,X=X+Math.imul(y,R0)|0,X=X+Math.imul(h,v0)|0,$=$+Math.imul(h,R0)|0,G=G+Math.imul(m,_0)|0,X=X+Math.imul(m,B0)|0,X=X+Math.imul(i,_0)|0,$=$+Math.imul(i,B0)|0,G=G+Math.imul(r,q0)|0,X=X+Math.imul(r,g)|0,X=X+Math.imul(d,q0)|0,$=$+Math.imul(d,g)|0,G=G+Math.imul(p,a)|0,X=X+Math.imul(p,X0)|0,X=X+Math.imul(n,a)|0,$=$+Math.imul(n,X0)|0,G=G+Math.imul(A,F0)|0,X=X+Math.imul(A,T0)|0,X=X+Math.imul(B,F0)|0,$=$+Math.imul(B,T0)|0;var e0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,G=Math.imul(W0,z0),X=Math.imul(W0,A0),X=X+Math.imul(H0,z0)|0,$=Math.imul(H0,A0),G=G+Math.imul(s,L0)|0,X=X+Math.imul(s,k0)|0,X=X+Math.imul(Z0,L0)|0,$=$+Math.imul(Z0,k0)|0,G=G+Math.imul(c,j0)|0,X=X+Math.imul(c,M0)|0,X=X+Math.imul(o,j0)|0,$=$+Math.imul(o,M0)|0,G=G+Math.imul(t,v0)|0,X=X+Math.imul(t,R0)|0,X=X+Math.imul(e,v0)|0,$=$+Math.imul(e,R0)|0,G=G+Math.imul(y,_0)|0,X=X+Math.imul(y,B0)|0,X=X+Math.imul(h,_0)|0,$=$+Math.imul(h,B0)|0,G=G+Math.imul(m,q0)|0,X=X+Math.imul(m,g)|0,X=X+Math.imul(i,q0)|0,$=$+Math.imul(i,g)|0,G=G+Math.imul(r,a)|0,X=X+Math.imul(r,X0)|0,X=X+Math.imul(d,a)|0,$=$+Math.imul(d,X0)|0,G=G+Math.imul(p,F0)|0,X=X+Math.imul(p,T0)|0,X=X+Math.imul(n,F0)|0,$=$+Math.imul(n,T0)|0,G=G+Math.imul(A,S0)|0,X=X+Math.imul(A,x0)|0,X=X+Math.imul(B,S0)|0,$=$+Math.imul(B,x0)|0;var i0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,G=Math.imul(O0,z0),X=Math.imul(O0,A0),X=X+Math.imul(D0,z0)|0,$=Math.imul(D0,A0),G=G+Math.imul(W0,L0)|0,X=X+Math.imul(W0,k0)|0,X=X+Math.imul(H0,L0)|0,$=$+Math.imul(H0,k0)|0,G=G+Math.imul(s,j0)|0,X=X+Math.imul(s,M0)|0,X=X+Math.imul(Z0,j0)|0,$=$+Math.imul(Z0,M0)|0,G=G+Math.imul(c,v0)|0,X=X+Math.imul(c,R0)|0,X=X+Math.imul(o,v0)|0,$=$+Math.imul(o,R0)|0,G=G+Math.imul(t,_0)|0,X=X+Math.imul(t,B0)|0,X=X+Math.imul(e,_0)|0,$=$+Math.imul(e,B0)|0,G=G+Math.imul(y,q0)|0,X=X+Math.imul(y,g)|0,X=X+Math.imul(h,q0)|0,$=$+Math.imul(h,g)|0,G=G+Math.imul(m,a)|0,X=X+Math.imul(m,X0)|0,X=X+Math.imul(i,a)|0,$=$+Math.imul(i,X0)|0,G=G+Math.imul(r,F0)|0,X=X+Math.imul(r,T0)|0,X=X+Math.imul(d,F0)|0,$=$+Math.imul(d,T0)|0,G=G+Math.imul(p,S0)|0,X=X+Math.imul(p,x0)|0,X=X+Math.imul(n,S0)|0,$=$+Math.imul(n,x0)|0,G=G+Math.imul(A,P0)|0,X=X+Math.imul(A,C0)|0,X=X+Math.imul(B,P0)|0,$=$+Math.imul(B,C0)|0;var UU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,G=Math.imul(O0,L0),X=Math.imul(O0,k0),X=X+Math.imul(D0,L0)|0,$=Math.imul(D0,k0),G=G+Math.imul(W0,j0)|0,X=X+Math.imul(W0,M0)|0,X=X+Math.imul(H0,j0)|0,$=$+Math.imul(H0,M0)|0,G=G+Math.imul(s,v0)|0,X=X+Math.imul(s,R0)|0,X=X+Math.imul(Z0,v0)|0,$=$+Math.imul(Z0,R0)|0,G=G+Math.imul(c,_0)|0,X=X+Math.imul(c,B0)|0,X=X+Math.imul(o,_0)|0,$=$+Math.imul(o,B0)|0,G=G+Math.imul(t,q0)|0,X=X+Math.imul(t,g)|0,X=X+Math.imul(e,q0)|0,$=$+Math.imul(e,g)|0,G=G+Math.imul(y,a)|0,X=X+Math.imul(y,X0)|0,X=X+Math.imul(h,a)|0,$=$+Math.imul(h,X0)|0,G=G+Math.imul(m,F0)|0,X=X+Math.imul(m,T0)|0,X=X+Math.imul(i,F0)|0,$=$+Math.imul(i,T0)|0,G=G+Math.imul(r,S0)|0,X=X+Math.imul(r,x0)|0,X=X+Math.imul(d,S0)|0,$=$+Math.imul(d,x0)|0,G=G+Math.imul(p,P0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(n,P0)|0,$=$+Math.imul(n,C0)|0;var XU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,G=Math.imul(O0,j0),X=Math.imul(O0,M0),X=X+Math.imul(D0,j0)|0,$=Math.imul(D0,M0),G=G+Math.imul(W0,v0)|0,X=X+Math.imul(W0,R0)|0,X=X+Math.imul(H0,v0)|0,$=$+Math.imul(H0,R0)|0,G=G+Math.imul(s,_0)|0,X=X+Math.imul(s,B0)|0,X=X+Math.imul(Z0,_0)|0,$=$+Math.imul(Z0,B0)|0,G=G+Math.imul(c,q0)|0,X=X+Math.imul(c,g)|0,X=X+Math.imul(o,q0)|0,$=$+Math.imul(o,g)|0,G=G+Math.imul(t,a)|0,X=X+Math.imul(t,X0)|0,X=X+Math.imul(e,a)|0,$=$+Math.imul(e,X0)|0,G=G+Math.imul(y,F0)|0,X=X+Math.imul(y,T0)|0,X=X+Math.imul(h,F0)|0,$=$+Math.imul(h,T0)|0,G=G+Math.imul(m,S0)|0,X=X+Math.imul(m,x0)|0,X=X+Math.imul(i,S0)|0,$=$+Math.imul(i,x0)|0,G=G+Math.imul(r,P0)|0,X=X+Math.imul(r,C0)|0,X=X+Math.imul(d,P0)|0,$=$+Math.imul(d,C0)|0;var ZU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,G=Math.imul(O0,v0),X=Math.imul(O0,R0),X=X+Math.imul(D0,v0)|0,$=Math.imul(D0,R0),G=G+Math.imul(W0,_0)|0,X=X+Math.imul(W0,B0)|0,X=X+Math.imul(H0,_0)|0,$=$+Math.imul(H0,B0)|0,G=G+Math.imul(s,q0)|0,X=X+Math.imul(s,g)|0,X=X+Math.imul(Z0,q0)|0,$=$+Math.imul(Z0,g)|0,G=G+Math.imul(c,a)|0,X=X+Math.imul(c,X0)|0,X=X+Math.imul(o,a)|0,$=$+Math.imul(o,X0)|0,G=G+Math.imul(t,F0)|0,X=X+Math.imul(t,T0)|0,X=X+Math.imul(e,F0)|0,$=$+Math.imul(e,T0)|0,G=G+Math.imul(y,S0)|0,X=X+Math.imul(y,x0)|0,X=X+Math.imul(h,S0)|0,$=$+Math.imul(h,x0)|0,G=G+Math.imul(m,P0)|0,X=X+Math.imul(m,C0)|0,X=X+Math.imul(i,P0)|0,$=$+Math.imul(i,C0)|0;var QU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,G=Math.imul(O0,_0),X=Math.imul(O0,B0),X=X+Math.imul(D0,_0)|0,$=Math.imul(D0,B0),G=G+Math.imul(W0,q0)|0,X=X+Math.imul(W0,g)|0,X=X+Math.imul(H0,q0)|0,$=$+Math.imul(H0,g)|0,G=G+Math.imul(s,a)|0,X=X+Math.imul(s,X0)|0,X=X+Math.imul(Z0,a)|0,$=$+Math.imul(Z0,X0)|0,G=G+Math.imul(c,F0)|0,X=X+Math.imul(c,T0)|0,X=X+Math.imul(o,F0)|0,$=$+Math.imul(o,T0)|0,G=G+Math.imul(t,S0)|0,X=X+Math.imul(t,x0)|0,X=X+Math.imul(e,S0)|0,$=$+Math.imul(e,x0)|0,G=G+Math.imul(y,P0)|0,X=X+Math.imul(y,C0)|0,X=X+Math.imul(h,P0)|0,$=$+Math.imul(h,C0)|0;var YU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,G=Math.imul(O0,q0),X=Math.imul(O0,g),X=X+Math.imul(D0,q0)|0,$=Math.imul(D0,g),G=G+Math.imul(W0,a)|0,X=X+Math.imul(W0,X0)|0,X=X+Math.imul(H0,a)|0,$=$+Math.imul(H0,X0)|0,G=G+Math.imul(s,F0)|0,X=X+Math.imul(s,T0)|0,X=X+Math.imul(Z0,F0)|0,$=$+Math.imul(Z0,T0)|0,G=G+Math.imul(c,S0)|0,X=X+Math.imul(c,x0)|0,X=X+Math.imul(o,S0)|0,$=$+Math.imul(o,x0)|0,G=G+Math.imul(t,P0)|0,X=X+Math.imul(t,C0)|0,X=X+Math.imul(e,P0)|0,$=$+Math.imul(e,C0)|0;var JU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(JU>>>26)|0,JU&=67108863,G=Math.imul(O0,a),X=Math.imul(O0,X0),X=X+Math.imul(D0,a)|0,$=Math.imul(D0,X0),G=G+Math.imul(W0,F0)|0,X=X+Math.imul(W0,T0)|0,X=X+Math.imul(H0,F0)|0,$=$+Math.imul(H0,T0)|0,G=G+Math.imul(s,S0)|0,X=X+Math.imul(s,x0)|0,X=X+Math.imul(Z0,S0)|0,$=$+Math.imul(Z0,x0)|0,G=G+Math.imul(c,P0)|0,X=X+Math.imul(c,C0)|0,X=X+Math.imul(o,P0)|0,$=$+Math.imul(o,C0)|0;var VU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,G=Math.imul(O0,F0),X=Math.imul(O0,T0),X=X+Math.imul(D0,F0)|0,$=Math.imul(D0,T0),G=G+Math.imul(W0,S0)|0,X=X+Math.imul(W0,x0)|0,X=X+Math.imul(H0,S0)|0,$=$+Math.imul(H0,x0)|0,G=G+Math.imul(s,P0)|0,X=X+Math.imul(s,C0)|0,X=X+Math.imul(Z0,P0)|0,$=$+Math.imul(Z0,C0)|0;var GU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,G=Math.imul(O0,S0),X=Math.imul(O0,x0),X=X+Math.imul(D0,S0)|0,$=Math.imul(D0,x0),G=G+Math.imul(W0,P0)|0,X=X+Math.imul(W0,C0)|0,X=X+Math.imul(H0,P0)|0,$=$+Math.imul(H0,C0)|0;var IU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,G=Math.imul(O0,P0),X=Math.imul(O0,C0),X=X+Math.imul(D0,P0)|0,$=Math.imul(D0,C0);var $U=(F+G|0)+((X&8191)<<13)|0;if(F=($+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,K[0]=s0,K[1]=c0,K[2]=y0,K[3]=l0,K[4]=b0,K[5]=r0,K[6]=a0,K[7]=e0,K[8]=i0,K[9]=UU,K[10]=XU,K[11]=ZU,K[12]=QU,K[13]=YU,K[14]=JU,K[15]=VU,K[16]=GU,K[17]=IU,K[18]=$U,F!==0)K[19]=F,J.length++;return J};if(!Math.imul)k=_;function j(U,Q,J){J.negative=Q.negative^U.negative,J.length=U.length+Q.length;var Z=0,Y=0;for(var K=0;K<J.length-1;K++){var F=Y;Y=0;var G=Z&67108863,X=Math.min(K,Q.length-1);for(var $=Math.max(0,K-U.length+1);$<=X;$++){var M=K-$,A=U.words[M]|0,B=Q.words[$]|0,w=A*B,p=w&67108863;F=F+(w/67108864|0)|0,p=p+G|0,G=p&67108863,F=F+(p>>>26)|0,Y+=F>>>26,F&=67108863}J.words[K]=G,Z=F,F=Y}if(Z!==0)J.words[K]=Z;else J.length--;return J.strip()}function v(U,Q,J){var Z=new x;return Z.mulp(U,Q,J)}V.prototype.mulTo=function(U,Q){var J,Z=this.length+U.length;if(this.length===10&&U.length===10)J=k(this,U,Q);else if(Z<63)J=_(this,U,Q);else if(Z<1024)J=j(this,U,Q);else J=v(this,U,Q);return J};function x(U,Q){this.x=U,this.y=Q}x.prototype.makeRBT=function(U){var Q=Array(U),J=V.prototype._countBits(U)-1;for(var Z=0;Z<U;Z++)Q[Z]=this.revBin(Z,J,U);return Q},x.prototype.revBin=function(U,Q,J){if(U===0||U===J-1)return U;var Z=0;for(var Y=0;Y<Q;Y++)Z|=(U&1)<<Q-Y-1,U>>=1;return Z},x.prototype.permute=function(U,Q,J,Z,Y,K){for(var F=0;F<K;F++)Z[F]=Q[U[F]],Y[F]=J[U[F]]},x.prototype.transform=function(U,Q,J,Z,Y,K){this.permute(K,U,Q,J,Z,Y);for(var F=1;F<Y;F<<=1){var G=F<<1,X=Math.cos(2*Math.PI/G),$=Math.sin(2*Math.PI/G);for(var M=0;M<Y;M+=G){var A=X,B=$;for(var w=0;w<F;w++){var p=J[M+w],n=Z[M+w],K0=J[M+w+F],r=Z[M+w+F],d=A*K0-B*r;if(r=A*r+B*K0,K0=d,J[M+w]=p+K0,Z[M+w]=n+r,J[M+w+F]=p-K0,Z[M+w+F]=n-r,w!==G)d=X*A-$*B,B=X*B+$*A,A=d}}}},x.prototype.guessLen13b=function(U,Q){var J=Math.max(Q,U)|1,Z=J&1,Y=0;for(J=J/2|0;J;J=J>>>1)Y++;return 1<<Y+1+Z},x.prototype.conjugate=function(U,Q,J){if(J<=1)return;for(var Z=0;Z<J/2;Z++){var Y=U[Z];U[Z]=U[J-Z-1],U[J-Z-1]=Y,Y=Q[Z],Q[Z]=-Q[J-Z-1],Q[J-Z-1]=-Y}},x.prototype.normalize13b=function(U,Q){var J=0;for(var Z=0;Z<Q/2;Z++){var Y=Math.round(U[2*Z+1]/Q)*8192+Math.round(U[2*Z]/Q)+J;if(U[Z]=Y&67108863,Y<67108864)J=0;else J=Y/67108864|0}return U},x.prototype.convert13b=function(U,Q,J,Z){var Y=0;for(var K=0;K<Q;K++)Y=Y+(U[K]|0),J[2*K]=Y&8191,Y=Y>>>13,J[2*K+1]=Y&8191,Y=Y>>>13;for(K=2*Q;K<Z;++K)J[K]=0;H(Y===0),H((Y&-8192)===0)},x.prototype.stub=function(U){var Q=Array(U);for(var J=0;J<U;J++)Q[J]=0;return Q},x.prototype.mulp=function(U,Q,J){var Z=2*this.guessLen13b(U.length,Q.length),Y=this.makeRBT(Z),K=this.stub(Z),F=Array(Z),G=Array(Z),X=Array(Z),$=Array(Z),M=Array(Z),A=Array(Z),B=J.words;B.length=Z,this.convert13b(U.words,U.length,F,Z),this.convert13b(Q.words,Q.length,$,Z),this.transform(F,K,G,X,Z,Y),this.transform($,K,M,A,Z,Y);for(var w=0;w<Z;w++){var p=G[w]*M[w]-X[w]*A[w];X[w]=G[w]*A[w]+X[w]*M[w],G[w]=p}return this.conjugate(G,X,Z),this.transform(G,X,B,K,Z,Y),this.conjugate(B,K,Z),this.normalize13b(B,Z),J.negative=U.negative^Q.negative,J.length=U.length+Q.length,J.strip()},V.prototype.mul=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),this.mulTo(U,Q)},V.prototype.mulf=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),v(this,U,Q)},V.prototype.imul=function(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function(U){H(typeof U==="number"),H(U<67108864);var Q=0;for(var J=0;J<this.length;J++){var Z=(this.words[J]|0)*U,Y=(Z&67108863)+(Q&67108863);Q>>=26,Q+=Z/67108864|0,Q+=Y>>>26,this.words[J]=Y&67108863}if(Q!==0)this.words[J]=Q,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function(U){return this.clone().imuln(U)},V.prototype.sqr=function(){return this.mul(this)},V.prototype.isqr=function(){return this.imul(this.clone())},V.prototype.pow=function(U){var Q=q(U);if(Q.length===0)return new V(1);var J=this;for(var Z=0;Z<Q.length;Z++,J=J.sqr())if(Q[Z]!==0)break;if(++Z<Q.length)for(var Y=J.sqr();Z<Q.length;Z++,Y=Y.sqr()){if(Q[Z]===0)continue;J=J.mul(Y)}return J},V.prototype.iushln=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=67108863>>>26-Q<<26-Q,Y;if(Q!==0){var K=0;for(Y=0;Y<this.length;Y++){var F=this.words[Y]&Z,G=(this.words[Y]|0)-F<<Q;this.words[Y]=G|K,K=F>>>26-Q}if(K)this.words[Y]=K,this.length++}if(J!==0){for(Y=this.length-1;Y>=0;Y--)this.words[Y+J]=this.words[Y];for(Y=0;Y<J;Y++)this.words[Y]=0;this.length+=J}return this.strip()},V.prototype.ishln=function(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function(U,Q,J){H(typeof U==="number"&&U>=0);var Z;if(Q)Z=(Q-Q%26)/26;else Z=0;var Y=U%26,K=Math.min((U-Y)/26,this.length),F=67108863^67108863>>>Y<<Y,G=J;if(Z-=K,Z=Math.max(0,Z),G){for(var X=0;X<K;X++)G.words[X]=this.words[X];G.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 $=0;for(X=this.length-1;X>=0&&($!==0||X>=Z);X--){var M=this.words[X]|0;this.words[X]=$<<26-Y|M>>>Y,$=M&F}if(G&&$!==0)G.words[G.length++]=$;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function(U,Q,J){return H(this.negative===0),this.iushrn(U,Q,J)},V.prototype.shln=function(U){return this.clone().ishln(U)},V.prototype.ushln=function(U){return this.clone().iushln(U)},V.prototype.shrn=function(U){return this.clone().ishrn(U)},V.prototype.ushrn=function(U){return this.clone().iushrn(U)},V.prototype.testn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return!1;var Y=this.words[J];return!!(Y&Z)},V.prototype.imaskn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=J)return this;if(Q!==0)J++;if(this.length=Math.min(J,this.length),Q!==0){var Z=67108863^67108863>>>Q<<Q;this.words[this.length-1]&=Z}return this.strip()},V.prototype.maskn=function(U){return this.clone().imaskn(U)},V.prototype.iaddn=function(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(U){this.words[0]+=U;for(var Q=0;Q<this.length&&this.words[Q]>=67108864;Q++)if(this.words[Q]-=67108864,Q===this.length-1)this.words[Q+1]=1;else this.words[Q+1]++;return this.length=Math.max(this.length,Q+1),this},V.prototype.isubn=function(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 Q=0;Q<this.length&&this.words[Q]<0;Q++)this.words[Q]+=67108864,this.words[Q+1]-=1;return this.strip()},V.prototype.addn=function(U){return this.clone().iaddn(U)},V.prototype.subn=function(U){return this.clone().isubn(U)},V.prototype.iabs=function(){return this.negative=0,this},V.prototype.abs=function(){return this.clone().iabs()},V.prototype._ishlnsubmul=function(U,Q,J){var Z=U.length+J,Y;this._expand(Z);var K,F=0;for(Y=0;Y<U.length;Y++){K=(this.words[Y+J]|0)+F;var G=(U.words[Y]|0)*Q;K-=G&67108863,F=(K>>26)-(G/67108864|0),this.words[Y+J]=K&67108863}for(;Y<this.length-J;Y++)K=(this.words[Y+J]|0)+F,F=K>>26,this.words[Y+J]=K&67108863;if(F===0)return this.strip();H(F===-1),F=0;for(Y=0;Y<this.length;Y++)K=-(this.words[Y]|0)+F,F=K>>26,this.words[Y]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function(U,Q){var J=this.length-U.length,Z=this.clone(),Y=U,K=Y.words[Y.length-1]|0,F=this._countBits(K);if(J=26-F,J!==0)Y=Y.ushln(J),Z.iushln(J),K=Y.words[Y.length-1]|0;var G=Z.length-Y.length,X;if(Q!=="mod"){X=new V(null),X.length=G+1,X.words=Array(X.length);for(var $=0;$<X.length;$++)X.words[$]=0}var M=Z.clone()._ishlnsubmul(Y,1,G);if(M.negative===0){if(Z=M,X)X.words[G]=1}for(var A=G-1;A>=0;A--){var B=(Z.words[Y.length+A]|0)*67108864+(Z.words[Y.length+A-1]|0);B=Math.min(B/K|0,67108863),Z._ishlnsubmul(Y,B,A);while(Z.negative!==0)if(B--,Z.negative=0,Z._ishlnsubmul(Y,1,A),!Z.isZero())Z.negative^=1;if(X)X.words[A]=B}if(X)X.strip();if(Z.strip(),Q!=="div"&&J!==0)Z.iushrn(J);return{div:X||null,mod:Z}},V.prototype.divmod=function(U,Q,J){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var Z,Y,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Q),Q!=="mod")Z=K.div.neg();if(Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.iadd(U)}return{div:Z,mod:Y}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Q),Q!=="mod")Z=K.div.neg();return{div:Z,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Q),Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.isub(U)}return{div:K.div,mod:Y}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Q==="div")return{div:this.divn(U.words[0]),mod:null};if(Q==="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,Q)},V.prototype.div=function(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function(U){var Q=this.divmod(U);if(Q.mod.isZero())return Q.div;var J=Q.div.negative!==0?Q.mod.isub(U):Q.mod,Z=U.ushrn(1),Y=U.andln(1),K=J.cmp(Z);if(K<0||Y===1&&K===0)return Q.div;return Q.div.negative!==0?Q.div.isubn(1):Q.div.iaddn(1)},V.prototype.modn=function(U){H(U<=67108863);var Q=67108864%U,J=0;for(var Z=this.length-1;Z>=0;Z--)J=(Q*J+(this.words[Z]|0))%U;return J},V.prototype.idivn=function(U){H(U<=67108863);var Q=0;for(var J=this.length-1;J>=0;J--){var Z=(this.words[J]|0)+Q*67108864;this.words[J]=Z/U|0,Q=Z%U}return this.strip()},V.prototype.divn=function(U){return this.clone().idivn(U)},V.prototype.egcd=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=new V(0),F=new V(1),G=0;while(Q.isEven()&&J.isEven())Q.iushrn(1),J.iushrn(1),++G;var X=J.clone(),$=Q.clone();while(!Q.isZero()){for(var M=0,A=1;(Q.words[0]&A)===0&&M<26;++M,A<<=1);if(M>0){Q.iushrn(M);while(M-- >0){if(Z.isOdd()||Y.isOdd())Z.iadd(X),Y.isub($);Z.iushrn(1),Y.iushrn(1)}}for(var B=0,w=1;(J.words[0]&w)===0&&B<26;++B,w<<=1);if(B>0){J.iushrn(B);while(B-- >0){if(K.isOdd()||F.isOdd())K.iadd(X),F.isub($);K.iushrn(1),F.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(K),Y.isub(F);else J.isub(Q),K.isub(Z),F.isub(Y)}return{a:K,b:F,gcd:J.iushln(G)}},V.prototype._invmp=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=J.clone();while(Q.cmpn(1)>0&&J.cmpn(1)>0){for(var F=0,G=1;(Q.words[0]&G)===0&&F<26;++F,G<<=1);if(F>0){Q.iushrn(F);while(F-- >0){if(Z.isOdd())Z.iadd(K);Z.iushrn(1)}}for(var X=0,$=1;(J.words[0]&$)===0&&X<26;++X,$<<=1);if(X>0){J.iushrn(X);while(X-- >0){if(Y.isOdd())Y.iadd(K);Y.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(Y);else J.isub(Q),Y.isub(Z)}var M;if(Q.cmpn(1)===0)M=Z;else M=Y;if(M.cmpn(0)<0)M.iadd(U);return M},V.prototype.gcd=function(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Q=this.clone(),J=U.clone();Q.negative=0,J.negative=0;for(var Z=0;Q.isEven()&&J.isEven();Z++)Q.iushrn(1),J.iushrn(1);do{while(Q.isEven())Q.iushrn(1);while(J.isEven())J.iushrn(1);var Y=Q.cmp(J);if(Y<0){var K=Q;Q=J,J=K}else if(Y===0||J.cmpn(1)===0)break;Q.isub(J)}while(!0);return J.iushln(Z)},V.prototype.invm=function(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function(){return(this.words[0]&1)===0},V.prototype.isOdd=function(){return(this.words[0]&1)===1},V.prototype.andln=function(U){return this.words[0]&U},V.prototype.bincn=function(U){H(typeof U==="number");var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return this._expand(J+1),this.words[J]|=Z,this;var Y=Z;for(var K=J;Y!==0&&K<this.length;K++){var F=this.words[K]|0;F+=Y,Y=F>>>26,F&=67108863,this.words[K]=F}if(Y!==0)this.words[K]=Y,this.length++;return this},V.prototype.isZero=function(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function(U){var Q=U<0;if(this.negative!==0&&!Q)return-1;if(this.negative===0&&Q)return 1;this.strip();var J;if(this.length>1)J=1;else{if(Q)U=-U;H(U<=67108863,"Number is too big");var Z=this.words[0]|0;J=Z===U?0:Z<U?-1:1}if(this.negative!==0)return-J|0;return J},V.prototype.cmp=function(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Q=this.ucmp(U);if(this.negative!==0)return-Q|0;return Q},V.prototype.ucmp=function(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Q=0;for(var J=this.length-1;J>=0;J--){var Z=this.words[J]|0,Y=U.words[J]|0;if(Z===Y)continue;if(Z<Y)Q=-1;else if(Z>Y)Q=1;break}return Q},V.prototype.gtn=function(U){return this.cmpn(U)===1},V.prototype.gt=function(U){return this.cmp(U)===1},V.prototype.gten=function(U){return this.cmpn(U)>=0},V.prototype.gte=function(U){return this.cmp(U)>=0},V.prototype.ltn=function(U){return this.cmpn(U)===-1},V.prototype.lt=function(U){return this.cmp(U)===-1},V.prototype.lten=function(U){return this.cmpn(U)<=0},V.prototype.lte=function(U){return this.cmp(U)<=0},V.prototype.eqn=function(U){return this.cmpn(U)===0},V.prototype.eq=function(U){return this.cmp(U)===0},V.red=function(U){return new u(U)},V.prototype.toRed=function(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(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function(U){return this.red=U,this},V.prototype.forceRed=function(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function(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(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(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var N={k256:null,p224:null,p192:null,p25519:null};function f(U,Q){this.name=U,this.p=new V(Q,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(){var U=new V(null);return U.words=Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function(U){var Q=U,J;do this.split(Q,this.tmp),Q=this.imulK(Q),Q=Q.iadd(this.tmp),J=Q.bitLength();while(J>this.n);var Z=J<this.n?-1:Q.ucmp(this.p);if(Z===0)Q.words[0]=0,Q.length=1;else if(Z>0)Q.isub(this.p);else if(Q.strip!==void 0)Q.strip();else Q._strip();return Q},f.prototype.split=function(U,Q){U.iushrn(this.n,0,Q)},f.prototype.imulK=function(U){return U.imul(this.k)};function b(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}L(b,f),b.prototype.split=function(U,Q){var J=4194303,Z=Math.min(U.length,9);for(var Y=0;Y<Z;Y++)Q.words[Y]=U.words[Y];if(Q.length=Z,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Q.words[Q.length++]=K&J;for(Y=10;Y<U.length;Y++){var F=U.words[Y]|0;U.words[Y-10]=(F&J)<<4|K>>>22,K=F}if(K>>>=22,U.words[Y-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},b.prototype.imulK=function(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Q=0;for(var J=0;J<U.length;J++){var Z=U.words[J]|0;Q+=Z*977,U.words[J]=Q&67108863,Q=Z*64+(Q/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function Q0(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}L(Q0,f);function G0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}L(G0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}L(Y0,f),Y0.prototype.imulK=function(U){var Q=0;for(var J=0;J<U.length;J++){var Z=(U.words[J]|0)*19+Q,Y=Z&67108863;Z>>>=26,U.words[J]=Y,Q=Z}if(Q!==0)U.words[U.length++]=Q;return U},V._prime=function(U){if(N[U])return N[U];var Q;if(U==="k256")Q=new b;else if(U==="p224")Q=new Q0;else if(U==="p192")Q=new G0;else if(U==="p25519")Q=new Y0;else throw Error("Unknown prime "+U);return N[U]=Q,Q};function u(U){if(typeof U==="string"){var Q=V._prime(U);this.m=Q.p,this.prime=Q}else H(U.gtn(1),"modulus must be greater than 1"),this.m=U,this.prime=null}u.prototype._verify1=function(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function(U,Q){H((U.negative|Q.negative)===0,"red works only with positives"),H(U.red&&U.red===Q.red,"red works only with red numbers")},u.prototype.imod=function(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function(U,Q){this._verify2(U,Q);var J=U.add(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J._forceRed(this)},u.prototype.iadd=function(U,Q){this._verify2(U,Q);var J=U.iadd(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J},u.prototype.sub=function(U,Q){this._verify2(U,Q);var J=U.sub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J._forceRed(this)},u.prototype.isub=function(U,Q){this._verify2(U,Q);var J=U.isub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J},u.prototype.shl=function(U,Q){return this._verify1(U),this.imod(U.ushln(Q))},u.prototype.imul=function(U,Q){return this._verify2(U,Q),this.imod(U.imul(Q))},u.prototype.mul=function(U,Q){return this._verify2(U,Q),this.imod(U.mul(Q))},u.prototype.isqr=function(U){return this.imul(U,U.clone())},u.prototype.sqr=function(U){return this.mul(U,U)},u.prototype.sqrt=function(U){if(U.isZero())return U.clone();var Q=this.m.andln(3);if(H(Q%2===1),Q===3){var J=this.m.add(new V(1)).iushrn(2);return this.pow(U,J)}var Z=this.m.subn(1),Y=0;while(!Z.isZero()&&Z.andln(1)===0)Y++,Z.iushrn(1);H(!Z.isZero());var K=new V(1).toRed(this),F=K.redNeg(),G=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,G).cmp(F)!==0)X.redIAdd(F);var $=this.pow(X,Z),M=this.pow(U,Z.addn(1).iushrn(1)),A=this.pow(U,Z),B=Y;while(A.cmp(K)!==0){var w=A;for(var p=0;w.cmp(K)!==0;p++)w=w.redSqr();H(p<B);var n=this.pow($,new V(1).iushln(B-p-1));M=M.redMul(n),$=n.redSqr(),A=A.redMul($),B=p}return M},u.prototype.invm=function(U){var Q=U._invmp(this.m);if(Q.negative!==0)return Q.negative=0,this.imod(Q).redNeg();else return this.imod(Q)},u.prototype.pow=function(U,Q){if(Q.isZero())return new V(1).toRed(this);if(Q.cmpn(1)===0)return U.clone();var J=4,Z=Array(1<<J);Z[0]=new V(1).toRed(this),Z[1]=U;for(var Y=2;Y<Z.length;Y++)Z[Y]=this.mul(Z[Y-1],U);var K=Z[0],F=0,G=0,X=Q.bitLength()%26;if(X===0)X=26;for(Y=Q.length-1;Y>=0;Y--){var $=Q.words[Y];for(var M=X-1;M>=0;M--){var A=$>>M&1;if(K!==Z[0])K=this.sqr(K);if(A===0&&F===0){G=0;continue}if(F<<=1,F|=A,G++,G!==J&&(Y!==0||M!==0))continue;K=this.mul(K,Z[F]),G=0,F=0}X=26}return K},u.prototype.convertTo=function(U){var Q=U.umod(this.m);return Q===U?Q.clone():Q},u.prototype.convertFrom=function(U){var Q=U.clone();return Q.red=null,Q},V.mont=function(U){return new U0(U)};function U0(U){if(u.call(this,U),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)}L(U0,u),U0.prototype.convertTo=function(U){return this.imod(U.ushln(this.shift))},U0.prototype.convertFrom=function(U){var Q=this.imod(U.mul(this.rinv));return Q.red=null,Q},U0.prototype.imul=function(U,Q){if(U.isZero()||Q.isZero())return U.words[0]=0,U.length=1,U;var J=U.imul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.mul=function(U,Q){if(U.isZero()||Q.isZero())return new V(0)._forceRed(this);var J=U.mul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.invm=function(U){var Q=this.imod(U._invmp(this.m).mul(this.r2));return Q._forceRed(this)}})(typeof O>"u"||O,I)}),cU=I0((I,O)=>{O.exports=W;function W(T,H){if(!T)throw Error(H||"Assertion failed")}W.equal=function(T,H,L){if(T!=H)throw Error(L||"Assertion failed: "+T+" != "+H)}}),xQ=I0((I)=>{var O=I;function W(L,V){if(Array.isArray(L))return L.slice();if(!L)return[];var P=[];if(typeof L!=="string"){for(var S=0;S<L.length;S++)P[S]=L[S]|0;return P}if(V==="hex"){if(L=L.replace(/[^a-z0-9]+/ig,""),L.length%2!==0)L="0"+L;for(var S=0;S<L.length;S+=2)P.push(parseInt(L[S]+L[S+1],16))}else for(var S=0;S<L.length;S++){var E=L.charCodeAt(S),C=E>>8,D=E&255;if(C)P.push(C,D);else P.push(D)}return P}O.toArray=W;function T(L){if(L.length===1)return"0"+L;else return L}O.zero2=T;function H(L){var V="";for(var P=0;P<L.length;P++)V+=T(L[P].toString(16));return V}O.toHex=H,O.encode=function(L,V){if(V==="hex")return H(L);else return L}}),kU=I0((I)=>{var O=I,W=gU(),T=cU(),H=xQ();O.assert=T,O.toArray=H.toArray,O.zero2=H.zero2,O.toHex=H.toHex,O.encode=H.encode;function L(C,D,z){var R=Array(Math.max(C.bitLength(),z)+1),q;for(q=0;q<R.length;q+=1)R[q]=0;var _=1<<D+1,k=C.clone();for(q=0;q<R.length;q++){var j,v=k.andln(_-1);if(k.isOdd()){if(v>(_>>1)-1)j=(_>>1)-v;else j=v;k.isubn(j)}else j=0;R[q]=j,k.iushrn(1)}return R}O.getNAF=L;function V(C,D){var z=[[],[]];C=C.clone(),D=D.clone();var R=0,q=0,_;while(C.cmpn(-R)>0||D.cmpn(-q)>0){var k=C.andln(3)+R&3,j=D.andln(3)+q&3;if(k===3)k=-1;if(j===3)j=-1;var v;if((k&1)===0)v=0;else if(_=C.andln(7)+R&7,(_===3||_===5)&&j===2)v=-k;else v=k;z[0].push(v);var x;if((j&1)===0)x=0;else if(_=D.andln(7)+q&7,(_===3||_===5)&&k===2)x=-j;else x=j;if(z[1].push(x),2*R===v+1)R=1-R;if(2*q===x+1)q=1-q;C.iushrn(1),D.iushrn(1)}return z}O.getJSF=V;function P(C,D,z){var R="_"+D;C.prototype[D]=function(){return this[R]!==void 0?this[R]:this[R]=z.call(this)}}O.cachedProperty=P;function S(C){return typeof C==="string"?O.toArray(C,"hex"):C}O.parseBytes=S;function E(C){return new W(C,"hex","le")}O.intFromLE=E}),NQ=I0((I,O)=>{var W;O.exports=function(L){if(!W)W=new T(null);return W.generate(L)};function T(L){this.rand=L}if(O.exports.Rand=T,T.prototype.generate=function(L){return this._rand(L)},T.prototype._rand=function(L){if(this.rand.getBytes)return this.rand.getBytes(L);var V=new Uint8Array(L);for(var P=0;P<V.length;P++)V[P]=this.rand.getByte();return V},typeof self==="object"){if(self.crypto&&self.crypto.getRandomValues)T.prototype._rand=function(L){var V=new Uint8Array(L);return self.crypto.getRandomValues(V),V};else if(self.msCrypto&&self.msCrypto.getRandomValues)T.prototype._rand=function(L){var V=new Uint8Array(L);return self.msCrypto.getRandomValues(V),V};else if(typeof window==="object")T.prototype._rand=function(){throw Error("Not implemented yet")}}else try{if(H=(qU(),h0(RU)),typeof H.randomBytes!=="function")throw Error("Not supported");T.prototype._rand=function(L){return H.randomBytes(L)}}catch(L){}var H}),kX=I0((I,O)=>{var W=gU(),T=kU(),H=T.getNAF,L=T.getJSF,V=T.assert;function P(E,C){this.type=E,this.p=new W(C.p,16),this.red=C.prime?W.red(C.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=C.n&&new W(C.n,16),this.g=C.g&&this.pointFromJSON(C.g,C.gRed),this._wnafT1=[,,,,],this._wnafT2=[,,,,],this._wnafT3=[,,,,],this._wnafT4=[,,,,],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)}O.exports=P,P.prototype.point=function(){throw Error("Not implemented")},P.prototype.validate=function(){throw Error("Not implemented")},P.prototype._fixedNafMul=function(E,C){V(E.precomputed);var D=E._getDoubles(),z=H(C,1,this._bitLength),R=(1<<D.step+1)-(D.step%2===0?2:1);R/=3;var q=[],_,k;for(_=0;_<z.length;_+=D.step){k=0;for(var j=_+D.step-1;j>=_;j--)k=(k<<1)+z[j];q.push(k)}var v=this.jpoint(null,null,null),x=this.jpoint(null,null,null);for(var N=R;N>0;N--){for(_=0;_<q.length;_++)if(k=q[_],k===N)x=x.mixedAdd(D.points[_]);else if(k===-N)x=x.mixedAdd(D.points[_].neg());v=v.add(x)}return v.toP()},P.prototype._wnafMul=function(E,C){var D=4,z=E._getNAFPoints(D);D=z.wnd;var R=z.points,q=H(C,D,this._bitLength),_=this.jpoint(null,null,null);for(var k=q.length-1;k>=0;k--){for(var j=0;k>=0&&q[k]===0;k--)j++;if(k>=0)j++;if(_=_.dblp(j),k<0)break;var v=q[k];if(V(v!==0),E.type==="affine")if(v>0)_=_.mixedAdd(R[v-1>>1]);else _=_.mixedAdd(R[-v-1>>1].neg());else if(v>0)_=_.add(R[v-1>>1]);else _=_.add(R[-v-1>>1].neg())}return E.type==="affine"?_.toP():_},P.prototype._wnafMulAdd=function(E,C,D,z,R){var q=this._wnafT1,_=this._wnafT2,k=this._wnafT3,j=0,v,x,N;for(v=0;v<z;v++){N=C[v];var f=N._getNAFPoints(E);q[v]=f.wnd,_[v]=f.points}for(v=z-1;v>=1;v-=2){var b=v-1,Q0=v;if(q[b]!==1||q[Q0]!==1){k[b]=H(D[b],q[b],this._bitLength),k[Q0]=H(D[Q0],q[Q0],this._bitLength),j=Math.max(k[b].length,j),j=Math.max(k[Q0].length,j);continue}var G0=[C[b],null,null,C[Q0]];if(C[b].y.cmp(C[Q0].y)===0)G0[1]=C[b].add(C[Q0]),G0[2]=C[b].toJ().mixedAdd(C[Q0].neg());else if(C[b].y.cmp(C[Q0].y.redNeg())===0)G0[1]=C[b].toJ().mixedAdd(C[Q0]),G0[2]=C[b].add(C[Q0].neg());else G0[1]=C[b].toJ().mixedAdd(C[Q0]),G0[2]=C[b].toJ().mixedAdd(C[Q0].neg());var Y0=[-3,-1,-5,-7,0,7,5,1,3],u=L(D[b],D[Q0]);j=Math.max(u[0].length,j),k[b]=Array(j),k[Q0]=Array(j);for(x=0;x<j;x++){var U0=u[0][x]|0,U=u[1][x]|0;k[b][x]=Y0[(U0+1)*3+(U+1)],k[Q0][x]=0,_[b]=G0}}var Q=this.jpoint(null,null,null),J=this._wnafT4;for(v=j;v>=0;v--){var Z=0;while(v>=0){var Y=!0;for(x=0;x<z;x++)if(J[x]=k[x][v]|0,J[x]!==0)Y=!1;if(!Y)break;Z++,v--}if(v>=0)Z++;if(Q=Q.dblp(Z),v<0)break;for(x=0;x<z;x++){var K=J[x];if(K===0)continue;else if(K>0)N=_[x][K-1>>1];else if(K<0)N=_[x][-K-1>>1].neg();if(N.type==="affine")Q=Q.mixedAdd(N);else Q=Q.add(N)}}for(v=0;v<z;v++)_[v]=null;if(R)return Q;else return Q.toP()};function S(E,C){this.curve=E,this.type=C,this.precomputed=null}P.BasePoint=S,S.prototype.eq=function(){throw Error("Not implemented")},S.prototype.validate=function(){return this.curve.validate(this)},P.prototype.decodePoint=function(E,C){E=T.toArray(E,C);var D=this.p.byteLength();if((E[0]===4||E[0]===6||E[0]===7)&&E.length-1===2*D){if(E[0]===6)V(E[E.length-1]%2===0);else if(E[0]===7)V(E[E.length-1]%2===1);var z=this.point(E.slice(1,1+D),E.slice(1+D,1+2*D));return z}else if((E[0]===2||E[0]===3)&&E.length-1===D)return this.pointFromX(E.slice(1,1+D),E[0]===3);throw Error("Unknown point format")},S.prototype.encodeCompressed=function(E){return this.encode(E,!0)},S.prototype._encode=function(E){var C=this.curve.p.byteLength(),D=this.getX().toArray("be",C);if(E)return[this.getY().isEven()?2:3].concat(D);return[4].concat(D,this.getY().toArray("be",C))},S.prototype.encode=function(E,C){return T.encode(this._encode(C),E)},S.prototype.precompute=function(E){if(this.precomputed)return this;var C={doubles:null,naf:null,beta:null};return C.naf=this._getNAFPoints(8),C.doubles=this._getDoubles(4,E),C.beta=this._getBeta(),this.precomputed=C,this},S.prototype._hasDoubles=function(E){if(!this.precomputed)return!1;var C=this.precomputed.doubles;if(!C)return!1;return C.points.length>=Math.ceil((E.bitLength()+1)/C.step)},S.prototype._getDoubles=function(E,C){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;var D=[this],z=this;for(var R=0;R<C;R+=E){for(var q=0;q<E;q++)z=z.dbl();D.push(z)}return{step:E,points:D}},S.prototype._getNAFPoints=function(E){if(this.precomputed&&this.precomputed.naf)return this.precomputed.naf;var C=[this],D=(1<<E)-1,z=D===1?null:this.dbl();for(var R=1;R<D;R++)C[R]=C[R-1].add(z);return{wnd:E,points:C}},S.prototype._getBeta=function(){return null},S.prototype.dblp=function(E){var C=this;for(var D=0;D<E;D++)C=C.dbl();return C}}),GV=I0((I,O)=>{if(typeof Object.create==="function")O.exports=function(W,T){if(T)W.super_=T,W.prototype=Object.create(T.prototype,{constructor:{value:W,enumerable:!1,writable:!0,configurable:!0}})};else O.exports=function(W,T){if(T){W.super_=T;var H=function(){};H.prototype=T.prototype,W.prototype=new H,W.prototype.constructor=W}}}),SU=I0((I,O)=>{try{if(W=(mZ(),h0(nZ)),typeof W.inherits!=="function")throw"";O.exports=W.inherits}catch(T){O.exports=GV()}var W}),IV=I0((I,O)=>{var W=kU(),T=gU(),H=SU(),L=kX(),V=W.assert;function P(C){L.call(this,"short",C),this.a=new T(C.a,16).toRed(this.red),this.b=new T(C.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(C),this._endoWnafT1=[,,,,],this._endoWnafT2=[,,,,]}H(P,L),O.exports=P,P.prototype._getEndomorphism=function(C){if(!this.zeroA||!this.g||!this.n||this.p.modn(3)!==1)return;var D,z;if(C.beta)D=new T(C.beta,16).toRed(this.red);else{var R=this._getEndoRoots(this.p);D=R[0].cmp(R[1])<0?R[0]:R[1],D=D.toRed(this.red)}if(C.lambda)z=new T(C.lambda,16);else{var q=this._getEndoRoots(this.n);if(this.g.mul(q[0]).x.cmp(this.g.x.redMul(D))===0)z=q[0];else z=q[1],V(this.g.mul(z).x.cmp(this.g.x.redMul(D))===0)}var _;if(C.basis)_=C.basis.map(function(k){return{a:new T(k.a,16),b:new T(k.b,16)}});else _=this._getEndoBasis(z);return{beta:D,lambda:z,basis:_}},P.prototype._getEndoRoots=function(C){var D=C===this.p?this.red:T.mont(C),z=new T(2).toRed(D).redInvm(),R=z.redNeg(),q=new T(3).toRed(D).redNeg().redSqrt().redMul(z),_=R.redAdd(q).fromRed(),k=R.redSub(q).fromRed();return[_,k]},P.prototype._getEndoBasis=function(C){var D=this.n.ushrn(Math.floor(this.n.bitLength()/2)),z=C,R=this.n.clone(),q=new T(1),_=new T(0),k=new T(0),j=new T(1),v,x,N,f,b,Q0,G0,Y0=0,u,U0;while(z.cmpn(0)!==0){var U=R.div(z);u=R.sub(U.mul(z)),U0=k.sub(U.mul(q));var Q=j.sub(U.mul(_));if(!N&&u.cmp(D)<0)v=G0.neg(),x=q,N=u.neg(),f=U0;else if(N&&++Y0===2)break;G0=u,R=z,z=u,k=q,q=U0,j=_,_=Q}b=u.neg(),Q0=U0;var J=N.sqr().add(f.sqr()),Z=b.sqr().add(Q0.sqr());if(Z.cmp(J)>=0)b=v,Q0=x;if(N.negative)N=N.neg(),f=f.neg();if(b.negative)b=b.neg(),Q0=Q0.neg();return[{a:N,b:f},{a:b,b:Q0}]},P.prototype._endoSplit=function(C){var D=this.endo.basis,z=D[0],R=D[1],q=R.b.mul(C).divRound(this.n),_=z.b.neg().mul(C).divRound(this.n),k=q.mul(z.a),j=_.mul(R.a),v=q.mul(z.b),x=_.mul(R.b),N=C.sub(k).sub(j),f=v.add(x).neg();return{k1:N,k2:f}},P.prototype.pointFromX=function(C,D){if(C=new T(C,16),!C.red)C=C.toRed(this.red);var z=C.redSqr().redMul(C).redIAdd(C.redMul(this.a)).redIAdd(this.b),R=z.redSqrt();if(R.redSqr().redSub(z).cmp(this.zero)!==0)throw Error("invalid point");var q=R.fromRed().isOdd();if(D&&!q||!D&&q)R=R.redNeg();return this.point(C,R)},P.prototype.validate=function(C){if(C.inf)return!0;var{x:D,y:z}=C,R=this.a.redMul(D),q=D.redSqr().redMul(D).redIAdd(R).redIAdd(this.b);return z.redSqr().redISub(q).cmpn(0)===0},P.prototype._endoWnafMulAdd=function(C,D,z){var R=this._endoWnafT1,q=this._endoWnafT2;for(var _=0;_<C.length;_++){var k=this._endoSplit(D[_]),j=C[_],v=j._getBeta();if(k.k1.negative)k.k1.ineg(),j=j.neg(!0);if(k.k2.negative)k.k2.ineg(),v=v.neg(!0);R[_*2]=j,R[_*2+1]=v,q[_*2]=k.k1,q[_*2+1]=k.k2}var x=this._wnafMulAdd(1,R,q,_*2,z);for(var N=0;N<_*2;N++)R[N]=null,q[N]=null;return x};function S(C,D,z,R){if(L.BasePoint.call(this,C,"affine"),D===null&&z===null)this.x=null,this.y=null,this.inf=!0;else{if(this.x=new T(D,16),this.y=new T(z,16),R)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(S,L.BasePoint),P.prototype.point=function(C,D,z){return new S(this,C,D,z)},P.prototype.pointFromJSON=function(C,D){return S.fromJSON(this,C,D)},S.prototype._getBeta=function(){if(!this.curve.endo)return;var C=this.precomputed;if(C&&C.beta)return C.beta;var D=this.curve.point(this.x.redMul(this.curve.endo.beta),this.y);if(C){var z=this.curve,R=function(q){return z.point(q.x.redMul(z.endo.beta),q.y)};C.beta=D,D.precomputed={beta:null,naf:C.naf&&{wnd:C.naf.wnd,points:C.naf.points.map(R)},doubles:C.doubles&&{step:C.doubles.step,points:C.doubles.points.map(R)}}}return D},S.prototype.toJSON=function(){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)}}]},S.fromJSON=function(C,D,z){if(typeof D==="string")D=JSON.parse(D);var R=C.point(D[0],D[1],z);if(!D[2])return R;function q(k){return C.point(k[0],k[1],z)}var _=D[2];return R.precomputed={beta:null,doubles:_.doubles&&{step:_.doubles.step,points:[R].concat(_.doubles.points.map(q))},naf:_.naf&&{wnd:_.naf.wnd,points:[R].concat(_.naf.points.map(q))}},R},S.prototype.inspect=function(){if(this.isInfinity())return"<EC Point Infinity>";return"<EC Point x: "+this.x.fromRed().toString(16,2)+" y: "+this.y.fromRed().toString(16,2)+">"},S.prototype.isInfinity=function(){return this.inf},S.prototype.add=function(C){if(this.inf)return C;if(C.inf)return this;if(this.eq(C))return this.dbl();if(this.neg().eq(C))return this.curve.point(null,null);if(this.x.cmp(C.x)===0)return this.curve.point(null,null);var D=this.y.redSub(C.y);if(D.cmpn(0)!==0)D=D.redMul(this.x.redSub(C.x).redInvm());var z=D.redSqr().redISub(this.x).redISub(C.x),R=D.redMul(this.x.redSub(z)).redISub(this.y);return this.curve.point(z,R)},S.prototype.dbl=function(){if(this.inf)return this;var C=this.y.redAdd(this.y);if(C.cmpn(0)===0)return this.curve.point(null,null);var D=this.curve.a,z=this.x.redSqr(),R=C.redInvm(),q=z.redAdd(z).redIAdd(z).redIAdd(D).redMul(R),_=q.redSqr().redISub(this.x.redAdd(this.x)),k=q.redMul(this.x.redSub(_)).redISub(this.y);return this.curve.point(_,k)},S.prototype.getX=function(){return this.x.fromRed()},S.prototype.getY=function(){return this.y.fromRed()},S.prototype.mul=function(C){if(C=new T(C,16),this.isInfinity())return this;else if(this._hasDoubles(C))return this.curve._fixedNafMul(this,C);else if(this.curve.endo)return this.curve._endoWnafMulAdd([this],[C]);else return this.curve._wnafMul(this,C)},S.prototype.mulAdd=function(C,D,z){var R=[this,D],q=[C,z];if(this.curve.endo)return this.curve._endoWnafMulAdd(R,q);else return this.curve._wnafMulAdd(1,R,q,2)},S.prototype.jmulAdd=function(C,D,z){var R=[this,D],q=[C,z];if(this.curve.endo)return this.curve._endoWnafMulAdd(R,q,!0);else return this.curve._wnafMulAdd(1,R,q,2,!0)},S.prototype.eq=function(C){return this===C||this.inf===C.inf&&(this.inf||this.x.cmp(C.x)===0&&this.y.cmp(C.y)===0)},S.prototype.neg=function(C){if(this.inf)return this;var D=this.curve.point(this.x,this.y.redNeg());if(C&&this.precomputed){var z=this.precomputed,R=function(q){return q.neg()};D.precomputed={naf:z.naf&&{wnd:z.naf.wnd,points:z.naf.points.map(R)},doubles:z.doubles&&{step:z.doubles.step,points:z.doubles.points.map(R)}}}return D},S.prototype.toJ=function(){if(this.inf)return this.curve.jpoint(null,null,null);var C=this.curve.jpoint(this.x,this.y,this.curve.one);return C};function E(C,D,z,R){if(L.BasePoint.call(this,C,"jacobian"),D===null&&z===null&&R===null)this.x=this.curve.one,this.y=this.curve.one,this.z=new T(0);else this.x=new T(D,16),this.y=new T(z,16),this.z=new T(R,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(E,L.BasePoint),P.prototype.jpoint=function(C,D,z){return new E(this,C,D,z)},E.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var C=this.z.redInvm(),D=C.redSqr(),z=this.x.redMul(D),R=this.y.redMul(D).redMul(C);return this.curve.point(z,R)},E.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},E.prototype.add=function(C){if(this.isInfinity())return C;if(C.isInfinity())return this;var D=C.z.redSqr(),z=this.z.redSqr(),R=this.x.redMul(D),q=C.x.redMul(z),_=this.y.redMul(D.redMul(C.z)),k=C.y.redMul(z.redMul(this.z)),j=R.redSub(q),v=_.redSub(k);if(j.cmpn(0)===0)if(v.cmpn(0)!==0)return this.curve.jpoint(null,null,null);else return this.dbl();var x=j.redSqr(),N=x.redMul(j),f=R.redMul(x),b=v.redSqr().redIAdd(N).redISub(f).redISub(f),Q0=v.redMul(f.redISub(b)).redISub(_.redMul(N)),G0=this.z.redMul(C.z).redMul(j);return this.curve.jpoint(b,Q0,G0)},E.prototype.mixedAdd=function(C){if(this.isInfinity())return C.toJ();if(C.isInfinity())return this;var D=this.z.redSqr(),z=this.x,R=C.x.redMul(D),q=this.y,_=C.y.redMul(D).redMul(this.z),k=z.redSub(R),j=q.redSub(_);if(k.cmpn(0)===0)if(j.cmpn(0)!==0)return this.curve.jpoint(null,null,null);else return this.dbl();var v=k.redSqr(),x=v.redMul(k),N=z.redMul(v),f=j.redSqr().redIAdd(x).redISub(N).redISub(N),b=j.redMul(N.redISub(f)).redISub(q.redMul(x)),Q0=this.z.redMul(k);return this.curve.jpoint(f,b,Q0)},E.prototype.dblp=function(C){if(C===0)return this;if(this.isInfinity())return this;if(!C)return this.dbl();var D;if(this.curve.zeroA||this.curve.threeA){var z=this;for(D=0;D<C;D++)z=z.dbl();return z}var R=this.curve.a,q=this.curve.tinv,_=this.x,k=this.y,j=this.z,v=j.redSqr().redSqr(),x=k.redAdd(k);for(D=0;D<C;D++){var N=_.redSqr(),f=x.redSqr(),b=f.redSqr(),Q0=N.redAdd(N).redIAdd(N).redIAdd(R.redMul(v)),G0=_.redMul(f),Y0=Q0.redSqr().redISub(G0.redAdd(G0)),u=G0.redISub(Y0),U0=Q0.redMul(u);U0=U0.redIAdd(U0).redISub(b);var U=x.redMul(j);if(D+1<C)v=v.redMul(b);_=Y0,j=U,x=U0}return this.curve.jpoint(_,x.redMul(q),j)},E.prototype.dbl=function(){if(this.isInfinity())return this;if(this.curve.zeroA)return this._zeroDbl();else if(this.curve.threeA)return this._threeDbl();else return this._dbl()},E.prototype._zeroDbl=function(){var C,D,z;if(this.zOne){var R=this.x.redSqr(),q=this.y.redSqr(),_=q.redSqr(),k=this.x.redAdd(q).redSqr().redISub(R).redISub(_);k=k.redIAdd(k);var j=R.redAdd(R).redIAdd(R),v=j.redSqr().redISub(k).redISub(k),x=_.redIAdd(_);x=x.redIAdd(x),x=x.redIAdd(x),C=v,D=j.redMul(k.redISub(v)).redISub(x),z=this.y.redAdd(this.y)}else{var N=this.x.redSqr(),f=this.y.redSqr(),b=f.redSqr(),Q0=this.x.redAdd(f).redSqr().redISub(N).redISub(b);Q0=Q0.redIAdd(Q0);var G0=N.redAdd(N).redIAdd(N),Y0=G0.redSqr(),u=b.redIAdd(b);u=u.redIAdd(u),u=u.redIAdd(u),C=Y0.redISub(Q0).redISub(Q0),D=G0.redMul(Q0.redISub(C)).redISub(u),z=this.y.redMul(this.z),z=z.redIAdd(z)}return this.curve.jpoint(C,D,z)},E.prototype._threeDbl=function(){var C,D,z;if(this.zOne){var R=this.x.redSqr(),q=this.y.redSqr(),_=q.redSqr(),k=this.x.redAdd(q).redSqr().redISub(R).redISub(_);k=k.redIAdd(k);var j=R.redAdd(R).redIAdd(R).redIAdd(this.curve.a),v=j.redSqr().redISub(k).redISub(k);C=v;var x=_.redIAdd(_);x=x.redIAdd(x),x=x.redIAdd(x),D=j.redMul(k.redISub(v)).redISub(x),z=this.y.redAdd(this.y)}else{var N=this.z.redSqr(),f=this.y.redSqr(),b=this.x.redMul(f),Q0=this.x.redSub(N).redMul(this.x.redAdd(N));Q0=Q0.redAdd(Q0).redIAdd(Q0);var G0=b.redIAdd(b);G0=G0.redIAdd(G0);var Y0=G0.redAdd(G0);C=Q0.redSqr().redISub(Y0),z=this.y.redAdd(this.z).redSqr().redISub(f).redISub(N);var u=f.redSqr();u=u.redIAdd(u),u=u.redIAdd(u),u=u.redIAdd(u),D=Q0.redMul(G0.redISub(C)).redISub(u)}return this.curve.jpoint(C,D,z)},E.prototype._dbl=function(){var C=this.curve.a,D=this.x,z=this.y,R=this.z,q=R.redSqr().redSqr(),_=D.redSqr(),k=z.redSqr(),j=_.redAdd(_).redIAdd(_).redIAdd(C.redMul(q)),v=D.redAdd(D);v=v.redIAdd(v);var x=v.redMul(k),N=j.redSqr().redISub(x.redAdd(x)),f=x.redISub(N),b=k.redSqr();b=b.redIAdd(b),b=b.redIAdd(b),b=b.redIAdd(b);var Q0=j.redMul(f).redISub(b),G0=z.redAdd(z).redMul(R);return this.curve.jpoint(N,Q0,G0)},E.prototype.trpl=function(){if(!this.curve.zeroA)return this.dbl().add(this);var C=this.x.redSqr(),D=this.y.redSqr(),z=this.z.redSqr(),R=D.redSqr(),q=C.redAdd(C).redIAdd(C),_=q.redSqr(),k=this.x.redAdd(D).redSqr().redISub(C).redISub(R);k=k.redIAdd(k),k=k.redAdd(k).redIAdd(k),k=k.redISub(_);var j=k.redSqr(),v=R.redIAdd(R);v=v.redIAdd(v),v=v.redIAdd(v),v=v.redIAdd(v);var x=q.redIAdd(k).redSqr().redISub(_).redISub(j).redISub(v),N=D.redMul(x);N=N.redIAdd(N),N=N.redIAdd(N);var f=this.x.redMul(j).redISub(N);f=f.redIAdd(f),f=f.redIAdd(f);var b=this.y.redMul(x.redMul(v.redISub(x)).redISub(k.redMul(j)));b=b.redIAdd(b),b=b.redIAdd(b),b=b.redIAdd(b);var Q0=this.z.redAdd(k).redSqr().redISub(z).redISub(j);return this.curve.jpoint(f,b,Q0)},E.prototype.mul=function(C,D){return C=new T(C,D),this.curve._wnafMul(this,C)},E.prototype.eq=function(C){if(C.type==="affine")return this.eq(C.toJ());if(this===C)return!0;var D=this.z.redSqr(),z=C.z.redSqr();if(this.x.redMul(z).redISub(C.x.redMul(D)).cmpn(0)!==0)return!1;var R=D.redMul(this.z),q=z.redMul(C.z);return this.y.redMul(q).redISub(C.y.redMul(R)).cmpn(0)===0},E.prototype.eqXToP=function(C){var D=this.z.redSqr(),z=C.toRed(this.curve.red).redMul(D);if(this.x.cmp(z)===0)return!0;var R=C.clone(),q=this.curve.redN.redMul(D);for(;;){if(R.iadd(this.curve.n),R.cmp(this.curve.p)>=0)return!1;if(z.redIAdd(q),this.x.cmp(z)===0)return!0}},E.prototype.inspect=function(){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)+">"},E.prototype.isInfinity=function(){return this.z.cmpn(0)===0}}),$V=I0((I,O)=>{var W=gU(),T=SU(),H=kX(),L=kU();function V(S){H.call(this,"mont",S),this.a=new W(S.a,16).toRed(this.red),this.b=new W(S.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))}T(V,H),O.exports=V,V.prototype.validate=function(S){var E=S.normalize().x,C=E.redSqr(),D=C.redMul(E).redAdd(C.redMul(this.a)).redAdd(E),z=D.redSqrt();return z.redSqr().cmp(D)===0};function P(S,E,C){if(H.BasePoint.call(this,S,"projective"),E===null&&C===null)this.x=this.curve.one,this.z=this.curve.zero;else{if(this.x=new W(E,16),this.z=new W(C,16),!this.x.red)this.x=this.x.toRed(this.curve.red);if(!this.z.red)this.z=this.z.toRed(this.curve.red)}}T(P,H.BasePoint),V.prototype.decodePoint=function(S,E){return this.point(L.toArray(S,E),1)},V.prototype.point=function(S,E){return new P(this,S,E)},V.prototype.pointFromJSON=function(S){return P.fromJSON(this,S)},P.prototype.precompute=function(){},P.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},P.fromJSON=function(S,E){return new P(S,E[0],E[1]||S.one)},P.prototype.inspect=function(){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(){return this.z.cmpn(0)===0},P.prototype.dbl=function(){var S=this.x.redAdd(this.z),E=S.redSqr(),C=this.x.redSub(this.z),D=C.redSqr(),z=E.redSub(D),R=E.redMul(D),q=z.redMul(D.redAdd(this.curve.a24.redMul(z)));return this.curve.point(R,q)},P.prototype.add=function(){throw Error("Not supported on Montgomery curve")},P.prototype.diffAdd=function(S,E){var C=this.x.redAdd(this.z),D=this.x.redSub(this.z),z=S.x.redAdd(S.z),R=S.x.redSub(S.z),q=R.redMul(C),_=z.redMul(D),k=E.z.redMul(q.redAdd(_).redSqr()),j=E.x.redMul(q.redISub(_).redSqr());return this.curve.point(k,j)},P.prototype.mul=function(S){var E=S.clone(),C=this,D=this.curve.point(null,null),z=this;for(var R=[];E.cmpn(0)!==0;E.iushrn(1))R.push(E.andln(1));for(var q=R.length-1;q>=0;q--)if(R[q]===0)C=C.diffAdd(D,z),D=D.dbl();else D=C.diffAdd(D,z),C=C.dbl();return D},P.prototype.mulAdd=function(){throw Error("Not supported on Montgomery curve")},P.prototype.jumlAdd=function(){throw Error("Not supported on Montgomery curve")},P.prototype.eq=function(S){return this.getX().cmp(S.getX())===0},P.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},P.prototype.getX=function(){return this.normalize(),this.x.fromRed()}}),KV=I0((I,O)=>{var W=kU(),T=gU(),H=SU(),L=kX(),V=W.assert;function P(E){this.twisted=(E.a|0)!==1,this.mOneA=this.twisted&&(E.a|0)===-1,this.extended=this.mOneA,L.call(this,"edwards",E),this.a=new T(E.a,16).umod(this.red.m),this.a=this.a.toRed(this.red),this.c=new T(E.c,16).toRed(this.red),this.c2=this.c.redSqr(),this.d=new T(E.d,16).toRed(this.red),this.dd=this.d.redAdd(this.d),V(!this.twisted||this.c.fromRed().cmpn(1)===0),this.oneC=(E.c|0)===1}H(P,L),O.exports=P,P.prototype._mulA=function(E){if(this.mOneA)return E.redNeg();else return this.a.redMul(E)},P.prototype._mulC=function(E){if(this.oneC)return E;else return this.c.redMul(E)},P.prototype.jpoint=function(E,C,D,z){return this.point(E,C,D,z)},P.prototype.pointFromX=function(E,C){if(E=new T(E,16),!E.red)E=E.toRed(this.red);var D=E.redSqr(),z=this.c2.redSub(this.a.redMul(D)),R=this.one.redSub(this.c2.redMul(this.d).redMul(D)),q=z.redMul(R.redInvm()),_=q.redSqrt();if(_.redSqr().redSub(q).cmp(this.zero)!==0)throw Error("invalid point");var k=_.fromRed().isOdd();if(C&&!k||!C&&k)_=_.redNeg();return this.point(E,_)},P.prototype.pointFromY=function(E,C){if(E=new T(E,16),!E.red)E=E.toRed(this.red);var D=E.redSqr(),z=D.redSub(this.c2),R=D.redMul(this.d).redMul(this.c2).redSub(this.a),q=z.redMul(R.redInvm());if(q.cmp(this.zero)===0)if(C)throw Error("invalid point");else return this.point(this.zero,E);var _=q.redSqrt();if(_.redSqr().redSub(q).cmp(this.zero)!==0)throw Error("invalid point");if(_.fromRed().isOdd()!==C)_=_.redNeg();return this.point(_,E)},P.prototype.validate=function(E){if(E.isInfinity())return!0;E.normalize();var C=E.x.redSqr(),D=E.y.redSqr(),z=C.redMul(this.a).redAdd(D),R=this.c2.redMul(this.one.redAdd(this.d.redMul(C).redMul(D)));return z.cmp(R)===0};function S(E,C,D,z,R){if(L.BasePoint.call(this,E,"projective"),C===null&&D===null&&z===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 T(C,16),this.y=new T(D,16),this.z=z?new T(z,16):this.curve.one,this.t=R&&new T(R,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(S,L.BasePoint),P.prototype.pointFromJSON=function(E){return S.fromJSON(this,E)},P.prototype.point=function(E,C,D,z){return new S(this,E,C,D,z)},S.fromJSON=function(E,C){return new S(E,C[0],C[1],C[2])},S.prototype.inspect=function(){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)+">"},S.prototype.isInfinity=function(){return this.x.cmpn(0)===0&&(this.y.cmp(this.z)===0||this.zOne&&this.y.cmp(this.curve.c)===0)},S.prototype._extDbl=function(){var E=this.x.redSqr(),C=this.y.redSqr(),D=this.z.redSqr();D=D.redIAdd(D);var z=this.curve._mulA(E),R=this.x.redAdd(this.y).redSqr().redISub(E).redISub(C),q=z.redAdd(C),_=q.redSub(D),k=z.redSub(C),j=R.redMul(_),v=q.redMul(k),x=R.redMul(k),N=_.redMul(q);return this.curve.point(j,v,N,x)},S.prototype._projDbl=function(){var E=this.x.redAdd(this.y).redSqr(),C=this.x.redSqr(),D=this.y.redSqr(),z,R,q,_,k,j;if(this.curve.twisted){_=this.curve._mulA(C);var v=_.redAdd(D);if(this.zOne)z=E.redSub(C).redSub(D).redMul(v.redSub(this.curve.two)),R=v.redMul(_.redSub(D)),q=v.redSqr().redSub(v).redSub(v);else k=this.z.redSqr(),j=v.redSub(k).redISub(k),z=E.redSub(C).redISub(D).redMul(j),R=v.redMul(_.redSub(D)),q=v.redMul(j)}else _=C.redAdd(D),k=this.curve._mulC(this.z).redSqr(),j=_.redSub(k).redSub(k),z=this.curve._mulC(E.redISub(_)).redMul(j),R=this.curve._mulC(_).redMul(C.redISub(D)),q=_.redMul(j);return this.curve.point(z,R,q)},S.prototype.dbl=function(){if(this.isInfinity())return this;if(this.curve.extended)return this._extDbl();else return this._projDbl()},S.prototype._extAdd=function(E){var C=this.y.redSub(this.x).redMul(E.y.redSub(E.x)),D=this.y.redAdd(this.x).redMul(E.y.redAdd(E.x)),z=this.t.redMul(this.curve.dd).redMul(E.t),R=this.z.redMul(E.z.redAdd(E.z)),q=D.redSub(C),_=R.redSub(z),k=R.redAdd(z),j=D.redAdd(C),v=q.redMul(_),x=k.redMul(j),N=q.redMul(j),f=_.redMul(k);return this.curve.point(v,x,f,N)},S.prototype._projAdd=function(E){var C=this.z.redMul(E.z),D=C.redSqr(),z=this.x.redMul(E.x),R=this.y.redMul(E.y),q=this.curve.d.redMul(z).redMul(R),_=D.redSub(q),k=D.redAdd(q),j=this.x.redAdd(this.y).redMul(E.x.redAdd(E.y)).redISub(z).redISub(R),v=C.redMul(_).redMul(j),x,N;if(this.curve.twisted)x=C.redMul(k).redMul(R.redSub(this.curve._mulA(z))),N=_.redMul(k);else x=C.redMul(k).redMul(R.redSub(z)),N=this.curve._mulC(_).redMul(k);return this.curve.point(v,x,N)},S.prototype.add=function(E){if(this.isInfinity())return E;if(E.isInfinity())return this;if(this.curve.extended)return this._extAdd(E);else return this._projAdd(E)},S.prototype.mul=function(E){if(this._hasDoubles(E))return this.curve._fixedNafMul(this,E);else return this.curve._wnafMul(this,E)},S.prototype.mulAdd=function(E,C,D){return this.curve._wnafMulAdd(1,[this,C],[E,D],2,!1)},S.prototype.jmulAdd=function(E,C,D){return this.curve._wnafMulAdd(1,[this,C],[E,D],2,!0)},S.prototype.normalize=function(){if(this.zOne)return this;var E=this.z.redInvm();if(this.x=this.x.redMul(E),this.y=this.y.redMul(E),this.t)this.t=this.t.redMul(E);return this.z=this.curve.one,this.zOne=!0,this},S.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},S.prototype.getX=function(){return this.normalize(),this.x.fromRed()},S.prototype.getY=function(){return this.normalize(),this.y.fromRed()},S.prototype.eq=function(E){return this===E||this.getX().cmp(E.getX())===0&&this.getY().cmp(E.getY())===0},S.prototype.eqXToP=function(E){var C=E.toRed(this.curve.red).redMul(this.z);if(this.x.cmp(C)===0)return!0;var D=E.clone(),z=this.curve.redN.redMul(this.z);for(;;){if(D.iadd(this.curve.n),D.cmp(this.curve.p)>=0)return!1;if(C.redIAdd(z),this.x.cmp(C)===0)return!0}},S.prototype.toP=S.prototype.normalize,S.prototype.mixedAdd=S.prototype.add}),gQ=I0((I)=>{var O=I;O.base=kX(),O.short=IV(),O.mont=$V(),O.edwards=KV()}),_U=I0((I)=>{var O=cU(),W=SU();I.inherits=W;function T(Q,J){if((Q.charCodeAt(J)&64512)!==55296)return!1;if(J<0||J+1>=Q.length)return!1;return(Q.charCodeAt(J+1)&64512)===56320}function H(Q,J){if(Array.isArray(Q))return Q.slice();if(!Q)return[];var Z=[];if(typeof Q==="string"){if(!J){var Y=0;for(var K=0;K<Q.length;K++){var F=Q.charCodeAt(K);if(F<128)Z[Y++]=F;else if(F<2048)Z[Y++]=F>>6|192,Z[Y++]=F&63|128;else if(T(Q,K))F=65536+((F&1023)<<10)+(Q.charCodeAt(++K)&1023),Z[Y++]=F>>18|240,Z[Y++]=F>>12&63|128,Z[Y++]=F>>6&63|128,Z[Y++]=F&63|128;else Z[Y++]=F>>12|224,Z[Y++]=F>>6&63|128,Z[Y++]=F&63|128}}else if(J==="hex"){if(Q=Q.replace(/[^a-z0-9]+/ig,""),Q.length%2!==0)Q="0"+Q;for(K=0;K<Q.length;K+=2)Z.push(parseInt(Q[K]+Q[K+1],16))}}else for(K=0;K<Q.length;K++)Z[K]=Q[K]|0;return Z}I.toArray=H;function L(Q){var J="";for(var Z=0;Z<Q.length;Z++)J+=S(Q[Z].toString(16));return J}I.toHex=L;function V(Q){var J=Q>>>24|Q>>>8&65280|Q<<8&16711680|(Q&255)<<24;return J>>>0}I.htonl=V;function P(Q,J){var Z="";for(var Y=0;Y<Q.length;Y++){var K=Q[Y];if(J==="little")K=V(K);Z+=E(K.toString(16))}return Z}I.toHex32=P;function S(Q){if(Q.length===1)return"0"+Q;else return Q}I.zero2=S;function E(Q){if(Q.length===7)return"0"+Q;else if(Q.length===6)return"00"+Q;else if(Q.length===5)return"000"+Q;else if(Q.length===4)return"0000"+Q;else if(Q.length===3)return"00000"+Q;else if(Q.length===2)return"000000"+Q;else if(Q.length===1)return"0000000"+Q;else return Q}I.zero8=E;function C(Q,J,Z,Y){var K=Z-J;O(K%4===0);var F=Array(K/4);for(var G=0,X=J;G<F.length;G++,X+=4){var $;if(Y==="big")$=Q[X]<<24|Q[X+1]<<16|Q[X+2]<<8|Q[X+3];else $=Q[X+3]<<24|Q[X+2]<<16|Q[X+1]<<8|Q[X];F[G]=$>>>0}return F}I.join32=C;function D(Q,J){var Z=Array(Q.length*4);for(var Y=0,K=0;Y<Q.length;Y++,K+=4){var F=Q[Y];if(J==="big")Z[K]=F>>>24,Z[K+1]=F>>>16&255,Z[K+2]=F>>>8&255,Z[K+3]=F&255;else Z[K+3]=F>>>24,Z[K+2]=F>>>16&255,Z[K+1]=F>>>8&255,Z[K]=F&255}return Z}I.split32=D;function z(Q,J){return Q>>>J|Q<<32-J}I.rotr32=z;function R(Q,J){return Q<<J|Q>>>32-J}I.rotl32=R;function q(Q,J){return Q+J>>>0}I.sum32=q;function _(Q,J,Z){return Q+J+Z>>>0}I.sum32_3=_;function k(Q,J,Z,Y){return Q+J+Z+Y>>>0}I.sum32_4=k;function j(Q,J,Z,Y,K){return Q+J+Z+Y+K>>>0}I.sum32_5=j;function v(Q,J,Z,Y){var K=Q[J],F=Q[J+1],G=Y+F>>>0,X=(G<Y?1:0)+Z+K;Q[J]=X>>>0,Q[J+1]=G}I.sum64=v;function x(Q,J,Z,Y){var K=J+Y>>>0,F=(K<J?1:0)+Q+Z;return F>>>0}I.sum64_hi=x;function N(Q,J,Z,Y){var K=J+Y;return K>>>0}I.sum64_lo=N;function f(Q,J,Z,Y,K,F,G,X){var $=0,M=J;M=M+Y>>>0,$+=M<J?1:0,M=M+F>>>0,$+=M<F?1:0,M=M+X>>>0,$+=M<X?1:0;var A=Q+Z+K+G+$;return A>>>0}I.sum64_4_hi=f;function b(Q,J,Z,Y,K,F,G,X){var $=J+Y+F+X;return $>>>0}I.sum64_4_lo=b;function Q0(Q,J,Z,Y,K,F,G,X,$,M){var A=0,B=J;B=B+Y>>>0,A+=B<J?1:0,B=B+F>>>0,A+=B<F?1:0,B=B+X>>>0,A+=B<X?1:0,B=B+M>>>0,A+=B<M?1:0;var w=Q+Z+K+G+$+A;return w>>>0}I.sum64_5_hi=Q0;function G0(Q,J,Z,Y,K,F,G,X,$,M){var A=J+Y+F+X+M;return A>>>0}I.sum64_5_lo=G0;function Y0(Q,J,Z){var Y=J<<32-Z|Q>>>Z;return Y>>>0}I.rotr64_hi=Y0;function u(Q,J,Z){var Y=Q<<32-Z|J>>>Z;return Y>>>0}I.rotr64_lo=u;function U0(Q,J,Z){return Q>>>Z}I.shr64_hi=U0;function U(Q,J,Z){var Y=Q<<32-Z|J>>>Z;return Y>>>0}I.shr64_lo=U}),GX=I0((I)=>{var O=_U(),W=cU();function T(){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}I.BlockHash=T,T.prototype.update=function(H,L){if(H=O.toArray(H,L),!this.pending)this.pending=H;else this.pending=this.pending.concat(H);if(this.pendingTotal+=H.length,this.pending.length>=this._delta8){H=this.pending;var V=H.length%this._delta8;if(this.pending=H.slice(H.length-V,H.length),this.pending.length===0)this.pending=null;H=O.join32(H,0,H.length-V,this.endian);for(var P=0;P<H.length;P+=this._delta32)this._update(H,P,P+this._delta32)}return this},T.prototype.digest=function(H){return this.update(this._pad()),W(this.pending===null),this._digest(H)},T.prototype._pad=function(){var H=this.pendingTotal,L=this._delta8,V=L-(H+this.padLength)%L,P=Array(V+this.padLength);P[0]=128;for(var S=1;S<V;S++)P[S]=0;if(H<<=3,this.endian==="big"){for(var E=8;E<this.padLength;E++)P[S++]=0;P[S++]=0,P[S++]=0,P[S++]=0,P[S++]=0,P[S++]=H>>>24&255,P[S++]=H>>>16&255,P[S++]=H>>>8&255,P[S++]=H&255}else{P[S++]=H&255,P[S++]=H>>>8&255,P[S++]=H>>>16&255,P[S++]=H>>>24&255,P[S++]=0,P[S++]=0,P[S++]=0,P[S++]=0;for(E=8;E<this.padLength;E++)P[S++]=0}return P}}),wQ=I0((I)=>{var O=_U(),W=O.rotr32;function T(D,z,R,q){if(D===0)return H(z,R,q);if(D===1||D===3)return V(z,R,q);if(D===2)return L(z,R,q)}I.ft_1=T;function H(D,z,R){return D&z^~D&R}I.ch32=H;function L(D,z,R){return D&z^D&R^z&R}I.maj32=L;function V(D,z,R){return D^z^R}I.p32=V;function P(D){return W(D,2)^W(D,13)^W(D,22)}I.s0_256=P;function S(D){return W(D,6)^W(D,11)^W(D,25)}I.s1_256=S;function E(D){return W(D,7)^W(D,18)^D>>>3}I.g0_256=E;function C(D){return W(D,17)^W(D,19)^D>>>10}I.g1_256=C}),OV=I0((I,O)=>{var W=_U(),T=GX(),H=wQ(),L=W.rotl32,V=W.sum32,P=W.sum32_5,S=H.ft_1,E=T.BlockHash,C=[1518500249,1859775393,2400959708,3395469782];function D(){if(!(this instanceof D))return new D;E.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.W=Array(80)}W.inherits(D,E),O.exports=D,D.blockSize=512,D.outSize=160,D.hmacStrength=80,D.padLength=64,D.prototype._update=function(z,R){var q=this.W;for(var _=0;_<16;_++)q[_]=z[R+_];for(;_<q.length;_++)q[_]=L(q[_-3]^q[_-8]^q[_-14]^q[_-16],1);var k=this.h[0],j=this.h[1],v=this.h[2],x=this.h[3],N=this.h[4];for(_=0;_<q.length;_++){var f=~~(_/20),b=P(L(k,5),S(f,j,v,x),N,q[_],C[f]);N=x,x=v,v=L(j,30),j=k,k=b}this.h[0]=V(this.h[0],k),this.h[1]=V(this.h[1],j),this.h[2]=V(this.h[2],v),this.h[3]=V(this.h[3],x),this.h[4]=V(this.h[4],N)},D.prototype._digest=function(z){if(z==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")}}),fQ=I0((I,O)=>{var W=_U(),T=GX(),H=wQ(),L=cU(),V=W.sum32,P=W.sum32_4,S=W.sum32_5,E=H.ch32,C=H.maj32,D=H.s0_256,z=H.s1_256,R=H.g0_256,q=H.g1_256,_=T.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 j(){if(!(this instanceof j))return new j;_.call(this),this.h=[1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225],this.k=k,this.W=Array(64)}W.inherits(j,_),O.exports=j,j.blockSize=512,j.outSize=256,j.hmacStrength=192,j.padLength=64,j.prototype._update=function(v,x){var N=this.W;for(var f=0;f<16;f++)N[f]=v[x+f];for(;f<N.length;f++)N[f]=P(q(N[f-2]),N[f-7],R(N[f-15]),N[f-16]);var b=this.h[0],Q0=this.h[1],G0=this.h[2],Y0=this.h[3],u=this.h[4],U0=this.h[5],U=this.h[6],Q=this.h[7];L(this.k.length===N.length);for(f=0;f<N.length;f++){var J=S(Q,z(u),E(u,U0,U),this.k[f],N[f]),Z=V(D(b),C(b,Q0,G0));Q=U,U=U0,U0=u,u=V(Y0,J),Y0=G0,G0=Q0,Q0=b,b=V(J,Z)}this.h[0]=V(this.h[0],b),this.h[1]=V(this.h[1],Q0),this.h[2]=V(this.h[2],G0),this.h[3]=V(this.h[3],Y0),this.h[4]=V(this.h[4],u),this.h[5]=V(this.h[5],U0),this.h[6]=V(this.h[6],U),this.h[7]=V(this.h[7],Q)},j.prototype._digest=function(v){if(v==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")}}),FV=I0((I,O)=>{var W=_U(),T=fQ();function H(){if(!(this instanceof H))return new H;T.call(this),this.h=[3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428]}W.inherits(H,T),O.exports=H,H.blockSize=512,H.outSize=224,H.hmacStrength=192,H.padLength=64,H.prototype._digest=function(L){if(L==="hex")return W.toHex32(this.h.slice(0,7),"big");else return W.split32(this.h.slice(0,7),"big")}}),yQ=I0((I,O)=>{var W=_U(),T=GX(),H=cU(),L=W.rotr64_hi,V=W.rotr64_lo,P=W.shr64_hi,S=W.shr64_lo,E=W.sum64,C=W.sum64_hi,D=W.sum64_lo,z=W.sum64_4_hi,R=W.sum64_4_lo,q=W.sum64_5_hi,_=W.sum64_5_lo,k=T.BlockHash,j=[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 v(){if(!(this instanceof v))return new v;k.call(this),this.h=[1779033703,4089235720,3144134277,2227873595,1013904242,4271175723,2773480762,1595750129,1359893119,2917565137,2600822924,725511199,528734635,4215389547,1541459225,327033209],this.k=j,this.W=Array(160)}W.inherits(v,k),O.exports=v,v.blockSize=1024,v.outSize=512,v.hmacStrength=192,v.padLength=128,v.prototype._prepareBlock=function(Z,Y){var K=this.W;for(var F=0;F<32;F++)K[F]=Z[Y+F];for(;F<K.length;F+=2){var G=Q(K[F-4],K[F-3]),X=J(K[F-4],K[F-3]),$=K[F-14],M=K[F-13],A=U0(K[F-30],K[F-29]),B=U(K[F-30],K[F-29]),w=K[F-32],p=K[F-31];K[F]=z(G,X,$,M,A,B,w,p),K[F+1]=R(G,X,$,M,A,B,w,p)}},v.prototype._update=function(Z,Y){this._prepareBlock(Z,Y);var K=this.W,F=this.h[0],G=this.h[1],X=this.h[2],$=this.h[3],M=this.h[4],A=this.h[5],B=this.h[6],w=this.h[7],p=this.h[8],n=this.h[9],K0=this.h[10],r=this.h[11],d=this.h[12],J0=this.h[13],m=this.h[14],i=this.h[15];H(this.k.length===K.length);for(var g0=0;g0<K.length;g0+=2){var y=m,h=i,V0=Y0(p,n),t=u(p,n),e=x(p,n,K0,r,d,J0),E0=N(p,n,K0,r,d,J0),c=this.k[g0],o=this.k[g0+1],N0=K[g0],s=K[g0+1],Z0=q(y,h,V0,t,e,E0,c,o,N0,s),f0=_(y,h,V0,t,e,E0,c,o,N0,s);y=Q0(F,G),h=G0(F,G),V0=f(F,G,X,$,M,A),t=b(F,G,X,$,M,A);var W0=C(y,h,V0,t),H0=D(y,h,V0,t);m=d,i=J0,d=K0,J0=r,K0=p,r=n,p=C(B,w,Z0,f0),n=D(w,w,Z0,f0),B=M,w=A,M=X,A=$,X=F,$=G,F=C(Z0,f0,W0,H0),G=D(Z0,f0,W0,H0)}E(this.h,0,F,G),E(this.h,2,X,$),E(this.h,4,M,A),E(this.h,6,B,w),E(this.h,8,p,n),E(this.h,10,K0,r),E(this.h,12,d,J0),E(this.h,14,m,i)},v.prototype._digest=function(Z){if(Z==="hex")return W.toHex32(this.h,"big");else return W.split32(this.h,"big")};function x(Z,Y,K,F,G){var X=Z&K^~Z&G;if(X<0)X+=4294967296;return X}function N(Z,Y,K,F,G,X){var $=Y&F^~Y&X;if($<0)$+=4294967296;return $}function f(Z,Y,K,F,G){var X=Z&K^Z&G^K&G;if(X<0)X+=4294967296;return X}function b(Z,Y,K,F,G,X){var $=Y&F^Y&X^F&X;if($<0)$+=4294967296;return $}function Q0(Z,Y){var K=L(Z,Y,28),F=L(Y,Z,2),G=L(Y,Z,7),X=K^F^G;if(X<0)X+=4294967296;return X}function G0(Z,Y){var K=V(Z,Y,28),F=V(Y,Z,2),G=V(Y,Z,7),X=K^F^G;if(X<0)X+=4294967296;return X}function Y0(Z,Y){var K=L(Z,Y,14),F=L(Z,Y,18),G=L(Y,Z,9),X=K^F^G;if(X<0)X+=4294967296;return X}function u(Z,Y){var K=V(Z,Y,14),F=V(Z,Y,18),G=V(Y,Z,9),X=K^F^G;if(X<0)X+=4294967296;return X}function U0(Z,Y){var K=L(Z,Y,1),F=L(Z,Y,8),G=P(Z,Y,7),X=K^F^G;if(X<0)X+=4294967296;return X}function U(Z,Y){var K=V(Z,Y,1),F=V(Z,Y,8),G=S(Z,Y,7),X=K^F^G;if(X<0)X+=4294967296;return X}function Q(Z,Y){var K=L(Z,Y,19),F=L(Y,Z,29),G=P(Z,Y,6),X=K^F^G;if(X<0)X+=4294967296;return X}function J(Z,Y){var K=V(Z,Y,19),F=V(Y,Z,29),G=S(Z,Y,6),X=K^F^G;if(X<0)X+=4294967296;return X}}),WV=I0((I,O)=>{var W=_U(),T=yQ();function H(){if(!(this instanceof H))return new H;T.call(this),this.h=[3418070365,3238371032,1654270250,914150663,2438529370,812702999,355462360,4144912697,1731405415,4290775857,2394180231,1750603025,3675008525,1694076839,1203062813,3204075428]}W.inherits(H,T),O.exports=H,H.blockSize=1024,H.outSize=384,H.hmacStrength=192,H.padLength=128,H.prototype._digest=function(L){if(L==="hex")return W.toHex32(this.h.slice(0,12),"big");else return W.split32(this.h.slice(0,12),"big")}}),HV=I0((I)=>{I.sha1=OV(),I.sha224=FV(),I.sha256=fQ(),I.sha384=WV(),I.sha512=yQ()}),DV=I0((I)=>{var O=_U(),W=GX(),T=O.rotl32,H=O.sum32,L=O.sum32_3,V=O.sum32_4,P=W.BlockHash;function S(){if(!(this instanceof S))return new S;P.call(this),this.h=[1732584193,4023233417,2562383102,271733878,3285377520],this.endian="little"}O.inherits(S,P),I.ripemd160=S,S.blockSize=512,S.outSize=160,S.hmacStrength=192,S.padLength=64,S.prototype._update=function(k,j){var v=this.h[0],x=this.h[1],N=this.h[2],f=this.h[3],b=this.h[4],Q0=v,G0=x,Y0=N,u=f,U0=b;for(var U=0;U<80;U++){var Q=H(T(V(v,E(U,x,N,f),k[z[U]+j],C(U)),q[U]),b);v=b,b=f,f=T(N,10),N=x,x=Q,Q=H(T(V(Q0,E(79-U,G0,Y0,u),k[R[U]+j],D(U)),_[U]),U0),Q0=U0,U0=u,u=T(Y0,10),Y0=G0,G0=Q}Q=L(this.h[1],N,u),this.h[1]=L(this.h[2],f,U0),this.h[2]=L(this.h[3],b,Q0),this.h[3]=L(this.h[4],v,G0),this.h[4]=L(this.h[0],x,Y0),this.h[0]=Q},S.prototype._digest=function(k){if(k==="hex")return O.toHex32(this.h,"little");else return O.split32(this.h,"little")};function E(k,j,v,x){if(k<=15)return j^v^x;else if(k<=31)return j&v|~j&x;else if(k<=47)return(j|~v)^x;else if(k<=63)return j&x|v&~x;else return j^(v|~x)}function C(k){if(k<=15)return 0;else if(k<=31)return 1518500249;else if(k<=47)return 1859775393;else if(k<=63)return 2400959708;else return 2840853838}function D(k){if(k<=15)return 1352829926;else if(k<=31)return 1548603684;else if(k<=47)return 1836072691;else if(k<=63)return 2053994217;else return 0}var z=[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],R=[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],q=[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],_=[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]}),TV=I0((I,O)=>{var W=_U(),T=cU();function H(L,V,P){if(!(this instanceof H))return new H(L,V,P);this.Hash=L,this.blockSize=L.blockSize/8,this.outSize=L.outSize/8,this.inner=null,this.outer=null,this._init(W.toArray(V,P))}O.exports=H,H.prototype._init=function(L){if(L.length>this.blockSize)L=new this.Hash().update(L).digest();T(L.length<=this.blockSize);for(var V=L.length;V<this.blockSize;V++)L.push(0);for(V=0;V<L.length;V++)L[V]^=54;this.inner=new this.Hash().update(L);for(V=0;V<L.length;V++)L[V]^=106;this.outer=new this.Hash().update(L)},H.prototype.update=function(L,V){return this.inner.update(L,V),this},H.prototype.digest=function(L){return this.outer.update(this.inner.digest()),this.outer.digest(L)}}),FZ=I0((I)=>{var O=I;O.utils=_U(),O.common=GX(),O.sha=HV(),O.ripemd=DV(),O.hmac=TV(),O.sha1=O.sha.sha1,O.sha256=O.sha.sha256,O.sha224=O.sha.sha224,O.sha384=O.sha.sha384,O.sha512=O.sha.sha512,O.ripemd160=O.ripemd.ripemd160}),AV=I0((I,O)=>{O.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"]]}}}),WZ=I0((I)=>{var O=I,W=FZ(),T=gQ(),H=kU(),L=H.assert;function V(E){if(E.type==="short")this.curve=new T.short(E);else if(E.type==="edwards")this.curve=new T.edwards(E);else this.curve=new T.mont(E);this.g=this.curve.g,this.n=this.curve.n,this.hash=E.hash,L(this.g.validate(),"Invalid curve"),L(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}O.PresetCurve=V;function P(E,C){Object.defineProperty(O,E,{configurable:!0,enumerable:!0,get:function(){var D=new V(C);return Object.defineProperty(O,E,{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 S;try{S=AV()}catch(E){S=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",S]})}),zV=I0((I,O)=>{var W=FZ(),T=xQ(),H=cU();function L(V){if(!(this instanceof L))return new L(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=T.toArray(V.entropy,V.entropyEnc||"hex"),S=T.toArray(V.nonce,V.nonceEnc||"hex"),E=T.toArray(V.pers,V.persEnc||"hex");H(P.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(P,S,E)}O.exports=L,L.prototype._init=function(V,P,S){var E=V.concat(P).concat(S);this.K=Array(this.outLen/8),this.V=Array(this.outLen/8);for(var C=0;C<this.V.length;C++)this.K[C]=0,this.V[C]=1;this._update(E),this._reseed=1,this.reseedInterval=281474976710656},L.prototype._hmac=function(){return new W.hmac(this.hash,this.K)},L.prototype._update=function(V){var P=this._hmac().update(this.V).update([0]);if(V)P=P.update(V);if(this.K=P.digest(),this.V=this._hmac().update(this.V).digest(),!V)return;this.K=this._hmac().update(this.V).update([1]).update(V).digest(),this.V=this._hmac().update(this.V).digest()},L.prototype.reseed=function(V,P,S,E){if(typeof P!=="string")E=S,S=P,P=null;V=T.toArray(V,P),S=T.toArray(S,E),H(V.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(V.concat(S||[])),this._reseed=1},L.prototype.generate=function(V,P,S,E){if(this._reseed>this.reseedInterval)throw Error("Reseed is required");if(typeof P!=="string")E=S,S=P,P=null;if(S)S=T.toArray(S,E||"hex"),this._update(S);var C=[];while(C.length<V)this.V=this._hmac().update(this.V).digest(),C=C.concat(this.V);var D=C.slice(0,V);return this._update(S),this._reseed++,T.encode(D,P)}}),CV=I0((I,O)=>{var W=gU(),T=kU(),H=T.assert;function L(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)}O.exports=L,L.fromPublic=function(V,P,S){if(P instanceof L)return P;return new L(V,{pub:P,pubEnc:S})},L.fromPrivate=function(V,P,S){if(P instanceof L)return P;return new L(V,{priv:P,privEnc:S})},L.prototype.validate=function(){var V=this.getPublic();if(V.isInfinity())return{result:!1,reason:"Invalid public key"};if(!V.validate())return{result:!1,reason:"Public key is not a point"};if(!V.mul(this.ec.curve.n).isInfinity())return{result:!1,reason:"Public key * N != O"};return{result:!0,reason:null}},L.prototype.getPublic=function(V,P){if(typeof V==="string")P=V,V=null;if(!this.pub)this.pub=this.ec.g.mul(this.priv);if(!P)return this.pub;return this.pub.encode(P,V)},L.prototype.getPrivate=function(V){if(V==="hex")return this.priv.toString(16,2);else return this.priv},L.prototype._importPrivate=function(V,P){this.priv=new W(V,P||16),this.priv=this.priv.umod(this.ec.curve.n)},L.prototype._importPublic=function(V,P){if(V.x||V.y){if(this.ec.curve.type==="mont")H(V.x,"Need x coordinate");else if(this.ec.curve.type==="short"||this.ec.curve.type==="edwards")H(V.x&&V.y,"Need both x and y coordinate");this.pub=this.ec.curve.point(V.x,V.y);return}this.pub=this.ec.curve.decodePoint(V,P)},L.prototype.derive=function(V){if(!V.validate())H(V.validate(),"public point not validated");return V.mul(this.priv).getX()},L.prototype.sign=function(V,P,S){return this.ec.sign(V,this,P,S)},L.prototype.verify=function(V,P,S){return this.ec.verify(V,P,this,void 0,S)},L.prototype.inspect=function(){return"<Key priv: "+(this.priv&&this.priv.toString(16,2))+" pub: "+(this.pub&&this.pub.inspect())+" >"}}),EV=I0((I,O)=>{var W=gU(),T=kU(),H=T.assert;function L(C,D){if(C instanceof L)return C;if(this._importDER(C,D))return;if(H(C.r&&C.s,"Signature without r or s"),this.r=new W(C.r,16),this.s=new W(C.s,16),C.recoveryParam===void 0)this.recoveryParam=null;else this.recoveryParam=C.recoveryParam}O.exports=L;function V(){this.place=0}function P(C,D){var z=C[D.place++];if(!(z&128))return z;var R=z&15;if(R===0||R>4)return!1;if(C[D.place]===0)return!1;var q=0;for(var _=0,k=D.place;_<R;_++,k++)q<<=8,q|=C[k],q>>>=0;if(q<=127)return!1;return D.place=k,q}function S(C){var D=0,z=C.length-1;while(!C[D]&&!(C[D+1]&128)&&D<z)D++;if(D===0)return C;return C.slice(D)}L.prototype._importDER=function(C,D){C=T.toArray(C,D);var z=new V;if(C[z.place++]!==48)return!1;var R=P(C,z);if(R===!1)return!1;if(R+z.place!==C.length)return!1;if(C[z.place++]!==2)return!1;var q=P(C,z);if(q===!1)return!1;if((C[z.place]&128)!==0)return!1;var _=C.slice(z.place,q+z.place);if(z.place+=q,C[z.place++]!==2)return!1;var k=P(C,z);if(k===!1)return!1;if(C.length!==k+z.place)return!1;if((C[z.place]&128)!==0)return!1;var j=C.slice(z.place,k+z.place);if(_[0]===0)if(_[1]&128)_=_.slice(1);else return!1;if(j[0]===0)if(j[1]&128)j=j.slice(1);else return!1;return this.r=new W(_),this.s=new W(j),this.recoveryParam=null,!0};function E(C,D){if(D<128){C.push(D);return}var z=1+(Math.log(D)/Math.LN2>>>3);C.push(z|128);while(--z)C.push(D>>>(z<<3)&255);C.push(D)}L.prototype.toDER=function(C){var D=this.r.toArray(),z=this.s.toArray();if(D[0]&128)D=[0].concat(D);if(z[0]&128)z=[0].concat(z);D=S(D),z=S(z);while(!z[0]&&!(z[1]&128))z=z.slice(1);var R=[2];E(R,D.length),R=R.concat(D),R.push(2),E(R,z.length);var q=R.concat(z),_=[48];return E(_,q.length),_=_.concat(q),T.encode(_,C)}}),LV=I0((I,O)=>{var W=gU(),T=zV(),H=kU(),L=WZ(),V=NQ(),P=H.assert,S=CV(),E=EV();function C(D){if(!(this instanceof C))return new C(D);if(typeof D==="string")P(Object.prototype.hasOwnProperty.call(L,D),"Unknown curve "+D),D=L[D];if(D instanceof L.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}O.exports=C,C.prototype.keyPair=function(D){return new S(this,D)},C.prototype.keyFromPrivate=function(D,z){return S.fromPrivate(this,D,z)},C.prototype.keyFromPublic=function(D,z){return S.fromPublic(this,D,z)},C.prototype.genKeyPair=function(D){if(!D)D={};var z=new T({hash:this.hash,pers:D.pers,persEnc:D.persEnc||"utf8",entropy:D.entropy||V(this.hash.hmacStrength),entropyEnc:D.entropy&&D.entropyEnc||"utf8",nonce:this.n.toArray()}),R=this.n.byteLength(),q=this.n.sub(new W(2));for(;;){var _=new W(z.generate(R));if(_.cmp(q)>0)continue;return _.iaddn(1),this.keyFromPrivate(_)}},C.prototype._truncateToN=function(D,z,R){var q;if(W.isBN(D)||typeof D==="number")D=new W(D,16),q=D.byteLength();else if(typeof D==="object")q=D.length,D=new W(D,16);else{var _=D.toString();q=_.length+1>>>1,D=new W(_,16)}if(typeof R!=="number")R=q*8;var k=R-this.n.bitLength();if(k>0)D=D.ushrn(k);if(!z&&D.cmp(this.n)>=0)return D.sub(this.n);else return D},C.prototype.sign=function(D,z,R,q){if(typeof R==="object")q=R,R=null;if(!q)q={};if(typeof D!=="string"&&typeof D!=="number"&&!W.isBN(D)){P(typeof D==="object"&&D&&typeof D.length==="number","Expected message to be an array-like, a hex string, or a BN instance"),P(D.length>>>0===D.length);for(var _=0;_<D.length;_++)P((D[_]&255)===D[_])}z=this.keyFromPrivate(z,R),D=this._truncateToN(D,!1,q.msgBitLength),P(!D.isNeg(),"Can not sign a negative message");var k=this.n.byteLength(),j=z.getPrivate().toArray("be",k),v=D.toArray("be",k);P(new W(v).eq(D),"Can not sign message");var x=new T({hash:this.hash,entropy:j,nonce:v,pers:q.pers,persEnc:q.persEnc||"utf8"}),N=this.n.sub(new W(1));for(var f=0;;f++){var b=q.k?q.k(f):new W(x.generate(this.n.byteLength()));if(b=this._truncateToN(b,!0),b.cmpn(1)<=0||b.cmp(N)>=0)continue;var Q0=this.g.mul(b);if(Q0.isInfinity())continue;var G0=Q0.getX(),Y0=G0.umod(this.n);if(Y0.cmpn(0)===0)continue;var u=b.invm(this.n).mul(Y0.mul(z.getPrivate()).iadd(D));if(u=u.umod(this.n),u.cmpn(0)===0)continue;var U0=(Q0.getY().isOdd()?1:0)|(G0.cmp(Y0)!==0?2:0);if(q.canonical&&u.cmp(this.nh)>0)u=this.n.sub(u),U0^=1;return new E({r:Y0,s:u,recoveryParam:U0})}},C.prototype.verify=function(D,z,R,q,_){if(!_)_={};D=this._truncateToN(D,!1,_.msgBitLength),R=this.keyFromPublic(R,q),z=new E(z,"hex");var{r:k,s:j}=z;if(k.cmpn(1)<0||k.cmp(this.n)>=0)return!1;if(j.cmpn(1)<0||j.cmp(this.n)>=0)return!1;var v=j.invm(this.n),x=v.mul(D).umod(this.n),N=v.mul(k).umod(this.n),f;if(!this.curve._maxwellTrick){if(f=this.g.mulAdd(x,R.getPublic(),N),f.isInfinity())return!1;return f.getX().umod(this.n).cmp(k)===0}if(f=this.g.jmulAdd(x,R.getPublic(),N),f.isInfinity())return!1;return f.eqXToP(k)},C.prototype.recoverPubKey=function(D,z,R,q){P((3&R)===R,"The recovery param is more than two bits"),z=new E(z,q);var _=this.n,k=new W(D),j=z.r,v=z.s,x=R&1,N=R>>1;if(j.cmp(this.curve.p.umod(this.curve.n))>=0&&N)throw Error("Unable to find sencond key candinate");if(N)j=this.curve.pointFromX(j.add(this.curve.n),x);else j=this.curve.pointFromX(j,x);var f=z.r.invm(_),b=_.sub(k).mul(f).umod(_),Q0=v.mul(f).umod(_);return this.g.mulAdd(b,j,Q0)},C.prototype.getKeyRecoveryParam=function(D,z,R,q){if(z=new E(z,q),z.recoveryParam!==null)return z.recoveryParam;for(var _=0;_<4;_++){var k;try{k=this.recoverPubKey(D,z,_)}catch(j){continue}if(k.eq(R))return _}throw Error("Unable to find valid recovery factor")}}),MV=I0((I,O)=>{var W=kU(),T=W.assert,H=W.parseBytes,L=W.cachedProperty;function V(P,S){if(this.eddsa=P,this._secret=H(S.secret),P.isPoint(S.pub))this._pub=S.pub;else this._pubBytes=H(S.pub)}V.fromPublic=function(P,S){if(S instanceof V)return S;return new V(P,{pub:S})},V.fromSecret=function(P,S){if(S instanceof V)return S;return new V(P,{secret:S})},V.prototype.secret=function(){return this._secret},L(V,"pubBytes",function(){return this.eddsa.encodePoint(this.pub())}),L(V,"pub",function(){if(this._pubBytes)return this.eddsa.decodePoint(this._pubBytes);return this.eddsa.g.mul(this.priv())}),L(V,"privBytes",function(){var P=this.eddsa,S=this.hash(),E=P.encodingLength-1,C=S.slice(0,P.encodingLength);return C[0]&=248,C[E]&=127,C[E]|=64,C}),L(V,"priv",function(){return this.eddsa.decodeInt(this.privBytes())}),L(V,"hash",function(){return this.eddsa.hash().update(this.secret()).digest()}),L(V,"messagePrefix",function(){return this.hash().slice(this.eddsa.encodingLength)}),V.prototype.sign=function(P){return T(this._secret,"KeyPair can only verify"),this.eddsa.sign(P,this)},V.prototype.verify=function(P,S){return this.eddsa.verify(P,S,this)},V.prototype.getSecret=function(P){return T(this._secret,"KeyPair is public only"),W.encode(this.secret(),P)},V.prototype.getPublic=function(P){return W.encode(this.pubBytes(),P)},O.exports=V}),RV=I0((I,O)=>{var W=gU(),T=kU(),H=T.assert,L=T.cachedProperty,V=T.parseBytes;function P(S,E){if(this.eddsa=S,typeof E!=="object")E=V(E);if(Array.isArray(E))H(E.length===S.encodingLength*2,"Signature has invalid size"),E={R:E.slice(0,S.encodingLength),S:E.slice(S.encodingLength)};if(H(E.R&&E.S,"Signature without R or S"),S.isPoint(E.R))this._R=E.R;if(E.S instanceof W)this._S=E.S;this._Rencoded=Array.isArray(E.R)?E.R:E.Rencoded,this._Sencoded=Array.isArray(E.S)?E.S:E.Sencoded}L(P,"S",function(){return this.eddsa.decodeInt(this.Sencoded())}),L(P,"R",function(){return this.eddsa.decodePoint(this.Rencoded())}),L(P,"Rencoded",function(){return this.eddsa.encodePoint(this.R())}),L(P,"Sencoded",function(){return this.eddsa.encodeInt(this.S())}),P.prototype.toBytes=function(){return this.Rencoded().concat(this.Sencoded())},P.prototype.toHex=function(){return T.encode(this.toBytes(),"hex").toUpperCase()},O.exports=P}),qV=I0((I,O)=>{var W=FZ(),T=WZ(),H=kU(),L=H.assert,V=H.parseBytes,P=MV(),S=RV();function E(C){if(L(C==="ed25519","only tested with ed25519 so far"),!(this instanceof E))return new E(C);C=T[C].curve,this.curve=C,this.g=C.g,this.g.precompute(C.n.bitLength()+1),this.pointClass=C.point().constructor,this.encodingLength=Math.ceil(C.n.bitLength()/8),this.hash=W.sha512}O.exports=E,E.prototype.sign=function(C,D){C=V(C);var z=this.keyFromSecret(D),R=this.hashInt(z.messagePrefix(),C),q=this.g.mul(R),_=this.encodePoint(q),k=this.hashInt(_,z.pubBytes(),C).mul(z.priv()),j=R.add(k).umod(this.curve.n);return this.makeSignature({R:q,S:j,Rencoded:_})},E.prototype.verify=function(C,D,z){if(C=V(C),D=this.makeSignature(D),D.S().gte(D.eddsa.curve.n)||D.S().isNeg())return!1;var R=this.keyFromPublic(z),q=this.hashInt(D.Rencoded(),R.pubBytes(),C),_=this.g.mul(D.S()),k=D.R().add(R.pub().mul(q));return k.eq(_)},E.prototype.hashInt=function(){var C=this.hash();for(var D=0;D<arguments.length;D++)C.update(arguments[D]);return H.intFromLE(C.digest()).umod(this.curve.n)},E.prototype.keyFromPublic=function(C){return P.fromPublic(this,C)},E.prototype.keyFromSecret=function(C){return P.fromSecret(this,C)},E.prototype.makeSignature=function(C){if(C instanceof S)return C;return new S(this,C)},E.prototype.encodePoint=function(C){var D=C.getY().toArray("le",this.encodingLength);return D[this.encodingLength-1]|=C.getX().isOdd()?128:0,D},E.prototype.decodePoint=function(C){C=H.parseBytes(C);var D=C.length-1,z=C.slice(0,D).concat(C[D]&-129),R=(C[D]&128)!==0,q=H.intFromLE(z);return this.curve.pointFromY(q,R)},E.prototype.encodeInt=function(C){return C.toArray("le",this.encodingLength)},E.prototype.decodeInt=function(C){return H.intFromLE(C)},E.prototype.isPoint=function(C){return C instanceof this.pointClass}}),SV=I0((I)=>{var O=I;O.version=VV().version,O.utils=kU(),O.rand=NQ(),O.curve=gQ(),O.curves=WZ(),O.ec=LV(),O.eddsa=qV()}),PV=I0((I,O)=>{(function(W,T){function H(U,Q){if(!U)throw Error(Q||"Assertion failed")}function L(U,Q){U.super_=Q;var J=function(){};J.prototype=Q.prototype,U.prototype=new J,U.prototype.constructor=U}function V(U,Q,J){if(V.isBN(U))return U;if(this.negative=0,this.words=null,this.length=0,this.red=null,U!==null){if(Q==="le"||Q==="be")J=Q,Q=10;this._init(U||0,Q||10,J||"be")}}if(typeof W==="object")W.exports=V;else T.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window<"u"&&typeof window.Buffer<"u")P=window.Buffer;else P=(HU(),h0(WU)).Buffer}catch(U){}V.isBN=function(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(U,Q){if(U.cmp(Q)>0)return U;return Q},V.min=function(U,Q){if(U.cmp(Q)<0)return U;return Q},V.prototype._init=function(U,Q,J){if(typeof U==="number")return this._initNumber(U,Q,J);if(typeof U==="object")return this._initArray(U,Q,J);if(Q==="hex")Q=16;H(Q===(Q|0)&&Q>=2&&Q<=36),U=U.toString().replace(/\s+/g,"");var Z=0;if(U[0]==="-")Z++,this.negative=1;if(Z<U.length){if(Q===16)this._parseHex(U,Z,J);else if(this._parseBase(U,Q,Z),J==="le")this._initArray(this.toArray(),Q,J)}},V.prototype._initNumber=function(U,Q,J){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(J!=="le")return;this._initArray(this.toArray(),Q,J)},V.prototype._initArray=function(U,Q,J){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=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y,K,F=0;if(J==="be"){for(Z=U.length-1,Y=0;Z>=0;Z-=3)if(K=U[Z]|U[Z-1]<<8|U[Z-2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}else if(J==="le"){for(Z=0,Y=0;Z<U.length;Z+=3)if(K=U[Z]|U[Z+1]<<8|U[Z+2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}return this.strip()};function S(U,Q){var J=U.charCodeAt(Q);if(J>=65&&J<=70)return J-55;else if(J>=97&&J<=102)return J-87;else return J-48&15}function E(U,Q,J){var Z=S(U,J);if(J-1>=Q)Z|=S(U,J-1)<<4;return Z}V.prototype._parseHex=function(U,Q,J){this.length=Math.ceil((U.length-Q)/6),this.words=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y=0,K=0,F;if(J==="be")for(Z=U.length-1;Z>=Q;Z-=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8;else{var G=U.length-Q;for(Z=G%2===0?Q+1:Q;Z<U.length;Z+=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8}this.strip()};function C(U,Q,J,Z){var Y=0,K=Math.min(U.length,J);for(var F=Q;F<K;F++){var G=U.charCodeAt(F)-48;if(Y*=Z,G>=49)Y+=G-49+10;else if(G>=17)Y+=G-17+10;else Y+=G}return Y}V.prototype._parseBase=function(U,Q,J){this.words=[0],this.length=1;for(var Z=0,Y=1;Y<=67108863;Y*=Q)Z++;Z--,Y=Y/Q|0;var K=U.length-J,F=K%Z,G=Math.min(K,K-F)+J,X=0;for(var $=J;$<G;$+=Z)if(X=C(U,$,$+Z,Q),this.imuln(Y),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(F!==0){var M=1;X=C(U,$,U.length,Q);for($=0;$<F;$++)M*=Q;if(this.imuln(M),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function(U){U.words=Array(this.length);for(var Q=0;Q<this.length;Q++)U.words[Q]=this.words[Q];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function(){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"],z=[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],R=[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(U,Q){U=U||10,Q=Q|0||1;var J;if(U===16||U==="hex"){J="";var Z=0,Y=0;for(var K=0;K<this.length;K++){var F=this.words[K],G=((F<<Z|Y)&16777215).toString(16);if(Y=F>>>24-Z&16777215,Z+=2,Z>=26)Z-=26,K--;if(Y!==0||K!==this.length-1)J=D[6-G.length]+G+J;else J=G+J}if(Y!==0)J=Y.toString(16)+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}if(U===(U|0)&&U>=2&&U<=36){var X=z[U],$=R[U];J="";var M=this.clone();M.negative=0;while(!M.isZero()){var A=M.modn($).toString(U);if(M=M.idivn($),!M.isZero())J=D[X-A.length]+A+J;else J=A+J}if(this.isZero())J="0"+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function(){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(){return this.toString(16)},V.prototype.toBuffer=function(U,Q){return H(typeof P<"u"),this.toArrayLike(P,U,Q)},V.prototype.toArray=function(U,Q){return this.toArrayLike(Array,U,Q)},V.prototype.toArrayLike=function(U,Q,J){var Z=this.byteLength(),Y=J||Math.max(1,Z);H(Z<=Y,"byte array longer than desired length"),H(Y>0,"Requested array length <= 0"),this.strip();var K=Q==="le",F=new U(Y),G,X,$=this.clone();if(!K){for(X=0;X<Y-Z;X++)F[X]=0;for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[Y-X-1]=G}else{for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[X]=G;for(;X<Y;X++)F[X]=0}return F},Math.clz32)V.prototype._countBits=function(U){return 32-Math.clz32(U)};else V.prototype._countBits=function(U){var Q=U,J=0;if(Q>=4096)J+=13,Q>>>=13;if(Q>=64)J+=7,Q>>>=7;if(Q>=8)J+=4,Q>>>=4;if(Q>=2)J+=2,Q>>>=2;return J+Q};V.prototype._zeroBits=function(U){if(U===0)return 26;var Q=U,J=0;if((Q&8191)===0)J+=13,Q>>>=13;if((Q&127)===0)J+=7,Q>>>=7;if((Q&15)===0)J+=4,Q>>>=4;if((Q&3)===0)J+=2,Q>>>=2;if((Q&1)===0)J++;return J},V.prototype.bitLength=function(){var U=this.words[this.length-1],Q=this._countBits(U);return(this.length-1)*26+Q};function q(U){var Q=Array(U.bitLength());for(var J=0;J<Q.length;J++){var Z=J/26|0,Y=J%26;Q[J]=(U.words[Z]&1<<Y)>>>Y}return Q}V.prototype.zeroBits=function(){if(this.isZero())return 0;var U=0;for(var Q=0;Q<this.length;Q++){var J=this._zeroBits(this.words[Q]);if(U+=J,J!==26)break}return U},V.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function(){return this.negative!==0},V.prototype.neg=function(){return this.clone().ineg()},V.prototype.ineg=function(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function(U){while(this.length<U.length)this.words[this.length++]=0;for(var Q=0;Q<U.length;Q++)this.words[Q]=this.words[Q]|U.words[Q];return this.strip()},V.prototype.ior=function(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function(U){var Q;if(this.length>U.length)Q=U;else Q=this;for(var J=0;J<Q.length;J++)this.words[J]=this.words[J]&U.words[J];return this.length=Q.length,this.strip()},V.prototype.iand=function(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function(U){var Q,J;if(this.length>U.length)Q=this,J=U;else Q=U,J=this;for(var Z=0;Z<J.length;Z++)this.words[Z]=Q.words[Z]^J.words[Z];if(this!==Q)for(;Z<Q.length;Z++)this.words[Z]=Q.words[Z];return this.length=Q.length,this.strip()},V.prototype.ixor=function(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function(U){H(typeof U==="number"&&U>=0);var Q=Math.ceil(U/26)|0,J=U%26;if(this._expand(Q),J>0)Q--;for(var Z=0;Z<Q;Z++)this.words[Z]=~this.words[Z]&67108863;if(J>0)this.words[Z]=~this.words[Z]&67108863>>26-J;return this.strip()},V.prototype.notn=function(U){return this.clone().inotn(U)},V.prototype.setn=function(U,Q){H(typeof U==="number"&&U>=0);var J=U/26|0,Z=U%26;if(this._expand(J+1),Q)this.words[J]=this.words[J]|1<<Z;else this.words[J]=this.words[J]&~(1<<Z);return this.strip()},V.prototype.iadd=function(U){var Q;if(this.negative!==0&&U.negative===0)return this.negative=0,Q=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Q=this.isub(U),U.negative=1,Q._normSign();var J,Z;if(this.length>U.length)J=this,Z=U;else J=U,Z=this;var Y=0;for(var K=0;K<Z.length;K++)Q=(J.words[K]|0)+(Z.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;for(;Y!==0&&K<J.length;K++)Q=(J.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;if(this.length=J.length,Y!==0)this.words[this.length]=Y,this.length++;else if(J!==this)for(;K<J.length;K++)this.words[K]=J.words[K];return this},V.prototype.add=function(U){var Q;if(U.negative!==0&&this.negative===0)return U.negative=0,Q=this.sub(U),U.negative^=1,Q;else if(U.negative===0&&this.negative!==0)return this.negative=0,Q=U.sub(this),this.negative=1,Q;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function(U){if(U.negative!==0){U.negative=0;var Q=this.iadd(U);return U.negative=1,Q._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var J=this.cmp(U);if(J===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Z,Y;if(J>0)Z=this,Y=U;else Z=U,Y=this;var K=0;for(var F=0;F<Y.length;F++)Q=(Z.words[F]|0)-(Y.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;for(;K!==0&&F<Z.length;F++)Q=(Z.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;if(K===0&&F<Z.length&&Z!==this)for(;F<Z.length;F++)this.words[F]=Z.words[F];if(this.length=Math.max(this.length,F),Z!==this)this.negative=1;return this.strip()},V.prototype.sub=function(U){return this.clone().isub(U)};function _(U,Q,J){J.negative=Q.negative^U.negative;var Z=U.length+Q.length|0;J.length=Z,Z=Z-1|0;var Y=U.words[0]|0,K=Q.words[0]|0,F=Y*K,G=F&67108863,X=F/67108864|0;J.words[0]=G;for(var $=1;$<Z;$++){var M=X>>>26,A=X&67108863,B=Math.min($,Q.length-1);for(var w=Math.max(0,$-U.length+1);w<=B;w++){var p=$-w|0;Y=U.words[p]|0,K=Q.words[w]|0,F=Y*K+A,M+=F/67108864|0,A=F&67108863}J.words[$]=A|0,X=M|0}if(X!==0)J.words[$]=X|0;else J.length--;return J.strip()}var k=function(U,Q,J){var Z=U.words,Y=Q.words,K=J.words,F=0,G,X,$,M=Z[0]|0,A=M&8191,B=M>>>13,w=Z[1]|0,p=w&8191,n=w>>>13,K0=Z[2]|0,r=K0&8191,d=K0>>>13,J0=Z[3]|0,m=J0&8191,i=J0>>>13,g0=Z[4]|0,y=g0&8191,h=g0>>>13,V0=Z[5]|0,t=V0&8191,e=V0>>>13,E0=Z[6]|0,c=E0&8191,o=E0>>>13,N0=Z[7]|0,s=N0&8191,Z0=N0>>>13,f0=Z[8]|0,W0=f0&8191,H0=f0>>>13,n0=Z[9]|0,O0=n0&8191,D0=n0>>>13,t0=Y[0]|0,z0=t0&8191,A0=t0>>>13,AU=Y[1]|0,L0=AU&8191,k0=AU>>>13,zU=Y[2]|0,j0=zU&8191,M0=zU>>>13,DU=Y[3]|0,v0=DU&8191,R0=DU>>>13,KU=Y[4]|0,_0=KU&8191,B0=KU>>>13,OU=Y[5]|0,q0=OU&8191,g=OU>>>13,l=Y[6]|0,a=l&8191,X0=l>>>13,w0=Y[7]|0,F0=w0&8191,T0=w0>>>13,m0=Y[8]|0,S0=m0&8191,x0=m0>>>13,TU=Y[9]|0,P0=TU&8191,C0=TU>>>13;J.negative=U.negative^Q.negative,J.length=19,G=Math.imul(A,z0),X=Math.imul(A,A0),X=X+Math.imul(B,z0)|0,$=Math.imul(B,A0);var s0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(s0>>>26)|0,s0&=67108863,G=Math.imul(p,z0),X=Math.imul(p,A0),X=X+Math.imul(n,z0)|0,$=Math.imul(n,A0),G=G+Math.imul(A,L0)|0,X=X+Math.imul(A,k0)|0,X=X+Math.imul(B,L0)|0,$=$+Math.imul(B,k0)|0;var c0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(c0>>>26)|0,c0&=67108863,G=Math.imul(r,z0),X=Math.imul(r,A0),X=X+Math.imul(d,z0)|0,$=Math.imul(d,A0),G=G+Math.imul(p,L0)|0,X=X+Math.imul(p,k0)|0,X=X+Math.imul(n,L0)|0,$=$+Math.imul(n,k0)|0,G=G+Math.imul(A,j0)|0,X=X+Math.imul(A,M0)|0,X=X+Math.imul(B,j0)|0,$=$+Math.imul(B,M0)|0;var y0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(y0>>>26)|0,y0&=67108863,G=Math.imul(m,z0),X=Math.imul(m,A0),X=X+Math.imul(i,z0)|0,$=Math.imul(i,A0),G=G+Math.imul(r,L0)|0,X=X+Math.imul(r,k0)|0,X=X+Math.imul(d,L0)|0,$=$+Math.imul(d,k0)|0,G=G+Math.imul(p,j0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(n,j0)|0,$=$+Math.imul(n,M0)|0,G=G+Math.imul(A,v0)|0,X=X+Math.imul(A,R0)|0,X=X+Math.imul(B,v0)|0,$=$+Math.imul(B,R0)|0;var l0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(l0>>>26)|0,l0&=67108863,G=Math.imul(y,z0),X=Math.imul(y,A0),X=X+Math.imul(h,z0)|0,$=Math.imul(h,A0),G=G+Math.imul(m,L0)|0,X=X+Math.imul(m,k0)|0,X=X+Math.imul(i,L0)|0,$=$+Math.imul(i,k0)|0,G=G+Math.imul(r,j0)|0,X=X+Math.imul(r,M0)|0,X=X+Math.imul(d,j0)|0,$=$+Math.imul(d,M0)|0,G=G+Math.imul(p,v0)|0,X=X+Math.imul(p,R0)|0,X=X+Math.imul(n,v0)|0,$=$+Math.imul(n,R0)|0,G=G+Math.imul(A,_0)|0,X=X+Math.imul(A,B0)|0,X=X+Math.imul(B,_0)|0,$=$+Math.imul(B,B0)|0;var b0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,G=Math.imul(t,z0),X=Math.imul(t,A0),X=X+Math.imul(e,z0)|0,$=Math.imul(e,A0),G=G+Math.imul(y,L0)|0,X=X+Math.imul(y,k0)|0,X=X+Math.imul(h,L0)|0,$=$+Math.imul(h,k0)|0,G=G+Math.imul(m,j0)|0,X=X+Math.imul(m,M0)|0,X=X+Math.imul(i,j0)|0,$=$+Math.imul(i,M0)|0,G=G+Math.imul(r,v0)|0,X=X+Math.imul(r,R0)|0,X=X+Math.imul(d,v0)|0,$=$+Math.imul(d,R0)|0,G=G+Math.imul(p,_0)|0,X=X+Math.imul(p,B0)|0,X=X+Math.imul(n,_0)|0,$=$+Math.imul(n,B0)|0,G=G+Math.imul(A,q0)|0,X=X+Math.imul(A,g)|0,X=X+Math.imul(B,q0)|0,$=$+Math.imul(B,g)|0;var r0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(r0>>>26)|0,r0&=67108863,G=Math.imul(c,z0),X=Math.imul(c,A0),X=X+Math.imul(o,z0)|0,$=Math.imul(o,A0),G=G+Math.imul(t,L0)|0,X=X+Math.imul(t,k0)|0,X=X+Math.imul(e,L0)|0,$=$+Math.imul(e,k0)|0,G=G+Math.imul(y,j0)|0,X=X+Math.imul(y,M0)|0,X=X+Math.imul(h,j0)|0,$=$+Math.imul(h,M0)|0,G=G+Math.imul(m,v0)|0,X=X+Math.imul(m,R0)|0,X=X+Math.imul(i,v0)|0,$=$+Math.imul(i,R0)|0,G=G+Math.imul(r,_0)|0,X=X+Math.imul(r,B0)|0,X=X+Math.imul(d,_0)|0,$=$+Math.imul(d,B0)|0,G=G+Math.imul(p,q0)|0,X=X+Math.imul(p,g)|0,X=X+Math.imul(n,q0)|0,$=$+Math.imul(n,g)|0,G=G+Math.imul(A,a)|0,X=X+Math.imul(A,X0)|0,X=X+Math.imul(B,a)|0,$=$+Math.imul(B,X0)|0;var a0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,G=Math.imul(s,z0),X=Math.imul(s,A0),X=X+Math.imul(Z0,z0)|0,$=Math.imul(Z0,A0),G=G+Math.imul(c,L0)|0,X=X+Math.imul(c,k0)|0,X=X+Math.imul(o,L0)|0,$=$+Math.imul(o,k0)|0,G=G+Math.imul(t,j0)|0,X=X+Math.imul(t,M0)|0,X=X+Math.imul(e,j0)|0,$=$+Math.imul(e,M0)|0,G=G+Math.imul(y,v0)|0,X=X+Math.imul(y,R0)|0,X=X+Math.imul(h,v0)|0,$=$+Math.imul(h,R0)|0,G=G+Math.imul(m,_0)|0,X=X+Math.imul(m,B0)|0,X=X+Math.imul(i,_0)|0,$=$+Math.imul(i,B0)|0,G=G+Math.imul(r,q0)|0,X=X+Math.imul(r,g)|0,X=X+Math.imul(d,q0)|0,$=$+Math.imul(d,g)|0,G=G+Math.imul(p,a)|0,X=X+Math.imul(p,X0)|0,X=X+Math.imul(n,a)|0,$=$+Math.imul(n,X0)|0,G=G+Math.imul(A,F0)|0,X=X+Math.imul(A,T0)|0,X=X+Math.imul(B,F0)|0,$=$+Math.imul(B,T0)|0;var e0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,G=Math.imul(W0,z0),X=Math.imul(W0,A0),X=X+Math.imul(H0,z0)|0,$=Math.imul(H0,A0),G=G+Math.imul(s,L0)|0,X=X+Math.imul(s,k0)|0,X=X+Math.imul(Z0,L0)|0,$=$+Math.imul(Z0,k0)|0,G=G+Math.imul(c,j0)|0,X=X+Math.imul(c,M0)|0,X=X+Math.imul(o,j0)|0,$=$+Math.imul(o,M0)|0,G=G+Math.imul(t,v0)|0,X=X+Math.imul(t,R0)|0,X=X+Math.imul(e,v0)|0,$=$+Math.imul(e,R0)|0,G=G+Math.imul(y,_0)|0,X=X+Math.imul(y,B0)|0,X=X+Math.imul(h,_0)|0,$=$+Math.imul(h,B0)|0,G=G+Math.imul(m,q0)|0,X=X+Math.imul(m,g)|0,X=X+Math.imul(i,q0)|0,$=$+Math.imul(i,g)|0,G=G+Math.imul(r,a)|0,X=X+Math.imul(r,X0)|0,X=X+Math.imul(d,a)|0,$=$+Math.imul(d,X0)|0,G=G+Math.imul(p,F0)|0,X=X+Math.imul(p,T0)|0,X=X+Math.imul(n,F0)|0,$=$+Math.imul(n,T0)|0,G=G+Math.imul(A,S0)|0,X=X+Math.imul(A,x0)|0,X=X+Math.imul(B,S0)|0,$=$+Math.imul(B,x0)|0;var i0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,G=Math.imul(O0,z0),X=Math.imul(O0,A0),X=X+Math.imul(D0,z0)|0,$=Math.imul(D0,A0),G=G+Math.imul(W0,L0)|0,X=X+Math.imul(W0,k0)|0,X=X+Math.imul(H0,L0)|0,$=$+Math.imul(H0,k0)|0,G=G+Math.imul(s,j0)|0,X=X+Math.imul(s,M0)|0,X=X+Math.imul(Z0,j0)|0,$=$+Math.imul(Z0,M0)|0,G=G+Math.imul(c,v0)|0,X=X+Math.imul(c,R0)|0,X=X+Math.imul(o,v0)|0,$=$+Math.imul(o,R0)|0,G=G+Math.imul(t,_0)|0,X=X+Math.imul(t,B0)|0,X=X+Math.imul(e,_0)|0,$=$+Math.imul(e,B0)|0,G=G+Math.imul(y,q0)|0,X=X+Math.imul(y,g)|0,X=X+Math.imul(h,q0)|0,$=$+Math.imul(h,g)|0,G=G+Math.imul(m,a)|0,X=X+Math.imul(m,X0)|0,X=X+Math.imul(i,a)|0,$=$+Math.imul(i,X0)|0,G=G+Math.imul(r,F0)|0,X=X+Math.imul(r,T0)|0,X=X+Math.imul(d,F0)|0,$=$+Math.imul(d,T0)|0,G=G+Math.imul(p,S0)|0,X=X+Math.imul(p,x0)|0,X=X+Math.imul(n,S0)|0,$=$+Math.imul(n,x0)|0,G=G+Math.imul(A,P0)|0,X=X+Math.imul(A,C0)|0,X=X+Math.imul(B,P0)|0,$=$+Math.imul(B,C0)|0;var UU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,G=Math.imul(O0,L0),X=Math.imul(O0,k0),X=X+Math.imul(D0,L0)|0,$=Math.imul(D0,k0),G=G+Math.imul(W0,j0)|0,X=X+Math.imul(W0,M0)|0,X=X+Math.imul(H0,j0)|0,$=$+Math.imul(H0,M0)|0,G=G+Math.imul(s,v0)|0,X=X+Math.imul(s,R0)|0,X=X+Math.imul(Z0,v0)|0,$=$+Math.imul(Z0,R0)|0,G=G+Math.imul(c,_0)|0,X=X+Math.imul(c,B0)|0,X=X+Math.imul(o,_0)|0,$=$+Math.imul(o,B0)|0,G=G+Math.imul(t,q0)|0,X=X+Math.imul(t,g)|0,X=X+Math.imul(e,q0)|0,$=$+Math.imul(e,g)|0,G=G+Math.imul(y,a)|0,X=X+Math.imul(y,X0)|0,X=X+Math.imul(h,a)|0,$=$+Math.imul(h,X0)|0,G=G+Math.imul(m,F0)|0,X=X+Math.imul(m,T0)|0,X=X+Math.imul(i,F0)|0,$=$+Math.imul(i,T0)|0,G=G+Math.imul(r,S0)|0,X=X+Math.imul(r,x0)|0,X=X+Math.imul(d,S0)|0,$=$+Math.imul(d,x0)|0,G=G+Math.imul(p,P0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(n,P0)|0,$=$+Math.imul(n,C0)|0;var XU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,G=Math.imul(O0,j0),X=Math.imul(O0,M0),X=X+Math.imul(D0,j0)|0,$=Math.imul(D0,M0),G=G+Math.imul(W0,v0)|0,X=X+Math.imul(W0,R0)|0,X=X+Math.imul(H0,v0)|0,$=$+Math.imul(H0,R0)|0,G=G+Math.imul(s,_0)|0,X=X+Math.imul(s,B0)|0,X=X+Math.imul(Z0,_0)|0,$=$+Math.imul(Z0,B0)|0,G=G+Math.imul(c,q0)|0,X=X+Math.imul(c,g)|0,X=X+Math.imul(o,q0)|0,$=$+Math.imul(o,g)|0,G=G+Math.imul(t,a)|0,X=X+Math.imul(t,X0)|0,X=X+Math.imul(e,a)|0,$=$+Math.imul(e,X0)|0,G=G+Math.imul(y,F0)|0,X=X+Math.imul(y,T0)|0,X=X+Math.imul(h,F0)|0,$=$+Math.imul(h,T0)|0,G=G+Math.imul(m,S0)|0,X=X+Math.imul(m,x0)|0,X=X+Math.imul(i,S0)|0,$=$+Math.imul(i,x0)|0,G=G+Math.imul(r,P0)|0,X=X+Math.imul(r,C0)|0,X=X+Math.imul(d,P0)|0,$=$+Math.imul(d,C0)|0;var ZU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,G=Math.imul(O0,v0),X=Math.imul(O0,R0),X=X+Math.imul(D0,v0)|0,$=Math.imul(D0,R0),G=G+Math.imul(W0,_0)|0,X=X+Math.imul(W0,B0)|0,X=X+Math.imul(H0,_0)|0,$=$+Math.imul(H0,B0)|0,G=G+Math.imul(s,q0)|0,X=X+Math.imul(s,g)|0,X=X+Math.imul(Z0,q0)|0,$=$+Math.imul(Z0,g)|0,G=G+Math.imul(c,a)|0,X=X+Math.imul(c,X0)|0,X=X+Math.imul(o,a)|0,$=$+Math.imul(o,X0)|0,G=G+Math.imul(t,F0)|0,X=X+Math.imul(t,T0)|0,X=X+Math.imul(e,F0)|0,$=$+Math.imul(e,T0)|0,G=G+Math.imul(y,S0)|0,X=X+Math.imul(y,x0)|0,X=X+Math.imul(h,S0)|0,$=$+Math.imul(h,x0)|0,G=G+Math.imul(m,P0)|0,X=X+Math.imul(m,C0)|0,X=X+Math.imul(i,P0)|0,$=$+Math.imul(i,C0)|0;var QU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,G=Math.imul(O0,_0),X=Math.imul(O0,B0),X=X+Math.imul(D0,_0)|0,$=Math.imul(D0,B0),G=G+Math.imul(W0,q0)|0,X=X+Math.imul(W0,g)|0,X=X+Math.imul(H0,q0)|0,$=$+Math.imul(H0,g)|0,G=G+Math.imul(s,a)|0,X=X+Math.imul(s,X0)|0,X=X+Math.imul(Z0,a)|0,$=$+Math.imul(Z0,X0)|0,G=G+Math.imul(c,F0)|0,X=X+Math.imul(c,T0)|0,X=X+Math.imul(o,F0)|0,$=$+Math.imul(o,T0)|0,G=G+Math.imul(t,S0)|0,X=X+Math.imul(t,x0)|0,X=X+Math.imul(e,S0)|0,$=$+Math.imul(e,x0)|0,G=G+Math.imul(y,P0)|0,X=X+Math.imul(y,C0)|0,X=X+Math.imul(h,P0)|0,$=$+Math.imul(h,C0)|0;var YU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,G=Math.imul(O0,q0),X=Math.imul(O0,g),X=X+Math.imul(D0,q0)|0,$=Math.imul(D0,g),G=G+Math.imul(W0,a)|0,X=X+Math.imul(W0,X0)|0,X=X+Math.imul(H0,a)|0,$=$+Math.imul(H0,X0)|0,G=G+Math.imul(s,F0)|0,X=X+Math.imul(s,T0)|0,X=X+Math.imul(Z0,F0)|0,$=$+Math.imul(Z0,T0)|0,G=G+Math.imul(c,S0)|0,X=X+Math.imul(c,x0)|0,X=X+Math.imul(o,S0)|0,$=$+Math.imul(o,x0)|0,G=G+Math.imul(t,P0)|0,X=X+Math.imul(t,C0)|0,X=X+Math.imul(e,P0)|0,$=$+Math.imul(e,C0)|0;var JU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(JU>>>26)|0,JU&=67108863,G=Math.imul(O0,a),X=Math.imul(O0,X0),X=X+Math.imul(D0,a)|0,$=Math.imul(D0,X0),G=G+Math.imul(W0,F0)|0,X=X+Math.imul(W0,T0)|0,X=X+Math.imul(H0,F0)|0,$=$+Math.imul(H0,T0)|0,G=G+Math.imul(s,S0)|0,X=X+Math.imul(s,x0)|0,X=X+Math.imul(Z0,S0)|0,$=$+Math.imul(Z0,x0)|0,G=G+Math.imul(c,P0)|0,X=X+Math.imul(c,C0)|0,X=X+Math.imul(o,P0)|0,$=$+Math.imul(o,C0)|0;var VU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,G=Math.imul(O0,F0),X=Math.imul(O0,T0),X=X+Math.imul(D0,F0)|0,$=Math.imul(D0,T0),G=G+Math.imul(W0,S0)|0,X=X+Math.imul(W0,x0)|0,X=X+Math.imul(H0,S0)|0,$=$+Math.imul(H0,x0)|0,G=G+Math.imul(s,P0)|0,X=X+Math.imul(s,C0)|0,X=X+Math.imul(Z0,P0)|0,$=$+Math.imul(Z0,C0)|0;var GU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,G=Math.imul(O0,S0),X=Math.imul(O0,x0),X=X+Math.imul(D0,S0)|0,$=Math.imul(D0,x0),G=G+Math.imul(W0,P0)|0,X=X+Math.imul(W0,C0)|0,X=X+Math.imul(H0,P0)|0,$=$+Math.imul(H0,C0)|0;var IU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,G=Math.imul(O0,P0),X=Math.imul(O0,C0),X=X+Math.imul(D0,P0)|0,$=Math.imul(D0,C0);var $U=(F+G|0)+((X&8191)<<13)|0;if(F=($+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,K[0]=s0,K[1]=c0,K[2]=y0,K[3]=l0,K[4]=b0,K[5]=r0,K[6]=a0,K[7]=e0,K[8]=i0,K[9]=UU,K[10]=XU,K[11]=ZU,K[12]=QU,K[13]=YU,K[14]=JU,K[15]=VU,K[16]=GU,K[17]=IU,K[18]=$U,F!==0)K[19]=F,J.length++;return J};if(!Math.imul)k=_;function j(U,Q,J){J.negative=Q.negative^U.negative,J.length=U.length+Q.length;var Z=0,Y=0;for(var K=0;K<J.length-1;K++){var F=Y;Y=0;var G=Z&67108863,X=Math.min(K,Q.length-1);for(var $=Math.max(0,K-U.length+1);$<=X;$++){var M=K-$,A=U.words[M]|0,B=Q.words[$]|0,w=A*B,p=w&67108863;F=F+(w/67108864|0)|0,p=p+G|0,G=p&67108863,F=F+(p>>>26)|0,Y+=F>>>26,F&=67108863}J.words[K]=G,Z=F,F=Y}if(Z!==0)J.words[K]=Z;else J.length--;return J.strip()}function v(U,Q,J){var Z=new x;return Z.mulp(U,Q,J)}V.prototype.mulTo=function(U,Q){var J,Z=this.length+U.length;if(this.length===10&&U.length===10)J=k(this,U,Q);else if(Z<63)J=_(this,U,Q);else if(Z<1024)J=j(this,U,Q);else J=v(this,U,Q);return J};function x(U,Q){this.x=U,this.y=Q}x.prototype.makeRBT=function(U){var Q=Array(U),J=V.prototype._countBits(U)-1;for(var Z=0;Z<U;Z++)Q[Z]=this.revBin(Z,J,U);return Q},x.prototype.revBin=function(U,Q,J){if(U===0||U===J-1)return U;var Z=0;for(var Y=0;Y<Q;Y++)Z|=(U&1)<<Q-Y-1,U>>=1;return Z},x.prototype.permute=function(U,Q,J,Z,Y,K){for(var F=0;F<K;F++)Z[F]=Q[U[F]],Y[F]=J[U[F]]},x.prototype.transform=function(U,Q,J,Z,Y,K){this.permute(K,U,Q,J,Z,Y);for(var F=1;F<Y;F<<=1){var G=F<<1,X=Math.cos(2*Math.PI/G),$=Math.sin(2*Math.PI/G);for(var M=0;M<Y;M+=G){var A=X,B=$;for(var w=0;w<F;w++){var p=J[M+w],n=Z[M+w],K0=J[M+w+F],r=Z[M+w+F],d=A*K0-B*r;if(r=A*r+B*K0,K0=d,J[M+w]=p+K0,Z[M+w]=n+r,J[M+w+F]=p-K0,Z[M+w+F]=n-r,w!==G)d=X*A-$*B,B=X*B+$*A,A=d}}}},x.prototype.guessLen13b=function(U,Q){var J=Math.max(Q,U)|1,Z=J&1,Y=0;for(J=J/2|0;J;J=J>>>1)Y++;return 1<<Y+1+Z},x.prototype.conjugate=function(U,Q,J){if(J<=1)return;for(var Z=0;Z<J/2;Z++){var Y=U[Z];U[Z]=U[J-Z-1],U[J-Z-1]=Y,Y=Q[Z],Q[Z]=-Q[J-Z-1],Q[J-Z-1]=-Y}},x.prototype.normalize13b=function(U,Q){var J=0;for(var Z=0;Z<Q/2;Z++){var Y=Math.round(U[2*Z+1]/Q)*8192+Math.round(U[2*Z]/Q)+J;if(U[Z]=Y&67108863,Y<67108864)J=0;else J=Y/67108864|0}return U},x.prototype.convert13b=function(U,Q,J,Z){var Y=0;for(var K=0;K<Q;K++)Y=Y+(U[K]|0),J[2*K]=Y&8191,Y=Y>>>13,J[2*K+1]=Y&8191,Y=Y>>>13;for(K=2*Q;K<Z;++K)J[K]=0;H(Y===0),H((Y&-8192)===0)},x.prototype.stub=function(U){var Q=Array(U);for(var J=0;J<U;J++)Q[J]=0;return Q},x.prototype.mulp=function(U,Q,J){var Z=2*this.guessLen13b(U.length,Q.length),Y=this.makeRBT(Z),K=this.stub(Z),F=Array(Z),G=Array(Z),X=Array(Z),$=Array(Z),M=Array(Z),A=Array(Z),B=J.words;B.length=Z,this.convert13b(U.words,U.length,F,Z),this.convert13b(Q.words,Q.length,$,Z),this.transform(F,K,G,X,Z,Y),this.transform($,K,M,A,Z,Y);for(var w=0;w<Z;w++){var p=G[w]*M[w]-X[w]*A[w];X[w]=G[w]*A[w]+X[w]*M[w],G[w]=p}return this.conjugate(G,X,Z),this.transform(G,X,B,K,Z,Y),this.conjugate(B,K,Z),this.normalize13b(B,Z),J.negative=U.negative^Q.negative,J.length=U.length+Q.length,J.strip()},V.prototype.mul=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),this.mulTo(U,Q)},V.prototype.mulf=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),v(this,U,Q)},V.prototype.imul=function(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function(U){H(typeof U==="number"),H(U<67108864);var Q=0;for(var J=0;J<this.length;J++){var Z=(this.words[J]|0)*U,Y=(Z&67108863)+(Q&67108863);Q>>=26,Q+=Z/67108864|0,Q+=Y>>>26,this.words[J]=Y&67108863}if(Q!==0)this.words[J]=Q,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function(U){return this.clone().imuln(U)},V.prototype.sqr=function(){return this.mul(this)},V.prototype.isqr=function(){return this.imul(this.clone())},V.prototype.pow=function(U){var Q=q(U);if(Q.length===0)return new V(1);var J=this;for(var Z=0;Z<Q.length;Z++,J=J.sqr())if(Q[Z]!==0)break;if(++Z<Q.length)for(var Y=J.sqr();Z<Q.length;Z++,Y=Y.sqr()){if(Q[Z]===0)continue;J=J.mul(Y)}return J},V.prototype.iushln=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=67108863>>>26-Q<<26-Q,Y;if(Q!==0){var K=0;for(Y=0;Y<this.length;Y++){var F=this.words[Y]&Z,G=(this.words[Y]|0)-F<<Q;this.words[Y]=G|K,K=F>>>26-Q}if(K)this.words[Y]=K,this.length++}if(J!==0){for(Y=this.length-1;Y>=0;Y--)this.words[Y+J]=this.words[Y];for(Y=0;Y<J;Y++)this.words[Y]=0;this.length+=J}return this.strip()},V.prototype.ishln=function(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function(U,Q,J){H(typeof U==="number"&&U>=0);var Z;if(Q)Z=(Q-Q%26)/26;else Z=0;var Y=U%26,K=Math.min((U-Y)/26,this.length),F=67108863^67108863>>>Y<<Y,G=J;if(Z-=K,Z=Math.max(0,Z),G){for(var X=0;X<K;X++)G.words[X]=this.words[X];G.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 $=0;for(X=this.length-1;X>=0&&($!==0||X>=Z);X--){var M=this.words[X]|0;this.words[X]=$<<26-Y|M>>>Y,$=M&F}if(G&&$!==0)G.words[G.length++]=$;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function(U,Q,J){return H(this.negative===0),this.iushrn(U,Q,J)},V.prototype.shln=function(U){return this.clone().ishln(U)},V.prototype.ushln=function(U){return this.clone().iushln(U)},V.prototype.shrn=function(U){return this.clone().ishrn(U)},V.prototype.ushrn=function(U){return this.clone().iushrn(U)},V.prototype.testn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return!1;var Y=this.words[J];return!!(Y&Z)},V.prototype.imaskn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=J)return this;if(Q!==0)J++;if(this.length=Math.min(J,this.length),Q!==0){var Z=67108863^67108863>>>Q<<Q;this.words[this.length-1]&=Z}return this.strip()},V.prototype.maskn=function(U){return this.clone().imaskn(U)},V.prototype.iaddn=function(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(U){this.words[0]+=U;for(var Q=0;Q<this.length&&this.words[Q]>=67108864;Q++)if(this.words[Q]-=67108864,Q===this.length-1)this.words[Q+1]=1;else this.words[Q+1]++;return this.length=Math.max(this.length,Q+1),this},V.prototype.isubn=function(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 Q=0;Q<this.length&&this.words[Q]<0;Q++)this.words[Q]+=67108864,this.words[Q+1]-=1;return this.strip()},V.prototype.addn=function(U){return this.clone().iaddn(U)},V.prototype.subn=function(U){return this.clone().isubn(U)},V.prototype.iabs=function(){return this.negative=0,this},V.prototype.abs=function(){return this.clone().iabs()},V.prototype._ishlnsubmul=function(U,Q,J){var Z=U.length+J,Y;this._expand(Z);var K,F=0;for(Y=0;Y<U.length;Y++){K=(this.words[Y+J]|0)+F;var G=(U.words[Y]|0)*Q;K-=G&67108863,F=(K>>26)-(G/67108864|0),this.words[Y+J]=K&67108863}for(;Y<this.length-J;Y++)K=(this.words[Y+J]|0)+F,F=K>>26,this.words[Y+J]=K&67108863;if(F===0)return this.strip();H(F===-1),F=0;for(Y=0;Y<this.length;Y++)K=-(this.words[Y]|0)+F,F=K>>26,this.words[Y]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function(U,Q){var J=this.length-U.length,Z=this.clone(),Y=U,K=Y.words[Y.length-1]|0,F=this._countBits(K);if(J=26-F,J!==0)Y=Y.ushln(J),Z.iushln(J),K=Y.words[Y.length-1]|0;var G=Z.length-Y.length,X;if(Q!=="mod"){X=new V(null),X.length=G+1,X.words=Array(X.length);for(var $=0;$<X.length;$++)X.words[$]=0}var M=Z.clone()._ishlnsubmul(Y,1,G);if(M.negative===0){if(Z=M,X)X.words[G]=1}for(var A=G-1;A>=0;A--){var B=(Z.words[Y.length+A]|0)*67108864+(Z.words[Y.length+A-1]|0);B=Math.min(B/K|0,67108863),Z._ishlnsubmul(Y,B,A);while(Z.negative!==0)if(B--,Z.negative=0,Z._ishlnsubmul(Y,1,A),!Z.isZero())Z.negative^=1;if(X)X.words[A]=B}if(X)X.strip();if(Z.strip(),Q!=="div"&&J!==0)Z.iushrn(J);return{div:X||null,mod:Z}},V.prototype.divmod=function(U,Q,J){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var Z,Y,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Q),Q!=="mod")Z=K.div.neg();if(Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.iadd(U)}return{div:Z,mod:Y}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Q),Q!=="mod")Z=K.div.neg();return{div:Z,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Q),Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.isub(U)}return{div:K.div,mod:Y}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Q==="div")return{div:this.divn(U.words[0]),mod:null};if(Q==="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,Q)},V.prototype.div=function(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function(U){var Q=this.divmod(U);if(Q.mod.isZero())return Q.div;var J=Q.div.negative!==0?Q.mod.isub(U):Q.mod,Z=U.ushrn(1),Y=U.andln(1),K=J.cmp(Z);if(K<0||Y===1&&K===0)return Q.div;return Q.div.negative!==0?Q.div.isubn(1):Q.div.iaddn(1)},V.prototype.modn=function(U){H(U<=67108863);var Q=67108864%U,J=0;for(var Z=this.length-1;Z>=0;Z--)J=(Q*J+(this.words[Z]|0))%U;return J},V.prototype.idivn=function(U){H(U<=67108863);var Q=0;for(var J=this.length-1;J>=0;J--){var Z=(this.words[J]|0)+Q*67108864;this.words[J]=Z/U|0,Q=Z%U}return this.strip()},V.prototype.divn=function(U){return this.clone().idivn(U)},V.prototype.egcd=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=new V(0),F=new V(1),G=0;while(Q.isEven()&&J.isEven())Q.iushrn(1),J.iushrn(1),++G;var X=J.clone(),$=Q.clone();while(!Q.isZero()){for(var M=0,A=1;(Q.words[0]&A)===0&&M<26;++M,A<<=1);if(M>0){Q.iushrn(M);while(M-- >0){if(Z.isOdd()||Y.isOdd())Z.iadd(X),Y.isub($);Z.iushrn(1),Y.iushrn(1)}}for(var B=0,w=1;(J.words[0]&w)===0&&B<26;++B,w<<=1);if(B>0){J.iushrn(B);while(B-- >0){if(K.isOdd()||F.isOdd())K.iadd(X),F.isub($);K.iushrn(1),F.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(K),Y.isub(F);else J.isub(Q),K.isub(Z),F.isub(Y)}return{a:K,b:F,gcd:J.iushln(G)}},V.prototype._invmp=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=J.clone();while(Q.cmpn(1)>0&&J.cmpn(1)>0){for(var F=0,G=1;(Q.words[0]&G)===0&&F<26;++F,G<<=1);if(F>0){Q.iushrn(F);while(F-- >0){if(Z.isOdd())Z.iadd(K);Z.iushrn(1)}}for(var X=0,$=1;(J.words[0]&$)===0&&X<26;++X,$<<=1);if(X>0){J.iushrn(X);while(X-- >0){if(Y.isOdd())Y.iadd(K);Y.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(Y);else J.isub(Q),Y.isub(Z)}var M;if(Q.cmpn(1)===0)M=Z;else M=Y;if(M.cmpn(0)<0)M.iadd(U);return M},V.prototype.gcd=function(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Q=this.clone(),J=U.clone();Q.negative=0,J.negative=0;for(var Z=0;Q.isEven()&&J.isEven();Z++)Q.iushrn(1),J.iushrn(1);do{while(Q.isEven())Q.iushrn(1);while(J.isEven())J.iushrn(1);var Y=Q.cmp(J);if(Y<0){var K=Q;Q=J,J=K}else if(Y===0||J.cmpn(1)===0)break;Q.isub(J)}while(!0);return J.iushln(Z)},V.prototype.invm=function(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function(){return(this.words[0]&1)===0},V.prototype.isOdd=function(){return(this.words[0]&1)===1},V.prototype.andln=function(U){return this.words[0]&U},V.prototype.bincn=function(U){H(typeof U==="number");var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return this._expand(J+1),this.words[J]|=Z,this;var Y=Z;for(var K=J;Y!==0&&K<this.length;K++){var F=this.words[K]|0;F+=Y,Y=F>>>26,F&=67108863,this.words[K]=F}if(Y!==0)this.words[K]=Y,this.length++;return this},V.prototype.isZero=function(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function(U){var Q=U<0;if(this.negative!==0&&!Q)return-1;if(this.negative===0&&Q)return 1;this.strip();var J;if(this.length>1)J=1;else{if(Q)U=-U;H(U<=67108863,"Number is too big");var Z=this.words[0]|0;J=Z===U?0:Z<U?-1:1}if(this.negative!==0)return-J|0;return J},V.prototype.cmp=function(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Q=this.ucmp(U);if(this.negative!==0)return-Q|0;return Q},V.prototype.ucmp=function(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Q=0;for(var J=this.length-1;J>=0;J--){var Z=this.words[J]|0,Y=U.words[J]|0;if(Z===Y)continue;if(Z<Y)Q=-1;else if(Z>Y)Q=1;break}return Q},V.prototype.gtn=function(U){return this.cmpn(U)===1},V.prototype.gt=function(U){return this.cmp(U)===1},V.prototype.gten=function(U){return this.cmpn(U)>=0},V.prototype.gte=function(U){return this.cmp(U)>=0},V.prototype.ltn=function(U){return this.cmpn(U)===-1},V.prototype.lt=function(U){return this.cmp(U)===-1},V.prototype.lten=function(U){return this.cmpn(U)<=0},V.prototype.lte=function(U){return this.cmp(U)<=0},V.prototype.eqn=function(U){return this.cmpn(U)===0},V.prototype.eq=function(U){return this.cmp(U)===0},V.red=function(U){return new u(U)},V.prototype.toRed=function(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(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function(U){return this.red=U,this},V.prototype.forceRed=function(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function(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(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(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var N={k256:null,p224:null,p192:null,p25519:null};function f(U,Q){this.name=U,this.p=new V(Q,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(){var U=new V(null);return U.words=Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function(U){var Q=U,J;do this.split(Q,this.tmp),Q=this.imulK(Q),Q=Q.iadd(this.tmp),J=Q.bitLength();while(J>this.n);var Z=J<this.n?-1:Q.ucmp(this.p);if(Z===0)Q.words[0]=0,Q.length=1;else if(Z>0)Q.isub(this.p);else if(Q.strip!==void 0)Q.strip();else Q._strip();return Q},f.prototype.split=function(U,Q){U.iushrn(this.n,0,Q)},f.prototype.imulK=function(U){return U.imul(this.k)};function b(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}L(b,f),b.prototype.split=function(U,Q){var J=4194303,Z=Math.min(U.length,9);for(var Y=0;Y<Z;Y++)Q.words[Y]=U.words[Y];if(Q.length=Z,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Q.words[Q.length++]=K&J;for(Y=10;Y<U.length;Y++){var F=U.words[Y]|0;U.words[Y-10]=(F&J)<<4|K>>>22,K=F}if(K>>>=22,U.words[Y-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},b.prototype.imulK=function(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Q=0;for(var J=0;J<U.length;J++){var Z=U.words[J]|0;Q+=Z*977,U.words[J]=Q&67108863,Q=Z*64+(Q/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function Q0(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}L(Q0,f);function G0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}L(G0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}L(Y0,f),Y0.prototype.imulK=function(U){var Q=0;for(var J=0;J<U.length;J++){var Z=(U.words[J]|0)*19+Q,Y=Z&67108863;Z>>>=26,U.words[J]=Y,Q=Z}if(Q!==0)U.words[U.length++]=Q;return U},V._prime=function(U){if(N[U])return N[U];var Q;if(U==="k256")Q=new b;else if(U==="p224")Q=new Q0;else if(U==="p192")Q=new G0;else if(U==="p25519")Q=new Y0;else throw Error("Unknown prime "+U);return N[U]=Q,Q};function u(U){if(typeof U==="string"){var Q=V._prime(U);this.m=Q.p,this.prime=Q}else H(U.gtn(1),"modulus must be greater than 1"),this.m=U,this.prime=null}u.prototype._verify1=function(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function(U,Q){H((U.negative|Q.negative)===0,"red works only with positives"),H(U.red&&U.red===Q.red,"red works only with red numbers")},u.prototype.imod=function(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function(U,Q){this._verify2(U,Q);var J=U.add(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J._forceRed(this)},u.prototype.iadd=function(U,Q){this._verify2(U,Q);var J=U.iadd(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J},u.prototype.sub=function(U,Q){this._verify2(U,Q);var J=U.sub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J._forceRed(this)},u.prototype.isub=function(U,Q){this._verify2(U,Q);var J=U.isub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J},u.prototype.shl=function(U,Q){return this._verify1(U),this.imod(U.ushln(Q))},u.prototype.imul=function(U,Q){return this._verify2(U,Q),this.imod(U.imul(Q))},u.prototype.mul=function(U,Q){return this._verify2(U,Q),this.imod(U.mul(Q))},u.prototype.isqr=function(U){return this.imul(U,U.clone())},u.prototype.sqr=function(U){return this.mul(U,U)},u.prototype.sqrt=function(U){if(U.isZero())return U.clone();var Q=this.m.andln(3);if(H(Q%2===1),Q===3){var J=this.m.add(new V(1)).iushrn(2);return this.pow(U,J)}var Z=this.m.subn(1),Y=0;while(!Z.isZero()&&Z.andln(1)===0)Y++,Z.iushrn(1);H(!Z.isZero());var K=new V(1).toRed(this),F=K.redNeg(),G=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,G).cmp(F)!==0)X.redIAdd(F);var $=this.pow(X,Z),M=this.pow(U,Z.addn(1).iushrn(1)),A=this.pow(U,Z),B=Y;while(A.cmp(K)!==0){var w=A;for(var p=0;w.cmp(K)!==0;p++)w=w.redSqr();H(p<B);var n=this.pow($,new V(1).iushln(B-p-1));M=M.redMul(n),$=n.redSqr(),A=A.redMul($),B=p}return M},u.prototype.invm=function(U){var Q=U._invmp(this.m);if(Q.negative!==0)return Q.negative=0,this.imod(Q).redNeg();else return this.imod(Q)},u.prototype.pow=function(U,Q){if(Q.isZero())return new V(1).toRed(this);if(Q.cmpn(1)===0)return U.clone();var J=4,Z=Array(1<<J);Z[0]=new V(1).toRed(this),Z[1]=U;for(var Y=2;Y<Z.length;Y++)Z[Y]=this.mul(Z[Y-1],U);var K=Z[0],F=0,G=0,X=Q.bitLength()%26;if(X===0)X=26;for(Y=Q.length-1;Y>=0;Y--){var $=Q.words[Y];for(var M=X-1;M>=0;M--){var A=$>>M&1;if(K!==Z[0])K=this.sqr(K);if(A===0&&F===0){G=0;continue}if(F<<=1,F|=A,G++,G!==J&&(Y!==0||M!==0))continue;K=this.mul(K,Z[F]),G=0,F=0}X=26}return K},u.prototype.convertTo=function(U){var Q=U.umod(this.m);return Q===U?Q.clone():Q},u.prototype.convertFrom=function(U){var Q=U.clone();return Q.red=null,Q},V.mont=function(U){return new U0(U)};function U0(U){if(u.call(this,U),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)}L(U0,u),U0.prototype.convertTo=function(U){return this.imod(U.ushln(this.shift))},U0.prototype.convertFrom=function(U){var Q=this.imod(U.mul(this.rinv));return Q.red=null,Q},U0.prototype.imul=function(U,Q){if(U.isZero()||Q.isZero())return U.words[0]=0,U.length=1,U;var J=U.imul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.mul=function(U,Q){if(U.isZero()||Q.isZero())return new V(0)._forceRed(this);var J=U.mul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.invm=function(U){var Q=this.imod(U._invmp(this.m).mul(this.r2));return Q._forceRed(this)}})(typeof O>"u"||O,I)}),kV=I0((I,O)=>{var W=SV(),T=PV();O.exports=function(P){return new L(P)};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 L(P){if(this.curveType=H[P],!this.curveType)this.curveType={name:P};this.curve=new W.ec(this.curveType.name),this.keys=void 0}L.prototype.generateKeys=function(P,S){return this.keys=this.curve.genKeyPair(),this.getPublicKey(P,S)},L.prototype.computeSecret=function(P,S,E){if(S=S||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,S);var C=this.curve.keyFromPublic(P).getPublic(),D=C.mul(this.keys.getPrivate()).getX();return V(D,E,this.curveType.byteLength)},L.prototype.getPublicKey=function(P,S){var E=this.keys.getPublic(S==="compressed",!0);if(S==="hybrid")if(E[E.length-1]%2)E[0]=7;else E[0]=6;return V(E,P)},L.prototype.getPrivateKey=function(P){return V(this.keys.getPrivate(),P)},L.prototype.setPublicKey=function(P,S){if(S=S||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,S);return this.keys._importPublic(P),this},L.prototype.setPrivateKey=function(P,S){if(S=S||"utf8",!Buffer.isBuffer(P))P=new Buffer(P,S);var E=new T(P);return E=E.toString(16),this.keys=this.curve.genKeyPair(),this.keys._importPrivate(E),this};function V(P,S,E){if(!Array.isArray(P))P=P.toArray();var C=new Buffer(P);if(E&&C.length<E){var D=new Buffer(E-C.length);D.fill(0),C=Buffer.concat([D,C])}if(!S)return C;else return C.toString(S)}}),jV=I0((I,O)=>{var W=(qU(),h0(RU)).createECDH;O.exports=W||kV()}),vV=I0((I,O)=>{(function(W,T){function H(U,Q){if(!U)throw Error(Q||"Assertion failed")}function L(U,Q){U.super_=Q;var J=function(){};J.prototype=Q.prototype,U.prototype=new J,U.prototype.constructor=U}function V(U,Q,J){if(V.isBN(U))return U;if(this.negative=0,this.words=null,this.length=0,this.red=null,U!==null){if(Q==="le"||Q==="be")J=Q,Q=10;this._init(U||0,Q||10,J||"be")}}if(typeof W==="object")W.exports=V;else T.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window<"u"&&typeof window.Buffer<"u")P=window.Buffer;else P=(HU(),h0(WU)).Buffer}catch(U){}V.isBN=function(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(U,Q){if(U.cmp(Q)>0)return U;return Q},V.min=function(U,Q){if(U.cmp(Q)<0)return U;return Q},V.prototype._init=function(U,Q,J){if(typeof U==="number")return this._initNumber(U,Q,J);if(typeof U==="object")return this._initArray(U,Q,J);if(Q==="hex")Q=16;H(Q===(Q|0)&&Q>=2&&Q<=36),U=U.toString().replace(/\s+/g,"");var Z=0;if(U[0]==="-")Z++,this.negative=1;if(Z<U.length){if(Q===16)this._parseHex(U,Z,J);else if(this._parseBase(U,Q,Z),J==="le")this._initArray(this.toArray(),Q,J)}},V.prototype._initNumber=function(U,Q,J){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(J!=="le")return;this._initArray(this.toArray(),Q,J)},V.prototype._initArray=function(U,Q,J){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=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y,K,F=0;if(J==="be"){for(Z=U.length-1,Y=0;Z>=0;Z-=3)if(K=U[Z]|U[Z-1]<<8|U[Z-2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}else if(J==="le"){for(Z=0,Y=0;Z<U.length;Z+=3)if(K=U[Z]|U[Z+1]<<8|U[Z+2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}return this.strip()};function S(U,Q){var J=U.charCodeAt(Q);if(J>=65&&J<=70)return J-55;else if(J>=97&&J<=102)return J-87;else return J-48&15}function E(U,Q,J){var Z=S(U,J);if(J-1>=Q)Z|=S(U,J-1)<<4;return Z}V.prototype._parseHex=function(U,Q,J){this.length=Math.ceil((U.length-Q)/6),this.words=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y=0,K=0,F;if(J==="be")for(Z=U.length-1;Z>=Q;Z-=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8;else{var G=U.length-Q;for(Z=G%2===0?Q+1:Q;Z<U.length;Z+=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8}this.strip()};function C(U,Q,J,Z){var Y=0,K=Math.min(U.length,J);for(var F=Q;F<K;F++){var G=U.charCodeAt(F)-48;if(Y*=Z,G>=49)Y+=G-49+10;else if(G>=17)Y+=G-17+10;else Y+=G}return Y}V.prototype._parseBase=function(U,Q,J){this.words=[0],this.length=1;for(var Z=0,Y=1;Y<=67108863;Y*=Q)Z++;Z--,Y=Y/Q|0;var K=U.length-J,F=K%Z,G=Math.min(K,K-F)+J,X=0;for(var $=J;$<G;$+=Z)if(X=C(U,$,$+Z,Q),this.imuln(Y),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(F!==0){var M=1;X=C(U,$,U.length,Q);for($=0;$<F;$++)M*=Q;if(this.imuln(M),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function(U){U.words=Array(this.length);for(var Q=0;Q<this.length;Q++)U.words[Q]=this.words[Q];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function(){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"],z=[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],R=[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(U,Q){U=U||10,Q=Q|0||1;var J;if(U===16||U==="hex"){J="";var Z=0,Y=0;for(var K=0;K<this.length;K++){var F=this.words[K],G=((F<<Z|Y)&16777215).toString(16);if(Y=F>>>24-Z&16777215,Z+=2,Z>=26)Z-=26,K--;if(Y!==0||K!==this.length-1)J=D[6-G.length]+G+J;else J=G+J}if(Y!==0)J=Y.toString(16)+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}if(U===(U|0)&&U>=2&&U<=36){var X=z[U],$=R[U];J="";var M=this.clone();M.negative=0;while(!M.isZero()){var A=M.modn($).toString(U);if(M=M.idivn($),!M.isZero())J=D[X-A.length]+A+J;else J=A+J}if(this.isZero())J="0"+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function(){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(){return this.toString(16)},V.prototype.toBuffer=function(U,Q){return H(typeof P<"u"),this.toArrayLike(P,U,Q)},V.prototype.toArray=function(U,Q){return this.toArrayLike(Array,U,Q)},V.prototype.toArrayLike=function(U,Q,J){var Z=this.byteLength(),Y=J||Math.max(1,Z);H(Z<=Y,"byte array longer than desired length"),H(Y>0,"Requested array length <= 0"),this.strip();var K=Q==="le",F=new U(Y),G,X,$=this.clone();if(!K){for(X=0;X<Y-Z;X++)F[X]=0;for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[Y-X-1]=G}else{for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[X]=G;for(;X<Y;X++)F[X]=0}return F},Math.clz32)V.prototype._countBits=function(U){return 32-Math.clz32(U)};else V.prototype._countBits=function(U){var Q=U,J=0;if(Q>=4096)J+=13,Q>>>=13;if(Q>=64)J+=7,Q>>>=7;if(Q>=8)J+=4,Q>>>=4;if(Q>=2)J+=2,Q>>>=2;return J+Q};V.prototype._zeroBits=function(U){if(U===0)return 26;var Q=U,J=0;if((Q&8191)===0)J+=13,Q>>>=13;if((Q&127)===0)J+=7,Q>>>=7;if((Q&15)===0)J+=4,Q>>>=4;if((Q&3)===0)J+=2,Q>>>=2;if((Q&1)===0)J++;return J},V.prototype.bitLength=function(){var U=this.words[this.length-1],Q=this._countBits(U);return(this.length-1)*26+Q};function q(U){var Q=Array(U.bitLength());for(var J=0;J<Q.length;J++){var Z=J/26|0,Y=J%26;Q[J]=(U.words[Z]&1<<Y)>>>Y}return Q}V.prototype.zeroBits=function(){if(this.isZero())return 0;var U=0;for(var Q=0;Q<this.length;Q++){var J=this._zeroBits(this.words[Q]);if(U+=J,J!==26)break}return U},V.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function(){return this.negative!==0},V.prototype.neg=function(){return this.clone().ineg()},V.prototype.ineg=function(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function(U){while(this.length<U.length)this.words[this.length++]=0;for(var Q=0;Q<U.length;Q++)this.words[Q]=this.words[Q]|U.words[Q];return this.strip()},V.prototype.ior=function(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function(U){var Q;if(this.length>U.length)Q=U;else Q=this;for(var J=0;J<Q.length;J++)this.words[J]=this.words[J]&U.words[J];return this.length=Q.length,this.strip()},V.prototype.iand=function(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function(U){var Q,J;if(this.length>U.length)Q=this,J=U;else Q=U,J=this;for(var Z=0;Z<J.length;Z++)this.words[Z]=Q.words[Z]^J.words[Z];if(this!==Q)for(;Z<Q.length;Z++)this.words[Z]=Q.words[Z];return this.length=Q.length,this.strip()},V.prototype.ixor=function(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function(U){H(typeof U==="number"&&U>=0);var Q=Math.ceil(U/26)|0,J=U%26;if(this._expand(Q),J>0)Q--;for(var Z=0;Z<Q;Z++)this.words[Z]=~this.words[Z]&67108863;if(J>0)this.words[Z]=~this.words[Z]&67108863>>26-J;return this.strip()},V.prototype.notn=function(U){return this.clone().inotn(U)},V.prototype.setn=function(U,Q){H(typeof U==="number"&&U>=0);var J=U/26|0,Z=U%26;if(this._expand(J+1),Q)this.words[J]=this.words[J]|1<<Z;else this.words[J]=this.words[J]&~(1<<Z);return this.strip()},V.prototype.iadd=function(U){var Q;if(this.negative!==0&&U.negative===0)return this.negative=0,Q=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Q=this.isub(U),U.negative=1,Q._normSign();var J,Z;if(this.length>U.length)J=this,Z=U;else J=U,Z=this;var Y=0;for(var K=0;K<Z.length;K++)Q=(J.words[K]|0)+(Z.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;for(;Y!==0&&K<J.length;K++)Q=(J.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;if(this.length=J.length,Y!==0)this.words[this.length]=Y,this.length++;else if(J!==this)for(;K<J.length;K++)this.words[K]=J.words[K];return this},V.prototype.add=function(U){var Q;if(U.negative!==0&&this.negative===0)return U.negative=0,Q=this.sub(U),U.negative^=1,Q;else if(U.negative===0&&this.negative!==0)return this.negative=0,Q=U.sub(this),this.negative=1,Q;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function(U){if(U.negative!==0){U.negative=0;var Q=this.iadd(U);return U.negative=1,Q._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var J=this.cmp(U);if(J===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Z,Y;if(J>0)Z=this,Y=U;else Z=U,Y=this;var K=0;for(var F=0;F<Y.length;F++)Q=(Z.words[F]|0)-(Y.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;for(;K!==0&&F<Z.length;F++)Q=(Z.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;if(K===0&&F<Z.length&&Z!==this)for(;F<Z.length;F++)this.words[F]=Z.words[F];if(this.length=Math.max(this.length,F),Z!==this)this.negative=1;return this.strip()},V.prototype.sub=function(U){return this.clone().isub(U)};function _(U,Q,J){J.negative=Q.negative^U.negative;var Z=U.length+Q.length|0;J.length=Z,Z=Z-1|0;var Y=U.words[0]|0,K=Q.words[0]|0,F=Y*K,G=F&67108863,X=F/67108864|0;J.words[0]=G;for(var $=1;$<Z;$++){var M=X>>>26,A=X&67108863,B=Math.min($,Q.length-1);for(var w=Math.max(0,$-U.length+1);w<=B;w++){var p=$-w|0;Y=U.words[p]|0,K=Q.words[w]|0,F=Y*K+A,M+=F/67108864|0,A=F&67108863}J.words[$]=A|0,X=M|0}if(X!==0)J.words[$]=X|0;else J.length--;return J.strip()}var k=function(U,Q,J){var Z=U.words,Y=Q.words,K=J.words,F=0,G,X,$,M=Z[0]|0,A=M&8191,B=M>>>13,w=Z[1]|0,p=w&8191,n=w>>>13,K0=Z[2]|0,r=K0&8191,d=K0>>>13,J0=Z[3]|0,m=J0&8191,i=J0>>>13,g0=Z[4]|0,y=g0&8191,h=g0>>>13,V0=Z[5]|0,t=V0&8191,e=V0>>>13,E0=Z[6]|0,c=E0&8191,o=E0>>>13,N0=Z[7]|0,s=N0&8191,Z0=N0>>>13,f0=Z[8]|0,W0=f0&8191,H0=f0>>>13,n0=Z[9]|0,O0=n0&8191,D0=n0>>>13,t0=Y[0]|0,z0=t0&8191,A0=t0>>>13,AU=Y[1]|0,L0=AU&8191,k0=AU>>>13,zU=Y[2]|0,j0=zU&8191,M0=zU>>>13,DU=Y[3]|0,v0=DU&8191,R0=DU>>>13,KU=Y[4]|0,_0=KU&8191,B0=KU>>>13,OU=Y[5]|0,q0=OU&8191,g=OU>>>13,l=Y[6]|0,a=l&8191,X0=l>>>13,w0=Y[7]|0,F0=w0&8191,T0=w0>>>13,m0=Y[8]|0,S0=m0&8191,x0=m0>>>13,TU=Y[9]|0,P0=TU&8191,C0=TU>>>13;J.negative=U.negative^Q.negative,J.length=19,G=Math.imul(A,z0),X=Math.imul(A,A0),X=X+Math.imul(B,z0)|0,$=Math.imul(B,A0);var s0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(s0>>>26)|0,s0&=67108863,G=Math.imul(p,z0),X=Math.imul(p,A0),X=X+Math.imul(n,z0)|0,$=Math.imul(n,A0),G=G+Math.imul(A,L0)|0,X=X+Math.imul(A,k0)|0,X=X+Math.imul(B,L0)|0,$=$+Math.imul(B,k0)|0;var c0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(c0>>>26)|0,c0&=67108863,G=Math.imul(r,z0),X=Math.imul(r,A0),X=X+Math.imul(d,z0)|0,$=Math.imul(d,A0),G=G+Math.imul(p,L0)|0,X=X+Math.imul(p,k0)|0,X=X+Math.imul(n,L0)|0,$=$+Math.imul(n,k0)|0,G=G+Math.imul(A,j0)|0,X=X+Math.imul(A,M0)|0,X=X+Math.imul(B,j0)|0,$=$+Math.imul(B,M0)|0;var y0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(y0>>>26)|0,y0&=67108863,G=Math.imul(m,z0),X=Math.imul(m,A0),X=X+Math.imul(i,z0)|0,$=Math.imul(i,A0),G=G+Math.imul(r,L0)|0,X=X+Math.imul(r,k0)|0,X=X+Math.imul(d,L0)|0,$=$+Math.imul(d,k0)|0,G=G+Math.imul(p,j0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(n,j0)|0,$=$+Math.imul(n,M0)|0,G=G+Math.imul(A,v0)|0,X=X+Math.imul(A,R0)|0,X=X+Math.imul(B,v0)|0,$=$+Math.imul(B,R0)|0;var l0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(l0>>>26)|0,l0&=67108863,G=Math.imul(y,z0),X=Math.imul(y,A0),X=X+Math.imul(h,z0)|0,$=Math.imul(h,A0),G=G+Math.imul(m,L0)|0,X=X+Math.imul(m,k0)|0,X=X+Math.imul(i,L0)|0,$=$+Math.imul(i,k0)|0,G=G+Math.imul(r,j0)|0,X=X+Math.imul(r,M0)|0,X=X+Math.imul(d,j0)|0,$=$+Math.imul(d,M0)|0,G=G+Math.imul(p,v0)|0,X=X+Math.imul(p,R0)|0,X=X+Math.imul(n,v0)|0,$=$+Math.imul(n,R0)|0,G=G+Math.imul(A,_0)|0,X=X+Math.imul(A,B0)|0,X=X+Math.imul(B,_0)|0,$=$+Math.imul(B,B0)|0;var b0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,G=Math.imul(t,z0),X=Math.imul(t,A0),X=X+Math.imul(e,z0)|0,$=Math.imul(e,A0),G=G+Math.imul(y,L0)|0,X=X+Math.imul(y,k0)|0,X=X+Math.imul(h,L0)|0,$=$+Math.imul(h,k0)|0,G=G+Math.imul(m,j0)|0,X=X+Math.imul(m,M0)|0,X=X+Math.imul(i,j0)|0,$=$+Math.imul(i,M0)|0,G=G+Math.imul(r,v0)|0,X=X+Math.imul(r,R0)|0,X=X+Math.imul(d,v0)|0,$=$+Math.imul(d,R0)|0,G=G+Math.imul(p,_0)|0,X=X+Math.imul(p,B0)|0,X=X+Math.imul(n,_0)|0,$=$+Math.imul(n,B0)|0,G=G+Math.imul(A,q0)|0,X=X+Math.imul(A,g)|0,X=X+Math.imul(B,q0)|0,$=$+Math.imul(B,g)|0;var r0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(r0>>>26)|0,r0&=67108863,G=Math.imul(c,z0),X=Math.imul(c,A0),X=X+Math.imul(o,z0)|0,$=Math.imul(o,A0),G=G+Math.imul(t,L0)|0,X=X+Math.imul(t,k0)|0,X=X+Math.imul(e,L0)|0,$=$+Math.imul(e,k0)|0,G=G+Math.imul(y,j0)|0,X=X+Math.imul(y,M0)|0,X=X+Math.imul(h,j0)|0,$=$+Math.imul(h,M0)|0,G=G+Math.imul(m,v0)|0,X=X+Math.imul(m,R0)|0,X=X+Math.imul(i,v0)|0,$=$+Math.imul(i,R0)|0,G=G+Math.imul(r,_0)|0,X=X+Math.imul(r,B0)|0,X=X+Math.imul(d,_0)|0,$=$+Math.imul(d,B0)|0,G=G+Math.imul(p,q0)|0,X=X+Math.imul(p,g)|0,X=X+Math.imul(n,q0)|0,$=$+Math.imul(n,g)|0,G=G+Math.imul(A,a)|0,X=X+Math.imul(A,X0)|0,X=X+Math.imul(B,a)|0,$=$+Math.imul(B,X0)|0;var a0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,G=Math.imul(s,z0),X=Math.imul(s,A0),X=X+Math.imul(Z0,z0)|0,$=Math.imul(Z0,A0),G=G+Math.imul(c,L0)|0,X=X+Math.imul(c,k0)|0,X=X+Math.imul(o,L0)|0,$=$+Math.imul(o,k0)|0,G=G+Math.imul(t,j0)|0,X=X+Math.imul(t,M0)|0,X=X+Math.imul(e,j0)|0,$=$+Math.imul(e,M0)|0,G=G+Math.imul(y,v0)|0,X=X+Math.imul(y,R0)|0,X=X+Math.imul(h,v0)|0,$=$+Math.imul(h,R0)|0,G=G+Math.imul(m,_0)|0,X=X+Math.imul(m,B0)|0,X=X+Math.imul(i,_0)|0,$=$+Math.imul(i,B0)|0,G=G+Math.imul(r,q0)|0,X=X+Math.imul(r,g)|0,X=X+Math.imul(d,q0)|0,$=$+Math.imul(d,g)|0,G=G+Math.imul(p,a)|0,X=X+Math.imul(p,X0)|0,X=X+Math.imul(n,a)|0,$=$+Math.imul(n,X0)|0,G=G+Math.imul(A,F0)|0,X=X+Math.imul(A,T0)|0,X=X+Math.imul(B,F0)|0,$=$+Math.imul(B,T0)|0;var e0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,G=Math.imul(W0,z0),X=Math.imul(W0,A0),X=X+Math.imul(H0,z0)|0,$=Math.imul(H0,A0),G=G+Math.imul(s,L0)|0,X=X+Math.imul(s,k0)|0,X=X+Math.imul(Z0,L0)|0,$=$+Math.imul(Z0,k0)|0,G=G+Math.imul(c,j0)|0,X=X+Math.imul(c,M0)|0,X=X+Math.imul(o,j0)|0,$=$+Math.imul(o,M0)|0,G=G+Math.imul(t,v0)|0,X=X+Math.imul(t,R0)|0,X=X+Math.imul(e,v0)|0,$=$+Math.imul(e,R0)|0,G=G+Math.imul(y,_0)|0,X=X+Math.imul(y,B0)|0,X=X+Math.imul(h,_0)|0,$=$+Math.imul(h,B0)|0,G=G+Math.imul(m,q0)|0,X=X+Math.imul(m,g)|0,X=X+Math.imul(i,q0)|0,$=$+Math.imul(i,g)|0,G=G+Math.imul(r,a)|0,X=X+Math.imul(r,X0)|0,X=X+Math.imul(d,a)|0,$=$+Math.imul(d,X0)|0,G=G+Math.imul(p,F0)|0,X=X+Math.imul(p,T0)|0,X=X+Math.imul(n,F0)|0,$=$+Math.imul(n,T0)|0,G=G+Math.imul(A,S0)|0,X=X+Math.imul(A,x0)|0,X=X+Math.imul(B,S0)|0,$=$+Math.imul(B,x0)|0;var i0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,G=Math.imul(O0,z0),X=Math.imul(O0,A0),X=X+Math.imul(D0,z0)|0,$=Math.imul(D0,A0),G=G+Math.imul(W0,L0)|0,X=X+Math.imul(W0,k0)|0,X=X+Math.imul(H0,L0)|0,$=$+Math.imul(H0,k0)|0,G=G+Math.imul(s,j0)|0,X=X+Math.imul(s,M0)|0,X=X+Math.imul(Z0,j0)|0,$=$+Math.imul(Z0,M0)|0,G=G+Math.imul(c,v0)|0,X=X+Math.imul(c,R0)|0,X=X+Math.imul(o,v0)|0,$=$+Math.imul(o,R0)|0,G=G+Math.imul(t,_0)|0,X=X+Math.imul(t,B0)|0,X=X+Math.imul(e,_0)|0,$=$+Math.imul(e,B0)|0,G=G+Math.imul(y,q0)|0,X=X+Math.imul(y,g)|0,X=X+Math.imul(h,q0)|0,$=$+Math.imul(h,g)|0,G=G+Math.imul(m,a)|0,X=X+Math.imul(m,X0)|0,X=X+Math.imul(i,a)|0,$=$+Math.imul(i,X0)|0,G=G+Math.imul(r,F0)|0,X=X+Math.imul(r,T0)|0,X=X+Math.imul(d,F0)|0,$=$+Math.imul(d,T0)|0,G=G+Math.imul(p,S0)|0,X=X+Math.imul(p,x0)|0,X=X+Math.imul(n,S0)|0,$=$+Math.imul(n,x0)|0,G=G+Math.imul(A,P0)|0,X=X+Math.imul(A,C0)|0,X=X+Math.imul(B,P0)|0,$=$+Math.imul(B,C0)|0;var UU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,G=Math.imul(O0,L0),X=Math.imul(O0,k0),X=X+Math.imul(D0,L0)|0,$=Math.imul(D0,k0),G=G+Math.imul(W0,j0)|0,X=X+Math.imul(W0,M0)|0,X=X+Math.imul(H0,j0)|0,$=$+Math.imul(H0,M0)|0,G=G+Math.imul(s,v0)|0,X=X+Math.imul(s,R0)|0,X=X+Math.imul(Z0,v0)|0,$=$+Math.imul(Z0,R0)|0,G=G+Math.imul(c,_0)|0,X=X+Math.imul(c,B0)|0,X=X+Math.imul(o,_0)|0,$=$+Math.imul(o,B0)|0,G=G+Math.imul(t,q0)|0,X=X+Math.imul(t,g)|0,X=X+Math.imul(e,q0)|0,$=$+Math.imul(e,g)|0,G=G+Math.imul(y,a)|0,X=X+Math.imul(y,X0)|0,X=X+Math.imul(h,a)|0,$=$+Math.imul(h,X0)|0,G=G+Math.imul(m,F0)|0,X=X+Math.imul(m,T0)|0,X=X+Math.imul(i,F0)|0,$=$+Math.imul(i,T0)|0,G=G+Math.imul(r,S0)|0,X=X+Math.imul(r,x0)|0,X=X+Math.imul(d,S0)|0,$=$+Math.imul(d,x0)|0,G=G+Math.imul(p,P0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(n,P0)|0,$=$+Math.imul(n,C0)|0;var XU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,G=Math.imul(O0,j0),X=Math.imul(O0,M0),X=X+Math.imul(D0,j0)|0,$=Math.imul(D0,M0),G=G+Math.imul(W0,v0)|0,X=X+Math.imul(W0,R0)|0,X=X+Math.imul(H0,v0)|0,$=$+Math.imul(H0,R0)|0,G=G+Math.imul(s,_0)|0,X=X+Math.imul(s,B0)|0,X=X+Math.imul(Z0,_0)|0,$=$+Math.imul(Z0,B0)|0,G=G+Math.imul(c,q0)|0,X=X+Math.imul(c,g)|0,X=X+Math.imul(o,q0)|0,$=$+Math.imul(o,g)|0,G=G+Math.imul(t,a)|0,X=X+Math.imul(t,X0)|0,X=X+Math.imul(e,a)|0,$=$+Math.imul(e,X0)|0,G=G+Math.imul(y,F0)|0,X=X+Math.imul(y,T0)|0,X=X+Math.imul(h,F0)|0,$=$+Math.imul(h,T0)|0,G=G+Math.imul(m,S0)|0,X=X+Math.imul(m,x0)|0,X=X+Math.imul(i,S0)|0,$=$+Math.imul(i,x0)|0,G=G+Math.imul(r,P0)|0,X=X+Math.imul(r,C0)|0,X=X+Math.imul(d,P0)|0,$=$+Math.imul(d,C0)|0;var ZU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,G=Math.imul(O0,v0),X=Math.imul(O0,R0),X=X+Math.imul(D0,v0)|0,$=Math.imul(D0,R0),G=G+Math.imul(W0,_0)|0,X=X+Math.imul(W0,B0)|0,X=X+Math.imul(H0,_0)|0,$=$+Math.imul(H0,B0)|0,G=G+Math.imul(s,q0)|0,X=X+Math.imul(s,g)|0,X=X+Math.imul(Z0,q0)|0,$=$+Math.imul(Z0,g)|0,G=G+Math.imul(c,a)|0,X=X+Math.imul(c,X0)|0,X=X+Math.imul(o,a)|0,$=$+Math.imul(o,X0)|0,G=G+Math.imul(t,F0)|0,X=X+Math.imul(t,T0)|0,X=X+Math.imul(e,F0)|0,$=$+Math.imul(e,T0)|0,G=G+Math.imul(y,S0)|0,X=X+Math.imul(y,x0)|0,X=X+Math.imul(h,S0)|0,$=$+Math.imul(h,x0)|0,G=G+Math.imul(m,P0)|0,X=X+Math.imul(m,C0)|0,X=X+Math.imul(i,P0)|0,$=$+Math.imul(i,C0)|0;var QU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,G=Math.imul(O0,_0),X=Math.imul(O0,B0),X=X+Math.imul(D0,_0)|0,$=Math.imul(D0,B0),G=G+Math.imul(W0,q0)|0,X=X+Math.imul(W0,g)|0,X=X+Math.imul(H0,q0)|0,$=$+Math.imul(H0,g)|0,G=G+Math.imul(s,a)|0,X=X+Math.imul(s,X0)|0,X=X+Math.imul(Z0,a)|0,$=$+Math.imul(Z0,X0)|0,G=G+Math.imul(c,F0)|0,X=X+Math.imul(c,T0)|0,X=X+Math.imul(o,F0)|0,$=$+Math.imul(o,T0)|0,G=G+Math.imul(t,S0)|0,X=X+Math.imul(t,x0)|0,X=X+Math.imul(e,S0)|0,$=$+Math.imul(e,x0)|0,G=G+Math.imul(y,P0)|0,X=X+Math.imul(y,C0)|0,X=X+Math.imul(h,P0)|0,$=$+Math.imul(h,C0)|0;var YU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,G=Math.imul(O0,q0),X=Math.imul(O0,g),X=X+Math.imul(D0,q0)|0,$=Math.imul(D0,g),G=G+Math.imul(W0,a)|0,X=X+Math.imul(W0,X0)|0,X=X+Math.imul(H0,a)|0,$=$+Math.imul(H0,X0)|0,G=G+Math.imul(s,F0)|0,X=X+Math.imul(s,T0)|0,X=X+Math.imul(Z0,F0)|0,$=$+Math.imul(Z0,T0)|0,G=G+Math.imul(c,S0)|0,X=X+Math.imul(c,x0)|0,X=X+Math.imul(o,S0)|0,$=$+Math.imul(o,x0)|0,G=G+Math.imul(t,P0)|0,X=X+Math.imul(t,C0)|0,X=X+Math.imul(e,P0)|0,$=$+Math.imul(e,C0)|0;var JU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(JU>>>26)|0,JU&=67108863,G=Math.imul(O0,a),X=Math.imul(O0,X0),X=X+Math.imul(D0,a)|0,$=Math.imul(D0,X0),G=G+Math.imul(W0,F0)|0,X=X+Math.imul(W0,T0)|0,X=X+Math.imul(H0,F0)|0,$=$+Math.imul(H0,T0)|0,G=G+Math.imul(s,S0)|0,X=X+Math.imul(s,x0)|0,X=X+Math.imul(Z0,S0)|0,$=$+Math.imul(Z0,x0)|0,G=G+Math.imul(c,P0)|0,X=X+Math.imul(c,C0)|0,X=X+Math.imul(o,P0)|0,$=$+Math.imul(o,C0)|0;var VU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,G=Math.imul(O0,F0),X=Math.imul(O0,T0),X=X+Math.imul(D0,F0)|0,$=Math.imul(D0,T0),G=G+Math.imul(W0,S0)|0,X=X+Math.imul(W0,x0)|0,X=X+Math.imul(H0,S0)|0,$=$+Math.imul(H0,x0)|0,G=G+Math.imul(s,P0)|0,X=X+Math.imul(s,C0)|0,X=X+Math.imul(Z0,P0)|0,$=$+Math.imul(Z0,C0)|0;var GU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,G=Math.imul(O0,S0),X=Math.imul(O0,x0),X=X+Math.imul(D0,S0)|0,$=Math.imul(D0,x0),G=G+Math.imul(W0,P0)|0,X=X+Math.imul(W0,C0)|0,X=X+Math.imul(H0,P0)|0,$=$+Math.imul(H0,C0)|0;var IU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,G=Math.imul(O0,P0),X=Math.imul(O0,C0),X=X+Math.imul(D0,P0)|0,$=Math.imul(D0,C0);var $U=(F+G|0)+((X&8191)<<13)|0;if(F=($+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,K[0]=s0,K[1]=c0,K[2]=y0,K[3]=l0,K[4]=b0,K[5]=r0,K[6]=a0,K[7]=e0,K[8]=i0,K[9]=UU,K[10]=XU,K[11]=ZU,K[12]=QU,K[13]=YU,K[14]=JU,K[15]=VU,K[16]=GU,K[17]=IU,K[18]=$U,F!==0)K[19]=F,J.length++;return J};if(!Math.imul)k=_;function j(U,Q,J){J.negative=Q.negative^U.negative,J.length=U.length+Q.length;var Z=0,Y=0;for(var K=0;K<J.length-1;K++){var F=Y;Y=0;var G=Z&67108863,X=Math.min(K,Q.length-1);for(var $=Math.max(0,K-U.length+1);$<=X;$++){var M=K-$,A=U.words[M]|0,B=Q.words[$]|0,w=A*B,p=w&67108863;F=F+(w/67108864|0)|0,p=p+G|0,G=p&67108863,F=F+(p>>>26)|0,Y+=F>>>26,F&=67108863}J.words[K]=G,Z=F,F=Y}if(Z!==0)J.words[K]=Z;else J.length--;return J.strip()}function v(U,Q,J){var Z=new x;return Z.mulp(U,Q,J)}V.prototype.mulTo=function(U,Q){var J,Z=this.length+U.length;if(this.length===10&&U.length===10)J=k(this,U,Q);else if(Z<63)J=_(this,U,Q);else if(Z<1024)J=j(this,U,Q);else J=v(this,U,Q);return J};function x(U,Q){this.x=U,this.y=Q}x.prototype.makeRBT=function(U){var Q=Array(U),J=V.prototype._countBits(U)-1;for(var Z=0;Z<U;Z++)Q[Z]=this.revBin(Z,J,U);return Q},x.prototype.revBin=function(U,Q,J){if(U===0||U===J-1)return U;var Z=0;for(var Y=0;Y<Q;Y++)Z|=(U&1)<<Q-Y-1,U>>=1;return Z},x.prototype.permute=function(U,Q,J,Z,Y,K){for(var F=0;F<K;F++)Z[F]=Q[U[F]],Y[F]=J[U[F]]},x.prototype.transform=function(U,Q,J,Z,Y,K){this.permute(K,U,Q,J,Z,Y);for(var F=1;F<Y;F<<=1){var G=F<<1,X=Math.cos(2*Math.PI/G),$=Math.sin(2*Math.PI/G);for(var M=0;M<Y;M+=G){var A=X,B=$;for(var w=0;w<F;w++){var p=J[M+w],n=Z[M+w],K0=J[M+w+F],r=Z[M+w+F],d=A*K0-B*r;if(r=A*r+B*K0,K0=d,J[M+w]=p+K0,Z[M+w]=n+r,J[M+w+F]=p-K0,Z[M+w+F]=n-r,w!==G)d=X*A-$*B,B=X*B+$*A,A=d}}}},x.prototype.guessLen13b=function(U,Q){var J=Math.max(Q,U)|1,Z=J&1,Y=0;for(J=J/2|0;J;J=J>>>1)Y++;return 1<<Y+1+Z},x.prototype.conjugate=function(U,Q,J){if(J<=1)return;for(var Z=0;Z<J/2;Z++){var Y=U[Z];U[Z]=U[J-Z-1],U[J-Z-1]=Y,Y=Q[Z],Q[Z]=-Q[J-Z-1],Q[J-Z-1]=-Y}},x.prototype.normalize13b=function(U,Q){var J=0;for(var Z=0;Z<Q/2;Z++){var Y=Math.round(U[2*Z+1]/Q)*8192+Math.round(U[2*Z]/Q)+J;if(U[Z]=Y&67108863,Y<67108864)J=0;else J=Y/67108864|0}return U},x.prototype.convert13b=function(U,Q,J,Z){var Y=0;for(var K=0;K<Q;K++)Y=Y+(U[K]|0),J[2*K]=Y&8191,Y=Y>>>13,J[2*K+1]=Y&8191,Y=Y>>>13;for(K=2*Q;K<Z;++K)J[K]=0;H(Y===0),H((Y&-8192)===0)},x.prototype.stub=function(U){var Q=Array(U);for(var J=0;J<U;J++)Q[J]=0;return Q},x.prototype.mulp=function(U,Q,J){var Z=2*this.guessLen13b(U.length,Q.length),Y=this.makeRBT(Z),K=this.stub(Z),F=Array(Z),G=Array(Z),X=Array(Z),$=Array(Z),M=Array(Z),A=Array(Z),B=J.words;B.length=Z,this.convert13b(U.words,U.length,F,Z),this.convert13b(Q.words,Q.length,$,Z),this.transform(F,K,G,X,Z,Y),this.transform($,K,M,A,Z,Y);for(var w=0;w<Z;w++){var p=G[w]*M[w]-X[w]*A[w];X[w]=G[w]*A[w]+X[w]*M[w],G[w]=p}return this.conjugate(G,X,Z),this.transform(G,X,B,K,Z,Y),this.conjugate(B,K,Z),this.normalize13b(B,Z),J.negative=U.negative^Q.negative,J.length=U.length+Q.length,J.strip()},V.prototype.mul=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),this.mulTo(U,Q)},V.prototype.mulf=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),v(this,U,Q)},V.prototype.imul=function(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function(U){H(typeof U==="number"),H(U<67108864);var Q=0;for(var J=0;J<this.length;J++){var Z=(this.words[J]|0)*U,Y=(Z&67108863)+(Q&67108863);Q>>=26,Q+=Z/67108864|0,Q+=Y>>>26,this.words[J]=Y&67108863}if(Q!==0)this.words[J]=Q,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function(U){return this.clone().imuln(U)},V.prototype.sqr=function(){return this.mul(this)},V.prototype.isqr=function(){return this.imul(this.clone())},V.prototype.pow=function(U){var Q=q(U);if(Q.length===0)return new V(1);var J=this;for(var Z=0;Z<Q.length;Z++,J=J.sqr())if(Q[Z]!==0)break;if(++Z<Q.length)for(var Y=J.sqr();Z<Q.length;Z++,Y=Y.sqr()){if(Q[Z]===0)continue;J=J.mul(Y)}return J},V.prototype.iushln=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=67108863>>>26-Q<<26-Q,Y;if(Q!==0){var K=0;for(Y=0;Y<this.length;Y++){var F=this.words[Y]&Z,G=(this.words[Y]|0)-F<<Q;this.words[Y]=G|K,K=F>>>26-Q}if(K)this.words[Y]=K,this.length++}if(J!==0){for(Y=this.length-1;Y>=0;Y--)this.words[Y+J]=this.words[Y];for(Y=0;Y<J;Y++)this.words[Y]=0;this.length+=J}return this.strip()},V.prototype.ishln=function(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function(U,Q,J){H(typeof U==="number"&&U>=0);var Z;if(Q)Z=(Q-Q%26)/26;else Z=0;var Y=U%26,K=Math.min((U-Y)/26,this.length),F=67108863^67108863>>>Y<<Y,G=J;if(Z-=K,Z=Math.max(0,Z),G){for(var X=0;X<K;X++)G.words[X]=this.words[X];G.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 $=0;for(X=this.length-1;X>=0&&($!==0||X>=Z);X--){var M=this.words[X]|0;this.words[X]=$<<26-Y|M>>>Y,$=M&F}if(G&&$!==0)G.words[G.length++]=$;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function(U,Q,J){return H(this.negative===0),this.iushrn(U,Q,J)},V.prototype.shln=function(U){return this.clone().ishln(U)},V.prototype.ushln=function(U){return this.clone().iushln(U)},V.prototype.shrn=function(U){return this.clone().ishrn(U)},V.prototype.ushrn=function(U){return this.clone().iushrn(U)},V.prototype.testn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return!1;var Y=this.words[J];return!!(Y&Z)},V.prototype.imaskn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=J)return this;if(Q!==0)J++;if(this.length=Math.min(J,this.length),Q!==0){var Z=67108863^67108863>>>Q<<Q;this.words[this.length-1]&=Z}return this.strip()},V.prototype.maskn=function(U){return this.clone().imaskn(U)},V.prototype.iaddn=function(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(U){this.words[0]+=U;for(var Q=0;Q<this.length&&this.words[Q]>=67108864;Q++)if(this.words[Q]-=67108864,Q===this.length-1)this.words[Q+1]=1;else this.words[Q+1]++;return this.length=Math.max(this.length,Q+1),this},V.prototype.isubn=function(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 Q=0;Q<this.length&&this.words[Q]<0;Q++)this.words[Q]+=67108864,this.words[Q+1]-=1;return this.strip()},V.prototype.addn=function(U){return this.clone().iaddn(U)},V.prototype.subn=function(U){return this.clone().isubn(U)},V.prototype.iabs=function(){return this.negative=0,this},V.prototype.abs=function(){return this.clone().iabs()},V.prototype._ishlnsubmul=function(U,Q,J){var Z=U.length+J,Y;this._expand(Z);var K,F=0;for(Y=0;Y<U.length;Y++){K=(this.words[Y+J]|0)+F;var G=(U.words[Y]|0)*Q;K-=G&67108863,F=(K>>26)-(G/67108864|0),this.words[Y+J]=K&67108863}for(;Y<this.length-J;Y++)K=(this.words[Y+J]|0)+F,F=K>>26,this.words[Y+J]=K&67108863;if(F===0)return this.strip();H(F===-1),F=0;for(Y=0;Y<this.length;Y++)K=-(this.words[Y]|0)+F,F=K>>26,this.words[Y]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function(U,Q){var J=this.length-U.length,Z=this.clone(),Y=U,K=Y.words[Y.length-1]|0,F=this._countBits(K);if(J=26-F,J!==0)Y=Y.ushln(J),Z.iushln(J),K=Y.words[Y.length-1]|0;var G=Z.length-Y.length,X;if(Q!=="mod"){X=new V(null),X.length=G+1,X.words=Array(X.length);for(var $=0;$<X.length;$++)X.words[$]=0}var M=Z.clone()._ishlnsubmul(Y,1,G);if(M.negative===0){if(Z=M,X)X.words[G]=1}for(var A=G-1;A>=0;A--){var B=(Z.words[Y.length+A]|0)*67108864+(Z.words[Y.length+A-1]|0);B=Math.min(B/K|0,67108863),Z._ishlnsubmul(Y,B,A);while(Z.negative!==0)if(B--,Z.negative=0,Z._ishlnsubmul(Y,1,A),!Z.isZero())Z.negative^=1;if(X)X.words[A]=B}if(X)X.strip();if(Z.strip(),Q!=="div"&&J!==0)Z.iushrn(J);return{div:X||null,mod:Z}},V.prototype.divmod=function(U,Q,J){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var Z,Y,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Q),Q!=="mod")Z=K.div.neg();if(Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.iadd(U)}return{div:Z,mod:Y}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Q),Q!=="mod")Z=K.div.neg();return{div:Z,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Q),Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.isub(U)}return{div:K.div,mod:Y}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Q==="div")return{div:this.divn(U.words[0]),mod:null};if(Q==="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,Q)},V.prototype.div=function(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function(U){var Q=this.divmod(U);if(Q.mod.isZero())return Q.div;var J=Q.div.negative!==0?Q.mod.isub(U):Q.mod,Z=U.ushrn(1),Y=U.andln(1),K=J.cmp(Z);if(K<0||Y===1&&K===0)return Q.div;return Q.div.negative!==0?Q.div.isubn(1):Q.div.iaddn(1)},V.prototype.modn=function(U){H(U<=67108863);var Q=67108864%U,J=0;for(var Z=this.length-1;Z>=0;Z--)J=(Q*J+(this.words[Z]|0))%U;return J},V.prototype.idivn=function(U){H(U<=67108863);var Q=0;for(var J=this.length-1;J>=0;J--){var Z=(this.words[J]|0)+Q*67108864;this.words[J]=Z/U|0,Q=Z%U}return this.strip()},V.prototype.divn=function(U){return this.clone().idivn(U)},V.prototype.egcd=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=new V(0),F=new V(1),G=0;while(Q.isEven()&&J.isEven())Q.iushrn(1),J.iushrn(1),++G;var X=J.clone(),$=Q.clone();while(!Q.isZero()){for(var M=0,A=1;(Q.words[0]&A)===0&&M<26;++M,A<<=1);if(M>0){Q.iushrn(M);while(M-- >0){if(Z.isOdd()||Y.isOdd())Z.iadd(X),Y.isub($);Z.iushrn(1),Y.iushrn(1)}}for(var B=0,w=1;(J.words[0]&w)===0&&B<26;++B,w<<=1);if(B>0){J.iushrn(B);while(B-- >0){if(K.isOdd()||F.isOdd())K.iadd(X),F.isub($);K.iushrn(1),F.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(K),Y.isub(F);else J.isub(Q),K.isub(Z),F.isub(Y)}return{a:K,b:F,gcd:J.iushln(G)}},V.prototype._invmp=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=J.clone();while(Q.cmpn(1)>0&&J.cmpn(1)>0){for(var F=0,G=1;(Q.words[0]&G)===0&&F<26;++F,G<<=1);if(F>0){Q.iushrn(F);while(F-- >0){if(Z.isOdd())Z.iadd(K);Z.iushrn(1)}}for(var X=0,$=1;(J.words[0]&$)===0&&X<26;++X,$<<=1);if(X>0){J.iushrn(X);while(X-- >0){if(Y.isOdd())Y.iadd(K);Y.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(Y);else J.isub(Q),Y.isub(Z)}var M;if(Q.cmpn(1)===0)M=Z;else M=Y;if(M.cmpn(0)<0)M.iadd(U);return M},V.prototype.gcd=function(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Q=this.clone(),J=U.clone();Q.negative=0,J.negative=0;for(var Z=0;Q.isEven()&&J.isEven();Z++)Q.iushrn(1),J.iushrn(1);do{while(Q.isEven())Q.iushrn(1);while(J.isEven())J.iushrn(1);var Y=Q.cmp(J);if(Y<0){var K=Q;Q=J,J=K}else if(Y===0||J.cmpn(1)===0)break;Q.isub(J)}while(!0);return J.iushln(Z)},V.prototype.invm=function(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function(){return(this.words[0]&1)===0},V.prototype.isOdd=function(){return(this.words[0]&1)===1},V.prototype.andln=function(U){return this.words[0]&U},V.prototype.bincn=function(U){H(typeof U==="number");var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return this._expand(J+1),this.words[J]|=Z,this;var Y=Z;for(var K=J;Y!==0&&K<this.length;K++){var F=this.words[K]|0;F+=Y,Y=F>>>26,F&=67108863,this.words[K]=F}if(Y!==0)this.words[K]=Y,this.length++;return this},V.prototype.isZero=function(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function(U){var Q=U<0;if(this.negative!==0&&!Q)return-1;if(this.negative===0&&Q)return 1;this.strip();var J;if(this.length>1)J=1;else{if(Q)U=-U;H(U<=67108863,"Number is too big");var Z=this.words[0]|0;J=Z===U?0:Z<U?-1:1}if(this.negative!==0)return-J|0;return J},V.prototype.cmp=function(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Q=this.ucmp(U);if(this.negative!==0)return-Q|0;return Q},V.prototype.ucmp=function(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Q=0;for(var J=this.length-1;J>=0;J--){var Z=this.words[J]|0,Y=U.words[J]|0;if(Z===Y)continue;if(Z<Y)Q=-1;else if(Z>Y)Q=1;break}return Q},V.prototype.gtn=function(U){return this.cmpn(U)===1},V.prototype.gt=function(U){return this.cmp(U)===1},V.prototype.gten=function(U){return this.cmpn(U)>=0},V.prototype.gte=function(U){return this.cmp(U)>=0},V.prototype.ltn=function(U){return this.cmpn(U)===-1},V.prototype.lt=function(U){return this.cmp(U)===-1},V.prototype.lten=function(U){return this.cmpn(U)<=0},V.prototype.lte=function(U){return this.cmp(U)<=0},V.prototype.eqn=function(U){return this.cmpn(U)===0},V.prototype.eq=function(U){return this.cmp(U)===0},V.red=function(U){return new u(U)},V.prototype.toRed=function(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(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function(U){return this.red=U,this},V.prototype.forceRed=function(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function(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(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(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var N={k256:null,p224:null,p192:null,p25519:null};function f(U,Q){this.name=U,this.p=new V(Q,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(){var U=new V(null);return U.words=Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function(U){var Q=U,J;do this.split(Q,this.tmp),Q=this.imulK(Q),Q=Q.iadd(this.tmp),J=Q.bitLength();while(J>this.n);var Z=J<this.n?-1:Q.ucmp(this.p);if(Z===0)Q.words[0]=0,Q.length=1;else if(Z>0)Q.isub(this.p);else if(Q.strip!==void 0)Q.strip();else Q._strip();return Q},f.prototype.split=function(U,Q){U.iushrn(this.n,0,Q)},f.prototype.imulK=function(U){return U.imul(this.k)};function b(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}L(b,f),b.prototype.split=function(U,Q){var J=4194303,Z=Math.min(U.length,9);for(var Y=0;Y<Z;Y++)Q.words[Y]=U.words[Y];if(Q.length=Z,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Q.words[Q.length++]=K&J;for(Y=10;Y<U.length;Y++){var F=U.words[Y]|0;U.words[Y-10]=(F&J)<<4|K>>>22,K=F}if(K>>>=22,U.words[Y-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},b.prototype.imulK=function(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Q=0;for(var J=0;J<U.length;J++){var Z=U.words[J]|0;Q+=Z*977,U.words[J]=Q&67108863,Q=Z*64+(Q/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function Q0(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}L(Q0,f);function G0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}L(G0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}L(Y0,f),Y0.prototype.imulK=function(U){var Q=0;for(var J=0;J<U.length;J++){var Z=(U.words[J]|0)*19+Q,Y=Z&67108863;Z>>>=26,U.words[J]=Y,Q=Z}if(Q!==0)U.words[U.length++]=Q;return U},V._prime=function(U){if(N[U])return N[U];var Q;if(U==="k256")Q=new b;else if(U==="p224")Q=new Q0;else if(U==="p192")Q=new G0;else if(U==="p25519")Q=new Y0;else throw Error("Unknown prime "+U);return N[U]=Q,Q};function u(U){if(typeof U==="string"){var Q=V._prime(U);this.m=Q.p,this.prime=Q}else H(U.gtn(1),"modulus must be greater than 1"),this.m=U,this.prime=null}u.prototype._verify1=function(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function(U,Q){H((U.negative|Q.negative)===0,"red works only with positives"),H(U.red&&U.red===Q.red,"red works only with red numbers")},u.prototype.imod=function(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function(U,Q){this._verify2(U,Q);var J=U.add(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J._forceRed(this)},u.prototype.iadd=function(U,Q){this._verify2(U,Q);var J=U.iadd(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J},u.prototype.sub=function(U,Q){this._verify2(U,Q);var J=U.sub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J._forceRed(this)},u.prototype.isub=function(U,Q){this._verify2(U,Q);var J=U.isub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J},u.prototype.shl=function(U,Q){return this._verify1(U),this.imod(U.ushln(Q))},u.prototype.imul=function(U,Q){return this._verify2(U,Q),this.imod(U.imul(Q))},u.prototype.mul=function(U,Q){return this._verify2(U,Q),this.imod(U.mul(Q))},u.prototype.isqr=function(U){return this.imul(U,U.clone())},u.prototype.sqr=function(U){return this.mul(U,U)},u.prototype.sqrt=function(U){if(U.isZero())return U.clone();var Q=this.m.andln(3);if(H(Q%2===1),Q===3){var J=this.m.add(new V(1)).iushrn(2);return this.pow(U,J)}var Z=this.m.subn(1),Y=0;while(!Z.isZero()&&Z.andln(1)===0)Y++,Z.iushrn(1);H(!Z.isZero());var K=new V(1).toRed(this),F=K.redNeg(),G=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,G).cmp(F)!==0)X.redIAdd(F);var $=this.pow(X,Z),M=this.pow(U,Z.addn(1).iushrn(1)),A=this.pow(U,Z),B=Y;while(A.cmp(K)!==0){var w=A;for(var p=0;w.cmp(K)!==0;p++)w=w.redSqr();H(p<B);var n=this.pow($,new V(1).iushln(B-p-1));M=M.redMul(n),$=n.redSqr(),A=A.redMul($),B=p}return M},u.prototype.invm=function(U){var Q=U._invmp(this.m);if(Q.negative!==0)return Q.negative=0,this.imod(Q).redNeg();else return this.imod(Q)},u.prototype.pow=function(U,Q){if(Q.isZero())return new V(1).toRed(this);if(Q.cmpn(1)===0)return U.clone();var J=4,Z=Array(1<<J);Z[0]=new V(1).toRed(this),Z[1]=U;for(var Y=2;Y<Z.length;Y++)Z[Y]=this.mul(Z[Y-1],U);var K=Z[0],F=0,G=0,X=Q.bitLength()%26;if(X===0)X=26;for(Y=Q.length-1;Y>=0;Y--){var $=Q.words[Y];for(var M=X-1;M>=0;M--){var A=$>>M&1;if(K!==Z[0])K=this.sqr(K);if(A===0&&F===0){G=0;continue}if(F<<=1,F|=A,G++,G!==J&&(Y!==0||M!==0))continue;K=this.mul(K,Z[F]),G=0,F=0}X=26}return K},u.prototype.convertTo=function(U){var Q=U.umod(this.m);return Q===U?Q.clone():Q},u.prototype.convertFrom=function(U){var Q=U.clone();return Q.red=null,Q},V.mont=function(U){return new U0(U)};function U0(U){if(u.call(this,U),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)}L(U0,u),U0.prototype.convertTo=function(U){return this.imod(U.ushln(this.shift))},U0.prototype.convertFrom=function(U){var Q=this.imod(U.mul(this.rinv));return Q.red=null,Q},U0.prototype.imul=function(U,Q){if(U.isZero()||Q.isZero())return U.words[0]=0,U.length=1,U;var J=U.imul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.mul=function(U,Q){if(U.isZero()||Q.isZero())return new V(0)._forceRed(this);var J=U.mul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.invm=function(U){var Q=this.imod(U._invmp(this.m).mul(this.r2));return Q._forceRed(this)}})(typeof O>"u"||O,I)}),_V=I0((I)=>{var O=IX(),W=SU(),T=I;T.define=function(L,V){return new H(L,V)};function H(L,V){this.name=L,this.body=V,this.decoders={},this.encoders={}}H.prototype._createNamed=function(L){var V;try{V=(()=>{throw new Error("Cannot require module "+"vm");})().runInThisContext("(function "+this.name+`(entity) {
|
|
12
|
+
this._initNamed(entity);
|
|
13
|
+
})`)}catch(P){V=function(S){this._initNamed(S)}}return W(V,L),V.prototype._initNamed=function(P){L.call(this,P)},new V(this)},H.prototype._getDecoder=function(L){if(L=L||"der",!this.decoders.hasOwnProperty(L))this.decoders[L]=this._createNamed(O.decoders[L]);return this.decoders[L]},H.prototype.decode=function(L,V,P){return this._getDecoder(V).decode(L,P)},H.prototype._getEncoder=function(L){if(L=L||"der",!this.encoders.hasOwnProperty(L))this.encoders[L]=this._createNamed(O.encoders[L]);return this.encoders[L]},H.prototype.encode=function(L,V,P){return this._getEncoder(V).encode(L,P)}}),BV=I0((I)=>{var O=SU();function W(H){this._reporterState={obj:null,path:[],options:H||{},errors:[]}}I.Reporter=W,W.prototype.isError=function(H){return H instanceof T},W.prototype.save=function(){var H=this._reporterState;return{obj:H.obj,pathLen:H.path.length}},W.prototype.restore=function(H){var L=this._reporterState;L.obj=H.obj,L.path=L.path.slice(0,H.pathLen)},W.prototype.enterKey=function(H){return this._reporterState.path.push(H)},W.prototype.exitKey=function(H){var L=this._reporterState;L.path=L.path.slice(0,H-1)},W.prototype.leaveKey=function(H,L,V){var P=this._reporterState;if(this.exitKey(H),P.obj!==null)P.obj[L]=V},W.prototype.path=function(){return this._reporterState.path.join("/")},W.prototype.enterObject=function(){var H=this._reporterState,L=H.obj;return H.obj={},L},W.prototype.leaveObject=function(H){var L=this._reporterState,V=L.obj;return L.obj=H,V},W.prototype.error=function(H){var L,V=this._reporterState,P=H instanceof T;if(P)L=H;else L=new T(V.path.map(function(S){return"["+JSON.stringify(S)+"]"}).join(""),H.message||H,H.stack);if(!V.options.partial)throw L;if(!P)V.errors.push(L);return L},W.prototype.wrapResult=function(H){var L=this._reporterState;if(!L.options.partial)return H;return{result:this.isError(H)?null:H,errors:L.errors}};function T(H,L){this.path=H,this.rethrow(L)}O(T,Error),T.prototype.rethrow=function(H){if(this.message=H+" at: "+(this.path||"(shallow)"),Error.captureStackTrace)Error.captureStackTrace(this,T);if(!this.stack)try{throw Error(this.message)}catch(L){this.stack=L.stack}return this}}),zQ=I0((I)=>{var O=SU(),W=QX().Reporter,T=(HU(),h0(WU)).Buffer;function H(V,P){if(W.call(this,P),!T.isBuffer(V)){this.error("Input not Buffer");return}this.base=V,this.offset=0,this.length=V.length}O(H,W),I.DecoderBuffer=H,H.prototype.save=function(){return{offset:this.offset,reporter:W.prototype.save.call(this)}},H.prototype.restore=function(V){var P=new H(this.base);return P.offset=V.offset,P.length=this.offset,this.offset=V.offset,W.prototype.restore.call(this,V.reporter),P},H.prototype.isEmpty=function(){return this.offset===this.length},H.prototype.readUInt8=function(V){if(this.offset+1<=this.length)return this.base.readUInt8(this.offset++,!0);else return this.error(V||"DecoderBuffer overrun")},H.prototype.skip=function(V,P){if(!(this.offset+V<=this.length))return this.error(P||"DecoderBuffer overrun");var S=new H(this.base);return S._reporterState=this._reporterState,S.offset=this.offset,S.length=this.offset+V,this.offset+=V,S},H.prototype.raw=function(V){return this.base.slice(V?V.offset:this.offset,this.length)};function L(V,P){if(Array.isArray(V))this.length=0,this.value=V.map(function(S){if(!(S instanceof L))S=new L(S,P);return this.length+=S.length,S},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=T.byteLength(V);else if(T.isBuffer(V))this.value=V,this.length=V.length;else return P.error("Unsupported type: "+typeof V)}I.EncoderBuffer=L,L.prototype.join=function(V,P){if(!V)V=new T(this.length);if(!P)P=0;if(this.length===0)return V;if(Array.isArray(this.value))this.value.forEach(function(S){S.join(V,P),P+=S.length});else{if(typeof this.value==="number")V[P]=this.value;else if(typeof this.value==="string")V.write(this.value,P);else if(T.isBuffer(this.value))this.value.copy(V,P);P+=this.length}return V}}),xV=I0((I,O)=>{var W=QX().Reporter,T=QX().EncoderBuffer,H=QX().DecoderBuffer,L=cU(),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),S=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function E(D,z){var R={};if(this._baseState=R,R.enc=D,R.parent=z||null,R.children=null,R.tag=null,R.args=null,R.reverseArgs=null,R.choice=null,R.optional=!1,R.any=!1,R.obj=!1,R.use=null,R.useDecoder=null,R.key=null,R.default=null,R.explicit=null,R.implicit=null,R.contains=null,!R.parent)R.children=[],this._wrap()}O.exports=E;var C=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];E.prototype.clone=function(){var D=this._baseState,z={};C.forEach(function(q){z[q]=D[q]});var R=new this.constructor(z.parent);return R._baseState=z,R},E.prototype._wrap=function(){var D=this._baseState;P.forEach(function(z){this[z]=function(){var R=new this.constructor(this);return D.children.push(R),R[z].apply(R,arguments)}},this)},E.prototype._init=function(D){var z=this._baseState;L(z.parent===null),D.call(this),z.children=z.children.filter(function(R){return R._baseState.parent===this},this),L.equal(z.children.length,1,"Root node can have only one child")},E.prototype._useArgs=function(D){var z=this._baseState,R=D.filter(function(q){return q instanceof this.constructor},this);if(D=D.filter(function(q){return!(q instanceof this.constructor)},this),R.length!==0)L(z.children===null),z.children=R,R.forEach(function(q){q._baseState.parent=this},this);if(D.length!==0)L(z.args===null),z.args=D,z.reverseArgs=D.map(function(q){if(typeof q!=="object"||q.constructor!==Object)return q;var _={};return Object.keys(q).forEach(function(k){if(k==(k|0))k|=0;var j=q[k];_[j]=k}),_})},S.forEach(function(D){E.prototype[D]=function(){var z=this._baseState;throw Error(D+" not implemented for encoding: "+z.enc)}}),V.forEach(function(D){E.prototype[D]=function(){var z=this._baseState,R=Array.prototype.slice.call(arguments);return L(z.tag===null),z.tag=D,this._useArgs(R),this}}),E.prototype.use=function(D){L(D);var z=this._baseState;return L(z.use===null),z.use=D,this},E.prototype.optional=function(){var D=this._baseState;return D.optional=!0,this},E.prototype.def=function(D){var z=this._baseState;return L(z.default===null),z.default=D,z.optional=!0,this},E.prototype.explicit=function(D){var z=this._baseState;return L(z.explicit===null&&z.implicit===null),z.explicit=D,this},E.prototype.implicit=function(D){var z=this._baseState;return L(z.explicit===null&&z.implicit===null),z.implicit=D,this},E.prototype.obj=function(){var D=this._baseState,z=Array.prototype.slice.call(arguments);if(D.obj=!0,z.length!==0)this._useArgs(z);return this},E.prototype.key=function(D){var z=this._baseState;return L(z.key===null),z.key=D,this},E.prototype.any=function(){var D=this._baseState;return D.any=!0,this},E.prototype.choice=function(D){var z=this._baseState;return L(z.choice===null),z.choice=D,this._useArgs(Object.keys(D).map(function(R){return D[R]})),this},E.prototype.contains=function(D){var z=this._baseState;return L(z.use===null),z.contains=D,this},E.prototype._decode=function(D,z){var R=this._baseState;if(R.parent===null)return D.wrapResult(R.children[0]._decode(D,z));var q=R.default,_=!0,k=null;if(R.key!==null)k=D.enterKey(R.key);if(R.optional){var j=null;if(R.explicit!==null)j=R.explicit;else if(R.implicit!==null)j=R.implicit;else if(R.tag!==null)j=R.tag;if(j===null&&!R.any){var v=D.save();try{if(R.choice===null)this._decodeGeneric(R.tag,D,z);else this._decodeChoice(D,z);_=!0}catch(G0){_=!1}D.restore(v)}else if(_=this._peekTag(D,j,R.any),D.isError(_))return _}var x;if(R.obj&&_)x=D.enterObject();if(_){if(R.explicit!==null){var N=this._decodeTag(D,R.explicit);if(D.isError(N))return N;D=N}var f=D.offset;if(R.use===null&&R.choice===null){if(R.any)var v=D.save();var b=this._decodeTag(D,R.implicit!==null?R.implicit:R.tag,R.any);if(D.isError(b))return b;if(R.any)q=D.raw(v);else D=b}if(z&&z.track&&R.tag!==null)z.track(D.path(),f,D.length,"tagged");if(z&&z.track&&R.tag!==null)z.track(D.path(),D.offset,D.length,"content");if(R.any)q=q;else if(R.choice===null)q=this._decodeGeneric(R.tag,D,z);else q=this._decodeChoice(D,z);if(D.isError(q))return q;if(!R.any&&R.choice===null&&R.children!==null)R.children.forEach(function(G0){G0._decode(D,z)});if(R.contains&&(R.tag==="octstr"||R.tag==="bitstr")){var Q0=new H(q);q=this._getUse(R.contains,D._reporterState.obj)._decode(Q0,z)}}if(R.obj&&_)q=D.leaveObject(x);if(R.key!==null&&(q!==null||_===!0))D.leaveKey(k,R.key,q);else if(k!==null)D.exitKey(k);return q},E.prototype._decodeGeneric=function(D,z,R){var q=this._baseState;if(D==="seq"||D==="set")return null;if(D==="seqof"||D==="setof")return this._decodeList(z,D,q.args[0],R);else if(/str$/.test(D))return this._decodeStr(z,D,R);else if(D==="objid"&&q.args)return this._decodeObjid(z,q.args[0],q.args[1],R);else if(D==="objid")return this._decodeObjid(z,null,null,R);else if(D==="gentime"||D==="utctime")return this._decodeTime(z,D,R);else if(D==="null_")return this._decodeNull(z,R);else if(D==="bool")return this._decodeBool(z,R);else if(D==="objDesc")return this._decodeStr(z,D,R);else if(D==="int"||D==="enum")return this._decodeInt(z,q.args&&q.args[0],R);if(q.use!==null)return this._getUse(q.use,z._reporterState.obj)._decode(z,R);else return z.error("unknown tag: "+D)},E.prototype._getUse=function(D,z){var R=this._baseState;if(R.useDecoder=this._use(D,z),L(R.useDecoder._baseState.parent===null),R.useDecoder=R.useDecoder._baseState.children[0],R.implicit!==R.useDecoder._baseState.implicit)R.useDecoder=R.useDecoder.clone(),R.useDecoder._baseState.implicit=R.implicit;return R.useDecoder},E.prototype._decodeChoice=function(D,z){var R=this._baseState,q=null,_=!1;if(Object.keys(R.choice).some(function(k){var j=D.save(),v=R.choice[k];try{var x=v._decode(D,z);if(D.isError(x))return!1;q={type:k,value:x},_=!0}catch(N){return D.restore(j),!1}return!0},this),!_)return D.error("Choice not matched");return q},E.prototype._createEncoderBuffer=function(D){return new T(D,this.reporter)},E.prototype._encode=function(D,z,R){var q=this._baseState;if(q.default!==null&&q.default===D)return;var _=this._encodeValue(D,z,R);if(_===void 0)return;if(this._skipDefault(_,z,R))return;return _},E.prototype._encodeValue=function(D,z,R){var q=this._baseState;if(q.parent===null)return q.children[0]._encode(D,z||new W);var v=null;if(this.reporter=z,q.optional&&D===void 0)if(q.default!==null)D=q.default;else return;var _=null,k=!1;if(q.any)v=this._createEncoderBuffer(D);else if(q.choice)v=this._encodeChoice(D,z);else if(q.contains)_=this._getUse(q.contains,R)._encode(D,z),k=!0;else if(q.children)_=q.children.map(function(f){if(f._baseState.tag==="null_")return f._encode(null,z,D);if(f._baseState.key===null)return z.error("Child should have a key");var b=z.enterKey(f._baseState.key);if(typeof D!=="object")return z.error("Child expected, but input is not object");var Q0=f._encode(D[f._baseState.key],z,D);return z.leaveKey(b),Q0},this).filter(function(f){return f}),_=this._createEncoderBuffer(_);else if(q.tag==="seqof"||q.tag==="setof"){if(!(q.args&&q.args.length===1))return z.error("Too many args for : "+q.tag);if(!Array.isArray(D))return z.error("seqof/setof, but data is not Array");var j=this.clone();j._baseState.implicit=null,_=this._createEncoderBuffer(D.map(function(f){var b=this._baseState;return this._getUse(b.args[0],D)._encode(f,z)},j))}else if(q.use!==null)v=this._getUse(q.use,R)._encode(D,z);else _=this._encodePrimitive(q.tag,D),k=!0;var v;if(!q.any&&q.choice===null){var x=q.implicit!==null?q.implicit:q.tag,N=q.implicit===null?"universal":"context";if(x===null){if(q.use===null)z.error("Tag could be omitted only for .use()")}else if(q.use===null)v=this._encodeComposite(x,k,N,_)}if(q.explicit!==null)v=this._encodeComposite(q.explicit,!1,"context",v);return v},E.prototype._encodeChoice=function(D,z){var R=this._baseState,q=R.choice[D.type];if(!q)L(!1,D.type+" not found in "+JSON.stringify(Object.keys(R.choice)));return q._encode(D.value,z)},E.prototype._encodePrimitive=function(D,z){var R=this._baseState;if(/str$/.test(D))return this._encodeStr(z,D);else if(D==="objid"&&R.args)return this._encodeObjid(z,R.reverseArgs[0],R.args[1]);else if(D==="objid")return this._encodeObjid(z,null,null);else if(D==="gentime"||D==="utctime")return this._encodeTime(z,D);else if(D==="null_")return this._encodeNull();else if(D==="int"||D==="enum")return this._encodeInt(z,R.args&&R.reverseArgs[0]);else if(D==="bool")return this._encodeBool(z);else if(D==="objDesc")return this._encodeStr(z,D);else throw Error("Unsupported tag: "+D)},E.prototype._isNumstr=function(D){return/^[0-9 ]*$/.test(D)},E.prototype._isPrintstr=function(D){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(D)}}),QX=I0((I)=>{var O=I;O.Reporter=BV().Reporter,O.DecoderBuffer=zQ().DecoderBuffer,O.EncoderBuffer=zQ().EncoderBuffer,O.Node=xV()}),NV=I0((I)=>{var O=cQ();I.tagClass={0:"universal",1:"application",2:"context",3:"private"},I.tagClassByName=O._reverse(I.tagClass),I.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"},I.tagByName=O._reverse(I.tag)}),cQ=I0((I)=>{var O=I;O._reverse=function(W){var T={};return Object.keys(W).forEach(function(H){if((H|0)==H)H=H|0;var L=W[H];T[L]=H}),T},O.der=NV()}),pQ=I0((I,O)=>{var W=SU(),T=IX(),H=T.base,L=T.bignum,V=T.constants.der;function P(D){this.enc="der",this.name=D.name,this.entity=D,this.tree=new S,this.tree._init(D.body)}O.exports=P,P.prototype.decode=function(D,z){if(!(D instanceof H.DecoderBuffer))D=new H.DecoderBuffer(D,z);return this.tree._decode(D,z)};function S(D){H.Node.call(this,"der",D)}W(S,H.Node),S.prototype._peekTag=function(D,z,R){if(D.isEmpty())return!1;var q=D.save(),_=E(D,'Failed to peek tag: "'+z+'"');if(D.isError(_))return _;return D.restore(q),_.tag===z||_.tagStr===z||_.tagStr+"of"===z||R},S.prototype._decodeTag=function(D,z,R){var q=E(D,'Failed to decode tag of "'+z+'"');if(D.isError(q))return q;var _=C(D,q.primitive,'Failed to get length of "'+z+'"');if(D.isError(_))return _;if(!R&&q.tag!==z&&q.tagStr!==z&&q.tagStr+"of"!==z)return D.error('Failed to match tag: "'+z+'"');if(q.primitive||_!==null)return D.skip(_,'Failed to match body of: "'+z+'"');var k=D.save(),j=this._skipUntilEnd(D,'Failed to skip indefinite length body: "'+this.tag+'"');if(D.isError(j))return j;return _=D.offset-k.offset,D.restore(k),D.skip(_,'Failed to match body of: "'+z+'"')},S.prototype._skipUntilEnd=function(D,z){while(!0){var R=E(D,z);if(D.isError(R))return R;var q=C(D,R.primitive,z);if(D.isError(q))return q;var _;if(R.primitive||q!==null)_=D.skip(q);else _=this._skipUntilEnd(D,z);if(D.isError(_))return _;if(R.tagStr==="end")break}},S.prototype._decodeList=function(D,z,R,q){var _=[];while(!D.isEmpty()){var k=this._peekTag(D,"end");if(D.isError(k))return k;var j=R.decode(D,"der",q);if(D.isError(j)&&k)break;_.push(j)}return _},S.prototype._decodeStr=function(D,z){if(z==="bitstr"){var R=D.readUInt8();if(D.isError(R))return R;return{unused:R,data:D.raw()}}else if(z==="bmpstr"){var q=D.raw();if(q.length%2===1)return D.error("Decoding of string type: bmpstr length mismatch");var _="";for(var k=0;k<q.length/2;k++)_+=String.fromCharCode(q.readUInt16BE(k*2));return _}else if(z==="numstr"){var j=D.raw().toString("ascii");if(!this._isNumstr(j))return D.error("Decoding of string type: numstr unsupported characters");return j}else if(z==="octstr")return D.raw();else if(z==="objDesc")return D.raw();else if(z==="printstr"){var v=D.raw().toString("ascii");if(!this._isPrintstr(v))return D.error("Decoding of string type: printstr unsupported characters");return v}else if(/str$/.test(z))return D.raw().toString();else return D.error("Decoding of string type: "+z+" unsupported")},S.prototype._decodeObjid=function(D,z,R){var q,_=[],k=0;while(!D.isEmpty()){var j=D.readUInt8();if(k<<=7,k|=j&127,(j&128)===0)_.push(k),k=0}if(j&128)_.push(k);var v=_[0]/40|0,x=_[0]%40;if(R)q=_;else q=[v,x].concat(_.slice(1));if(z){var N=z[q.join(" ")];if(N===void 0)N=z[q.join(".")];if(N!==void 0)q=N}return q},S.prototype._decodeTime=function(D,z){var R=D.raw().toString();if(z==="gentime")var q=R.slice(0,4)|0,_=R.slice(4,6)|0,k=R.slice(6,8)|0,j=R.slice(8,10)|0,v=R.slice(10,12)|0,x=R.slice(12,14)|0;else if(z==="utctime"){var q=R.slice(0,2)|0,_=R.slice(2,4)|0,k=R.slice(4,6)|0,j=R.slice(6,8)|0,v=R.slice(8,10)|0,x=R.slice(10,12)|0;if(q<70)q=2000+q;else q=1900+q}else return D.error("Decoding "+z+" time is not supported yet");return Date.UTC(q,_-1,k,j,v,x,0)},S.prototype._decodeNull=function(D){return null},S.prototype._decodeBool=function(D){var z=D.readUInt8();if(D.isError(z))return z;else return z!==0},S.prototype._decodeInt=function(D,z){var R=D.raw(),q=new L(R);if(z)q=z[q.toString(10)]||q;return q},S.prototype._use=function(D,z){if(typeof D==="function")D=D(z);return D._getDecoder("der").tree};function E(D,z){var R=D.readUInt8(z);if(D.isError(R))return R;var q=V.tagClass[R>>6],_=(R&32)===0;if((R&31)===31){var k=R;R=0;while((k&128)===128){if(k=D.readUInt8(z),D.isError(k))return k;R<<=7,R|=k&127}}else R&=31;var j=V.tag[R];return{cls:q,primitive:_,tag:R,tagStr:j}}function C(D,z,R){var q=D.readUInt8(R);if(D.isError(q))return q;if(!z&&q===128)return null;if((q&128)===0)return q;var _=q&127;if(_>4)return D.error("length octect is too long");q=0;for(var k=0;k<_;k++){q<<=8;var j=D.readUInt8(R);if(D.isError(j))return j;q|=j}return q}}),gV=I0((I,O)=>{var W=SU(),T=(HU(),h0(WU)).Buffer,H=pQ();function L(V){H.call(this,V),this.enc="pem"}W(L,H),O.exports=L,L.prototype.decode=function(V,P){var S=V.toString().split(/[\r\n]+/g),E=P.label.toUpperCase(),C=/^-----(BEGIN|END) ([^-]+)-----$/,D=-1,z=-1;for(var R=0;R<S.length;R++){var q=S[R].match(C);if(q===null)continue;if(q[2]!==E)continue;if(D===-1){if(q[1]!=="BEGIN")break;D=R}else{if(q[1]!=="END")break;z=R;break}}if(D===-1||z===-1)throw Error("PEM section not found for: "+E);var _=S.slice(D+1,z).join("");_.replace(/[^a-z0-9\+\/=]+/gi,"");var k=new T(_,"base64");return H.prototype.decode.call(this,k,P)}}),wV=I0((I)=>{var O=I;O.der=pQ(),O.pem=gV()}),hQ=I0((I,O)=>{var W=SU(),T=(HU(),h0(WU)).Buffer,H=IX(),L=H.base,V=H.constants.der;function P(D){this.enc="der",this.name=D.name,this.entity=D,this.tree=new S,this.tree._init(D.body)}O.exports=P,P.prototype.encode=function(D,z){return this.tree._encode(D,z).join()};function S(D){L.Node.call(this,"der",D)}W(S,L.Node),S.prototype._encodeComposite=function(D,z,R,q){var _=C(D,z,R,this.reporter);if(q.length<128){var v=new T(2);return v[0]=_,v[1]=q.length,this._createEncoderBuffer([v,q])}var k=1;for(var j=q.length;j>=256;j>>=8)k++;var v=new T(2+k);v[0]=_,v[1]=128|k;for(var j=1+k,x=q.length;x>0;j--,x>>=8)v[j]=x&255;return this._createEncoderBuffer([v,q])},S.prototype._encodeStr=function(D,z){if(z==="bitstr")return this._createEncoderBuffer([D.unused|0,D.data]);else if(z==="bmpstr"){var R=new T(D.length*2);for(var q=0;q<D.length;q++)R.writeUInt16BE(D.charCodeAt(q),q*2);return this._createEncoderBuffer(R)}else if(z==="numstr"){if(!this._isNumstr(D))return this.reporter.error("Encoding of string type: numstr supports only digits and space");return this._createEncoderBuffer(D)}else if(z==="printstr"){if(!this._isPrintstr(D))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(D)}else if(/str$/.test(z))return this._createEncoderBuffer(D);else if(z==="objDesc")return this._createEncoderBuffer(D);else return this.reporter.error("Encoding of string type: "+z+" unsupported")},S.prototype._encodeObjid=function(D,z,R){if(typeof D==="string"){if(!z)return this.reporter.error("string objid given, but no values map found");if(!z.hasOwnProperty(D))return this.reporter.error("objid not found in values map");D=z[D].split(/[\s\.]+/g);for(var q=0;q<D.length;q++)D[q]|=0}else if(Array.isArray(D)){D=D.slice();for(var q=0;q<D.length;q++)D[q]|=0}if(!Array.isArray(D))return this.reporter.error("objid() should be either array or string, got: "+JSON.stringify(D));if(!R){if(D[1]>=40)return this.reporter.error("Second objid identifier OOB");D.splice(0,2,D[0]*40+D[1])}var _=0;for(var q=0;q<D.length;q++){var k=D[q];for(_++;k>=128;k>>=7)_++}var j=new T(_),v=j.length-1;for(var q=D.length-1;q>=0;q--){var k=D[q];j[v--]=k&127;while((k>>=7)>0)j[v--]=128|k&127}return this._createEncoderBuffer(j)};function E(D){if(D<10)return"0"+D;else return D}S.prototype._encodeTime=function(D,z){var R,q=new Date(D);if(z==="gentime")R=[E(q.getFullYear()),E(q.getUTCMonth()+1),E(q.getUTCDate()),E(q.getUTCHours()),E(q.getUTCMinutes()),E(q.getUTCSeconds()),"Z"].join("");else if(z==="utctime")R=[E(q.getFullYear()%100),E(q.getUTCMonth()+1),E(q.getUTCDate()),E(q.getUTCHours()),E(q.getUTCMinutes()),E(q.getUTCSeconds()),"Z"].join("");else this.reporter.error("Encoding "+z+" time is not supported yet");return this._encodeStr(R,"octstr")},S.prototype._encodeNull=function(){return this._createEncoderBuffer("")},S.prototype._encodeInt=function(D,z){if(typeof D==="string"){if(!z)return this.reporter.error("String int or enum given, but no values map");if(!z.hasOwnProperty(D))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(D));D=z[D]}if(typeof D!=="number"&&!T.isBuffer(D)){var R=D.toArray();if(!D.sign&&R[0]&128)R.unshift(0);D=new T(R)}if(T.isBuffer(D)){var q=D.length;if(D.length===0)q++;var k=new T(q);if(D.copy(k),D.length===0)k[0]=0;return this._createEncoderBuffer(k)}if(D<128)return this._createEncoderBuffer(D);if(D<256)return this._createEncoderBuffer([0,D]);var q=1;for(var _=D;_>=256;_>>=8)q++;var k=Array(q);for(var _=k.length-1;_>=0;_--)k[_]=D&255,D>>=8;if(k[0]&128)k.unshift(0);return this._createEncoderBuffer(new T(k))},S.prototype._encodeBool=function(D){return this._createEncoderBuffer(D?255:0)},S.prototype._use=function(D,z){if(typeof D==="function")D=D(z);return D._getEncoder("der").tree},S.prototype._skipDefault=function(D,z,R){var q=this._baseState,_;if(q.default===null)return!1;var k=D.join();if(q.defaultBuffer===void 0)q.defaultBuffer=this._encodeValue(q.default,z,R).join();if(k.length!==q.defaultBuffer.length)return!1;for(_=0;_<k.length;_++)if(k[_]!==q.defaultBuffer[_])return!1;return!0};function C(D,z,R,q){var _;if(D==="seqof")D="seq";else if(D==="setof")D="set";if(V.tagByName.hasOwnProperty(D))_=V.tagByName[D];else if(typeof D==="number"&&(D|0)===D)_=D;else return q.error("Unknown tag: "+D);if(_>=31)return q.error("Multi-octet tag encoding unsupported");if(!z)_|=32;return _|=V.tagClassByName[R||"universal"]<<6,_}}),fV=I0((I,O)=>{var W=SU(),T=hQ();function H(L){T.call(this,L),this.enc="pem"}W(H,T),O.exports=H,H.prototype.encode=function(L,V){var P=T.prototype.encode.call(this,L),S=P.toString("base64"),E=["-----BEGIN "+V.label+"-----"];for(var C=0;C<S.length;C+=64)E.push(S.slice(C,C+64));return E.push("-----END "+V.label+"-----"),E.join(`
|
|
14
|
+
`)}}),yV=I0((I)=>{var O=I;O.der=hQ(),O.pem=fV()}),IX=I0((I)=>{var O=I;O.bignum=vV(),O.define=_V().define,O.base=QX(),O.constants=cQ(),O.decoders=wV(),O.encoders=yV()}),cV=I0((I,O)=>{var W=IX(),T=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())}),L=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(L),this.key("subjectPublicKey").bitstr())}),P=W.define("RelativeDistinguishedName",function(){this.setof(H)}),S=W.define("RDNSequence",function(){this.seqof(P)}),E=W.define("Name",function(){this.choice({rdnSequence:this.use(S)})}),C=W.define("Validity",function(){this.seq().obj(this.key("notBefore").use(T),this.key("notAfter").use(T))}),D=W.define("Extension",function(){this.seq().obj(this.key("extnID").objid(),this.key("critical").bool().def(!1),this.key("extnValue").octstr())}),z=W.define("TBSCertificate",function(){this.seq().obj(this.key("version").explicit(0).int().optional(),this.key("serialNumber").int(),this.key("signature").use(L),this.key("issuer").use(E),this.key("validity").use(C),this.key("subject").use(E),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())}),R=W.define("X509Certificate",function(){this.seq().obj(this.key("tbsCertificate").use(z),this.key("signatureAlgorithm").use(L),this.key("signatureValue").bitstr())});O.exports=R}),pV=I0((I)=>{var O=IX();I.certificate=cV();var W=O.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())});I.RSAPrivateKey=W;var T=O.define("RSAPublicKey",function(){this.seq().obj(this.key("modulus").int(),this.key("publicExponent").int())});I.RSAPublicKey=T;var H=O.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())}),L=O.define("SubjectPublicKeyInfo",function(){this.seq().obj(this.key("algorithm").use(H),this.key("subjectPublicKey").bitstr())});I.PublicKey=L;var V=O.define("PrivateKeyInfo",function(){this.seq().obj(this.key("version").int(),this.key("algorithm").use(H),this.key("subjectPrivateKey").octstr())});I.PrivateKey=V;var P=O.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())});I.EncryptedPrivateKey=P;var S=O.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())});I.DSAPrivateKey=S,I.DSAparam=O.define("DSAparam",function(){this.int()});var E=O.define("ECParameters",function(){this.choice({namedCurve:this.objid()})}),C=O.define("ECPrivateKey",function(){this.seq().obj(this.key("version").int(),this.key("privateKey").octstr(),this.key("parameters").optional().explicit(0).use(E),this.key("publicKey").optional().explicit(1).bitstr())});I.ECPrivateKey=C,I.signature=O.define("signature",function(){this.seq().obj(this.key("r").int(),this.key("s").int())})}),hV=I0((I,O)=>{O.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=I0((I,O)=>{var W=EU().Buffer,T=YZ().Transform,H=SU();function L(E){T.call(this),this._block=W.allocUnsafe(E),this._blockSize=E,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}H(L,T),L.prototype._transform=function(E,C,D){var z=null;try{this.update(E,C)}catch(R){z=R}D(z)},L.prototype._flush=function(E){var C=null;try{this.push(this.digest())}catch(D){C=D}E(C)};var V=typeof Uint8Array<"u",P=typeof ArrayBuffer<"u"&&typeof Uint8Array<"u"&&ArrayBuffer.isView&&(W.prototype instanceof Uint8Array||W.TYPED_ARRAY_SUPPORT);function S(E,C){if(E instanceof W)return E;if(typeof E==="string")return W.from(E,C);if(P&&ArrayBuffer.isView(E)){if(E.byteLength===0)return W.alloc(0);var D=W.from(E.buffer,E.byteOffset,E.byteLength);if(D.byteLength===E.byteLength)return D}if(V&&E instanceof Uint8Array)return W.from(E);if(W.isBuffer(E)&&E.constructor&&typeof E.constructor.isBuffer==="function"&&E.constructor.isBuffer(E))return W.from(E);throw TypeError('The "data" argument must be of type string or an instance of Buffer, TypedArray, or DataView.')}L.prototype.update=function(E,C){if(this._finalized)throw Error("Digest already called");E=S(E,C);var D=this._block,z=0;while(this._blockOffset+E.length-z>=this._blockSize){for(var R=this._blockOffset;R<this._blockSize;)D[R++]=E[z++];this._update(),this._blockOffset=0}while(z<E.length)D[this._blockOffset++]=E[z++];for(var q=0,_=E.length*8;_>0;++q)if(this._length[q]+=_,_=this._length[q]/4294967296|0,_>0)this._length[q]-=4294967296*_;return this},L.prototype._update=function(){throw Error("_update is not implemented")},L.prototype.digest=function(E){if(this._finalized)throw Error("Digest already called");this._finalized=!0;var C=this._digest();if(E!==void 0)C=C.toString(E);this._block.fill(0),this._blockOffset=0;for(var D=0;D<4;++D)this._length[D]=0;return C},L.prototype._digest=function(){throw Error("_digest is not implemented")},O.exports=L}),bV=I0((I,O)=>{var W=SU(),T=uV(),H=EU().Buffer,L=Array(16);function V(){T.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}W(V,T),V.prototype._update=function(){var z=L;for(var R=0;R<16;++R)z[R]=this._block.readInt32LE(R*4);var q=this._a,_=this._b,k=this._c,j=this._d;q=S(q,_,k,j,z[0],3614090360,7),j=S(j,q,_,k,z[1],3905402710,12),k=S(k,j,q,_,z[2],606105819,17),_=S(_,k,j,q,z[3],3250441966,22),q=S(q,_,k,j,z[4],4118548399,7),j=S(j,q,_,k,z[5],1200080426,12),k=S(k,j,q,_,z[6],2821735955,17),_=S(_,k,j,q,z[7],4249261313,22),q=S(q,_,k,j,z[8],1770035416,7),j=S(j,q,_,k,z[9],2336552879,12),k=S(k,j,q,_,z[10],4294925233,17),_=S(_,k,j,q,z[11],2304563134,22),q=S(q,_,k,j,z[12],1804603682,7),j=S(j,q,_,k,z[13],4254626195,12),k=S(k,j,q,_,z[14],2792965006,17),_=S(_,k,j,q,z[15],1236535329,22),q=E(q,_,k,j,z[1],4129170786,5),j=E(j,q,_,k,z[6],3225465664,9),k=E(k,j,q,_,z[11],643717713,14),_=E(_,k,j,q,z[0],3921069994,20),q=E(q,_,k,j,z[5],3593408605,5),j=E(j,q,_,k,z[10],38016083,9),k=E(k,j,q,_,z[15],3634488961,14),_=E(_,k,j,q,z[4],3889429448,20),q=E(q,_,k,j,z[9],568446438,5),j=E(j,q,_,k,z[14],3275163606,9),k=E(k,j,q,_,z[3],4107603335,14),_=E(_,k,j,q,z[8],1163531501,20),q=E(q,_,k,j,z[13],2850285829,5),j=E(j,q,_,k,z[2],4243563512,9),k=E(k,j,q,_,z[7],1735328473,14),_=E(_,k,j,q,z[12],2368359562,20),q=C(q,_,k,j,z[5],4294588738,4),j=C(j,q,_,k,z[8],2272392833,11),k=C(k,j,q,_,z[11],1839030562,16),_=C(_,k,j,q,z[14],4259657740,23),q=C(q,_,k,j,z[1],2763975236,4),j=C(j,q,_,k,z[4],1272893353,11),k=C(k,j,q,_,z[7],4139469664,16),_=C(_,k,j,q,z[10],3200236656,23),q=C(q,_,k,j,z[13],681279174,4),j=C(j,q,_,k,z[0],3936430074,11),k=C(k,j,q,_,z[3],3572445317,16),_=C(_,k,j,q,z[6],76029189,23),q=C(q,_,k,j,z[9],3654602809,4),j=C(j,q,_,k,z[12],3873151461,11),k=C(k,j,q,_,z[15],530742520,16),_=C(_,k,j,q,z[2],3299628645,23),q=D(q,_,k,j,z[0],4096336452,6),j=D(j,q,_,k,z[7],1126891415,10),k=D(k,j,q,_,z[14],2878612391,15),_=D(_,k,j,q,z[5],4237533241,21),q=D(q,_,k,j,z[12],1700485571,6),j=D(j,q,_,k,z[3],2399980690,10),k=D(k,j,q,_,z[10],4293915773,15),_=D(_,k,j,q,z[1],2240044497,21),q=D(q,_,k,j,z[8],1873313359,6),j=D(j,q,_,k,z[15],4264355552,10),k=D(k,j,q,_,z[6],2734768916,15),_=D(_,k,j,q,z[13],1309151649,21),q=D(q,_,k,j,z[4],4149444226,6),j=D(j,q,_,k,z[11],3174756917,10),k=D(k,j,q,_,z[2],718787259,15),_=D(_,k,j,q,z[9],3951481745,21),this._a=this._a+q|0,this._b=this._b+_|0,this._c=this._c+k|0,this._d=this._d+j|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 z=H.allocUnsafe(16);return z.writeInt32LE(this._a,0),z.writeInt32LE(this._b,4),z.writeInt32LE(this._c,8),z.writeInt32LE(this._d,12),z};function P(z,R){return z<<R|z>>>32-R}function S(z,R,q,_,k,j,v){return P(z+(R&q|~R&_)+k+j|0,v)+R|0}function E(z,R,q,_,k,j,v){return P(z+(R&_|q&~_)+k+j|0,v)+R|0}function C(z,R,q,_,k,j,v){return P(z+(R^q^_)+k+j|0,v)+R|0}function D(z,R,q,_,k,j,v){return P(z+(q^(R|~_))+k+j|0,v)+R|0}O.exports=V}),lV=I0((I,O)=>{var W=EU().Buffer,T=bV();function H(L,V,P,S){if(!W.isBuffer(L))L=W.from(L,"binary");if(V){if(!W.isBuffer(V))V=W.from(V,"binary");if(V.length!==8)throw RangeError("salt should be Buffer with 8 byte length")}var E=P/8,C=W.alloc(E),D=W.alloc(S||0),z=W.alloc(0);while(E>0||S>0){var R=new T;if(R.update(z),R.update(L),V)R.update(V);z=R.digest();var q=0;if(E>0){var _=C.length-E;q=Math.min(E,z.length),z.copy(C,_,0,q),E-=q}if(q<z.length&&S>0){var k=D.length-S,j=Math.min(S,z.length-q);z.copy(D,k,q,q+j),S-=j}}return z.fill(0),{key:C,iv:D}}O.exports=H}),uQ=I0((I)=>{var O=(qU(),h0(RU));I.createCipher=I.Cipher=O.createCipher,I.createCipheriv=I.Cipheriv=O.createCipheriv,I.createDecipher=I.Decipher=O.createDecipher,I.createDecipheriv=I.Decipheriv=O.createDecipheriv,I.listCiphers=I.getCiphers=O.getCiphers}),dV=I0((I,O)=>{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,T=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----/m,H=/^-----BEGIN ((?:.*? KEY)|CERTIFICATE)-----([0-9A-z\n\r+/=]+)-----END \1-----$/m,L=lV(),V=uQ(),P=EU().Buffer;O.exports=function(S,E){var C=S.toString(),D=C.match(W),z;if(!D){var R=C.match(H);z=P.from(R[2].replace(/[\r\n]/g,""),"base64")}else{var q="aes"+D[1],_=P.from(D[2],"hex"),k=P.from(D[3].replace(/[\r\n]/g,""),"base64"),j=L(E,_.slice(0,8),parseInt(D[1],10)).key,v=[],x=V.createDecipheriv(q,j,_);v.push(x.update(k)),v.push(x.final()),z=P.concat(v)}var N=C.match(T)[1];return{tag:N,data:z}}}),bQ=I0((I,O)=>{var W=pV(),T=hV(),H=dV(),L=uQ(),V=BQ().pbkdf2Sync,P=EU().Buffer;function S(C,D){var z=C.algorithm.decrypt.kde.kdeparams.salt,R=parseInt(C.algorithm.decrypt.kde.kdeparams.iters.toString(),10),q=T[C.algorithm.decrypt.cipher.algo.join(".")],_=C.algorithm.decrypt.cipher.iv,k=C.subjectPrivateKey,j=parseInt(q.split("-")[1],10)/8,v=V(D,z,R,j,"sha1"),x=L.createDecipheriv(q,v,_),N=[];return N.push(x.update(k)),N.push(x.final()),P.concat(N)}function E(C){var D;if(typeof C==="object"&&!P.isBuffer(C))D=C.passphrase,C=C.key;if(typeof C==="string")C=P.from(C);var z=H(C,D),R=z.tag,q=z.data,_,k;switch(R){case"CERTIFICATE":k=W.certificate.decode(q,"der").tbsCertificate.subjectPublicKeyInfo;case"PUBLIC KEY":if(!k)k=W.PublicKey.decode(q,"der");switch(_=k.algorithm.algorithm.join("."),_){case"1.2.840.113549.1.1.1":return W.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=W.DSAparam.decode(k.subjectPublicKey.data,"der"),{type:"dsa",data:k.algorithm.params};default:throw Error("unknown key id "+_)}case"ENCRYPTED PRIVATE KEY":q=W.EncryptedPrivateKey.decode(q,"der"),q=S(q,D);case"PRIVATE KEY":switch(k=W.PrivateKey.decode(q,"der"),_=k.algorithm.algorithm.join("."),_){case"1.2.840.113549.1.1.1":return W.RSAPrivateKey.decode(k.subjectPrivateKey,"der");case"1.2.840.10045.2.1":return{curve:k.algorithm.curve,privateKey:W.ECPrivateKey.decode(k.subjectPrivateKey,"der").privateKey};case"1.2.840.10040.4.1":return k.algorithm.params.priv_key=W.DSAparam.decode(k.subjectPrivateKey,"der"),{type:"dsa",params:k.algorithm.params};default:throw Error("unknown key id "+_)}case"RSA PUBLIC KEY":return W.RSAPublicKey.decode(q,"der");case"RSA PRIVATE KEY":return W.RSAPrivateKey.decode(q,"der");case"DSA PRIVATE KEY":return{type:"dsa",params:W.DSAPrivateKey.decode(q,"der")};case"EC PRIVATE KEY":return q=W.ECPrivateKey.decode(q,"der"),{curve:q.parameters.value,privateKey:q.privateKey};default:throw Error("unknown key type "+R)}}E.signature=W.signature,O.exports=E}),lQ=I0((I,O)=>{var W=SX(),T=EU().Buffer;O.exports=function(L,V){var P=T.alloc(0),S=0,E;while(P.length<V)E=H(S++),P=T.concat([P,W("sha1").update(L).update(E).digest()]);return P.slice(0,V)};function H(L){var V=T.allocUnsafe(4);return V.writeUInt32BE(L,0),V}}),dQ=I0((I,O)=>{O.exports=function(W,T){var H=W.length,L=-1;while(++L<H)W[L]^=T[L];return W}}),HZ=I0((I,O)=>{(function(W,T){function H(U,Q){if(!U)throw Error(Q||"Assertion failed")}function L(U,Q){U.super_=Q;var J=function(){};J.prototype=Q.prototype,U.prototype=new J,U.prototype.constructor=U}function V(U,Q,J){if(V.isBN(U))return U;if(this.negative=0,this.words=null,this.length=0,this.red=null,U!==null){if(Q==="le"||Q==="be")J=Q,Q=10;this._init(U||0,Q||10,J||"be")}}if(typeof W==="object")W.exports=V;else T.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window<"u"&&typeof window.Buffer<"u")P=window.Buffer;else P=(HU(),h0(WU)).Buffer}catch(U){}V.isBN=function(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(U,Q){if(U.cmp(Q)>0)return U;return Q},V.min=function(U,Q){if(U.cmp(Q)<0)return U;return Q},V.prototype._init=function(U,Q,J){if(typeof U==="number")return this._initNumber(U,Q,J);if(typeof U==="object")return this._initArray(U,Q,J);if(Q==="hex")Q=16;H(Q===(Q|0)&&Q>=2&&Q<=36),U=U.toString().replace(/\s+/g,"");var Z=0;if(U[0]==="-")Z++,this.negative=1;if(Z<U.length){if(Q===16)this._parseHex(U,Z,J);else if(this._parseBase(U,Q,Z),J==="le")this._initArray(this.toArray(),Q,J)}},V.prototype._initNumber=function(U,Q,J){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(J!=="le")return;this._initArray(this.toArray(),Q,J)},V.prototype._initArray=function(U,Q,J){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=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y,K,F=0;if(J==="be"){for(Z=U.length-1,Y=0;Z>=0;Z-=3)if(K=U[Z]|U[Z-1]<<8|U[Z-2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}else if(J==="le"){for(Z=0,Y=0;Z<U.length;Z+=3)if(K=U[Z]|U[Z+1]<<8|U[Z+2]<<16,this.words[Y]|=K<<F&67108863,this.words[Y+1]=K>>>26-F&67108863,F+=24,F>=26)F-=26,Y++}return this.strip()};function S(U,Q){var J=U.charCodeAt(Q);if(J>=65&&J<=70)return J-55;else if(J>=97&&J<=102)return J-87;else return J-48&15}function E(U,Q,J){var Z=S(U,J);if(J-1>=Q)Z|=S(U,J-1)<<4;return Z}V.prototype._parseHex=function(U,Q,J){this.length=Math.ceil((U.length-Q)/6),this.words=Array(this.length);for(var Z=0;Z<this.length;Z++)this.words[Z]=0;var Y=0,K=0,F;if(J==="be")for(Z=U.length-1;Z>=Q;Z-=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8;else{var G=U.length-Q;for(Z=G%2===0?Q+1:Q;Z<U.length;Z+=2)if(F=E(U,Q,Z)<<Y,this.words[K]|=F&67108863,Y>=18)Y-=18,K+=1,this.words[K]|=F>>>26;else Y+=8}this.strip()};function C(U,Q,J,Z){var Y=0,K=Math.min(U.length,J);for(var F=Q;F<K;F++){var G=U.charCodeAt(F)-48;if(Y*=Z,G>=49)Y+=G-49+10;else if(G>=17)Y+=G-17+10;else Y+=G}return Y}V.prototype._parseBase=function(U,Q,J){this.words=[0],this.length=1;for(var Z=0,Y=1;Y<=67108863;Y*=Q)Z++;Z--,Y=Y/Q|0;var K=U.length-J,F=K%Z,G=Math.min(K,K-F)+J,X=0;for(var $=J;$<G;$+=Z)if(X=C(U,$,$+Z,Q),this.imuln(Y),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X);if(F!==0){var M=1;X=C(U,$,U.length,Q);for($=0;$<F;$++)M*=Q;if(this.imuln(M),this.words[0]+X<67108864)this.words[0]+=X;else this._iaddn(X)}this.strip()},V.prototype.copy=function(U){U.words=Array(this.length);for(var Q=0;Q<this.length;Q++)U.words[Q]=this.words[Q];U.length=this.length,U.negative=this.negative,U.red=this.red},V.prototype.clone=function(){var U=new V(null);return this.copy(U),U},V.prototype._expand=function(U){while(this.length<U)this.words[this.length++]=0;return this},V.prototype.strip=function(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},V.prototype.inspect=function(){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"],z=[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],R=[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(U,Q){U=U||10,Q=Q|0||1;var J;if(U===16||U==="hex"){J="";var Z=0,Y=0;for(var K=0;K<this.length;K++){var F=this.words[K],G=((F<<Z|Y)&16777215).toString(16);if(Y=F>>>24-Z&16777215,Z+=2,Z>=26)Z-=26,K--;if(Y!==0||K!==this.length-1)J=D[6-G.length]+G+J;else J=G+J}if(Y!==0)J=Y.toString(16)+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}if(U===(U|0)&&U>=2&&U<=36){var X=z[U],$=R[U];J="";var M=this.clone();M.negative=0;while(!M.isZero()){var A=M.modn($).toString(U);if(M=M.idivn($),!M.isZero())J=D[X-A.length]+A+J;else J=A+J}if(this.isZero())J="0"+J;while(J.length%Q!==0)J="0"+J;if(this.negative!==0)J="-"+J;return J}H(!1,"Base should be between 2 and 36")},V.prototype.toNumber=function(){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(){return this.toString(16)},V.prototype.toBuffer=function(U,Q){return H(typeof P<"u"),this.toArrayLike(P,U,Q)},V.prototype.toArray=function(U,Q){return this.toArrayLike(Array,U,Q)},V.prototype.toArrayLike=function(U,Q,J){var Z=this.byteLength(),Y=J||Math.max(1,Z);H(Z<=Y,"byte array longer than desired length"),H(Y>0,"Requested array length <= 0"),this.strip();var K=Q==="le",F=new U(Y),G,X,$=this.clone();if(!K){for(X=0;X<Y-Z;X++)F[X]=0;for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[Y-X-1]=G}else{for(X=0;!$.isZero();X++)G=$.andln(255),$.iushrn(8),F[X]=G;for(;X<Y;X++)F[X]=0}return F},Math.clz32)V.prototype._countBits=function(U){return 32-Math.clz32(U)};else V.prototype._countBits=function(U){var Q=U,J=0;if(Q>=4096)J+=13,Q>>>=13;if(Q>=64)J+=7,Q>>>=7;if(Q>=8)J+=4,Q>>>=4;if(Q>=2)J+=2,Q>>>=2;return J+Q};V.prototype._zeroBits=function(U){if(U===0)return 26;var Q=U,J=0;if((Q&8191)===0)J+=13,Q>>>=13;if((Q&127)===0)J+=7,Q>>>=7;if((Q&15)===0)J+=4,Q>>>=4;if((Q&3)===0)J+=2,Q>>>=2;if((Q&1)===0)J++;return J},V.prototype.bitLength=function(){var U=this.words[this.length-1],Q=this._countBits(U);return(this.length-1)*26+Q};function q(U){var Q=Array(U.bitLength());for(var J=0;J<Q.length;J++){var Z=J/26|0,Y=J%26;Q[J]=(U.words[Z]&1<<Y)>>>Y}return Q}V.prototype.zeroBits=function(){if(this.isZero())return 0;var U=0;for(var Q=0;Q<this.length;Q++){var J=this._zeroBits(this.words[Q]);if(U+=J,J!==26)break}return U},V.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function(U){if(this.negative!==0)return this.abs().inotn(U).iaddn(1);return this.clone()},V.prototype.fromTwos=function(U){if(this.testn(U-1))return this.notn(U).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function(){return this.negative!==0},V.prototype.neg=function(){return this.clone().ineg()},V.prototype.ineg=function(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function(U){while(this.length<U.length)this.words[this.length++]=0;for(var Q=0;Q<U.length;Q++)this.words[Q]=this.words[Q]|U.words[Q];return this.strip()},V.prototype.ior=function(U){return H((this.negative|U.negative)===0),this.iuor(U)},V.prototype.or=function(U){if(this.length>U.length)return this.clone().ior(U);return U.clone().ior(this)},V.prototype.uor=function(U){if(this.length>U.length)return this.clone().iuor(U);return U.clone().iuor(this)},V.prototype.iuand=function(U){var Q;if(this.length>U.length)Q=U;else Q=this;for(var J=0;J<Q.length;J++)this.words[J]=this.words[J]&U.words[J];return this.length=Q.length,this.strip()},V.prototype.iand=function(U){return H((this.negative|U.negative)===0),this.iuand(U)},V.prototype.and=function(U){if(this.length>U.length)return this.clone().iand(U);return U.clone().iand(this)},V.prototype.uand=function(U){if(this.length>U.length)return this.clone().iuand(U);return U.clone().iuand(this)},V.prototype.iuxor=function(U){var Q,J;if(this.length>U.length)Q=this,J=U;else Q=U,J=this;for(var Z=0;Z<J.length;Z++)this.words[Z]=Q.words[Z]^J.words[Z];if(this!==Q)for(;Z<Q.length;Z++)this.words[Z]=Q.words[Z];return this.length=Q.length,this.strip()},V.prototype.ixor=function(U){return H((this.negative|U.negative)===0),this.iuxor(U)},V.prototype.xor=function(U){if(this.length>U.length)return this.clone().ixor(U);return U.clone().ixor(this)},V.prototype.uxor=function(U){if(this.length>U.length)return this.clone().iuxor(U);return U.clone().iuxor(this)},V.prototype.inotn=function(U){H(typeof U==="number"&&U>=0);var Q=Math.ceil(U/26)|0,J=U%26;if(this._expand(Q),J>0)Q--;for(var Z=0;Z<Q;Z++)this.words[Z]=~this.words[Z]&67108863;if(J>0)this.words[Z]=~this.words[Z]&67108863>>26-J;return this.strip()},V.prototype.notn=function(U){return this.clone().inotn(U)},V.prototype.setn=function(U,Q){H(typeof U==="number"&&U>=0);var J=U/26|0,Z=U%26;if(this._expand(J+1),Q)this.words[J]=this.words[J]|1<<Z;else this.words[J]=this.words[J]&~(1<<Z);return this.strip()},V.prototype.iadd=function(U){var Q;if(this.negative!==0&&U.negative===0)return this.negative=0,Q=this.isub(U),this.negative^=1,this._normSign();else if(this.negative===0&&U.negative!==0)return U.negative=0,Q=this.isub(U),U.negative=1,Q._normSign();var J,Z;if(this.length>U.length)J=this,Z=U;else J=U,Z=this;var Y=0;for(var K=0;K<Z.length;K++)Q=(J.words[K]|0)+(Z.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;for(;Y!==0&&K<J.length;K++)Q=(J.words[K]|0)+Y,this.words[K]=Q&67108863,Y=Q>>>26;if(this.length=J.length,Y!==0)this.words[this.length]=Y,this.length++;else if(J!==this)for(;K<J.length;K++)this.words[K]=J.words[K];return this},V.prototype.add=function(U){var Q;if(U.negative!==0&&this.negative===0)return U.negative=0,Q=this.sub(U),U.negative^=1,Q;else if(U.negative===0&&this.negative!==0)return this.negative=0,Q=U.sub(this),this.negative=1,Q;if(this.length>U.length)return this.clone().iadd(U);return U.clone().iadd(this)},V.prototype.isub=function(U){if(U.negative!==0){U.negative=0;var Q=this.iadd(U);return U.negative=1,Q._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(U),this.negative=1,this._normSign();var J=this.cmp(U);if(J===0)return this.negative=0,this.length=1,this.words[0]=0,this;var Z,Y;if(J>0)Z=this,Y=U;else Z=U,Y=this;var K=0;for(var F=0;F<Y.length;F++)Q=(Z.words[F]|0)-(Y.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;for(;K!==0&&F<Z.length;F++)Q=(Z.words[F]|0)+K,K=Q>>26,this.words[F]=Q&67108863;if(K===0&&F<Z.length&&Z!==this)for(;F<Z.length;F++)this.words[F]=Z.words[F];if(this.length=Math.max(this.length,F),Z!==this)this.negative=1;return this.strip()},V.prototype.sub=function(U){return this.clone().isub(U)};function _(U,Q,J){J.negative=Q.negative^U.negative;var Z=U.length+Q.length|0;J.length=Z,Z=Z-1|0;var Y=U.words[0]|0,K=Q.words[0]|0,F=Y*K,G=F&67108863,X=F/67108864|0;J.words[0]=G;for(var $=1;$<Z;$++){var M=X>>>26,A=X&67108863,B=Math.min($,Q.length-1);for(var w=Math.max(0,$-U.length+1);w<=B;w++){var p=$-w|0;Y=U.words[p]|0,K=Q.words[w]|0,F=Y*K+A,M+=F/67108864|0,A=F&67108863}J.words[$]=A|0,X=M|0}if(X!==0)J.words[$]=X|0;else J.length--;return J.strip()}var k=function(U,Q,J){var Z=U.words,Y=Q.words,K=J.words,F=0,G,X,$,M=Z[0]|0,A=M&8191,B=M>>>13,w=Z[1]|0,p=w&8191,n=w>>>13,K0=Z[2]|0,r=K0&8191,d=K0>>>13,J0=Z[3]|0,m=J0&8191,i=J0>>>13,g0=Z[4]|0,y=g0&8191,h=g0>>>13,V0=Z[5]|0,t=V0&8191,e=V0>>>13,E0=Z[6]|0,c=E0&8191,o=E0>>>13,N0=Z[7]|0,s=N0&8191,Z0=N0>>>13,f0=Z[8]|0,W0=f0&8191,H0=f0>>>13,n0=Z[9]|0,O0=n0&8191,D0=n0>>>13,t0=Y[0]|0,z0=t0&8191,A0=t0>>>13,AU=Y[1]|0,L0=AU&8191,k0=AU>>>13,zU=Y[2]|0,j0=zU&8191,M0=zU>>>13,DU=Y[3]|0,v0=DU&8191,R0=DU>>>13,KU=Y[4]|0,_0=KU&8191,B0=KU>>>13,OU=Y[5]|0,q0=OU&8191,g=OU>>>13,l=Y[6]|0,a=l&8191,X0=l>>>13,w0=Y[7]|0,F0=w0&8191,T0=w0>>>13,m0=Y[8]|0,S0=m0&8191,x0=m0>>>13,TU=Y[9]|0,P0=TU&8191,C0=TU>>>13;J.negative=U.negative^Q.negative,J.length=19,G=Math.imul(A,z0),X=Math.imul(A,A0),X=X+Math.imul(B,z0)|0,$=Math.imul(B,A0);var s0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(s0>>>26)|0,s0&=67108863,G=Math.imul(p,z0),X=Math.imul(p,A0),X=X+Math.imul(n,z0)|0,$=Math.imul(n,A0),G=G+Math.imul(A,L0)|0,X=X+Math.imul(A,k0)|0,X=X+Math.imul(B,L0)|0,$=$+Math.imul(B,k0)|0;var c0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(c0>>>26)|0,c0&=67108863,G=Math.imul(r,z0),X=Math.imul(r,A0),X=X+Math.imul(d,z0)|0,$=Math.imul(d,A0),G=G+Math.imul(p,L0)|0,X=X+Math.imul(p,k0)|0,X=X+Math.imul(n,L0)|0,$=$+Math.imul(n,k0)|0,G=G+Math.imul(A,j0)|0,X=X+Math.imul(A,M0)|0,X=X+Math.imul(B,j0)|0,$=$+Math.imul(B,M0)|0;var y0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(y0>>>26)|0,y0&=67108863,G=Math.imul(m,z0),X=Math.imul(m,A0),X=X+Math.imul(i,z0)|0,$=Math.imul(i,A0),G=G+Math.imul(r,L0)|0,X=X+Math.imul(r,k0)|0,X=X+Math.imul(d,L0)|0,$=$+Math.imul(d,k0)|0,G=G+Math.imul(p,j0)|0,X=X+Math.imul(p,M0)|0,X=X+Math.imul(n,j0)|0,$=$+Math.imul(n,M0)|0,G=G+Math.imul(A,v0)|0,X=X+Math.imul(A,R0)|0,X=X+Math.imul(B,v0)|0,$=$+Math.imul(B,R0)|0;var l0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(l0>>>26)|0,l0&=67108863,G=Math.imul(y,z0),X=Math.imul(y,A0),X=X+Math.imul(h,z0)|0,$=Math.imul(h,A0),G=G+Math.imul(m,L0)|0,X=X+Math.imul(m,k0)|0,X=X+Math.imul(i,L0)|0,$=$+Math.imul(i,k0)|0,G=G+Math.imul(r,j0)|0,X=X+Math.imul(r,M0)|0,X=X+Math.imul(d,j0)|0,$=$+Math.imul(d,M0)|0,G=G+Math.imul(p,v0)|0,X=X+Math.imul(p,R0)|0,X=X+Math.imul(n,v0)|0,$=$+Math.imul(n,R0)|0,G=G+Math.imul(A,_0)|0,X=X+Math.imul(A,B0)|0,X=X+Math.imul(B,_0)|0,$=$+Math.imul(B,B0)|0;var b0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(b0>>>26)|0,b0&=67108863,G=Math.imul(t,z0),X=Math.imul(t,A0),X=X+Math.imul(e,z0)|0,$=Math.imul(e,A0),G=G+Math.imul(y,L0)|0,X=X+Math.imul(y,k0)|0,X=X+Math.imul(h,L0)|0,$=$+Math.imul(h,k0)|0,G=G+Math.imul(m,j0)|0,X=X+Math.imul(m,M0)|0,X=X+Math.imul(i,j0)|0,$=$+Math.imul(i,M0)|0,G=G+Math.imul(r,v0)|0,X=X+Math.imul(r,R0)|0,X=X+Math.imul(d,v0)|0,$=$+Math.imul(d,R0)|0,G=G+Math.imul(p,_0)|0,X=X+Math.imul(p,B0)|0,X=X+Math.imul(n,_0)|0,$=$+Math.imul(n,B0)|0,G=G+Math.imul(A,q0)|0,X=X+Math.imul(A,g)|0,X=X+Math.imul(B,q0)|0,$=$+Math.imul(B,g)|0;var r0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(r0>>>26)|0,r0&=67108863,G=Math.imul(c,z0),X=Math.imul(c,A0),X=X+Math.imul(o,z0)|0,$=Math.imul(o,A0),G=G+Math.imul(t,L0)|0,X=X+Math.imul(t,k0)|0,X=X+Math.imul(e,L0)|0,$=$+Math.imul(e,k0)|0,G=G+Math.imul(y,j0)|0,X=X+Math.imul(y,M0)|0,X=X+Math.imul(h,j0)|0,$=$+Math.imul(h,M0)|0,G=G+Math.imul(m,v0)|0,X=X+Math.imul(m,R0)|0,X=X+Math.imul(i,v0)|0,$=$+Math.imul(i,R0)|0,G=G+Math.imul(r,_0)|0,X=X+Math.imul(r,B0)|0,X=X+Math.imul(d,_0)|0,$=$+Math.imul(d,B0)|0,G=G+Math.imul(p,q0)|0,X=X+Math.imul(p,g)|0,X=X+Math.imul(n,q0)|0,$=$+Math.imul(n,g)|0,G=G+Math.imul(A,a)|0,X=X+Math.imul(A,X0)|0,X=X+Math.imul(B,a)|0,$=$+Math.imul(B,X0)|0;var a0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(a0>>>26)|0,a0&=67108863,G=Math.imul(s,z0),X=Math.imul(s,A0),X=X+Math.imul(Z0,z0)|0,$=Math.imul(Z0,A0),G=G+Math.imul(c,L0)|0,X=X+Math.imul(c,k0)|0,X=X+Math.imul(o,L0)|0,$=$+Math.imul(o,k0)|0,G=G+Math.imul(t,j0)|0,X=X+Math.imul(t,M0)|0,X=X+Math.imul(e,j0)|0,$=$+Math.imul(e,M0)|0,G=G+Math.imul(y,v0)|0,X=X+Math.imul(y,R0)|0,X=X+Math.imul(h,v0)|0,$=$+Math.imul(h,R0)|0,G=G+Math.imul(m,_0)|0,X=X+Math.imul(m,B0)|0,X=X+Math.imul(i,_0)|0,$=$+Math.imul(i,B0)|0,G=G+Math.imul(r,q0)|0,X=X+Math.imul(r,g)|0,X=X+Math.imul(d,q0)|0,$=$+Math.imul(d,g)|0,G=G+Math.imul(p,a)|0,X=X+Math.imul(p,X0)|0,X=X+Math.imul(n,a)|0,$=$+Math.imul(n,X0)|0,G=G+Math.imul(A,F0)|0,X=X+Math.imul(A,T0)|0,X=X+Math.imul(B,F0)|0,$=$+Math.imul(B,T0)|0;var e0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(e0>>>26)|0,e0&=67108863,G=Math.imul(W0,z0),X=Math.imul(W0,A0),X=X+Math.imul(H0,z0)|0,$=Math.imul(H0,A0),G=G+Math.imul(s,L0)|0,X=X+Math.imul(s,k0)|0,X=X+Math.imul(Z0,L0)|0,$=$+Math.imul(Z0,k0)|0,G=G+Math.imul(c,j0)|0,X=X+Math.imul(c,M0)|0,X=X+Math.imul(o,j0)|0,$=$+Math.imul(o,M0)|0,G=G+Math.imul(t,v0)|0,X=X+Math.imul(t,R0)|0,X=X+Math.imul(e,v0)|0,$=$+Math.imul(e,R0)|0,G=G+Math.imul(y,_0)|0,X=X+Math.imul(y,B0)|0,X=X+Math.imul(h,_0)|0,$=$+Math.imul(h,B0)|0,G=G+Math.imul(m,q0)|0,X=X+Math.imul(m,g)|0,X=X+Math.imul(i,q0)|0,$=$+Math.imul(i,g)|0,G=G+Math.imul(r,a)|0,X=X+Math.imul(r,X0)|0,X=X+Math.imul(d,a)|0,$=$+Math.imul(d,X0)|0,G=G+Math.imul(p,F0)|0,X=X+Math.imul(p,T0)|0,X=X+Math.imul(n,F0)|0,$=$+Math.imul(n,T0)|0,G=G+Math.imul(A,S0)|0,X=X+Math.imul(A,x0)|0,X=X+Math.imul(B,S0)|0,$=$+Math.imul(B,x0)|0;var i0=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(i0>>>26)|0,i0&=67108863,G=Math.imul(O0,z0),X=Math.imul(O0,A0),X=X+Math.imul(D0,z0)|0,$=Math.imul(D0,A0),G=G+Math.imul(W0,L0)|0,X=X+Math.imul(W0,k0)|0,X=X+Math.imul(H0,L0)|0,$=$+Math.imul(H0,k0)|0,G=G+Math.imul(s,j0)|0,X=X+Math.imul(s,M0)|0,X=X+Math.imul(Z0,j0)|0,$=$+Math.imul(Z0,M0)|0,G=G+Math.imul(c,v0)|0,X=X+Math.imul(c,R0)|0,X=X+Math.imul(o,v0)|0,$=$+Math.imul(o,R0)|0,G=G+Math.imul(t,_0)|0,X=X+Math.imul(t,B0)|0,X=X+Math.imul(e,_0)|0,$=$+Math.imul(e,B0)|0,G=G+Math.imul(y,q0)|0,X=X+Math.imul(y,g)|0,X=X+Math.imul(h,q0)|0,$=$+Math.imul(h,g)|0,G=G+Math.imul(m,a)|0,X=X+Math.imul(m,X0)|0,X=X+Math.imul(i,a)|0,$=$+Math.imul(i,X0)|0,G=G+Math.imul(r,F0)|0,X=X+Math.imul(r,T0)|0,X=X+Math.imul(d,F0)|0,$=$+Math.imul(d,T0)|0,G=G+Math.imul(p,S0)|0,X=X+Math.imul(p,x0)|0,X=X+Math.imul(n,S0)|0,$=$+Math.imul(n,x0)|0,G=G+Math.imul(A,P0)|0,X=X+Math.imul(A,C0)|0,X=X+Math.imul(B,P0)|0,$=$+Math.imul(B,C0)|0;var UU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(UU>>>26)|0,UU&=67108863,G=Math.imul(O0,L0),X=Math.imul(O0,k0),X=X+Math.imul(D0,L0)|0,$=Math.imul(D0,k0),G=G+Math.imul(W0,j0)|0,X=X+Math.imul(W0,M0)|0,X=X+Math.imul(H0,j0)|0,$=$+Math.imul(H0,M0)|0,G=G+Math.imul(s,v0)|0,X=X+Math.imul(s,R0)|0,X=X+Math.imul(Z0,v0)|0,$=$+Math.imul(Z0,R0)|0,G=G+Math.imul(c,_0)|0,X=X+Math.imul(c,B0)|0,X=X+Math.imul(o,_0)|0,$=$+Math.imul(o,B0)|0,G=G+Math.imul(t,q0)|0,X=X+Math.imul(t,g)|0,X=X+Math.imul(e,q0)|0,$=$+Math.imul(e,g)|0,G=G+Math.imul(y,a)|0,X=X+Math.imul(y,X0)|0,X=X+Math.imul(h,a)|0,$=$+Math.imul(h,X0)|0,G=G+Math.imul(m,F0)|0,X=X+Math.imul(m,T0)|0,X=X+Math.imul(i,F0)|0,$=$+Math.imul(i,T0)|0,G=G+Math.imul(r,S0)|0,X=X+Math.imul(r,x0)|0,X=X+Math.imul(d,S0)|0,$=$+Math.imul(d,x0)|0,G=G+Math.imul(p,P0)|0,X=X+Math.imul(p,C0)|0,X=X+Math.imul(n,P0)|0,$=$+Math.imul(n,C0)|0;var XU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(XU>>>26)|0,XU&=67108863,G=Math.imul(O0,j0),X=Math.imul(O0,M0),X=X+Math.imul(D0,j0)|0,$=Math.imul(D0,M0),G=G+Math.imul(W0,v0)|0,X=X+Math.imul(W0,R0)|0,X=X+Math.imul(H0,v0)|0,$=$+Math.imul(H0,R0)|0,G=G+Math.imul(s,_0)|0,X=X+Math.imul(s,B0)|0,X=X+Math.imul(Z0,_0)|0,$=$+Math.imul(Z0,B0)|0,G=G+Math.imul(c,q0)|0,X=X+Math.imul(c,g)|0,X=X+Math.imul(o,q0)|0,$=$+Math.imul(o,g)|0,G=G+Math.imul(t,a)|0,X=X+Math.imul(t,X0)|0,X=X+Math.imul(e,a)|0,$=$+Math.imul(e,X0)|0,G=G+Math.imul(y,F0)|0,X=X+Math.imul(y,T0)|0,X=X+Math.imul(h,F0)|0,$=$+Math.imul(h,T0)|0,G=G+Math.imul(m,S0)|0,X=X+Math.imul(m,x0)|0,X=X+Math.imul(i,S0)|0,$=$+Math.imul(i,x0)|0,G=G+Math.imul(r,P0)|0,X=X+Math.imul(r,C0)|0,X=X+Math.imul(d,P0)|0,$=$+Math.imul(d,C0)|0;var ZU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,G=Math.imul(O0,v0),X=Math.imul(O0,R0),X=X+Math.imul(D0,v0)|0,$=Math.imul(D0,R0),G=G+Math.imul(W0,_0)|0,X=X+Math.imul(W0,B0)|0,X=X+Math.imul(H0,_0)|0,$=$+Math.imul(H0,B0)|0,G=G+Math.imul(s,q0)|0,X=X+Math.imul(s,g)|0,X=X+Math.imul(Z0,q0)|0,$=$+Math.imul(Z0,g)|0,G=G+Math.imul(c,a)|0,X=X+Math.imul(c,X0)|0,X=X+Math.imul(o,a)|0,$=$+Math.imul(o,X0)|0,G=G+Math.imul(t,F0)|0,X=X+Math.imul(t,T0)|0,X=X+Math.imul(e,F0)|0,$=$+Math.imul(e,T0)|0,G=G+Math.imul(y,S0)|0,X=X+Math.imul(y,x0)|0,X=X+Math.imul(h,S0)|0,$=$+Math.imul(h,x0)|0,G=G+Math.imul(m,P0)|0,X=X+Math.imul(m,C0)|0,X=X+Math.imul(i,P0)|0,$=$+Math.imul(i,C0)|0;var QU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(QU>>>26)|0,QU&=67108863,G=Math.imul(O0,_0),X=Math.imul(O0,B0),X=X+Math.imul(D0,_0)|0,$=Math.imul(D0,B0),G=G+Math.imul(W0,q0)|0,X=X+Math.imul(W0,g)|0,X=X+Math.imul(H0,q0)|0,$=$+Math.imul(H0,g)|0,G=G+Math.imul(s,a)|0,X=X+Math.imul(s,X0)|0,X=X+Math.imul(Z0,a)|0,$=$+Math.imul(Z0,X0)|0,G=G+Math.imul(c,F0)|0,X=X+Math.imul(c,T0)|0,X=X+Math.imul(o,F0)|0,$=$+Math.imul(o,T0)|0,G=G+Math.imul(t,S0)|0,X=X+Math.imul(t,x0)|0,X=X+Math.imul(e,S0)|0,$=$+Math.imul(e,x0)|0,G=G+Math.imul(y,P0)|0,X=X+Math.imul(y,C0)|0,X=X+Math.imul(h,P0)|0,$=$+Math.imul(h,C0)|0;var YU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(YU>>>26)|0,YU&=67108863,G=Math.imul(O0,q0),X=Math.imul(O0,g),X=X+Math.imul(D0,q0)|0,$=Math.imul(D0,g),G=G+Math.imul(W0,a)|0,X=X+Math.imul(W0,X0)|0,X=X+Math.imul(H0,a)|0,$=$+Math.imul(H0,X0)|0,G=G+Math.imul(s,F0)|0,X=X+Math.imul(s,T0)|0,X=X+Math.imul(Z0,F0)|0,$=$+Math.imul(Z0,T0)|0,G=G+Math.imul(c,S0)|0,X=X+Math.imul(c,x0)|0,X=X+Math.imul(o,S0)|0,$=$+Math.imul(o,x0)|0,G=G+Math.imul(t,P0)|0,X=X+Math.imul(t,C0)|0,X=X+Math.imul(e,P0)|0,$=$+Math.imul(e,C0)|0;var JU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(JU>>>26)|0,JU&=67108863,G=Math.imul(O0,a),X=Math.imul(O0,X0),X=X+Math.imul(D0,a)|0,$=Math.imul(D0,X0),G=G+Math.imul(W0,F0)|0,X=X+Math.imul(W0,T0)|0,X=X+Math.imul(H0,F0)|0,$=$+Math.imul(H0,T0)|0,G=G+Math.imul(s,S0)|0,X=X+Math.imul(s,x0)|0,X=X+Math.imul(Z0,S0)|0,$=$+Math.imul(Z0,x0)|0,G=G+Math.imul(c,P0)|0,X=X+Math.imul(c,C0)|0,X=X+Math.imul(o,P0)|0,$=$+Math.imul(o,C0)|0;var VU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(VU>>>26)|0,VU&=67108863,G=Math.imul(O0,F0),X=Math.imul(O0,T0),X=X+Math.imul(D0,F0)|0,$=Math.imul(D0,T0),G=G+Math.imul(W0,S0)|0,X=X+Math.imul(W0,x0)|0,X=X+Math.imul(H0,S0)|0,$=$+Math.imul(H0,x0)|0,G=G+Math.imul(s,P0)|0,X=X+Math.imul(s,C0)|0,X=X+Math.imul(Z0,P0)|0,$=$+Math.imul(Z0,C0)|0;var GU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(GU>>>26)|0,GU&=67108863,G=Math.imul(O0,S0),X=Math.imul(O0,x0),X=X+Math.imul(D0,S0)|0,$=Math.imul(D0,x0),G=G+Math.imul(W0,P0)|0,X=X+Math.imul(W0,C0)|0,X=X+Math.imul(H0,P0)|0,$=$+Math.imul(H0,C0)|0;var IU=(F+G|0)+((X&8191)<<13)|0;F=($+(X>>>13)|0)+(IU>>>26)|0,IU&=67108863,G=Math.imul(O0,P0),X=Math.imul(O0,C0),X=X+Math.imul(D0,P0)|0,$=Math.imul(D0,C0);var $U=(F+G|0)+((X&8191)<<13)|0;if(F=($+(X>>>13)|0)+($U>>>26)|0,$U&=67108863,K[0]=s0,K[1]=c0,K[2]=y0,K[3]=l0,K[4]=b0,K[5]=r0,K[6]=a0,K[7]=e0,K[8]=i0,K[9]=UU,K[10]=XU,K[11]=ZU,K[12]=QU,K[13]=YU,K[14]=JU,K[15]=VU,K[16]=GU,K[17]=IU,K[18]=$U,F!==0)K[19]=F,J.length++;return J};if(!Math.imul)k=_;function j(U,Q,J){J.negative=Q.negative^U.negative,J.length=U.length+Q.length;var Z=0,Y=0;for(var K=0;K<J.length-1;K++){var F=Y;Y=0;var G=Z&67108863,X=Math.min(K,Q.length-1);for(var $=Math.max(0,K-U.length+1);$<=X;$++){var M=K-$,A=U.words[M]|0,B=Q.words[$]|0,w=A*B,p=w&67108863;F=F+(w/67108864|0)|0,p=p+G|0,G=p&67108863,F=F+(p>>>26)|0,Y+=F>>>26,F&=67108863}J.words[K]=G,Z=F,F=Y}if(Z!==0)J.words[K]=Z;else J.length--;return J.strip()}function v(U,Q,J){var Z=new x;return Z.mulp(U,Q,J)}V.prototype.mulTo=function(U,Q){var J,Z=this.length+U.length;if(this.length===10&&U.length===10)J=k(this,U,Q);else if(Z<63)J=_(this,U,Q);else if(Z<1024)J=j(this,U,Q);else J=v(this,U,Q);return J};function x(U,Q){this.x=U,this.y=Q}x.prototype.makeRBT=function(U){var Q=Array(U),J=V.prototype._countBits(U)-1;for(var Z=0;Z<U;Z++)Q[Z]=this.revBin(Z,J,U);return Q},x.prototype.revBin=function(U,Q,J){if(U===0||U===J-1)return U;var Z=0;for(var Y=0;Y<Q;Y++)Z|=(U&1)<<Q-Y-1,U>>=1;return Z},x.prototype.permute=function(U,Q,J,Z,Y,K){for(var F=0;F<K;F++)Z[F]=Q[U[F]],Y[F]=J[U[F]]},x.prototype.transform=function(U,Q,J,Z,Y,K){this.permute(K,U,Q,J,Z,Y);for(var F=1;F<Y;F<<=1){var G=F<<1,X=Math.cos(2*Math.PI/G),$=Math.sin(2*Math.PI/G);for(var M=0;M<Y;M+=G){var A=X,B=$;for(var w=0;w<F;w++){var p=J[M+w],n=Z[M+w],K0=J[M+w+F],r=Z[M+w+F],d=A*K0-B*r;if(r=A*r+B*K0,K0=d,J[M+w]=p+K0,Z[M+w]=n+r,J[M+w+F]=p-K0,Z[M+w+F]=n-r,w!==G)d=X*A-$*B,B=X*B+$*A,A=d}}}},x.prototype.guessLen13b=function(U,Q){var J=Math.max(Q,U)|1,Z=J&1,Y=0;for(J=J/2|0;J;J=J>>>1)Y++;return 1<<Y+1+Z},x.prototype.conjugate=function(U,Q,J){if(J<=1)return;for(var Z=0;Z<J/2;Z++){var Y=U[Z];U[Z]=U[J-Z-1],U[J-Z-1]=Y,Y=Q[Z],Q[Z]=-Q[J-Z-1],Q[J-Z-1]=-Y}},x.prototype.normalize13b=function(U,Q){var J=0;for(var Z=0;Z<Q/2;Z++){var Y=Math.round(U[2*Z+1]/Q)*8192+Math.round(U[2*Z]/Q)+J;if(U[Z]=Y&67108863,Y<67108864)J=0;else J=Y/67108864|0}return U},x.prototype.convert13b=function(U,Q,J,Z){var Y=0;for(var K=0;K<Q;K++)Y=Y+(U[K]|0),J[2*K]=Y&8191,Y=Y>>>13,J[2*K+1]=Y&8191,Y=Y>>>13;for(K=2*Q;K<Z;++K)J[K]=0;H(Y===0),H((Y&-8192)===0)},x.prototype.stub=function(U){var Q=Array(U);for(var J=0;J<U;J++)Q[J]=0;return Q},x.prototype.mulp=function(U,Q,J){var Z=2*this.guessLen13b(U.length,Q.length),Y=this.makeRBT(Z),K=this.stub(Z),F=Array(Z),G=Array(Z),X=Array(Z),$=Array(Z),M=Array(Z),A=Array(Z),B=J.words;B.length=Z,this.convert13b(U.words,U.length,F,Z),this.convert13b(Q.words,Q.length,$,Z),this.transform(F,K,G,X,Z,Y),this.transform($,K,M,A,Z,Y);for(var w=0;w<Z;w++){var p=G[w]*M[w]-X[w]*A[w];X[w]=G[w]*A[w]+X[w]*M[w],G[w]=p}return this.conjugate(G,X,Z),this.transform(G,X,B,K,Z,Y),this.conjugate(B,K,Z),this.normalize13b(B,Z),J.negative=U.negative^Q.negative,J.length=U.length+Q.length,J.strip()},V.prototype.mul=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),this.mulTo(U,Q)},V.prototype.mulf=function(U){var Q=new V(null);return Q.words=Array(this.length+U.length),v(this,U,Q)},V.prototype.imul=function(U){return this.clone().mulTo(U,this)},V.prototype.imuln=function(U){H(typeof U==="number"),H(U<67108864);var Q=0;for(var J=0;J<this.length;J++){var Z=(this.words[J]|0)*U,Y=(Z&67108863)+(Q&67108863);Q>>=26,Q+=Z/67108864|0,Q+=Y>>>26,this.words[J]=Y&67108863}if(Q!==0)this.words[J]=Q,this.length++;return this.length=U===0?1:this.length,this},V.prototype.muln=function(U){return this.clone().imuln(U)},V.prototype.sqr=function(){return this.mul(this)},V.prototype.isqr=function(){return this.imul(this.clone())},V.prototype.pow=function(U){var Q=q(U);if(Q.length===0)return new V(1);var J=this;for(var Z=0;Z<Q.length;Z++,J=J.sqr())if(Q[Z]!==0)break;if(++Z<Q.length)for(var Y=J.sqr();Z<Q.length;Z++,Y=Y.sqr()){if(Q[Z]===0)continue;J=J.mul(Y)}return J},V.prototype.iushln=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=67108863>>>26-Q<<26-Q,Y;if(Q!==0){var K=0;for(Y=0;Y<this.length;Y++){var F=this.words[Y]&Z,G=(this.words[Y]|0)-F<<Q;this.words[Y]=G|K,K=F>>>26-Q}if(K)this.words[Y]=K,this.length++}if(J!==0){for(Y=this.length-1;Y>=0;Y--)this.words[Y+J]=this.words[Y];for(Y=0;Y<J;Y++)this.words[Y]=0;this.length+=J}return this.strip()},V.prototype.ishln=function(U){return H(this.negative===0),this.iushln(U)},V.prototype.iushrn=function(U,Q,J){H(typeof U==="number"&&U>=0);var Z;if(Q)Z=(Q-Q%26)/26;else Z=0;var Y=U%26,K=Math.min((U-Y)/26,this.length),F=67108863^67108863>>>Y<<Y,G=J;if(Z-=K,Z=Math.max(0,Z),G){for(var X=0;X<K;X++)G.words[X]=this.words[X];G.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 $=0;for(X=this.length-1;X>=0&&($!==0||X>=Z);X--){var M=this.words[X]|0;this.words[X]=$<<26-Y|M>>>Y,$=M&F}if(G&&$!==0)G.words[G.length++]=$;if(this.length===0)this.words[0]=0,this.length=1;return this.strip()},V.prototype.ishrn=function(U,Q,J){return H(this.negative===0),this.iushrn(U,Q,J)},V.prototype.shln=function(U){return this.clone().ishln(U)},V.prototype.ushln=function(U){return this.clone().iushln(U)},V.prototype.shrn=function(U){return this.clone().ishrn(U)},V.prototype.ushrn=function(U){return this.clone().iushrn(U)},V.prototype.testn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return!1;var Y=this.words[J];return!!(Y&Z)},V.prototype.imaskn=function(U){H(typeof U==="number"&&U>=0);var Q=U%26,J=(U-Q)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=J)return this;if(Q!==0)J++;if(this.length=Math.min(J,this.length),Q!==0){var Z=67108863^67108863>>>Q<<Q;this.words[this.length-1]&=Z}return this.strip()},V.prototype.maskn=function(U){return this.clone().imaskn(U)},V.prototype.iaddn=function(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(U){this.words[0]+=U;for(var Q=0;Q<this.length&&this.words[Q]>=67108864;Q++)if(this.words[Q]-=67108864,Q===this.length-1)this.words[Q+1]=1;else this.words[Q+1]++;return this.length=Math.max(this.length,Q+1),this},V.prototype.isubn=function(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 Q=0;Q<this.length&&this.words[Q]<0;Q++)this.words[Q]+=67108864,this.words[Q+1]-=1;return this.strip()},V.prototype.addn=function(U){return this.clone().iaddn(U)},V.prototype.subn=function(U){return this.clone().isubn(U)},V.prototype.iabs=function(){return this.negative=0,this},V.prototype.abs=function(){return this.clone().iabs()},V.prototype._ishlnsubmul=function(U,Q,J){var Z=U.length+J,Y;this._expand(Z);var K,F=0;for(Y=0;Y<U.length;Y++){K=(this.words[Y+J]|0)+F;var G=(U.words[Y]|0)*Q;K-=G&67108863,F=(K>>26)-(G/67108864|0),this.words[Y+J]=K&67108863}for(;Y<this.length-J;Y++)K=(this.words[Y+J]|0)+F,F=K>>26,this.words[Y+J]=K&67108863;if(F===0)return this.strip();H(F===-1),F=0;for(Y=0;Y<this.length;Y++)K=-(this.words[Y]|0)+F,F=K>>26,this.words[Y]=K&67108863;return this.negative=1,this.strip()},V.prototype._wordDiv=function(U,Q){var J=this.length-U.length,Z=this.clone(),Y=U,K=Y.words[Y.length-1]|0,F=this._countBits(K);if(J=26-F,J!==0)Y=Y.ushln(J),Z.iushln(J),K=Y.words[Y.length-1]|0;var G=Z.length-Y.length,X;if(Q!=="mod"){X=new V(null),X.length=G+1,X.words=Array(X.length);for(var $=0;$<X.length;$++)X.words[$]=0}var M=Z.clone()._ishlnsubmul(Y,1,G);if(M.negative===0){if(Z=M,X)X.words[G]=1}for(var A=G-1;A>=0;A--){var B=(Z.words[Y.length+A]|0)*67108864+(Z.words[Y.length+A-1]|0);B=Math.min(B/K|0,67108863),Z._ishlnsubmul(Y,B,A);while(Z.negative!==0)if(B--,Z.negative=0,Z._ishlnsubmul(Y,1,A),!Z.isZero())Z.negative^=1;if(X)X.words[A]=B}if(X)X.strip();if(Z.strip(),Q!=="div"&&J!==0)Z.iushrn(J);return{div:X||null,mod:Z}},V.prototype.divmod=function(U,Q,J){if(H(!U.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var Z,Y,K;if(this.negative!==0&&U.negative===0){if(K=this.neg().divmod(U,Q),Q!=="mod")Z=K.div.neg();if(Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.iadd(U)}return{div:Z,mod:Y}}if(this.negative===0&&U.negative!==0){if(K=this.divmod(U.neg(),Q),Q!=="mod")Z=K.div.neg();return{div:Z,mod:K.mod}}if((this.negative&U.negative)!==0){if(K=this.neg().divmod(U.neg(),Q),Q!=="div"){if(Y=K.mod.neg(),J&&Y.negative!==0)Y.isub(U)}return{div:K.div,mod:Y}}if(U.length>this.length||this.cmp(U)<0)return{div:new V(0),mod:this};if(U.length===1){if(Q==="div")return{div:this.divn(U.words[0]),mod:null};if(Q==="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,Q)},V.prototype.div=function(U){return this.divmod(U,"div",!1).div},V.prototype.mod=function(U){return this.divmod(U,"mod",!1).mod},V.prototype.umod=function(U){return this.divmod(U,"mod",!0).mod},V.prototype.divRound=function(U){var Q=this.divmod(U);if(Q.mod.isZero())return Q.div;var J=Q.div.negative!==0?Q.mod.isub(U):Q.mod,Z=U.ushrn(1),Y=U.andln(1),K=J.cmp(Z);if(K<0||Y===1&&K===0)return Q.div;return Q.div.negative!==0?Q.div.isubn(1):Q.div.iaddn(1)},V.prototype.modn=function(U){H(U<=67108863);var Q=67108864%U,J=0;for(var Z=this.length-1;Z>=0;Z--)J=(Q*J+(this.words[Z]|0))%U;return J},V.prototype.idivn=function(U){H(U<=67108863);var Q=0;for(var J=this.length-1;J>=0;J--){var Z=(this.words[J]|0)+Q*67108864;this.words[J]=Z/U|0,Q=Z%U}return this.strip()},V.prototype.divn=function(U){return this.clone().idivn(U)},V.prototype.egcd=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=new V(0),F=new V(1),G=0;while(Q.isEven()&&J.isEven())Q.iushrn(1),J.iushrn(1),++G;var X=J.clone(),$=Q.clone();while(!Q.isZero()){for(var M=0,A=1;(Q.words[0]&A)===0&&M<26;++M,A<<=1);if(M>0){Q.iushrn(M);while(M-- >0){if(Z.isOdd()||Y.isOdd())Z.iadd(X),Y.isub($);Z.iushrn(1),Y.iushrn(1)}}for(var B=0,w=1;(J.words[0]&w)===0&&B<26;++B,w<<=1);if(B>0){J.iushrn(B);while(B-- >0){if(K.isOdd()||F.isOdd())K.iadd(X),F.isub($);K.iushrn(1),F.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(K),Y.isub(F);else J.isub(Q),K.isub(Z),F.isub(Y)}return{a:K,b:F,gcd:J.iushln(G)}},V.prototype._invmp=function(U){H(U.negative===0),H(!U.isZero());var Q=this,J=U.clone();if(Q.negative!==0)Q=Q.umod(U);else Q=Q.clone();var Z=new V(1),Y=new V(0),K=J.clone();while(Q.cmpn(1)>0&&J.cmpn(1)>0){for(var F=0,G=1;(Q.words[0]&G)===0&&F<26;++F,G<<=1);if(F>0){Q.iushrn(F);while(F-- >0){if(Z.isOdd())Z.iadd(K);Z.iushrn(1)}}for(var X=0,$=1;(J.words[0]&$)===0&&X<26;++X,$<<=1);if(X>0){J.iushrn(X);while(X-- >0){if(Y.isOdd())Y.iadd(K);Y.iushrn(1)}}if(Q.cmp(J)>=0)Q.isub(J),Z.isub(Y);else J.isub(Q),Y.isub(Z)}var M;if(Q.cmpn(1)===0)M=Z;else M=Y;if(M.cmpn(0)<0)M.iadd(U);return M},V.prototype.gcd=function(U){if(this.isZero())return U.abs();if(U.isZero())return this.abs();var Q=this.clone(),J=U.clone();Q.negative=0,J.negative=0;for(var Z=0;Q.isEven()&&J.isEven();Z++)Q.iushrn(1),J.iushrn(1);do{while(Q.isEven())Q.iushrn(1);while(J.isEven())J.iushrn(1);var Y=Q.cmp(J);if(Y<0){var K=Q;Q=J,J=K}else if(Y===0||J.cmpn(1)===0)break;Q.isub(J)}while(!0);return J.iushln(Z)},V.prototype.invm=function(U){return this.egcd(U).a.umod(U)},V.prototype.isEven=function(){return(this.words[0]&1)===0},V.prototype.isOdd=function(){return(this.words[0]&1)===1},V.prototype.andln=function(U){return this.words[0]&U},V.prototype.bincn=function(U){H(typeof U==="number");var Q=U%26,J=(U-Q)/26,Z=1<<Q;if(this.length<=J)return this._expand(J+1),this.words[J]|=Z,this;var Y=Z;for(var K=J;Y!==0&&K<this.length;K++){var F=this.words[K]|0;F+=Y,Y=F>>>26,F&=67108863,this.words[K]=F}if(Y!==0)this.words[K]=Y,this.length++;return this},V.prototype.isZero=function(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function(U){var Q=U<0;if(this.negative!==0&&!Q)return-1;if(this.negative===0&&Q)return 1;this.strip();var J;if(this.length>1)J=1;else{if(Q)U=-U;H(U<=67108863,"Number is too big");var Z=this.words[0]|0;J=Z===U?0:Z<U?-1:1}if(this.negative!==0)return-J|0;return J},V.prototype.cmp=function(U){if(this.negative!==0&&U.negative===0)return-1;if(this.negative===0&&U.negative!==0)return 1;var Q=this.ucmp(U);if(this.negative!==0)return-Q|0;return Q},V.prototype.ucmp=function(U){if(this.length>U.length)return 1;if(this.length<U.length)return-1;var Q=0;for(var J=this.length-1;J>=0;J--){var Z=this.words[J]|0,Y=U.words[J]|0;if(Z===Y)continue;if(Z<Y)Q=-1;else if(Z>Y)Q=1;break}return Q},V.prototype.gtn=function(U){return this.cmpn(U)===1},V.prototype.gt=function(U){return this.cmp(U)===1},V.prototype.gten=function(U){return this.cmpn(U)>=0},V.prototype.gte=function(U){return this.cmp(U)>=0},V.prototype.ltn=function(U){return this.cmpn(U)===-1},V.prototype.lt=function(U){return this.cmp(U)===-1},V.prototype.lten=function(U){return this.cmpn(U)<=0},V.prototype.lte=function(U){return this.cmp(U)<=0},V.prototype.eqn=function(U){return this.cmpn(U)===0},V.prototype.eq=function(U){return this.cmp(U)===0},V.red=function(U){return new u(U)},V.prototype.toRed=function(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(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function(U){return this.red=U,this},V.prototype.forceRed=function(U){return H(!this.red,"Already a number in reduction context"),this._forceRed(U)},V.prototype.redAdd=function(U){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,U)},V.prototype.redIAdd=function(U){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,U)},V.prototype.redSub=function(U){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,U)},V.prototype.redISub=function(U){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,U)},V.prototype.redShl=function(U){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,U)},V.prototype.redMul=function(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(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(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function(U){return H(this.red&&!U.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,U)};var N={k256:null,p224:null,p192:null,p25519:null};function f(U,Q){this.name=U,this.p=new V(Q,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(){var U=new V(null);return U.words=Array(Math.ceil(this.n/13)),U},f.prototype.ireduce=function(U){var Q=U,J;do this.split(Q,this.tmp),Q=this.imulK(Q),Q=Q.iadd(this.tmp),J=Q.bitLength();while(J>this.n);var Z=J<this.n?-1:Q.ucmp(this.p);if(Z===0)Q.words[0]=0,Q.length=1;else if(Z>0)Q.isub(this.p);else if(Q.strip!==void 0)Q.strip();else Q._strip();return Q},f.prototype.split=function(U,Q){U.iushrn(this.n,0,Q)},f.prototype.imulK=function(U){return U.imul(this.k)};function b(){f.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}L(b,f),b.prototype.split=function(U,Q){var J=4194303,Z=Math.min(U.length,9);for(var Y=0;Y<Z;Y++)Q.words[Y]=U.words[Y];if(Q.length=Z,U.length<=9){U.words[0]=0,U.length=1;return}var K=U.words[9];Q.words[Q.length++]=K&J;for(Y=10;Y<U.length;Y++){var F=U.words[Y]|0;U.words[Y-10]=(F&J)<<4|K>>>22,K=F}if(K>>>=22,U.words[Y-10]=K,K===0&&U.length>10)U.length-=10;else U.length-=9},b.prototype.imulK=function(U){U.words[U.length]=0,U.words[U.length+1]=0,U.length+=2;var Q=0;for(var J=0;J<U.length;J++){var Z=U.words[J]|0;Q+=Z*977,U.words[J]=Q&67108863,Q=Z*64+(Q/67108864|0)}if(U.words[U.length-1]===0){if(U.length--,U.words[U.length-1]===0)U.length--}return U};function Q0(){f.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}L(Q0,f);function G0(){f.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}L(G0,f);function Y0(){f.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}L(Y0,f),Y0.prototype.imulK=function(U){var Q=0;for(var J=0;J<U.length;J++){var Z=(U.words[J]|0)*19+Q,Y=Z&67108863;Z>>>=26,U.words[J]=Y,Q=Z}if(Q!==0)U.words[U.length++]=Q;return U},V._prime=function(U){if(N[U])return N[U];var Q;if(U==="k256")Q=new b;else if(U==="p224")Q=new Q0;else if(U==="p192")Q=new G0;else if(U==="p25519")Q=new Y0;else throw Error("Unknown prime "+U);return N[U]=Q,Q};function u(U){if(typeof U==="string"){var Q=V._prime(U);this.m=Q.p,this.prime=Q}else H(U.gtn(1),"modulus must be greater than 1"),this.m=U,this.prime=null}u.prototype._verify1=function(U){H(U.negative===0,"red works only with positives"),H(U.red,"red works only with red numbers")},u.prototype._verify2=function(U,Q){H((U.negative|Q.negative)===0,"red works only with positives"),H(U.red&&U.red===Q.red,"red works only with red numbers")},u.prototype.imod=function(U){if(this.prime)return this.prime.ireduce(U)._forceRed(this);return U.umod(this.m)._forceRed(this)},u.prototype.neg=function(U){if(U.isZero())return U.clone();return this.m.sub(U)._forceRed(this)},u.prototype.add=function(U,Q){this._verify2(U,Q);var J=U.add(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J._forceRed(this)},u.prototype.iadd=function(U,Q){this._verify2(U,Q);var J=U.iadd(Q);if(J.cmp(this.m)>=0)J.isub(this.m);return J},u.prototype.sub=function(U,Q){this._verify2(U,Q);var J=U.sub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J._forceRed(this)},u.prototype.isub=function(U,Q){this._verify2(U,Q);var J=U.isub(Q);if(J.cmpn(0)<0)J.iadd(this.m);return J},u.prototype.shl=function(U,Q){return this._verify1(U),this.imod(U.ushln(Q))},u.prototype.imul=function(U,Q){return this._verify2(U,Q),this.imod(U.imul(Q))},u.prototype.mul=function(U,Q){return this._verify2(U,Q),this.imod(U.mul(Q))},u.prototype.isqr=function(U){return this.imul(U,U.clone())},u.prototype.sqr=function(U){return this.mul(U,U)},u.prototype.sqrt=function(U){if(U.isZero())return U.clone();var Q=this.m.andln(3);if(H(Q%2===1),Q===3){var J=this.m.add(new V(1)).iushrn(2);return this.pow(U,J)}var Z=this.m.subn(1),Y=0;while(!Z.isZero()&&Z.andln(1)===0)Y++,Z.iushrn(1);H(!Z.isZero());var K=new V(1).toRed(this),F=K.redNeg(),G=this.m.subn(1).iushrn(1),X=this.m.bitLength();X=new V(2*X*X).toRed(this);while(this.pow(X,G).cmp(F)!==0)X.redIAdd(F);var $=this.pow(X,Z),M=this.pow(U,Z.addn(1).iushrn(1)),A=this.pow(U,Z),B=Y;while(A.cmp(K)!==0){var w=A;for(var p=0;w.cmp(K)!==0;p++)w=w.redSqr();H(p<B);var n=this.pow($,new V(1).iushln(B-p-1));M=M.redMul(n),$=n.redSqr(),A=A.redMul($),B=p}return M},u.prototype.invm=function(U){var Q=U._invmp(this.m);if(Q.negative!==0)return Q.negative=0,this.imod(Q).redNeg();else return this.imod(Q)},u.prototype.pow=function(U,Q){if(Q.isZero())return new V(1).toRed(this);if(Q.cmpn(1)===0)return U.clone();var J=4,Z=Array(1<<J);Z[0]=new V(1).toRed(this),Z[1]=U;for(var Y=2;Y<Z.length;Y++)Z[Y]=this.mul(Z[Y-1],U);var K=Z[0],F=0,G=0,X=Q.bitLength()%26;if(X===0)X=26;for(Y=Q.length-1;Y>=0;Y--){var $=Q.words[Y];for(var M=X-1;M>=0;M--){var A=$>>M&1;if(K!==Z[0])K=this.sqr(K);if(A===0&&F===0){G=0;continue}if(F<<=1,F|=A,G++,G!==J&&(Y!==0||M!==0))continue;K=this.mul(K,Z[F]),G=0,F=0}X=26}return K},u.prototype.convertTo=function(U){var Q=U.umod(this.m);return Q===U?Q.clone():Q},u.prototype.convertFrom=function(U){var Q=U.clone();return Q.red=null,Q},V.mont=function(U){return new U0(U)};function U0(U){if(u.call(this,U),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)}L(U0,u),U0.prototype.convertTo=function(U){return this.imod(U.ushln(this.shift))},U0.prototype.convertFrom=function(U){var Q=this.imod(U.mul(this.rinv));return Q.red=null,Q},U0.prototype.imul=function(U,Q){if(U.isZero()||Q.isZero())return U.words[0]=0,U.length=1,U;var J=U.imul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.mul=function(U,Q){if(U.isZero()||Q.isZero())return new V(0)._forceRed(this);var J=U.mul(Q),Z=J.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),Y=J.isub(Z).iushrn(this.shift),K=Y;if(Y.cmp(this.m)>=0)K=Y.isub(this.m);else if(Y.cmpn(0)<0)K=Y.iadd(this.m);return K._forceRed(this)},U0.prototype.invm=function(U){var Q=this.imod(U._invmp(this.m).mul(this.r2));return Q._forceRed(this)}})(typeof O>"u"||O,I)}),oQ=I0((I,O)=>{var W=HZ(),T=EU().Buffer;function H(L,V){return T.from(L.toRed(W.mont(V.modulus)).redPow(new W(V.publicExponent)).fromRed().toArray())}O.exports=H}),oV=I0((I,O)=>{(function(W,T){function H(Z,Y){if(!Z)throw Error(Y||"Assertion failed")}function L(Z,Y){Z.super_=Y;var K=function(){};K.prototype=Y.prototype,Z.prototype=new K,Z.prototype.constructor=Z}function V(Z,Y,K){if(V.isBN(Z))return Z;if(this.negative=0,this.words=null,this.length=0,this.red=null,Z!==null){if(Y==="le"||Y==="be")K=Y,Y=10;this._init(Z||0,Y||10,K||"be")}}if(typeof W==="object")W.exports=V;else T.BN=V;V.BN=V,V.wordSize=26;var P;try{if(typeof window<"u"&&typeof window.Buffer<"u")P=window.Buffer;else P=(HU(),h0(WU)).Buffer}catch(Z){}V.isBN=function(Z){if(Z instanceof V)return!0;return Z!==null&&typeof Z==="object"&&Z.constructor.wordSize===V.wordSize&&Array.isArray(Z.words)},V.max=function(Z,Y){if(Z.cmp(Y)>0)return Z;return Y},V.min=function(Z,Y){if(Z.cmp(Y)<0)return Z;return Y},V.prototype._init=function(Z,Y,K){if(typeof Z==="number")return this._initNumber(Z,Y,K);if(typeof Z==="object")return this._initArray(Z,Y,K);if(Y==="hex")Y=16;H(Y===(Y|0)&&Y>=2&&Y<=36),Z=Z.toString().replace(/\s+/g,"");var F=0;if(Z[0]==="-")F++,this.negative=1;if(F<Z.length){if(Y===16)this._parseHex(Z,F,K);else if(this._parseBase(Z,Y,F),K==="le")this._initArray(this.toArray(),Y,K)}},V.prototype._initNumber=function(Z,Y,K){if(Z<0)this.negative=1,Z=-Z;if(Z<67108864)this.words=[Z&67108863],this.length=1;else if(Z<4503599627370496)this.words=[Z&67108863,Z/67108864&67108863],this.length=2;else H(Z<9007199254740992),this.words=[Z&67108863,Z/67108864&67108863,1],this.length=3;if(K!=="le")return;this._initArray(this.toArray(),Y,K)},V.prototype._initArray=function(Z,Y,K){if(H(typeof Z.length==="number"),Z.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(Z.length/3),this.words=Array(this.length);for(var F=0;F<this.length;F++)this.words[F]=0;var G,X,$=0;if(K==="be"){for(F=Z.length-1,G=0;F>=0;F-=3)if(X=Z[F]|Z[F-1]<<8|Z[F-2]<<16,this.words[G]|=X<<$&67108863,this.words[G+1]=X>>>26-$&67108863,$+=24,$>=26)$-=26,G++}else if(K==="le"){for(F=0,G=0;F<Z.length;F+=3)if(X=Z[F]|Z[F+1]<<8|Z[F+2]<<16,this.words[G]|=X<<$&67108863,this.words[G+1]=X>>>26-$&67108863,$+=24,$>=26)$-=26,G++}return this._strip()};function S(Z,Y){var K=Z.charCodeAt(Y);if(K>=48&&K<=57)return K-48;else if(K>=65&&K<=70)return K-55;else if(K>=97&&K<=102)return K-87;else H(!1,"Invalid character in "+Z)}function E(Z,Y,K){var F=S(Z,K);if(K-1>=Y)F|=S(Z,K-1)<<4;return F}V.prototype._parseHex=function(Z,Y,K){this.length=Math.ceil((Z.length-Y)/6),this.words=Array(this.length);for(var F=0;F<this.length;F++)this.words[F]=0;var G=0,X=0,$;if(K==="be")for(F=Z.length-1;F>=Y;F-=2)if($=E(Z,Y,F)<<G,this.words[X]|=$&67108863,G>=18)G-=18,X+=1,this.words[X]|=$>>>26;else G+=8;else{var M=Z.length-Y;for(F=M%2===0?Y+1:Y;F<Z.length;F+=2)if($=E(Z,Y,F)<<G,this.words[X]|=$&67108863,G>=18)G-=18,X+=1,this.words[X]|=$>>>26;else G+=8}this._strip()};function C(Z,Y,K,F){var G=0,X=0,$=Math.min(Z.length,K);for(var M=Y;M<$;M++){var A=Z.charCodeAt(M)-48;if(G*=F,A>=49)X=A-49+10;else if(A>=17)X=A-17+10;else X=A;H(A>=0&&X<F,"Invalid character"),G+=X}return G}V.prototype._parseBase=function(Z,Y,K){this.words=[0],this.length=1;for(var F=0,G=1;G<=67108863;G*=Y)F++;F--,G=G/Y|0;var X=Z.length-K,$=X%F,M=Math.min(X,X-$)+K,A=0;for(var B=K;B<M;B+=F)if(A=C(Z,B,B+F,Y),this.imuln(G),this.words[0]+A<67108864)this.words[0]+=A;else this._iaddn(A);if($!==0){var w=1;A=C(Z,B,Z.length,Y);for(B=0;B<$;B++)w*=Y;if(this.imuln(w),this.words[0]+A<67108864)this.words[0]+=A;else this._iaddn(A)}this._strip()},V.prototype.copy=function(Z){Z.words=Array(this.length);for(var Y=0;Y<this.length;Y++)Z.words[Y]=this.words[Y];Z.length=this.length,Z.negative=this.negative,Z.red=this.red};function D(Z,Y){Z.words=Y.words,Z.length=Y.length,Z.negative=Y.negative,Z.red=Y.red}if(V.prototype._move=function(Z){D(Z,this)},V.prototype.clone=function(){var Z=new V(null);return this.copy(Z),Z},V.prototype._expand=function(Z){while(this.length<Z)this.words[this.length++]=0;return this},V.prototype._strip=function(){while(this.length>1&&this.words[this.length-1]===0)this.length--;return this._normSign()},V.prototype._normSign=function(){if(this.length===1&&this.words[0]===0)this.negative=0;return this},typeof Symbol<"u"&&typeof Symbol.for==="function")try{V.prototype[Symbol.for("nodejs.util.inspect.custom")]=z}catch(Z){V.prototype.inspect=z}else V.prototype.inspect=z;function z(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var R=["","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"],q=[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],_=[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(Z,Y){Z=Z||10,Y=Y|0||1;var K;if(Z===16||Z==="hex"){K="";var F=0,G=0;for(var X=0;X<this.length;X++){var $=this.words[X],M=(($<<F|G)&16777215).toString(16);if(G=$>>>24-F&16777215,F+=2,F>=26)F-=26,X--;if(G!==0||X!==this.length-1)K=R[6-M.length]+M+K;else K=M+K}if(G!==0)K=G.toString(16)+K;while(K.length%Y!==0)K="0"+K;if(this.negative!==0)K="-"+K;return K}if(Z===(Z|0)&&Z>=2&&Z<=36){var A=q[Z],B=_[Z];K="";var w=this.clone();w.negative=0;while(!w.isZero()){var p=w.modrn(B).toString(Z);if(w=w.idivn(B),!w.isZero())K=R[A-p.length]+p+K;else K=p+K}if(this.isZero())K="0"+K;while(K.length%Y!==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(){var Z=this.words[0];if(this.length===2)Z+=this.words[1]*67108864;else if(this.length===3&&this.words[2]===1)Z+=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?-Z:Z},V.prototype.toJSON=function(){return this.toString(16,2)},P)V.prototype.toBuffer=function(Z,Y){return this.toArrayLike(P,Z,Y)};V.prototype.toArray=function(Z,Y){return this.toArrayLike(Array,Z,Y)};var k=function(Z,Y){if(Z.allocUnsafe)return Z.allocUnsafe(Y);return new Z(Y)};if(V.prototype.toArrayLike=function(Z,Y,K){this._strip();var F=this.byteLength(),G=K||Math.max(1,F);H(F<=G,"byte array longer than desired length"),H(G>0,"Requested array length <= 0");var X=k(Z,G),$=Y==="le"?"LE":"BE";return this["_toArrayLike"+$](X,F),X},V.prototype._toArrayLikeLE=function(Z,Y){var K=0,F=0;for(var G=0,X=0;G<this.length;G++){var $=this.words[G]<<X|F;if(Z[K++]=$&255,K<Z.length)Z[K++]=$>>8&255;if(K<Z.length)Z[K++]=$>>16&255;if(X===6){if(K<Z.length)Z[K++]=$>>24&255;F=0,X=0}else F=$>>>24,X+=2}if(K<Z.length){Z[K++]=F;while(K<Z.length)Z[K++]=0}},V.prototype._toArrayLikeBE=function(Z,Y){var K=Z.length-1,F=0;for(var G=0,X=0;G<this.length;G++){var $=this.words[G]<<X|F;if(Z[K--]=$&255,K>=0)Z[K--]=$>>8&255;if(K>=0)Z[K--]=$>>16&255;if(X===6){if(K>=0)Z[K--]=$>>24&255;F=0,X=0}else F=$>>>24,X+=2}if(K>=0){Z[K--]=F;while(K>=0)Z[K--]=0}},Math.clz32)V.prototype._countBits=function(Z){return 32-Math.clz32(Z)};else V.prototype._countBits=function(Z){var Y=Z,K=0;if(Y>=4096)K+=13,Y>>>=13;if(Y>=64)K+=7,Y>>>=7;if(Y>=8)K+=4,Y>>>=4;if(Y>=2)K+=2,Y>>>=2;return K+Y};V.prototype._zeroBits=function(Z){if(Z===0)return 26;var Y=Z,K=0;if((Y&8191)===0)K+=13,Y>>>=13;if((Y&127)===0)K+=7,Y>>>=7;if((Y&15)===0)K+=4,Y>>>=4;if((Y&3)===0)K+=2,Y>>>=2;if((Y&1)===0)K++;return K},V.prototype.bitLength=function(){var Z=this.words[this.length-1],Y=this._countBits(Z);return(this.length-1)*26+Y};function j(Z){var Y=Array(Z.bitLength());for(var K=0;K<Y.length;K++){var F=K/26|0,G=K%26;Y[K]=Z.words[F]>>>G&1}return Y}V.prototype.zeroBits=function(){if(this.isZero())return 0;var Z=0;for(var Y=0;Y<this.length;Y++){var K=this._zeroBits(this.words[Y]);if(Z+=K,K!==26)break}return Z},V.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},V.prototype.toTwos=function(Z){if(this.negative!==0)return this.abs().inotn(Z).iaddn(1);return this.clone()},V.prototype.fromTwos=function(Z){if(this.testn(Z-1))return this.notn(Z).iaddn(1).ineg();return this.clone()},V.prototype.isNeg=function(){return this.negative!==0},V.prototype.neg=function(){return this.clone().ineg()},V.prototype.ineg=function(){if(!this.isZero())this.negative^=1;return this},V.prototype.iuor=function(Z){while(this.length<Z.length)this.words[this.length++]=0;for(var Y=0;Y<Z.length;Y++)this.words[Y]=this.words[Y]|Z.words[Y];return this._strip()},V.prototype.ior=function(Z){return H((this.negative|Z.negative)===0),this.iuor(Z)},V.prototype.or=function(Z){if(this.length>Z.length)return this.clone().ior(Z);return Z.clone().ior(this)},V.prototype.uor=function(Z){if(this.length>Z.length)return this.clone().iuor(Z);return Z.clone().iuor(this)},V.prototype.iuand=function(Z){var Y;if(this.length>Z.length)Y=Z;else Y=this;for(var K=0;K<Y.length;K++)this.words[K]=this.words[K]&Z.words[K];return this.length=Y.length,this._strip()},V.prototype.iand=function(Z){return H((this.negative|Z.negative)===0),this.iuand(Z)},V.prototype.and=function(Z){if(this.length>Z.length)return this.clone().iand(Z);return Z.clone().iand(this)},V.prototype.uand=function(Z){if(this.length>Z.length)return this.clone().iuand(Z);return Z.clone().iuand(this)},V.prototype.iuxor=function(Z){var Y,K;if(this.length>Z.length)Y=this,K=Z;else Y=Z,K=this;for(var F=0;F<K.length;F++)this.words[F]=Y.words[F]^K.words[F];if(this!==Y)for(;F<Y.length;F++)this.words[F]=Y.words[F];return this.length=Y.length,this._strip()},V.prototype.ixor=function(Z){return H((this.negative|Z.negative)===0),this.iuxor(Z)},V.prototype.xor=function(Z){if(this.length>Z.length)return this.clone().ixor(Z);return Z.clone().ixor(this)},V.prototype.uxor=function(Z){if(this.length>Z.length)return this.clone().iuxor(Z);return Z.clone().iuxor(this)},V.prototype.inotn=function(Z){H(typeof Z==="number"&&Z>=0);var Y=Math.ceil(Z/26)|0,K=Z%26;if(this._expand(Y),K>0)Y--;for(var F=0;F<Y;F++)this.words[F]=~this.words[F]&67108863;if(K>0)this.words[F]=~this.words[F]&67108863>>26-K;return this._strip()},V.prototype.notn=function(Z){return this.clone().inotn(Z)},V.prototype.setn=function(Z,Y){H(typeof Z==="number"&&Z>=0);var K=Z/26|0,F=Z%26;if(this._expand(K+1),Y)this.words[K]=this.words[K]|1<<F;else this.words[K]=this.words[K]&~(1<<F);return this._strip()},V.prototype.iadd=function(Z){var Y;if(this.negative!==0&&Z.negative===0)return this.negative=0,Y=this.isub(Z),this.negative^=1,this._normSign();else if(this.negative===0&&Z.negative!==0)return Z.negative=0,Y=this.isub(Z),Z.negative=1,Y._normSign();var K,F;if(this.length>Z.length)K=this,F=Z;else K=Z,F=this;var G=0;for(var X=0;X<F.length;X++)Y=(K.words[X]|0)+(F.words[X]|0)+G,this.words[X]=Y&67108863,G=Y>>>26;for(;G!==0&&X<K.length;X++)Y=(K.words[X]|0)+G,this.words[X]=Y&67108863,G=Y>>>26;if(this.length=K.length,G!==0)this.words[this.length]=G,this.length++;else if(K!==this)for(;X<K.length;X++)this.words[X]=K.words[X];return this},V.prototype.add=function(Z){var Y;if(Z.negative!==0&&this.negative===0)return Z.negative=0,Y=this.sub(Z),Z.negative^=1,Y;else if(Z.negative===0&&this.negative!==0)return this.negative=0,Y=Z.sub(this),this.negative=1,Y;if(this.length>Z.length)return this.clone().iadd(Z);return Z.clone().iadd(this)},V.prototype.isub=function(Z){if(Z.negative!==0){Z.negative=0;var Y=this.iadd(Z);return Z.negative=1,Y._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(Z),this.negative=1,this._normSign();var K=this.cmp(Z);if(K===0)return this.negative=0,this.length=1,this.words[0]=0,this;var F,G;if(K>0)F=this,G=Z;else F=Z,G=this;var X=0;for(var $=0;$<G.length;$++)Y=(F.words[$]|0)-(G.words[$]|0)+X,X=Y>>26,this.words[$]=Y&67108863;for(;X!==0&&$<F.length;$++)Y=(F.words[$]|0)+X,X=Y>>26,this.words[$]=Y&67108863;if(X===0&&$<F.length&&F!==this)for(;$<F.length;$++)this.words[$]=F.words[$];if(this.length=Math.max(this.length,$),F!==this)this.negative=1;return this._strip()},V.prototype.sub=function(Z){return this.clone().isub(Z)};function v(Z,Y,K){K.negative=Y.negative^Z.negative;var F=Z.length+Y.length|0;K.length=F,F=F-1|0;var G=Z.words[0]|0,X=Y.words[0]|0,$=G*X,M=$&67108863,A=$/67108864|0;K.words[0]=M;for(var B=1;B<F;B++){var w=A>>>26,p=A&67108863,n=Math.min(B,Y.length-1);for(var K0=Math.max(0,B-Z.length+1);K0<=n;K0++){var r=B-K0|0;G=Z.words[r]|0,X=Y.words[K0]|0,$=G*X+p,w+=$/67108864|0,p=$&67108863}K.words[B]=p|0,A=w|0}if(A!==0)K.words[B]=A|0;else K.length--;return K._strip()}var x=function(Z,Y,K){var F=Z.words,G=Y.words,X=K.words,$=0,M,A,B,w=F[0]|0,p=w&8191,n=w>>>13,K0=F[1]|0,r=K0&8191,d=K0>>>13,J0=F[2]|0,m=J0&8191,i=J0>>>13,g0=F[3]|0,y=g0&8191,h=g0>>>13,V0=F[4]|0,t=V0&8191,e=V0>>>13,E0=F[5]|0,c=E0&8191,o=E0>>>13,N0=F[6]|0,s=N0&8191,Z0=N0>>>13,f0=F[7]|0,W0=f0&8191,H0=f0>>>13,n0=F[8]|0,O0=n0&8191,D0=n0>>>13,t0=F[9]|0,z0=t0&8191,A0=t0>>>13,AU=G[0]|0,L0=AU&8191,k0=AU>>>13,zU=G[1]|0,j0=zU&8191,M0=zU>>>13,DU=G[2]|0,v0=DU&8191,R0=DU>>>13,KU=G[3]|0,_0=KU&8191,B0=KU>>>13,OU=G[4]|0,q0=OU&8191,g=OU>>>13,l=G[5]|0,a=l&8191,X0=l>>>13,w0=G[6]|0,F0=w0&8191,T0=w0>>>13,m0=G[7]|0,S0=m0&8191,x0=m0>>>13,TU=G[8]|0,P0=TU&8191,C0=TU>>>13,s0=G[9]|0,c0=s0&8191,y0=s0>>>13;K.negative=Z.negative^Y.negative,K.length=19,M=Math.imul(p,L0),A=Math.imul(p,k0),A=A+Math.imul(n,L0)|0,B=Math.imul(n,k0);var l0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(l0>>>26)|0,l0&=67108863,M=Math.imul(r,L0),A=Math.imul(r,k0),A=A+Math.imul(d,L0)|0,B=Math.imul(d,k0),M=M+Math.imul(p,j0)|0,A=A+Math.imul(p,M0)|0,A=A+Math.imul(n,j0)|0,B=B+Math.imul(n,M0)|0;var b0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(b0>>>26)|0,b0&=67108863,M=Math.imul(m,L0),A=Math.imul(m,k0),A=A+Math.imul(i,L0)|0,B=Math.imul(i,k0),M=M+Math.imul(r,j0)|0,A=A+Math.imul(r,M0)|0,A=A+Math.imul(d,j0)|0,B=B+Math.imul(d,M0)|0,M=M+Math.imul(p,v0)|0,A=A+Math.imul(p,R0)|0,A=A+Math.imul(n,v0)|0,B=B+Math.imul(n,R0)|0;var r0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(r0>>>26)|0,r0&=67108863,M=Math.imul(y,L0),A=Math.imul(y,k0),A=A+Math.imul(h,L0)|0,B=Math.imul(h,k0),M=M+Math.imul(m,j0)|0,A=A+Math.imul(m,M0)|0,A=A+Math.imul(i,j0)|0,B=B+Math.imul(i,M0)|0,M=M+Math.imul(r,v0)|0,A=A+Math.imul(r,R0)|0,A=A+Math.imul(d,v0)|0,B=B+Math.imul(d,R0)|0,M=M+Math.imul(p,_0)|0,A=A+Math.imul(p,B0)|0,A=A+Math.imul(n,_0)|0,B=B+Math.imul(n,B0)|0;var a0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(a0>>>26)|0,a0&=67108863,M=Math.imul(t,L0),A=Math.imul(t,k0),A=A+Math.imul(e,L0)|0,B=Math.imul(e,k0),M=M+Math.imul(y,j0)|0,A=A+Math.imul(y,M0)|0,A=A+Math.imul(h,j0)|0,B=B+Math.imul(h,M0)|0,M=M+Math.imul(m,v0)|0,A=A+Math.imul(m,R0)|0,A=A+Math.imul(i,v0)|0,B=B+Math.imul(i,R0)|0,M=M+Math.imul(r,_0)|0,A=A+Math.imul(r,B0)|0,A=A+Math.imul(d,_0)|0,B=B+Math.imul(d,B0)|0,M=M+Math.imul(p,q0)|0,A=A+Math.imul(p,g)|0,A=A+Math.imul(n,q0)|0,B=B+Math.imul(n,g)|0;var e0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(e0>>>26)|0,e0&=67108863,M=Math.imul(c,L0),A=Math.imul(c,k0),A=A+Math.imul(o,L0)|0,B=Math.imul(o,k0),M=M+Math.imul(t,j0)|0,A=A+Math.imul(t,M0)|0,A=A+Math.imul(e,j0)|0,B=B+Math.imul(e,M0)|0,M=M+Math.imul(y,v0)|0,A=A+Math.imul(y,R0)|0,A=A+Math.imul(h,v0)|0,B=B+Math.imul(h,R0)|0,M=M+Math.imul(m,_0)|0,A=A+Math.imul(m,B0)|0,A=A+Math.imul(i,_0)|0,B=B+Math.imul(i,B0)|0,M=M+Math.imul(r,q0)|0,A=A+Math.imul(r,g)|0,A=A+Math.imul(d,q0)|0,B=B+Math.imul(d,g)|0,M=M+Math.imul(p,a)|0,A=A+Math.imul(p,X0)|0,A=A+Math.imul(n,a)|0,B=B+Math.imul(n,X0)|0;var i0=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(i0>>>26)|0,i0&=67108863,M=Math.imul(s,L0),A=Math.imul(s,k0),A=A+Math.imul(Z0,L0)|0,B=Math.imul(Z0,k0),M=M+Math.imul(c,j0)|0,A=A+Math.imul(c,M0)|0,A=A+Math.imul(o,j0)|0,B=B+Math.imul(o,M0)|0,M=M+Math.imul(t,v0)|0,A=A+Math.imul(t,R0)|0,A=A+Math.imul(e,v0)|0,B=B+Math.imul(e,R0)|0,M=M+Math.imul(y,_0)|0,A=A+Math.imul(y,B0)|0,A=A+Math.imul(h,_0)|0,B=B+Math.imul(h,B0)|0,M=M+Math.imul(m,q0)|0,A=A+Math.imul(m,g)|0,A=A+Math.imul(i,q0)|0,B=B+Math.imul(i,g)|0,M=M+Math.imul(r,a)|0,A=A+Math.imul(r,X0)|0,A=A+Math.imul(d,a)|0,B=B+Math.imul(d,X0)|0,M=M+Math.imul(p,F0)|0,A=A+Math.imul(p,T0)|0,A=A+Math.imul(n,F0)|0,B=B+Math.imul(n,T0)|0;var UU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(UU>>>26)|0,UU&=67108863,M=Math.imul(W0,L0),A=Math.imul(W0,k0),A=A+Math.imul(H0,L0)|0,B=Math.imul(H0,k0),M=M+Math.imul(s,j0)|0,A=A+Math.imul(s,M0)|0,A=A+Math.imul(Z0,j0)|0,B=B+Math.imul(Z0,M0)|0,M=M+Math.imul(c,v0)|0,A=A+Math.imul(c,R0)|0,A=A+Math.imul(o,v0)|0,B=B+Math.imul(o,R0)|0,M=M+Math.imul(t,_0)|0,A=A+Math.imul(t,B0)|0,A=A+Math.imul(e,_0)|0,B=B+Math.imul(e,B0)|0,M=M+Math.imul(y,q0)|0,A=A+Math.imul(y,g)|0,A=A+Math.imul(h,q0)|0,B=B+Math.imul(h,g)|0,M=M+Math.imul(m,a)|0,A=A+Math.imul(m,X0)|0,A=A+Math.imul(i,a)|0,B=B+Math.imul(i,X0)|0,M=M+Math.imul(r,F0)|0,A=A+Math.imul(r,T0)|0,A=A+Math.imul(d,F0)|0,B=B+Math.imul(d,T0)|0,M=M+Math.imul(p,S0)|0,A=A+Math.imul(p,x0)|0,A=A+Math.imul(n,S0)|0,B=B+Math.imul(n,x0)|0;var XU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(XU>>>26)|0,XU&=67108863,M=Math.imul(O0,L0),A=Math.imul(O0,k0),A=A+Math.imul(D0,L0)|0,B=Math.imul(D0,k0),M=M+Math.imul(W0,j0)|0,A=A+Math.imul(W0,M0)|0,A=A+Math.imul(H0,j0)|0,B=B+Math.imul(H0,M0)|0,M=M+Math.imul(s,v0)|0,A=A+Math.imul(s,R0)|0,A=A+Math.imul(Z0,v0)|0,B=B+Math.imul(Z0,R0)|0,M=M+Math.imul(c,_0)|0,A=A+Math.imul(c,B0)|0,A=A+Math.imul(o,_0)|0,B=B+Math.imul(o,B0)|0,M=M+Math.imul(t,q0)|0,A=A+Math.imul(t,g)|0,A=A+Math.imul(e,q0)|0,B=B+Math.imul(e,g)|0,M=M+Math.imul(y,a)|0,A=A+Math.imul(y,X0)|0,A=A+Math.imul(h,a)|0,B=B+Math.imul(h,X0)|0,M=M+Math.imul(m,F0)|0,A=A+Math.imul(m,T0)|0,A=A+Math.imul(i,F0)|0,B=B+Math.imul(i,T0)|0,M=M+Math.imul(r,S0)|0,A=A+Math.imul(r,x0)|0,A=A+Math.imul(d,S0)|0,B=B+Math.imul(d,x0)|0,M=M+Math.imul(p,P0)|0,A=A+Math.imul(p,C0)|0,A=A+Math.imul(n,P0)|0,B=B+Math.imul(n,C0)|0;var ZU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(ZU>>>26)|0,ZU&=67108863,M=Math.imul(z0,L0),A=Math.imul(z0,k0),A=A+Math.imul(A0,L0)|0,B=Math.imul(A0,k0),M=M+Math.imul(O0,j0)|0,A=A+Math.imul(O0,M0)|0,A=A+Math.imul(D0,j0)|0,B=B+Math.imul(D0,M0)|0,M=M+Math.imul(W0,v0)|0,A=A+Math.imul(W0,R0)|0,A=A+Math.imul(H0,v0)|0,B=B+Math.imul(H0,R0)|0,M=M+Math.imul(s,_0)|0,A=A+Math.imul(s,B0)|0,A=A+Math.imul(Z0,_0)|0,B=B+Math.imul(Z0,B0)|0,M=M+Math.imul(c,q0)|0,A=A+Math.imul(c,g)|0,A=A+Math.imul(o,q0)|0,B=B+Math.imul(o,g)|0,M=M+Math.imul(t,a)|0,A=A+Math.imul(t,X0)|0,A=A+Math.imul(e,a)|0,B=B+Math.imul(e,X0)|0,M=M+Math.imul(y,F0)|0,A=A+Math.imul(y,T0)|0,A=A+Math.imul(h,F0)|0,B=B+Math.imul(h,T0)|0,M=M+Math.imul(m,S0)|0,A=A+Math.imul(m,x0)|0,A=A+Math.imul(i,S0)|0,B=B+Math.imul(i,x0)|0,M=M+Math.imul(r,P0)|0,A=A+Math.imul(r,C0)|0,A=A+Math.imul(d,P0)|0,B=B+Math.imul(d,C0)|0,M=M+Math.imul(p,c0)|0,A=A+Math.imul(p,y0)|0,A=A+Math.imul(n,c0)|0,B=B+Math.imul(n,y0)|0;var QU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(QU>>>26)|0,QU&=67108863,M=Math.imul(z0,j0),A=Math.imul(z0,M0),A=A+Math.imul(A0,j0)|0,B=Math.imul(A0,M0),M=M+Math.imul(O0,v0)|0,A=A+Math.imul(O0,R0)|0,A=A+Math.imul(D0,v0)|0,B=B+Math.imul(D0,R0)|0,M=M+Math.imul(W0,_0)|0,A=A+Math.imul(W0,B0)|0,A=A+Math.imul(H0,_0)|0,B=B+Math.imul(H0,B0)|0,M=M+Math.imul(s,q0)|0,A=A+Math.imul(s,g)|0,A=A+Math.imul(Z0,q0)|0,B=B+Math.imul(Z0,g)|0,M=M+Math.imul(c,a)|0,A=A+Math.imul(c,X0)|0,A=A+Math.imul(o,a)|0,B=B+Math.imul(o,X0)|0,M=M+Math.imul(t,F0)|0,A=A+Math.imul(t,T0)|0,A=A+Math.imul(e,F0)|0,B=B+Math.imul(e,T0)|0,M=M+Math.imul(y,S0)|0,A=A+Math.imul(y,x0)|0,A=A+Math.imul(h,S0)|0,B=B+Math.imul(h,x0)|0,M=M+Math.imul(m,P0)|0,A=A+Math.imul(m,C0)|0,A=A+Math.imul(i,P0)|0,B=B+Math.imul(i,C0)|0,M=M+Math.imul(r,c0)|0,A=A+Math.imul(r,y0)|0,A=A+Math.imul(d,c0)|0,B=B+Math.imul(d,y0)|0;var YU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(YU>>>26)|0,YU&=67108863,M=Math.imul(z0,v0),A=Math.imul(z0,R0),A=A+Math.imul(A0,v0)|0,B=Math.imul(A0,R0),M=M+Math.imul(O0,_0)|0,A=A+Math.imul(O0,B0)|0,A=A+Math.imul(D0,_0)|0,B=B+Math.imul(D0,B0)|0,M=M+Math.imul(W0,q0)|0,A=A+Math.imul(W0,g)|0,A=A+Math.imul(H0,q0)|0,B=B+Math.imul(H0,g)|0,M=M+Math.imul(s,a)|0,A=A+Math.imul(s,X0)|0,A=A+Math.imul(Z0,a)|0,B=B+Math.imul(Z0,X0)|0,M=M+Math.imul(c,F0)|0,A=A+Math.imul(c,T0)|0,A=A+Math.imul(o,F0)|0,B=B+Math.imul(o,T0)|0,M=M+Math.imul(t,S0)|0,A=A+Math.imul(t,x0)|0,A=A+Math.imul(e,S0)|0,B=B+Math.imul(e,x0)|0,M=M+Math.imul(y,P0)|0,A=A+Math.imul(y,C0)|0,A=A+Math.imul(h,P0)|0,B=B+Math.imul(h,C0)|0,M=M+Math.imul(m,c0)|0,A=A+Math.imul(m,y0)|0,A=A+Math.imul(i,c0)|0,B=B+Math.imul(i,y0)|0;var JU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(JU>>>26)|0,JU&=67108863,M=Math.imul(z0,_0),A=Math.imul(z0,B0),A=A+Math.imul(A0,_0)|0,B=Math.imul(A0,B0),M=M+Math.imul(O0,q0)|0,A=A+Math.imul(O0,g)|0,A=A+Math.imul(D0,q0)|0,B=B+Math.imul(D0,g)|0,M=M+Math.imul(W0,a)|0,A=A+Math.imul(W0,X0)|0,A=A+Math.imul(H0,a)|0,B=B+Math.imul(H0,X0)|0,M=M+Math.imul(s,F0)|0,A=A+Math.imul(s,T0)|0,A=A+Math.imul(Z0,F0)|0,B=B+Math.imul(Z0,T0)|0,M=M+Math.imul(c,S0)|0,A=A+Math.imul(c,x0)|0,A=A+Math.imul(o,S0)|0,B=B+Math.imul(o,x0)|0,M=M+Math.imul(t,P0)|0,A=A+Math.imul(t,C0)|0,A=A+Math.imul(e,P0)|0,B=B+Math.imul(e,C0)|0,M=M+Math.imul(y,c0)|0,A=A+Math.imul(y,y0)|0,A=A+Math.imul(h,c0)|0,B=B+Math.imul(h,y0)|0;var VU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(VU>>>26)|0,VU&=67108863,M=Math.imul(z0,q0),A=Math.imul(z0,g),A=A+Math.imul(A0,q0)|0,B=Math.imul(A0,g),M=M+Math.imul(O0,a)|0,A=A+Math.imul(O0,X0)|0,A=A+Math.imul(D0,a)|0,B=B+Math.imul(D0,X0)|0,M=M+Math.imul(W0,F0)|0,A=A+Math.imul(W0,T0)|0,A=A+Math.imul(H0,F0)|0,B=B+Math.imul(H0,T0)|0,M=M+Math.imul(s,S0)|0,A=A+Math.imul(s,x0)|0,A=A+Math.imul(Z0,S0)|0,B=B+Math.imul(Z0,x0)|0,M=M+Math.imul(c,P0)|0,A=A+Math.imul(c,C0)|0,A=A+Math.imul(o,P0)|0,B=B+Math.imul(o,C0)|0,M=M+Math.imul(t,c0)|0,A=A+Math.imul(t,y0)|0,A=A+Math.imul(e,c0)|0,B=B+Math.imul(e,y0)|0;var GU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(GU>>>26)|0,GU&=67108863,M=Math.imul(z0,a),A=Math.imul(z0,X0),A=A+Math.imul(A0,a)|0,B=Math.imul(A0,X0),M=M+Math.imul(O0,F0)|0,A=A+Math.imul(O0,T0)|0,A=A+Math.imul(D0,F0)|0,B=B+Math.imul(D0,T0)|0,M=M+Math.imul(W0,S0)|0,A=A+Math.imul(W0,x0)|0,A=A+Math.imul(H0,S0)|0,B=B+Math.imul(H0,x0)|0,M=M+Math.imul(s,P0)|0,A=A+Math.imul(s,C0)|0,A=A+Math.imul(Z0,P0)|0,B=B+Math.imul(Z0,C0)|0,M=M+Math.imul(c,c0)|0,A=A+Math.imul(c,y0)|0,A=A+Math.imul(o,c0)|0,B=B+Math.imul(o,y0)|0;var IU=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(IU>>>26)|0,IU&=67108863,M=Math.imul(z0,F0),A=Math.imul(z0,T0),A=A+Math.imul(A0,F0)|0,B=Math.imul(A0,T0),M=M+Math.imul(O0,S0)|0,A=A+Math.imul(O0,x0)|0,A=A+Math.imul(D0,S0)|0,B=B+Math.imul(D0,x0)|0,M=M+Math.imul(W0,P0)|0,A=A+Math.imul(W0,C0)|0,A=A+Math.imul(H0,P0)|0,B=B+Math.imul(H0,C0)|0,M=M+Math.imul(s,c0)|0,A=A+Math.imul(s,y0)|0,A=A+Math.imul(Z0,c0)|0,B=B+Math.imul(Z0,y0)|0;var $U=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+($U>>>26)|0,$U&=67108863,M=Math.imul(z0,S0),A=Math.imul(z0,x0),A=A+Math.imul(A0,S0)|0,B=Math.imul(A0,x0),M=M+Math.imul(O0,P0)|0,A=A+Math.imul(O0,C0)|0,A=A+Math.imul(D0,P0)|0,B=B+Math.imul(D0,C0)|0,M=M+Math.imul(W0,c0)|0,A=A+Math.imul(W0,y0)|0,A=A+Math.imul(H0,c0)|0,B=B+Math.imul(H0,y0)|0;var BX=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(BX>>>26)|0,BX&=67108863,M=Math.imul(z0,P0),A=Math.imul(z0,C0),A=A+Math.imul(A0,P0)|0,B=Math.imul(A0,C0),M=M+Math.imul(O0,c0)|0,A=A+Math.imul(O0,y0)|0,A=A+Math.imul(D0,c0)|0,B=B+Math.imul(D0,y0)|0;var xX=($+M|0)+((A&8191)<<13)|0;$=(B+(A>>>13)|0)+(xX>>>26)|0,xX&=67108863,M=Math.imul(z0,c0),A=Math.imul(z0,y0),A=A+Math.imul(A0,c0)|0,B=Math.imul(A0,y0);var NX=($+M|0)+((A&8191)<<13)|0;if($=(B+(A>>>13)|0)+(NX>>>26)|0,NX&=67108863,X[0]=l0,X[1]=b0,X[2]=r0,X[3]=a0,X[4]=e0,X[5]=i0,X[6]=UU,X[7]=XU,X[8]=ZU,X[9]=QU,X[10]=YU,X[11]=JU,X[12]=VU,X[13]=GU,X[14]=IU,X[15]=$U,X[16]=BX,X[17]=xX,X[18]=NX,$!==0)X[19]=$,K.length++;return K};if(!Math.imul)x=v;function N(Z,Y,K){K.negative=Y.negative^Z.negative,K.length=Z.length+Y.length;var F=0,G=0;for(var X=0;X<K.length-1;X++){var $=G;G=0;var M=F&67108863,A=Math.min(X,Y.length-1);for(var B=Math.max(0,X-Z.length+1);B<=A;B++){var w=X-B,p=Z.words[w]|0,n=Y.words[B]|0,K0=p*n,r=K0&67108863;$=$+(K0/67108864|0)|0,r=r+M|0,M=r&67108863,$=$+(r>>>26)|0,G+=$>>>26,$&=67108863}K.words[X]=M,F=$,$=G}if(F!==0)K.words[X]=F;else K.length--;return K._strip()}function f(Z,Y,K){return N(Z,Y,K)}V.prototype.mulTo=function(Z,Y){var K,F=this.length+Z.length;if(this.length===10&&Z.length===10)K=x(this,Z,Y);else if(F<63)K=v(this,Z,Y);else if(F<1024)K=N(this,Z,Y);else K=f(this,Z,Y);return K};function b(Z,Y){this.x=Z,this.y=Y}b.prototype.makeRBT=function(Z){var Y=Array(Z),K=V.prototype._countBits(Z)-1;for(var F=0;F<Z;F++)Y[F]=this.revBin(F,K,Z);return Y},b.prototype.revBin=function(Z,Y,K){if(Z===0||Z===K-1)return Z;var F=0;for(var G=0;G<Y;G++)F|=(Z&1)<<Y-G-1,Z>>=1;return F},b.prototype.permute=function(Z,Y,K,F,G,X){for(var $=0;$<X;$++)F[$]=Y[Z[$]],G[$]=K[Z[$]]},b.prototype.transform=function(Z,Y,K,F,G,X){this.permute(X,Z,Y,K,F,G);for(var $=1;$<G;$<<=1){var M=$<<1,A=Math.cos(2*Math.PI/M),B=Math.sin(2*Math.PI/M);for(var w=0;w<G;w+=M){var p=A,n=B;for(var K0=0;K0<$;K0++){var r=K[w+K0],d=F[w+K0],J0=K[w+K0+$],m=F[w+K0+$],i=p*J0-n*m;if(m=p*m+n*J0,J0=i,K[w+K0]=r+J0,F[w+K0]=d+m,K[w+K0+$]=r-J0,F[w+K0+$]=d-m,K0!==M)i=A*p-B*n,n=A*n+B*p,p=i}}}},b.prototype.guessLen13b=function(Z,Y){var K=Math.max(Y,Z)|1,F=K&1,G=0;for(K=K/2|0;K;K=K>>>1)G++;return 1<<G+1+F},b.prototype.conjugate=function(Z,Y,K){if(K<=1)return;for(var F=0;F<K/2;F++){var G=Z[F];Z[F]=Z[K-F-1],Z[K-F-1]=G,G=Y[F],Y[F]=-Y[K-F-1],Y[K-F-1]=-G}},b.prototype.normalize13b=function(Z,Y){var K=0;for(var F=0;F<Y/2;F++){var G=Math.round(Z[2*F+1]/Y)*8192+Math.round(Z[2*F]/Y)+K;if(Z[F]=G&67108863,G<67108864)K=0;else K=G/67108864|0}return Z},b.prototype.convert13b=function(Z,Y,K,F){var G=0;for(var X=0;X<Y;X++)G=G+(Z[X]|0),K[2*X]=G&8191,G=G>>>13,K[2*X+1]=G&8191,G=G>>>13;for(X=2*Y;X<F;++X)K[X]=0;H(G===0),H((G&-8192)===0)},b.prototype.stub=function(Z){var Y=Array(Z);for(var K=0;K<Z;K++)Y[K]=0;return Y},b.prototype.mulp=function(Z,Y,K){var F=2*this.guessLen13b(Z.length,Y.length),G=this.makeRBT(F),X=this.stub(F),$=Array(F),M=Array(F),A=Array(F),B=Array(F),w=Array(F),p=Array(F),n=K.words;n.length=F,this.convert13b(Z.words,Z.length,$,F),this.convert13b(Y.words,Y.length,B,F),this.transform($,X,M,A,F,G),this.transform(B,X,w,p,F,G);for(var K0=0;K0<F;K0++){var r=M[K0]*w[K0]-A[K0]*p[K0];A[K0]=M[K0]*p[K0]+A[K0]*w[K0],M[K0]=r}return this.conjugate(M,A,F),this.transform(M,A,n,X,F,G),this.conjugate(n,X,F),this.normalize13b(n,F),K.negative=Z.negative^Y.negative,K.length=Z.length+Y.length,K._strip()},V.prototype.mul=function(Z){var Y=new V(null);return Y.words=Array(this.length+Z.length),this.mulTo(Z,Y)},V.prototype.mulf=function(Z){var Y=new V(null);return Y.words=Array(this.length+Z.length),f(this,Z,Y)},V.prototype.imul=function(Z){return this.clone().mulTo(Z,this)},V.prototype.imuln=function(Z){var Y=Z<0;if(Y)Z=-Z;H(typeof Z==="number"),H(Z<67108864);var K=0;for(var F=0;F<this.length;F++){var G=(this.words[F]|0)*Z,X=(G&67108863)+(K&67108863);K>>=26,K+=G/67108864|0,K+=X>>>26,this.words[F]=X&67108863}if(K!==0)this.words[F]=K,this.length++;return this.length=Z===0?1:this.length,Y?this.ineg():this},V.prototype.muln=function(Z){return this.clone().imuln(Z)},V.prototype.sqr=function(){return this.mul(this)},V.prototype.isqr=function(){return this.imul(this.clone())},V.prototype.pow=function(Z){var Y=j(Z);if(Y.length===0)return new V(1);var K=this;for(var F=0;F<Y.length;F++,K=K.sqr())if(Y[F]!==0)break;if(++F<Y.length)for(var G=K.sqr();F<Y.length;F++,G=G.sqr()){if(Y[F]===0)continue;K=K.mul(G)}return K},V.prototype.iushln=function(Z){H(typeof Z==="number"&&Z>=0);var Y=Z%26,K=(Z-Y)/26,F=67108863>>>26-Y<<26-Y,G;if(Y!==0){var X=0;for(G=0;G<this.length;G++){var $=this.words[G]&F,M=(this.words[G]|0)-$<<Y;this.words[G]=M|X,X=$>>>26-Y}if(X)this.words[G]=X,this.length++}if(K!==0){for(G=this.length-1;G>=0;G--)this.words[G+K]=this.words[G];for(G=0;G<K;G++)this.words[G]=0;this.length+=K}return this._strip()},V.prototype.ishln=function(Z){return H(this.negative===0),this.iushln(Z)},V.prototype.iushrn=function(Z,Y,K){H(typeof Z==="number"&&Z>=0);var F;if(Y)F=(Y-Y%26)/26;else F=0;var G=Z%26,X=Math.min((Z-G)/26,this.length),$=67108863^67108863>>>G<<G,M=K;if(F-=X,F=Math.max(0,F),M){for(var A=0;A<X;A++)M.words[A]=this.words[A];M.length=X}if(X===0);else if(this.length>X){this.length-=X;for(A=0;A<this.length;A++)this.words[A]=this.words[A+X]}else this.words[0]=0,this.length=1;var B=0;for(A=this.length-1;A>=0&&(B!==0||A>=F);A--){var w=this.words[A]|0;this.words[A]=B<<26-G|w>>>G,B=w&$}if(M&&B!==0)M.words[M.length++]=B;if(this.length===0)this.words[0]=0,this.length=1;return this._strip()},V.prototype.ishrn=function(Z,Y,K){return H(this.negative===0),this.iushrn(Z,Y,K)},V.prototype.shln=function(Z){return this.clone().ishln(Z)},V.prototype.ushln=function(Z){return this.clone().iushln(Z)},V.prototype.shrn=function(Z){return this.clone().ishrn(Z)},V.prototype.ushrn=function(Z){return this.clone().iushrn(Z)},V.prototype.testn=function(Z){H(typeof Z==="number"&&Z>=0);var Y=Z%26,K=(Z-Y)/26,F=1<<Y;if(this.length<=K)return!1;var G=this.words[K];return!!(G&F)},V.prototype.imaskn=function(Z){H(typeof Z==="number"&&Z>=0);var Y=Z%26,K=(Z-Y)/26;if(H(this.negative===0,"imaskn works only with positive numbers"),this.length<=K)return this;if(Y!==0)K++;if(this.length=Math.min(K,this.length),Y!==0){var F=67108863^67108863>>>Y<<Y;this.words[this.length-1]&=F}return this._strip()},V.prototype.maskn=function(Z){return this.clone().imaskn(Z)},V.prototype.iaddn=function(Z){if(H(typeof Z==="number"),H(Z<67108864),Z<0)return this.isubn(-Z);if(this.negative!==0){if(this.length===1&&(this.words[0]|0)<=Z)return this.words[0]=Z-(this.words[0]|0),this.negative=0,this;return this.negative=0,this.isubn(Z),this.negative=1,this}return this._iaddn(Z)},V.prototype._iaddn=function(Z){this.words[0]+=Z;for(var Y=0;Y<this.length&&this.words[Y]>=67108864;Y++)if(this.words[Y]-=67108864,Y===this.length-1)this.words[Y+1]=1;else this.words[Y+1]++;return this.length=Math.max(this.length,Y+1),this},V.prototype.isubn=function(Z){if(H(typeof Z==="number"),H(Z<67108864),Z<0)return this.iaddn(-Z);if(this.negative!==0)return this.negative=0,this.iaddn(Z),this.negative=1,this;if(this.words[0]-=Z,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var Y=0;Y<this.length&&this.words[Y]<0;Y++)this.words[Y]+=67108864,this.words[Y+1]-=1;return this._strip()},V.prototype.addn=function(Z){return this.clone().iaddn(Z)},V.prototype.subn=function(Z){return this.clone().isubn(Z)},V.prototype.iabs=function(){return this.negative=0,this},V.prototype.abs=function(){return this.clone().iabs()},V.prototype._ishlnsubmul=function(Z,Y,K){var F=Z.length+K,G;this._expand(F);var X,$=0;for(G=0;G<Z.length;G++){X=(this.words[G+K]|0)+$;var M=(Z.words[G]|0)*Y;X-=M&67108863,$=(X>>26)-(M/67108864|0),this.words[G+K]=X&67108863}for(;G<this.length-K;G++)X=(this.words[G+K]|0)+$,$=X>>26,this.words[G+K]=X&67108863;if($===0)return this._strip();H($===-1),$=0;for(G=0;G<this.length;G++)X=-(this.words[G]|0)+$,$=X>>26,this.words[G]=X&67108863;return this.negative=1,this._strip()},V.prototype._wordDiv=function(Z,Y){var K=this.length-Z.length,F=this.clone(),G=Z,X=G.words[G.length-1]|0,$=this._countBits(X);if(K=26-$,K!==0)G=G.ushln(K),F.iushln(K),X=G.words[G.length-1]|0;var M=F.length-G.length,A;if(Y!=="mod"){A=new V(null),A.length=M+1,A.words=Array(A.length);for(var B=0;B<A.length;B++)A.words[B]=0}var w=F.clone()._ishlnsubmul(G,1,M);if(w.negative===0){if(F=w,A)A.words[M]=1}for(var p=M-1;p>=0;p--){var n=(F.words[G.length+p]|0)*67108864+(F.words[G.length+p-1]|0);n=Math.min(n/X|0,67108863),F._ishlnsubmul(G,n,p);while(F.negative!==0)if(n--,F.negative=0,F._ishlnsubmul(G,1,p),!F.isZero())F.negative^=1;if(A)A.words[p]=n}if(A)A._strip();if(F._strip(),Y!=="div"&&K!==0)F.iushrn(K);return{div:A||null,mod:F}},V.prototype.divmod=function(Z,Y,K){if(H(!Z.isZero()),this.isZero())return{div:new V(0),mod:new V(0)};var F,G,X;if(this.negative!==0&&Z.negative===0){if(X=this.neg().divmod(Z,Y),Y!=="mod")F=X.div.neg();if(Y!=="div"){if(G=X.mod.neg(),K&&G.negative!==0)G.iadd(Z)}return{div:F,mod:G}}if(this.negative===0&&Z.negative!==0){if(X=this.divmod(Z.neg(),Y),Y!=="mod")F=X.div.neg();return{div:F,mod:X.mod}}if((this.negative&Z.negative)!==0){if(X=this.neg().divmod(Z.neg(),Y),Y!=="div"){if(G=X.mod.neg(),K&&G.negative!==0)G.isub(Z)}return{div:X.div,mod:G}}if(Z.length>this.length||this.cmp(Z)<0)return{div:new V(0),mod:this};if(Z.length===1){if(Y==="div")return{div:this.divn(Z.words[0]),mod:null};if(Y==="mod")return{div:null,mod:new V(this.modrn(Z.words[0]))};return{div:this.divn(Z.words[0]),mod:new V(this.modrn(Z.words[0]))}}return this._wordDiv(Z,Y)},V.prototype.div=function(Z){return this.divmod(Z,"div",!1).div},V.prototype.mod=function(Z){return this.divmod(Z,"mod",!1).mod},V.prototype.umod=function(Z){return this.divmod(Z,"mod",!0).mod},V.prototype.divRound=function(Z){var Y=this.divmod(Z);if(Y.mod.isZero())return Y.div;var K=Y.div.negative!==0?Y.mod.isub(Z):Y.mod,F=Z.ushrn(1),G=Z.andln(1),X=K.cmp(F);if(X<0||G===1&&X===0)return Y.div;return Y.div.negative!==0?Y.div.isubn(1):Y.div.iaddn(1)},V.prototype.modrn=function(Z){var Y=Z<0;if(Y)Z=-Z;H(Z<=67108863);var K=67108864%Z,F=0;for(var G=this.length-1;G>=0;G--)F=(K*F+(this.words[G]|0))%Z;return Y?-F:F},V.prototype.modn=function(Z){return this.modrn(Z)},V.prototype.idivn=function(Z){var Y=Z<0;if(Y)Z=-Z;H(Z<=67108863);var K=0;for(var F=this.length-1;F>=0;F--){var G=(this.words[F]|0)+K*67108864;this.words[F]=G/Z|0,K=G%Z}return this._strip(),Y?this.ineg():this},V.prototype.divn=function(Z){return this.clone().idivn(Z)},V.prototype.egcd=function(Z){H(Z.negative===0),H(!Z.isZero());var Y=this,K=Z.clone();if(Y.negative!==0)Y=Y.umod(Z);else Y=Y.clone();var F=new V(1),G=new V(0),X=new V(0),$=new V(1),M=0;while(Y.isEven()&&K.isEven())Y.iushrn(1),K.iushrn(1),++M;var A=K.clone(),B=Y.clone();while(!Y.isZero()){for(var w=0,p=1;(Y.words[0]&p)===0&&w<26;++w,p<<=1);if(w>0){Y.iushrn(w);while(w-- >0){if(F.isOdd()||G.isOdd())F.iadd(A),G.isub(B);F.iushrn(1),G.iushrn(1)}}for(var n=0,K0=1;(K.words[0]&K0)===0&&n<26;++n,K0<<=1);if(n>0){K.iushrn(n);while(n-- >0){if(X.isOdd()||$.isOdd())X.iadd(A),$.isub(B);X.iushrn(1),$.iushrn(1)}}if(Y.cmp(K)>=0)Y.isub(K),F.isub(X),G.isub($);else K.isub(Y),X.isub(F),$.isub(G)}return{a:X,b:$,gcd:K.iushln(M)}},V.prototype._invmp=function(Z){H(Z.negative===0),H(!Z.isZero());var Y=this,K=Z.clone();if(Y.negative!==0)Y=Y.umod(Z);else Y=Y.clone();var F=new V(1),G=new V(0),X=K.clone();while(Y.cmpn(1)>0&&K.cmpn(1)>0){for(var $=0,M=1;(Y.words[0]&M)===0&&$<26;++$,M<<=1);if($>0){Y.iushrn($);while($-- >0){if(F.isOdd())F.iadd(X);F.iushrn(1)}}for(var A=0,B=1;(K.words[0]&B)===0&&A<26;++A,B<<=1);if(A>0){K.iushrn(A);while(A-- >0){if(G.isOdd())G.iadd(X);G.iushrn(1)}}if(Y.cmp(K)>=0)Y.isub(K),F.isub(G);else K.isub(Y),G.isub(F)}var w;if(Y.cmpn(1)===0)w=F;else w=G;if(w.cmpn(0)<0)w.iadd(Z);return w},V.prototype.gcd=function(Z){if(this.isZero())return Z.abs();if(Z.isZero())return this.abs();var Y=this.clone(),K=Z.clone();Y.negative=0,K.negative=0;for(var F=0;Y.isEven()&&K.isEven();F++)Y.iushrn(1),K.iushrn(1);do{while(Y.isEven())Y.iushrn(1);while(K.isEven())K.iushrn(1);var G=Y.cmp(K);if(G<0){var X=Y;Y=K,K=X}else if(G===0||K.cmpn(1)===0)break;Y.isub(K)}while(!0);return K.iushln(F)},V.prototype.invm=function(Z){return this.egcd(Z).a.umod(Z)},V.prototype.isEven=function(){return(this.words[0]&1)===0},V.prototype.isOdd=function(){return(this.words[0]&1)===1},V.prototype.andln=function(Z){return this.words[0]&Z},V.prototype.bincn=function(Z){H(typeof Z==="number");var Y=Z%26,K=(Z-Y)/26,F=1<<Y;if(this.length<=K)return this._expand(K+1),this.words[K]|=F,this;var G=F;for(var X=K;G!==0&&X<this.length;X++){var $=this.words[X]|0;$+=G,G=$>>>26,$&=67108863,this.words[X]=$}if(G!==0)this.words[X]=G,this.length++;return this},V.prototype.isZero=function(){return this.length===1&&this.words[0]===0},V.prototype.cmpn=function(Z){var Y=Z<0;if(this.negative!==0&&!Y)return-1;if(this.negative===0&&Y)return 1;this._strip();var K;if(this.length>1)K=1;else{if(Y)Z=-Z;H(Z<=67108863,"Number is too big");var F=this.words[0]|0;K=F===Z?0:F<Z?-1:1}if(this.negative!==0)return-K|0;return K},V.prototype.cmp=function(Z){if(this.negative!==0&&Z.negative===0)return-1;if(this.negative===0&&Z.negative!==0)return 1;var Y=this.ucmp(Z);if(this.negative!==0)return-Y|0;return Y},V.prototype.ucmp=function(Z){if(this.length>Z.length)return 1;if(this.length<Z.length)return-1;var Y=0;for(var K=this.length-1;K>=0;K--){var F=this.words[K]|0,G=Z.words[K]|0;if(F===G)continue;if(F<G)Y=-1;else if(F>G)Y=1;break}return Y},V.prototype.gtn=function(Z){return this.cmpn(Z)===1},V.prototype.gt=function(Z){return this.cmp(Z)===1},V.prototype.gten=function(Z){return this.cmpn(Z)>=0},V.prototype.gte=function(Z){return this.cmp(Z)>=0},V.prototype.ltn=function(Z){return this.cmpn(Z)===-1},V.prototype.lt=function(Z){return this.cmp(Z)===-1},V.prototype.lten=function(Z){return this.cmpn(Z)<=0},V.prototype.lte=function(Z){return this.cmp(Z)<=0},V.prototype.eqn=function(Z){return this.cmpn(Z)===0},V.prototype.eq=function(Z){return this.cmp(Z)===0},V.red=function(Z){return new Q(Z)},V.prototype.toRed=function(Z){return H(!this.red,"Already a number in reduction context"),H(this.negative===0,"red works only with positives"),Z.convertTo(this)._forceRed(Z)},V.prototype.fromRed=function(){return H(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},V.prototype._forceRed=function(Z){return this.red=Z,this},V.prototype.forceRed=function(Z){return H(!this.red,"Already a number in reduction context"),this._forceRed(Z)},V.prototype.redAdd=function(Z){return H(this.red,"redAdd works only with red numbers"),this.red.add(this,Z)},V.prototype.redIAdd=function(Z){return H(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,Z)},V.prototype.redSub=function(Z){return H(this.red,"redSub works only with red numbers"),this.red.sub(this,Z)},V.prototype.redISub=function(Z){return H(this.red,"redISub works only with red numbers"),this.red.isub(this,Z)},V.prototype.redShl=function(Z){return H(this.red,"redShl works only with red numbers"),this.red.shl(this,Z)},V.prototype.redMul=function(Z){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,Z),this.red.mul(this,Z)},V.prototype.redIMul=function(Z){return H(this.red,"redMul works only with red numbers"),this.red._verify2(this,Z),this.red.imul(this,Z)},V.prototype.redSqr=function(){return H(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},V.prototype.redISqr=function(){return H(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},V.prototype.redSqrt=function(){return H(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},V.prototype.redInvm=function(){return H(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},V.prototype.redNeg=function(){return H(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},V.prototype.redPow=function(Z){return H(this.red&&!Z.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,Z)};var Q0={k256:null,p224:null,p192:null,p25519:null};function G0(Z,Y){this.name=Z,this.p=new V(Y,16),this.n=this.p.bitLength(),this.k=new V(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}G0.prototype._tmp=function(){var Z=new V(null);return Z.words=Array(Math.ceil(this.n/13)),Z},G0.prototype.ireduce=function(Z){var Y=Z,K;do this.split(Y,this.tmp),Y=this.imulK(Y),Y=Y.iadd(this.tmp),K=Y.bitLength();while(K>this.n);var F=K<this.n?-1:Y.ucmp(this.p);if(F===0)Y.words[0]=0,Y.length=1;else if(F>0)Y.isub(this.p);else if(Y.strip!==void 0)Y.strip();else Y._strip();return Y},G0.prototype.split=function(Z,Y){Z.iushrn(this.n,0,Y)},G0.prototype.imulK=function(Z){return Z.imul(this.k)};function Y0(){G0.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}L(Y0,G0),Y0.prototype.split=function(Z,Y){var K=4194303,F=Math.min(Z.length,9);for(var G=0;G<F;G++)Y.words[G]=Z.words[G];if(Y.length=F,Z.length<=9){Z.words[0]=0,Z.length=1;return}var X=Z.words[9];Y.words[Y.length++]=X&K;for(G=10;G<Z.length;G++){var $=Z.words[G]|0;Z.words[G-10]=($&K)<<4|X>>>22,X=$}if(X>>>=22,Z.words[G-10]=X,X===0&&Z.length>10)Z.length-=10;else Z.length-=9},Y0.prototype.imulK=function(Z){Z.words[Z.length]=0,Z.words[Z.length+1]=0,Z.length+=2;var Y=0;for(var K=0;K<Z.length;K++){var F=Z.words[K]|0;Y+=F*977,Z.words[K]=Y&67108863,Y=F*64+(Y/67108864|0)}if(Z.words[Z.length-1]===0){if(Z.length--,Z.words[Z.length-1]===0)Z.length--}return Z};function u(){G0.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}L(u,G0);function U0(){G0.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}L(U0,G0);function U(){G0.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}L(U,G0),U.prototype.imulK=function(Z){var Y=0;for(var K=0;K<Z.length;K++){var F=(Z.words[K]|0)*19+Y,G=F&67108863;F>>>=26,Z.words[K]=G,Y=F}if(Y!==0)Z.words[Z.length++]=Y;return Z},V._prime=function(Z){if(Q0[Z])return Q0[Z];var Y;if(Z==="k256")Y=new Y0;else if(Z==="p224")Y=new u;else if(Z==="p192")Y=new U0;else if(Z==="p25519")Y=new U;else throw Error("Unknown prime "+Z);return Q0[Z]=Y,Y};function Q(Z){if(typeof Z==="string"){var Y=V._prime(Z);this.m=Y.p,this.prime=Y}else H(Z.gtn(1),"modulus must be greater than 1"),this.m=Z,this.prime=null}Q.prototype._verify1=function(Z){H(Z.negative===0,"red works only with positives"),H(Z.red,"red works only with red numbers")},Q.prototype._verify2=function(Z,Y){H((Z.negative|Y.negative)===0,"red works only with positives"),H(Z.red&&Z.red===Y.red,"red works only with red numbers")},Q.prototype.imod=function(Z){if(this.prime)return this.prime.ireduce(Z)._forceRed(this);return D(Z,Z.umod(this.m)._forceRed(this)),Z},Q.prototype.neg=function(Z){if(Z.isZero())return Z.clone();return this.m.sub(Z)._forceRed(this)},Q.prototype.add=function(Z,Y){this._verify2(Z,Y);var K=Z.add(Y);if(K.cmp(this.m)>=0)K.isub(this.m);return K._forceRed(this)},Q.prototype.iadd=function(Z,Y){this._verify2(Z,Y);var K=Z.iadd(Y);if(K.cmp(this.m)>=0)K.isub(this.m);return K},Q.prototype.sub=function(Z,Y){this._verify2(Z,Y);var K=Z.sub(Y);if(K.cmpn(0)<0)K.iadd(this.m);return K._forceRed(this)},Q.prototype.isub=function(Z,Y){this._verify2(Z,Y);var K=Z.isub(Y);if(K.cmpn(0)<0)K.iadd(this.m);return K},Q.prototype.shl=function(Z,Y){return this._verify1(Z),this.imod(Z.ushln(Y))},Q.prototype.imul=function(Z,Y){return this._verify2(Z,Y),this.imod(Z.imul(Y))},Q.prototype.mul=function(Z,Y){return this._verify2(Z,Y),this.imod(Z.mul(Y))},Q.prototype.isqr=function(Z){return this.imul(Z,Z.clone())},Q.prototype.sqr=function(Z){return this.mul(Z,Z)},Q.prototype.sqrt=function(Z){if(Z.isZero())return Z.clone();var Y=this.m.andln(3);if(H(Y%2===1),Y===3){var K=this.m.add(new V(1)).iushrn(2);return this.pow(Z,K)}var F=this.m.subn(1),G=0;while(!F.isZero()&&F.andln(1)===0)G++,F.iushrn(1);H(!F.isZero());var X=new V(1).toRed(this),$=X.redNeg(),M=this.m.subn(1).iushrn(1),A=this.m.bitLength();A=new V(2*A*A).toRed(this);while(this.pow(A,M).cmp($)!==0)A.redIAdd($);var B=this.pow(A,F),w=this.pow(Z,F.addn(1).iushrn(1)),p=this.pow(Z,F),n=G;while(p.cmp(X)!==0){var K0=p;for(var r=0;K0.cmp(X)!==0;r++)K0=K0.redSqr();H(r<n);var d=this.pow(B,new V(1).iushln(n-r-1));w=w.redMul(d),B=d.redSqr(),p=p.redMul(B),n=r}return w},Q.prototype.invm=function(Z){var Y=Z._invmp(this.m);if(Y.negative!==0)return Y.negative=0,this.imod(Y).redNeg();else return this.imod(Y)},Q.prototype.pow=function(Z,Y){if(Y.isZero())return new V(1).toRed(this);if(Y.cmpn(1)===0)return Z.clone();var K=4,F=Array(1<<K);F[0]=new V(1).toRed(this),F[1]=Z;for(var G=2;G<F.length;G++)F[G]=this.mul(F[G-1],Z);var X=F[0],$=0,M=0,A=Y.bitLength()%26;if(A===0)A=26;for(G=Y.length-1;G>=0;G--){var B=Y.words[G];for(var w=A-1;w>=0;w--){var p=B>>w&1;if(X!==F[0])X=this.sqr(X);if(p===0&&$===0){M=0;continue}if($<<=1,$|=p,M++,M!==K&&(G!==0||w!==0))continue;X=this.mul(X,F[$]),M=0,$=0}A=26}return X},Q.prototype.convertTo=function(Z){var Y=Z.umod(this.m);return Y===Z?Y.clone():Y},Q.prototype.convertFrom=function(Z){var Y=Z.clone();return Y.red=null,Y},V.mont=function(Z){return new J(Z)};function J(Z){if(Q.call(this,Z),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)}L(J,Q),J.prototype.convertTo=function(Z){return this.imod(Z.ushln(this.shift))},J.prototype.convertFrom=function(Z){var Y=this.imod(Z.mul(this.rinv));return Y.red=null,Y},J.prototype.imul=function(Z,Y){if(Z.isZero()||Y.isZero())return Z.words[0]=0,Z.length=1,Z;var K=Z.imul(Y),F=K.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),G=K.isub(F).iushrn(this.shift),X=G;if(G.cmp(this.m)>=0)X=G.isub(this.m);else if(G.cmpn(0)<0)X=G.iadd(this.m);return X._forceRed(this)},J.prototype.mul=function(Z,Y){if(Z.isZero()||Y.isZero())return new V(0)._forceRed(this);var K=Z.mul(Y),F=K.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),G=K.isub(F).iushrn(this.shift),X=G;if(G.cmp(this.m)>=0)X=G.isub(this.m);else if(G.cmpn(0)<0)X=G.iadd(this.m);return X._forceRed(this)},J.prototype.invm=function(Z){var Y=this.imod(Z._invmp(this.m).mul(this.r2));return Y._forceRed(this)}})(typeof O>"u"||O,I)}),nQ=I0((I,O)=>{var W=oV(),T=qX(),H=EU().Buffer;function L(S){var E=S.modulus.byteLength(),C;do C=new W(T(E));while(C.cmp(S.modulus)>=0||!C.umod(S.prime1)||!C.umod(S.prime2));return C}function V(S){var E=L(S),C=E.toRed(W.mont(S.modulus)).redPow(new W(S.publicExponent)).fromRed();return{blinder:C,unblinder:E.invm(S.modulus)}}function P(S,E){var C=V(E),D=E.modulus.byteLength(),z=new W(S).mul(C.blinder).umod(E.modulus),R=z.toRed(W.mont(E.prime1)),q=z.toRed(W.mont(E.prime2)),_=E.coefficient,k=E.prime1,j=E.prime2,v=R.redPow(E.exponent1).fromRed(),x=q.redPow(E.exponent2).fromRed(),N=v.isub(x).imul(_).umod(k).imul(j);return x.iadd(N).imul(C.unblinder).umod(E.modulus).toArrayLike(H,"be",D)}P.getr=L,O.exports=P}),nV=I0((I,O)=>{var W=bQ(),T=qX(),H=SX(),L=lQ(),V=dQ(),P=HZ(),S=oQ(),E=nQ(),C=EU().Buffer;O.exports=function(q,_,k){var j;if(q.padding)j=q.padding;else if(k)j=1;else j=4;var v=W(q),x;if(j===4)x=D(v,_);else if(j===1)x=z(v,_,k);else if(j===3){if(x=new P(_),x.cmp(v.modulus)>=0)throw Error("data too long for modulus")}else throw Error("unknown padding");if(k)return E(x,v);else return S(x,v)};function D(q,_){var k=q.modulus.byteLength(),j=_.length,v=H("sha1").update(C.alloc(0)).digest(),x=v.length,N=2*x;if(j>k-N-2)throw Error("message too long");var f=C.alloc(k-j-N-2),b=k-x-1,Q0=T(x),G0=V(C.concat([v,f,C.alloc(1,1),_],b),L(Q0,b)),Y0=V(Q0,L(G0,x));return new P(C.concat([C.alloc(1),Y0,G0],k))}function z(q,_,k){var j=_.length,v=q.modulus.byteLength();if(j>v-11)throw Error("message too long");var x;if(k)x=C.alloc(v-j-3,255);else x=R(v-j-3);return new P(C.concat([C.from([0,k?1:2]),x,C.alloc(1),_],v))}function R(q){var _=C.allocUnsafe(q),k=0,j=T(q*2),v=0,x;while(k<q){if(v===j.length)j=T(q*2),v=0;if(x=j[v++],x)_[k++]=x}return _}}),mV=I0((I,O)=>{var W=bQ(),T=lQ(),H=dQ(),L=HZ(),V=nQ(),P=SX(),S=oQ(),E=EU().Buffer;O.exports=function(R,q,_){var k;if(R.padding)k=R.padding;else if(_)k=1;else k=4;var j=W(R),v=j.modulus.byteLength();if(q.length>v||new L(q).cmp(j.modulus)>=0)throw Error("decryption error");var x;if(_)x=S(new L(q),j);else x=V(q,j);var N=E.alloc(v-x.length);if(x=E.concat([N,x],v),k===4)return C(j,x);else if(k===1)return D(j,x,_);else if(k===3)return x;else throw Error("unknown padding")};function C(R,q){var _=R.modulus.byteLength(),k=P("sha1").update(E.alloc(0)).digest(),j=k.length;if(q[0]!==0)throw Error("decryption error");var v=q.slice(1,j+1),x=q.slice(j+1),N=H(v,T(x,j)),f=H(x,T(N,_-j-1));if(z(k,f.slice(0,j)))throw Error("decryption error");var b=j;while(f[b]===0)b++;if(f[b++]!==1)throw Error("decryption error");return f.slice(b)}function D(R,q,_){var k=q.slice(0,2),j=2,v=0;while(q[j++]!==0)if(j>=q.length){v++;break}var x=q.slice(2,j-1);if(k.toString("hex")!=="0002"&&!_||k.toString("hex")!=="0001"&&_)v++;if(x.length<8)v++;if(v)throw Error("decryption error");return q.slice(j)}function z(R,q){R=E.from(R),q=E.from(q);var _=0,k=R.length;if(R.length!==q.length)_++,k=Math.min(R.length,q.length);var j=-1;while(++j<k)_+=R[j]^q[j];return _}}),JZ=I0((I)=>{I.publicEncrypt=nV(),I.privateDecrypt=mV(),I.privateEncrypt=function(O,W){return I.publicEncrypt(O,W,!0)},I.publicDecrypt=function(O,W){return I.privateDecrypt(O,W,!0)}}),sV=I0((I)=>{var O=(qU(),h0(RU));if(typeof O.publicEncrypt!=="function")O=JZ();if(I.publicEncrypt=O.publicEncrypt,I.privateDecrypt=O.privateDecrypt,typeof O.privateEncrypt!=="function")I.privateEncrypt=JZ().privateEncrypt;else I.privateEncrypt=O.privateEncrypt;if(typeof O.publicDecrypt!=="function")I.publicDecrypt=JZ().publicDecrypt;else I.publicDecrypt=O.publicDecrypt}),tV=I0((I)=>{var O=EU(),W=qX(),T=O.Buffer,H=O.kMaxLength,L=globalThis.crypto||globalThis.msCrypto,V=Math.pow(2,32)-1;function P(z,R){if(typeof z!=="number"||z!==z)throw TypeError("offset must be a number");if(z>V||z<0)throw TypeError("offset must be a uint32");if(z>H||z>R)throw RangeError("offset out of range")}function S(z,R,q){if(typeof z!=="number"||z!==z)throw TypeError("size must be a number");if(z>V||z<0)throw TypeError("size must be a uint32");if(z+R>q||z>H)throw RangeError("buffer too small")}L&&L.getRandomValues,I.randomFill=E,I.randomFillSync=D;function E(z,R,q,_){if(!T.isBuffer(z)&&!(z instanceof globalThis.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');if(typeof R==="function")_=R,R=0,q=z.length;else if(typeof q==="function")_=q,q=z.length-R;else if(typeof _!=="function")throw TypeError('"cb" argument must be a function');return P(R,z.length),S(q,R,z.length),C(z,R,q,_)}function C(z,R,q,_){if(!1)var k,j;if(_){W(q,function(x,N){if(x)return _(x);N.copy(z,R),_(null,z)});return}var v=W(q);return v.copy(z,R),z}function D(z,R,q){if(typeof R>"u")R=0;if(!T.isBuffer(z)&&!(z instanceof globalThis.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');if(P(R,z.length),q===void 0)q=z.length-R;return S(q,R,z.length),C(z,R,q)}}),rV=I0((I,O)=>{var W=(qU(),h0(RU));if(typeof W.randomFill==="function"&&typeof W.randomFillSync==="function")I.randomFill=W.randomFill,I.randomFillSync=W.randomFillSync;else O.exports=tV()}),aV=I0((I)=>{I.randomBytes=I.rng=I.pseudoRandomBytes=I.prng=qX(),I.createHash=I.Hash=SX(),I.createHmac=I.Hmac=EQ();var O=LJ(),W=Object.keys(O),T=["sha1","sha224","sha256","sha384","sha512","md5","rmd160"].concat(W);I.getHashes=function(){return T};var H=BQ();I.pbkdf2=H.pbkdf2,I.pbkdf2Sync=H.pbkdf2Sync;var L=QV();I.Cipher=L.Cipher,I.createCipher=L.createCipher,I.Cipheriv=L.Cipheriv,I.createCipheriv=L.createCipheriv,I.Decipher=L.Decipher,I.createDecipher=L.createDecipher,I.Decipheriv=L.Decipheriv,I.createDecipheriv=L.createDecipheriv,I.getCiphers=L.getCiphers,I.listCiphers=L.listCiphers;var V=YV();I.DiffieHellmanGroup=V.DiffieHellmanGroup,I.createDiffieHellmanGroup=V.createDiffieHellmanGroup,I.getDiffieHellman=V.getDiffieHellman,I.createDiffieHellman=V.createDiffieHellman,I.DiffieHellman=V.DiffieHellman;var P=JV();I.createSign=P.createSign,I.Sign=P.Sign,I.createVerify=P.createVerify,I.Verify=P.Verify,I.createECDH=jV();var S=sV();I.publicEncrypt=S.publicEncrypt,I.privateEncrypt=S.privateEncrypt,I.publicDecrypt=S.publicDecrypt,I.privateDecrypt=S.privateDecrypt;var E=rV();I.randomFill=E.randomFill,I.randomFillSync=E.randomFillSync,I.createCredentials=function(){throw Error(`sorry, createCredentials is not implemented yet
|
|
15
|
+
we accept pull requests
|
|
16
|
+
https://github.com/browserify/crypto-browserify`)},I.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}}),p0=EJ(aV(),1),eV=p0.prng,iV=p0.pseudoRandomBytes,UG=p0.rng,XG=p0.randomBytes,ZG=p0.Hash,QG=p0.createHash,YG=p0.Hmac,JG=p0.createHmac,VG=p0.getHashes,GG=p0.pbkdf2,IG=p0.pbkdf2Sync,$G=p0.Cipher,KG=p0.createCipher,OG=p0.Cipheriv,FG=p0.createCipheriv,WG=p0.Decipher,HG=p0.createDecipher,DG=p0.Decipheriv,TG=p0.createDecipheriv,AG=p0.getCiphers,zG=p0.listCiphers,CG=p0.DiffieHellmanGroup,EG=p0.createDiffieHellmanGroup,LG=p0.getDiffieHellman,MG=p0.createDiffieHellman,RG=p0.DiffieHellman,qG=p0.createSign,SG=p0.Sign,PG=p0.createVerify,kG=p0.Verify,jG=p0.createECDH,vG=p0.publicEncrypt,_G=p0.privateEncrypt,BG=p0.publicDecrypt,xG=p0.privateDecrypt,NG=p0.randomFill,gG=p0.randomFillSync,wG=p0.createCredentials,fG=p0.constants,hG=["p192","p224","p256","p384","p521","curve25519","ed25519","secp256k1","secp224r1","prime256v1","prime192v1","ed25519","secp384r1","secp521r1"];bG=crypto,lG=crypto});var DZ=EX((jX,mQ)=>{(function(I,O){if(typeof jX==="object")mQ.exports=jX=O();else if(typeof define==="function"&&define.amd)define([],O);else I.CryptoJS=O()})(jX,function(){var I=I||function(O,W){var T;if(typeof window<"u"&&window.crypto)T=window.crypto;if(typeof self<"u"&&self.crypto)T=self.crypto;if(typeof globalThis<"u"&&globalThis.crypto)T=globalThis.crypto;if(!T&&typeof window<"u"&&window.msCrypto)T=window.msCrypto;if(!T&&typeof global<"u"&&global.crypto)T=global.crypto;if(!T)try{T=(qU(),h0(RU))}catch(j){}var H=function(){if(T){if(typeof T.getRandomValues==="function")try{return T.getRandomValues(new Uint32Array(1))[0]}catch(j){}if(typeof T.randomBytes==="function")try{return T.randomBytes(4).readInt32LE()}catch(j){}}throw Error("Native crypto module could not be used to get secure random number.")},L=Object.create||function(){function j(){}return function(v){var x;return j.prototype=v,x=new j,j.prototype=null,x}}(),V={},P=V.lib={},S=P.Base=function(){return{extend:function(j){var v=L(this);if(j)v.mixIn(j);if(!v.hasOwnProperty("init")||this.init===v.init)v.init=function(){v.$super.init.apply(this,arguments)};return v.init.prototype=v,v.$super=this,v},create:function(){var j=this.extend();return j.init.apply(j,arguments),j},init:function(){},mixIn:function(j){for(var v in j)if(j.hasOwnProperty(v))this[v]=j[v];if(j.hasOwnProperty("toString"))this.toString=j.toString},clone:function(){return this.init.prototype.extend(this)}}}(),E=P.WordArray=S.extend({init:function(j,v){if(j=this.words=j||[],v!=W)this.sigBytes=v;else this.sigBytes=j.length*4},toString:function(j){return(j||D).stringify(this)},concat:function(j){var v=this.words,x=j.words,N=this.sigBytes,f=j.sigBytes;if(this.clamp(),N%4)for(var b=0;b<f;b++){var Q0=x[b>>>2]>>>24-b%4*8&255;v[N+b>>>2]|=Q0<<24-(N+b)%4*8}else for(var G0=0;G0<f;G0+=4)v[N+G0>>>2]=x[G0>>>2];return this.sigBytes+=f,this},clamp:function(){var j=this.words,v=this.sigBytes;j[v>>>2]&=4294967295<<32-v%4*8,j.length=O.ceil(v/4)},clone:function(){var j=S.clone.call(this);return j.words=this.words.slice(0),j},random:function(j){var v=[];for(var x=0;x<j;x+=4)v.push(H());return new E.init(v,j)}}),C=V.enc={},D=C.Hex={stringify:function(j){var{words:v,sigBytes:x}=j,N=[];for(var f=0;f<x;f++){var b=v[f>>>2]>>>24-f%4*8&255;N.push((b>>>4).toString(16)),N.push((b&15).toString(16))}return N.join("")},parse:function(j){var v=j.length,x=[];for(var N=0;N<v;N+=2)x[N>>>3]|=parseInt(j.substr(N,2),16)<<24-N%8*4;return new E.init(x,v/2)}},z=C.Latin1={stringify:function(j){var{words:v,sigBytes:x}=j,N=[];for(var f=0;f<x;f++){var b=v[f>>>2]>>>24-f%4*8&255;N.push(String.fromCharCode(b))}return N.join("")},parse:function(j){var v=j.length,x=[];for(var N=0;N<v;N++)x[N>>>2]|=(j.charCodeAt(N)&255)<<24-N%4*8;return new E.init(x,v)}},R=C.Utf8={stringify:function(j){try{return decodeURIComponent(escape(z.stringify(j)))}catch(v){throw Error("Malformed UTF-8 data")}},parse:function(j){return z.parse(unescape(encodeURIComponent(j)))}},q=P.BufferedBlockAlgorithm=S.extend({reset:function(){this._data=new E.init,this._nDataBytes=0},_append:function(j){if(typeof j=="string")j=R.parse(j);this._data.concat(j),this._nDataBytes+=j.sigBytes},_process:function(j){var v,x=this._data,N=x.words,f=x.sigBytes,b=this.blockSize,Q0=b*4,G0=f/Q0;if(j)G0=O.ceil(G0);else G0=O.max((G0|0)-this._minBufferSize,0);var Y0=G0*b,u=O.min(Y0*4,f);if(Y0){for(var U0=0;U0<Y0;U0+=b)this._doProcessBlock(N,U0);v=N.splice(0,Y0),x.sigBytes-=u}return new E.init(v,u)},clone:function(){var j=S.clone.call(this);return j._data=this._data.clone(),j},_minBufferSize:0}),_=P.Hasher=q.extend({cfg:S.extend(),init:function(j){this.cfg=this.cfg.extend(j),this.reset()},reset:function(){q.reset.call(this),this._doReset()},update:function(j){return this._append(j),this._process(),this},finalize:function(j){if(j)this._append(j);var v=this._doFinalize();return v},blockSize:16,_createHelper:function(j){return function(v,x){return new j.init(x).finalize(v)}},_createHmacHelper:function(j){return function(v,x){return new k.HMAC.init(j,x).finalize(v)}}}),k=V.algo={};return V}(Math);return I})});var tQ=EX((vX,sQ)=>{(function(I,O){if(typeof vX==="object")sQ.exports=vX=O(DZ());else if(typeof define==="function"&&define.amd)define(["./core"],O);else O(I.CryptoJS)})(vX,function(I){return function(O){var W=I,T=W.lib,H=T.WordArray,L=T.Hasher,V=W.algo,P=[],S=[];(function(){function D(_){var k=O.sqrt(_);for(var j=2;j<=k;j++)if(!(_%j))return!1;return!0}function z(_){return(_-(_|0))*4294967296|0}var R=2,q=0;while(q<64){if(D(R)){if(q<8)P[q]=z(O.pow(R,0.5));S[q]=z(O.pow(R,0.3333333333333333)),q++}R++}})();var E=[],C=V.SHA256=L.extend({_doReset:function(){this._hash=new H.init(P.slice(0))},_doProcessBlock:function(D,z){var R=this._hash.words,q=R[0],_=R[1],k=R[2],j=R[3],v=R[4],x=R[5],N=R[6],f=R[7];for(var b=0;b<64;b++){if(b<16)E[b]=D[z+b]|0;else{var Q0=E[b-15],G0=(Q0<<25|Q0>>>7)^(Q0<<14|Q0>>>18)^Q0>>>3,Y0=E[b-2],u=(Y0<<15|Y0>>>17)^(Y0<<13|Y0>>>19)^Y0>>>10;E[b]=G0+E[b-7]+u+E[b-16]}var U0=v&x^~v&N,U=q&_^q&k^_&k,Q=(q<<30|q>>>2)^(q<<19|q>>>13)^(q<<10|q>>>22),J=(v<<26|v>>>6)^(v<<21|v>>>11)^(v<<7|v>>>25),Z=f+J+U0+S[b]+E[b],Y=Q+U;f=N,N=x,x=v,v=j+Z|0,j=k,k=_,_=q,q=Z+Y|0}R[0]=R[0]+q|0,R[1]=R[1]+_|0,R[2]=R[2]+k|0,R[3]=R[3]+j|0,R[4]=R[4]+v|0,R[5]=R[5]+x|0,R[6]=R[6]+N|0,R[7]=R[7]+f|0},_doFinalize:function(){var D=this._data,z=D.words,R=this._nDataBytes*8,q=D.sigBytes*8;return z[q>>>5]|=128<<24-q%32,z[(q+64>>>9<<4)+14]=O.floor(R/4294967296),z[(q+64>>>9<<4)+15]=R,D.sigBytes=z.length*4,this._process(),this._hash},clone:function(){var D=L.clone.call(this);return D._hash=this._hash.clone(),D}});W.SHA256=L._createHelper(C),W.HmacSHA256=L._createHmacHelper(C)}(Math),I.SHA256})});var dG=EX((_X,rQ)=>{(function(I,O,W){if(typeof _X==="object")rQ.exports=_X=O(DZ(),tQ());else if(typeof define==="function"&&define.amd)define(["./core","./sha256"],O);else O(I.CryptoJS)})(_X,function(I){return function(){var O=I,W=O.lib,T=W.WordArray,H=O.algo,L=H.SHA256,V=H.SHA224=L.extend({_doReset:function(){this._hash=new T.init([3238371032,914150663,812702999,4144912697,4290775857,1750603025,1694076839,3204075428])},_doFinalize:function(){var P=L._doFinalize.call(this);return P.sigBytes-=4,P}});O.SHA224=L._createHelper(V),O.HmacSHA224=L._createHmacHelper(V)}(),I.SHA224})});
|
|
17
|
+
export{DZ as ya,tQ as za,dG as Aa};
|
|
18
|
+
|
|
19
|
+
//# debugId=EC7B4E31E9447DE464756E2164756E21
|
|
20
|
+
//# sourceMappingURL=chunk-yrxe491r.js.map
|