diff --git a/404.html b/404.html index 9b3974b6..2c32c300 100644 --- a/404.html +++ b/404.html @@ -1,4 +1,4 @@ -404: This page could not be found

404

This page could not be found.

\ No newline at end of file +

404

This page could not be found.

\ No newline at end of file diff --git a/404/index.html b/404/index.html index 9b3974b6..2c32c300 100644 --- a/404/index.html +++ b/404/index.html @@ -1,4 +1,4 @@ -404: This page could not be found

404

This page could not be found.

\ No newline at end of file +

404

This page could not be found.

\ No newline at end of file diff --git a/_next/static/chunks/pages/_app-b9f73300e65ed714.js b/_next/static/chunks/pages/_app-484b48379908877d.js similarity index 94% rename from _next/static/chunks/pages/_app-b9f73300e65ed714.js rename to _next/static/chunks/pages/_app-484b48379908877d.js index 4d9146c7..7e81f990 100644 --- a/_next/static/chunks/pages/_app-b9f73300e65ed714.js +++ b/_next/static/chunks/pages/_app-484b48379908877d.js @@ -380,7 +380,7 @@ ${et.item_hash}`)}ei.any=eb,ei.GetVerificationBuffer=ey},16863:function(et,ei,es * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. - */var es="function"==typeof Symbol&&Symbol.for,ef=es?Symbol.for("react.element"):60103,eu=es?Symbol.for("react.portal"):60106,ed=es?Symbol.for("react.fragment"):60107,em=es?Symbol.for("react.strict_mode"):60108,eH=es?Symbol.for("react.profiler"):60114,ez=es?Symbol.for("react.provider"):60109,eV=es?Symbol.for("react.context"):60110,eM=es?Symbol.for("react.async_mode"):60111,eg=es?Symbol.for("react.concurrent_mode"):60111,eL=es?Symbol.for("react.forward_ref"):60112,eb=es?Symbol.for("react.suspense"):60113,ey=es?Symbol.for("react.suspense_list"):60120,eC=es?Symbol.for("react.memo"):60115,ex=es?Symbol.for("react.lazy"):60116,ew=es?Symbol.for("react.block"):60121,eN=es?Symbol.for("react.fundamental"):60117,eS=es?Symbol.for("react.responder"):60118,eA=es?Symbol.for("react.scope"):60119;function e_(et){if("object"==typeof et&&null!==et){var ei=et.$$typeof;switch(ei){case ef:switch(et=et.type){case eM:case eg:case ed:case eH:case em:case eb:return et;default:switch(et=et&&et.$$typeof){case eV:case eL:case ex:case eC:case ez:return et;default:return ei}}case eu:return ei}}}function eE(et){return e_(et)===eg}ei.AsyncMode=eM,ei.ConcurrentMode=eg,ei.ContextConsumer=eV,ei.ContextProvider=ez,ei.Element=ef,ei.ForwardRef=eL,ei.Fragment=ed,ei.Lazy=ex,ei.Memo=eC,ei.Portal=eu,ei.Profiler=eH,ei.StrictMode=em,ei.Suspense=eb,ei.isAsyncMode=function(et){return eE(et)||e_(et)===eM},ei.isConcurrentMode=eE,ei.isContextConsumer=function(et){return e_(et)===eV},ei.isContextProvider=function(et){return e_(et)===ez},ei.isElement=function(et){return"object"==typeof et&&null!==et&&et.$$typeof===ef},ei.isForwardRef=function(et){return e_(et)===eL},ei.isFragment=function(et){return e_(et)===ed},ei.isLazy=function(et){return e_(et)===ex},ei.isMemo=function(et){return e_(et)===eC},ei.isPortal=function(et){return e_(et)===eu},ei.isProfiler=function(et){return e_(et)===eH},ei.isStrictMode=function(et){return e_(et)===em},ei.isSuspense=function(et){return e_(et)===eb},ei.isValidElementType=function(et){return"string"==typeof et||"function"==typeof et||et===ed||et===eg||et===eH||et===em||et===eb||et===ey||"object"==typeof et&&null!==et&&(et.$$typeof===ex||et.$$typeof===eC||et.$$typeof===ez||et.$$typeof===eV||et.$$typeof===eL||et.$$typeof===eN||et.$$typeof===eS||et.$$typeof===eA||et.$$typeof===ew)},ei.typeOf=e_},21296:function(et,ei,es){"use strict";et.exports=es(96103)},80645:function(et,ei){/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh */ei.read=function(et,ei,es,ef,eu){var ed,em,eH=8*eu-ef-1,ez=(1<>1,eM=-7,eg=es?eu-1:0,eL=es?-1:1,eb=et[ei+eg];for(eg+=eL,ed=eb&(1<<-eM)-1,eb>>=-eM,eM+=eH;eM>0;ed=256*ed+et[ei+eg],eg+=eL,eM-=8);for(em=ed&(1<<-eM)-1,ed>>=-eM,eM+=ef;eM>0;em=256*em+et[ei+eg],eg+=eL,eM-=8);if(0===ed)ed=1-eV;else{if(ed===ez)return em?NaN:(eb?-1:1)*(1/0);em+=Math.pow(2,ef),ed-=eV}return(eb?-1:1)*em*Math.pow(2,ed-ef)},ei.write=function(et,ei,es,ef,eu,ed){var em,eH,ez,eV=8*ed-eu-1,eM=(1<>1,eL=23===eu?5960464477539062e-23:0,eb=ef?0:ed-1,ey=ef?1:-1,eC=ei<0||0===ei&&1/ei<0?1:0;for(isNaN(ei=Math.abs(ei))||ei===1/0?(eH=isNaN(ei)?1:0,em=eM):(em=Math.floor(Math.log(ei)/Math.LN2),ei*(ez=Math.pow(2,-em))<1&&(em--,ez*=2),em+eg>=1?ei+=eL/ez:ei+=eL*Math.pow(2,1-eg),ei*ez>=2&&(em++,ez/=2),em+eg>=eM?(eH=0,em=eM):em+eg>=1?(eH=(ei*ez-1)*Math.pow(2,eu),em+=eg):(eH=ei*Math.pow(2,eg-1)*Math.pow(2,eu),em=0));eu>=8;et[es+eb]=255&eH,eb+=ey,eH/=256,eu-=8);for(em=em<0;et[es+eb]=255&em,eb+=ey,em/=256,eV-=8);et[es+eb-ey]|=128*eC}},35717:function(et){"function"==typeof Object.create?et.exports=function(et,ei){ei&&(et.super_=ei,et.prototype=Object.create(ei.prototype,{constructor:{value:et,enumerable:!1,writable:!0,configurable:!0}}))}:et.exports=function(et,ei){if(ei){et.super_=ei;var es=function(){};es.prototype=ei.prototype,et.prototype=new es,et.prototype.constructor=et}}},82584:function(et,ei,es){"use strict";var ef=es(96410)(),eu=es(21924)("Object.prototype.toString"),ed=function(et){return(!ef||!et||"object"!=typeof et||!(Symbol.toStringTag in et))&&"[object Arguments]"===eu(et)},em=function(et){return!!ed(et)||null!==et&&"object"==typeof et&&"number"==typeof et.length&&et.length>=0&&"[object Array]"!==eu(et)&&"[object Function]"===eu(et.callee)},eH=function(){return ed(arguments)}();ed.isLegacyArguments=em,et.exports=eH?ed:em},95320:function(et){"use strict";var ei,es,ef=Function.prototype.toString,eu="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof eu&&"function"==typeof Object.defineProperty)try{ei=Object.defineProperty({},"length",{get:function(){throw es}}),es={},eu(function(){throw 42},null,ei)}catch(et){et!==es&&(eu=null)}else eu=null;var ed=/^\s*class\b/,em=function(et){try{var ei=ef.call(et);return ed.test(ei)}catch(et){return!1}},eH=function(et){try{if(em(et))return!1;return ef.call(et),!0}catch(et){return!1}},ez=Object.prototype.toString,eV="[object Object]",eM="[object Function]",eg="[object GeneratorFunction]",eL="[object HTMLAllCollection]",eb="[object HTML document.all class]",ey="[object HTMLCollection]",eC="function"==typeof Symbol&&!!Symbol.toStringTag,ex=!(0 in[,]),ew=function(){return!1};if("object"==typeof document){var eN=document.all;ez.call(eN)===ez.call(document.all)&&(ew=function(et){if((ex||!et)&&(void 0===et||"object"==typeof et))try{var ei=ez.call(et);return(ei===eL||ei===eb||ei===ey||ei===eV)&&null==et("")}catch(et){}return!1})}et.exports=eu?function(et){if(ew(et))return!0;if(!et||"function"!=typeof et&&"object"!=typeof et)return!1;try{eu(et,null,ei)}catch(et){if(et!==es)return!1}return!em(et)&&eH(et)}:function(et){if(ew(et))return!0;if(!et||"function"!=typeof et&&"object"!=typeof et)return!1;if(eC)return eH(et);if(em(et))return!1;var ei=ez.call(et);return!!(ei===eM||ei===eg||/^\[object HTML/.test(ei))&&eH(et)}},48662:function(et,ei,es){"use strict";var ef,eu=Object.prototype.toString,ed=Function.prototype.toString,em=/^\s*(?:function)?\*/,eH=es(96410)(),ez=Object.getPrototypeOf,eV=function(){if(!eH)return!1;try{return Function("return function*() {}")()}catch(et){}};et.exports=function(et){if("function"!=typeof et)return!1;if(em.test(ed.call(et)))return!0;if(!eH)return"[object GeneratorFunction]"===eu.call(et);if(!ez)return!1;if(void 0===ef){var ei=eV();ef=!!ei&&ez(ei)}return ez(et)===ef}},23944:function(et){et.exports=function(et){if("string"!=typeof et)throw Error("[is-hex-prefixed] value must be type 'string', is currently type "+typeof et+", while checking isHexPrefixed.");return"0x"===et.slice(0,2)}},98611:function(et){"use strict";et.exports=function(et){return et!=et}},20360:function(et,ei,es){"use strict";var ef=es(55559),eu=es(4289),ed=es(98611),em=es(29415),eH=es(23194),ez=ef(em(),Number);eu(ez,{getPolyfill:em,implementation:ed,shim:eH}),et.exports=ez},29415:function(et,ei,es){"use strict";var ef=es(98611);et.exports=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:ef}},23194:function(et,ei,es){"use strict";var ef=es(4289),eu=es(29415);et.exports=function(){var et=eu();return ef(Number,{isNaN:et},{isNaN:function(){return Number.isNaN!==et}}),et}},85692:function(et,ei,es){"use strict";var ef=es(94029),eu=es(63083),ed=es(21924),em=ed("Object.prototype.toString"),eH=es(96410)(),ez=es(27296),eV="undefined"==typeof globalThis?es.g:globalThis,eM=eu(),eg=ed("Array.prototype.indexOf",!0)||function(et,ei){for(var es=0;es-1)}},31198:function(et,ei,es){"use strict";let ef=es(64667).v4,eu=es(17741),ed=function(et,ei){if(!(this instanceof ed))return new ed(et,ei);ei||(ei={}),this.options={reviver:void 0!==ei.reviver?ei.reviver:null,replacer:void 0!==ei.replacer?ei.replacer:null,generator:void 0!==ei.generator?ei.generator:function(){return ef()},version:void 0!==ei.version?ei.version:2,notificationIdNull:"boolean"==typeof ei.notificationIdNull&&ei.notificationIdNull},this.callServer=et};et.exports=ed,ed.prototype.request=function(et,ei,es,ef){let ed;let em=this,eH=null,ez=Array.isArray(et)&&"function"==typeof ei;if(1===this.options.version&&ez)throw TypeError("JSON-RPC 1.0 does not support batching");let eV=!ez&&et&&"object"==typeof et&&"function"==typeof ei;if(ez||eV)ef=ei,eH=et;else{"function"==typeof es&&(ef=es,es=void 0);let ed="function"==typeof ef;try{eH=eu(et,ei,es,{generator:this.options.generator,version:this.options.version,notificationIdNull:this.options.notificationIdNull})}catch(et){if(ed)return ef(et);throw et}if(!ed)return eH}try{ed=JSON.stringify(eH,this.options.replacer)}catch(et){return ef(et)}return this.callServer(ed,function(et,ei){em._parseResponse(et,ei,ef)}),eH},ed.prototype._parseResponse=function(et,ei,es){let ef;if(et){es(et);return}if(!ei)return es();try{ef=JSON.parse(ei,this.options.reviver)}catch(et){return es(et)}if(3===es.length){if(!Array.isArray(ef))return es(null,ef.error,ef.result);{let et=function(et){return void 0!==et.error},ei=function(ei){return!et(ei)};return es(null,ef.filter(et),ef.filter(ei))}}es(null,ef)}},17741:function(et,ei,es){"use strict";let ef=es(64667).v4,eu=function(et,ei,es,eu){if("string"!=typeof et)throw TypeError(et+" must be a string");eu=eu||{};let ed="number"==typeof eu.version?eu.version:2;if(1!==ed&&2!==ed)throw TypeError(ed+" must be 1 or 2");let em={method:et};if(2===ed&&(em.jsonrpc="2.0"),ei){if("object"!=typeof ei&&!Array.isArray(ei))throw TypeError(ei+" must be an object, array or omitted");em.params=ei}if(void 0===es){let et="function"==typeof eu.generator?eu.generator:function(){return ef()};em.id=et(em,eu)}else 2===ed&&null===es?eu.notificationIdNull&&(em.id=null):em.id=es;return em};et.exports=eu},64667:function(et,ei,es){"use strict";es.d(ei,{v4:function(){return eg}});var ef,eu=new Uint8Array(16);function ed(){if(!ef&&!(ef="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ef(eu)}for(var em=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,eH=function(et){return"string"==typeof et&&em.test(et)},ez=[],eV=0;eV<256;++eV)ez.push((eV+256).toString(16).substr(1));var eM=function(et){var ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,es=(ez[et[ei+0]]+ez[et[ei+1]]+ez[et[ei+2]]+ez[et[ei+3]]+"-"+ez[et[ei+4]]+ez[et[ei+5]]+"-"+ez[et[ei+6]]+ez[et[ei+7]]+"-"+ez[et[ei+8]]+ez[et[ei+9]]+"-"+ez[et[ei+10]]+ez[et[ei+11]]+ez[et[ei+12]]+ez[et[ei+13]]+ez[et[ei+14]]+ez[et[ei+15]]).toLowerCase();if(!eH(es))throw TypeError("Stringified UUID is invalid");return es},eg=function(et,ei,es){var ef=(et=et||{}).random||(et.rng||ed)();if(ef[6]=15&ef[6]|64,ef[8]=63&ef[8]|128,ei){es=es||0;for(var eu=0;eu<16;++eu)ei[es+eu]=ef[eu];return ei}return eM(ef)}},91094:function(et,ei,es){var ef,eu=es(83454);!function(){"use strict";var ed="input is invalid type",em="finalize already called",eH="object"==typeof window,ez=eH?window:{};ez.JS_SHA3_NO_WINDOW&&(eH=!1);var eV=!eH&&"object"==typeof self;!ez.JS_SHA3_NO_NODE_JS&&"object"==typeof eu&&eu.versions&&eu.versions.node?ez=es.g:eV&&(ez=self);var eM=!ez.JS_SHA3_NO_COMMON_JS&&et.exports,eg=es.amdO,eL=!ez.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,eb="0123456789abcdef".split(""),ey=[31,7936,2031616,520093696],eC=[4,1024,262144,67108864],ex=[1,256,65536,16777216],ew=[6,1536,393216,100663296],eN=[0,8,16,24],eS=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],eA=[224,256,384,512],e_=[128,256],eE=["hex","buffer","arrayBuffer","array","digest"],eP={128:168,256:136};(ez.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(et){return"[object Array]"===Object.prototype.toString.call(et)}),eL&&(ez.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(et){return"object"==typeof et&&et.buffer&&et.buffer.constructor===ArrayBuffer});for(var eB=function(et,ei,es){return function(ef){return new eJ(et,ei,et).update(ef)[es]()}},eT=function(et,ei,es){return function(ef,eu){return new eJ(et,ei,eu).update(ef)[es]()}},eI=function(et,ei,es){return function(ei,ef,eu,ed){return eF["cshake"+et].update(ei,ef,eu,ed)[es]()}},eR=function(et,ei,es){return function(ei,ef,eu,ed){return eF["kmac"+et].update(ei,ef,eu,ed)[es]()}},eO=function(et,ei,es,ef){for(var eu=0;eu>5,this.byteCount=this.blockCount<<2,this.outputBlocks=es>>5,this.extraBytes=(31&es)>>3;for(var ef=0;ef<50;++ef)this.s[ef]=0}function eY(et,ei,es){eJ.call(this,et,ei,es)}eJ.prototype.update=function(et){if(this.finalized)throw Error(em);var ei,es=typeof et;if("string"!==es){if("object"===es){if(null===et)throw Error(ed);if(eL&&et.constructor===ArrayBuffer)et=new Uint8Array(et);else if(!Array.isArray(et)&&(!eL||!ArrayBuffer.isView(et)))throw Error(ed)}else throw Error(ed);ei=!0}for(var ef,eu,eH=this.blocks,ez=this.byteCount,eV=et.length,eM=this.blockCount,eg=0,eb=this.s;eg>2]|=et[eg]<>2]|=eu<>2]|=(192|eu>>6)<>2]|=(128|63&eu)<=57344?(eH[ef>>2]|=(224|eu>>12)<>2]|=(128|eu>>6&63)<>2]|=(128|63&eu)<>2]|=(240|eu>>18)<>2]|=(128|eu>>12&63)<>2]|=(128|eu>>6&63)<>2]|=(128|63&eu)<=ez){for(this.start=ef-ez,this.block=eH[eM],ef=0;ef>=8,es=255&et;es>0;)eu.unshift(es),et>>=8,es=255&et,++ef;return ei?eu.push(ef):eu.unshift(ef),this.update(eu),eu.length},eJ.prototype.encodeString=function(et){var ei,es=typeof et;if("string"!==es){if("object"===es){if(null===et)throw Error(ed);if(eL&&et.constructor===ArrayBuffer)et=new Uint8Array(et);else if(!Array.isArray(et)&&(!eL||!ArrayBuffer.isView(et)))throw Error(ed)}else throw Error(ed);ei=!0}var ef=0,eu=et.length;if(ei)ef=eu;else for(var em=0;em=57344?ef+=3:(eH=65536+((1023&eH)<<10|1023&et.charCodeAt(++em)),ef+=4)}return ef+=this.encode(8*ef),this.update(et),ef},eJ.prototype.bytepad=function(et,ei){for(var es=this.encode(ei),ef=0;ef>2]|=this.padding[3&ei],this.lastByteIndex===this.byteCount)for(ei=1,et[0]=et[es];ei>4&15]+eb[15&et]+eb[et>>12&15]+eb[et>>8&15]+eb[et>>20&15]+eb[et>>16&15]+eb[et>>28&15]+eb[et>>24&15];em%ei==0&&(eX(es),ed=0)}return eu&&(eH+=eb[(et=es[ed])>>4&15]+eb[15&et],eu>1&&(eH+=eb[et>>12&15]+eb[et>>8&15]),eu>2&&(eH+=eb[et>>20&15]+eb[et>>16&15])),eH},eJ.prototype.arrayBuffer=function(){this.finalize();var et,ei=this.blockCount,es=this.s,ef=this.outputBlocks,eu=this.extraBytes,ed=0,em=0,eH=this.outputBits>>3;et=new ArrayBuffer(eu?ef+1<<2:eH);for(var ez=new Uint32Array(et);em>8&255,ez[et+2]=ei>>16&255,ez[et+3]=ei>>24&255;eH%es==0&&eX(ef)}return ed&&(et=eH<<2,ei=ef[em],ez[et]=255&ei,ed>1&&(ez[et+1]=ei>>8&255),ed>2&&(ez[et+2]=ei>>16&255)),ez},eY.prototype=new eJ,eY.prototype.finalize=function(){return this.encode(this.outputBits,!0),eJ.prototype.finalize.call(this)};var eX=function(et){var ei,es,ef,eu,ed,em,eH,ez,eV,eM,eg,eL,eb,ey,eC,ex,ew,eN,eA,e_,eE,eP,eB,eT,eI,eR,eO,ej,eD,eF,eU,eq,eZ,eG,eW,eK,e$,eJ,eY,eX,eQ,e1,e2,e4,e3,e6,e0,e8,e5,e7,e9,cc,ci,cs,cf,cd,cm,cH,cz,cV,cM,cg,cL;for(ef=0;ef<48;ef+=2)eu=et[0]^et[10]^et[20]^et[30]^et[40],ed=et[1]^et[11]^et[21]^et[31]^et[41],em=et[2]^et[12]^et[22]^et[32]^et[42],eH=et[3]^et[13]^et[23]^et[33]^et[43],ez=et[4]^et[14]^et[24]^et[34]^et[44],eV=et[5]^et[15]^et[25]^et[35]^et[45],eM=et[6]^et[16]^et[26]^et[36]^et[46],eg=et[7]^et[17]^et[27]^et[37]^et[47],eL=et[8]^et[18]^et[28]^et[38]^et[48],eb=et[9]^et[19]^et[29]^et[39]^et[49],ei=eL^(em<<1|eH>>>31),es=eb^(eH<<1|em>>>31),et[0]^=ei,et[1]^=es,et[10]^=ei,et[11]^=es,et[20]^=ei,et[21]^=es,et[30]^=ei,et[31]^=es,et[40]^=ei,et[41]^=es,ei=eu^(ez<<1|eV>>>31),es=ed^(eV<<1|ez>>>31),et[2]^=ei,et[3]^=es,et[12]^=ei,et[13]^=es,et[22]^=ei,et[23]^=es,et[32]^=ei,et[33]^=es,et[42]^=ei,et[43]^=es,ei=em^(eM<<1|eg>>>31),es=eH^(eg<<1|eM>>>31),et[4]^=ei,et[5]^=es,et[14]^=ei,et[15]^=es,et[24]^=ei,et[25]^=es,et[34]^=ei,et[35]^=es,et[44]^=ei,et[45]^=es,ei=ez^(eL<<1|eb>>>31),es=eV^(eb<<1|eL>>>31),et[6]^=ei,et[7]^=es,et[16]^=ei,et[17]^=es,et[26]^=ei,et[27]^=es,et[36]^=ei,et[37]^=es,et[46]^=ei,et[47]^=es,ei=eM^(eu<<1|ed>>>31),es=eg^(ed<<1|eu>>>31),et[8]^=ei,et[9]^=es,et[18]^=ei,et[19]^=es,et[28]^=ei,et[29]^=es,et[38]^=ei,et[39]^=es,et[48]^=ei,et[49]^=es,ey=et[0],eC=et[1],e6=et[11]<<4|et[10]>>>28,e0=et[10]<<4|et[11]>>>28,ej=et[20]<<3|et[21]>>>29,eD=et[21]<<3|et[20]>>>29,cV=et[31]<<9|et[30]>>>23,cM=et[30]<<9|et[31]>>>23,e1=et[40]<<18|et[41]>>>14,e2=et[41]<<18|et[40]>>>14,eG=et[2]<<1|et[3]>>>31,eW=et[3]<<1|et[2]>>>31,ex=et[13]<<12|et[12]>>>20,ew=et[12]<<12|et[13]>>>20,e8=et[22]<<10|et[23]>>>22,e5=et[23]<<10|et[22]>>>22,eF=et[33]<<13|et[32]>>>19,eU=et[32]<<13|et[33]>>>19,cg=et[42]<<2|et[43]>>>30,cL=et[43]<<2|et[42]>>>30,cs=et[5]<<30|et[4]>>>2,cf=et[4]<<30|et[5]>>>2,eK=et[14]<<6|et[15]>>>26,e$=et[15]<<6|et[14]>>>26,eN=et[25]<<11|et[24]>>>21,eA=et[24]<<11|et[25]>>>21,e7=et[34]<<15|et[35]>>>17,e9=et[35]<<15|et[34]>>>17,eq=et[45]<<29|et[44]>>>3,eZ=et[44]<<29|et[45]>>>3,eT=et[6]<<28|et[7]>>>4,eI=et[7]<<28|et[6]>>>4,cd=et[17]<<23|et[16]>>>9,cm=et[16]<<23|et[17]>>>9,eJ=et[26]<<25|et[27]>>>7,eY=et[27]<<25|et[26]>>>7,e_=et[36]<<21|et[37]>>>11,eE=et[37]<<21|et[36]>>>11,cc=et[47]<<24|et[46]>>>8,ci=et[46]<<24|et[47]>>>8,e4=et[8]<<27|et[9]>>>5,e3=et[9]<<27|et[8]>>>5,eR=et[18]<<20|et[19]>>>12,eO=et[19]<<20|et[18]>>>12,cH=et[29]<<7|et[28]>>>25,cz=et[28]<<7|et[29]>>>25,eX=et[38]<<8|et[39]>>>24,eQ=et[39]<<8|et[38]>>>24,eP=et[48]<<14|et[49]>>>18,eB=et[49]<<14|et[48]>>>18,et[0]=ey^~ex&eN,et[1]=eC^~ew&eA,et[10]=eT^~eR&ej,et[11]=eI^~eO&eD,et[20]=eG^~eK&eJ,et[21]=eW^~e$&eY,et[30]=e4^~e6&e8,et[31]=e3^~e0&e5,et[40]=cs^~cd&cH,et[41]=cf^~cm&cz,et[2]=ex^~eN&e_,et[3]=ew^~eA&eE,et[12]=eR^~ej&eF,et[13]=eO^~eD&eU,et[22]=eK^~eJ&eX,et[23]=e$^~eY&eQ,et[32]=e6^~e8&e7,et[33]=e0^~e5&e9,et[42]=cd^~cH&cV,et[43]=cm^~cz&cM,et[4]=eN^~e_&eP,et[5]=eA^~eE&eB,et[14]=ej^~eF&eq,et[15]=eD^~eU&eZ,et[24]=eJ^~eX&e1,et[25]=eY^~eQ&e2,et[34]=e8^~e7&cc,et[35]=e5^~e9&ci,et[44]=cH^~cV&cg,et[45]=cz^~cM&cL,et[6]=e_^~eP&ey,et[7]=eE^~eB&eC,et[16]=eF^~eq&eT,et[17]=eU^~eZ&eI,et[26]=eX^~e1&eG,et[27]=eQ^~e2&eW,et[36]=e7^~cc&e4,et[37]=e9^~ci&e3,et[46]=cV^~cg&cs,et[47]=cM^~cL&cf,et[8]=eP^~ey&ex,et[9]=eB^~eC&ew,et[18]=eq^~eT&eR,et[19]=eZ^~eI&eO,et[28]=e1^~eG&eK,et[29]=e2^~eW&e$,et[38]=cc^~e4&e6,et[39]=ci^~e3&e0,et[48]=cg^~cs&cd,et[49]=cL^~cf&cm,et[0]^=eS[ef],et[1]^=eS[ef+1]};if(eM)et.exports=eF;else{for(eq=0;eqclass ei extends eu{constructor(ei,es,ef,eu,ed){super(ed),this._rate=ei,this._capacity=es,this._delimitedSuffix=ef,this._hashBitLength=eu,this._options=ed,this._state=new et,this._state.initialize(ei,es),this._finalized=!1}_transform(et,ei,es){let ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)}_flush(et){let ei=null;try{this.push(this.digest())}catch(et){ei=et}et(ei)}update(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Digest already called");return ef.isBuffer(et)||(et=ef.from(et,ei)),this._state.absorb(et),this}digest(et){if(this._finalized)throw Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);let ei=this._state.squeeze(this._hashBitLength/8);return void 0!==et&&(ei=ei.toString(et)),this._resetState(),ei}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let et=new ei(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(et._state),et._finalized=this._finalized,et}}},5675:function(et,ei,es){var ef=es(48764).Buffer;let{Transform:eu}=es(88473);et.exports=et=>class ei extends eu{constructor(ei,es,ef,eu){super(eu),this._rate=ei,this._capacity=es,this._delimitedSuffix=ef,this._options=eu,this._state=new et,this._state.initialize(ei,es),this._finalized=!1}_transform(et,ei,es){let ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)}_flush(){}_read(et){this.push(this.squeeze(et))}update(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Squeeze already called");return ef.isBuffer(et)||(et=ef.from(et,ei)),this._state.absorb(et),this}squeeze(et,ei){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));let es=this._state.squeeze(et);return void 0!==ei&&(es=es.toString(ei)),es}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let et=new ei(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(et._state),et._finalized=this._finalized,et}}},34040:function(et,ei){let es=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648];ei.p1600=function(et){for(let ei=0;ei<24;++ei){let ef=et[0]^et[10]^et[20]^et[30]^et[40],eu=et[1]^et[11]^et[21]^et[31]^et[41],ed=et[2]^et[12]^et[22]^et[32]^et[42],em=et[3]^et[13]^et[23]^et[33]^et[43],eH=et[4]^et[14]^et[24]^et[34]^et[44],ez=et[5]^et[15]^et[25]^et[35]^et[45],eV=et[6]^et[16]^et[26]^et[36]^et[46],eM=et[7]^et[17]^et[27]^et[37]^et[47],eg=et[8]^et[18]^et[28]^et[38]^et[48],eL=et[9]^et[19]^et[29]^et[39]^et[49],eb=eg^(ed<<1|em>>>31),ey=eL^(em<<1|ed>>>31),eC=et[0]^eb,ex=et[1]^ey,ew=et[10]^eb,eN=et[11]^ey,eS=et[20]^eb,eA=et[21]^ey,e_=et[30]^eb,eE=et[31]^ey,eP=et[40]^eb,eB=et[41]^ey;eb=ef^(eH<<1|ez>>>31),ey=eu^(ez<<1|eH>>>31);let eT=et[2]^eb,eI=et[3]^ey,eR=et[12]^eb,eO=et[13]^ey,ej=et[22]^eb,eD=et[23]^ey,eF=et[32]^eb,eU=et[33]^ey,eq=et[42]^eb,eZ=et[43]^ey;eb=ed^(eV<<1|eM>>>31),ey=em^(eM<<1|eV>>>31);let eG=et[4]^eb,eW=et[5]^ey,eK=et[14]^eb,e$=et[15]^ey,eJ=et[24]^eb,eY=et[25]^ey,eX=et[34]^eb,eQ=et[35]^ey,e1=et[44]^eb,e2=et[45]^ey;eb=eH^(eg<<1|eL>>>31),ey=ez^(eL<<1|eg>>>31);let e4=et[6]^eb,e3=et[7]^ey,e6=et[16]^eb,e0=et[17]^ey,e8=et[26]^eb,e5=et[27]^ey,e7=et[36]^eb,e9=et[37]^ey,cc=et[46]^eb,ci=et[47]^ey;eb=eV^(ef<<1|eu>>>31),ey=eM^(eu<<1|ef>>>31);let cs=et[8]^eb,cf=et[9]^ey,cd=et[18]^eb,cm=et[19]^ey,cH=et[28]^eb,cz=et[29]^ey,cV=et[38]^eb,cM=et[39]^ey,cg=et[48]^eb,cL=et[49]^ey,cy=eC,cC=ex,cx=eN<<4|ew>>>28,cw=ew<<4|eN>>>28,ck=eS<<3|eA>>>29,cN=eA<<3|eS>>>29,cS=eE<<9|e_>>>23,cA=e_<<9|eE>>>23,c_=eP<<18|eB>>>14,cE=eB<<18|eP>>>14,cP=eT<<1|eI>>>31,cB=eI<<1|eT>>>31,cT=eO<<12|eR>>>20,cI=eR<<12|eO>>>20,cR=ej<<10|eD>>>22,cO=eD<<10|ej>>>22,cj=eU<<13|eF>>>19,cD=eF<<13|eU>>>19,cF=eq<<2|eZ>>>30,cU=eZ<<2|eq>>>30,cq=eW<<30|eG>>>2,cZ=eG<<30|eW>>>2,cG=eK<<6|e$>>>26,cW=e$<<6|eK>>>26,cK=eY<<11|eJ>>>21,c$=eJ<<11|eY>>>21,cJ=eX<<15|eQ>>>17,cY=eQ<<15|eX>>>17,cX=e2<<29|e1>>>3,cQ=e1<<29|e2>>>3,tc=e4<<28|e3>>>4,ta=e3<<28|e4>>>4,tf=e0<<23|e6>>>9,tu=e6<<23|e0>>>9,td=e8<<25|e5>>>7,tm=e5<<25|e8>>>7,tp=e7<<21|e9>>>11,tH=e9<<21|e7>>>11,tz=ci<<24|cc>>>8,tV=cc<<24|ci>>>8,tv=cs<<27|cf>>>5,tM=cf<<27|cs>>>5,tg=cd<<20|cm>>>12,tL=cm<<20|cd>>>12,tb=cz<<7|cH>>>25,tC=cH<<7|cz>>>25,tw=cV<<8|cM>>>24,tN=cM<<8|cV>>>24,tS=cg<<14|cL>>>18,tA=cL<<14|cg>>>18;et[0]=cy^~cT&cK,et[1]=cC^~cI&c$,et[10]=tc^~tg&ck,et[11]=ta^~tL&cN,et[20]=cP^~cG&td,et[21]=cB^~cW&tm,et[30]=tv^~cx&cR,et[31]=tM^~cw&cO,et[40]=cq^~tf&tb,et[41]=cZ^~tu&tC,et[2]=cT^~cK&tp,et[3]=cI^~c$&tH,et[12]=tg^~ck&cj,et[13]=tL^~cN&cD,et[22]=cG^~td&tw,et[23]=cW^~tm&tN,et[32]=cx^~cR&cJ,et[33]=cw^~cO&cY,et[42]=tf^~tb&cS,et[43]=tu^~tC&cA,et[4]=cK^~tp&tS,et[5]=c$^~tH&tA,et[14]=ck^~cj&cX,et[15]=cN^~cD&cQ,et[24]=td^~tw&c_,et[25]=tm^~tN&cE,et[34]=cR^~cJ&tz,et[35]=cO^~cY&tV,et[44]=tb^~cS&cF,et[45]=tC^~cA&cU,et[6]=tp^~tS&cy,et[7]=tH^~tA&cC,et[16]=cj^~cX&tc,et[17]=cD^~cQ&ta,et[26]=tw^~c_&cP,et[27]=tN^~cE&cB,et[36]=cJ^~tz&tv,et[37]=cY^~tV&tM,et[46]=cS^~cF&cq,et[47]=cA^~cU&cZ,et[8]=tS^~cy&cT,et[9]=tA^~cC&cI,et[18]=cX^~tc&tg,et[19]=cQ^~ta&tL,et[28]=c_^~cP&cG,et[29]=cE^~cB&cW,et[38]=tz^~tv&cx,et[39]=tV^~tM&cw,et[48]=cF^~cq&tf,et[49]=cU^~cZ&tu,et[0]^=es[2*ei],et[1]^=es[2*ei+1]}}},79653:function(et,ei,es){var ef=es(48764).Buffer;let eu=es(34040);function ed(){this.state=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],this.blockSize=null,this.count=0,this.squeezing=!1}ed.prototype.initialize=function(et,ei){for(let et=0;et<50;++et)this.state[et]=0;this.blockSize=et/8,this.count=0,this.squeezing=!1},ed.prototype.absorb=function(et){for(let ei=0;ei>>8*(this.count%4)&255,this.count+=1,this.count===this.blockSize&&(eu.p1600(this.state),this.count=0);return ei},ed.prototype.copy=function(et){for(let ei=0;ei<50;++ei)et.state[ei]=this.state[ei];et.blockSize=this.blockSize,et.count=this.count,et.squeezing=this.squeezing},et.exports=ed},62318:function(et,ei,es){"use strict";var ef=es(35717),eu=es(3349),ed=es(89509).Buffer,em=Array(16);function eH(){eu.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function ez(et,ei){return et<>>32-ei}function eV(et,ei,es,ef,eu,ed,em){return ez(et+(ei&es|~ei&ef)+eu+ed|0,em)+ei|0}function eM(et,ei,es,ef,eu,ed,em){return ez(et+(ei&ef|es&~ef)+eu+ed|0,em)+ei|0}function eg(et,ei,es,ef,eu,ed,em){return ez(et+(ei^es^ef)+eu+ed|0,em)+ei|0}function eL(et,ei,es,ef,eu,ed,em){return ez(et+(es^(ei|~ef))+eu+ed|0,em)+ei|0}ef(eH,eu),eH.prototype._update=function(){for(var et=em,ei=0;ei<16;++ei)et[ei]=this._block.readInt32LE(4*ei);var es=this._a,ef=this._b,eu=this._c,ed=this._d;es=eV(es,ef,eu,ed,et[0],3614090360,7),ed=eV(ed,es,ef,eu,et[1],3905402710,12),eu=eV(eu,ed,es,ef,et[2],606105819,17),ef=eV(ef,eu,ed,es,et[3],3250441966,22),es=eV(es,ef,eu,ed,et[4],4118548399,7),ed=eV(ed,es,ef,eu,et[5],1200080426,12),eu=eV(eu,ed,es,ef,et[6],2821735955,17),ef=eV(ef,eu,ed,es,et[7],4249261313,22),es=eV(es,ef,eu,ed,et[8],1770035416,7),ed=eV(ed,es,ef,eu,et[9],2336552879,12),eu=eV(eu,ed,es,ef,et[10],4294925233,17),ef=eV(ef,eu,ed,es,et[11],2304563134,22),es=eV(es,ef,eu,ed,et[12],1804603682,7),ed=eV(ed,es,ef,eu,et[13],4254626195,12),eu=eV(eu,ed,es,ef,et[14],2792965006,17),ef=eV(ef,eu,ed,es,et[15],1236535329,22),es=eM(es,ef,eu,ed,et[1],4129170786,5),ed=eM(ed,es,ef,eu,et[6],3225465664,9),eu=eM(eu,ed,es,ef,et[11],643717713,14),ef=eM(ef,eu,ed,es,et[0],3921069994,20),es=eM(es,ef,eu,ed,et[5],3593408605,5),ed=eM(ed,es,ef,eu,et[10],38016083,9),eu=eM(eu,ed,es,ef,et[15],3634488961,14),ef=eM(ef,eu,ed,es,et[4],3889429448,20),es=eM(es,ef,eu,ed,et[9],568446438,5),ed=eM(ed,es,ef,eu,et[14],3275163606,9),eu=eM(eu,ed,es,ef,et[3],4107603335,14),ef=eM(ef,eu,ed,es,et[8],1163531501,20),es=eM(es,ef,eu,ed,et[13],2850285829,5),ed=eM(ed,es,ef,eu,et[2],4243563512,9),eu=eM(eu,ed,es,ef,et[7],1735328473,14),ef=eM(ef,eu,ed,es,et[12],2368359562,20),es=eg(es,ef,eu,ed,et[5],4294588738,4),ed=eg(ed,es,ef,eu,et[8],2272392833,11),eu=eg(eu,ed,es,ef,et[11],1839030562,16),ef=eg(ef,eu,ed,es,et[14],4259657740,23),es=eg(es,ef,eu,ed,et[1],2763975236,4),ed=eg(ed,es,ef,eu,et[4],1272893353,11),eu=eg(eu,ed,es,ef,et[7],4139469664,16),ef=eg(ef,eu,ed,es,et[10],3200236656,23),es=eg(es,ef,eu,ed,et[13],681279174,4),ed=eg(ed,es,ef,eu,et[0],3936430074,11),eu=eg(eu,ed,es,ef,et[3],3572445317,16),ef=eg(ef,eu,ed,es,et[6],76029189,23),es=eg(es,ef,eu,ed,et[9],3654602809,4),ed=eg(ed,es,ef,eu,et[12],3873151461,11),eu=eg(eu,ed,es,ef,et[15],530742520,16),ef=eg(ef,eu,ed,es,et[2],3299628645,23),es=eL(es,ef,eu,ed,et[0],4096336452,6),ed=eL(ed,es,ef,eu,et[7],1126891415,10),eu=eL(eu,ed,es,ef,et[14],2878612391,15),ef=eL(ef,eu,ed,es,et[5],4237533241,21),es=eL(es,ef,eu,ed,et[12],1700485571,6),ed=eL(ed,es,ef,eu,et[3],2399980690,10),eu=eL(eu,ed,es,ef,et[10],4293915773,15),ef=eL(ef,eu,ed,es,et[1],2240044497,21),es=eL(es,ef,eu,ed,et[8],1873313359,6),ed=eL(ed,es,ef,eu,et[15],4264355552,10),eu=eL(eu,ed,es,ef,et[6],2734768916,15),ef=eL(ef,eu,ed,es,et[13],1309151649,21),es=eL(es,ef,eu,ed,et[4],4149444226,6),ed=eL(ed,es,ef,eu,et[11],3174756917,10),eu=eL(eu,ed,es,ef,et[2],718787259,15),ef=eL(ef,eu,ed,es,et[9],3951481745,21),this._a=this._a+es|0,this._b=this._b+ef|0,this._c=this._c+eu|0,this._d=this._d+ed|0},eH.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ed.allocUnsafe(16);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et},et.exports=eH},79746:function(et){function ei(et,ei){if(!et)throw Error(ei||"Assertion failed")}et.exports=ei,ei.equal=function(et,ei,es){if(et!=ei)throw Error(es||"Assertion failed: "+et+" != "+ei)}},34504:function(et,ei){"use strict";var es=ei;function ef(et,ei){if(Array.isArray(et))return et.slice();if(!et)return[];var es=[];if("string"!=typeof et){for(var ef=0;ef>8,em=255&eu;ed?es.push(ed,em):es.push(em)}return es}function eu(et){return 1===et.length?"0"+et:et}function ed(et){for(var ei="",es=0;eset.toUpperCase(),eb=(0,ed.useMemo)(()=>{if(eM)return[];let et=ez.pathname.split("/").filter(et=>""!==et).map((et,eu,ed)=>{let em=null==ei?void 0:ei[et];if(eu===ed.length-1){let[,ei]=ez.asPath.split("#"),eu=es||(em?"object"==typeof em?em[ei]:em:eL(et));return(0,ef.jsx)("span",{children:eu},et)}let eH=em||eL(et);return(0,ef.jsx)(eV(),{href:String("../").repeat(ed.length-(eu+1))+et,children:eH},et)});return eu&&et.unshift((0,ef.jsx)(eV(),{href:"/",children:(null==ei?void 0:ei["/"])||"HOME"},"home")),et},[ez.pathname,ez.asPath,es,ei,eM,eu]);return eM?null:(0,ef.jsx)(eg,{navLinks:eb,...eH})}var eg=(0,eu.ZP)(eH.aG).withConfig({displayName:"cmp___StyledBreadcrumb",componentId:"sc-1pse81j-0"})({paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1.25rem",paddingBottom:"1.25rem","@media (min-width: 768px)":{paddingLeft:"4rem",paddingRight:"4rem"}})},87531:function(et,ei,es){"use strict";es.d(ei,{Z:function(){return ed}});var ef=es(19521);let eu=ef.ZP.div.withConfig({displayName:"styles__StyledContainer",componentId:"sc-ex4pya-0"})(["",""],et=>{let{theme:ei}=et;return(0,ef.iv)([""," box-sizing:border-box;width:100%;margin:0 auto;max-width:","rem;"],{paddingLeft:"1.5rem",paddingRight:"1.5rem","@media (min-width: 768px)":{paddingLeft:"4rem",paddingRight:"4rem"}},ei.breakpoint.xxl+12.5)});var ed=eu},36470:function(et,ei,es){"use strict";es.d(ei,{WE:function(){return eH},mr:function(){return ez}});var ef=es(85893),eu=es(67294),ed=es(48847);let em=(0,eu.createContext)([ed.E3,()=>null]);function eH(et){let{children:ei}=et,[es,eH]=(0,eu.useReducer)(ed.I6,ed.E3);return(0,ef.jsx)(em.Provider,{value:[es,eH],children:ei})}function ez(){return(0,eu.useContext)(em)}},65526:function(et,ei,es){"use strict";es.d(ei,{Y:function(){return eH}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(22733);class eH{async getAll(){try{let et=await ef.aggregate.Get({address:this.account.address,keys:[this.key]});return this.parseAggregate(et)}catch(et){return[]}}async get(et){let ei=await this.getAll();return ei.find(ei=>ei.id===et)}async add(et,ei){et=Array.isArray(et)?et:[et],et=await this.parseDomains(et,ei);try{if(!et.length)return[];let ei=et.reduce((et,ei)=>{let{name:es,ref:ef,target:eu,programType:em}=ei,eH={message_id:ef,programType:em,type:eu};return eu===ed.vs.Program&&(eH.programType=ei.programType||ed.py.Instance),et[es]=eH,et},{}),es=await ef.aggregate.Publish({account:this.account,key:this.key,channel:this.channel,content:ei});return this.parseNewAggregate(es)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;let ei={[et]:null};try{await ef.aggregate.Publish({account:this.account,key:this.key,channel:this.channel,content:ei})}catch(et){throw eu.Z.RequestFailed(et)}}async checkStatus(et){let ei=await fetch("https://api.dns.public.aleph.sh/domain/check",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:et.name,owner:this.account.address,target:et.target})}),es=await ei.json();return es}async parseDomains(et){let ei=!(arguments.length>1)||void 0===arguments[1]||arguments[1];et=await eH.addManySchema.parseAsync(et);let es=await this.getAll(),ef=new Set(es.map(et=>et.name));return ei?et.map(et=>{if(!ef.has(et.name))return et;throw Error("Domain name already used by another resource: ".concat(et.name))}):et.filter(et=>!ef.has(et.name))}parseAggregate(et){let ei=et[this.key];return this.parseAggregateItems(ei)}parseNewAggregate(et){let ei=et.content.content;return this.parseAggregateItems(ei)}parseAggregateItems(et){return Object.entries(et).filter(et=>{let[,ei]=et;return null!==ei}).map(et=>{let[ei,es]=et;return this.parseAggregateItem(ei,es)})}parseAggregateItem(et,ei){let{message_id:es,type:ef}=ei,eu={type:ed.py.Domain,id:et,name:et,target:ef,ref:es,confirmed:!0};return ef===ed.vs.Program&&(eu.programType=ei.programType||ed.py.Instance),eu}constructor(et,ei=ed.T4,es=ed.fM){this.account=et,this.key=ei,this.channel=es}}(()=>{eH.addSchema=em.CJ})(),(()=>{eH.addManySchema=em.I})()},94443:function(et,ei,es){"use strict";es.d(ei,{E:function(){return ed}});var ef=es(59925),eu=es(33358);class ed{parseEnvVars(et){if(et&&0!==et.length)return Object.fromEntries(et.map(et=>{let{name:ei,value:es}=et;return[ei,es]}))}async parseDomains(et,ei){if(!ei||0===ei.length)return[];let es=ei.map(ei=>({...ei,ref:et}));return this.domainManager.add(es,!1)}async parseVolumes(et){if(!et||0===(et=Array.isArray(et)?et:[et]).length)return;let ei=await this.volumeManager.add(et),es=et.map((et,es)=>et.volumeType===ef.z.New?{...et,volumeType:ef.z.Existing,refHash:ei[es].id}:et);return es.map(et=>{if(et.volumeType===ef.z.Persistent){let{mountPath:ei,size:es,name:ef}=et;return{persistence:"host",mount:ei,size_mib:es,name:ef}}let{refHash:ei,mountPath:es,useLatest:eu=!1}=et;return{ref:ei,mount:es,use_latest:eu}})}parseSpecs(et){return{vcpus:et.cpu,memory:et.ram}}parseMetadata(){let et=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Untitled",ei=arguments.length>1?arguments[1]:void 0,es=arguments.length>2?arguments[2]:void 0,ef={name:et};return ei&&ei.length>0&&(ef.tags=ei),{...es,...ef}}constructor(et,ei,es){this.account=et,this.volumeManager=ei,this.domainManager=es}}(()=>{ed.getExecutableCost=et=>{let{type:ei,isPersistent:es,specs:ed,capabilities:em={},volumes:eH=[]}=et;if(!ed)return{computeTotalCost:0,volumeTotalCost:0,perVolumeCost:[],totalCost:0};es=ei===eu.py.Instance||es;let ez=es?2e3:200,eV=Object.values(em).reduce((et,ei)=>et+Number(ei),1),eM=ez*ed.cpu*eV,eg=ei===eu.py.Instance?0:ed.storage,{perVolumeCost:eL,totalCost:eb}=ef.l.getCost({volumes:eH,sizeDiscount:eg}),ey=eb+eM;return{computeTotalCost:eM,perVolumeCost:eL,volumeTotalCost:eb,totalCost:ey}}})()},21685:function(et,ei,es){"use strict";es.d(ei,{p:function(){return eg}});var ef=es(39261),eu=es(22733),ed=es(32523),em=es(70714),eH=es(34853),ez=es(59925),eV=es(33358),eM=es(48071);class eg{static getStaticProgramConfig(){let et=!0,ei={indexer:!0},es={...(0,ed.Fk)(!0)[1]},ef={lang:eM.D.Node,type:"ref",encoding:em.Encoding.squashfs,entrypoint:"dist/run.js",programRef:"32c3ac6e4810a18d3d3f64cb4dd6b2eb111993e9f9832124d3ad5efba93ce13e"},eu=eM.Y[ef.lang].runtime,eH=[{volumeType:ez.z.Persistent,name:"data",mountPath:"/data",size:40960}];return{isPersistent:et,metadata:ei,specs:es,runtime:eu,code:ef,volumes:eH}}async getAll(){try{let et=await this.programManager.getAll();return et.filter(et=>{var ei;return!!(null===(ei=et.metadata)||void 0===ei?void 0:ei.indexer)})}catch(et){return[]}}async get(et){var ei;let es=await this.programManager.get(et);if(null==es?void 0:null===(ei=es.metadata)||void 0===ei?void 0:ei.indexer)return es}async add(et){let ei=await this.parseIndexers(et);return await this.programManager.add(ei)}async del(et){await this.programManager.del(et)}parseEnvVars(et){let ei=et.networks.map(et=>{let{id:ei,blockchain:es}=et;return es===ei?ei:"".concat(es,":").concat(ei)}).join(","),es=(0,eH.mA)(et.name),ef=et.networks.reduce((et,ei)=>(et[this.getBlockchainEnvName(ei.id,"INDEX_LOGS")]="true",et[this.getBlockchainEnvName(ei.id,"INDEX_BLOCKS")]="false",et[this.getBlockchainEnvName(ei.id,"INDEX_TRANSACTIONS")]="false",et[this.getBlockchainEnvName(ei.id,"RPC")]=ei.rpcUrl,et[this.getBlockchainEnvName(ei.id,"EXPLORER_URL")]=ei.abiUrl?ei.abiUrl:eV._G[ei.blockchain],et),{}),eu=et.accounts.map(et=>{let{network:ei,contract:es,deployer:ef,supply:eu,decimals:ed}=et;return"".concat(ei,":").concat(es,":").concat(ef,":").concat(eu,":").concat(ed)}).join(",");return Object.entries({...ef,INDEXER_ACCOUNTS:eu,INDEXER_NAMESPACE:es,INDEXER_BLOCKCHAINS:ei,INDEXER_DATA_PATH:"/data"}).map(et=>{let[ei,es]=et;return{name:ei,value:es}})}async parseIndexers(et){et=await eg.addSchema.parseAsync(et);let{name:ei,tags:es}=et,ef=this.parseEnvVars(et),{code:eu,specs:ed,runtime:em,metadata:eH,isPersistent:ez,volumes:eV}=eg.getStaticProgramConfig();return{code:eu,name:ei,tags:es,specs:ed,runtime:em,envVars:ef,volumes:eV,metadata:eH,isPersistent:ez}}getBlockchainEnvName(et,ei){return(0,eH.D1)("".concat(et,"_").concat(ei)).toUpperCase()}constructor(et,ei){this.account=et,this.programManager=ei}}(()=>{eg.addSchema=eu.Ot})(),(()=>{eg.getCost=et=>{let{specs:ei}=eg.getStaticProgramConfig();return ef.L.getCost({...et,isPersistent:!0,specs:ei})}})()},49875:function(et,ei,es){"use strict";es.d(ei,{u:function(){return eM}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(57492),ez=es(94443),eV=es(22733);class eM extends ez.E{async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:eH.MessageType.instance,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:eH.MessageType.instance,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){try{let ei=await this.parseInstance(et),es=await ef.instance.publish(ei),[eu]=await this.parseMessages([es]);return await this.parseDomains(eu.id,et.domains),eu}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async checkStatus(et){let ei=await fetch("https://scheduler.api.aleph.sh/api/v0/allocation/".concat(et.id));if(404===ei.status)return;let es=await ei.json();return es}async parseInstance(et){et=await eM.addSchema.parseAsync(et);let{account:ei,channel:es}=this,{envVars:ef,specs:eu,image:ed,sshKeys:em,name:eH,tags:ez}=et,eV=this.parseEnvVars(ef),eg=this.parseSpecs(eu),eL=this.parseMetadata(eH,ez),eb=await this.parseSSHKeys(em),ey=await this.parseVolumes(et.volumes);return{account:ei,channel:es,variables:eV,resources:eg,metadata:eL,image:ed,authorized_keys:eb,volumes:ey}}async parseVolumes(et){if(et)return et=(et=Array.isArray(et)?et:[et]).filter(et=>!et.isFake),super.parseVolumes(et)}async parseSSHKeys(et){if(!et||0===et.length)return;let ei=et.filter(et=>et.isNew&&et.isSelected);return await this.sshKeyManager.add(ei,!1),et.filter(et=>et.isSelected).map(et=>{let{key:ei}=et;return ei})}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>{let es=et.content.volumes.reduce((et,es)=>et+("size_mib"in es?es.size_mib:ei[es.ref]),0);return{id:et.item_hash,...et.content,type:ed.py.Instance,url:(0,em.DI)(et),date:(0,em._3)(et.time),size:es,confirmed:!!et.confirmed}})}constructor(et,ei,es,ef,eu,em=ed.Dl){super(et,ei,es),this.account=et,this.volumeManager=ei,this.domainManager=es,this.sshKeyManager=ef,this.fileManager=eu,this.channel=em}}(()=>{eM.addSchema=eV.OC})(),(()=>{eM.getCost=et=>ez.E.getExecutableCost({...et,type:ed.py.Instance})})()},48071:function(et,ei,es){"use strict";var ef,eu;es.d(ei,{D:function(){return eu},Y:function(){return ed}}),function(et){et.Runtime1="bd79839bf96e595a06da5ac0b6ba51dea6f7e2591bb913deccded04d831d29f4",et.Runtime2="bd79839bf96e595a06da5ac0b6ba51dea6f7e2591bb913deccded04d831d29f4 ",et.Runtime3="3c238dd3ffba73ab9b2cccb90a11e40e78aff396152de922a6d794a0a65a305e",et.Custom="custom"}(ef||(ef={})),ef.Runtime1,ef.Runtime1,ef.Runtime2,ef.Runtime2,ef.Runtime3,ef.Runtime3,ef.Custom,ef.Custom,function(et){et.Python="python",et.Node="node",et.Other="other"}(eu||(eu={}));let ed={[eu.Python]:{id:eu.Python,lang:"python",runtime:ef.Runtime1},[eu.Node]:{id:eu.Node,lang:"javascript",runtime:ef.Runtime3},[eu.Other]:{id:eu.Other,lang:"text",runtime:ef.Custom}}},39261:function(et,ei,es){"use strict";es.d(ei,{L:function(){return eL}});var ef=es(67572),eu=es(70714),ed=es(81287),em=es(33358),eH=es(34853),ez=es(57492),eV=es(94443),eM=es(22733),eg=es(48071);class eL extends eV.E{async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:ez.MessageType.program,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:ez.MessageType.program,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){try{let ei=await this.parseProgram(et),es=await ef.program.publish(ei),[eu]=await this.parseMessages([es]);return await this.parseDomains(eu.id,et.domains),eu}catch(et){throw ed.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw ed.Z.RequestFailed(et)}}async download(et){let ei=et.code.ref,es=await this.messageManager.get(ei),ef=es.content.item_hash,eu=await fetch("".concat(em.Sd).concat(ef)),ed=await eu.blob();return(0,eH.lm)(ed,"VM_".concat(et.id.slice(-12),".zip"))}async parseCode(et){if("text"===et.type)return{entrypoint:"main:app",file:new Blob([et.text],{type:"text/plain"}),encoding:eu.Encoding.plain};if("file"===et.type){let ei;if(!et.file)throw Error("Invalid function code file");let es=et.file.name;if(es.endsWith(".zip"))ei=eu.Encoding.zip;else if(es.endsWith(".sqsh"))ei=eu.Encoding.squashfs;else throw Error("Invalid function code file");return{entrypoint:et.entrypoint,file:et.file,encoding:ei}}if("ref"===et.type)return{entrypoint:et.entrypoint,encoding:et.encoding,programRef:et.programRef};throw Error("Invalid function code type")}async parseProgram(et){et=await eL.addSchema.parseAsync(et);let{account:ei,channel:es}=this,{name:ef,tags:eu,isPersistent:ed,envVars:em,specs:eH}=et,ez=this.parseEnvVars(em),{memory:eV,vcpus:eM}=this.parseSpecs(eH),eg=this.parseMetadata(ef,eu,et.metadata),eb=this.parseRuntime(et),ey=await this.parseVolumes(et.volumes),eC=await this.parseCode(et.code);return{account:ei,channel:es,runtime:eb,isPersistent:ed,variables:ez,memory:eV,vcpus:eM,volumes:ey,...eC,metadata:eg}}parseRuntime(et){let{code:ei,runtime:es}=et;if(es)return es;if(ei.lang===eg.D.Other)throw Error("Custom runtime should be added");return eg.Y[ei.lang].runtime}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>{let es=et.content.volumes.reduce((et,es)=>et+("size_mib"in es?es.size_mib:ei[es.ref]),0);return{id:et.item_hash,...et.content,type:em.py.Program,url:(0,eH.DI)(et),urlVM:"".concat(em.gC).concat(et.item_hash),date:(0,eH._3)(et.time),size:es,confirmed:!!et.confirmed}})}constructor(et,ei,es,ef,eu,ed=em.d1){super(et,ei,es),this.account=et,this.volumeManager=ei,this.domainManager=es,this.messageManager=ef,this.fileManager=eu,this.channel=ed}}(()=>{eL.addSchema=eM._G})(),(()=>{eL.getCost=et=>eV.E.getExecutableCost({...et,type:em.py.Program})})()},61941:function(et,ei,es){"use strict";es.d(ei,{X:function(){return ez}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(22733);class ez{async getAll(){try{let et=await ef.post.Get({addresses:[this.account.address],types:[this.type],channels:[this.channel]});return this.parsePosts(et.posts)}catch(et){return[]}}async get(et){let ei=await ef.post.Get({addresses:[this.account.address],types:[this.type],channels:[this.channel],hashes:[et]}),[es]=this.parsePosts(ei.posts);return es}async getByValues(et){let ei=await this.getAll();return et.map(et=>ei.find(ei=>ei.key===et))}async add(et,ei){et=Array.isArray(et)?et:[et],et=await this.parseSSHKeys(et,ei);try{let ei=await Promise.all(et.map(et=>{let{key:ei,label:es}=et;return ef.post.Publish({account:this.account,postType:this.type,channel:this.channel,content:{key:ei,label:es}})}));return this.parseNewPosts(ei)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async parseSSHKeys(et){let ei=!(arguments.length>1)||void 0===arguments[1]||arguments[1];et=await ez.addManySchema.parseAsync(et);let es=await this.getAll(),ef=new Set(es.map(et=>et.key));return ei?et.map(et=>{if(!ef.has(et.key))return et;throw Error("SSH key already exists on your collection: ".concat(et.label||et.key))}):et.filter(et=>!ef.has(et.key))}parsePosts(et){return et.map(et=>this.parsePost(et,et.content))}parseNewPosts(et){return et.map(et=>this.parsePost(et,et.content.content))}parseNewPost(et){return this.parsePost(et,et.content.content)}parsePost(et,ei){return{type:ed.py.SSHKey,id:et.item_hash,...ei,url:(0,em.DI)(et),date:(0,em._3)(et.time),confirmed:!!et.confirmed}}constructor(et,ei=ed.Wt,es=ed.GI){this.account=et,this.type=ei,this.channel=es}}(()=>{ez.addSchema=eH.ve})(),(()=>{ez.addManySchema=eH.K7})()},59925:function(et,ei,es){"use strict";es.d(ei,{l:function(){return eV},z:function(){return ed.lf}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(57492),ez=es(22733);class eV{static getVolumeSize(et){if(et.volumeType===ed.lf.New){var ei;return(0,em.Fx)((null==et?void 0:null===(ei=et.file)||void 0===ei?void 0:ei.size)||0,{from:"B",to:"MiB"})}return et.size||0}static getVolumeMiBPrice(et){return et.volumeType!==ed.lf.New||et.mountPath?20:1/3}static getPerVolumeCost(et){let{volumes:ei=[],sizeDiscount:es=0,exclude:ef=[ed.lf.Existing]}=et;return ei.map(et=>{let ei=ef.includes(et.volumeType),eu=this.getVolumeSize(et)||0,ed=this.getVolumeMiBPrice(et);if(ei)return{size:eu,price:0,discount:0,cost:0};let em=eu;es>0&&(em<=es?(es-=em,em=0):(em-=es,es=0));let eH=eu>0?1-em/eu:0,ez=eu*ed,eV=em*ed;return{size:eu,price:ez,discount:eH,cost:eV}},[])}static getCost(et){var ei;et={...et,volumes:null===(ei=et.volumes)||void 0===ei?void 0:ei.filter(et=>!et.isFake)};let es=this.getPerVolumeCost(et),ef=Math.ceil(Object.values(es).reduce((et,ei)=>et+ei.cost,0));return{perVolumeCost:es,totalCost:ef}}async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:eH.MessageType.store,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:eH.MessageType.store,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){et=Array.isArray(et)?et:[et];let ei=await this.parseNewVolumes(et);if(0===ei.length)return[];try{let{account:et,channel:es}=this,eu=await Promise.all(ei.map(async ei=>{let{file:eu}=ei;return ef.store.Publish({account:et,channel:es,fileObject:eu})}));return await this.parseMessages(eu)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async download(et){et="string"==typeof et?et:et.id;let ei=await fetch("".concat(ed.Sd).concat(et)),es=await ei.blob();return(0,em.lm)(es,"Volume_".concat(et.slice(-12),".sqsh"))}async parseNewVolumes(et){let ei=et.filter(et=>et.volumeType===ed.lf.New&&!!et.file);return et=await eV.addManySchema.parseAsync(ei),ei}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>this.parseMessage(et,et.content,ei))}parseMessage(et,ei,es){return{id:et.item_hash,...ei,type:ed.py.Volume,volumeType:ed.lf.Existing,url:(0,em.DI)(et),date:(0,em._3)(et.time),size:es[et.item_hash],confirmed:!!et.confirmed}}constructor(et,ei,es=ed.yk){this.account=et,this.fileManager=ei,this.channel=es}}(()=>{eV.addSchema=ez.wy})(),(()=>{eV.addManySchema=ez.iq})()},33358:function(et,ei,es){"use strict";var ef,eu,ed,em;es.d(ei,{Dl:function(){return ey},GI:function(){return eb},K_:function(){return eN},MQ:function(){return em},Sd:function(){return ez},T4:function(){return eV},Wt:function(){return eM},_G:function(){return eA},d1:function(){return eC},fM:function(){return ex},gC:function(){return eH},lf:function(){return ed},py:function(){return ef},sT:function(){return eg},sv:function(){return ew},vs:function(){return eu},yk:function(){return eL}});let eH="https://aleph.sh/vm/",ez="https://api2.aleph.im/api/v0/storage/raw/",eV="domains",eM="ALEPH-SSH",eg="ALEPH-CLOUDSOLUTIONS",eL=eg,eb=eg,ey=eg,eC=eg,ex=eg,ew={"/":"SOLUTIONS","/dashboard/function":"SETUP NEW FUNCTION","/dashboard/volume":"SETUP NEW VOLUME"};!function(et){et.Volume="volume",et.Program="program",et.Instance="instance",et.SSHKey="sshKey",et.Domain="domain",et.Indexer="indexer"}(ef||(ef={})),function(et){et.IPFS="ipfs",et.Program="program",et.Instance="instance"}(eu||(eu={})),function(et){et.New="new",et.Existing="existing",et.Persistent="persistent"}(ed||(ed={}));let eN={[ef.Volume]:"Volume",[ef.Program]:"Function",[ef.Instance]:"Instance",[ef.SSHKey]:"SSH Key",[ef.Domain]:"Domain",[ef.Indexer]:"Indexer"};!function(et){et.Ethereum="ethereum",et.Bsc="bsc"}(em||(em={}));let eS="https://api.etherscan.io/api?module=contract&action=getabi&address=0x27702a26126e0B3702af63Ee09aC4d1A084EF628",eA={[em.Ethereum]:eS,[em.Bsc]:eS}},81287:function(et,ei){"use strict";ei.Z={ChainNotYetSupported:Error("Chain is not yet supported"),RequestTimeout:Error("Request timed out"),RequestFailed:et=>Error("Request failed",{cause:et})}},22733:function(et,ei,es){"use strict";es.d(ei,{CJ:function(){return eB},I:function(){return eT},K7:function(){return eP},OC:function(){return e6},Ot:function(){return ci},_G:function(){return e3},iq:function(){return eR},ve:function(){return eE},wy:function(){return eI}});var ef=es(1604),eu=es(33358),ed=es(34853),em=es(70714),eH=es(48071);let ez=ef.z.string().trim().min(1,{message:"Required field"});function eV(et){return et.optional().or(ef.z.literal(""))}let eM=ef.z.string().trim().optional(),eg=ez.regex(/^[0-9a-f]{64}$/,{message:"Invalid hash format"}),eL=ez.regex(/^((?!-))(xn--)?[a-z0-9][a-z0-9-_]{0,61}[a-z0-9]{0,1}\.(xn--)?([a-z0-9\-]{1,61}|[a-z0-9-]{1,30}\.[a-z]{2,})$/,{message:"Invalid domain format"}),eb=ez.regex(/^(?:http(s)?:\/\/)?[\w.-]+(?:\.[\w\.-]+)+[\w\-\._~:/?#[\]@!\$&'\(\)\*\+,;=.]+$/,{message:"Invalid url format"}),ey=ez.regex(/^(\/[^\/ ]*)+\/?$/,{message:"Invalid path format"}),eC=ez.regex(/^0x[a-fA-F0-9]{40}$/,{message:"Invalid address format"}),ex=ez.regex(/^[0-9]+$/,{message:"Invalid supply format"}),ew=ef.z.custom(et=>et instanceof File,"Required file").refine(et=>"application/zip"===et.type&&et.name.endsWith(".zip")||et.name.endsWith(".sqsh")||et.name.endsWith(".squashfs"),{message:"only .zip, .sqsh and .squashfs formats are valid"}).refine(et=>et.size>0,{message:"File size should be greater than 0"}),eN=ef.z.custom(et=>et instanceof File,"Required file").refine(et=>(console.log(et),"application/zip"===et.type&&et.name.endsWith(".zip")||et.name.endsWith(".sqsh")||et.name.endsWith(".squashfs")),{message:"only .zip, .sqsh and .squashfs formats are valid"}).refine(et=>et.size>0,{message:"File size should be greater than 0"}),eS=ef.z.enum([eu.py.Instance,eu.py.Program]),eA=ef.z.enum([eu.MQ.Ethereum,eu.MQ.Bsc]),e_=ef.z.record(ez,ef.z.unknown()),eE=ef.z.object({key:ez,label:eM}),eP=ef.z.array(eE),eB=ef.z.object({name:eL,target:ef.z.enum([eu.vs.IPFS,eu.vs.Program,eu.vs.Instance]),programType:eS,ref:eg}),eT=ef.z.array(eB),eI=ef.z.object({volumeType:ef.z.literal(eu.lf.New),file:ew}),eR=ef.z.array(eI),eO=eI.extend({mountPath:ey,useLatest:ef.z.coerce.boolean(),isFake:ef.z.boolean().optional()}),ej=ef.z.object({volumeType:ef.z.literal(eu.lf.Existing),refHash:eg,mountPath:ey,useLatest:ef.z.coerce.boolean(),isFake:ef.z.boolean().optional()}),eD=ef.z.object({volumeType:ef.z.literal(eu.lf.Persistent),name:ez,mountPath:ey,size:ef.z.number().gt(0),isFake:ef.z.boolean().optional()}),eF=ef.z.discriminatedUnion("volumeType",[eO,ej,eD]),eU=ef.z.array(eF),eq=eB.extend({ref:eM}),eZ=ef.z.array(eq),eG=ef.z.object({name:ez,value:ez}),eW=ef.z.array(eG),eK=ef.z.object({lang:ef.z.enum([eH.D.Python,eH.D.Node,eH.D.Other])}),e$=ef.z.discriminatedUnion("type",[eK.extend({type:ef.z.literal("file"),file:eN,entrypoint:ez}),eK.extend({type:ef.z.literal("text"),text:ez}),eK.extend({type:ef.z.literal("ref"),encoding:ef.z.enum([em.Encoding.squashfs,em.Encoding.zip,em.Encoding.plain]),programRef:eg,entrypoint:ez})]),eJ=ef.z.object({name:ez,tags:ef.z.array(ef.z.string().trim()).optional()}),eY=eE.extend({isSelected:ef.z.boolean(),isNew:ef.z.boolean()}),eX=ef.z.array(eY).refine(et=>et.some(et=>et.isSelected),{message:"At least one ssh key should be add and selected",path:["0.isSelected"]}),eQ=ef.z.coerce.boolean(),e1=eg,e2=ef.z.object({cpu:ef.z.union([ef.z.literal(1),ef.z.literal(2),ef.z.literal(4),ef.z.literal(6),ef.z.literal(8),ef.z.literal(12)]),ram:ef.z.number().gt(0),storage:ef.z.number().gt(0)}).refine(et=>{let{cpu:ei,ram:es}=et;return es===(0,ed.Fx)(2*ei,{from:"GiB",to:"MiB"})},{message:"Invalid specs"}).refine(et=>{let{cpu:ei,storage:es}=et;return es===(0,ed.Fx)(20*ei,{from:"GiB",to:"MiB"})||es===(0,ed.Fx)(2*ei,{from:"GiB",to:"MiB"})},{message:"Invalid specs"}),e4=eV(eg),e3=ef.z.object({code:e$,isPersistent:eQ,specs:e2,runtime:e4.optional(),volumes:eU.optional(),envVars:eW.optional(),domains:eZ.optional(),metadata:e_.optional()}).merge(eJ).refine(et=>{let{code:ei,runtime:es}=et;return!!es||ei.lang!==eH.D.Other},{message:"Invalid function runtime",path:["runtime"]}),e6=ef.z.object({image:e1,specs:e2,sshKeys:eX,volumes:eU.optional(),envVars:eW.optional(),domains:eZ.optional(),metadata:e_.optional()}).merge(eJ),e0=ez.regex(/^[0-9a-z-]+$/,{message:"Network id should be provided in kebab-case-format"}),e8=eb.includes("$ADDRESS",{message:'The url must contain the token "$ADDRESS" that will be replaced in runtime with token contract addresses'}),e5=ef.z.object({id:e0,blockchain:eA,rpcUrl:eb,abiUrl:eV(e8)}),e7=ef.z.array(e5),e9=ef.z.object({network:ez,contract:eC,deployer:eC,supply:ex,decimals:ef.z.number().gte(0)}),cc=ef.z.array(e9),ci=ef.z.object({networks:e7.min(1),accounts:cc.min(1)}).merge(eJ).superRefine(async(et,ei)=>{let{networks:es,accounts:eu}=et;for(let[et,ed]of Object.entries(eu)){let eu;let em=es.findIndex(et=>et.id===ed.network),eH=es[em];if(!eH)return ei.addIssue({fatal:!0,code:ef.z.ZodIssueCode.custom,message:"Invalid network. It should be one of the defined blockchain networks ids",path:["accounts.".concat(et,".network")]}),ef.z.NEVER;if(!ed.contract||!eH.abiUrl||!eH.abiUrl.includes("$ADDRESS"))return ef.z.NEVER;let ez=eH.abiUrl.replace("$ADDRESS",ed.contract),eV=await fetch(ez),eM=await eV.json();try{eu=JSON.parse(null==eM?void 0:eM.result)}catch(et){if(null==eM?void 0:eM.result.includes("rate limit"))return ef.z.NEVER}if(!eu)return ei.addIssue({fatal:!0,code:ef.z.ZodIssueCode.custom,message:"Invalid ABI url. It should return a valid ABI json inside response.body.result field",path:["networks.".concat(em,".abiUrl")]}),ef.z.NEVER}})},48847:function(et,ei,es){"use strict";es.d(ei,{MF:function(){return ef},E3:function(){return ex},I6:function(){return e_}});var ef,eu=es(61941),ed=es(59925),em=es(49875),eH=es(39261),ez=es(33358),eV=es(34853);class eM{async getAll(){let{address:et}=this.account,ei={address:et,total_size:0,files:[]};try{let es=await fetch("https://api2.aleph.im/api/v0/addresses/".concat(et,"/files")),ef=await es.json()||ei;return this.parseSizesMap(ef.files),ef}catch(et){return console.error(et),ei}}async getSizesMap(){let et=await this.mutex.acquire();try{this.lastFetch+6e4(et[ei.item_hash]=(0,eV.Fx)(ei.size,{from:"B",to:"MiB"}),et),{})}constructor(et,ei=ez.sT){this.account=et,this.channel=ei,this.sizesMapCache={},this.lastFetch=0,this.mutex=new eV.WU}}var eg=es(67572),eL=es(81287);class eb{async get(et){try{let ei=await eg.any.GetMessage({hash:et});return ei}catch(et){throw eL.Z.RequestFailed(et)}}async del(et){try{let ei=await eg.forget.Publish({account:this.account,hashes:[et.item_hash],channel:et.channel});return ei}catch(et){throw eL.Z.RequestFailed(et)}}constructor(et,ei=ez.sT){this.account=et,this.channel=ei}}var ey=es(65526),eC=es(21685);!function(et){et[et.connect=0]="connect",et[et.disconnect=1]="disconnect",et[et.setAccountBalance=2]="setAccountBalance",et[et.setAccountFiles=3]="setAccountFiles",et[et.setAccountSSHKeys=4]="setAccountSSHKeys",et[et.addAccountSSHKey=5]="addAccountSSHKey",et[et.delAccountSSHKey=6]="delAccountSSHKey",et[et.setAccountFunctions=7]="setAccountFunctions",et[et.addAccountFunction=8]="addAccountFunction",et[et.delAccountFunction=9]="delAccountFunction",et[et.setAccountVolumes=10]="setAccountVolumes",et[et.addAccountVolume=11]="addAccountVolume",et[et.delAccountVolume=12]="delAccountVolume",et[et.setAccountInstances=13]="setAccountInstances",et[et.addAccountInstance=14]="addAccountInstance",et[et.delAccountInstance=15]="delAccountInstance",et[et.setAccountDomains=16]="setAccountDomains",et[et.addAccountDomain=17]="addAccountDomain",et[et.delAccountDomain=18]="delAccountDomain"}(ef||(ef={}));let ex={account:void 0,accountBalance:void 0,accountInstances:void 0,accountFunctions:void 0,accountVolumes:void 0,accountFiles:void 0,accountSSHKeys:void 0,accountDomains:void 0,fileManager:void 0,messageManager:void 0,sshKeyManager:void 0,domainManager:void 0,volumeManager:void 0,programManager:void 0,instanceManager:void 0,indexerManager:void 0};function ew(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],es=new Map(ei.map(et=>[et.id,et]));for(let ei of et)es.set(ei.id,ei);return Array.from(es.values())}function eN(et,ei){return ew([et],ei)}function eS(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return ei.filter(ei=>ei.id!==et)}function eA(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],es=ei.filter(et=>!et.confirmed);return ew(et,es)}let e_=function(){let et=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ex,{type:ei,payload:es}=arguments.length>1?arguments[1]:void 0;switch(ei){case ef.connect:{let{account:ei}=es,ef=new eM(ei),ez=new eb(ei),eV=new eu.X(ei),eg=new ey.Y(ei),eL=new ed.l(ei,ef),ex=new eH.L(ei,eL,eg,ez,ef),ew=new em.u(ei,eL,eg,eV,ef),eN=new eC.p(ei,ex);return{...et,account:ei,fileManager:ef,messageManager:ez,sshKeyManager:eV,domainManager:eg,volumeManager:eL,programManager:ex,instanceManager:ew,indexerManager:eN}}case ef.disconnect:return{...et,account:void 0,fileManager:void 0,messageManager:void 0,sshKeyManager:void 0,domainManager:void 0,volumeManager:void 0,programManager:void 0,instanceManager:void 0};case ef.setAccountBalance:return{...et,accountBalance:es.balance};case ef.setAccountFiles:return{...et,accountFiles:es.accountFiles};case ef.setAccountSSHKeys:{let ei=eA(es.accountSSHKeys,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.addAccountSSHKey:{let ei=eN(es.accountSSHKey,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.delAccountSSHKey:{let ei=eS(es.id,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.setAccountFunctions:{let ei=eA(es.accountFunctions,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.addAccountFunction:{let ei=eN(es.accountFunction,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.delAccountFunction:{let ei=eS(es.id,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.setAccountVolumes:{let ei=eA(es.accountVolumes,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.addAccountVolume:{let ei=eN(es.accountVolume,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.delAccountVolume:{let ei=eS(es.id,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.setAccountInstances:{let ei=eA(es.accountInstances,et.accountInstances);return{...et,accountInstances:ei}}case ef.addAccountInstance:{let ei=eN(es.accountInstance,et.accountInstances);return{...et,accountInstances:ei}}case ef.delAccountInstance:{let ei=eS(es.id,et.accountInstances);return{...et,accountInstances:ei}}case ef.setAccountDomains:{let ei=eA(es.accountDomains,et.accountDomains);return{...et,accountDomains:ei}}case ef.addAccountDomain:{let ei=eN(es.accountDomain,et.accountDomains);return{...et,accountDomains:ei}}case ef.delAccountDomain:{let ei=eS(es.id,et.accountDomains);return{...et,accountDomains:ei}}default:return et}}},34853:function(et,ei,es){"use strict";es.d(ei,{D1:function(){return ej},DI:function(){return ex},Eb:function(){return ez},Fx:function(){return eL},Py:function(){return eT},RK:function(){return eC},WU:function(){return eR},_3:function(){return ew},bs:function(){return em},eB:function(){return ey},f6:function(){return eV},gE:function(){return eP},lm:function(){return eN},mA:function(){return eO},w2:function(){return eB},zN:function(){return eH}});var ef=es(81287),eu=es(57492),ed=es(33358);let em=function(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,es=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return et.length<=ei||et.length<=es?et:"".concat(et.slice(0,ei),"...").concat(es>0?et.slice(-es):"")},eH=et=>em(et,6,4),ez=async et=>{try{let ei=await fetch("https://api2.aleph.im/api/v0/addresses/".concat(et,"/balance"));if(404===ei.status)return 0;let{balance:es}=await ei.json();return es}catch(et){throw ef.Z.RequestFailed(et)}},eV=async et=>{try{let ei=await fetch("https://balance1.api.aleph.cloud/solana/".concat(et)),{balance:es}=await ei.json();return es}catch(et){throw ef.Z.RequestFailed(et)}},eM={B:1,kB:1e3,MB:1e6,GB:1e9,TB:1e12,KiB:1024,MiB:1048576,GiB:1073741824,TiB:1099511627776},eg={B:"B",kB:"kB",MB:"MB",GB:"GB",TB:"TB",KiB:"kB",MiB:"MB",GiB:"GB",TiB:"TB"};function eL(et,ei){let{from:es="MiB",to:ef="GiB",displayUnit:eu=!1}=ei,ed=et*eM[es]/eM[ef];return eu?"".concat(ed.toFixed(2)," ").concat(eg[ef]):ed}function eb(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["B","KiB","MiB","GiB","TiB"],es="B";for(let ef of ei){if(et1&&void 0!==arguments[1]?arguments[1]:"B";if(void 0===et)return"n/a";if(0===et)return"-";let es=eL(et,{from:ei,to:"B"}),ef=eb(es);return eL(et,{from:ei,to:ef,displayUnit:!0})}let eC=et=>void 0===et?"n/a":0===et?et:et<1e3?et.toFixed(1):et<1e6?(et/1e3).toFixed(1)+"K":et<1e9?(et/1e6).toFixed(1)+"M":(et/1e9).toFixed(1)+"B",ex=et=>{let{item_hash:ei,chain:es,sender:ef,type:eu}=et;return"https://explorer.aleph.im/address/".concat(es,"/").concat(ef,"/message/").concat(eu,"/").concat(ei)},ew=et=>{let[ei,es]=new Date(1e3*et).toISOString().split("T"),[ef]=es.split(".");return"".concat(ei," ").concat(ef)},eN=(et,ei)=>{let es=document.createElement("a");es.href=window.URL.createObjectURL(et),es.download=ei,es.click()},eS=et=>et.type===eu.MessageType.store,eA=et=>et.type===eu.MessageType.program,e_=et=>et.type===eu.MessageType.instance,eE=et=>et.type===eu.MessageType.post;function eP(et){if(eS(et))return ed.py.Volume;if(eA(et))return ed.py.Program;if(e_(et))return ed.py.Instance;if(eE(et))return ed.py.SSHKey;throw Error("Unknown type")}function eB(et){return et.hasOwnProperty("persistence")}function eT(et){return et.hasOwnProperty("ephemeral")}class eI{constructor(){this.promise=new Promise((et,ei)=>{this.resolve=et,this.reject=ei})}}class eR{async acquire(){let et=new eI,ei=this.queue;return this.queue=this.queue.then(()=>et.promise),this.count++,await ei,()=>{this.count--,et.resolve()}}constructor(){this.queue=Promise.resolve(),this.count=0}}function eO(et){return et.trim().toLowerCase().replace(/[^a-z0-9_\\-]/g,"").replace(/_/g,"-")}function ej(et){return eO(et).replace(/-/g,"_")}},6477:function(et,ei,es){"use strict";es.d(ei,{$:function(){return eC}});var ef=es(36470),eu=es(57492),ed=es(24566),em=es(74931),eH=es(34853),ez=es(81287);let eV=(et,ei)=>{switch(et){case eu.Chain.ETH:return(0,ed.GetAccountFromProvider)(ei);case eu.Chain.SOL:return(0,em.GetAccountFromProvider)(ei);default:throw ez.Z.ChainNotYetSupported}},eM=async et=>{switch(et.GetChain()){case eu.Chain.ETH:return(0,eH.Eb)(et.address);case eu.Chain.SOL:return(0,eH.f6)(et.address);default:throw ez.Z.ChainNotYetSupported}};var eg=es(48847),eL=es(3837),eb=es(67294),ey=es(5678);function eC(){let[et,ei]=(0,ef.mr)(),es=(0,eL.lm)(),[ed,em]=(0,ey.Xs)("keepAccountAlive",!1),eH=(0,eb.useCallback)(et=>{es&&es.add({variant:"error",title:"Error",text:et})},[es]),ez=(0,eb.useCallback)(async et=>{let es=await eM(et);ei({type:eg.MF.setAccountBalance,payload:{balance:es}})},[ei]),eC=(0,eb.useCallback)(async()=>{let et;try{et=await eV(eu.Chain.ETH,null==window?void 0:window.ethereum)}catch(et){eH("You need an Ethereum wallet to use Aleph.im.")}if(et)return em(!0),await Promise.all([ez(et)]).catch(et=>{eH(et.message)}),ei({type:eg.MF.connect,payload:{account:et}}),et},[em,ez,ei,eH]),ex=(0,eb.useCallback)(async()=>{em(!1),ei({type:eg.MF.disconnect,payload:null})},[ei,em]),{account:ew}=et,eN=!!(null==ew?void 0:ew.address),eS=(0,eb.useCallback)(async()=>{!eN&&ed&&await eC()},[eN,ed,eC]);return{connect:eC,disconnect:ex,isConnected:eN,account:ew,tryReconnect:eS}}},32523:function(et,ei,es){"use strict";es.d(ei,{FH:function(){return ez},Fk:function(){return eH}});var ef=es(34853),eu=es(67294),ed=es(87536);function em(et,ei){return{...et,storage:(0,ef.Fx)(2*et.cpu*(ei?10:1),{from:"GiB",to:"MiB"})}}function eH(et){return[1,2,4,6,8,12].map(ei=>em({cpu:ei,ram:(0,ef.Fx)(2*ei,{from:"GiB",to:"MiB"}),storage:0},et))}function ez(et){let{name:ei="specs",control:es,defaultValue:ef,type:ez,options:eV,isPersistent:eM=!1}=et,eg=eV||eH(eM),eL=(0,ed.bc)({control:es,name:ei,defaultValue:ef}),{value:eb,onChange:ey}=eL.field;return(0,eu.useEffect)(()=>{if(!eb)return;let et=em(eb,eM);et.storage!==eb.storage&&ey(et)},[eM,eb,ey]),{specsCtrl:eL,options:eg,type:ez,isPersistent:eM}}},27234:function(et,ei,es){"use strict";es.r(ei),es.d(ei,{default:function(){return cd}});var ef=es(85893);es(69416);var eu=es(23636);es(53119);var ed=es(19521),em=es(3837),eH=es(67294),ez=es(87531);let eV=ed.ZP.footer.withConfig({displayName:"styles__StyledFooter",componentId:"sc-1l7mq5x-0"})([""," background-color:#00000033;box-sizing:border-box;width:100%;"],{paddingTop:"3rem",paddingBottom:"3rem","@media (min-width: 768px)":{paddingTop:"3rem",paddingBottom:"3rem"}}),eM=(0,ed.ZP)(em.zx).attrs(et=>({...et,kind:"neon",variant:"tertiary",color:"main0",size:"big"})).withConfig({displayName:"styles__StyledButton",componentId:"sc-1l7mq5x-1"})(()=>[{marginBottom:"1.5rem !important",display:"block !important",":last-child":{marginBottom:"0px !important"}}]),eg=ed.ZP.a.attrs(et=>({...(0,em.PT)("tp-nav")(et),href:et.href||"#"})).withConfig({displayName:"styles__StyledLink",componentId:"sc-1l7mq5x-2"})(["",""],et=>{let{theme:ei}=et;return(0,ed.iv)(["display:block;cursor:pointer;font-weight:700;white-space:nowrap;color:",";text-decoration:none;&:last-child{margin-bottom:0;}"],ei.color.text)}),eL=(0,ed.ZP)(em.JO).attrs(et=>({...et,size:"lg"})).withConfig({displayName:"styles__StyledIcon",componentId:"sc-1l7mq5x-3"})(()=>[{marginRight:"0.625rem"}]),eb=(0,ed.ZP)(em.JO).attrs(et=>({...et,size:"lg"})).withConfig({displayName:"styles__StyledIcon2",componentId:"sc-1l7mq5x-4"})(()=>[{marginLeft:"0.625rem"}]),ey=et=>{let{small:ei=!1}=et;return(0,ef.jsx)(eV,{children:(0,ef.jsx)(ez.Z,{children:ei?(0,ef.jsxs)(em.X2,{xs:1,md:2,lg:3,xsGap:"3rem",lgGap:"0",children:[(0,ef.jsx)(em.JX,{xs:1,md:2,lg:1,children:(0,ef.jsx)(ex,{children:(0,ef.jsx)(em.TR,{size:28})})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)(ew,{children:[(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://docs.aleph.im",children:["Documentation",(0,ef.jsx)(eb,{name:"external-link-square-alt"})]})}),(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://t.me/alephim",children:["Telegram Developers",(0,ef.jsx)(eb,{name:"external-link-square-alt"})]})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)(eN,{children:[(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://twitter.com/aleph_im",children:[(0,ef.jsx)(eL,{name:"twitter"}),"Twitter"]})}),(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://medium.com/aleph-im",children:[(0,ef.jsx)(eL,{name:"medium"}),"Medium"]})})]})})]}):(0,ef.jsxs)(ef.Fragment,{children:[(0,ef.jsx)(eS,{children:(0,ef.jsx)(em.TR,{size:55})}),(0,ef.jsx)(eA,{children:(0,ef.jsxs)(em.X2,{xs:1,md:2,lg:4,xsGap:"3rem",mdGap:"1.5rem",children:[(0,ef.jsxs)(em.JX,{children:[(0,ef.jsx)(eM,{children:"Work with us"}),(0,ef.jsx)(eM,{children:"Try our dApps"}),(0,ef.jsx)(eM,{children:"Start a project"})]}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(e_,{children:(0,ef.jsx)(eg,{children:"Solutions"})}),(0,ef.jsx)(eE,{children:(0,ef.jsx)(eg,{children:"Roadmap"})}),(0,ef.jsx)(eP,{children:(0,ef.jsx)(eg,{children:"Indexing"})}),(0,ef.jsx)(eB,{children:(0,ef.jsx)(eg,{children:"Demo's"})}),(0,ef.jsx)(eT,{children:(0,ef.jsx)(eg,{children:"Team"})}),(0,ef.jsx)(eI,{children:(0,ef.jsx)(eg,{children:"Developers"})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(eR,{children:(0,ef.jsx)(eg,{children:"Jobs"})}),(0,ef.jsx)(eO,{children:(0,ef.jsx)(eg,{children:"Whitepaper"})}),(0,ef.jsx)(ej,{children:(0,ef.jsx)(eg,{children:"Token"})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(eD,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://twitter.com/aleph_im",children:[(0,ef.jsx)(eL,{name:"twitter"}),"Twitter"]})}),(0,ef.jsx)(eF,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://t.me/alephim",children:[(0,ef.jsx)(eL,{name:"telegram"}),"Telegram"]})}),(0,ef.jsx)(eU,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://medium.com/aleph-im",children:[(0,ef.jsx)(eL,{name:"medium"}),"Medium"]})})]})})]})})]})})})};var eC=ey,ex=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv",componentId:"sc-1m9qt74-0"})({display:"flex",alignItems:"center","@media (min-width: 1024px)":{justifyContent:"flex-start"}}),ew=(0,ed.ZP)("ul").withConfig({displayName:"cmp___StyledUl",componentId:"sc-1m9qt74-1"})({display:"flex",flexDirection:"column",gap:"1.5rem","@media (min-width: 768px)":{flexDirection:"row",alignItems:"center"},"@media (min-width: 1024px)":{justifyContent:"center"}}),eN=(0,ed.ZP)("ul").withConfig({displayName:"cmp___StyledUl2",componentId:"sc-1m9qt74-2"})({display:"flex",alignItems:"center",gap:"1.5rem","@media (min-width: 768px)":{justifyContent:"flex-end"}}),eS=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv2",componentId:"sc-1m9qt74-3"})({marginBottom:"3rem"}),eA=(0,ed.ZP)("nav").withConfig({displayName:"cmp___StyledNav",componentId:"sc-1m9qt74-4"})({margin:"0px"}),e_=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi",componentId:"sc-1m9qt74-5"})({marginBottom:"1.5rem"}),eE=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi2",componentId:"sc-1m9qt74-6"})({marginBottom:"1.5rem"}),eP=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi3",componentId:"sc-1m9qt74-7"})({marginBottom:"1.5rem"}),eB=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi4",componentId:"sc-1m9qt74-8"})({marginBottom:"1.5rem"}),eT=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi5",componentId:"sc-1m9qt74-9"})({marginBottom:"1.5rem"}),eI=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi6",componentId:"sc-1m9qt74-10"})({marginBottom:"0px"}),eR=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi7",componentId:"sc-1m9qt74-11"})({marginBottom:"1.5rem"}),eO=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi8",componentId:"sc-1m9qt74-12"})({marginBottom:"1.5rem"}),ej=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi9",componentId:"sc-1m9qt74-13"})({marginBottom:"0px"}),eD=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi10",componentId:"sc-1m9qt74-14"})({marginBottom:"1.5rem"}),eF=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi11",componentId:"sc-1m9qt74-15"})({marginBottom:"1.5rem"}),eU=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi12",componentId:"sc-1m9qt74-16"})({marginBottom:"0px"});let eq=(0,ed.vJ)([" body,#__next{display:flex;flex-direction:column;min-height:100vh;}.unavailable-content{opacity:0.3;filter:grayscale(1);pointer-events:none;}textarea{width:100%;background:linear-gradient(to bottom,#FFFFFF33,transparent);border-radius:5px;padding:5px;border:1px solid #FFFFFF33;color:inherit;}table{max-width:100%;overflow:auto;}"]);var eZ=es(41664),eG=es.n(eZ);let eW=ed.ZP.header.withConfig({displayName:"styles__StyledHeader",componentId:"sc-1uc7qj0-0"})(["font-size:inherit;line-height:inherit;box-sizing:border-box;width:100%;margin:0;position:sticky;top:0;z-index:10;"]),eK=(0,ed.ZP)(em.wp).withConfig({displayName:"styles__StyledNavbar",componentId:"sc-1uc7qj0-1"})(["position:relative;"]),e$=(0,ed.ZP)(em.zx).attrs(et=>({...et,color:"main0",kind:"neon",size:"regular",variant:"tertiary"})).withConfig({displayName:"styles__StyledButton",componentId:"sc-1uc7qj0-2"})(["display:block;&:last-child{margin-bottom:0;}"]);var eJ=es(34853),eY=es(11163),eX=es(36470),eQ=es(6477),e1=es(5678);function e2(){let{connect:et,disconnect:ei,isConnected:es,account:ef}=(0,eQ.$)(),eu=(0,ed.Fg)(),[em]=(0,eX.mr)(),ez=(0,eY.useRouter)(),[eV,eM]=(0,e1.Xs)("keepAccountAlive",!1);(0,eH.useEffect)(()=>{(async()=>{!ef&&eV&&ey()})()},[ef,eV]);let eg=et=>ez.pathname===et,{accountBalance:eL}=em,eb=(0,eH.useCallback)(async()=>{if(es)eM(!1),await ei(),ez.push("/");else{eM(!0);let ei=await et();if(!ei)return;ez.push("/dashboard")}ex(!1)},[et,ei,es,ez]),ey=(0,eH.useCallback)(async()=>{if(es)await ei();else{let ei=await et();if(!ei)return}},[et,ei,es,ef]),[eC,ex]=(0,eH.useState)(!1);return{theme:eu,handleConnect:eb,account:ef,isOnPath:eg,displayWalletPicker:eC,setDisplayWalletPicker:ex,accountBalance:eL}}let e4=()=>{let{theme:et,handleConnect:ei,account:es,isOnPath:eu,displayWalletPicker:ed,setDisplayWalletPicker:ez,accountBalance:eV}=e2(),{connect:eM}=(0,eQ.$)(),eg=(0,eH.useRef)(null);(0,em.O8)(()=>{ed&&ez(!1)},[eg]);let eL=()=>{ez(!ed)},eb=()=>{var et;return null===(et=window.ethereum)||void 0===et||et.on("accountsChanged",function(){eM()}),window.ethereum};(0,eH.useEffect)(()=>(eb(),()=>{var et;null===(et=window.ethereum)||void 0===et||et.removeListener("accountsChanged",()=>{eM()})}),[]);let[ey,eC]=(0,eH.useState)(!1),ex=(0,eH.useCallback)(et=>{eC(et)},[]),ew=(0,eH.useCallback)(()=>{eC(!1)},[eC]);return(0,ef.jsx)(eW,{children:(0,ef.jsxs)(eK,{open:ey,onToggle:ex,logo:(0,ef.jsx)(eG(),{href:"/",children:(0,ef.jsx)(em.TR,{})}),mobileTopContent:es?(0,ef.jsx)(em.zx,{variant:"secondary",color:"main1",kind:"neon",size:"regular",children:(0,ef.jsx)(em.JO,{name:"meteor",size:"md",color:et.color.main1})}):(0,ef.jsx)(e$,{onClick:ei,children:(0,ef.jsx)(em.JO,{name:"meteor",size:"md",color:et.color.main0})}),children:[(0,ef.jsxs)(em.o8,{withSlash:!0,onClick:ew,children:[(0,ef.jsx)(em.iV,{isActive:eu("/"),children:(0,ef.jsx)(eG(),{href:"/",children:"Solutions"},"solutions")}),(0,ef.jsx)(em.iV,{isActive:eu("/dashboard"),children:(0,ef.jsx)(eG(),{href:"/dashboard",children:"Dashboard"},"dashboard")})]}),(0,ef.jsxs)(em.o8,{onlyDesktop:!0,children:[(0,ef.jsx)(em.iV,{children:(0,ef.jsx)(e$,{forwardedAs:"button",disabled:!0,children:(0,ef.jsx)(em.JO,{name:"ethereum"})},"link")}),(0,ef.jsx)(e6,{children:(0,ef.jsxs)(em.iV,{children:[es?(0,ef.jsxs)(em.zx,{as:"button",variant:"secondary",color:"main1",kind:"neon",size:"regular",onClick:eL,children:[(0,eJ.zN)(es.address)," ",(0,ef.jsx)(e0,{name:"meteor",size:"lg",color:et.color.main1})]}):(0,ef.jsxs)(em.zx,{as:"button",variant:"tertiary",color:"main0",kind:"neon",size:"regular",onClick:eL,children:["Connect"," ",(0,ef.jsx)(e8,{name:"meteor",size:"lg",color:et.color.main0})]}),(0,ef.jsx)(e5,{ref:eg,children:ed&&(0,ef.jsx)(em.nd,{networks:[{icon:"ethereum",name:"Ethereum",wallets:[{color:"orange",icon:"circle",name:"Metamask",provider:eb}]}],onConnect:ei,onDisconnect:ei,address:null==es?void 0:es.address,addressHref:"https://etherscan.io/address/".concat(null==es?void 0:es.address),balance:eV,size:"regular"})})]})})]})]})})};var e3=e4,e6=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv",componentId:"sc-m0h8p1-0"})({position:"relative"}),e0=(0,ed.ZP)(em.JO).withConfig({displayName:"cmp___StyledIcon",componentId:"sc-m0h8p1-1"})({marginLeft:"0.625rem"}),e8=(0,ed.ZP)(em.JO).withConfig({displayName:"cmp___StyledIcon2",componentId:"sc-m0h8p1-2"})({marginLeft:"0.625rem"}),e5=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv2",componentId:"sc-m0h8p1-3"})({position:"absolute",right:"0px",marginTop:"2.5rem"});function e7(et){let{children:ei}=et,[es,eu]=(0,eH.useState)(!0);return(0,eH.useEffect)(()=>eu(!1),[]),es?(0,ef.jsx)(ef.Fragment,{children:ei}):(0,ef.jsx)(em.P_,{max:10,timeout:2e3,children:ei})}var e9=es(36001),cc=es(33358);let ci=ed.ZP.main.withConfig({displayName:"styles__StyledMain",componentId:"sc-4lx0v5-0"})(["",""],{display:"flex",flex:"1 1 0%",flexDirection:"column"}),cs=et=>{let{children:ei}=et;return(0,ef.jsx)(ci,{children:ei})};var cf=cs;function cd(et){let{Component:ei,pageProps:es}=et,eu=(0,eY.useRouter)(),eH="/dashboard/manage"!==eu.pathname;return(0,ef.jsxs)(ed.f6,{theme:em.np.dark,children:[(0,ef.jsx)(em.nz,{}),(0,ef.jsx)(eq,{}),(0,ef.jsx)(eX.WE,{children:(0,ef.jsxs)(e7,{children:[(0,ef.jsx)(e3,{}),(0,ef.jsxs)(cf,{children:[eH&&(0,ef.jsx)(e9.Z,{names:cc.sv}),(0,ef.jsx)(ei,{...es})]}),(0,ef.jsx)(eC,{small:!0})]})})]})}eu.vc.autoAddCss=!1},81516:function(et,ei){"use strict";function es(et,ei,es,ef){return!1}Object.defineProperty(ei,"__esModule",{value:!0}),ei.getDomainLocale=es,("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},95569:function(et,ei,es){"use strict";Object.defineProperty(ei,"__esModule",{value:!0}),ei.default=void 0;var ef=es(92648).Z,eu=es(17273).Z,ed=ef(es(67294)),em=es(14532),eH=es(83353),ez=es(61410),eV=es(79064),eM=es(370),eg=es(69955),eL=es(24224),eb=es(80508),ey=es(81516),eC=es(64266);let ex=new Set;function ew(et,ei,es,ef,eu){if(eu||eH.isLocalURL(ei)){if(!ef.bypassPrefetchedCheck){let eu=void 0!==ef.locale?ef.locale:"locale"in et?et.locale:void 0,ed=ei+"%"+es+"%"+eu;if(ex.has(ed))return;ex.add(ed)}Promise.resolve(et.prefetch(ei,es,ef)).catch(et=>{})}}function eN(et){let ei=et.currentTarget,es=ei.getAttribute("target");return es&&"_self"!==es||et.metaKey||et.ctrlKey||et.shiftKey||et.altKey||et.nativeEvent&&2===et.nativeEvent.which}function eS(et,ei,es,ef,eu,em,ez,eV,eM,eg){let{nodeName:eL}=et.currentTarget,eb="A"===eL.toUpperCase();if(eb&&(eN(et)||!eM&&!eH.isLocalURL(es)))return;et.preventDefault();let ey=()=>{"beforePopState"in ei?ei[eu?"replace":"push"](es,ef,{shallow:em,locale:eV,scroll:ez}):ei[eu?"replace":"push"](ef||es,{forceOptimisticNavigation:!eg})};eM?ed.default.startTransition(ey):ey()}function eA(et){return"string"==typeof et?et:ez.formatUrl(et)}let e_=ed.default.forwardRef(function(et,ei){let es,ef;let{href:eH,as:ez,children:ex,prefetch:eN,passHref:e_,replace:eE,shallow:eP,scroll:eB,locale:eT,onClick:eI,onMouseEnter:eR,onTouchStart:eO,legacyBehavior:ej=!1}=et,eD=eu(et,["href","as","children","prefetch","passHref","replace","shallow","scroll","locale","onClick","onMouseEnter","onTouchStart","legacyBehavior"]);es=ex,ej&&("string"==typeof es||"number"==typeof es)&&(es=ed.default.createElement("a",null,es));let eF=!1!==eN,eU=ed.default.useContext(eg.RouterContext),eq=ed.default.useContext(eL.AppRouterContext),eZ=null!=eU?eU:eq,eG=!eU,{href:eW,as:eK}=ed.default.useMemo(()=>{if(!eU){let et=eA(eH);return{href:et,as:ez?eA(ez):et}}let[et,ei]=em.resolveHref(eU,eH,!0);return{href:et,as:ez?em.resolveHref(eU,ez):ei||et}},[eU,eH,ez]),e$=ed.default.useRef(eW),eJ=ed.default.useRef(eK);ej&&(ef=ed.default.Children.only(es));let eY=ej?ef&&"object"==typeof ef&&ef.ref:ei,[eX,eQ,e1]=eb.useIntersection({rootMargin:"200px"}),e2=ed.default.useCallback(et=>{(eJ.current!==eK||e$.current!==eW)&&(e1(),eJ.current=eK,e$.current=eW),eX(et),eY&&("function"==typeof eY?eY(et):"object"==typeof eY&&(eY.current=et))},[eK,eY,eW,e1,eX]);ed.default.useEffect(()=>{eZ&&eQ&&eF&&ew(eZ,eW,eK,{locale:eT},eG)},[eK,eW,eQ,eT,eF,null==eU?void 0:eU.locale,eZ,eG]);let e4={ref:e2,onClick(et){ej||"function"!=typeof eI||eI(et),ej&&ef.props&&"function"==typeof ef.props.onClick&&ef.props.onClick(et),eZ&&!et.defaultPrevented&&eS(et,eZ,eW,eK,eE,eP,eB,eT,eG,eF)},onMouseEnter(et){ej||"function"!=typeof eR||eR(et),ej&&ef.props&&"function"==typeof ef.props.onMouseEnter&&ef.props.onMouseEnter(et),eZ&&(eF||!eG)&&ew(eZ,eW,eK,{locale:eT,priority:!0,bypassPrefetchedCheck:!0},eG)},onTouchStart(et){ej||"function"!=typeof eO||eO(et),ej&&ef.props&&"function"==typeof ef.props.onTouchStart&&ef.props.onTouchStart(et),eZ&&(eF||!eG)&&ew(eZ,eW,eK,{locale:eT,priority:!0,bypassPrefetchedCheck:!0},eG)}};if(eV.isAbsoluteUrl(eK))e4.href=eK;else if(!ej||e_||"a"===ef.type&&!("href"in ef.props)){let et=void 0!==eT?eT:null==eU?void 0:eU.locale,ei=(null==eU?void 0:eU.isLocaleDomain)&&ey.getDomainLocale(eK,et,null==eU?void 0:eU.locales,null==eU?void 0:eU.domainLocales);e4.href=ei||eC.addBasePath(eM.addLocale(eK,et,null==eU?void 0:eU.defaultLocale))}return ej?ed.default.cloneElement(ef,e4):ed.default.createElement("a",Object.assign({},eD,e4),es)});var eE=e_;ei.default=eE,("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},80508:function(et,ei,es){"use strict";Object.defineProperty(ei,"__esModule",{value:!0}),ei.useIntersection=eM;var ef=es(67294),eu=es(10029);let ed="function"==typeof IntersectionObserver,em=new Map,eH=[];function ez(et){let ei;let es={root:et.root||null,margin:et.rootMargin||""},ef=eH.find(et=>et.root===es.root&&et.margin===es.margin);if(ef&&(ei=em.get(ef)))return ei;let eu=new Map,ed=new IntersectionObserver(et=>{et.forEach(et=>{let ei=eu.get(et.target),es=et.isIntersecting||et.intersectionRatio>0;ei&&es&&ei(es)})},et);return ei={id:es,observer:ed,elements:eu},eH.push(es),em.set(es,ei),ei}function eV(et,ei,es){let{id:ef,observer:eu,elements:ed}=ez(es);return ed.set(et,ei),eu.observe(et),function(){if(ed.delete(et),eu.unobserve(et),0===ed.size){eu.disconnect(),em.delete(ef);let et=eH.findIndex(et=>et.root===ef.root&&et.margin===ef.margin);et>-1&&eH.splice(et,1)}}}function eM(et){let{rootRef:ei,rootMargin:es,disabled:em}=et,eH=em||!ed,[ez,eM]=ef.useState(!1),eg=ef.useRef(null),eL=ef.useCallback(et=>{eg.current=et},[]);ef.useEffect(()=>{if(ed){if(eH||ez)return;let et=eg.current;if(et&&et.tagName){let ef=eV(et,et=>et&&eM(et),{root:null==ei?void 0:ei.current,rootMargin:es});return ef}}else if(!ez){let et=eu.requestIdleCallback(()=>eM(!0));return()=>eu.cancelIdleCallback(et)}},[eH,es,ei,ez,eg.current]);let eb=ef.useCallback(()=>{eM(!1)},[]);return[eL,ez,eb]}("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},42474:function(et,ei,es){var ef="/",eu=es(48764).Buffer,ed=es(83454);!function(){var ei={7160:function(et,ei,es){var ef=ei;ef.bignum=es(711),ef.define=es(495).define,ef.base=es(853),ef.constants=es(7335),ef.decoders=es(6701),ef.encoders=es(3418)},495:function(et,ei,es){var ef=es(7160),eu=es(3782);function ed(et,ei){this.name=et,this.body=ei,this.decoders={},this.encoders={}}ei.define=function(et,ei){return new ed(et,ei)},ed.prototype._createNamed=function(et){var ei;try{ei=es(6144).runInThisContext("(function "+this.name+"(entity) {\n this._initNamed(entity);\n})")}catch(et){ei=function(et){this._initNamed(et)}}return eu(ei,et),ei.prototype._initNamed=function(ei){et.call(this,ei)},new ei(this)},ed.prototype._getDecoder=function(et){return et=et||"der",this.decoders.hasOwnProperty(et)||(this.decoders[et]=this._createNamed(ef.decoders[et])),this.decoders[et]},ed.prototype.decode=function(et,ei,es){return this._getDecoder(ei).decode(et,es)},ed.prototype._getEncoder=function(et){return et=et||"der",this.encoders.hasOwnProperty(et)||(this.encoders[et]=this._createNamed(ef.encoders[et])),this.encoders[et]},ed.prototype.encode=function(et,ei,es){return this._getEncoder(ei).encode(et,es)}},6483:function(et,ei,es){var ef=es(3782),eu=es(853).Reporter,ed=es(4300).Buffer;function em(et,ei){if(eu.call(this,ei),!ed.isBuffer(et)){this.error("Input not Buffer");return}this.base=et,this.offset=0,this.length=et.length}function eH(et,ei){if(Array.isArray(et))this.length=0,this.value=et.map(function(et){return et instanceof eH||(et=new eH(et,ei)),this.length+=et.length,et},this);else if("number"==typeof et){if(!(0<=et&&et<=255))return ei.error("non-byte EncoderBuffer value");this.value=et,this.length=1}else if("string"==typeof et)this.value=et,this.length=ed.byteLength(et);else{if(!ed.isBuffer(et))return ei.error("Unsupported type: "+typeof et);this.value=et,this.length=et.length}}ef(em,eu),ei.C=em,em.prototype.save=function(){return{offset:this.offset,reporter:eu.prototype.save.call(this)}},em.prototype.restore=function(et){var ei=new em(this.base);return ei.offset=et.offset,ei.length=this.offset,this.offset=et.offset,eu.prototype.restore.call(this,et.reporter),ei},em.prototype.isEmpty=function(){return this.offset===this.length},em.prototype.readUInt8=function(et){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(et||"DecoderBuffer overrun")},em.prototype.skip=function(et,ei){if(!(this.offset+et<=this.length))return this.error(ei||"DecoderBuffer overrun");var es=new em(this.base);return es._reporterState=this._reporterState,es.offset=this.offset,es.length=this.offset+et,this.offset+=et,es},em.prototype.raw=function(et){return this.base.slice(et?et.offset:this.offset,this.length)},ei.R=eH,eH.prototype.join=function(et,ei){return et||(et=new ed(this.length)),ei||(ei=0),0===this.length||(Array.isArray(this.value)?this.value.forEach(function(es){es.join(et,ei),ei+=es.length}):("number"==typeof this.value?et[ei]=this.value:"string"==typeof this.value?et.write(this.value,ei):ed.isBuffer(this.value)&&this.value.copy(et,ei),ei+=this.length)),et}},853:function(et,ei,es){var ef=ei;ef.Reporter=es(1293).b,ef.DecoderBuffer=es(6483).C,ef.EncoderBuffer=es(6483).R,ef.Node=es(9374)},9374:function(et,ei,es){var ef=es(853).Reporter,eu=es(853).EncoderBuffer,ed=es(853).DecoderBuffer,em=es(3523),eH=["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"],ez=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(eH),eV=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function eM(et,ei){var es={};this._baseState=es,es.enc=et,es.parent=ei||null,es.children=null,es.tag=null,es.args=null,es.reverseArgs=null,es.choice=null,es.optional=!1,es.any=!1,es.obj=!1,es.use=null,es.useDecoder=null,es.key=null,es.default=null,es.explicit=null,es.implicit=null,es.contains=null,es.parent||(es.children=[],this._wrap())}et.exports=eM;var eg=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];eM.prototype.clone=function(){var et=this._baseState,ei={};eg.forEach(function(es){ei[es]=et[es]});var es=new this.constructor(ei.parent);return es._baseState=ei,es},eM.prototype._wrap=function(){var et=this._baseState;ez.forEach(function(ei){this[ei]=function(){var es=new this.constructor(this);return et.children.push(es),es[ei].apply(es,arguments)}},this)},eM.prototype._init=function(et){var ei=this._baseState;em(null===ei.parent),et.call(this),ei.children=ei.children.filter(function(et){return et._baseState.parent===this},this),em.equal(ei.children.length,1,"Root node can have only one child")},eM.prototype._useArgs=function(et){var ei=this._baseState,es=et.filter(function(et){return et instanceof this.constructor},this);et=et.filter(function(et){return!(et instanceof this.constructor)},this),0!==es.length&&(em(null===ei.children),ei.children=es,es.forEach(function(et){et._baseState.parent=this},this)),0!==et.length&&(em(null===ei.args),ei.args=et,ei.reverseArgs=et.map(function(et){if("object"!=typeof et||et.constructor!==Object)return et;var ei={};return Object.keys(et).forEach(function(es){es==(0|es)&&(es|=0),ei[et[es]]=es}),ei}))},eV.forEach(function(et){eM.prototype[et]=function(){throw Error(et+" not implemented for encoding: "+this._baseState.enc)}}),eH.forEach(function(et){eM.prototype[et]=function(){var ei=this._baseState,es=Array.prototype.slice.call(arguments);return em(null===ei.tag),ei.tag=et,this._useArgs(es),this}}),eM.prototype.use=function(et){em(et);var ei=this._baseState;return em(null===ei.use),ei.use=et,this},eM.prototype.optional=function(){return this._baseState.optional=!0,this},eM.prototype.def=function(et){var ei=this._baseState;return em(null===ei.default),ei.default=et,ei.optional=!0,this},eM.prototype.explicit=function(et){var ei=this._baseState;return em(null===ei.explicit&&null===ei.implicit),ei.explicit=et,this},eM.prototype.implicit=function(et){var ei=this._baseState;return em(null===ei.explicit&&null===ei.implicit),ei.implicit=et,this},eM.prototype.obj=function(){var et=this._baseState,ei=Array.prototype.slice.call(arguments);return et.obj=!0,0!==ei.length&&this._useArgs(ei),this},eM.prototype.key=function(et){var ei=this._baseState;return em(null===ei.key),ei.key=et,this},eM.prototype.any=function(){return this._baseState.any=!0,this},eM.prototype.choice=function(et){var ei=this._baseState;return em(null===ei.choice),ei.choice=et,this._useArgs(Object.keys(et).map(function(ei){return et[ei]})),this},eM.prototype.contains=function(et){var ei=this._baseState;return em(null===ei.use),ei.contains=et,this},eM.prototype._decode=function(et,ei){var es,ef=this._baseState;if(null===ef.parent)return et.wrapResult(ef.children[0]._decode(et,ei));var eu=ef.default,em=!0,eH=null;if(null!==ef.key&&(eH=et.enterKey(ef.key)),ef.optional){var ez=null;if(null!==ef.explicit?ez=ef.explicit:null!==ef.implicit?ez=ef.implicit:null!==ef.tag&&(ez=ef.tag),null!==ez||ef.any){if(em=this._peekTag(et,ez,ef.any),et.isError(em))return em}else{var eV=et.save();try{null===ef.choice?this._decodeGeneric(ef.tag,et,ei):this._decodeChoice(et,ei),em=!0}catch(et){em=!1}et.restore(eV)}}if(ef.obj&&em&&(es=et.enterObject()),em){if(null!==ef.explicit){var eM=this._decodeTag(et,ef.explicit);if(et.isError(eM))return eM;et=eM}var eg=et.offset;if(null===ef.use&&null===ef.choice){if(ef.any)var eV=et.save();var eL=this._decodeTag(et,null!==ef.implicit?ef.implicit:ef.tag,ef.any);if(et.isError(eL))return eL;ef.any?eu=et.raw(eV):et=eL}if(ei&&ei.track&&null!==ef.tag&&ei.track(et.path(),eg,et.length,"tagged"),ei&&ei.track&&null!==ef.tag&&ei.track(et.path(),et.offset,et.length,"content"),ef.any||(eu=null===ef.choice?this._decodeGeneric(ef.tag,et,ei):this._decodeChoice(et,ei)),et.isError(eu))return eu;if(ef.any||null!==ef.choice||null===ef.children||ef.children.forEach(function(es){es._decode(et,ei)}),ef.contains&&("octstr"===ef.tag||"bitstr"===ef.tag)){var eb=new ed(eu);eu=this._getUse(ef.contains,et._reporterState.obj)._decode(eb,ei)}}return ef.obj&&em&&(eu=et.leaveObject(es)),null!==ef.key&&(null!==eu||!0===em)?et.leaveKey(eH,ef.key,eu):null!==eH&&et.exitKey(eH),eu},eM.prototype._decodeGeneric=function(et,ei,es){var ef=this._baseState;if("seq"===et||"set"===et)return null;if("seqof"===et||"setof"===et)return this._decodeList(ei,et,ef.args[0],es);if(/str$/.test(et))return this._decodeStr(ei,et,es);if("objid"===et&&ef.args)return this._decodeObjid(ei,ef.args[0],ef.args[1],es);if("objid"===et)return this._decodeObjid(ei,null,null,es);if("gentime"===et||"utctime"===et)return this._decodeTime(ei,et,es);if("null_"===et)return this._decodeNull(ei,es);if("bool"===et)return this._decodeBool(ei,es);else if("objDesc"===et)return this._decodeStr(ei,et,es);else if("int"===et||"enum"===et)return this._decodeInt(ei,ef.args&&ef.args[0],es);return null!==ef.use?this._getUse(ef.use,ei._reporterState.obj)._decode(ei,es):ei.error("unknown tag: "+et)},eM.prototype._getUse=function(et,ei){var es=this._baseState;return es.useDecoder=this._use(et,ei),em(null===es.useDecoder._baseState.parent),es.useDecoder=es.useDecoder._baseState.children[0],es.implicit!==es.useDecoder._baseState.implicit&&(es.useDecoder=es.useDecoder.clone(),es.useDecoder._baseState.implicit=es.implicit),es.useDecoder},eM.prototype._decodeChoice=function(et,ei){var es=this._baseState,ef=null,eu=!1;return(Object.keys(es.choice).some(function(ed){var em=et.save(),eH=es.choice[ed];try{var ez=eH._decode(et,ei);if(et.isError(ez))return!1;ef={type:ed,value:ez},eu=!0}catch(ei){return et.restore(em),!1}return!0},this),eu)?ef:et.error("Choice not matched")},eM.prototype._createEncoderBuffer=function(et){return new eu(et,this.reporter)},eM.prototype._encode=function(et,ei,es){var ef=this._baseState;if(null===ef.default||ef.default!==et){var eu=this._encodeValue(et,ei,es);if(void 0!==eu&&!this._skipDefault(eu,ei,es))return eu}},eM.prototype._encodeValue=function(et,ei,es){var eu,ed=this._baseState;if(null===ed.parent)return ed.children[0]._encode(et,ei||new ef);var eu=null;if(this.reporter=ei,ed.optional&&void 0===et){if(null===ed.default)return;et=ed.default}var em=null,eH=!1;if(ed.any)eu=this._createEncoderBuffer(et);else if(ed.choice)eu=this._encodeChoice(et,ei);else if(ed.contains)em=this._getUse(ed.contains,es)._encode(et,ei),eH=!0;else if(ed.children)em=ed.children.map(function(es){if("null_"===es._baseState.tag)return es._encode(null,ei,et);if(null===es._baseState.key)return ei.error("Child should have a key");var ef=ei.enterKey(es._baseState.key);if("object"!=typeof et)return ei.error("Child expected, but input is not object");var eu=es._encode(et[es._baseState.key],ei,et);return ei.leaveKey(ef),eu},this).filter(function(et){return et}),em=this._createEncoderBuffer(em);else if("seqof"===ed.tag||"setof"===ed.tag){if(!(ed.args&&1===ed.args.length))return ei.error("Too many args for : "+ed.tag);if(!Array.isArray(et))return ei.error("seqof/setof, but data is not Array");var ez=this.clone();ez._baseState.implicit=null,em=this._createEncoderBuffer(et.map(function(es){var ef=this._baseState;return this._getUse(ef.args[0],et)._encode(es,ei)},ez))}else null!==ed.use?eu=this._getUse(ed.use,es)._encode(et,ei):(em=this._encodePrimitive(ed.tag,et),eH=!0);if(!ed.any&&null===ed.choice){var eV=null!==ed.implicit?ed.implicit:ed.tag,eM=null===ed.implicit?"universal":"context";null===eV?null===ed.use&&ei.error("Tag could be omitted only for .use()"):null===ed.use&&(eu=this._encodeComposite(eV,eH,eM,em))}return null!==ed.explicit&&(eu=this._encodeComposite(ed.explicit,!1,"context",eu)),eu},eM.prototype._encodeChoice=function(et,ei){var es=this._baseState,ef=es.choice[et.type];return ef||em(!1,et.type+" not found in "+JSON.stringify(Object.keys(es.choice))),ef._encode(et.value,ei)},eM.prototype._encodePrimitive=function(et,ei){var es=this._baseState;if(/str$/.test(et))return this._encodeStr(ei,et);if("objid"===et&&es.args)return this._encodeObjid(ei,es.reverseArgs[0],es.args[1]);if("objid"===et)return this._encodeObjid(ei,null,null);if("gentime"===et||"utctime"===et)return this._encodeTime(ei,et);if("null_"===et)return this._encodeNull();if("int"===et||"enum"===et)return this._encodeInt(ei,es.args&&es.reverseArgs[0]);if("bool"===et)return this._encodeBool(ei);else if("objDesc"===et)return this._encodeStr(ei,et);else throw Error("Unsupported tag: "+et)},eM.prototype._isNumstr=function(et){return/^[0-9 ]*$/.test(et)},eM.prototype._isPrintstr=function(et){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(et)}},1293:function(et,ei,es){var ef=es(3782);function eu(et){this._reporterState={obj:null,path:[],options:et||{},errors:[]}}function ed(et,ei){this.path=et,this.rethrow(ei)}ei.b=eu,eu.prototype.isError=function(et){return et instanceof ed},eu.prototype.save=function(){var et=this._reporterState;return{obj:et.obj,pathLen:et.path.length}},eu.prototype.restore=function(et){var ei=this._reporterState;ei.obj=et.obj,ei.path=ei.path.slice(0,et.pathLen)},eu.prototype.enterKey=function(et){return this._reporterState.path.push(et)},eu.prototype.exitKey=function(et){var ei=this._reporterState;ei.path=ei.path.slice(0,et-1)},eu.prototype.leaveKey=function(et,ei,es){var ef=this._reporterState;this.exitKey(et),null!==ef.obj&&(ef.obj[ei]=es)},eu.prototype.path=function(){return this._reporterState.path.join("/")},eu.prototype.enterObject=function(){var et=this._reporterState,ei=et.obj;return et.obj={},ei},eu.prototype.leaveObject=function(et){var ei=this._reporterState,es=ei.obj;return ei.obj=et,es},eu.prototype.error=function(et){var ei,es=this._reporterState,ef=et instanceof ed;if(ei=ef?et:new ed(es.path.map(function(et){return"["+JSON.stringify(et)+"]"}).join(""),et.message||et,et.stack),!es.options.partial)throw ei;return ef||es.errors.push(ei),ei},eu.prototype.wrapResult=function(et){var ei=this._reporterState;return ei.options.partial?{result:this.isError(et)?null:et,errors:ei.errors}:et},ef(ed,Error),ed.prototype.rethrow=function(et){if(this.message=et+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,ed),!this.stack)try{throw Error(this.message)}catch(et){this.stack=et.stack}return this}},9791:function(et,ei,es){var ef=es(7335);ei.tagClass={0:"universal",1:"application",2:"context",3:"private"},ei.tagClassByName=ef._reverse(ei.tagClass),ei.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"},ei.tagByName=ef._reverse(ei.tag)},7335:function(et,ei,es){var ef=ei;ef._reverse=function(et){var ei={};return Object.keys(et).forEach(function(es){(0|es)==es&&(es|=0),ei[et[es]]=es}),ei},ef.der=es(9791)},2259:function(et,ei,es){var ef=es(3782),eu=es(7160),ed=eu.base,em=eu.bignum,eH=eu.constants.der;function ez(et){this.enc="der",this.name=et.name,this.entity=et,this.tree=new eV,this.tree._init(et.body)}function eV(et){ed.Node.call(this,"der",et)}function eM(et,ei){var es=et.readUInt8(ei);if(et.isError(es))return es;var ef=eH.tagClass[es>>6],eu=(32&es)==0;if((31&es)==31){var ed=es;for(es=0;(128&ed)==128;){if(ed=et.readUInt8(ei),et.isError(ed))return ed;es<<=7,es|=127&ed}}else es&=31;var em=eH.tag[es];return{cls:ef,primitive:eu,tag:es,tagStr:em}}function eg(et,ei,es){var ef=et.readUInt8(es);if(et.isError(ef))return ef;if(!ei&&128===ef)return null;if((128&ef)==0)return ef;var eu=127&ef;if(eu>4)return et.error("length octect is too long");ef=0;for(var ed=0;ed=31?ef.error("Multi-octet tag encoding unsupported"):(ei||(eu|=32),eu|=eH.tagClassByName[es||"universal"]<<6)}et.exports=ez,ez.prototype.encode=function(et,ei){return this.tree._encode(et,ei).join()},ef(eV,em.Node),eV.prototype._encodeComposite=function(et,ei,es,ef){var ed=eg(et,ei,es,this.reporter);if(ef.length<128){var em=new eu(2);return em[0]=ed,em[1]=ef.length,this._createEncoderBuffer([em,ef])}for(var eH=1,ez=ef.length;ez>=256;ez>>=8)eH++;var em=new eu(2+eH);em[0]=ed,em[1]=128|eH;for(var ez=1+eH,eV=ef.length;eV>0;ez--,eV>>=8)em[ez]=255&eV;return this._createEncoderBuffer([em,ef])},eV.prototype._encodeStr=function(et,ei){if("bitstr"===ei)return this._createEncoderBuffer([0|et.unused,et.data]);if("bmpstr"===ei){for(var es=new eu(2*et.length),ef=0;ef=40)return this.reporter.error("Second objid identifier OOB");et.splice(0,2,40*et[0]+et[1])}for(var ed=0,ef=0;ef=128;em>>=7)ed++}for(var eH=new eu(ed),ez=eH.length-1,ef=et.length-1;ef>=0;ef--){var em=et[ef];for(eH[ez--]=127&em;(em>>=7)>0;)eH[ez--]=128|127&em}return this._createEncoderBuffer(eH)},eV.prototype._encodeTime=function(et,ei){var es,ef=new Date(et);return"gentime"===ei?es=[eM(ef.getFullYear()),eM(ef.getUTCMonth()+1),eM(ef.getUTCDate()),eM(ef.getUTCHours()),eM(ef.getUTCMinutes()),eM(ef.getUTCSeconds()),"Z"].join(""):"utctime"===ei?es=[eM(ef.getFullYear()%100),eM(ef.getUTCMonth()+1),eM(ef.getUTCDate()),eM(ef.getUTCHours()),eM(ef.getUTCMinutes()),eM(ef.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+ei+" time is not supported yet"),this._encodeStr(es,"octstr")},eV.prototype._encodeNull=function(){return this._createEncoderBuffer("")},eV.prototype._encodeInt=function(et,ei){if("string"==typeof et){if(!ei)return this.reporter.error("String int or enum given, but no values map");if(!ei.hasOwnProperty(et))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(et));et=ei[et]}if("number"!=typeof et&&!eu.isBuffer(et)){var es=et.toArray();!et.sign&&128&es[0]&&es.unshift(0),et=new eu(es)}if(eu.isBuffer(et)){var ef=et.length;0===et.length&&ef++;var ed=new eu(ef);return et.copy(ed),0===et.length&&(ed[0]=0),this._createEncoderBuffer(ed)}if(et<128)return this._createEncoderBuffer(et);if(et<256)return this._createEncoderBuffer([0,et]);for(var ef=1,em=et;em>=256;em>>=8)ef++;for(var ed=Array(ef),em=ed.length-1;em>=0;em--)ed[em]=255&et,et>>=8;return 128&ed[0]&&ed.unshift(0),this._createEncoderBuffer(new eu(ed))},eV.prototype._encodeBool=function(et){return this._createEncoderBuffer(et?255:0)},eV.prototype._use=function(et,ei){return"function"==typeof et&&(et=et(ei)),et._getEncoder("der").tree},eV.prototype._skipDefault=function(et,ei,es){var ef,eu=this._baseState;if(null===eu.default)return!1;var ed=et.join();if(void 0===eu.defaultBuffer&&(eu.defaultBuffer=this._encodeValue(eu.default,ei,es).join()),ed.length!==eu.defaultBuffer.length)return!1;for(ef=0;ef=49&&em<=54?ef|=em-49+10:em>=17&&em<=22?ef|=em-17+10:ef|=15&em}return ef}function eH(et,ei,es,ef){for(var eu=0,ed=Math.min(et.length,es),em=ei;em=49?eu+=eH-49+10:eH>=17?eu+=eH-17+10:eu+=eH}return eu}ed.isBN=function(et){return et instanceof ed||null!==et&&"object"==typeof et&&et.constructor.wordSize===ed.wordSize&&Array.isArray(et.words)},ed.max=function(et,ei){return et.cmp(ei)>0?et:ei},ed.min=function(et,ei){return 0>et.cmp(ei)?et:ei},ed.prototype._init=function(et,ei,es){if("number"==typeof et)return this._initNumber(et,ei,es);if("object"==typeof et)return this._initArray(et,ei,es);"hex"===ei&&(ei=16),ef(ei===(0|ei)&&ei>=2&&ei<=36);var eu=0;"-"===(et=et.toString().replace(/\s+/g,""))[0]&&eu++,16===ei?this._parseHex(et,eu):this._parseBase(et,ei,eu),"-"===et[0]&&(this.negative=1),this.strip(),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initNumber=function(et,ei,es){et<0&&(this.negative=1,et=-et),et<67108864?(this.words=[67108863&et],this.length=1):et<4503599627370496?(this.words=[67108863&et,et/67108864&67108863],this.length=2):(ef(et<9007199254740992),this.words=[67108863&et,et/67108864&67108863,1],this.length=3),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initArray=function(et,ei,es){if(ef("number"==typeof et.length),et.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(et.length/3),this.words=Array(this.length);for(var eu,ed,em=0;em=0;em-=3)ed=et[em]|et[em-1]<<8|et[em-2]<<16,this.words[eu]|=ed<>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);else if("le"===es)for(em=0,eu=0;em>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);return this.strip()},ed.prototype._parseHex=function(et,ei){this.length=Math.ceil((et.length-ei)/6),this.words=Array(this.length);for(var es,ef,eu=0;eu=ei;eu-=6)ef=em(et,eu,eu+6),this.words[es]|=ef<>>26-ed&4194303,(ed+=24)>=26&&(ed-=26,es++);eu+6!==ei&&(ef=em(et,ei,eu+6),this.words[es]|=ef<>>26-ed&4194303),this.strip()},ed.prototype._parseBase=function(et,ei,es){this.words=[0],this.length=1;for(var ef=0,eu=1;eu<=67108863;eu*=ei)ef++;ef--,eu=eu/ei|0;for(var ed=et.length-es,em=ed%ef,ez=Math.min(ed,ed-em)+es,eV=0,eM=es;eM1&&0===this.words[this.length-1];)this.length--;return this._normSign()},ed.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},ed.prototype.inspect=function(){return(this.red?""};var ez,eV=["","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"],eM=[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],eg=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function eL(et){for(var ei=Array(et.bitLength()),es=0;es>>eu}return ei}function eb(et,ei,es){es.negative=ei.negative^et.negative;var ef=et.length+ei.length|0;es.length=ef,ef=ef-1|0;var eu=0|et.words[0],ed=0|ei.words[0],em=eu*ed,eH=67108863&em,ez=em/67108864|0;es.words[0]=eH;for(var eV=1;eV>>26,eg=67108863&ez,eL=Math.min(eV,ei.length-1),eb=Math.max(0,eV-et.length+1);eb<=eL;eb++){var ey=eV-eb|0;eM+=(em=(eu=0|et.words[ey])*(ed=0|ei.words[eb])+eg)/67108864|0,eg=67108863&em}es.words[eV]=0|eg,ez=0|eM}return 0!==ez?es.words[eV]=0|ez:es.length--,es.strip()}ed.prototype.toString=function(et,ei){if(ei=0|ei||1,16===(et=et||10)||"hex"===et){es="";for(var es,eu=0,ed=0,em=0;em>>24-eu&16777215)||em!==this.length-1?eV[6-ez.length]+ez+es:ez+es,(eu+=2)>=26&&(eu-=26,em--)}for(0!==ed&&(es=ed.toString(16)+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}if(et===(0|et)&&et>=2&&et<=36){var eL=eM[et],eb=eg[et];es="";var ey=this.clone();for(ey.negative=0;!ey.isZero();){var eC=ey.modn(eb).toString(et);es=(ey=ey.idivn(eb)).isZero()?eC+es:eV[eL-eC.length]+eC+es}for(this.isZero()&&(es="0"+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}ef(!1,"Base should be between 2 and 36")},ed.prototype.toNumber=function(){var et=this.words[0];return 2===this.length?et+=67108864*this.words[1]:3===this.length&&1===this.words[2]?et+=4503599627370496+67108864*this.words[1]:this.length>2&&ef(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-et:et},ed.prototype.toJSON=function(){return this.toString(16)},ed.prototype.toBuffer=function(et,ei){return ef(void 0!==ez),this.toArrayLike(ez,et,ei)},ed.prototype.toArray=function(et,ei){return this.toArrayLike(Array,et,ei)},ed.prototype.toArrayLike=function(et,ei,es){var eu,ed,em=this.byteLength(),eH=es||Math.max(1,em);ef(em<=eH,"byte array longer than desired length"),ef(eH>0,"Requested array length <= 0"),this.strip();var ez="le"===ei,eV=new et(eH),eM=this.clone();if(ez){for(ed=0;!eM.isZero();ed++)eu=eM.andln(255),eM.iushrn(8),eV[ed]=eu;for(;ed=4096&&(es+=13,ei>>>=13),ei>=64&&(es+=7,ei>>>=7),ei>=8&&(es+=4,ei>>>=4),ei>=2&&(es+=2,ei>>>=2),es+ei},ed.prototype._zeroBits=function(et){if(0===et)return 26;var ei=et,es=0;return(8191&ei)==0&&(es+=13,ei>>>=13),(127&ei)==0&&(es+=7,ei>>>=7),(15&ei)==0&&(es+=4,ei>>>=4),(3&ei)==0&&(es+=2,ei>>>=2),(1&ei)==0&&es++,es},ed.prototype.bitLength=function(){var et=this.words[this.length-1],ei=this._countBits(et);return(this.length-1)*26+ei},ed.prototype.zeroBits=function(){if(this.isZero())return 0;for(var et=0,ei=0;eiet.length?this.clone().ior(et):et.clone().ior(this)},ed.prototype.uor=function(et){return this.length>et.length?this.clone().iuor(et):et.clone().iuor(this)},ed.prototype.iuand=function(et){var ei;ei=this.length>et.length?et:this;for(var es=0;eset.length?this.clone().iand(et):et.clone().iand(this)},ed.prototype.uand=function(et){return this.length>et.length?this.clone().iuand(et):et.clone().iuand(this)},ed.prototype.iuxor=function(et){this.length>et.length?(ei=this,es=et):(ei=et,es=this);for(var ei,es,ef=0;efet.length?this.clone().ixor(et):et.clone().ixor(this)},ed.prototype.uxor=function(et){return this.length>et.length?this.clone().iuxor(et):et.clone().iuxor(this)},ed.prototype.inotn=function(et){ef("number"==typeof et&&et>=0);var ei=0|Math.ceil(et/26),es=et%26;this._expand(ei),es>0&&ei--;for(var eu=0;eu0&&(this.words[eu]=~this.words[eu]&67108863>>26-es),this.strip()},ed.prototype.notn=function(et){return this.clone().inotn(et)},ed.prototype.setn=function(et,ei){ef("number"==typeof et&&et>=0);var es=et/26|0,eu=et%26;return this._expand(es+1),ei?this.words[es]=this.words[es]|1<et.length?(es=this,ef=et):(es=et,ef=this);for(var ei,es,ef,eu=0,ed=0;ed>>26;for(;0!==eu&&ed>>26;if(this.length=es.length,0!==eu)this.words[this.length]=eu,this.length++;else if(es!==this)for(;edet.length?this.clone().iadd(et):et.clone().iadd(this)},ed.prototype.isub=function(et){if(0!==et.negative){et.negative=0;var ei,es,ef=this.iadd(et);return et.negative=1,ef._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(et),this.negative=1,this._normSign();var eu=this.cmp(et);if(0===eu)return this.negative=0,this.length=1,this.words[0]=0,this;eu>0?(ei=this,es=et):(ei=et,es=this);for(var ed=0,em=0;em>26,this.words[em]=67108863&ef;for(;0!==ed&&em>26,this.words[em]=67108863&ef;if(0===ed&&em>>13,eb=0|em[1],ey=8191&eb,eC=eb>>>13,ex=0|em[2],ew=8191&ex,eN=ex>>>13,eS=0|em[3],eA=8191&eS,e_=eS>>>13,eE=0|em[4],eP=8191&eE,eB=eE>>>13,eT=0|em[5],eI=8191&eT,eR=eT>>>13,eO=0|em[6],ej=8191&eO,eD=eO>>>13,eF=0|em[7],eU=8191&eF,eq=eF>>>13,eZ=0|em[8],eG=8191&eZ,eW=eZ>>>13,eK=0|em[9],e$=8191&eK,eJ=eK>>>13,eY=0|eH[0],eX=8191&eY,eQ=eY>>>13,e1=0|eH[1],e2=8191&e1,e4=e1>>>13,e3=0|eH[2],e6=8191&e3,e0=e3>>>13,e8=0|eH[3],e5=8191&e8,e7=e8>>>13,e9=0|eH[4],cc=8191&e9,ci=e9>>>13,cs=0|eH[5],cf=8191&cs,cd=cs>>>13,cm=0|eH[6],cH=8191&cm,cz=cm>>>13,cV=0|eH[7],cM=8191&cV,cg=cV>>>13,cL=0|eH[8],cy=8191&cL,cC=cL>>>13,cx=0|eH[9],cw=8191&cx,ck=cx>>>13;es.negative=et.negative^ei.negative,es.length=19;var cN=(eV+(ef=Math.imul(eg,eX))|0)+((8191&(eu=(eu=Math.imul(eg,eQ))+Math.imul(eL,eX)|0))<<13)|0;eV=((ed=Math.imul(eL,eQ))+(eu>>>13)|0)+(cN>>>26)|0,cN&=67108863,ef=Math.imul(ey,eX),eu=(eu=Math.imul(ey,eQ))+Math.imul(eC,eX)|0,ed=Math.imul(eC,eQ);var cS=(eV+(ef=ef+Math.imul(eg,e2)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e4)|0)+Math.imul(eL,e2)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e4)|0)+(eu>>>13)|0)+(cS>>>26)|0,cS&=67108863,ef=Math.imul(ew,eX),eu=(eu=Math.imul(ew,eQ))+Math.imul(eN,eX)|0,ed=Math.imul(eN,eQ),ef=ef+Math.imul(ey,e2)|0,eu=(eu=eu+Math.imul(ey,e4)|0)+Math.imul(eC,e2)|0,ed=ed+Math.imul(eC,e4)|0;var cA=(eV+(ef=ef+Math.imul(eg,e6)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e0)|0)+Math.imul(eL,e6)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e0)|0)+(eu>>>13)|0)+(cA>>>26)|0,cA&=67108863,ef=Math.imul(eA,eX),eu=(eu=Math.imul(eA,eQ))+Math.imul(e_,eX)|0,ed=Math.imul(e_,eQ),ef=ef+Math.imul(ew,e2)|0,eu=(eu=eu+Math.imul(ew,e4)|0)+Math.imul(eN,e2)|0,ed=ed+Math.imul(eN,e4)|0,ef=ef+Math.imul(ey,e6)|0,eu=(eu=eu+Math.imul(ey,e0)|0)+Math.imul(eC,e6)|0,ed=ed+Math.imul(eC,e0)|0;var c_=(eV+(ef=ef+Math.imul(eg,e5)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e7)|0)+Math.imul(eL,e5)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e7)|0)+(eu>>>13)|0)+(c_>>>26)|0,c_&=67108863,ef=Math.imul(eP,eX),eu=(eu=Math.imul(eP,eQ))+Math.imul(eB,eX)|0,ed=Math.imul(eB,eQ),ef=ef+Math.imul(eA,e2)|0,eu=(eu=eu+Math.imul(eA,e4)|0)+Math.imul(e_,e2)|0,ed=ed+Math.imul(e_,e4)|0,ef=ef+Math.imul(ew,e6)|0,eu=(eu=eu+Math.imul(ew,e0)|0)+Math.imul(eN,e6)|0,ed=ed+Math.imul(eN,e0)|0,ef=ef+Math.imul(ey,e5)|0,eu=(eu=eu+Math.imul(ey,e7)|0)+Math.imul(eC,e5)|0,ed=ed+Math.imul(eC,e7)|0;var cE=(eV+(ef=ef+Math.imul(eg,cc)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ci)|0)+Math.imul(eL,cc)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ci)|0)+(eu>>>13)|0)+(cE>>>26)|0,cE&=67108863,ef=Math.imul(eI,eX),eu=(eu=Math.imul(eI,eQ))+Math.imul(eR,eX)|0,ed=Math.imul(eR,eQ),ef=ef+Math.imul(eP,e2)|0,eu=(eu=eu+Math.imul(eP,e4)|0)+Math.imul(eB,e2)|0,ed=ed+Math.imul(eB,e4)|0,ef=ef+Math.imul(eA,e6)|0,eu=(eu=eu+Math.imul(eA,e0)|0)+Math.imul(e_,e6)|0,ed=ed+Math.imul(e_,e0)|0,ef=ef+Math.imul(ew,e5)|0,eu=(eu=eu+Math.imul(ew,e7)|0)+Math.imul(eN,e5)|0,ed=ed+Math.imul(eN,e7)|0,ef=ef+Math.imul(ey,cc)|0,eu=(eu=eu+Math.imul(ey,ci)|0)+Math.imul(eC,cc)|0,ed=ed+Math.imul(eC,ci)|0;var cP=(eV+(ef=ef+Math.imul(eg,cf)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cd)|0)+Math.imul(eL,cf)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cd)|0)+(eu>>>13)|0)+(cP>>>26)|0,cP&=67108863,ef=Math.imul(ej,eX),eu=(eu=Math.imul(ej,eQ))+Math.imul(eD,eX)|0,ed=Math.imul(eD,eQ),ef=ef+Math.imul(eI,e2)|0,eu=(eu=eu+Math.imul(eI,e4)|0)+Math.imul(eR,e2)|0,ed=ed+Math.imul(eR,e4)|0,ef=ef+Math.imul(eP,e6)|0,eu=(eu=eu+Math.imul(eP,e0)|0)+Math.imul(eB,e6)|0,ed=ed+Math.imul(eB,e0)|0,ef=ef+Math.imul(eA,e5)|0,eu=(eu=eu+Math.imul(eA,e7)|0)+Math.imul(e_,e5)|0,ed=ed+Math.imul(e_,e7)|0,ef=ef+Math.imul(ew,cc)|0,eu=(eu=eu+Math.imul(ew,ci)|0)+Math.imul(eN,cc)|0,ed=ed+Math.imul(eN,ci)|0,ef=ef+Math.imul(ey,cf)|0,eu=(eu=eu+Math.imul(ey,cd)|0)+Math.imul(eC,cf)|0,ed=ed+Math.imul(eC,cd)|0;var cB=(eV+(ef=ef+Math.imul(eg,cH)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cz)|0)+Math.imul(eL,cH)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cz)|0)+(eu>>>13)|0)+(cB>>>26)|0,cB&=67108863,ef=Math.imul(eU,eX),eu=(eu=Math.imul(eU,eQ))+Math.imul(eq,eX)|0,ed=Math.imul(eq,eQ),ef=ef+Math.imul(ej,e2)|0,eu=(eu=eu+Math.imul(ej,e4)|0)+Math.imul(eD,e2)|0,ed=ed+Math.imul(eD,e4)|0,ef=ef+Math.imul(eI,e6)|0,eu=(eu=eu+Math.imul(eI,e0)|0)+Math.imul(eR,e6)|0,ed=ed+Math.imul(eR,e0)|0,ef=ef+Math.imul(eP,e5)|0,eu=(eu=eu+Math.imul(eP,e7)|0)+Math.imul(eB,e5)|0,ed=ed+Math.imul(eB,e7)|0,ef=ef+Math.imul(eA,cc)|0,eu=(eu=eu+Math.imul(eA,ci)|0)+Math.imul(e_,cc)|0,ed=ed+Math.imul(e_,ci)|0,ef=ef+Math.imul(ew,cf)|0,eu=(eu=eu+Math.imul(ew,cd)|0)+Math.imul(eN,cf)|0,ed=ed+Math.imul(eN,cd)|0,ef=ef+Math.imul(ey,cH)|0,eu=(eu=eu+Math.imul(ey,cz)|0)+Math.imul(eC,cH)|0,ed=ed+Math.imul(eC,cz)|0;var cT=(eV+(ef=ef+Math.imul(eg,cM)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cg)|0)+Math.imul(eL,cM)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cg)|0)+(eu>>>13)|0)+(cT>>>26)|0,cT&=67108863,ef=Math.imul(eG,eX),eu=(eu=Math.imul(eG,eQ))+Math.imul(eW,eX)|0,ed=Math.imul(eW,eQ),ef=ef+Math.imul(eU,e2)|0,eu=(eu=eu+Math.imul(eU,e4)|0)+Math.imul(eq,e2)|0,ed=ed+Math.imul(eq,e4)|0,ef=ef+Math.imul(ej,e6)|0,eu=(eu=eu+Math.imul(ej,e0)|0)+Math.imul(eD,e6)|0,ed=ed+Math.imul(eD,e0)|0,ef=ef+Math.imul(eI,e5)|0,eu=(eu=eu+Math.imul(eI,e7)|0)+Math.imul(eR,e5)|0,ed=ed+Math.imul(eR,e7)|0,ef=ef+Math.imul(eP,cc)|0,eu=(eu=eu+Math.imul(eP,ci)|0)+Math.imul(eB,cc)|0,ed=ed+Math.imul(eB,ci)|0,ef=ef+Math.imul(eA,cf)|0,eu=(eu=eu+Math.imul(eA,cd)|0)+Math.imul(e_,cf)|0,ed=ed+Math.imul(e_,cd)|0,ef=ef+Math.imul(ew,cH)|0,eu=(eu=eu+Math.imul(ew,cz)|0)+Math.imul(eN,cH)|0,ed=ed+Math.imul(eN,cz)|0,ef=ef+Math.imul(ey,cM)|0,eu=(eu=eu+Math.imul(ey,cg)|0)+Math.imul(eC,cM)|0,ed=ed+Math.imul(eC,cg)|0;var cI=(eV+(ef=ef+Math.imul(eg,cy)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cC)|0)+Math.imul(eL,cy)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cC)|0)+(eu>>>13)|0)+(cI>>>26)|0,cI&=67108863,ef=Math.imul(e$,eX),eu=(eu=Math.imul(e$,eQ))+Math.imul(eJ,eX)|0,ed=Math.imul(eJ,eQ),ef=ef+Math.imul(eG,e2)|0,eu=(eu=eu+Math.imul(eG,e4)|0)+Math.imul(eW,e2)|0,ed=ed+Math.imul(eW,e4)|0,ef=ef+Math.imul(eU,e6)|0,eu=(eu=eu+Math.imul(eU,e0)|0)+Math.imul(eq,e6)|0,ed=ed+Math.imul(eq,e0)|0,ef=ef+Math.imul(ej,e5)|0,eu=(eu=eu+Math.imul(ej,e7)|0)+Math.imul(eD,e5)|0,ed=ed+Math.imul(eD,e7)|0,ef=ef+Math.imul(eI,cc)|0,eu=(eu=eu+Math.imul(eI,ci)|0)+Math.imul(eR,cc)|0,ed=ed+Math.imul(eR,ci)|0,ef=ef+Math.imul(eP,cf)|0,eu=(eu=eu+Math.imul(eP,cd)|0)+Math.imul(eB,cf)|0,ed=ed+Math.imul(eB,cd)|0,ef=ef+Math.imul(eA,cH)|0,eu=(eu=eu+Math.imul(eA,cz)|0)+Math.imul(e_,cH)|0,ed=ed+Math.imul(e_,cz)|0,ef=ef+Math.imul(ew,cM)|0,eu=(eu=eu+Math.imul(ew,cg)|0)+Math.imul(eN,cM)|0,ed=ed+Math.imul(eN,cg)|0,ef=ef+Math.imul(ey,cy)|0,eu=(eu=eu+Math.imul(ey,cC)|0)+Math.imul(eC,cy)|0,ed=ed+Math.imul(eC,cC)|0;var cR=(eV+(ef=ef+Math.imul(eg,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ck)|0)+Math.imul(eL,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ck)|0)+(eu>>>13)|0)+(cR>>>26)|0,cR&=67108863,ef=Math.imul(e$,e2),eu=(eu=Math.imul(e$,e4))+Math.imul(eJ,e2)|0,ed=Math.imul(eJ,e4),ef=ef+Math.imul(eG,e6)|0,eu=(eu=eu+Math.imul(eG,e0)|0)+Math.imul(eW,e6)|0,ed=ed+Math.imul(eW,e0)|0,ef=ef+Math.imul(eU,e5)|0,eu=(eu=eu+Math.imul(eU,e7)|0)+Math.imul(eq,e5)|0,ed=ed+Math.imul(eq,e7)|0,ef=ef+Math.imul(ej,cc)|0,eu=(eu=eu+Math.imul(ej,ci)|0)+Math.imul(eD,cc)|0,ed=ed+Math.imul(eD,ci)|0,ef=ef+Math.imul(eI,cf)|0,eu=(eu=eu+Math.imul(eI,cd)|0)+Math.imul(eR,cf)|0,ed=ed+Math.imul(eR,cd)|0,ef=ef+Math.imul(eP,cH)|0,eu=(eu=eu+Math.imul(eP,cz)|0)+Math.imul(eB,cH)|0,ed=ed+Math.imul(eB,cz)|0,ef=ef+Math.imul(eA,cM)|0,eu=(eu=eu+Math.imul(eA,cg)|0)+Math.imul(e_,cM)|0,ed=ed+Math.imul(e_,cg)|0,ef=ef+Math.imul(ew,cy)|0,eu=(eu=eu+Math.imul(ew,cC)|0)+Math.imul(eN,cy)|0,ed=ed+Math.imul(eN,cC)|0;var cO=(eV+(ef=ef+Math.imul(ey,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ey,ck)|0)+Math.imul(eC,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eC,ck)|0)+(eu>>>13)|0)+(cO>>>26)|0,cO&=67108863,ef=Math.imul(e$,e6),eu=(eu=Math.imul(e$,e0))+Math.imul(eJ,e6)|0,ed=Math.imul(eJ,e0),ef=ef+Math.imul(eG,e5)|0,eu=(eu=eu+Math.imul(eG,e7)|0)+Math.imul(eW,e5)|0,ed=ed+Math.imul(eW,e7)|0,ef=ef+Math.imul(eU,cc)|0,eu=(eu=eu+Math.imul(eU,ci)|0)+Math.imul(eq,cc)|0,ed=ed+Math.imul(eq,ci)|0,ef=ef+Math.imul(ej,cf)|0,eu=(eu=eu+Math.imul(ej,cd)|0)+Math.imul(eD,cf)|0,ed=ed+Math.imul(eD,cd)|0,ef=ef+Math.imul(eI,cH)|0,eu=(eu=eu+Math.imul(eI,cz)|0)+Math.imul(eR,cH)|0,ed=ed+Math.imul(eR,cz)|0,ef=ef+Math.imul(eP,cM)|0,eu=(eu=eu+Math.imul(eP,cg)|0)+Math.imul(eB,cM)|0,ed=ed+Math.imul(eB,cg)|0,ef=ef+Math.imul(eA,cy)|0,eu=(eu=eu+Math.imul(eA,cC)|0)+Math.imul(e_,cy)|0,ed=ed+Math.imul(e_,cC)|0;var cj=(eV+(ef=ef+Math.imul(ew,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ew,ck)|0)+Math.imul(eN,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eN,ck)|0)+(eu>>>13)|0)+(cj>>>26)|0,cj&=67108863,ef=Math.imul(e$,e5),eu=(eu=Math.imul(e$,e7))+Math.imul(eJ,e5)|0,ed=Math.imul(eJ,e7),ef=ef+Math.imul(eG,cc)|0,eu=(eu=eu+Math.imul(eG,ci)|0)+Math.imul(eW,cc)|0,ed=ed+Math.imul(eW,ci)|0,ef=ef+Math.imul(eU,cf)|0,eu=(eu=eu+Math.imul(eU,cd)|0)+Math.imul(eq,cf)|0,ed=ed+Math.imul(eq,cd)|0,ef=ef+Math.imul(ej,cH)|0,eu=(eu=eu+Math.imul(ej,cz)|0)+Math.imul(eD,cH)|0,ed=ed+Math.imul(eD,cz)|0,ef=ef+Math.imul(eI,cM)|0,eu=(eu=eu+Math.imul(eI,cg)|0)+Math.imul(eR,cM)|0,ed=ed+Math.imul(eR,cg)|0,ef=ef+Math.imul(eP,cy)|0,eu=(eu=eu+Math.imul(eP,cC)|0)+Math.imul(eB,cy)|0,ed=ed+Math.imul(eB,cC)|0;var cD=(eV+(ef=ef+Math.imul(eA,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eA,ck)|0)+Math.imul(e_,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(e_,ck)|0)+(eu>>>13)|0)+(cD>>>26)|0,cD&=67108863,ef=Math.imul(e$,cc),eu=(eu=Math.imul(e$,ci))+Math.imul(eJ,cc)|0,ed=Math.imul(eJ,ci),ef=ef+Math.imul(eG,cf)|0,eu=(eu=eu+Math.imul(eG,cd)|0)+Math.imul(eW,cf)|0,ed=ed+Math.imul(eW,cd)|0,ef=ef+Math.imul(eU,cH)|0,eu=(eu=eu+Math.imul(eU,cz)|0)+Math.imul(eq,cH)|0,ed=ed+Math.imul(eq,cz)|0,ef=ef+Math.imul(ej,cM)|0,eu=(eu=eu+Math.imul(ej,cg)|0)+Math.imul(eD,cM)|0,ed=ed+Math.imul(eD,cg)|0,ef=ef+Math.imul(eI,cy)|0,eu=(eu=eu+Math.imul(eI,cC)|0)+Math.imul(eR,cy)|0,ed=ed+Math.imul(eR,cC)|0;var cF=(eV+(ef=ef+Math.imul(eP,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eP,ck)|0)+Math.imul(eB,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eB,ck)|0)+(eu>>>13)|0)+(cF>>>26)|0,cF&=67108863,ef=Math.imul(e$,cf),eu=(eu=Math.imul(e$,cd))+Math.imul(eJ,cf)|0,ed=Math.imul(eJ,cd),ef=ef+Math.imul(eG,cH)|0,eu=(eu=eu+Math.imul(eG,cz)|0)+Math.imul(eW,cH)|0,ed=ed+Math.imul(eW,cz)|0,ef=ef+Math.imul(eU,cM)|0,eu=(eu=eu+Math.imul(eU,cg)|0)+Math.imul(eq,cM)|0,ed=ed+Math.imul(eq,cg)|0,ef=ef+Math.imul(ej,cy)|0,eu=(eu=eu+Math.imul(ej,cC)|0)+Math.imul(eD,cy)|0,ed=ed+Math.imul(eD,cC)|0;var cU=(eV+(ef=ef+Math.imul(eI,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eI,ck)|0)+Math.imul(eR,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eR,ck)|0)+(eu>>>13)|0)+(cU>>>26)|0,cU&=67108863,ef=Math.imul(e$,cH),eu=(eu=Math.imul(e$,cz))+Math.imul(eJ,cH)|0,ed=Math.imul(eJ,cz),ef=ef+Math.imul(eG,cM)|0,eu=(eu=eu+Math.imul(eG,cg)|0)+Math.imul(eW,cM)|0,ed=ed+Math.imul(eW,cg)|0,ef=ef+Math.imul(eU,cy)|0,eu=(eu=eu+Math.imul(eU,cC)|0)+Math.imul(eq,cy)|0,ed=ed+Math.imul(eq,cC)|0;var cq=(eV+(ef=ef+Math.imul(ej,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ej,ck)|0)+Math.imul(eD,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eD,ck)|0)+(eu>>>13)|0)+(cq>>>26)|0,cq&=67108863,ef=Math.imul(e$,cM),eu=(eu=Math.imul(e$,cg))+Math.imul(eJ,cM)|0,ed=Math.imul(eJ,cg),ef=ef+Math.imul(eG,cy)|0,eu=(eu=eu+Math.imul(eG,cC)|0)+Math.imul(eW,cy)|0,ed=ed+Math.imul(eW,cC)|0;var cZ=(eV+(ef=ef+Math.imul(eU,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eU,ck)|0)+Math.imul(eq,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eq,ck)|0)+(eu>>>13)|0)+(cZ>>>26)|0,cZ&=67108863,ef=Math.imul(e$,cy),eu=(eu=Math.imul(e$,cC))+Math.imul(eJ,cy)|0,ed=Math.imul(eJ,cC);var cG=(eV+(ef=ef+Math.imul(eG,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eG,ck)|0)+Math.imul(eW,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eW,ck)|0)+(eu>>>13)|0)+(cG>>>26)|0,cG&=67108863;var cW=(eV+(ef=Math.imul(e$,cw))|0)+((8191&(eu=(eu=Math.imul(e$,ck))+Math.imul(eJ,cw)|0))<<13)|0;return eV=((ed=Math.imul(eJ,ck))+(eu>>>13)|0)+(cW>>>26)|0,cW&=67108863,ez[0]=cN,ez[1]=cS,ez[2]=cA,ez[3]=c_,ez[4]=cE,ez[5]=cP,ez[6]=cB,ez[7]=cT,ez[8]=cI,ez[9]=cR,ez[10]=cO,ez[11]=cj,ez[12]=cD,ez[13]=cF,ez[14]=cU,ez[15]=cq,ez[16]=cZ,ez[17]=cG,ez[18]=cW,0!==eV&&(ez[19]=eV,es.length++),es};function eC(et,ei,es){es.negative=ei.negative^et.negative,es.length=et.length+ei.length;for(var ef=0,eu=0,ed=0;ed>>26)|0)>>>26,em&=67108863}es.words[ed]=eH,ef=em,em=eu}return 0!==ef?es.words[ed]=ef:es.length--,es.strip()}function ex(et,ei,es){return(new ew).mulp(et,ei,es)}function ew(et,ei){this.x=et,this.y=ei}Math.imul||(ey=eb),ed.prototype.mulTo=function(et,ei){var es=this.length+et.length;return 10===this.length&&10===et.length?ey(this,et,ei):es<63?eb(this,et,ei):es<1024?eC(this,et,ei):ex(this,et,ei)},ew.prototype.makeRBT=function(et){for(var ei=Array(et),es=ed.prototype._countBits(et)-1,ef=0;ef>=1;return ef},ew.prototype.permute=function(et,ei,es,ef,eu,ed){for(var em=0;em>>=1)eu++;return 1<>>=13,es[2*em+1]=8191&ed,ed>>>=13;for(em=2*ei;em>=26,ei+=(eu/67108864|0)+(ed>>>26),this.words[es]=67108863&ed}return 0!==ei&&(this.words[es]=ei,this.length++),this},ed.prototype.muln=function(et){return this.clone().imuln(et)},ed.prototype.sqr=function(){return this.mul(this)},ed.prototype.isqr=function(){return this.imul(this.clone())},ed.prototype.pow=function(et){var ei=eL(et);if(0===ei.length)return new ed(1);for(var es=this,ef=0;ef=0);var ei,es=et%26,eu=(et-es)/26,ed=67108863>>>26-es<<26-es;if(0!==es){var em=0;for(ei=0;ei>>26-es}em&&(this.words[ei]=em,this.length++)}if(0!==eu){for(ei=this.length-1;ei>=0;ei--)this.words[ei+eu]=this.words[ei];for(ei=0;ei=0),eu=ei?(ei-ei%26)/26:0;var eu,ed=et%26,em=Math.min((et-ed)/26,this.length),eH=67108863^67108863>>>ed<em)for(this.length-=em,eV=0;eV=0&&(0!==eM||eV>=eu);eV--){var eg=0|this.words[eV];this.words[eV]=eM<<26-ed|eg>>>ed,eM=eg&eH}return ez&&0!==eM&&(ez.words[ez.length++]=eM),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},ed.prototype.ishrn=function(et,ei,es){return ef(0===this.negative),this.iushrn(et,ei,es)},ed.prototype.shln=function(et){return this.clone().ishln(et)},ed.prototype.ushln=function(et){return this.clone().iushln(et)},ed.prototype.shrn=function(et){return this.clone().ishrn(et)},ed.prototype.ushrn=function(et){return this.clone().iushrn(et)},ed.prototype.testn=function(et){ef("number"==typeof et&&et>=0);var ei=et%26,es=(et-ei)/26,eu=1<=0);var ei=et%26,es=(et-ei)/26;if(ef(0===this.negative,"imaskn works only with positive numbers"),this.length<=es)return this;if(0!==ei&&es++,this.length=Math.min(es,this.length),0!==ei){var eu=67108863^67108863>>>ei<=67108864;ei++)this.words[ei]-=67108864,ei===this.length-1?this.words[ei+1]=1:this.words[ei+1]++;return this.length=Math.max(this.length,ei+1),this},ed.prototype.isubn=function(et){if(ef("number"==typeof et),ef(et<67108864),et<0)return this.iaddn(-et);if(0!==this.negative)return this.negative=0,this.iaddn(et),this.negative=1,this;if(this.words[0]-=et,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var ei=0;ei>26)-(ez/67108864|0),this.words[eu+es]=67108863&ed}for(;eu>26,this.words[eu+es]=67108863&ed;if(0===eH)return this.strip();for(ef(-1===eH),eH=0,eu=0;eu>26,this.words[eu]=67108863&ed;return this.negative=1,this.strip()},ed.prototype._wordDiv=function(et,ei){var es,ef=this.length-et.length,eu=this.clone(),em=et,eH=0|em.words[em.length-1];0!=(ef=26-this._countBits(eH))&&(em=em.ushln(ef),eu.iushln(ef),eH=0|em.words[em.length-1]);var ez=eu.length-em.length;if("mod"!==ei){(es=new ed(null)).length=ez+1,es.words=Array(es.length);for(var eV=0;eV=0;eg--){var eL=(0|eu.words[em.length+eg])*67108864+(0|eu.words[em.length+eg-1]);for(eL=Math.min(eL/eH|0,67108863),eu._ishlnsubmul(em,eL,eg);0!==eu.negative;)eL--,eu.negative=0,eu._ishlnsubmul(em,1,eg),eu.isZero()||(eu.negative^=1);es&&(es.words[eg]=eL)}return es&&es.strip(),eu.strip(),"div"!==ei&&0!==ef&&eu.iushrn(ef),{div:es||null,mod:eu}},ed.prototype.divmod=function(et,ei,es){var eu,em,eH;return(ef(!et.isZero()),this.isZero())?{div:new ed(0),mod:new ed(0)}:0!==this.negative&&0===et.negative?(eH=this.neg().divmod(et,ei),"mod"!==ei&&(eu=eH.div.neg()),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.iadd(et)),{div:eu,mod:em}):0===this.negative&&0!==et.negative?(eH=this.divmod(et.neg(),ei),"mod"!==ei&&(eu=eH.div.neg()),{div:eu,mod:eH.mod}):(this.negative&et.negative)!=0?(eH=this.neg().divmod(et.neg(),ei),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.isub(et)),{div:eH.div,mod:em}):et.length>this.length||0>this.cmp(et)?{div:new ed(0),mod:this}:1===et.length?"div"===ei?{div:this.divn(et.words[0]),mod:null}:"mod"===ei?{div:null,mod:new ed(this.modn(et.words[0]))}:{div:this.divn(et.words[0]),mod:new ed(this.modn(et.words[0]))}:this._wordDiv(et,ei)},ed.prototype.div=function(et){return this.divmod(et,"div",!1).div},ed.prototype.mod=function(et){return this.divmod(et,"mod",!1).mod},ed.prototype.umod=function(et){return this.divmod(et,"mod",!0).mod},ed.prototype.divRound=function(et){var ei=this.divmod(et);if(ei.mod.isZero())return ei.div;var es=0!==ei.div.negative?ei.mod.isub(et):ei.mod,ef=et.ushrn(1),eu=et.andln(1),ed=es.cmp(ef);return ed<0||1===eu&&0===ed?ei.div:0!==ei.div.negative?ei.div.isubn(1):ei.div.iaddn(1)},ed.prototype.modn=function(et){ef(et<=67108863);for(var ei=67108864%et,es=0,eu=this.length-1;eu>=0;eu--)es=(ei*es+(0|this.words[eu]))%et;return es},ed.prototype.idivn=function(et){ef(et<=67108863);for(var ei=0,es=this.length-1;es>=0;es--){var eu=(0|this.words[es])+67108864*ei;this.words[es]=eu/et|0,ei=eu%et}return this.strip()},ed.prototype.divn=function(et){return this.clone().idivn(et)},ed.prototype.egcd=function(et){ef(0===et.negative),ef(!et.isZero());var ei=this,es=et.clone();ei=0!==ei.negative?ei.umod(et):ei.clone();for(var eu=new ed(1),em=new ed(0),eH=new ed(0),ez=new ed(1),eV=0;ei.isEven()&&es.isEven();)ei.iushrn(1),es.iushrn(1),++eV;for(var eM=es.clone(),eg=ei.clone();!ei.isZero();){for(var eL=0,eb=1;(ei.words[0]&eb)==0&&eL<26;++eL,eb<<=1);if(eL>0)for(ei.iushrn(eL);eL-- >0;)(eu.isOdd()||em.isOdd())&&(eu.iadd(eM),em.isub(eg)),eu.iushrn(1),em.iushrn(1);for(var ey=0,eC=1;(es.words[0]&eC)==0&&ey<26;++ey,eC<<=1);if(ey>0)for(es.iushrn(ey);ey-- >0;)(eH.isOdd()||ez.isOdd())&&(eH.iadd(eM),ez.isub(eg)),eH.iushrn(1),ez.iushrn(1);ei.cmp(es)>=0?(ei.isub(es),eu.isub(eH),em.isub(ez)):(es.isub(ei),eH.isub(eu),ez.isub(em))}return{a:eH,b:ez,gcd:es.iushln(eV)}},ed.prototype._invmp=function(et){ef(0===et.negative),ef(!et.isZero());var ei,es=this,eu=et.clone();es=0!==es.negative?es.umod(et):es.clone();for(var em=new ed(1),eH=new ed(0),ez=eu.clone();es.cmpn(1)>0&&eu.cmpn(1)>0;){for(var eV=0,eM=1;(es.words[0]&eM)==0&&eV<26;++eV,eM<<=1);if(eV>0)for(es.iushrn(eV);eV-- >0;)em.isOdd()&&em.iadd(ez),em.iushrn(1);for(var eg=0,eL=1;(eu.words[0]&eL)==0&&eg<26;++eg,eL<<=1);if(eg>0)for(eu.iushrn(eg);eg-- >0;)eH.isOdd()&&eH.iadd(ez),eH.iushrn(1);es.cmp(eu)>=0?(es.isub(eu),em.isub(eH)):(eu.isub(es),eH.isub(em))}return 0>(ei=0===es.cmpn(1)?em:eH).cmpn(0)&&ei.iadd(et),ei},ed.prototype.gcd=function(et){if(this.isZero())return et.abs();if(et.isZero())return this.abs();var ei=this.clone(),es=et.clone();ei.negative=0,es.negative=0;for(var ef=0;ei.isEven()&&es.isEven();ef++)ei.iushrn(1),es.iushrn(1);for(;;){for(;ei.isEven();)ei.iushrn(1);for(;es.isEven();)es.iushrn(1);var eu=ei.cmp(es);if(eu<0){var ed=ei;ei=es,es=ed}else if(0===eu||0===es.cmpn(1))break;ei.isub(es)}return es.iushln(ef)},ed.prototype.invm=function(et){return this.egcd(et).a.umod(et)},ed.prototype.isEven=function(){return(1&this.words[0])==0},ed.prototype.isOdd=function(){return(1&this.words[0])==1},ed.prototype.andln=function(et){return this.words[0]&et},ed.prototype.bincn=function(et){ef("number"==typeof et);var ei=et%26,es=(et-ei)/26,eu=1<>>26,eH&=67108863,this.words[em]=eH}return 0!==ed&&(this.words[em]=ed,this.length++),this},ed.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},ed.prototype.cmpn=function(et){var ei,es=et<0;if(0!==this.negative&&!es)return -1;if(0===this.negative&&es)return 1;if(this.strip(),this.length>1)ei=1;else{es&&(et=-et),ef(et<=67108863,"Number is too big");var eu=0|this.words[0];ei=eu===et?0:euet.length)return 1;if(this.length=0;es--){var ef=0|this.words[es],eu=0|et.words[es];if(ef!==eu){efeu&&(ei=1);break}}return ei},ed.prototype.gtn=function(et){return 1===this.cmpn(et)},ed.prototype.gt=function(et){return 1===this.cmp(et)},ed.prototype.gten=function(et){return this.cmpn(et)>=0},ed.prototype.gte=function(et){return this.cmp(et)>=0},ed.prototype.ltn=function(et){return -1===this.cmpn(et)},ed.prototype.lt=function(et){return -1===this.cmp(et)},ed.prototype.lten=function(et){return 0>=this.cmpn(et)},ed.prototype.lte=function(et){return 0>=this.cmp(et)},ed.prototype.eqn=function(et){return 0===this.cmpn(et)},ed.prototype.eq=function(et){return 0===this.cmp(et)},ed.red=function(et){return new eB(et)},ed.prototype.toRed=function(et){return ef(!this.red,"Already a number in reduction context"),ef(0===this.negative,"red works only with positives"),et.convertTo(this)._forceRed(et)},ed.prototype.fromRed=function(){return ef(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},ed.prototype._forceRed=function(et){return this.red=et,this},ed.prototype.forceRed=function(et){return ef(!this.red,"Already a number in reduction context"),this._forceRed(et)},ed.prototype.redAdd=function(et){return ef(this.red,"redAdd works only with red numbers"),this.red.add(this,et)},ed.prototype.redIAdd=function(et){return ef(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,et)},ed.prototype.redSub=function(et){return ef(this.red,"redSub works only with red numbers"),this.red.sub(this,et)},ed.prototype.redISub=function(et){return ef(this.red,"redISub works only with red numbers"),this.red.isub(this,et)},ed.prototype.redShl=function(et){return ef(this.red,"redShl works only with red numbers"),this.red.shl(this,et)},ed.prototype.redMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.mul(this,et)},ed.prototype.redIMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.imul(this,et)},ed.prototype.redSqr=function(){return ef(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},ed.prototype.redISqr=function(){return ef(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},ed.prototype.redSqrt=function(){return ef(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},ed.prototype.redInvm=function(){return ef(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},ed.prototype.redNeg=function(){return ef(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},ed.prototype.redPow=function(et){return ef(this.red&&!et.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,et)};var eN={k256:null,p224:null,p192:null,p25519:null};function eS(et,ei){this.name=et,this.p=new ed(ei,16),this.n=this.p.bitLength(),this.k=new ed(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function eA(){eS.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function e_(){eS.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function eE(){eS.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function eP(){eS.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function eB(et){if("string"==typeof et){var ei=ed._prime(et);this.m=ei.p,this.prime=ei}else ef(et.gtn(1),"modulus must be greater than 1"),this.m=et,this.prime=null}function eT(et){eB.call(this,et),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new ed(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)}eS.prototype._tmp=function(){var et=new ed(null);return et.words=Array(Math.ceil(this.n/13)),et},eS.prototype.ireduce=function(et){var ei,es=et;do this.split(es,this.tmp),ei=(es=(es=this.imulK(es)).iadd(this.tmp)).bitLength();while(ei>this.n);var ef=ei0?es.isub(this.p):void 0!==es.strip?es.strip():es._strip(),es},eS.prototype.split=function(et,ei){et.iushrn(this.n,0,ei)},eS.prototype.imulK=function(et){return et.imul(this.k)},eu(eA,eS),eA.prototype.split=function(et,ei){for(var es=4194303,ef=Math.min(et.length,9),eu=0;eu>>22,ed=em}ed>>>=22,et.words[eu-10]=ed,0===ed&&et.length>10?et.length-=10:et.length-=9},eA.prototype.imulK=function(et){et.words[et.length]=0,et.words[et.length+1]=0,et.length+=2;for(var ei=0,es=0;es>>=26,et.words[es]=eu,ei=ef}return 0!==ei&&(et.words[et.length++]=ei),et},ed._prime=function(et){var ei;if(eN[et])return eN[et];if("k256"===et)ei=new eA;else if("p224"===et)ei=new e_;else if("p192"===et)ei=new eE;else if("p25519"===et)ei=new eP;else throw Error("Unknown prime "+et);return eN[et]=ei,ei},eB.prototype._verify1=function(et){ef(0===et.negative,"red works only with positives"),ef(et.red,"red works only with red numbers")},eB.prototype._verify2=function(et,ei){ef((et.negative|ei.negative)==0,"red works only with positives"),ef(et.red&&et.red===ei.red,"red works only with red numbers")},eB.prototype.imod=function(et){return this.prime?this.prime.ireduce(et)._forceRed(this):et.umod(this.m)._forceRed(this)},eB.prototype.neg=function(et){return et.isZero()?et.clone():this.m.sub(et)._forceRed(this)},eB.prototype.add=function(et,ei){this._verify2(et,ei);var es=et.add(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es._forceRed(this)},eB.prototype.iadd=function(et,ei){this._verify2(et,ei);var es=et.iadd(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es},eB.prototype.sub=function(et,ei){this._verify2(et,ei);var es=et.sub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es._forceRed(this)},eB.prototype.isub=function(et,ei){this._verify2(et,ei);var es=et.isub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es},eB.prototype.shl=function(et,ei){return this._verify1(et),this.imod(et.ushln(ei))},eB.prototype.imul=function(et,ei){return this._verify2(et,ei),this.imod(et.imul(ei))},eB.prototype.mul=function(et,ei){return this._verify2(et,ei),this.imod(et.mul(ei))},eB.prototype.isqr=function(et){return this.imul(et,et.clone())},eB.prototype.sqr=function(et){return this.mul(et,et)},eB.prototype.sqrt=function(et){if(et.isZero())return et.clone();var ei=this.m.andln(3);if(ef(ei%2==1),3===ei){var es=this.m.add(new ed(1)).iushrn(2);return this.pow(et,es)}for(var eu=this.m.subn(1),em=0;!eu.isZero()&&0===eu.andln(1);)em++,eu.iushrn(1);ef(!eu.isZero());var eH=new ed(1).toRed(this),ez=eH.redNeg(),eV=this.m.subn(1).iushrn(1),eM=this.m.bitLength();for(eM=new ed(2*eM*eM).toRed(this);0!==this.pow(eM,eV).cmp(ez);)eM.redIAdd(ez);for(var eg=this.pow(eM,eu),eL=this.pow(et,eu.addn(1).iushrn(1)),eb=this.pow(et,eu),ey=em;0!==eb.cmp(eH);){for(var eC=eb,ex=0;0!==eC.cmp(eH);ex++)eC=eC.redSqr();ef(ex=0;eu--){for(var eM=ei.words[eu],eg=eV-1;eg>=0;eg--){var eL=eM>>eg&1;if(em!==ef[0]&&(em=this.sqr(em)),0===eL&&0===eH){ez=0;continue}eH<<=1,eH|=eL,(++ez===es||0===eu&&0===eg)&&(em=this.mul(em,ef[eH]),ez=0,eH=0)}eV=26}return em},eB.prototype.convertTo=function(et){var ei=et.umod(this.m);return ei===et?ei.clone():ei},eB.prototype.convertFrom=function(et){var ei=et.clone();return ei.red=null,ei},ed.mont=function(et){return new eT(et)},eu(eT,eB),eT.prototype.convertTo=function(et){return this.imod(et.ushln(this.shift))},eT.prototype.convertFrom=function(et){var ei=this.imod(et.mul(this.rinv));return ei.red=null,ei},eT.prototype.imul=function(et,ei){if(et.isZero()||ei.isZero())return et.words[0]=0,et.length=1,et;var es=et.imul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),ed=eu;return eu.cmp(this.m)>=0?ed=eu.isub(this.m):0>eu.cmpn(0)&&(ed=eu.iadd(this.m)),ed._forceRed(this)},eT.prototype.mul=function(et,ei){if(et.isZero()||ei.isZero())return new ed(0)._forceRed(this);var es=et.mul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),em=eu;return eu.cmp(this.m)>=0?em=eu.isub(this.m):0>eu.cmpn(0)&&(em=eu.iadd(this.m)),em._forceRed(this)},eT.prototype.invm=function(et){return this.imod(et._invmp(this.m).mul(this.r2))._forceRed(this)}}(et=es.nmd(et),this)},1670:function(et,ei,es){!function(et,ei){"use strict";function ef(et,ei){if(!et)throw Error(ei||"Assertion failed")}function eu(et,ei){et.super_=ei;var es=function(){};es.prototype=ei.prototype,et.prototype=new es,et.prototype.constructor=et}function ed(et,ei,es){if(ed.isBN(et))return et;this.negative=0,this.words=null,this.length=0,this.red=null,null!==et&&(("le"===ei||"be"===ei)&&(es=ei,ei=10),this._init(et||0,ei||10,es||"be"))}"object"==typeof et?et.exports=ed:ei.BN=ed,ed.BN=ed,ed.wordSize=26;try{eM=es(4300).Buffer}catch(et){}function em(et,ei,es){for(var eu=0,ed=Math.min(et.length,es),em=0,eH=ei;eH=49&&eV<=54?eV-49+10:eV>=17&&eV<=22?eV-17+10:eV,em|=ez}return ef(!(240&em),"Invalid character in "+et),eu}function eH(et,ei,es,eu){for(var ed=0,em=0,eH=Math.min(et.length,es),ez=ei;ez=49?eV-49+10:eV>=17?eV-17+10:eV,ef(eV>=0&&em"}ed.isBN=function(et){return et instanceof ed||null!==et&&"object"==typeof et&&et.constructor.wordSize===ed.wordSize&&Array.isArray(et.words)},ed.max=function(et,ei){return et.cmp(ei)>0?et:ei},ed.min=function(et,ei){return 0>et.cmp(ei)?et:ei},ed.prototype._init=function(et,ei,es){if("number"==typeof et)return this._initNumber(et,ei,es);if("object"==typeof et)return this._initArray(et,ei,es);"hex"===ei&&(ei=16),ef(ei===(0|ei)&&ei>=2&&ei<=36);var eu=0;"-"===(et=et.toString().replace(/\s+/g,""))[0]&&eu++,16===ei?this._parseHex(et,eu):this._parseBase(et,ei,eu),"-"===et[0]&&(this.negative=1),this._strip(),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initNumber=function(et,ei,es){et<0&&(this.negative=1,et=-et),et<67108864?(this.words=[67108863&et],this.length=1):et<4503599627370496?(this.words=[67108863&et,et/67108864&67108863],this.length=2):(ef(et<9007199254740992),this.words=[67108863&et,et/67108864&67108863,1],this.length=3),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initArray=function(et,ei,es){if(ef("number"==typeof et.length),et.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(et.length/3),this.words=Array(this.length);for(var eu,ed,em=0;em=0;em-=3)ed=et[em]|et[em-1]<<8|et[em-2]<<16,this.words[eu]|=ed<>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);else if("le"===es)for(em=0,eu=0;em>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);return this._strip()},ed.prototype._parseHex=function(et,ei){this.length=Math.ceil((et.length-ei)/6),this.words=Array(this.length);for(var es,ef,eu=0;eu=ei;eu-=6)ef=em(et,eu,eu+6),this.words[es]|=ef<>>26-ed&4194303,(ed+=24)>=26&&(ed-=26,es++);eu+6!==ei&&(ef=em(et,ei,eu+6),this.words[es]|=ef<>>26-ed&4194303),this._strip()},ed.prototype._parseBase=function(et,ei,es){this.words=[0],this.length=1;for(var ef=0,eu=1;eu<=67108863;eu*=ei)ef++;ef--,eu=eu/ei|0;for(var ed=et.length-es,em=ed%ef,ez=Math.min(ed,ed-em)+es,eV=0,eM=es;eM1&&0===this.words[this.length-1];)this.length--;return this._normSign()},ed.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for?ed.prototype[Symbol.for("nodejs.util.inspect.custom")]=eV:ed.prototype.inspect=eV;var eM,eg=["","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"],eL=[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],eb=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];ed.prototype.toString=function(et,ei){if(ei=0|ei||1,16===(et=et||10)||"hex"===et){es="";for(var es,eu=0,ed=0,em=0;em>>24-eu&16777215)||em!==this.length-1?eg[6-ez.length]+ez+es:ez+es,(eu+=2)>=26&&(eu-=26,em--)}for(0!==ed&&(es=ed.toString(16)+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}if(et===(0|et)&&et>=2&&et<=36){var eV=eL[et],eM=eb[et];es="";var ey=this.clone();for(ey.negative=0;!ey.isZero();){var eC=ey.modrn(eM).toString(et);es=(ey=ey.idivn(eM)).isZero()?eC+es:eg[eV-eC.length]+eC+es}for(this.isZero()&&(es="0"+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}ef(!1,"Base should be between 2 and 36")},ed.prototype.toNumber=function(){var et=this.words[0];return 2===this.length?et+=67108864*this.words[1]:3===this.length&&1===this.words[2]?et+=4503599627370496+67108864*this.words[1]:this.length>2&&ef(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-et:et},ed.prototype.toJSON=function(){return this.toString(16,2)},eM&&(ed.prototype.toBuffer=function(et,ei){return this.toArrayLike(eM,et,ei)}),ed.prototype.toArray=function(et,ei){return this.toArrayLike(Array,et,ei)};var ey=function(et,ei){return et.allocUnsafe?et.allocUnsafe(ei):new et(ei)};function eC(et){for(var ei=Array(et.bitLength()),es=0;es>>eu&1}return ei}function ex(et,ei,es){es.negative=ei.negative^et.negative;var ef=et.length+ei.length|0;es.length=ef,ef=ef-1|0;var eu=0|et.words[0],ed=0|ei.words[0],em=eu*ed,eH=67108863&em,ez=em/67108864|0;es.words[0]=eH;for(var eV=1;eV>>26,eg=67108863&ez,eL=Math.min(eV,ei.length-1),eb=Math.max(0,eV-et.length+1);eb<=eL;eb++){var ey=eV-eb|0;eM+=(em=(eu=0|et.words[ey])*(ed=0|ei.words[eb])+eg)/67108864|0,eg=67108863&em}es.words[eV]=0|eg,ez=0|eM}return 0!==ez?es.words[eV]=0|ez:es.length--,es._strip()}ed.prototype.toArrayLike=function(et,ei,es){this._strip();var eu=this.byteLength(),ed=es||Math.max(1,eu);ef(eu<=ed,"byte array longer than desired length"),ef(ed>0,"Requested array length <= 0");var em=ey(et,ed);return this["_toArrayLike"+("le"===ei?"LE":"BE")](em,eu),em},ed.prototype._toArrayLikeLE=function(et,ei){for(var es=0,ef=0,eu=0,ed=0;eu>8&255),es>16&255),6===ed?(es>24&255),ef=0,ed=0):(ef=em>>>24,ed+=2)}if(es=0&&(et[es--]=em>>8&255),es>=0&&(et[es--]=em>>16&255),6===ed?(es>=0&&(et[es--]=em>>24&255),ef=0,ed=0):(ef=em>>>24,ed+=2)}if(es>=0)for(et[es--]=ef;es>=0;)et[es--]=0},Math.clz32?ed.prototype._countBits=function(et){return 32-Math.clz32(et)}:ed.prototype._countBits=function(et){var ei=et,es=0;return ei>=4096&&(es+=13,ei>>>=13),ei>=64&&(es+=7,ei>>>=7),ei>=8&&(es+=4,ei>>>=4),ei>=2&&(es+=2,ei>>>=2),es+ei},ed.prototype._zeroBits=function(et){if(0===et)return 26;var ei=et,es=0;return(8191&ei)==0&&(es+=13,ei>>>=13),(127&ei)==0&&(es+=7,ei>>>=7),(15&ei)==0&&(es+=4,ei>>>=4),(3&ei)==0&&(es+=2,ei>>>=2),(1&ei)==0&&es++,es},ed.prototype.bitLength=function(){var et=this.words[this.length-1],ei=this._countBits(et);return(this.length-1)*26+ei},ed.prototype.zeroBits=function(){if(this.isZero())return 0;for(var et=0,ei=0;eiet.length?this.clone().ior(et):et.clone().ior(this)},ed.prototype.uor=function(et){return this.length>et.length?this.clone().iuor(et):et.clone().iuor(this)},ed.prototype.iuand=function(et){var ei;ei=this.length>et.length?et:this;for(var es=0;eset.length?this.clone().iand(et):et.clone().iand(this)},ed.prototype.uand=function(et){return this.length>et.length?this.clone().iuand(et):et.clone().iuand(this)},ed.prototype.iuxor=function(et){this.length>et.length?(ei=this,es=et):(ei=et,es=this);for(var ei,es,ef=0;efet.length?this.clone().ixor(et):et.clone().ixor(this)},ed.prototype.uxor=function(et){return this.length>et.length?this.clone().iuxor(et):et.clone().iuxor(this)},ed.prototype.inotn=function(et){ef("number"==typeof et&&et>=0);var ei=0|Math.ceil(et/26),es=et%26;this._expand(ei),es>0&&ei--;for(var eu=0;eu0&&(this.words[eu]=~this.words[eu]&67108863>>26-es),this._strip()},ed.prototype.notn=function(et){return this.clone().inotn(et)},ed.prototype.setn=function(et,ei){ef("number"==typeof et&&et>=0);var es=et/26|0,eu=et%26;return this._expand(es+1),ei?this.words[es]=this.words[es]|1<et.length?(es=this,ef=et):(es=et,ef=this);for(var ei,es,ef,eu=0,ed=0;ed>>26;for(;0!==eu&&ed>>26;if(this.length=es.length,0!==eu)this.words[this.length]=eu,this.length++;else if(es!==this)for(;edet.length?this.clone().iadd(et):et.clone().iadd(this)},ed.prototype.isub=function(et){if(0!==et.negative){et.negative=0;var ei,es,ef=this.iadd(et);return et.negative=1,ef._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(et),this.negative=1,this._normSign();var eu=this.cmp(et);if(0===eu)return this.negative=0,this.length=1,this.words[0]=0,this;eu>0?(ei=this,es=et):(ei=et,es=this);for(var ed=0,em=0;em>26,this.words[em]=67108863&ef;for(;0!==ed&&em>26,this.words[em]=67108863&ef;if(0===ed&&em>>13,eb=0|em[1],ey=8191&eb,eC=eb>>>13,ex=0|em[2],ew=8191&ex,eN=ex>>>13,eS=0|em[3],eA=8191&eS,e_=eS>>>13,eE=0|em[4],eP=8191&eE,eB=eE>>>13,eT=0|em[5],eI=8191&eT,eR=eT>>>13,eO=0|em[6],ej=8191&eO,eD=eO>>>13,eF=0|em[7],eU=8191&eF,eq=eF>>>13,eZ=0|em[8],eG=8191&eZ,eW=eZ>>>13,eK=0|em[9],e$=8191&eK,eJ=eK>>>13,eY=0|eH[0],eX=8191&eY,eQ=eY>>>13,e1=0|eH[1],e2=8191&e1,e4=e1>>>13,e3=0|eH[2],e6=8191&e3,e0=e3>>>13,e8=0|eH[3],e5=8191&e8,e7=e8>>>13,e9=0|eH[4],cc=8191&e9,ci=e9>>>13,cs=0|eH[5],cf=8191&cs,cd=cs>>>13,cm=0|eH[6],cH=8191&cm,cz=cm>>>13,cV=0|eH[7],cM=8191&cV,cg=cV>>>13,cL=0|eH[8],cy=8191&cL,cC=cL>>>13,cx=0|eH[9],cw=8191&cx,ck=cx>>>13;es.negative=et.negative^ei.negative,es.length=19;var cN=(eV+(ef=Math.imul(eg,eX))|0)+((8191&(eu=(eu=Math.imul(eg,eQ))+Math.imul(eL,eX)|0))<<13)|0;eV=((ed=Math.imul(eL,eQ))+(eu>>>13)|0)+(cN>>>26)|0,cN&=67108863,ef=Math.imul(ey,eX),eu=(eu=Math.imul(ey,eQ))+Math.imul(eC,eX)|0,ed=Math.imul(eC,eQ);var cS=(eV+(ef=ef+Math.imul(eg,e2)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e4)|0)+Math.imul(eL,e2)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e4)|0)+(eu>>>13)|0)+(cS>>>26)|0,cS&=67108863,ef=Math.imul(ew,eX),eu=(eu=Math.imul(ew,eQ))+Math.imul(eN,eX)|0,ed=Math.imul(eN,eQ),ef=ef+Math.imul(ey,e2)|0,eu=(eu=eu+Math.imul(ey,e4)|0)+Math.imul(eC,e2)|0,ed=ed+Math.imul(eC,e4)|0;var cA=(eV+(ef=ef+Math.imul(eg,e6)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e0)|0)+Math.imul(eL,e6)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e0)|0)+(eu>>>13)|0)+(cA>>>26)|0,cA&=67108863,ef=Math.imul(eA,eX),eu=(eu=Math.imul(eA,eQ))+Math.imul(e_,eX)|0,ed=Math.imul(e_,eQ),ef=ef+Math.imul(ew,e2)|0,eu=(eu=eu+Math.imul(ew,e4)|0)+Math.imul(eN,e2)|0,ed=ed+Math.imul(eN,e4)|0,ef=ef+Math.imul(ey,e6)|0,eu=(eu=eu+Math.imul(ey,e0)|0)+Math.imul(eC,e6)|0,ed=ed+Math.imul(eC,e0)|0;var c_=(eV+(ef=ef+Math.imul(eg,e5)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e7)|0)+Math.imul(eL,e5)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e7)|0)+(eu>>>13)|0)+(c_>>>26)|0,c_&=67108863,ef=Math.imul(eP,eX),eu=(eu=Math.imul(eP,eQ))+Math.imul(eB,eX)|0,ed=Math.imul(eB,eQ),ef=ef+Math.imul(eA,e2)|0,eu=(eu=eu+Math.imul(eA,e4)|0)+Math.imul(e_,e2)|0,ed=ed+Math.imul(e_,e4)|0,ef=ef+Math.imul(ew,e6)|0,eu=(eu=eu+Math.imul(ew,e0)|0)+Math.imul(eN,e6)|0,ed=ed+Math.imul(eN,e0)|0,ef=ef+Math.imul(ey,e5)|0,eu=(eu=eu+Math.imul(ey,e7)|0)+Math.imul(eC,e5)|0,ed=ed+Math.imul(eC,e7)|0;var cE=(eV+(ef=ef+Math.imul(eg,cc)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ci)|0)+Math.imul(eL,cc)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ci)|0)+(eu>>>13)|0)+(cE>>>26)|0,cE&=67108863,ef=Math.imul(eI,eX),eu=(eu=Math.imul(eI,eQ))+Math.imul(eR,eX)|0,ed=Math.imul(eR,eQ),ef=ef+Math.imul(eP,e2)|0,eu=(eu=eu+Math.imul(eP,e4)|0)+Math.imul(eB,e2)|0,ed=ed+Math.imul(eB,e4)|0,ef=ef+Math.imul(eA,e6)|0,eu=(eu=eu+Math.imul(eA,e0)|0)+Math.imul(e_,e6)|0,ed=ed+Math.imul(e_,e0)|0,ef=ef+Math.imul(ew,e5)|0,eu=(eu=eu+Math.imul(ew,e7)|0)+Math.imul(eN,e5)|0,ed=ed+Math.imul(eN,e7)|0,ef=ef+Math.imul(ey,cc)|0,eu=(eu=eu+Math.imul(ey,ci)|0)+Math.imul(eC,cc)|0,ed=ed+Math.imul(eC,ci)|0;var cP=(eV+(ef=ef+Math.imul(eg,cf)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cd)|0)+Math.imul(eL,cf)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cd)|0)+(eu>>>13)|0)+(cP>>>26)|0,cP&=67108863,ef=Math.imul(ej,eX),eu=(eu=Math.imul(ej,eQ))+Math.imul(eD,eX)|0,ed=Math.imul(eD,eQ),ef=ef+Math.imul(eI,e2)|0,eu=(eu=eu+Math.imul(eI,e4)|0)+Math.imul(eR,e2)|0,ed=ed+Math.imul(eR,e4)|0,ef=ef+Math.imul(eP,e6)|0,eu=(eu=eu+Math.imul(eP,e0)|0)+Math.imul(eB,e6)|0,ed=ed+Math.imul(eB,e0)|0,ef=ef+Math.imul(eA,e5)|0,eu=(eu=eu+Math.imul(eA,e7)|0)+Math.imul(e_,e5)|0,ed=ed+Math.imul(e_,e7)|0,ef=ef+Math.imul(ew,cc)|0,eu=(eu=eu+Math.imul(ew,ci)|0)+Math.imul(eN,cc)|0,ed=ed+Math.imul(eN,ci)|0,ef=ef+Math.imul(ey,cf)|0,eu=(eu=eu+Math.imul(ey,cd)|0)+Math.imul(eC,cf)|0,ed=ed+Math.imul(eC,cd)|0;var cB=(eV+(ef=ef+Math.imul(eg,cH)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cz)|0)+Math.imul(eL,cH)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cz)|0)+(eu>>>13)|0)+(cB>>>26)|0,cB&=67108863,ef=Math.imul(eU,eX),eu=(eu=Math.imul(eU,eQ))+Math.imul(eq,eX)|0,ed=Math.imul(eq,eQ),ef=ef+Math.imul(ej,e2)|0,eu=(eu=eu+Math.imul(ej,e4)|0)+Math.imul(eD,e2)|0,ed=ed+Math.imul(eD,e4)|0,ef=ef+Math.imul(eI,e6)|0,eu=(eu=eu+Math.imul(eI,e0)|0)+Math.imul(eR,e6)|0,ed=ed+Math.imul(eR,e0)|0,ef=ef+Math.imul(eP,e5)|0,eu=(eu=eu+Math.imul(eP,e7)|0)+Math.imul(eB,e5)|0,ed=ed+Math.imul(eB,e7)|0,ef=ef+Math.imul(eA,cc)|0,eu=(eu=eu+Math.imul(eA,ci)|0)+Math.imul(e_,cc)|0,ed=ed+Math.imul(e_,ci)|0,ef=ef+Math.imul(ew,cf)|0,eu=(eu=eu+Math.imul(ew,cd)|0)+Math.imul(eN,cf)|0,ed=ed+Math.imul(eN,cd)|0,ef=ef+Math.imul(ey,cH)|0,eu=(eu=eu+Math.imul(ey,cz)|0)+Math.imul(eC,cH)|0,ed=ed+Math.imul(eC,cz)|0;var cT=(eV+(ef=ef+Math.imul(eg,cM)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cg)|0)+Math.imul(eL,cM)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cg)|0)+(eu>>>13)|0)+(cT>>>26)|0,cT&=67108863,ef=Math.imul(eG,eX),eu=(eu=Math.imul(eG,eQ))+Math.imul(eW,eX)|0,ed=Math.imul(eW,eQ),ef=ef+Math.imul(eU,e2)|0,eu=(eu=eu+Math.imul(eU,e4)|0)+Math.imul(eq,e2)|0,ed=ed+Math.imul(eq,e4)|0,ef=ef+Math.imul(ej,e6)|0,eu=(eu=eu+Math.imul(ej,e0)|0)+Math.imul(eD,e6)|0,ed=ed+Math.imul(eD,e0)|0,ef=ef+Math.imul(eI,e5)|0,eu=(eu=eu+Math.imul(eI,e7)|0)+Math.imul(eR,e5)|0,ed=ed+Math.imul(eR,e7)|0,ef=ef+Math.imul(eP,cc)|0,eu=(eu=eu+Math.imul(eP,ci)|0)+Math.imul(eB,cc)|0,ed=ed+Math.imul(eB,ci)|0,ef=ef+Math.imul(eA,cf)|0,eu=(eu=eu+Math.imul(eA,cd)|0)+Math.imul(e_,cf)|0,ed=ed+Math.imul(e_,cd)|0,ef=ef+Math.imul(ew,cH)|0,eu=(eu=eu+Math.imul(ew,cz)|0)+Math.imul(eN,cH)|0,ed=ed+Math.imul(eN,cz)|0,ef=ef+Math.imul(ey,cM)|0,eu=(eu=eu+Math.imul(ey,cg)|0)+Math.imul(eC,cM)|0,ed=ed+Math.imul(eC,cg)|0;var cI=(eV+(ef=ef+Math.imul(eg,cy)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cC)|0)+Math.imul(eL,cy)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cC)|0)+(eu>>>13)|0)+(cI>>>26)|0,cI&=67108863,ef=Math.imul(e$,eX),eu=(eu=Math.imul(e$,eQ))+Math.imul(eJ,eX)|0,ed=Math.imul(eJ,eQ),ef=ef+Math.imul(eG,e2)|0,eu=(eu=eu+Math.imul(eG,e4)|0)+Math.imul(eW,e2)|0,ed=ed+Math.imul(eW,e4)|0,ef=ef+Math.imul(eU,e6)|0,eu=(eu=eu+Math.imul(eU,e0)|0)+Math.imul(eq,e6)|0,ed=ed+Math.imul(eq,e0)|0,ef=ef+Math.imul(ej,e5)|0,eu=(eu=eu+Math.imul(ej,e7)|0)+Math.imul(eD,e5)|0,ed=ed+Math.imul(eD,e7)|0,ef=ef+Math.imul(eI,cc)|0,eu=(eu=eu+Math.imul(eI,ci)|0)+Math.imul(eR,cc)|0,ed=ed+Math.imul(eR,ci)|0,ef=ef+Math.imul(eP,cf)|0,eu=(eu=eu+Math.imul(eP,cd)|0)+Math.imul(eB,cf)|0,ed=ed+Math.imul(eB,cd)|0,ef=ef+Math.imul(eA,cH)|0,eu=(eu=eu+Math.imul(eA,cz)|0)+Math.imul(e_,cH)|0,ed=ed+Math.imul(e_,cz)|0,ef=ef+Math.imul(ew,cM)|0,eu=(eu=eu+Math.imul(ew,cg)|0)+Math.imul(eN,cM)|0,ed=ed+Math.imul(eN,cg)|0,ef=ef+Math.imul(ey,cy)|0,eu=(eu=eu+Math.imul(ey,cC)|0)+Math.imul(eC,cy)|0,ed=ed+Math.imul(eC,cC)|0;var cR=(eV+(ef=ef+Math.imul(eg,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ck)|0)+Math.imul(eL,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ck)|0)+(eu>>>13)|0)+(cR>>>26)|0,cR&=67108863,ef=Math.imul(e$,e2),eu=(eu=Math.imul(e$,e4))+Math.imul(eJ,e2)|0,ed=Math.imul(eJ,e4),ef=ef+Math.imul(eG,e6)|0,eu=(eu=eu+Math.imul(eG,e0)|0)+Math.imul(eW,e6)|0,ed=ed+Math.imul(eW,e0)|0,ef=ef+Math.imul(eU,e5)|0,eu=(eu=eu+Math.imul(eU,e7)|0)+Math.imul(eq,e5)|0,ed=ed+Math.imul(eq,e7)|0,ef=ef+Math.imul(ej,cc)|0,eu=(eu=eu+Math.imul(ej,ci)|0)+Math.imul(eD,cc)|0,ed=ed+Math.imul(eD,ci)|0,ef=ef+Math.imul(eI,cf)|0,eu=(eu=eu+Math.imul(eI,cd)|0)+Math.imul(eR,cf)|0,ed=ed+Math.imul(eR,cd)|0,ef=ef+Math.imul(eP,cH)|0,eu=(eu=eu+Math.imul(eP,cz)|0)+Math.imul(eB,cH)|0,ed=ed+Math.imul(eB,cz)|0,ef=ef+Math.imul(eA,cM)|0,eu=(eu=eu+Math.imul(eA,cg)|0)+Math.imul(e_,cM)|0,ed=ed+Math.imul(e_,cg)|0,ef=ef+Math.imul(ew,cy)|0,eu=(eu=eu+Math.imul(ew,cC)|0)+Math.imul(eN,cy)|0,ed=ed+Math.imul(eN,cC)|0;var cO=(eV+(ef=ef+Math.imul(ey,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ey,ck)|0)+Math.imul(eC,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eC,ck)|0)+(eu>>>13)|0)+(cO>>>26)|0,cO&=67108863,ef=Math.imul(e$,e6),eu=(eu=Math.imul(e$,e0))+Math.imul(eJ,e6)|0,ed=Math.imul(eJ,e0),ef=ef+Math.imul(eG,e5)|0,eu=(eu=eu+Math.imul(eG,e7)|0)+Math.imul(eW,e5)|0,ed=ed+Math.imul(eW,e7)|0,ef=ef+Math.imul(eU,cc)|0,eu=(eu=eu+Math.imul(eU,ci)|0)+Math.imul(eq,cc)|0,ed=ed+Math.imul(eq,ci)|0,ef=ef+Math.imul(ej,cf)|0,eu=(eu=eu+Math.imul(ej,cd)|0)+Math.imul(eD,cf)|0,ed=ed+Math.imul(eD,cd)|0,ef=ef+Math.imul(eI,cH)|0,eu=(eu=eu+Math.imul(eI,cz)|0)+Math.imul(eR,cH)|0,ed=ed+Math.imul(eR,cz)|0,ef=ef+Math.imul(eP,cM)|0,eu=(eu=eu+Math.imul(eP,cg)|0)+Math.imul(eB,cM)|0,ed=ed+Math.imul(eB,cg)|0,ef=ef+Math.imul(eA,cy)|0,eu=(eu=eu+Math.imul(eA,cC)|0)+Math.imul(e_,cy)|0,ed=ed+Math.imul(e_,cC)|0;var cj=(eV+(ef=ef+Math.imul(ew,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ew,ck)|0)+Math.imul(eN,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eN,ck)|0)+(eu>>>13)|0)+(cj>>>26)|0,cj&=67108863,ef=Math.imul(e$,e5),eu=(eu=Math.imul(e$,e7))+Math.imul(eJ,e5)|0,ed=Math.imul(eJ,e7),ef=ef+Math.imul(eG,cc)|0,eu=(eu=eu+Math.imul(eG,ci)|0)+Math.imul(eW,cc)|0,ed=ed+Math.imul(eW,ci)|0,ef=ef+Math.imul(eU,cf)|0,eu=(eu=eu+Math.imul(eU,cd)|0)+Math.imul(eq,cf)|0,ed=ed+Math.imul(eq,cd)|0,ef=ef+Math.imul(ej,cH)|0,eu=(eu=eu+Math.imul(ej,cz)|0)+Math.imul(eD,cH)|0,ed=ed+Math.imul(eD,cz)|0,ef=ef+Math.imul(eI,cM)|0,eu=(eu=eu+Math.imul(eI,cg)|0)+Math.imul(eR,cM)|0,ed=ed+Math.imul(eR,cg)|0,ef=ef+Math.imul(eP,cy)|0,eu=(eu=eu+Math.imul(eP,cC)|0)+Math.imul(eB,cy)|0,ed=ed+Math.imul(eB,cC)|0;var cD=(eV+(ef=ef+Math.imul(eA,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eA,ck)|0)+Math.imul(e_,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(e_,ck)|0)+(eu>>>13)|0)+(cD>>>26)|0,cD&=67108863,ef=Math.imul(e$,cc),eu=(eu=Math.imul(e$,ci))+Math.imul(eJ,cc)|0,ed=Math.imul(eJ,ci),ef=ef+Math.imul(eG,cf)|0,eu=(eu=eu+Math.imul(eG,cd)|0)+Math.imul(eW,cf)|0,ed=ed+Math.imul(eW,cd)|0,ef=ef+Math.imul(eU,cH)|0,eu=(eu=eu+Math.imul(eU,cz)|0)+Math.imul(eq,cH)|0,ed=ed+Math.imul(eq,cz)|0,ef=ef+Math.imul(ej,cM)|0,eu=(eu=eu+Math.imul(ej,cg)|0)+Math.imul(eD,cM)|0,ed=ed+Math.imul(eD,cg)|0,ef=ef+Math.imul(eI,cy)|0,eu=(eu=eu+Math.imul(eI,cC)|0)+Math.imul(eR,cy)|0,ed=ed+Math.imul(eR,cC)|0;var cF=(eV+(ef=ef+Math.imul(eP,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eP,ck)|0)+Math.imul(eB,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eB,ck)|0)+(eu>>>13)|0)+(cF>>>26)|0,cF&=67108863,ef=Math.imul(e$,cf),eu=(eu=Math.imul(e$,cd))+Math.imul(eJ,cf)|0,ed=Math.imul(eJ,cd),ef=ef+Math.imul(eG,cH)|0,eu=(eu=eu+Math.imul(eG,cz)|0)+Math.imul(eW,cH)|0,ed=ed+Math.imul(eW,cz)|0,ef=ef+Math.imul(eU,cM)|0,eu=(eu=eu+Math.imul(eU,cg)|0)+Math.imul(eq,cM)|0,ed=ed+Math.imul(eq,cg)|0,ef=ef+Math.imul(ej,cy)|0,eu=(eu=eu+Math.imul(ej,cC)|0)+Math.imul(eD,cy)|0,ed=ed+Math.imul(eD,cC)|0;var cU=(eV+(ef=ef+Math.imul(eI,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eI,ck)|0)+Math.imul(eR,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eR,ck)|0)+(eu>>>13)|0)+(cU>>>26)|0,cU&=67108863,ef=Math.imul(e$,cH),eu=(eu=Math.imul(e$,cz))+Math.imul(eJ,cH)|0,ed=Math.imul(eJ,cz),ef=ef+Math.imul(eG,cM)|0,eu=(eu=eu+Math.imul(eG,cg)|0)+Math.imul(eW,cM)|0,ed=ed+Math.imul(eW,cg)|0,ef=ef+Math.imul(eU,cy)|0,eu=(eu=eu+Math.imul(eU,cC)|0)+Math.imul(eq,cy)|0,ed=ed+Math.imul(eq,cC)|0;var cq=(eV+(ef=ef+Math.imul(ej,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ej,ck)|0)+Math.imul(eD,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eD,ck)|0)+(eu>>>13)|0)+(cq>>>26)|0,cq&=67108863,ef=Math.imul(e$,cM),eu=(eu=Math.imul(e$,cg))+Math.imul(eJ,cM)|0,ed=Math.imul(eJ,cg),ef=ef+Math.imul(eG,cy)|0,eu=(eu=eu+Math.imul(eG,cC)|0)+Math.imul(eW,cy)|0,ed=ed+Math.imul(eW,cC)|0;var cZ=(eV+(ef=ef+Math.imul(eU,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eU,ck)|0)+Math.imul(eq,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eq,ck)|0)+(eu>>>13)|0)+(cZ>>>26)|0,cZ&=67108863,ef=Math.imul(e$,cy),eu=(eu=Math.imul(e$,cC))+Math.imul(eJ,cy)|0,ed=Math.imul(eJ,cC);var cG=(eV+(ef=ef+Math.imul(eG,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eG,ck)|0)+Math.imul(eW,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eW,ck)|0)+(eu>>>13)|0)+(cG>>>26)|0,cG&=67108863;var cW=(eV+(ef=Math.imul(e$,cw))|0)+((8191&(eu=(eu=Math.imul(e$,ck))+Math.imul(eJ,cw)|0))<<13)|0;return eV=((ed=Math.imul(eJ,ck))+(eu>>>13)|0)+(cW>>>26)|0,cW&=67108863,ez[0]=cN,ez[1]=cS,ez[2]=cA,ez[3]=c_,ez[4]=cE,ez[5]=cP,ez[6]=cB,ez[7]=cT,ez[8]=cI,ez[9]=cR,ez[10]=cO,ez[11]=cj,ez[12]=cD,ez[13]=cF,ez[14]=cU,ez[15]=cq,ez[16]=cZ,ez[17]=cG,ez[18]=cW,0!==eV&&(ez[19]=eV,es.length++),es};function eN(et,ei,es){es.negative=ei.negative^et.negative,es.length=et.length+ei.length;for(var ef=0,eu=0,ed=0;ed>>26)|0)>>>26,em&=67108863}es.words[ed]=eH,ef=em,em=eu}return 0!==ef?es.words[ed]=ef:es.length--,es._strip()}function eS(et,ei,es){return eN(et,ei,es)}function eA(et,ei){this.x=et,this.y=ei}Math.imul||(ew=ex),ed.prototype.mulTo=function(et,ei){var es=this.length+et.length;return 10===this.length&&10===et.length?ew(this,et,ei):es<63?ex(this,et,ei):es<1024?eN(this,et,ei):eS(this,et,ei)},eA.prototype.makeRBT=function(et){for(var ei=Array(et),es=ed.prototype._countBits(et)-1,ef=0;ef>=1;return ef},eA.prototype.permute=function(et,ei,es,ef,eu,ed){for(var em=0;em>>=1)eu++;return 1<>>=13,es[2*em+1]=8191&ed,ed>>>=13;for(em=2*ei;em>=26,es+=(ed/67108864|0)+(em>>>26),this.words[eu]=67108863&em}return 0!==es&&(this.words[eu]=es,this.length++),ei?this.ineg():this},ed.prototype.muln=function(et){return this.clone().imuln(et)},ed.prototype.sqr=function(){return this.mul(this)},ed.prototype.isqr=function(){return this.imul(this.clone())},ed.prototype.pow=function(et){var ei=eC(et);if(0===ei.length)return new ed(1);for(var es=this,ef=0;ef=0);var ei,es=et%26,eu=(et-es)/26,ed=67108863>>>26-es<<26-es;if(0!==es){var em=0;for(ei=0;ei>>26-es}em&&(this.words[ei]=em,this.length++)}if(0!==eu){for(ei=this.length-1;ei>=0;ei--)this.words[ei+eu]=this.words[ei];for(ei=0;ei=0),eu=ei?(ei-ei%26)/26:0;var eu,ed=et%26,em=Math.min((et-ed)/26,this.length),eH=67108863^67108863>>>ed<em)for(this.length-=em,eV=0;eV=0&&(0!==eM||eV>=eu);eV--){var eg=0|this.words[eV];this.words[eV]=eM<<26-ed|eg>>>ed,eM=eg&eH}return ez&&0!==eM&&(ez.words[ez.length++]=eM),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},ed.prototype.ishrn=function(et,ei,es){return ef(0===this.negative),this.iushrn(et,ei,es)},ed.prototype.shln=function(et){return this.clone().ishln(et)},ed.prototype.ushln=function(et){return this.clone().iushln(et)},ed.prototype.shrn=function(et){return this.clone().ishrn(et)},ed.prototype.ushrn=function(et){return this.clone().iushrn(et)},ed.prototype.testn=function(et){ef("number"==typeof et&&et>=0);var ei=et%26,es=(et-ei)/26,eu=1<=0);var ei=et%26,es=(et-ei)/26;if(ef(0===this.negative,"imaskn works only with positive numbers"),this.length<=es)return this;if(0!==ei&&es++,this.length=Math.min(es,this.length),0!==ei){var eu=67108863^67108863>>>ei<=67108864;ei++)this.words[ei]-=67108864,ei===this.length-1?this.words[ei+1]=1:this.words[ei+1]++;return this.length=Math.max(this.length,ei+1),this},ed.prototype.isubn=function(et){if(ef("number"==typeof et),ef(et<67108864),et<0)return this.iaddn(-et);if(0!==this.negative)return this.negative=0,this.iaddn(et),this.negative=1,this;if(this.words[0]-=et,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var ei=0;ei>26)-(ez/67108864|0),this.words[eu+es]=67108863&ed}for(;eu>26,this.words[eu+es]=67108863&ed;if(0===eH)return this._strip();for(ef(-1===eH),eH=0,eu=0;eu>26,this.words[eu]=67108863&ed;return this.negative=1,this._strip()},ed.prototype._wordDiv=function(et,ei){var es,ef=this.length-et.length,eu=this.clone(),em=et,eH=0|em.words[em.length-1];0!=(ef=26-this._countBits(eH))&&(em=em.ushln(ef),eu.iushln(ef),eH=0|em.words[em.length-1]);var ez=eu.length-em.length;if("mod"!==ei){(es=new ed(null)).length=ez+1,es.words=Array(es.length);for(var eV=0;eV=0;eg--){var eL=(0|eu.words[em.length+eg])*67108864+(0|eu.words[em.length+eg-1]);for(eL=Math.min(eL/eH|0,67108863),eu._ishlnsubmul(em,eL,eg);0!==eu.negative;)eL--,eu.negative=0,eu._ishlnsubmul(em,1,eg),eu.isZero()||(eu.negative^=1);es&&(es.words[eg]=eL)}return es&&es._strip(),eu._strip(),"div"!==ei&&0!==ef&&eu.iushrn(ef),{div:es||null,mod:eu}},ed.prototype.divmod=function(et,ei,es){var eu,em,eH;return(ef(!et.isZero()),this.isZero())?{div:new ed(0),mod:new ed(0)}:0!==this.negative&&0===et.negative?(eH=this.neg().divmod(et,ei),"mod"!==ei&&(eu=eH.div.neg()),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.iadd(et)),{div:eu,mod:em}):0===this.negative&&0!==et.negative?(eH=this.divmod(et.neg(),ei),"mod"!==ei&&(eu=eH.div.neg()),{div:eu,mod:eH.mod}):(this.negative&et.negative)!=0?(eH=this.neg().divmod(et.neg(),ei),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.isub(et)),{div:eH.div,mod:em}):et.length>this.length||0>this.cmp(et)?{div:new ed(0),mod:this}:1===et.length?"div"===ei?{div:this.divn(et.words[0]),mod:null}:"mod"===ei?{div:null,mod:new ed(this.modrn(et.words[0]))}:{div:this.divn(et.words[0]),mod:new ed(this.modrn(et.words[0]))}:this._wordDiv(et,ei)},ed.prototype.div=function(et){return this.divmod(et,"div",!1).div},ed.prototype.mod=function(et){return this.divmod(et,"mod",!1).mod},ed.prototype.umod=function(et){return this.divmod(et,"mod",!0).mod},ed.prototype.divRound=function(et){var ei=this.divmod(et);if(ei.mod.isZero())return ei.div;var es=0!==ei.div.negative?ei.mod.isub(et):ei.mod,ef=et.ushrn(1),eu=et.andln(1),ed=es.cmp(ef);return ed<0||1===eu&&0===ed?ei.div:0!==ei.div.negative?ei.div.isubn(1):ei.div.iaddn(1)},ed.prototype.modrn=function(et){var ei=et<0;ei&&(et=-et),ef(et<=67108863);for(var es=67108864%et,eu=0,ed=this.length-1;ed>=0;ed--)eu=(es*eu+(0|this.words[ed]))%et;return ei?-eu:eu},ed.prototype.modn=function(et){return this.modrn(et)},ed.prototype.idivn=function(et){var ei=et<0;ei&&(et=-et),ef(et<=67108863);for(var es=0,eu=this.length-1;eu>=0;eu--){var ed=(0|this.words[eu])+67108864*es;this.words[eu]=ed/et|0,es=ed%et}return this._strip(),ei?this.ineg():this},ed.prototype.divn=function(et){return this.clone().idivn(et)},ed.prototype.egcd=function(et){ef(0===et.negative),ef(!et.isZero());var ei=this,es=et.clone();ei=0!==ei.negative?ei.umod(et):ei.clone();for(var eu=new ed(1),em=new ed(0),eH=new ed(0),ez=new ed(1),eV=0;ei.isEven()&&es.isEven();)ei.iushrn(1),es.iushrn(1),++eV;for(var eM=es.clone(),eg=ei.clone();!ei.isZero();){for(var eL=0,eb=1;(ei.words[0]&eb)==0&&eL<26;++eL,eb<<=1);if(eL>0)for(ei.iushrn(eL);eL-- >0;)(eu.isOdd()||em.isOdd())&&(eu.iadd(eM),em.isub(eg)),eu.iushrn(1),em.iushrn(1);for(var ey=0,eC=1;(es.words[0]&eC)==0&&ey<26;++ey,eC<<=1);if(ey>0)for(es.iushrn(ey);ey-- >0;)(eH.isOdd()||ez.isOdd())&&(eH.iadd(eM),ez.isub(eg)),eH.iushrn(1),ez.iushrn(1);ei.cmp(es)>=0?(ei.isub(es),eu.isub(eH),em.isub(ez)):(es.isub(ei),eH.isub(eu),ez.isub(em))}return{a:eH,b:ez,gcd:es.iushln(eV)}},ed.prototype._invmp=function(et){ef(0===et.negative),ef(!et.isZero());var ei,es=this,eu=et.clone();es=0!==es.negative?es.umod(et):es.clone();for(var em=new ed(1),eH=new ed(0),ez=eu.clone();es.cmpn(1)>0&&eu.cmpn(1)>0;){for(var eV=0,eM=1;(es.words[0]&eM)==0&&eV<26;++eV,eM<<=1);if(eV>0)for(es.iushrn(eV);eV-- >0;)em.isOdd()&&em.iadd(ez),em.iushrn(1);for(var eg=0,eL=1;(eu.words[0]&eL)==0&&eg<26;++eg,eL<<=1);if(eg>0)for(eu.iushrn(eg);eg-- >0;)eH.isOdd()&&eH.iadd(ez),eH.iushrn(1);es.cmp(eu)>=0?(es.isub(eu),em.isub(eH)):(eu.isub(es),eH.isub(em))}return 0>(ei=0===es.cmpn(1)?em:eH).cmpn(0)&&ei.iadd(et),ei},ed.prototype.gcd=function(et){if(this.isZero())return et.abs();if(et.isZero())return this.abs();var ei=this.clone(),es=et.clone();ei.negative=0,es.negative=0;for(var ef=0;ei.isEven()&&es.isEven();ef++)ei.iushrn(1),es.iushrn(1);for(;;){for(;ei.isEven();)ei.iushrn(1);for(;es.isEven();)es.iushrn(1);var eu=ei.cmp(es);if(eu<0){var ed=ei;ei=es,es=ed}else if(0===eu||0===es.cmpn(1))break;ei.isub(es)}return es.iushln(ef)},ed.prototype.invm=function(et){return this.egcd(et).a.umod(et)},ed.prototype.isEven=function(){return(1&this.words[0])==0},ed.prototype.isOdd=function(){return(1&this.words[0])==1},ed.prototype.andln=function(et){return this.words[0]&et},ed.prototype.bincn=function(et){ef("number"==typeof et);var ei=et%26,es=(et-ei)/26,eu=1<>>26,eH&=67108863,this.words[em]=eH}return 0!==ed&&(this.words[em]=ed,this.length++),this},ed.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},ed.prototype.cmpn=function(et){var ei,es=et<0;if(0!==this.negative&&!es)return -1;if(0===this.negative&&es)return 1;if(this._strip(),this.length>1)ei=1;else{es&&(et=-et),ef(et<=67108863,"Number is too big");var eu=0|this.words[0];ei=eu===et?0:euet.length)return 1;if(this.length=0;es--){var ef=0|this.words[es],eu=0|et.words[es];if(ef!==eu){efeu&&(ei=1);break}}return ei},ed.prototype.gtn=function(et){return 1===this.cmpn(et)},ed.prototype.gt=function(et){return 1===this.cmp(et)},ed.prototype.gten=function(et){return this.cmpn(et)>=0},ed.prototype.gte=function(et){return this.cmp(et)>=0},ed.prototype.ltn=function(et){return -1===this.cmpn(et)},ed.prototype.lt=function(et){return -1===this.cmp(et)},ed.prototype.lten=function(et){return 0>=this.cmpn(et)},ed.prototype.lte=function(et){return 0>=this.cmp(et)},ed.prototype.eqn=function(et){return 0===this.cmpn(et)},ed.prototype.eq=function(et){return 0===this.cmp(et)},ed.red=function(et){return new eR(et)},ed.prototype.toRed=function(et){return ef(!this.red,"Already a number in reduction context"),ef(0===this.negative,"red works only with positives"),et.convertTo(this)._forceRed(et)},ed.prototype.fromRed=function(){return ef(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},ed.prototype._forceRed=function(et){return this.red=et,this},ed.prototype.forceRed=function(et){return ef(!this.red,"Already a number in reduction context"),this._forceRed(et)},ed.prototype.redAdd=function(et){return ef(this.red,"redAdd works only with red numbers"),this.red.add(this,et)},ed.prototype.redIAdd=function(et){return ef(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,et)},ed.prototype.redSub=function(et){return ef(this.red,"redSub works only with red numbers"),this.red.sub(this,et)},ed.prototype.redISub=function(et){return ef(this.red,"redISub works only with red numbers"),this.red.isub(this,et)},ed.prototype.redShl=function(et){return ef(this.red,"redShl works only with red numbers"),this.red.shl(this,et)},ed.prototype.redMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.mul(this,et)},ed.prototype.redIMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.imul(this,et)},ed.prototype.redSqr=function(){return ef(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},ed.prototype.redISqr=function(){return ef(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},ed.prototype.redSqrt=function(){return ef(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},ed.prototype.redInvm=function(){return ef(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},ed.prototype.redNeg=function(){return ef(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},ed.prototype.redPow=function(et){return ef(this.red&&!et.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,et)};var e_={k256:null,p224:null,p192:null,p25519:null};function eE(et,ei){this.name=et,this.p=new ed(ei,16),this.n=this.p.bitLength(),this.k=new ed(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function eP(){eE.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function eB(){eE.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function eT(){eE.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function eI(){eE.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function eR(et){if("string"==typeof et){var ei=ed._prime(et);this.m=ei.p,this.prime=ei}else ef(et.gtn(1),"modulus must be greater than 1"),this.m=et,this.prime=null}function eO(et){eR.call(this,et),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new ed(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)}eE.prototype._tmp=function(){var et=new ed(null);return et.words=Array(Math.ceil(this.n/13)),et},eE.prototype.ireduce=function(et){var ei,es=et;do this.split(es,this.tmp),ei=(es=(es=this.imulK(es)).iadd(this.tmp)).bitLength();while(ei>this.n);var ef=ei0?es.isub(this.p):void 0!==es.strip?es.strip():es._strip(),es},eE.prototype.split=function(et,ei){et.iushrn(this.n,0,ei)},eE.prototype.imulK=function(et){return et.imul(this.k)},eu(eP,eE),eP.prototype.split=function(et,ei){for(var es=4194303,ef=Math.min(et.length,9),eu=0;eu>>22,ed=em}ed>>>=22,et.words[eu-10]=ed,0===ed&&et.length>10?et.length-=10:et.length-=9},eP.prototype.imulK=function(et){et.words[et.length]=0,et.words[et.length+1]=0,et.length+=2;for(var ei=0,es=0;es>>=26,et.words[es]=eu,ei=ef}return 0!==ei&&(et.words[et.length++]=ei),et},ed._prime=function(et){var ei;if(e_[et])return e_[et];if("k256"===et)ei=new eP;else if("p224"===et)ei=new eB;else if("p192"===et)ei=new eT;else if("p25519"===et)ei=new eI;else throw Error("Unknown prime "+et);return e_[et]=ei,ei},eR.prototype._verify1=function(et){ef(0===et.negative,"red works only with positives"),ef(et.red,"red works only with red numbers")},eR.prototype._verify2=function(et,ei){ef((et.negative|ei.negative)==0,"red works only with positives"),ef(et.red&&et.red===ei.red,"red works only with red numbers")},eR.prototype.imod=function(et){return this.prime?this.prime.ireduce(et)._forceRed(this):(ez(et,et.umod(this.m)._forceRed(this)),et)},eR.prototype.neg=function(et){return et.isZero()?et.clone():this.m.sub(et)._forceRed(this)},eR.prototype.add=function(et,ei){this._verify2(et,ei);var es=et.add(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es._forceRed(this)},eR.prototype.iadd=function(et,ei){this._verify2(et,ei);var es=et.iadd(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es},eR.prototype.sub=function(et,ei){this._verify2(et,ei);var es=et.sub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es._forceRed(this)},eR.prototype.isub=function(et,ei){this._verify2(et,ei);var es=et.isub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es},eR.prototype.shl=function(et,ei){return this._verify1(et),this.imod(et.ushln(ei))},eR.prototype.imul=function(et,ei){return this._verify2(et,ei),this.imod(et.imul(ei))},eR.prototype.mul=function(et,ei){return this._verify2(et,ei),this.imod(et.mul(ei))},eR.prototype.isqr=function(et){return this.imul(et,et.clone())},eR.prototype.sqr=function(et){return this.mul(et,et)},eR.prototype.sqrt=function(et){if(et.isZero())return et.clone();var ei=this.m.andln(3);if(ef(ei%2==1),3===ei){var es=this.m.add(new ed(1)).iushrn(2);return this.pow(et,es)}for(var eu=this.m.subn(1),em=0;!eu.isZero()&&0===eu.andln(1);)em++,eu.iushrn(1);ef(!eu.isZero());var eH=new ed(1).toRed(this),ez=eH.redNeg(),eV=this.m.subn(1).iushrn(1),eM=this.m.bitLength();for(eM=new ed(2*eM*eM).toRed(this);0!==this.pow(eM,eV).cmp(ez);)eM.redIAdd(ez);for(var eg=this.pow(eM,eu),eL=this.pow(et,eu.addn(1).iushrn(1)),eb=this.pow(et,eu),ey=em;0!==eb.cmp(eH);){for(var eC=eb,ex=0;0!==eC.cmp(eH);ex++)eC=eC.redSqr();ef(ex=0;eu--){for(var eM=ei.words[eu],eg=eV-1;eg>=0;eg--){var eL=eM>>eg&1;if(em!==ef[0]&&(em=this.sqr(em)),0===eL&&0===eH){ez=0;continue}eH<<=1,eH|=eL,(++ez===es||0===eu&&0===eg)&&(em=this.mul(em,ef[eH]),ez=0,eH=0)}eV=26}return em},eR.prototype.convertTo=function(et){var ei=et.umod(this.m);return ei===et?ei.clone():ei},eR.prototype.convertFrom=function(et){var ei=et.clone();return ei.red=null,ei},ed.mont=function(et){return new eO(et)},eu(eO,eR),eO.prototype.convertTo=function(et){return this.imod(et.ushln(this.shift))},eO.prototype.convertFrom=function(et){var ei=this.imod(et.mul(this.rinv));return ei.red=null,ei},eO.prototype.imul=function(et,ei){if(et.isZero()||ei.isZero())return et.words[0]=0,et.length=1,et;var es=et.imul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),ed=eu;return eu.cmp(this.m)>=0?ed=eu.isub(this.m):0>eu.cmpn(0)&&(ed=eu.iadd(this.m)),ed._forceRed(this)},eO.prototype.mul=function(et,ei){if(et.isZero()||ei.isZero())return new ed(0)._forceRed(this);var es=et.mul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),em=eu;return eu.cmp(this.m)>=0?em=eu.isub(this.m):0>eu.cmpn(0)&&(em=eu.iadd(this.m)),em._forceRed(this)},eO.prototype.invm=function(et){return this.imod(et._invmp(this.m).mul(this.r2))._forceRed(this)}}(et=es.nmd(et),this)},3500:function(et,ei,es){var ef;function eu(et){this.rand=et}if(et.exports=function(et){return ef||(ef=new eu(null)),ef.generate(et)},et.exports.Rand=eu,eu.prototype.generate=function(et){return this._rand(et)},eu.prototype._rand=function(et){if(this.rand.getBytes)return this.rand.getBytes(et);for(var ei=new Uint8Array(et),es=0;es>>24]^eM[ey>>>16&255]^eg[eC>>>8&255]^eL[255&ex]^ei[ew++],em=eV[ey>>>24]^eM[eC>>>16&255]^eg[ex>>>8&255]^eL[255&eb]^ei[ew++],eH=eV[eC>>>24]^eM[ex>>>16&255]^eg[eb>>>8&255]^eL[255&ey]^ei[ew++],ez=eV[ex>>>24]^eM[eb>>>16&255]^eg[ey>>>8&255]^eL[255&eC]^ei[ew++],eb=ed,ey=em,eC=eH,ex=ez;return ed=(ef[eb>>>24]<<24|ef[ey>>>16&255]<<16|ef[eC>>>8&255]<<8|ef[255&ex])^ei[ew++],em=(ef[ey>>>24]<<24|ef[eC>>>16&255]<<16|ef[ex>>>8&255]<<8|ef[255&eb])^ei[ew++],[ed>>>=0,em>>>=0,eH=((ef[eC>>>24]<<24|ef[ex>>>16&255]<<16|ef[eb>>>8&255]<<8|ef[255&ey])^ei[ew++])>>>0,ez=((ef[ex>>>24]<<24|ef[eb>>>16&255]<<16|ef[ey>>>8&255]<<8|ef[255&eC])^ei[ew++])>>>0]}var eH=[0,1,2,4,8,16,32,64,128,27,54],ez=function(){for(var et=Array(256),ei=0;ei<256;ei++)ei<128?et[ei]=ei<<1:et[ei]=ei<<1^283;for(var es=[],ef=[],eu=[[],[],[],[]],ed=[[],[],[],[]],em=0,eH=0,ez=0;ez<256;++ez){var eV=eH^eH<<1^eH<<2^eH<<3^eH<<4;eV=eV>>>8^255&eV^99,es[em]=eV,ef[eV]=em;var eM=et[em],eg=et[eM],eL=et[eg],eb=257*et[eV]^16843008*eV;eu[0][em]=eb<<24|eb>>>8,eu[1][em]=eb<<16|eb>>>16,eu[2][em]=eb<<8|eb>>>24,eu[3][em]=eb,eb=16843009*eL^65537*eg^257*eM^16843008*em,ed[0][eV]=eb<<24|eb>>>8,ed[1][eV]=eb<<16|eb>>>16,ed[2][eV]=eb<<8|eb>>>24,ed[3][eV]=eb,0===em?em=eH=1:(em=eM^et[et[et[eL^eM]]],eH^=et[et[eH]])}return{SBOX:es,INV_SBOX:ef,SUB_MIX:eu,INV_SUB_MIX:ed}}();function eV(et){this._key=eu(et),this._reset()}eV.blockSize=16,eV.keySize=32,eV.prototype.blockSize=eV.blockSize,eV.prototype.keySize=eV.keySize,eV.prototype._reset=function(){for(var et=this._key,ei=et.length,es=ei+6,ef=(es+1)*4,eu=[],ed=0;ed>>24,em=(ez.SBOX[em>>>24]<<24|ez.SBOX[em>>>16&255]<<16|ez.SBOX[em>>>8&255]<<8|ez.SBOX[255&em])^eH[ed/ei|0]<<24):ei>6&&ed%ei==4&&(em=ez.SBOX[em>>>24]<<24|ez.SBOX[em>>>16&255]<<16|ez.SBOX[em>>>8&255]<<8|ez.SBOX[255&em]),eu[ed]=eu[ed-ei]^em}for(var eV=[],eM=0;eM>>24]]^ez.INV_SUB_MIX[1][ez.SBOX[eL>>>16&255]]^ez.INV_SUB_MIX[2][ez.SBOX[eL>>>8&255]]^ez.INV_SUB_MIX[3][ez.SBOX[255&eL]]}this._nRounds=es,this._keySchedule=eu,this._invKeySchedule=eV},eV.prototype.encryptBlockRaw=function(et){return em(et=eu(et),this._keySchedule,ez.SUB_MIX,ez.SBOX,this._nRounds)},eV.prototype.encryptBlock=function(et){var ei=this.encryptBlockRaw(et),es=ef.allocUnsafe(16);return es.writeUInt32BE(ei[0],0),es.writeUInt32BE(ei[1],4),es.writeUInt32BE(ei[2],8),es.writeUInt32BE(ei[3],12),es},eV.prototype.decryptBlock=function(et){var ei=(et=eu(et))[1];et[1]=et[3],et[3]=ei;var es=em(et,this._invKeySchedule,ez.INV_SUB_MIX,ez.INV_SBOX,this._nRounds),ed=ef.allocUnsafe(16);return ed.writeUInt32BE(es[0],0),ed.writeUInt32BE(es[3],4),ed.writeUInt32BE(es[2],8),ed.writeUInt32BE(es[1],12),ed},eV.prototype.scrub=function(){ed(this._keySchedule),ed(this._invKeySchedule),ed(this._key)},et.exports.AES=eV},6624:function(et,ei,es){var ef=es(1387),eu=es(6911).Buffer,ed=es(1043),em=es(3782),eH=es(7225),ez=es(4734),eV=es(598);function eM(et,ei){var es=0;et.length!==ei.length&&es++;for(var ef=Math.min(et.length,ei.length),eu=0;eu16)throw Error("unable to decrypt data");for(var es=-1;++es16)return ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),ei}else if(this.cache.length>=16)return ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),ei;return null},eg.prototype.flush=function(){if(this.cache.length)return this.cache},ei.createDecipher=ey,ei.createDecipheriv=eb},2:function(et,ei,es){var ef=es(6370),eu=es(6624),ed=es(6911).Buffer,em=es(126),eH=es(1043),ez=es(1387),eV=es(8368);function eM(et,ei,es){eH.call(this),this._cache=new eL,this._cipher=new ez.AES(ei),this._prev=ed.from(es),this._mode=et,this._autopadding=!0}es(3782)(eM,eH),eM.prototype._update=function(et){this._cache.add(et);for(var ei,es,ef=[];ei=this._cache.get();)es=this._mode.encrypt(this,ei),ef.push(es);return ed.concat(ef)};var eg=ed.alloc(16,16);function eL(){this.cache=ed.allocUnsafe(0)}function eb(et,ei,es){var eH=ef[et.toLowerCase()];if(!eH)throw TypeError("invalid suite type");if("string"==typeof ei&&(ei=ed.from(ei)),ei.length!==eH.key/8)throw TypeError("invalid key length "+ei.length);if("string"==typeof es&&(es=ed.from(es)),"GCM"!==eH.mode&&es.length!==eH.iv)throw TypeError("invalid iv length "+es.length);return"stream"===eH.type?new em(eH.module,ei,es):"auth"===eH.type?new eu(eH.module,ei,es):new eM(eH.module,ei,es)}function ey(et,ei){var es=ef[et.toLowerCase()];if(!es)throw TypeError("invalid suite type");var eu=eV(ei,!1,es.key,es.iv);return eb(et,eu.key,eu.iv)}eM.prototype._final=function(){var et=this._cache.flush();if(this._autopadding)return et=this._mode.encrypt(this,et),this._cipher.scrub(),et;if(!et.equals(eg))throw this._cipher.scrub(),Error("data not multiple of block length")},eM.prototype.setAutoPadding=function(et){return this._autopadding=!!et,this},eL.prototype.add=function(et){this.cache=ed.concat([this.cache,et])},eL.prototype.get=function(){if(this.cache.length>15){var et=this.cache.slice(0,16);return this.cache=this.cache.slice(16),et}return null},eL.prototype.flush=function(){for(var et=16-this.cache.length,ei=ed.allocUnsafe(et),es=-1;++es>>0,0),ei.writeUInt32BE(et[1]>>>0,4),ei.writeUInt32BE(et[2]>>>0,8),ei.writeUInt32BE(et[3]>>>0,12),ei}function eH(et){this.h=et,this.state=ef.alloc(16,0),this.cache=ef.allocUnsafe(0)}eH.prototype.ghash=function(et){for(var ei=-1;++ei0;et--)es[et]=es[et]>>>1|(1&es[et-1])<<31;es[0]=es[0]>>>1,ei&&(es[0]=-520093696^es[0])}this.state=em(ef)},eH.prototype.update=function(et){var ei;for(this.cache=ef.concat([this.cache,et]);this.cache.length>=16;)ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(ei)},eH.prototype.final=function(et,ei){return this.cache.length&&this.ghash(ef.concat([this.cache,eu],16)),this.ghash(em([0,et,0,ei])),this.state},et.exports=eH},598:function(et){function ei(et){for(var ei,es=et.length;es--;)if(255===(ei=et.readUInt8(es)))et.writeUInt8(0,es);else{ei++,et.writeUInt8(ei,es);break}}et.exports=ei},9825:function(et,ei,es){var ef=es(4734);ei.encrypt=function(et,ei){var es=ef(ei,et._prev);return et._prev=et._cipher.encryptBlock(es),et._prev},ei.decrypt=function(et,ei){var es=et._prev;return et._prev=ei,ef(et._cipher.decryptBlock(ei),es)}},321:function(et,ei,es){var ef=es(6911).Buffer,eu=es(4734);function ed(et,ei,es){var ed=ei.length,em=eu(ei,et._cache);return et._cache=et._cache.slice(ed),et._prev=ef.concat([et._prev,es?ei:em]),em}ei.encrypt=function(et,ei,es){for(var eu,em=ef.allocUnsafe(0);ei.length;)if(0===et._cache.length&&(et._cache=et._cipher.encryptBlock(et._prev),et._prev=ef.allocUnsafe(0)),et._cache.length<=ei.length)eu=et._cache.length,em=ef.concat([em,ed(et,ei.slice(0,eu),es)]),ei=ei.slice(eu);else{em=ef.concat([em,ed(et,ei,es)]);break}return em}},3147:function(et,ei,es){var ef=es(6911).Buffer;function eu(et,ei,es){for(var ef,eu,em,eH=-1,ez=8,eV=0;++eH>eH%8,et._prev=ed(et._prev,es?eu:em);return eV}function ed(et,ei){var es=et.length,eu=-1,ed=ef.allocUnsafe(et.length);for(et=ef.concat([et,ef.from([ei])]);++eu>7;return ed}ei.encrypt=function(et,ei,es){for(var ed=ei.length,em=ef.allocUnsafe(ed),eH=-1;++eH=0||!es.umod(et.prime1)||!es.umod(et.prime2);)es=new ef(ed(ei));return es}et.exports=eH,eH.getr=ez},9276:function(et,ei,es){et.exports=es(2908)},4078:function(et,ei,es){var ef=es(6911).Buffer,eu=es(9739),ed=es(3726),em=es(3782),eH=es(9807),ez=es(4013),eV=es(2908);function eM(et){ed.Writable.call(this);var ei=eV[et];if(!ei)throw Error("Unknown message digest");this._hashType=ei.hash,this._hash=eu(ei.hash),this._tag=ei.id,this._signType=ei.sign}function eg(et){ed.Writable.call(this);var ei=eV[et];if(!ei)throw Error("Unknown message digest");this._hash=eu(ei.hash),this._tag=ei.id,this._signType=ei.sign}function eL(et){return new eM(et)}function eb(et){return new eg(et)}Object.keys(eV).forEach(function(et){eV[et].id=ef.from(eV[et].id,"hex"),eV[et.toLowerCase()]=eV[et]}),em(eM,ed.Writable),eM.prototype._write=function(et,ei,es){this._hash.update(et),es()},eM.prototype.update=function(et,ei){return"string"==typeof et&&(et=ef.from(et,ei)),this._hash.update(et),this},eM.prototype.sign=function(et,ei){this.end();var es=eH(this._hash.digest(),et,this._hashType,this._signType,this._tag);return ei?es.toString(ei):es},em(eg,ed.Writable),eg.prototype._write=function(et,ei,es){this._hash.update(et),es()},eg.prototype.update=function(et,ei){return"string"==typeof et&&(et=ef.from(et,ei)),this._hash.update(et),this},eg.prototype.verify=function(et,ei,es){return"string"==typeof ei&&(ei=ef.from(ei,es)),this.end(),ez(ei,this._hash.digest(),et,this._signType,this._tag)},et.exports={Sign:eL,Verify:eb,createSign:eL,createVerify:eb}},9807:function(et,ei,es){var ef=es(6911).Buffer,eu=es(4873),ed=es(7166),em=es(949).ec,eH=es(1670),ez=es(9902),eV=es(9267);function eM(et,ei,es,eu,em){var eH=ez(ei);if(eH.curve){if("ecdsa"!==eu&&"ecdsa/rsa"!==eu)throw Error("wrong private key type");return eg(et,eH)}if("dsa"===eH.type){if("dsa"!==eu)throw Error("wrong private key type");return eL(et,eH,es)}if("rsa"!==eu&&"ecdsa/rsa"!==eu)throw Error("wrong private key type");et=ef.concat([em,et]);for(var eV=eH.modulus.byteLength(),eM=[0,1];et.length+eM.length+10&&es.ishrn(ef),es}function ex(et,ei){et=(et=eC(et,ei)).mod(ei);var es=ef.from(et.toArray());if(es.length=et.cmpn(0)||et.cmp(ei)>=ei)throw Error("invalid sig")}et.exports=ez},4734:function(et){et.exports=function(et,ei){for(var es=Math.min(et.length,ei.length),ef=new eu(es),ed=0;edes?ei=("rmd160"===et?new ez:eV(et)).update(ei).digest():ei.lengtheH?ei=et(ei):ei.length0;ef--)ei+=this._buffer(et,ei),es+=this._flushBuffer(eu,es);return ei+=this._buffer(et,ei),eu},eu.prototype.final=function(et){var ei,es;return(et&&(ei=this.update(et)),es="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),ei)?ei.concat(es):es},eu.prototype._pad=function(et,ei){if(0===ei)return!1;for(;ei>>1];es=ed.r28shl(es,eH),eu=ed.r28shl(eu,eH),ed.pc2(es,eu,et.keys,em)}},ez.prototype._update=function(et,ei,es,ef){var eu=this._desState,em=ed.readUInt32BE(et,ei),eH=ed.readUInt32BE(et,ei+4);ed.ip(em,eH,eu.tmp,0),em=eu.tmp[0],eH=eu.tmp[1],"encrypt"===this.type?this._encrypt(eu,em,eH,eu.tmp,0):this._decrypt(eu,em,eH,eu.tmp,0),em=eu.tmp[0],eH=eu.tmp[1],ed.writeUInt32BE(es,em,ef),ed.writeUInt32BE(es,eH,ef+4)},ez.prototype._pad=function(et,ei){for(var es=et.length-ei,ef=ei;ef>>0,em=eb}ed.rip(eH,em,ef,eu)},ez.prototype._decrypt=function(et,ei,es,ef,eu){for(var em=es,eH=ei,ez=et.keys.length-2;ez>=0;ez-=2){var eV=et.keys[ez],eM=et.keys[ez+1];ed.expand(em,et.tmp,0),eV^=et.tmp[0],eM^=et.tmp[1];var eg=ed.substitute(eV,eM),eL=ed.permute(eg),eb=em;em=(eH^eL)>>>0,eH=eb}ed.rip(em,eH,ef,eu)}},6159:function(et,ei,es){"use strict";var ef=es(3523),eu=es(3782),ed=es(9876),em=es(1016);function eH(et,ei){ef.equal(ei.length,24,"Invalid key length");var es=ei.slice(0,8),eu=ei.slice(8,16),ed=ei.slice(16,24);"encrypt"===et?this.ciphers=[em.create({type:"encrypt",key:es}),em.create({type:"decrypt",key:eu}),em.create({type:"encrypt",key:ed})]:this.ciphers=[em.create({type:"decrypt",key:ed}),em.create({type:"encrypt",key:eu}),em.create({type:"decrypt",key:es})]}function ez(et){ed.call(this,et);var ei=new eH(this.type,this.options.key);this._edeState=ei}eu(ez,ed),et.exports=ez,ez.create=function(et){return new ez(et)},ez.prototype._update=function(et,ei,es,ef){var eu=this._edeState;eu.ciphers[0]._update(et,ei,es,ef),eu.ciphers[1]._update(es,ef,es,ef),eu.ciphers[2]._update(es,ef,es,ef)},ez.prototype._pad=em.prototype._pad,ez.prototype._unpad=em.prototype._unpad},5334:function(et,ei){"use strict";ei.readUInt32BE=function(et,ei){return(et[0+ei]<<24|et[1+ei]<<16|et[2+ei]<<8|et[3+ei])>>>0},ei.writeUInt32BE=function(et,ei,es){et[0+es]=ei>>>24,et[1+es]=ei>>>16&255,et[2+es]=ei>>>8&255,et[3+es]=255&ei},ei.ip=function(et,ei,es,ef){for(var eu=0,ed=0,em=6;em>=0;em-=2){for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>>eH+em&1;for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=et>>>eH+em&1}for(var em=6;em>=0;em-=2){for(var eH=1;eH<=25;eH+=8)ed<<=1,ed|=ei>>>eH+em&1;for(var eH=1;eH<=25;eH+=8)ed<<=1,ed|=et>>>eH+em&1}es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.rip=function(et,ei,es,ef){for(var eu=0,ed=0,em=0;em<4;em++)for(var eH=24;eH>=0;eH-=8)eu<<=1,eu|=ei>>>eH+em&1,eu<<=1,eu|=et>>>eH+em&1;for(var em=4;em<8;em++)for(var eH=24;eH>=0;eH-=8)ed<<=1,ed|=ei>>>eH+em&1,ed<<=1,ed|=et>>>eH+em&1;es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.pc1=function(et,ei,es,ef){for(var eu=0,ed=0,em=7;em>=5;em--){for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>eH+em&1;for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=et>>eH+em&1}for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>eH+em&1;for(var em=1;em<=3;em++){for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=ei>>eH+em&1;for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=et>>eH+em&1}for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=et>>eH+em&1;es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.r28shl=function(et,ei){return et<>>28-ei};var es=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];ei.pc2=function(et,ei,ef,eu){for(var ed=0,em=0,eH=es.length>>>1,ez=0;ez>>es[ez]&1;for(var ez=eH;ez>>es[ez]&1;ef[eu+0]=ed>>>0,ef[eu+1]=em>>>0},ei.expand=function(et,ei,es){var ef=0,eu=0;ef=(1&et)<<5|et>>>27;for(var ed=23;ed>=15;ed-=4)ef<<=6,ef|=et>>>ed&63;for(var ed=11;ed>=3;ed-=4)eu|=et>>>ed&63,eu<<=6;eu|=(31&et)<<1|et>>>31,ei[es+0]=ef>>>0,ei[es+1]=eu>>>0};var ef=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];ei.substitute=function(et,ei){for(var es=0,eu=0;eu<4;eu++){var ed=et>>>18-6*eu&63,em=ef[64*eu+ed];es<<=4,es|=em}for(var eu=0;eu<4;eu++){var ed=ei>>>18-6*eu&63,em=ef[256+64*eu+ed];es<<=4,es|=em}return es>>>0};var eu=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];ei.permute=function(et){for(var ei=0,es=0;es>>eu[es]&1;return ei>>>0},ei.padSplit=function(et,ei,es){for(var ef=et.toString(2);ef.lengthet;)es.ishrn(1);if(es.isEven()&&es.iadd(eH),es.testn(1)||es.iadd(ez),ei.cmp(ez)){if(!ei.cmp(eV))for(;es.mod(eM).cmp(eg);)es.iadd(eb)}else for(;es.mod(ed).cmp(eL);)es.iadd(eb);if(ex(ey=es.shrn(1))&&ex(es)&&ew(ey)&&ew(es)&&em.test(ey)&&em.test(es))return es}}},949:function(et,ei,es){"use strict";var ef=ei;ef.version=es(2531).i8,ef.utils=es(4401),ef.rand=es(3500),ef.curve=es(9359),ef.curves=es(6226),ef.ec=es(4088),ef.eddsa=es(8511)},2727:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401),ed=eu.getNAF,em=eu.getJSF,eH=eu.assert;function ez(et,ei){this.type=et,this.p=new ef(ei.p,16),this.red=ei.prime?ef.red(ei.prime):ef.mont(this.p),this.zero=new ef(0).toRed(this.red),this.one=new ef(1).toRed(this.red),this.two=new ef(2).toRed(this.red),this.n=ei.n&&new ef(ei.n,16),this.g=ei.g&&this.pointFromJSON(ei.g,ei.gRed),this._wnafT1=[,,,,],this._wnafT2=[,,,,],this._wnafT3=[,,,,],this._wnafT4=[,,,,],this._bitLength=this.n?this.n.bitLength():0;var es=this.n&&this.p.div(this.n);!es||es.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function eV(et,ei){this.curve=et,this.type=ei,this.precomputed=null}et.exports=ez,ez.prototype.point=function(){throw Error("Not implemented")},ez.prototype.validate=function(){throw Error("Not implemented")},ez.prototype._fixedNafMul=function(et,ei){eH(et.precomputed);var es=et._getDoubles(),ef=ed(ei,1,this._bitLength),eu=(1<=ez;ei--)eV=(eV<<1)+ef[ei];em.push(eV)}for(var eM=this.jpoint(null,null,null),eg=this.jpoint(null,null,null),eL=eu;eL>0;eL--){for(var ez=0;ez=0;eV--){for(var ei=0;eV>=0&&0===em[eV];eV--)ei++;if(eV>=0&&ei++,ez=ez.dblp(ei),eV<0)break;var eM=em[eV];eH(0!==eM),ez="affine"===et.type?eM>0?ez.mixedAdd(eu[eM-1>>1]):ez.mixedAdd(eu[-eM-1>>1].neg()):eM>0?ez.add(eu[eM-1>>1]):ez.add(eu[-eM-1>>1].neg())}return"affine"===et.type?ez.toP():ez},ez.prototype._wnafMulAdd=function(et,ei,es,ef,eu){for(var eH=this._wnafT1,ez=this._wnafT2,eV=this._wnafT3,eM=0,eg=0;eg=1;eg-=2){var ey=eg-1,eC=eg;if(1!==eH[ey]||1!==eH[eC]){eV[ey]=ed(es[ey],eH[ey],this._bitLength),eV[eC]=ed(es[eC],eH[eC],this._bitLength),eM=Math.max(eV[ey].length,eM),eM=Math.max(eV[eC].length,eM);continue}var ex=[ei[ey],null,null,ei[eC]];0===ei[ey].y.cmp(ei[eC].y)?(ex[1]=ei[ey].add(ei[eC]),ex[2]=ei[ey].toJ().mixedAdd(ei[eC].neg())):0===ei[ey].y.cmp(ei[eC].y.redNeg())?(ex[1]=ei[ey].toJ().mixedAdd(ei[eC]),ex[2]=ei[ey].add(ei[eC].neg())):(ex[1]=ei[ey].toJ().mixedAdd(ei[eC]),ex[2]=ei[ey].toJ().mixedAdd(ei[eC].neg()));var ew=[-3,-1,-5,-7,0,7,5,1,3],eN=em(es[ey],es[eC]);eM=Math.max(eN[0].length,eM),eV[ey]=Array(eM),eV[eC]=Array(eM);for(var eS=0;eS=0;eg--){for(var eB=0;eg>=0;){for(var eT=!0,eS=0;eS=0&&eB++,eE=eE.dblp(eB),eg<0)break;for(var eS=0;eS0?eL=ez[eS][eI-1>>1]:eI<0&&(eL=ez[eS][-eI-1>>1].neg()),eE="affine"===eL.type?eE.mixedAdd(eL):eE.add(eL))}}for(var eg=0;eg=Math.ceil((et.bitLength()+1)/ei.step)},eV.prototype._getDoubles=function(et,ei){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var es=[this],ef=this,eu=0;eu":""},eV.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},eV.prototype._extDbl=function(){var et=this.x.redSqr(),ei=this.y.redSqr(),es=this.z.redSqr();es=es.redIAdd(es);var ef=this.curve._mulA(et),eu=this.x.redAdd(this.y).redSqr().redISub(et).redISub(ei),ed=ef.redAdd(ei),em=ed.redSub(es),eH=ef.redSub(ei),ez=eu.redMul(em),eV=ed.redMul(eH),eM=eu.redMul(eH),eg=em.redMul(ed);return this.curve.point(ez,eV,eg,eM)},eV.prototype._projDbl=function(){var et,ei,es,ef=this.x.redAdd(this.y).redSqr(),eu=this.x.redSqr(),ed=this.y.redSqr();if(this.curve.twisted){var em=this.curve._mulA(eu),eH=em.redAdd(ed);if(this.zOne)et=ef.redSub(eu).redSub(ed).redMul(eH.redSub(this.curve.two)),ei=eH.redMul(em.redSub(ed)),es=eH.redSqr().redSub(eH).redSub(eH);else{var ez=this.z.redSqr(),eV=eH.redSub(ez).redISub(ez);et=ef.redSub(eu).redISub(ed).redMul(eV),ei=eH.redMul(em.redSub(ed)),es=eH.redMul(eV)}}else{var em=eu.redAdd(ed),ez=this.curve._mulC(this.z).redSqr(),eV=em.redSub(ez).redSub(ez);et=this.curve._mulC(ef.redISub(em)).redMul(eV),ei=this.curve._mulC(em).redMul(eu.redISub(ed)),es=em.redMul(eV)}return this.curve.point(et,ei,es)},eV.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},eV.prototype._extAdd=function(et){var ei=this.y.redSub(this.x).redMul(et.y.redSub(et.x)),es=this.y.redAdd(this.x).redMul(et.y.redAdd(et.x)),ef=this.t.redMul(this.curve.dd).redMul(et.t),eu=this.z.redMul(et.z.redAdd(et.z)),ed=es.redSub(ei),em=eu.redSub(ef),eH=eu.redAdd(ef),ez=es.redAdd(ei),eV=ed.redMul(em),eM=eH.redMul(ez),eg=ed.redMul(ez),eL=em.redMul(eH);return this.curve.point(eV,eM,eL,eg)},eV.prototype._projAdd=function(et){var ei,es,ef=this.z.redMul(et.z),eu=ef.redSqr(),ed=this.x.redMul(et.x),em=this.y.redMul(et.y),eH=this.curve.d.redMul(ed).redMul(em),ez=eu.redSub(eH),eV=eu.redAdd(eH),eM=this.x.redAdd(this.y).redMul(et.x.redAdd(et.y)).redISub(ed).redISub(em),eg=ef.redMul(ez).redMul(eM);return this.curve.twisted?(ei=ef.redMul(eV).redMul(em.redSub(this.curve._mulA(ed))),es=ez.redMul(eV)):(ei=ef.redMul(eV).redMul(em.redSub(ed)),es=this.curve._mulC(ez).redMul(eV)),this.curve.point(eg,ei,es)},eV.prototype.add=function(et){return this.isInfinity()?et:et.isInfinity()?this:this.curve.extended?this._extAdd(et):this._projAdd(et)},eV.prototype.mul=function(et){return this._hasDoubles(et)?this.curve._fixedNafMul(this,et):this.curve._wnafMul(this,et)},eV.prototype.mulAdd=function(et,ei,es){return this.curve._wnafMulAdd(1,[this,ei],[et,es],2,!1)},eV.prototype.jmulAdd=function(et,ei,es){return this.curve._wnafMulAdd(1,[this,ei],[et,es],2,!0)},eV.prototype.normalize=function(){if(this.zOne)return this;var et=this.z.redInvm();return this.x=this.x.redMul(et),this.y=this.y.redMul(et),this.t&&(this.t=this.t.redMul(et)),this.z=this.curve.one,this.zOne=!0,this},eV.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},eV.prototype.getX=function(){return this.normalize(),this.x.fromRed()},eV.prototype.getY=function(){return this.normalize(),this.y.fromRed()},eV.prototype.eq=function(et){return this===et||0===this.getX().cmp(et.getX())&&0===this.getY().cmp(et.getY())},eV.prototype.eqXToP=function(et){var ei=et.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(ei))return!0;for(var es=et.clone(),ef=this.curve.redN.redMul(this.z);;){if(es.iadd(this.curve.n),es.cmp(this.curve.p)>=0)return!1;if(ei.redIAdd(ef),0===this.x.cmp(ei))return!0}},eV.prototype.toP=eV.prototype.normalize,eV.prototype.mixedAdd=eV.prototype.add},9359:function(et,ei,es){"use strict";var ef=ei;ef.base=es(2727),ef.short=es(4720),ef.mont=es(6653),ef.edwards=es(2705)},6653:function(et,ei,es){"use strict";var ef=es(711),eu=es(3782),ed=es(2727),em=es(4401);function eH(et){ed.call(this,"mont",et),this.a=new ef(et.a,16).toRed(this.red),this.b=new ef(et.b,16).toRed(this.red),this.i4=new ef(4).toRed(this.red).redInvm(),this.two=new ef(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function ez(et,ei,es){ed.BasePoint.call(this,et,"projective"),null===ei&&null===es?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new ef(ei,16),this.z=new ef(es,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}eu(eH,ed),et.exports=eH,eH.prototype.validate=function(et){var ei=et.normalize().x,es=ei.redSqr(),ef=es.redMul(ei).redAdd(es.redMul(this.a)).redAdd(ei);return 0===ef.redSqrt().redSqr().cmp(ef)},eu(ez,ed.BasePoint),eH.prototype.decodePoint=function(et,ei){return this.point(em.toArray(et,ei),1)},eH.prototype.point=function(et,ei){return new ez(this,et,ei)},eH.prototype.pointFromJSON=function(et){return ez.fromJSON(this,et)},ez.prototype.precompute=function(){},ez.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},ez.fromJSON=function(et,ei){return new ez(et,ei[0],ei[1]||et.one)},ez.prototype.inspect=function(){return this.isInfinity()?"":""},ez.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},ez.prototype.dbl=function(){var et=this.x.redAdd(this.z).redSqr(),ei=this.x.redSub(this.z).redSqr(),es=et.redSub(ei),ef=et.redMul(ei),eu=es.redMul(ei.redAdd(this.curve.a24.redMul(es)));return this.curve.point(ef,eu)},ez.prototype.add=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.diffAdd=function(et,ei){var es=this.x.redAdd(this.z),ef=this.x.redSub(this.z),eu=et.x.redAdd(et.z),ed=et.x.redSub(et.z).redMul(es),em=eu.redMul(ef),eH=ei.z.redMul(ed.redAdd(em).redSqr()),ez=ei.x.redMul(ed.redISub(em).redSqr());return this.curve.point(eH,ez)},ez.prototype.mul=function(et){for(var ei=et.clone(),es=this,ef=this.curve.point(null,null),eu=this,ed=[];0!==ei.cmpn(0);ei.iushrn(1))ed.push(ei.andln(1));for(var em=ed.length-1;em>=0;em--)0===ed[em]?(es=es.diffAdd(ef,eu),ef=ef.dbl()):(ef=es.diffAdd(ef,eu),es=es.dbl());return ef},ez.prototype.mulAdd=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.jumlAdd=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.eq=function(et){return 0===this.getX().cmp(et.getX())},ez.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},ez.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},4720:function(et,ei,es){"use strict";var ef=es(4401),eu=es(711),ed=es(3782),em=es(2727),eH=ef.assert;function ez(et){em.call(this,"short",et),this.a=new eu(et.a,16).toRed(this.red),this.b=new eu(et.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(et),this._endoWnafT1=[,,,,],this._endoWnafT2=[,,,,]}function eV(et,ei,es,ef){em.BasePoint.call(this,et,"affine"),null===ei&&null===es?(this.x=null,this.y=null,this.inf=!0):(this.x=new eu(ei,16),this.y=new eu(es,16),ef&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function eM(et,ei,es,ef){em.BasePoint.call(this,et,"jacobian"),null===ei&&null===es&&null===ef?(this.x=this.curve.one,this.y=this.curve.one,this.z=new eu(0)):(this.x=new eu(ei,16),this.y=new eu(es,16),this.z=new eu(ef,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}ed(ez,em),et.exports=ez,ez.prototype._getEndomorphism=function(et){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){if(et.beta)ei=new eu(et.beta,16).toRed(this.red);else{var ei,es,ef,ed=this._getEndoRoots(this.p);ei=(ei=0>ed[0].cmp(ed[1])?ed[0]:ed[1]).toRed(this.red)}if(et.lambda)es=new eu(et.lambda,16);else{var em=this._getEndoRoots(this.n);0===this.g.mul(em[0]).x.cmp(this.g.x.redMul(ei))?es=em[0]:(es=em[1],eH(0===this.g.mul(es).x.cmp(this.g.x.redMul(ei))))}return ef=et.basis?et.basis.map(function(et){return{a:new eu(et.a,16),b:new eu(et.b,16)}}):this._getEndoBasis(es),{beta:ei,lambda:es,basis:ef}}},ez.prototype._getEndoRoots=function(et){var ei=et===this.p?this.red:eu.mont(et),es=new eu(2).toRed(ei).redInvm(),ef=es.redNeg(),ed=new eu(3).toRed(ei).redNeg().redSqrt().redMul(es);return[ef.redAdd(ed).fromRed(),ef.redSub(ed).fromRed()]},ez.prototype._getEndoBasis=function(et){for(var ei,es,ef,ed,em,eH,ez,eV,eM,eg=this.n.ushrn(Math.floor(this.n.bitLength()/2)),eL=et,eb=this.n.clone(),ey=new eu(1),eC=new eu(0),ex=new eu(0),ew=new eu(1),eN=0;0!==eL.cmpn(0);){var eS=eb.div(eL);eV=eb.sub(eS.mul(eL)),eM=ex.sub(eS.mul(ey));var eA=ew.sub(eS.mul(eC));if(!ef&&0>eV.cmp(eg))ei=ez.neg(),es=ey,ef=eV.neg(),ed=eM;else if(ef&&2==++eN)break;ez=eV,eb=eL,eL=eV,ex=ey,ey=eM,ew=eC,eC=eA}em=eV.neg(),eH=eM;var e_=ef.sqr().add(ed.sqr());return em.sqr().add(eH.sqr()).cmp(e_)>=0&&(em=ei,eH=es),ef.negative&&(ef=ef.neg(),ed=ed.neg()),em.negative&&(em=em.neg(),eH=eH.neg()),[{a:ef,b:ed},{a:em,b:eH}]},ez.prototype._endoSplit=function(et){var ei=this.endo.basis,es=ei[0],ef=ei[1],eu=ef.b.mul(et).divRound(this.n),ed=es.b.neg().mul(et).divRound(this.n),em=eu.mul(es.a),eH=ed.mul(ef.a),ez=eu.mul(es.b),eV=ed.mul(ef.b);return{k1:et.sub(em).sub(eH),k2:ez.add(eV).neg()}},ez.prototype.pointFromX=function(et,ei){(et=new eu(et,16)).red||(et=et.toRed(this.red));var es=et.redSqr().redMul(et).redIAdd(et.redMul(this.a)).redIAdd(this.b),ef=es.redSqrt();if(0!==ef.redSqr().redSub(es).cmp(this.zero))throw Error("invalid point");var ed=ef.fromRed().isOdd();return(ei&&!ed||!ei&&ed)&&(ef=ef.redNeg()),this.point(et,ef)},ez.prototype.validate=function(et){if(et.inf)return!0;var ei=et.x,es=et.y,ef=this.a.redMul(ei),eu=ei.redSqr().redMul(ei).redIAdd(ef).redIAdd(this.b);return 0===es.redSqr().redISub(eu).cmpn(0)},ez.prototype._endoWnafMulAdd=function(et,ei,es){for(var ef=this._endoWnafT1,eu=this._endoWnafT2,ed=0;ed":""},eV.prototype.isInfinity=function(){return this.inf},eV.prototype.add=function(et){if(this.inf)return et;if(et.inf)return this;if(this.eq(et))return this.dbl();if(this.neg().eq(et)||0===this.x.cmp(et.x))return this.curve.point(null,null);var ei=this.y.redSub(et.y);0!==ei.cmpn(0)&&(ei=ei.redMul(this.x.redSub(et.x).redInvm()));var es=ei.redSqr().redISub(this.x).redISub(et.x),ef=ei.redMul(this.x.redSub(es)).redISub(this.y);return this.curve.point(es,ef)},eV.prototype.dbl=function(){if(this.inf)return this;var et=this.y.redAdd(this.y);if(0===et.cmpn(0))return this.curve.point(null,null);var ei=this.curve.a,es=this.x.redSqr(),ef=et.redInvm(),eu=es.redAdd(es).redIAdd(es).redIAdd(ei).redMul(ef),ed=eu.redSqr().redISub(this.x.redAdd(this.x)),em=eu.redMul(this.x.redSub(ed)).redISub(this.y);return this.curve.point(ed,em)},eV.prototype.getX=function(){return this.x.fromRed()},eV.prototype.getY=function(){return this.y.fromRed()},eV.prototype.mul=function(et){return(et=new eu(et,16),this.isInfinity())?this:this._hasDoubles(et)?this.curve._fixedNafMul(this,et):this.curve.endo?this.curve._endoWnafMulAdd([this],[et]):this.curve._wnafMul(this,et)},eV.prototype.mulAdd=function(et,ei,es){var ef=[this,ei],eu=[et,es];return this.curve.endo?this.curve._endoWnafMulAdd(ef,eu):this.curve._wnafMulAdd(1,ef,eu,2)},eV.prototype.jmulAdd=function(et,ei,es){var ef=[this,ei],eu=[et,es];return this.curve.endo?this.curve._endoWnafMulAdd(ef,eu,!0):this.curve._wnafMulAdd(1,ef,eu,2,!0)},eV.prototype.eq=function(et){return this===et||this.inf===et.inf&&(this.inf||0===this.x.cmp(et.x)&&0===this.y.cmp(et.y))},eV.prototype.neg=function(et){if(this.inf)return this;var ei=this.curve.point(this.x,this.y.redNeg());if(et&&this.precomputed){var es=this.precomputed,ef=function(et){return et.neg()};ei.precomputed={naf:es.naf&&{wnd:es.naf.wnd,points:es.naf.points.map(ef)},doubles:es.doubles&&{step:es.doubles.step,points:es.doubles.points.map(ef)}}}return ei},eV.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},ed(eM,em.BasePoint),ez.prototype.jpoint=function(et,ei,es){return new eM(this,et,ei,es)},eM.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var et=this.z.redInvm(),ei=et.redSqr(),es=this.x.redMul(ei),ef=this.y.redMul(ei).redMul(et);return this.curve.point(es,ef)},eM.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},eM.prototype.add=function(et){if(this.isInfinity())return et;if(et.isInfinity())return this;var ei=et.z.redSqr(),es=this.z.redSqr(),ef=this.x.redMul(ei),eu=et.x.redMul(es),ed=this.y.redMul(ei.redMul(et.z)),em=et.y.redMul(es.redMul(this.z)),eH=ef.redSub(eu),ez=ed.redSub(em);if(0===eH.cmpn(0))return 0!==ez.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var eV=eH.redSqr(),eM=eV.redMul(eH),eg=ef.redMul(eV),eL=ez.redSqr().redIAdd(eM).redISub(eg).redISub(eg),eb=ez.redMul(eg.redISub(eL)).redISub(ed.redMul(eM)),ey=this.z.redMul(et.z).redMul(eH);return this.curve.jpoint(eL,eb,ey)},eM.prototype.mixedAdd=function(et){if(this.isInfinity())return et.toJ();if(et.isInfinity())return this;var ei=this.z.redSqr(),es=this.x,ef=et.x.redMul(ei),eu=this.y,ed=et.y.redMul(ei).redMul(this.z),em=es.redSub(ef),eH=eu.redSub(ed);if(0===em.cmpn(0))return 0!==eH.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var ez=em.redSqr(),eV=ez.redMul(em),eM=es.redMul(ez),eg=eH.redSqr().redIAdd(eV).redISub(eM).redISub(eM),eL=eH.redMul(eM.redISub(eg)).redISub(eu.redMul(eV)),eb=this.z.redMul(em);return this.curve.jpoint(eg,eL,eb)},eM.prototype.dblp=function(et){if(0===et||this.isInfinity())return this;if(!et)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var ei=this,es=0;es=0)return!1;if(es.redIAdd(eu),0===this.x.cmp(es))return!0}},eM.prototype.inspect=function(){return this.isInfinity()?"":""},eM.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},6226:function(et,ei,es){"use strict";var ef,eu=ei,ed=es(7028),em=es(9359),eH=es(4401).assert;function ez(et){"short"===et.type?this.curve=new em.short(et):"edwards"===et.type?this.curve=new em.edwards(et):this.curve=new em.mont(et),this.g=this.curve.g,this.n=this.curve.n,this.hash=et.hash,eH(this.g.validate(),"Invalid curve"),eH(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function eV(et,ei){Object.defineProperty(eu,et,{configurable:!0,enumerable:!0,get:function(){var es=new ez(ei);return Object.defineProperty(eu,et,{configurable:!0,enumerable:!0,value:es}),es}})}eu.PresetCurve=ez,eV("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:ed.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),eV("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:ed.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),eV("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:ed.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),eV("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:ed.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"]}),eV("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:ed.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"]}),eV("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:ed.sha256,gRed:!1,g:["9"]}),eV("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:ed.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{ef=es(9702)}catch(et){ef=void 0}eV("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:ed.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",ef]})},4088:function(et,ei,es){"use strict";var ef=es(711),eu=es(4910),ed=es(4401),em=es(6226),eH=es(3500),ez=ed.assert,eV=es(4724),eM=es(7526);function eg(et){if(!(this instanceof eg))return new eg(et);"string"==typeof et&&(ez(em.hasOwnProperty(et),"Unknown curve "+et),et=em[et]),et instanceof em.PresetCurve&&(et={curve:et}),this.curve=et.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=et.curve.g,this.g.precompute(et.curve.n.bitLength()+1),this.hash=et.hash||et.curve.hash}et.exports=eg,eg.prototype.keyPair=function(et){return new eV(this,et)},eg.prototype.keyFromPrivate=function(et,ei){return eV.fromPrivate(this,et,ei)},eg.prototype.keyFromPublic=function(et,ei){return eV.fromPublic(this,et,ei)},eg.prototype.genKeyPair=function(et){et||(et={});for(var ei=new eu({hash:this.hash,pers:et.pers,persEnc:et.persEnc||"utf8",entropy:et.entropy||eH(this.hash.hmacStrength),entropyEnc:et.entropy&&et.entropyEnc||"utf8",nonce:this.n.toArray()}),es=this.n.byteLength(),ed=this.n.sub(new ef(2));;){var em=new ef(ei.generate(es));if(!(em.cmp(ed)>0))return em.iaddn(1),this.keyFromPrivate(em)}},eg.prototype._truncateToN=function(et,ei){var es=8*et.byteLength()-this.n.bitLength();return(es>0&&(et=et.ushrn(es)),!ei&&et.cmp(this.n)>=0)?et.sub(this.n):et},eg.prototype.sign=function(et,ei,es,ed){"object"==typeof es&&(ed=es,es=null),ed||(ed={}),ei=this.keyFromPrivate(ei,es),et=this._truncateToN(new ef(et,16));for(var em=this.n.byteLength(),eH=ei.getPrivate().toArray("be",em),ez=et.toArray("be",em),eV=new eu({hash:this.hash,entropy:eH,nonce:ez,pers:ed.pers,persEnc:ed.persEnc||"utf8"}),eg=this.n.sub(new ef(1)),eL=0;;eL++){var eb=ed.k?ed.k(eL):new ef(eV.generate(this.n.byteLength()));if(!(0>=(eb=this._truncateToN(eb,!0)).cmpn(1)||eb.cmp(eg)>=0)){var ey=this.g.mul(eb);if(!ey.isInfinity()){var eC=ey.getX(),ex=eC.umod(this.n);if(0!==ex.cmpn(0)){var ew=eb.invm(this.n).mul(ex.mul(ei.getPrivate()).iadd(et));if(0!==(ew=ew.umod(this.n)).cmpn(0)){var eN=(ey.getY().isOdd()?1:0)|(0!==eC.cmp(ex)?2:0);return ed.canonical&&ew.cmp(this.nh)>0&&(ew=this.n.sub(ew),eN^=1),new eM({r:ex,s:ew,recoveryParam:eN})}}}}}},eg.prototype.verify=function(et,ei,es,eu){et=this._truncateToN(new ef(et,16)),es=this.keyFromPublic(es,eu);var ed=(ei=new eM(ei,"hex")).r,em=ei.s;if(0>ed.cmpn(1)||ed.cmp(this.n)>=0||0>em.cmpn(1)||em.cmp(this.n)>=0)return!1;var eH=em.invm(this.n),ez=eH.mul(et).umod(this.n),eV=eH.mul(ed).umod(this.n);if(!this.curve._maxwellTrick){var eg=this.g.mulAdd(ez,es.getPublic(),eV);return!eg.isInfinity()&&0===eg.getX().umod(this.n).cmp(ed)}var eg=this.g.jmulAdd(ez,es.getPublic(),eV);return!eg.isInfinity()&&eg.eqXToP(ed)},eg.prototype.recoverPubKey=function(et,ei,es,eu){ez((3&es)===es,"The recovery param is more than two bits"),ei=new eM(ei,eu);var ed=this.n,em=new ef(et),eH=ei.r,eV=ei.s,eg=1&es,eL=es>>1;if(eH.cmp(this.curve.p.umod(this.curve.n))>=0&&eL)throw Error("Unable to find sencond key candinate");eH=eL?this.curve.pointFromX(eH.add(this.curve.n),eg):this.curve.pointFromX(eH,eg);var eb=ei.r.invm(ed),ey=ed.sub(em).mul(eb).umod(ed),eC=eV.mul(eb).umod(ed);return this.g.mulAdd(ey,eH,eC)},eg.prototype.getKeyRecoveryParam=function(et,ei,es,ef){if(null!==(ei=new eM(ei,ef)).recoveryParam)return ei.recoveryParam;for(var eu,ed=0;ed<4;ed++){try{eu=this.recoverPubKey(et,ei,ed)}catch(et){continue}if(eu.eq(es))return ed}throw Error("Unable to find valid recovery factor")}},4724:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401).assert;function ed(et,ei){this.ec=et,this.priv=null,this.pub=null,ei.priv&&this._importPrivate(ei.priv,ei.privEnc),ei.pub&&this._importPublic(ei.pub,ei.pubEnc)}et.exports=ed,ed.fromPublic=function(et,ei,es){return ei instanceof ed?ei:new ed(et,{pub:ei,pubEnc:es})},ed.fromPrivate=function(et,ei,es){return ei instanceof ed?ei:new ed(et,{priv:ei,privEnc:es})},ed.prototype.validate=function(){var et=this.getPublic();return et.isInfinity()?{result:!1,reason:"Invalid public key"}:et.validate()?et.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},ed.prototype.getPublic=function(et,ei){return("string"==typeof et&&(ei=et,et=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),ei)?this.pub.encode(ei,et):this.pub},ed.prototype.getPrivate=function(et){return"hex"===et?this.priv.toString(16,2):this.priv},ed.prototype._importPrivate=function(et,ei){this.priv=new ef(et,ei||16),this.priv=this.priv.umod(this.ec.curve.n)},ed.prototype._importPublic=function(et,ei){if(et.x||et.y){"mont"===this.ec.curve.type?eu(et.x,"Need x coordinate"):("short"===this.ec.curve.type||"edwards"===this.ec.curve.type)&&eu(et.x&&et.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(et.x,et.y);return}this.pub=this.ec.curve.decodePoint(et,ei)},ed.prototype.derive=function(et){return et.mul(this.priv).getX()},ed.prototype.sign=function(et,ei,es){return this.ec.sign(et,this,ei,es)},ed.prototype.verify=function(et,ei){return this.ec.verify(et,ei,this)},ed.prototype.inspect=function(){return""}},7526:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401),ed=eu.assert;function em(et,ei){if(et instanceof em)return et;this._importDER(et,ei)||(ed(et.r&&et.s,"Signature without r or s"),this.r=new ef(et.r,16),this.s=new ef(et.s,16),void 0===et.recoveryParam?this.recoveryParam=null:this.recoveryParam=et.recoveryParam)}function eH(){this.place=0}function ez(et,ei){var es=et[ei.place++];if(!(128&es))return es;var ef=15&es;if(0===ef||ef>4)return!1;for(var eu=0,ed=0,em=ei.place;ed>>=0;return!(eu<=127)&&(ei.place=em,eu)}function eV(et){for(var ei=0,es=et.length-1;!et[ei]&&!(128&et[ei+1])&&ei>>3);for(et.push(128|es);--es;)et.push(ei>>>(es<<3)&255);et.push(ei)}et.exports=em,em.prototype._importDER=function(et,ei){et=eu.toArray(et,ei);var es=new eH;if(48!==et[es.place++])return!1;var ed=ez(et,es);if(!1===ed||ed+es.place!==et.length||2!==et[es.place++])return!1;var em=ez(et,es);if(!1===em)return!1;var eV=et.slice(es.place,em+es.place);if(es.place+=em,2!==et[es.place++])return!1;var eM=ez(et,es);if(!1===eM||et.length!==eM+es.place)return!1;var eg=et.slice(es.place,eM+es.place);if(0===eV[0]){if(!(128&eV[1]))return!1;eV=eV.slice(1)}if(0===eg[0]){if(!(128&eg[1]))return!1;eg=eg.slice(1)}return this.r=new ef(eV),this.s=new ef(eg),this.recoveryParam=null,!0},em.prototype.toDER=function(et){var ei=this.r.toArray(),es=this.s.toArray();for(128&ei[0]&&(ei=[0].concat(ei)),128&es[0]&&(es=[0].concat(es)),ei=eV(ei),es=eV(es);!es[0]&&!(128&es[1]);)es=es.slice(1);var ef=[2];eM(ef,ei.length),(ef=ef.concat(ei)).push(2),eM(ef,es.length);var ed=ef.concat(es),em=[48];return eM(em,ed.length),em=em.concat(ed),eu.encode(em,et)}},8511:function(et,ei,es){"use strict";var ef=es(7028),eu=es(6226),ed=es(4401),em=ed.assert,eH=ed.parseBytes,ez=es(9917),eV=es(9314);function eM(et){if(em("ed25519"===et,"only tested with ed25519 so far"),!(this instanceof eM))return new eM(et);var et=eu[et].curve;this.curve=et,this.g=et.g,this.g.precompute(et.n.bitLength()+1),this.pointClass=et.point().constructor,this.encodingLength=Math.ceil(et.n.bitLength()/8),this.hash=ef.sha512}et.exports=eM,eM.prototype.sign=function(et,ei){et=eH(et);var es=this.keyFromSecret(ei),ef=this.hashInt(es.messagePrefix(),et),eu=this.g.mul(ef),ed=this.encodePoint(eu),em=this.hashInt(ed,es.pubBytes(),et).mul(es.priv()),ez=ef.add(em).umod(this.curve.n);return this.makeSignature({R:eu,S:ez,Rencoded:ed})},eM.prototype.verify=function(et,ei,es){et=eH(et),ei=this.makeSignature(ei);var ef=this.keyFromPublic(es),eu=this.hashInt(ei.Rencoded(),ef.pubBytes(),et),ed=this.g.mul(ei.S());return ei.R().add(ef.pub().mul(eu)).eq(ed)},eM.prototype.hashInt=function(){for(var et=this.hash(),ei=0;ei(eu>>1)-1?(eu>>1)-ez:ez,ed.isubn(eH)):eH=0,ef[em]=eH,ed.iushrn(1)}return ef}function ez(et,ei){var es=[[],[]];et=et.clone(),ei=ei.clone();for(var ef=0,eu=0;et.cmpn(-ef)>0||ei.cmpn(-eu)>0;){var ed,em,eH=et.andln(3)+ef&3,ez=ei.andln(3)+eu&3;if(3===eH&&(eH=-1),3===ez&&(ez=-1),(1&eH)==0)ed=0;else{var eV=et.andln(7)+ef&7;ed=(3===eV||5===eV)&&2===ez?-eH:eH}if(es[0].push(ed),(1&ez)==0)em=0;else{var eV=ei.andln(7)+eu&7;em=(3===eV||5===eV)&&2===eH?-ez:ez}es[1].push(em),2*ef===ed+1&&(ef=1-ef),2*eu===em+1&&(eu=1-eu),et.iushrn(1),ei.iushrn(1)}return es}function eV(et,ei,es){var ef="_"+ei;et.prototype[ei]=function(){return void 0!==this[ef]?this[ef]:this[ef]=es.call(this)}}function eM(et){return"string"==typeof et?ef.toArray(et,"hex"):et}function eg(et){return new eu(et,"hex","le")}ef.assert=ed,ef.toArray=em.toArray,ef.zero2=em.zero2,ef.toHex=em.toHex,ef.encode=em.encode,ef.getNAF=eH,ef.getJSF=ez,ef.cachedProperty=eV,ef.parseBytes=eM,ef.intFromLE=eg},8368:function(et,ei,es){var ef=es(6911).Buffer,eu=es(3533);function ed(et,ei,es,ed){if(ef.isBuffer(et)||(et=ef.from(et,"binary")),ei&&(ef.isBuffer(ei)||(ei=ef.from(ei,"binary")),8!==ei.length))throw RangeError("salt should be Buffer with 8 byte length");for(var em=es/8,eH=ef.alloc(em),ez=ef.alloc(ed||0),eV=ef.alloc(0);em>0||ed>0;){var eM=new eu;eM.update(eV),eM.update(et),ei&&eM.update(ei),eV=eM.digest();var eg=0;if(em>0){var eL=eH.length-em;eg=Math.min(em,eV.length),eV.copy(eH,eL,0,eg),em-=eg}if(eg0){var eb=ez.length-ed,ey=Math.min(ed,eV.length-eg);eV.copy(ez,eb,eg,eg+ey),ed-=ey}}return eV.fill(0),{key:eH,iv:ez}}et.exports=ed},9029:function(et,ei,es){"use strict";var ef=es(6911).Buffer,eu=es(3726).Transform;function ed(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError(ei+" must be a string or a buffer")}function em(et){eu.call(this),this._block=ef.allocUnsafe(et),this._blockSize=et,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}es(3782)(em,eu),em.prototype._transform=function(et,ei,es){var ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)},em.prototype._flush=function(et){var ei=null;try{this.push(this.digest())}catch(et){ei=et}et(ei)},em.prototype.update=function(et,ei){if(ed(et,"Data"),this._finalized)throw Error("Digest already called");ef.isBuffer(et)||(et=ef.from(et,ei));for(var es=this._block,eu=0;this._blockOffset+et.length-eu>=this._blockSize;){for(var em=this._blockOffset;em0;++eH)this._length[eH]+=ez,(ez=this._length[eH]/4294967296|0)>0&&(this._length[eH]-=4294967296*ez);return this},em.prototype._update=function(){throw Error("_update is not implemented")},em.prototype.digest=function(et){if(this._finalized)throw Error("Digest already called");this._finalized=!0;var ei=this._digest();void 0!==et&&(ei=ei.toString(et)),this._block.fill(0),this._blockOffset=0;for(var es=0;es<4;++es)this._length[es]=0;return ei},em.prototype._digest=function(){throw Error("_digest is not implemented")},et.exports=em},7028:function(et,ei,es){var ef=ei;ef.utils=es(263),ef.common=es(1330),ef.sha=es(301),ef.ripemd=es(3079),ef.hmac=es(3092),ef.sha1=ef.sha.sha1,ef.sha256=ef.sha.sha256,ef.sha224=ef.sha.sha224,ef.sha384=ef.sha.sha384,ef.sha512=ef.sha.sha512,ef.ripemd160=ef.ripemd.ripemd160},1330:function(et,ei,es){"use strict";var ef=es(263),eu=es(3523);function ed(){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}ei.BlockHash=ed,ed.prototype.update=function(et,ei){if(et=ef.toArray(et,ei),this.pending?this.pending=this.pending.concat(et):this.pending=et,this.pendingTotal+=et.length,this.pending.length>=this._delta8){var es=(et=this.pending).length%this._delta8;this.pending=et.slice(et.length-es,et.length),0===this.pending.length&&(this.pending=null),et=ef.join32(et,0,et.length-es,this.endian);for(var eu=0;eu>>24&255,ef[eu++]=et>>>16&255,ef[eu++]=et>>>8&255,ef[eu++]=255&et}else for(ed=8,ef[eu++]=255&et,ef[eu++]=et>>>8&255,ef[eu++]=et>>>16&255,ef[eu++]=et>>>24&255,ef[eu++]=0,ef[eu++]=0,ef[eu++]=0,ef[eu++]=0;edthis.blockSize&&(et=(new this.Hash).update(et).digest()),eu(et.length<=this.blockSize);for(var ei=et.length;ei>>3}function eg(et){return ef(et,17)^ef(et,19)^et>>>10}ei.ft_1=eu,ei.ch32=ed,ei.maj32=em,ei.p32=eH,ei.s0_256=ez,ei.s1_256=eV,ei.g0_256=eM,ei.g1_256=eg},263:function(et,ei,es){"use strict";var ef=es(3523),eu=es(3782);function ed(et,ei){return(64512&et.charCodeAt(ei))==55296&&!(ei<0)&&!(ei+1>=et.length)&&(64512&et.charCodeAt(ei+1))==56320}function em(et,ei){if(Array.isArray(et))return et.slice();if(!et)return[];var es=[];if("string"==typeof et){if(ei){if("hex"===ei)for((et=et.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(et="0"+et),eu=0;eu>6|192,es[ef++]=63&em|128):ed(et,eu)?(em=65536+((1023&em)<<10)+(1023&et.charCodeAt(++eu)),es[ef++]=em>>18|240,es[ef++]=em>>12&63|128,es[ef++]=em>>6&63|128,es[ef++]=63&em|128):(es[ef++]=em>>12|224,es[ef++]=em>>6&63|128,es[ef++]=63&em|128)}}else for(eu=0;eu>>24|et>>>8&65280|et<<8&16711680|(255&et)<<24)>>>0}function eV(et,ei){for(var es="",ef=0;ef>>0;return eH}function eb(et,ei){for(var es=Array(4*et.length),ef=0,eu=0;ef>>24,es[eu+1]=ed>>>16&255,es[eu+2]=ed>>>8&255,es[eu+3]=255&ed):(es[eu+3]=ed>>>24,es[eu+2]=ed>>>16&255,es[eu+1]=ed>>>8&255,es[eu]=255&ed)}return es}function ey(et,ei){return et>>>ei|et<<32-ei}function eC(et,ei){return et<>>32-ei}function ex(et,ei){return et+ei>>>0}function ew(et,ei,es){return et+ei+es>>>0}function eN(et,ei,es,ef){return et+ei+es+ef>>>0}function eS(et,ei,es,ef,eu){return et+ei+es+ef+eu>>>0}function eA(et,ei,es,ef){var eu=et[ei],ed=ef+et[ei+1]>>>0,em=(ed>>0,et[ei+1]=ed}function e_(et,ei,es,ef){return(ei+ef>>>0>>0}function eE(et,ei,es,ef){return ei+ef>>>0}function eP(et,ei,es,ef,eu,ed,em,eH){var ez,eV=ei;return et+es+eu+em+(ez=0+((eV=eV+ef>>>0)>>0)>>0)>>0}function eB(et,ei,es,ef,eu,ed,em,eH){return ei+ef+ed+eH>>>0}function eT(et,ei,es,ef,eu,ed,em,eH,ez,eV){var eM,eg=ei;return et+es+eu+em+ez+(eM=0+((eg=eg+ef>>>0)>>0)>>0)>>0)>>0}function eI(et,ei,es,ef,eu,ed,em,eH,ez,eV){return ei+ef+ed+eH+eV>>>0}function eR(et,ei,es){return(ei<<32-es|et>>>es)>>>0}function eO(et,ei,es){return(et<<32-es|ei>>>es)>>>0}function ej(et,ei,es){return et>>>es}function eD(et,ei,es){return(et<<32-es|ei>>>es)>>>0}ei.inherits=eu,ei.toArray=em,ei.toHex=eH,ei.htonl=ez,ei.toHex32=eV,ei.zero2=eM,ei.zero8=eg,ei.join32=eL,ei.split32=eb,ei.rotr32=ey,ei.rotl32=eC,ei.sum32=ex,ei.sum32_3=ew,ei.sum32_4=eN,ei.sum32_5=eS,ei.sum64=eA,ei.sum64_hi=e_,ei.sum64_lo=eE,ei.sum64_4_hi=eP,ei.sum64_4_lo=eB,ei.sum64_5_hi=eT,ei.sum64_5_lo=eI,ei.rotr64_hi=eR,ei.rotr64_lo=eO,ei.shr64_hi=ej,ei.shr64_lo=eD},4910:function(et,ei,es){"use strict";var ef=es(7028),eu=es(6545),ed=es(3523);function em(et){if(!(this instanceof em))return new em(et);this.hash=et.hash,this.predResist=!!et.predResist,this.outLen=this.hash.outSize,this.minEntropy=et.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var ei=eu.toArray(et.entropy,et.entropyEnc||"hex"),es=eu.toArray(et.nonce,et.nonceEnc||"hex"),ef=eu.toArray(et.pers,et.persEnc||"hex");ed(ei.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(ei,es,ef)}et.exports=em,em.prototype._init=function(et,ei,es){var ef=et.concat(ei).concat(es);this.K=Array(this.outLen/8),this.V=Array(this.outLen/8);for(var eu=0;eu=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(et.concat(es||[])),this._reseed=1},em.prototype.generate=function(et,ei,es,ef){if(this._reseed>this.reseedInterval)throw Error("Reseed is required");"string"!=typeof ei&&(ef=es,es=ei,ei=null),es&&(es=eu.toArray(es,ef||"hex"),this._update(es));for(var ed=[];ed.length>>32-ei}function eV(et,ei,es,ef,eu,ed,em){return ez(et+(ei&es|~ei&ef)+eu+ed|0,em)+ei|0}function eM(et,ei,es,ef,eu,ed,em){return ez(et+(ei&ef|es&~ef)+eu+ed|0,em)+ei|0}function eg(et,ei,es,ef,eu,ed,em){return ez(et+(ei^es^ef)+eu+ed|0,em)+ei|0}function eL(et,ei,es,ef,eu,ed,em){return ez(et+(es^(ei|~ef))+eu+ed|0,em)+ei|0}ef(eH,eu),eH.prototype._update=function(){for(var et=em,ei=0;ei<16;++ei)et[ei]=this._block.readInt32LE(4*ei);var es=this._a,ef=this._b,eu=this._c,ed=this._d;es=eV(es,ef,eu,ed,et[0],3614090360,7),ed=eV(ed,es,ef,eu,et[1],3905402710,12),eu=eV(eu,ed,es,ef,et[2],606105819,17),ef=eV(ef,eu,ed,es,et[3],3250441966,22),es=eV(es,ef,eu,ed,et[4],4118548399,7),ed=eV(ed,es,ef,eu,et[5],1200080426,12),eu=eV(eu,ed,es,ef,et[6],2821735955,17),ef=eV(ef,eu,ed,es,et[7],4249261313,22),es=eV(es,ef,eu,ed,et[8],1770035416,7),ed=eV(ed,es,ef,eu,et[9],2336552879,12),eu=eV(eu,ed,es,ef,et[10],4294925233,17),ef=eV(ef,eu,ed,es,et[11],2304563134,22),es=eV(es,ef,eu,ed,et[12],1804603682,7),ed=eV(ed,es,ef,eu,et[13],4254626195,12),eu=eV(eu,ed,es,ef,et[14],2792965006,17),ef=eV(ef,eu,ed,es,et[15],1236535329,22),es=eM(es,ef,eu,ed,et[1],4129170786,5),ed=eM(ed,es,ef,eu,et[6],3225465664,9),eu=eM(eu,ed,es,ef,et[11],643717713,14),ef=eM(ef,eu,ed,es,et[0],3921069994,20),es=eM(es,ef,eu,ed,et[5],3593408605,5),ed=eM(ed,es,ef,eu,et[10],38016083,9),eu=eM(eu,ed,es,ef,et[15],3634488961,14),ef=eM(ef,eu,ed,es,et[4],3889429448,20),es=eM(es,ef,eu,ed,et[9],568446438,5),ed=eM(ed,es,ef,eu,et[14],3275163606,9),eu=eM(eu,ed,es,ef,et[3],4107603335,14),ef=eM(ef,eu,ed,es,et[8],1163531501,20),es=eM(es,ef,eu,ed,et[13],2850285829,5),ed=eM(ed,es,ef,eu,et[2],4243563512,9),eu=eM(eu,ed,es,ef,et[7],1735328473,14),ef=eM(ef,eu,ed,es,et[12],2368359562,20),es=eg(es,ef,eu,ed,et[5],4294588738,4),ed=eg(ed,es,ef,eu,et[8],2272392833,11),eu=eg(eu,ed,es,ef,et[11],1839030562,16),ef=eg(ef,eu,ed,es,et[14],4259657740,23),es=eg(es,ef,eu,ed,et[1],2763975236,4),ed=eg(ed,es,ef,eu,et[4],1272893353,11),eu=eg(eu,ed,es,ef,et[7],4139469664,16),ef=eg(ef,eu,ed,es,et[10],3200236656,23),es=eg(es,ef,eu,ed,et[13],681279174,4),ed=eg(ed,es,ef,eu,et[0],3936430074,11),eu=eg(eu,ed,es,ef,et[3],3572445317,16),ef=eg(ef,eu,ed,es,et[6],76029189,23),es=eg(es,ef,eu,ed,et[9],3654602809,4),ed=eg(ed,es,ef,eu,et[12],3873151461,11),eu=eg(eu,ed,es,ef,et[15],530742520,16),ef=eg(ef,eu,ed,es,et[2],3299628645,23),es=eL(es,ef,eu,ed,et[0],4096336452,6),ed=eL(ed,es,ef,eu,et[7],1126891415,10),eu=eL(eu,ed,es,ef,et[14],2878612391,15),ef=eL(ef,eu,ed,es,et[5],4237533241,21),es=eL(es,ef,eu,ed,et[12],1700485571,6),ed=eL(ed,es,ef,eu,et[3],2399980690,10),eu=eL(eu,ed,es,ef,et[10],4293915773,15),ef=eL(ef,eu,ed,es,et[1],2240044497,21),es=eL(es,ef,eu,ed,et[8],1873313359,6),ed=eL(ed,es,ef,eu,et[15],4264355552,10),eu=eL(eu,ed,es,ef,et[6],2734768916,15),ef=eL(ef,eu,ed,es,et[13],1309151649,21),es=eL(es,ef,eu,ed,et[4],4149444226,6),ed=eL(ed,es,ef,eu,et[11],3174756917,10),eu=eL(eu,ed,es,ef,et[2],718787259,15),ef=eL(ef,eu,ed,es,et[9],3951481745,21),this._a=this._a+es|0,this._b=this._b+ef|0,this._c=this._c+eu|0,this._d=this._d+ed|0},eH.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ed.allocUnsafe(16);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et},et.exports=eH},1354:function(et,ei,es){var ef=es(711),eu=es(3500);function ed(et){this.rand=et||new eu.Rand}et.exports=ed,ed.create=function(et){return new ed(et)},ed.prototype._randbelow=function(et){var ei=Math.ceil(et.bitLength()/8);do var es=new ef(this.rand.generate(ei));while(es.cmp(et)>=0);return es},ed.prototype._randrange=function(et,ei){var es=ei.sub(et);return et.add(this._randbelow(es))},ed.prototype.test=function(et,ei,es){var eu=et.bitLength(),ed=ef.mont(et),em=new ef(1).toRed(ed);ei||(ei=Math.max(1,eu/48|0));for(var eH=et.subn(1),ez=0;!eH.testn(ez);ez++);for(var eV=et.shrn(ez),eM=eH.toRed(ed),eg=!0;ei>0;ei--){var eL=this._randrange(new ef(2),eH);es&&es(eL);var eb=eL.toRed(ed).redPow(eV);if(0!==eb.cmp(em)&&0!==eb.cmp(eM)){for(var ey=1;ey0;ei--){var eM=this._randrange(new ef(2),em),eg=et.gcd(eM);if(0!==eg.cmpn(1))return eg;var eL=eM.toRed(eu).redPow(ez);if(0!==eL.cmp(ed)&&0!==eL.cmp(eV)){for(var eb=1;eb>8,em=255&eu;ed?es.push(ed,em):es.push(em)}return es}function eu(et){return 1===et.length?"0"+et:et}function ed(et){for(var ei="",es=0;esei||es!=es)throw TypeError("Bad key length")}},2127:function(et,ei,es){var ef={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20},eu=es(4873),ed=es(6911).Buffer,em=es(5349),eH=es(7007),ez=es(5407);function eV(et,ei,es,eV,eM){em(es,eV),et=ez(et,eH,"Password"),ei=ez(ei,eH,"Salt"),eM=eM||"sha1";var eg=ed.allocUnsafe(eV),eL=ed.allocUnsafe(ei.length+4);ei.copy(eL,0,0,ei.length);for(var eb=0,ey=ef[eM],eC=Math.ceil(eV/ey),ex=1;ex<=eC;ex++){eL.writeUInt32BE(ex,ei.length);for(var ew=eu(eM,et).update(eL).digest(),eN=ew,eS=1;eS=ei.length){ed++;break}var em=ei.slice(2,eu-1);if(("0002"!==ef.toString("hex")&&!es||"0001"!==ef.toString("hex")&&es)&&ed++,em.length<8&&ed++,ed)throw Error("decryption error");return ei.slice(eu)}function eb(et,ei){et=eM.from(et),ei=eM.from(ei);var es=0,ef=et.length;et.length!==ei.length&&(es++,ef=Math.min(et.length,ei.length));for(var eu=-1;++eueb||new em(ei).cmp(ez.modulus)>=0)throw Error("decryption error");ed=es?eV(new em(ei),ez):eH(ei,ez);var ey=eM.alloc(eb-ed.length);if(ed=eM.concat([ey,ed],eb),4===eu)return eg(ez,ed);if(1===eu)return eL(ez,ed,es);if(3===eu)return ed;throw Error("unknown padding")}},3995:function(et,ei,es){var ef=es(9902),eu=es(7223),ed=es(9739),em=es(5520),eH=es(6386),ez=es(711),eV=es(1607),eM=es(7166),eg=es(6911).Buffer;function eL(et,ei){var es=et.modulus.byteLength(),ef=ei.length,eV=ed("sha1").update(eg.alloc(0)).digest(),eM=eV.length,eL=2*eM;if(ef>es-eL-2)throw Error("message too long");var eb=eg.alloc(es-ef-eL-2),ey=es-eM-1,eC=eu(eM),ex=eH(eg.concat([eV,eb,eg.alloc(1,1),ei],ey),em(eC,ey)),ew=eH(eC,em(ex,eM));return new ez(eg.concat([eg.alloc(1),ew,ex],es))}function eb(et,ei,es){var ef,eu=ei.length,ed=et.modulus.byteLength();if(eu>ed-11)throw Error("message too long");return ef=es?eg.alloc(ed-eu-3,255):ey(ed-eu-3),new ez(eg.concat([eg.from([0,es?1:2]),ef,eg.alloc(1),ei],ed))}function ey(et){for(var ei,es=eg.allocUnsafe(et),ef=0,ed=eu(2*et),em=0;ef=0)throw Error("data too long for modulus")}else throw Error("unknown padding");return es?eM(ed,em):eV(ed,em)}},1607:function(et,ei,es){var ef=es(711),eu=es(6911).Buffer;function ed(et,ei){return eu.from(et.toRed(ef.mont(ei.modulus)).redPow(new ef(ei.publicExponent)).fromRed().toArray())}et.exports=ed},6386:function(et){et.exports=function(et,ei){for(var es=et.length,ef=-1;++efem)throw RangeError("requested too many random bytes");var es=ez.allocUnsafe(et);if(et>0){if(et>eu)for(var ef=0;efeM||et<0)throw TypeError("offset must be a uint32");if(et>ez||et>ei)throw RangeError("offset out of range")}function eL(et,ei,es){if("number"!=typeof et||et!=et)throw TypeError("size must be a number");if(et>eM||et<0)throw TypeError("size must be a uint32");if(et+ei>es||et>ez)throw RangeError("buffer too small")}function eb(et,ei,ef,eu){if(!eH.isBuffer(et)&&!(et instanceof es.g.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof ei)eu=ei,ei=0,ef=et.length;else if("function"==typeof ef)eu=ef,ef=et.length-ei;else if("function"!=typeof eu)throw TypeError('"cb" argument must be a function');return eg(ei,et.length),eL(ef,ei,et.length),ey(et,ei,ef,eu)}function ey(et,ei,es,ef){var eu=et.buffer,em=new Uint8Array(eu,ei,es);if(eV.getRandomValues(em),ef){ed.nextTick(function(){ef(null,et)});return}return et}function eC(et,ei,ef){if(void 0===ei&&(ei=0),!eH.isBuffer(et)&&!(et instanceof es.g.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');return eg(ei,et.length),void 0===ef&&(ef=et.length-ei),eL(ef,ei,et.length),ey(et,ei,ef)}eV&&eV.getRandomValues?(ei.randomFill=eb,ei.randomFillSync=eC):(ei.randomFill=eu,ei.randomFillSync=eu)},4646:function(et){"use strict";let ei={};function es(et,es,ef){function eu(et,ei,ef){return"string"==typeof es?es:es(et,ei,ef)}ef||(ef=Error);class ed extends ef{constructor(et,ei,es){super(eu(et,ei,es))}}ed.prototype.name=ef.name,ed.prototype.code=et,ei[et]=ed}function ef(et,ei){if(!Array.isArray(et))return`of ${ei} ${String(et)}`;{let es=et.length;return(et=et.map(et=>String(et)),es>2)?`one of ${ei} ${et.slice(0,es-1).join(", ")}, or `+et[es-1]:2===es?`one of ${ei} ${et[0]} or ${et[1]}`:`of ${ei} ${et[0]}`}}function eu(et,ei,es){return et.substr(!es||es<0?0:+es,ei.length)===ei}function ed(et,ei,es){return(void 0===es||es>et.length)&&(es=et.length),et.substring(es-ei.length,es)===ei}function em(et,ei,es){return"number"!=typeof es&&(es=0),!(es+ei.length>et.length)&&-1!==et.indexOf(ei,es)}es("ERR_INVALID_OPT_VALUE",function(et,ei){return'The value "'+ei+'" is invalid for option "'+et+'"'},TypeError),es("ERR_INVALID_ARG_TYPE",function(et,ei,es){let eH,ez;if("string"==typeof ei&&eu(ei,"not ")?(eH="must not be",ei=ei.replace(/^not /,"")):eH="must be",ed(et," argument"))ez=`The ${et} ${eH} ${ef(ei,"type")}`;else{let es=em(et,".")?"property":"argument";ez=`The "${et}" ${es} ${eH} ${ef(ei,"type")}`}return ez+`. Received type ${typeof es}`},TypeError),es("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),es("ERR_METHOD_NOT_IMPLEMENTED",function(et){return"The "+et+" method is not implemented"}),es("ERR_STREAM_PREMATURE_CLOSE","Premature close"),es("ERR_STREAM_DESTROYED",function(et){return"Cannot call "+et+" after a stream was destroyed"}),es("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),es("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),es("ERR_STREAM_WRITE_AFTER_END","write after end"),es("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),es("ERR_UNKNOWN_ENCODING",function(et){return"Unknown encoding: "+et},TypeError),es("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),et.exports.q=ei},2403:function(et,ei,es){"use strict";var ef=Object.keys||function(et){var ei=[];for(var es in et)ei.push(es);return ei};et.exports=eM;var eu=es(1709),em=es(7337);es(3782)(eM,eu);for(var eH=ef(em.prototype),ez=0;ez0){if("string"==typeof ei||eH.objectMode||Object.getPrototypeOf(ei)===eL.prototype||(ei=ey(ei)),ef)eH.endEmitted?eT(et,new eB):eF(et,eH,ei,!0);else if(eH.ended)eT(et,new eE);else{if(eH.destroyed)return!1;eH.reading=!1,eH.decoder&&!es?(ei=eH.decoder.write(ei),eH.objectMode||0!==ei.length?eF(et,eH,ei,!1):eJ(et,eH)):eF(et,eH,ei,!1)}}else ef||(eH.reading=!1,eJ(et,eH));return!eH.ended&&(eH.length=eq?et=eq:(et--,et|=et>>>1,et|=et>>>2,et|=et>>>4,et|=et>>>8,et|=et>>>16,et++),et}function eG(et,ei){return et<=0||0===ei.length&&ei.ended?0:ei.objectMode?1:et!=et?ei.flowing&&ei.length?ei.buffer.head.data.length:ei.length:(et>ei.highWaterMark&&(ei.highWaterMark=eZ(et)),et<=ei.length)?et:ei.ended?ei.length:(ei.needReadable=!0,0)}function eW(et,ei){if(em("onEofChunk"),!ei.ended){if(ei.decoder){var es=ei.decoder.end();es&&es.length&&(ei.buffer.push(es),ei.length+=ei.objectMode?1:es.length)}ei.ended=!0,ei.sync?eK(et):(ei.needReadable=!1,ei.emittedReadable||(ei.emittedReadable=!0,e$(et)))}}function eK(et){var ei=et._readableState;em("emitReadable",ei.needReadable,ei.emittedReadable),ei.needReadable=!1,ei.emittedReadable||(em("emitReadable",ei.flowing),ei.emittedReadable=!0,ed.nextTick(e$,et))}function e$(et){var ei=et._readableState;em("emitReadable_",ei.destroyed,ei.length,ei.ended),!ei.destroyed&&(ei.length||ei.ended)&&(et.emit("readable"),ei.emittedReadable=!1),ei.needReadable=!ei.flowing&&!ei.ended&&ei.length<=ei.highWaterMark,e3(et)}function eJ(et,ei){ei.readingMore||(ei.readingMore=!0,ed.nextTick(eY,et,ei))}function eY(et,ei){for(;!ei.reading&&!ei.ended&&(ei.length0,ei.resumeScheduled&&!ei.paused?ei.flowing=!0:et.listenerCount("data")>0&&et.resume()}function e1(et){em("readable nexttick read 0"),et.read(0)}function e2(et,ei){ei.resumeScheduled||(ei.resumeScheduled=!0,ed.nextTick(e4,et,ei))}function e4(et,ei){em("resume",ei.reading),ei.reading||et.read(0),ei.resumeScheduled=!1,et.emit("resume"),e3(et),ei.flowing&&!ei.reading&&et.read(0)}function e3(et){var ei=et._readableState;for(em("flow",ei.flowing);ei.flowing&&null!==et.read(););}function e6(et,ei){var es;return 0===ei.length?null:(ei.objectMode?es=ei.buffer.shift():!et||et>=ei.length?(es=ei.decoder?ei.buffer.join(""):1===ei.buffer.length?ei.buffer.first():ei.buffer.concat(ei.length),ei.buffer.clear()):es=ei.buffer.consume(et,ei.decoder),es)}function e0(et){var ei=et._readableState;em("endReadable",ei.endEmitted),ei.endEmitted||(ei.ended=!0,ed.nextTick(e8,ei,et))}function e8(et,ei){if(em("endReadableNT",et.endEmitted,et.length),!et.endEmitted&&0===et.length&&(et.endEmitted=!0,ei.readable=!1,ei.emit("end"),et.autoDestroy)){var es=ei._writableState;(!es||es.autoDestroy&&es.finished)&&ei.destroy()}}function e5(et,ei){for(var es=0,ef=et.length;es=es.highWaterMark:es.length>0)||es.ended))return em("read: emitReadable",es.length,es.ended),0===es.length&&es.ended?e0(this):eK(this),null;if(0===(et=eG(et,es))&&es.ended)return 0===es.length&&e0(this),null;var eu=es.needReadable;return em("need readable",eu),(0===es.length||es.length-et0?e6(et,es):null)?(es.needReadable=es.length<=es.highWaterMark,et=0):(es.length-=et,es.awaitDrain=0),0===es.length&&(es.ended||(es.needReadable=!0),ef!==et&&es.ended&&e0(this)),null!==ei&&this.emit("data",ei),ei},ej.prototype._read=function(et){eT(this,new eP("_read()"))},ej.prototype.pipe=function(et,ei){var es=this,ef=this._readableState;switch(ef.pipesCount){case 0:ef.pipes=et;break;case 1:ef.pipes=[ef.pipes,et];break;default:ef.pipes.push(et)}ef.pipesCount+=1,em("pipe count=%d opts=%j",ef.pipesCount,ei);var eu=ei&&!1===ei.end||et===ed.stdout||et===ed.stderr?ew:ez;function eH(et,ei){em("onunpipe"),et===es&&ei&&!1===ei.hasUnpiped&&(ei.hasUnpiped=!0,eL())}function ez(){em("onend"),et.end()}ef.endEmitted?ed.nextTick(eu):es.once("end",eu),et.on("unpipe",eH);var eV=eX(es);et.on("drain",eV);var eg=!1;function eL(){em("cleanup"),et.removeListener("close",eC),et.removeListener("finish",ex),et.removeListener("drain",eV),et.removeListener("error",ey),et.removeListener("unpipe",eH),es.removeListener("end",ez),es.removeListener("end",ew),es.removeListener("data",eb),eg=!0,ef.awaitDrain&&(!et._writableState||et._writableState.needDrain)&&eV()}function eb(ei){em("ondata");var eu=et.write(ei);em("dest.write",eu),!1===eu&&((1===ef.pipesCount&&ef.pipes===et||ef.pipesCount>1&&-1!==e5(ef.pipes,et))&&!eg&&(em("false write response, pause",ef.awaitDrain),ef.awaitDrain++),es.pause())}function ey(ei){em("onerror",ei),ew(),et.removeListener("error",ey),0===eM(et,"error")&&eT(et,ei)}function eC(){et.removeListener("finish",ex),ew()}function ex(){em("onfinish"),et.removeListener("close",eC),ew()}function ew(){em("unpipe"),es.unpipe(et)}return es.on("data",eb),eR(et,"error",ey),et.once("close",eC),et.once("finish",ex),et.emit("pipe",es),ef.flowing||(em("pipe resume"),es.resume()),et},ej.prototype.unpipe=function(et){var ei=this._readableState,es={hasUnpiped:!1};if(0===ei.pipesCount)return this;if(1===ei.pipesCount)return et&&et!==ei.pipes||(et||(et=ei.pipes),ei.pipes=null,ei.pipesCount=0,ei.flowing=!1,et&&et.emit("unpipe",this,es)),this;if(!et){var ef=ei.pipes,eu=ei.pipesCount;ei.pipes=null,ei.pipesCount=0,ei.flowing=!1;for(var ed=0;ed0,!1!==ef.flowing&&this.resume()):"readable"!==et||ef.endEmitted||ef.readableListening||(ef.readableListening=ef.needReadable=!0,ef.flowing=!1,ef.emittedReadable=!1,em("on readable",ef.length,ef.reading),ef.length?eK(this):ef.reading||ed.nextTick(e1,this)),es},ej.prototype.addListener=ej.prototype.on,ej.prototype.removeListener=function(et,ei){var es=eg.prototype.removeListener.call(this,et,ei);return"readable"===et&&ed.nextTick(eQ,this),es},ej.prototype.removeAllListeners=function(et){var ei=eg.prototype.removeAllListeners.apply(this,arguments);return("readable"===et||void 0===et)&&ed.nextTick(eQ,this),ei},ej.prototype.resume=function(){var et=this._readableState;return et.flowing||(em("resume"),et.flowing=!et.readableListening,e2(this,et)),et.paused=!1,this},ej.prototype.pause=function(){return em("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(em("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},ej.prototype.wrap=function(et){var ei=this,es=this._readableState,ef=!1;for(var eu in et.on("end",function(){if(em("wrapped end"),es.decoder&&!es.ended){var et=es.decoder.end();et&&et.length&&ei.push(et)}ei.push(null)}),et.on("data",function(eu){em("wrapped data"),es.decoder&&(eu=es.decoder.write(eu)),(!es.objectMode||null!=eu)&&(es.objectMode||eu&&eu.length)&&(ei.push(eu)||(ef=!0,et.pause()))}),et)void 0===this[eu]&&"function"==typeof et[eu]&&(this[eu]=function(ei){return function(){return et[ei].apply(et,arguments)}}(eu));for(var ed=0;ed-1))throw new eB(et);return this._writableState.defaultEncoding=et,this},Object.defineProperty(eO.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(eO.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),eO.prototype._write=function(et,ei,es){es(new eN("_write()"))},eO.prototype._writev=null,eO.prototype.end=function(et,ei,es){var ef=this._writableState;return"function"==typeof et?(es=et,et=null,ei=null):"function"==typeof ei&&(es=ei,ei=null),null!=et&&this.write(et,ei),ef.corked&&(ef.corked=1,this.uncork()),ef.ending||e2(this,ef,es),this},Object.defineProperty(eO.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(eO.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(et){this._writableState&&(this._writableState.destroyed=et)}}),eO.prototype.destroy=ey.destroy,eO.prototype._undestroy=ey.undestroy,eO.prototype._destroy=function(et,ei){ei(et)}},6871:function(et,ei,es){"use strict";function ef(et,ei,es){return ei in et?Object.defineProperty(et,ei,{value:es,enumerable:!0,configurable:!0,writable:!0}):et[ei]=es,et}var eu,em=es(9698),eH=Symbol("lastResolve"),ez=Symbol("lastReject"),eV=Symbol("error"),eM=Symbol("ended"),eg=Symbol("lastPromise"),eL=Symbol("handlePromise"),eb=Symbol("stream");function ey(et,ei){return{value:et,done:ei}}function eC(et){var ei=et[eH];if(null!==ei){var es=et[eb].read();null!==es&&(et[eg]=null,et[eH]=null,et[ez]=null,ei(ey(es,!1)))}}function ex(et){ed.nextTick(eC,et)}function ew(et,ei){return function(es,ef){et.then(function(){if(ei[eM]){es(ey(void 0,!0));return}ei[eL](es,ef)},ef)}}var eN=Object.getPrototypeOf(function(){}),eS=Object.setPrototypeOf((ef(eu={get stream(){return this[eb]},next:function(){var et,ei=this,es=this[eV];if(null!==es)return Promise.reject(es);if(this[eM])return Promise.resolve(ey(void 0,!0));if(this[eb].destroyed)return new Promise(function(et,es){ed.nextTick(function(){ei[eV]?es(ei[eV]):et(ey(void 0,!0))})});var ef=this[eg];if(ef)et=new Promise(ew(ef,this));else{var eu=this[eb].read();if(null!==eu)return Promise.resolve(ey(eu,!1));et=new Promise(this[eL])}return this[eg]=et,et}},Symbol.asyncIterator,function(){return this}),ef(eu,"return",function(){var et=this;return new Promise(function(ei,es){et[eb].destroy(null,function(et){if(et){es(et);return}ei(ey(void 0,!0))})})}),eu),eN),eA=function(et){var ei,es=Object.create(eS,(ef(ei={},eb,{value:et,writable:!0}),ef(ei,eH,{value:null,writable:!0}),ef(ei,ez,{value:null,writable:!0}),ef(ei,eV,{value:null,writable:!0}),ef(ei,eM,{value:et._readableState.endEmitted,writable:!0}),ef(ei,eL,{value:function(et,ei){var ef=es[eb].read();ef?(es[eg]=null,es[eH]=null,es[ez]=null,et(ey(ef,!1))):(es[eH]=et,es[ez]=ei)},writable:!0}),ei));return es[eg]=null,em(et,function(et){if(et&&"ERR_STREAM_PREMATURE_CLOSE"!==et.code){var ei=es[ez];null!==ei&&(es[eg]=null,es[eH]=null,es[ez]=null,ei(et)),es[eV]=et;return}var ef=es[eH];null!==ef&&(es[eg]=null,es[eH]=null,es[ez]=null,ef(ey(void 0,!0))),es[eM]=!0}),et.on("readable",ex.bind(null,es)),es};et.exports=eA},4379:function(et,ei,es){"use strict";function ef(et,ei){var es=Object.keys(et);if(Object.getOwnPropertySymbols){var ef=Object.getOwnPropertySymbols(et);ei&&(ef=ef.filter(function(ei){return Object.getOwnPropertyDescriptor(et,ei).enumerable})),es.push.apply(es,ef)}return es}function eu(et){for(var ei=1;ei0?this.tail.next=ei:this.head=ei,this.tail=ei,++this.length}},{key:"unshift",value:function(et){var ei={data:et,next:this.head};0===this.length&&(this.tail=ei),this.head=ei,++this.length}},{key:"shift",value:function(){if(0!==this.length){var et=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,et}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(et){if(0===this.length)return"";for(var ei=this.head,es=""+ei.data;ei=ei.next;)es+=et+ei.data;return es}},{key:"concat",value:function(et){if(0===this.length)return eV.alloc(0);for(var ei=eV.allocUnsafe(et>>>0),es=this.head,ef=0;es;)eL(es.data,ei,ef),ef+=es.data.length,es=es.next;return ei}},{key:"consume",value:function(et,ei){var es;return eteu.length?eu.length:et;if(ed===eu.length?ef+=eu:ef+=eu.slice(0,et),0==(et-=ed)){ed===eu.length?(++es,ei.next?this.head=ei.next:this.head=this.tail=null):(this.head=ei,ei.data=eu.slice(ed));break}++es}return this.length-=es,ef}},{key:"_getBuffer",value:function(et){var ei=eV.allocUnsafe(et),es=this.head,ef=1;for(es.data.copy(ei),et-=es.data.length;es=es.next;){var eu=es.data,ed=et>eu.length?eu.length:et;if(eu.copy(ei,ei.length-et,0,ed),0==(et-=ed)){ed===eu.length?(++ef,es.next?this.head=es.next:this.head=this.tail=null):(this.head=es,es.data=eu.slice(ed));break}++ef}return this.length-=ef,ei}},{key:eg,value:function(et,ei){return eM(this,eu({},ei,{depth:0,customInspect:!1}))}}]),et}()},7025:function(et){"use strict";function ei(et,ei){var eu=this,eH=this._readableState&&this._readableState.destroyed,ez=this._writableState&&this._writableState.destroyed;return eH||ez?(ei?ei(et):et&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,ed.nextTick(em,this,et)):ed.nextTick(em,this,et)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(et||null,function(et){!ei&&et?eu._writableState?eu._writableState.errorEmitted?ed.nextTick(ef,eu):(eu._writableState.errorEmitted=!0,ed.nextTick(es,eu,et)):ed.nextTick(es,eu,et):ei?(ed.nextTick(ef,eu),ei(et)):ed.nextTick(ef,eu)}),this)}function es(et,ei){em(et,ei),ef(et)}function ef(et){(!et._writableState||et._writableState.emitClose)&&(!et._readableState||et._readableState.emitClose)&&et.emit("close")}function eu(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function em(et,ei){et.emit("error",ei)}function eH(et,ei){var es=et._readableState,ef=et._writableState;es&&es.autoDestroy||ef&&ef.autoDestroy?et.destroy(ei):et.emit("error",ei)}et.exports={destroy:ei,undestroy:eu,errorOrDestroy:eH}},9698:function(et,ei,es){"use strict";var ef=es(4646).q.ERR_STREAM_PREMATURE_CLOSE;function eu(et){var ei=!1;return function(){if(!ei){ei=!0;for(var es=arguments.length,ef=Array(es),eu=0;eu0,function(ei){et||(et=ei),ei&&ed.forEach(eg),em||(ed.forEach(eg),eu(et))})});return es.reduce(eL)}et.exports=ey},6776:function(et,ei,es){"use strict";var ef=es(4646).q.ERR_INVALID_OPT_VALUE;function eu(et,ei,es){return null!=et.highWaterMark?et.highWaterMark:ei?et[es]:null}function ed(et,ei,es,ed){var em=eu(ei,ed,es);if(null!=em){if(!(isFinite(em)&&Math.floor(em)===em)||em<0){var eH=ed?es:"highWaterMark";throw new ef(eH,em)}return Math.floor(em)}return et.objectMode?16:16384}et.exports={getHighWaterMark:ed}},4678:function(et,ei,es){et.exports=es(2781)},3726:function(et,ei,es){var ef=es(2781);"disable"===ed.env.READABLE_STREAM&&ef?(et.exports=ef.Readable,Object.assign(et.exports,ef),et.exports.Stream=ef):((ei=et.exports=es(1709)).Stream=ef||ei,ei.Readable=ei,ei.Writable=es(7337),ei.Duplex=es(2403),ei.Transform=es(1170),ei.PassThrough=es(7889),ei.finished=es(9698),ei.pipeline=es(8442))},3225:function(et,ei,es){"use strict";var ef=es(4300).Buffer,eu=es(3782),ed=es(9029),em=Array(16),eH=[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],ez=[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],eV=[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],eM=[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],eg=[0,1518500249,1859775393,2400959708,2840853838],eL=[1352829926,1548603684,1836072691,2053994217,0];function eb(){ed.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function ey(et,ei){return et<>>32-ei}function eC(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei^es^ef)+ed+em|0,eH)+eu|0}function ex(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei&es|~ei&ef)+ed+em|0,eH)+eu|0}function ew(et,ei,es,ef,eu,ed,em,eH){return ey(et+((ei|~es)^ef)+ed+em|0,eH)+eu|0}function eN(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei&ef|es&~ef)+ed+em|0,eH)+eu|0}function eS(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei^(es|~ef))+ed+em|0,eH)+eu|0}eu(eb,ed),eb.prototype._update=function(){for(var et,ei,es=em,ef=0;ef<16;++ef)es[ef]=this._block.readInt32LE(4*ef);for(var eu=0|this._a,ed=0|this._b,eb=0|this._c,eA=0|this._d,e_=0|this._e,eE=0|this._a,eP=0|this._b,eB=0|this._c,eT=0|this._d,eI=0|this._e,eR=0;eR<80;eR+=1)eR<16?(et=eC(eu,ed,eb,eA,e_,es[eH[eR]],eg[0],eV[eR]),ei=eS(eE,eP,eB,eT,eI,es[ez[eR]],eL[0],eM[eR])):eR<32?(et=ex(eu,ed,eb,eA,e_,es[eH[eR]],eg[1],eV[eR]),ei=eN(eE,eP,eB,eT,eI,es[ez[eR]],eL[1],eM[eR])):eR<48?(et=ew(eu,ed,eb,eA,e_,es[eH[eR]],eg[2],eV[eR]),ei=ew(eE,eP,eB,eT,eI,es[ez[eR]],eL[2],eM[eR])):eR<64?(et=eN(eu,ed,eb,eA,e_,es[eH[eR]],eg[3],eV[eR]),ei=ex(eE,eP,eB,eT,eI,es[ez[eR]],eL[3],eM[eR])):(et=eS(eu,ed,eb,eA,e_,es[eH[eR]],eg[4],eV[eR]),ei=eC(eE,eP,eB,eT,eI,es[ez[eR]],eL[4],eM[eR])),eu=e_,e_=eA,eA=ey(eb,10),eb=ed,ed=et,eE=eI,eI=eT,eT=ey(eB,10),eB=eP,eP=ei;var eO=this._b+eb+eT|0;this._b=this._c+eA+eI|0,this._c=this._d+e_+eE|0,this._d=this._e+eu+eP|0,this._e=this._a+ed+eB|0,this._a=eO},eb.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ef.alloc?ef.alloc(20):new ef(20);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et.writeInt32LE(this._e,16),et},et.exports=eb},5055:function(et,ei,es){var ef=es(4300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},6911:function(et,ei,es){/*! safe-buffer. MIT License. Feross Aboukhadijeh */var ef=es(4300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},2858:function(et,ei,es){var ef=es(6911).Buffer;function eu(et,ei){this._block=ef.alloc(et),this._finalSize=ei,this._blockSize=et,this._len=0}eu.prototype.update=function(et,ei){"string"==typeof et&&(ei=ei||"utf8",et=ef.from(et,ei));for(var es=this._block,eu=this._blockSize,ed=et.length,em=this._len,eH=0;eH=this._finalSize&&(this._update(this._block),this._block.fill(0));var es=8*this._len;if(es<=4294967295)this._block.writeUInt32BE(es,this._blockSize-4);else{var ef=(4294967295&es)>>>0,eu=(es-ef)/4294967296;this._block.writeUInt32BE(eu,this._blockSize-8),this._block.writeUInt32BE(ef,this._blockSize-4)}this._update(this._block);var ed=this._hash();return et?ed.toString(et):ed},eu.prototype._update=function(){throw Error("_update must be implemented by subclass")},et.exports=eu},4371:function(et,ei,es){var ef=et.exports=function(et){var ei=ef[et=et.toLowerCase()];if(!ei)throw Error(et+" is not supported (we accept pull requests)");return new ei};ef.sha=es(4018),ef.sha1=es(4179),ef.sha224=es(532),ef.sha256=es(1843),ef.sha384=es(7455),ef.sha512=es(9934)},4018:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[1518500249,1859775393,-1894007588,-899497514],eH=Array(80);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et){return et<<5|et>>>27}function eM(et){return et<<30|et>>>2}function eg(et,ei,es,ef){return 0===et?ei&es|~ei&ef:2===et?ei&es|ei&ef|es&ef:ei^es^ef}ef(ez,eu),ez.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0;ez<16;++ez)ei[ez]=et.readInt32BE(4*ez);for(;ez<80;++ez)ei[ez]=ei[ez-3]^ei[ez-8]^ei[ez-14]^ei[ez-16];for(var eL=0;eL<80;++eL){var eb=~~(eL/20),ey=eV(es)+eg(eb,ef,eu,ed)+eH+ei[eL]+em[eb]|0;eH=ed,ed=eu,eu=eM(ef),ef=es,es=ey}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(20);return et.writeInt32BE(0|this._a,0),et.writeInt32BE(0|this._b,4),et.writeInt32BE(0|this._c,8),et.writeInt32BE(0|this._d,12),et.writeInt32BE(0|this._e,16),et},et.exports=ez},4179:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[1518500249,1859775393,-1894007588,-899497514],eH=Array(80);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et){return et<<1|et>>>31}function eM(et){return et<<5|et>>>27}function eg(et){return et<<30|et>>>2}function eL(et,ei,es,ef){return 0===et?ei&es|~ei&ef:2===et?ei&es|ei&ef|es&ef:ei^es^ef}ef(ez,eu),ez.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0;ez<16;++ez)ei[ez]=et.readInt32BE(4*ez);for(;ez<80;++ez)ei[ez]=eV(ei[ez-3]^ei[ez-8]^ei[ez-14]^ei[ez-16]);for(var eb=0;eb<80;++eb){var ey=~~(eb/20),eC=eM(es)+eL(ey,ef,eu,ed)+eH+ei[eb]+em[ey]|0;eH=ed,ed=eu,eu=eg(ef),ef=es,es=eC}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(20);return et.writeInt32BE(0|this._a,0),et.writeInt32BE(0|this._b,4),et.writeInt32BE(0|this._c,8),et.writeInt32BE(0|this._d,12),et.writeInt32BE(0|this._e,16),et},et.exports=ez},532:function(et,ei,es){var ef=es(3782),eu=es(1843),ed=es(2858),em=es(6911).Buffer,eH=Array(64);function ez(){this.init(),this._w=eH,ed.call(this,64,56)}ef(ez,eu),ez.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},ez.prototype._hash=function(){var et=em.allocUnsafe(28);return et.writeInt32BE(this._a,0),et.writeInt32BE(this._b,4),et.writeInt32BE(this._c,8),et.writeInt32BE(this._d,12),et.writeInt32BE(this._e,16),et.writeInt32BE(this._f,20),et.writeInt32BE(this._g,24),et},et.exports=ez},1843:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[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],eH=Array(64);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et,ei,es){return es^et&(ei^es)}function eM(et,ei,es){return et&ei|es&(et|ei)}function eg(et){return(et>>>2|et<<30)^(et>>>13|et<<19)^(et>>>22|et<<10)}function eL(et){return(et>>>6|et<<26)^(et>>>11|et<<21)^(et>>>25|et<<7)}function eb(et){return(et>>>7|et<<25)^(et>>>18|et<<14)^et>>>3}function ey(et){return(et>>>17|et<<15)^(et>>>19|et<<13)^et>>>10}ef(ez,eu),ez.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0|this._f,eC=0|this._g,ex=0|this._h,ew=0;ew<16;++ew)ei[ew]=et.readInt32BE(4*ew);for(;ew<64;++ew)ei[ew]=ey(ei[ew-2])+ei[ew-7]+eb(ei[ew-15])+ei[ew-16]|0;for(var eN=0;eN<64;++eN){var eS=ex+eL(eH)+eV(eH,ez,eC)+em[eN]+ei[eN]|0,eA=eg(es)+eM(es,ef,eu)|0;ex=eC,eC=ez,ez=eH,eH=ed+eS|0,ed=eu,eu=ef,ef=es,es=eS+eA|0}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0,this._f=ez+this._f|0,this._g=eC+this._g|0,this._h=ex+this._h|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(32);return et.writeInt32BE(this._a,0),et.writeInt32BE(this._b,4),et.writeInt32BE(this._c,8),et.writeInt32BE(this._d,12),et.writeInt32BE(this._e,16),et.writeInt32BE(this._f,20),et.writeInt32BE(this._g,24),et.writeInt32BE(this._h,28),et},et.exports=ez},7455:function(et,ei,es){var ef=es(3782),eu=es(9934),ed=es(2858),em=es(6911).Buffer,eH=Array(160);function ez(){this.init(),this._w=eH,ed.call(this,128,112)}ef(ez,eu),ez.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},ez.prototype._hash=function(){var et=em.allocUnsafe(48);function ei(ei,es,ef){et.writeInt32BE(ei,ef),et.writeInt32BE(es,ef+4)}return ei(this._ah,this._al,0),ei(this._bh,this._bl,8),ei(this._ch,this._cl,16),ei(this._dh,this._dl,24),ei(this._eh,this._el,32),ei(this._fh,this._fl,40),et},et.exports=ez},9934:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[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],eH=Array(160);function ez(){this.init(),this._w=eH,eu.call(this,128,112)}function eV(et,ei,es){return es^et&(ei^es)}function eM(et,ei,es){return et&ei|es&(et|ei)}function eg(et,ei){return(et>>>28|ei<<4)^(ei>>>2|et<<30)^(ei>>>7|et<<25)}function eL(et,ei){return(et>>>14|ei<<18)^(et>>>18|ei<<14)^(ei>>>9|et<<23)}function eb(et,ei){return(et>>>1|ei<<31)^(et>>>8|ei<<24)^et>>>7}function ey(et,ei){return(et>>>1|ei<<31)^(et>>>8|ei<<24)^(et>>>7|ei<<25)}function eC(et,ei){return(et>>>19|ei<<13)^(ei>>>29|et<<3)^et>>>6}function ex(et,ei){return(et>>>19|ei<<13)^(ei>>>29|et<<3)^(et>>>6|ei<<26)}function ew(et,ei){return et>>>0>>0?1:0}ef(ez,eu),ez.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._ah,ef=0|this._bh,eu=0|this._ch,ed=0|this._dh,eH=0|this._eh,ez=0|this._fh,eN=0|this._gh,eS=0|this._hh,eA=0|this._al,e_=0|this._bl,eE=0|this._cl,eP=0|this._dl,eB=0|this._el,eT=0|this._fl,eI=0|this._gl,eR=0|this._hl,eO=0;eO<32;eO+=2)ei[eO]=et.readInt32BE(4*eO),ei[eO+1]=et.readInt32BE(4*eO+4);for(;eO<160;eO+=2){var ej=ei[eO-30],eD=ei[eO-30+1],eF=eb(ej,eD),eU=ey(eD,ej);ej=ei[eO-4],eD=ei[eO-4+1];var eq=eC(ej,eD),eZ=ex(eD,ej),eG=ei[eO-14],eW=ei[eO-14+1],eK=ei[eO-32],e$=ei[eO-32+1],eJ=eU+eW|0,eY=eF+eG+ew(eJ,eU)|0;eY=(eY=eY+eq+ew(eJ=eJ+eZ|0,eZ)|0)+eK+ew(eJ=eJ+e$|0,e$)|0,ei[eO]=eY,ei[eO+1]=eJ}for(var eX=0;eX<160;eX+=2){eY=ei[eX],eJ=ei[eX+1];var eQ=eM(es,ef,eu),e1=eM(eA,e_,eE),e2=eg(es,eA),e4=eg(eA,es),e3=eL(eH,eB),e6=eL(eB,eH),e0=em[eX],e8=em[eX+1],e5=eV(eH,ez,eN),e7=eV(eB,eT,eI),e9=eR+e6|0,cc=eS+e3+ew(e9,eR)|0;cc=(cc=(cc=cc+e5+ew(e9=e9+e7|0,e7)|0)+e0+ew(e9=e9+e8|0,e8)|0)+eY+ew(e9=e9+eJ|0,eJ)|0;var ci=e4+e1|0,cs=e2+eQ+ew(ci,e4)|0;eS=eN,eR=eI,eN=ez,eI=eT,ez=eH,eT=eB,eH=ed+cc+ew(eB=eP+e9|0,eP)|0,ed=eu,eP=eE,eu=ef,eE=e_,ef=es,e_=eA,es=cc+cs+ew(eA=e9+ci|0,e9)|0}this._al=this._al+eA|0,this._bl=this._bl+e_|0,this._cl=this._cl+eE|0,this._dl=this._dl+eP|0,this._el=this._el+eB|0,this._fl=this._fl+eT|0,this._gl=this._gl+eI|0,this._hl=this._hl+eR|0,this._ah=this._ah+es+ew(this._al,eA)|0,this._bh=this._bh+ef+ew(this._bl,e_)|0,this._ch=this._ch+eu+ew(this._cl,eE)|0,this._dh=this._dh+ed+ew(this._dl,eP)|0,this._eh=this._eh+eH+ew(this._el,eB)|0,this._fh=this._fh+ez+ew(this._fl,eT)|0,this._gh=this._gh+eN+ew(this._gl,eI)|0,this._hh=this._hh+eS+ew(this._hl,eR)|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(64);function ei(ei,es,ef){et.writeInt32BE(ei,ef),et.writeInt32BE(es,ef+4)}return ei(this._ah,this._al,0),ei(this._bh,this._bl,8),ei(this._ch,this._cl,16),ei(this._dh,this._dl,24),ei(this._eh,this._el,32),ei(this._fh,this._fl,40),ei(this._gh,this._gl,48),ei(this._hh,this._hl,56),et},et.exports=ez},3704:function(et,ei,es){"use strict";var ef=es(5055).Buffer,eu=ef.isEncoding||function(et){switch((et=""+et)&&et.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 ed(et){var ei;if(!et)return"utf8";for(;;)switch(et){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 et;default:if(ei)return;et=(""+et).toLowerCase(),ei=!0}}function em(et){var ei=ed(et);if("string"!=typeof ei&&(ef.isEncoding===eu||!eu(et)))throw Error("Unknown encoding: "+et);return ei||et}function eH(et){var ei;switch(this.encoding=em(et),this.encoding){case"utf16le":this.text=ey,this.end=eC,ei=4;break;case"utf8":this.fillLast=eg,ei=4;break;case"base64":this.text=ex,this.end=ew,ei=3;break;default:this.write=eN,this.end=eS;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ef.allocUnsafe(ei)}function ez(et){return et<=127?0:et>>5==6?2:et>>4==14?3:et>>3==30?4:et>>6==2?-1:-2}function eV(et,ei,es){var ef=ei.length-1;if(ef=0?(eu>0&&(et.lastNeed=eu-1),eu):--ef=0?(eu>0&&(et.lastNeed=eu-2),eu):--ef=0?(eu>0&&(2===eu?eu=0:et.lastNeed=eu-3),eu):0}function eM(et,ei,es){if((192&ei[0])!=128)return et.lastNeed=0,"�";if(et.lastNeed>1&&ei.length>1){if((192&ei[1])!=128)return et.lastNeed=1,"�";if(et.lastNeed>2&&ei.length>2&&(192&ei[2])!=128)return et.lastNeed=2,"�"}}function eg(et){var ei=this.lastTotal-this.lastNeed,es=eM(this,et,ei);return void 0!==es?es:this.lastNeed<=et.length?(et.copy(this.lastChar,ei,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(et.copy(this.lastChar,ei,0,et.length),this.lastNeed-=et.length)}function eL(et,ei){var es=eV(this,et,ei);if(!this.lastNeed)return et.toString("utf8",ei);this.lastTotal=es;var ef=et.length-(es-this.lastNeed);return et.copy(this.lastChar,0,ef),et.toString("utf8",ei,ef)}function eb(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+"�":ei}function ey(et,ei){if((et.length-ei)%2==0){var es=et.toString("utf16le",ei);if(es){var ef=es.charCodeAt(es.length-1);if(ef>=55296&&ef<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1],es.slice(0,-1)}return es}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=et[et.length-1],et.toString("utf16le",ei,et.length-1)}function eC(et){var ei=et&&et.length?this.write(et):"";if(this.lastNeed){var es=this.lastTotal-this.lastNeed;return ei+this.lastChar.toString("utf16le",0,es)}return ei}function ex(et,ei){var es=(et.length-ei)%3;return 0===es?et.toString("base64",ei):(this.lastNeed=3-es,this.lastTotal=3,1===es?this.lastChar[0]=et[et.length-1]:(this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1]),et.toString("base64",ei,et.length-es))}function ew(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+this.lastChar.toString("base64",0,3-this.lastNeed):ei}function eN(et){return et.toString(this.encoding)}function eS(et){return et&&et.length?this.write(et):""}ei.s=eH,eH.prototype.write=function(et){var ei,es;if(0===et.length)return"";if(this.lastNeed){if(void 0===(ei=this.fillLast(et)))return"";es=this.lastNeed,this.lastNeed=0}else es=0;return es1)for(var es=1;esString(et)),es>2)?`one of ${ei} ${et.slice(0,es-1).join(", ")}, or `+et[es-1]:2===es?`one of ${ei} ${et[0]} or ${et[1]}`:`of ${ei} ${et[0]}`}}function eu(et,ei,es){return et.substr(!es||es<0?0:+es,ei.length)===ei}function ed(et,ei,es){return(void 0===es||es>et.length)&&(es=et.length),et.substring(es-ei.length,es)===ei}function em(et,ei,es){return"number"!=typeof es&&(es=0),!(es+ei.length>et.length)&&-1!==et.indexOf(ei,es)}es("ERR_INVALID_OPT_VALUE",function(et,ei){return'The value "'+ei+'" is invalid for option "'+et+'"'},TypeError),es("ERR_INVALID_ARG_TYPE",function(et,ei,es){let eH,ez;if("string"==typeof ei&&eu(ei,"not ")?(eH="must not be",ei=ei.replace(/^not /,"")):eH="must be",ed(et," argument"))ez=`The ${et} ${eH} ${ef(ei,"type")}`;else{let es=em(et,".")?"property":"argument";ez=`The "${et}" ${es} ${eH} ${ef(ei,"type")}`}return ez+`. Received type ${typeof es}`},TypeError),es("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),es("ERR_METHOD_NOT_IMPLEMENTED",function(et){return"The "+et+" method is not implemented"}),es("ERR_STREAM_PREMATURE_CLOSE","Premature close"),es("ERR_STREAM_DESTROYED",function(et){return"Cannot call "+et+" after a stream was destroyed"}),es("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),es("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),es("ERR_STREAM_WRITE_AFTER_END","write after end"),es("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),es("ERR_UNKNOWN_ENCODING",function(et){return"Unknown encoding: "+et},TypeError),es("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),et.exports.q=ei},403:function(et,ei,es){"use strict";var ef=Object.keys||function(et){var ei=[];for(var es in et)ei.push(es);return ei};et.exports=eM;var ed=es(709),em=es(337);es(782)(eM,ed);for(var eH=ef(em.prototype),ez=0;ez0){if("string"==typeof ei||eH.objectMode||Object.getPrototypeOf(ei)===eL.prototype||(ei=ey(ei)),ef)eH.endEmitted?eT(et,new eB):eF(et,eH,ei,!0);else if(eH.ended)eT(et,new eE);else{if(eH.destroyed)return!1;eH.reading=!1,eH.decoder&&!es?(ei=eH.decoder.write(ei),eH.objectMode||0!==ei.length?eF(et,eH,ei,!1):eJ(et,eH)):eF(et,eH,ei,!1)}}else ef||(eH.reading=!1,eJ(et,eH));return!eH.ended&&(eH.length=eq?et=eq:(et--,et|=et>>>1,et|=et>>>2,et|=et>>>4,et|=et>>>8,et|=et>>>16,et++),et}function eG(et,ei){return et<=0||0===ei.length&&ei.ended?0:ei.objectMode?1:et!=et?ei.flowing&&ei.length?ei.buffer.head.data.length:ei.length:(et>ei.highWaterMark&&(ei.highWaterMark=eZ(et)),et<=ei.length)?et:ei.ended?ei.length:(ei.needReadable=!0,0)}function eW(et,ei){if(em("onEofChunk"),!ei.ended){if(ei.decoder){var es=ei.decoder.end();es&&es.length&&(ei.buffer.push(es),ei.length+=ei.objectMode?1:es.length)}ei.ended=!0,ei.sync?eK(et):(ei.needReadable=!1,ei.emittedReadable||(ei.emittedReadable=!0,e$(et)))}}function eK(et){var ei=et._readableState;em("emitReadable",ei.needReadable,ei.emittedReadable),ei.needReadable=!1,ei.emittedReadable||(em("emitReadable",ei.flowing),ei.emittedReadable=!0,eu.nextTick(e$,et))}function e$(et){var ei=et._readableState;em("emitReadable_",ei.destroyed,ei.length,ei.ended),!ei.destroyed&&(ei.length||ei.ended)&&(et.emit("readable"),ei.emittedReadable=!1),ei.needReadable=!ei.flowing&&!ei.ended&&ei.length<=ei.highWaterMark,e3(et)}function eJ(et,ei){ei.readingMore||(ei.readingMore=!0,eu.nextTick(eY,et,ei))}function eY(et,ei){for(;!ei.reading&&!ei.ended&&(ei.length0,ei.resumeScheduled&&!ei.paused?ei.flowing=!0:et.listenerCount("data")>0&&et.resume()}function e1(et){em("readable nexttick read 0"),et.read(0)}function e2(et,ei){ei.resumeScheduled||(ei.resumeScheduled=!0,eu.nextTick(e4,et,ei))}function e4(et,ei){em("resume",ei.reading),ei.reading||et.read(0),ei.resumeScheduled=!1,et.emit("resume"),e3(et),ei.flowing&&!ei.reading&&et.read(0)}function e3(et){var ei=et._readableState;for(em("flow",ei.flowing);ei.flowing&&null!==et.read(););}function e6(et,ei){var es;return 0===ei.length?null:(ei.objectMode?es=ei.buffer.shift():!et||et>=ei.length?(es=ei.decoder?ei.buffer.join(""):1===ei.buffer.length?ei.buffer.first():ei.buffer.concat(ei.length),ei.buffer.clear()):es=ei.buffer.consume(et,ei.decoder),es)}function e0(et){var ei=et._readableState;em("endReadable",ei.endEmitted),ei.endEmitted||(ei.ended=!0,eu.nextTick(e8,ei,et))}function e8(et,ei){if(em("endReadableNT",et.endEmitted,et.length),!et.endEmitted&&0===et.length&&(et.endEmitted=!0,ei.readable=!1,ei.emit("end"),et.autoDestroy)){var es=ei._writableState;(!es||es.autoDestroy&&es.finished)&&ei.destroy()}}function e5(et,ei){for(var es=0,ef=et.length;es=es.highWaterMark:es.length>0)||es.ended))return em("read: emitReadable",es.length,es.ended),0===es.length&&es.ended?e0(this):eK(this),null;if(0===(et=eG(et,es))&&es.ended)return 0===es.length&&e0(this),null;var eu=es.needReadable;return em("need readable",eu),(0===es.length||es.length-et0?e6(et,es):null)?(es.needReadable=es.length<=es.highWaterMark,et=0):(es.length-=et,es.awaitDrain=0),0===es.length&&(es.ended||(es.needReadable=!0),ef!==et&&es.ended&&e0(this)),null!==ei&&this.emit("data",ei),ei},ej.prototype._read=function(et){eT(this,new eP("_read()"))},ej.prototype.pipe=function(et,ei){var es=this,ef=this._readableState;switch(ef.pipesCount){case 0:ef.pipes=et;break;case 1:ef.pipes=[ef.pipes,et];break;default:ef.pipes.push(et)}ef.pipesCount+=1,em("pipe count=%d opts=%j",ef.pipesCount,ei);var ed=ei&&!1===ei.end||et===eu.stdout||et===eu.stderr?ew:ez;function eH(et,ei){em("onunpipe"),et===es&&ei&&!1===ei.hasUnpiped&&(ei.hasUnpiped=!0,eL())}function ez(){em("onend"),et.end()}ef.endEmitted?eu.nextTick(ed):es.once("end",ed),et.on("unpipe",eH);var eV=eX(es);et.on("drain",eV);var eg=!1;function eL(){em("cleanup"),et.removeListener("close",eC),et.removeListener("finish",ex),et.removeListener("drain",eV),et.removeListener("error",ey),et.removeListener("unpipe",eH),es.removeListener("end",ez),es.removeListener("end",ew),es.removeListener("data",eb),eg=!0,ef.awaitDrain&&(!et._writableState||et._writableState.needDrain)&&eV()}function eb(ei){em("ondata");var eu=et.write(ei);em("dest.write",eu),!1===eu&&((1===ef.pipesCount&&ef.pipes===et||ef.pipesCount>1&&-1!==e5(ef.pipes,et))&&!eg&&(em("false write response, pause",ef.awaitDrain),ef.awaitDrain++),es.pause())}function ey(ei){em("onerror",ei),ew(),et.removeListener("error",ey),0===eM(et,"error")&&eT(et,ei)}function eC(){et.removeListener("finish",ex),ew()}function ex(){em("onfinish"),et.removeListener("close",eC),ew()}function ew(){em("unpipe"),es.unpipe(et)}return es.on("data",eb),eR(et,"error",ey),et.once("close",eC),et.once("finish",ex),et.emit("pipe",es),ef.flowing||(em("pipe resume"),es.resume()),et},ej.prototype.unpipe=function(et){var ei=this._readableState,es={hasUnpiped:!1};if(0===ei.pipesCount)return this;if(1===ei.pipesCount)return et&&et!==ei.pipes||(et||(et=ei.pipes),ei.pipes=null,ei.pipesCount=0,ei.flowing=!1,et&&et.emit("unpipe",this,es)),this;if(!et){var ef=ei.pipes,eu=ei.pipesCount;ei.pipes=null,ei.pipesCount=0,ei.flowing=!1;for(var ed=0;ed0,!1!==ef.flowing&&this.resume()):"readable"!==et||ef.endEmitted||ef.readableListening||(ef.readableListening=ef.needReadable=!0,ef.flowing=!1,ef.emittedReadable=!1,em("on readable",ef.length,ef.reading),ef.length?eK(this):ef.reading||eu.nextTick(e1,this)),es},ej.prototype.addListener=ej.prototype.on,ej.prototype.removeListener=function(et,ei){var es=eg.prototype.removeListener.call(this,et,ei);return"readable"===et&&eu.nextTick(eQ,this),es},ej.prototype.removeAllListeners=function(et){var ei=eg.prototype.removeAllListeners.apply(this,arguments);return("readable"===et||void 0===et)&&eu.nextTick(eQ,this),ei},ej.prototype.resume=function(){var et=this._readableState;return et.flowing||(em("resume"),et.flowing=!et.readableListening,e2(this,et)),et.paused=!1,this},ej.prototype.pause=function(){return em("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(em("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},ej.prototype.wrap=function(et){var ei=this,es=this._readableState,ef=!1;for(var eu in et.on("end",function(){if(em("wrapped end"),es.decoder&&!es.ended){var et=es.decoder.end();et&&et.length&&ei.push(et)}ei.push(null)}),et.on("data",function(eu){em("wrapped data"),es.decoder&&(eu=es.decoder.write(eu)),(!es.objectMode||null!=eu)&&(es.objectMode||eu&&eu.length)&&(ei.push(eu)||(ef=!0,et.pause()))}),et)void 0===this[eu]&&"function"==typeof et[eu]&&(this[eu]=function(ei){return function(){return et[ei].apply(et,arguments)}}(eu));for(var ed=0;ed-1))throw new eB(et);return this._writableState.defaultEncoding=et,this},Object.defineProperty(eO.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(eO.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),eO.prototype._write=function(et,ei,es){es(new eN("_write()"))},eO.prototype._writev=null,eO.prototype.end=function(et,ei,es){var ef=this._writableState;return"function"==typeof et?(es=et,et=null,ei=null):"function"==typeof ei&&(es=ei,ei=null),null!=et&&this.write(et,ei),ef.corked&&(ef.corked=1,this.uncork()),ef.ending||e2(this,ef,es),this},Object.defineProperty(eO.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(eO.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(et){this._writableState&&(this._writableState.destroyed=et)}}),eO.prototype.destroy=ey.destroy,eO.prototype._undestroy=ey.undestroy,eO.prototype._destroy=function(et,ei){ei(et)}},871:function(et,ei,es){"use strict";function ef(et,ei,es){return ei in et?Object.defineProperty(et,ei,{value:es,enumerable:!0,configurable:!0,writable:!0}):et[ei]=es,et}var ed,em=es(698),eH=Symbol("lastResolve"),ez=Symbol("lastReject"),eV=Symbol("error"),eM=Symbol("ended"),eg=Symbol("lastPromise"),eL=Symbol("handlePromise"),eb=Symbol("stream");function ey(et,ei){return{value:et,done:ei}}function eC(et){var ei=et[eH];if(null!==ei){var es=et[eb].read();null!==es&&(et[eg]=null,et[eH]=null,et[ez]=null,ei(ey(es,!1)))}}function ex(et){eu.nextTick(eC,et)}function ew(et,ei){return function(es,ef){et.then(function(){if(ei[eM]){es(ey(void 0,!0));return}ei[eL](es,ef)},ef)}}var eN=Object.getPrototypeOf(function(){}),eS=Object.setPrototypeOf((ef(ed={get stream(){return this[eb]},next:function(){var et,ei=this,es=this[eV];if(null!==es)return Promise.reject(es);if(this[eM])return Promise.resolve(ey(void 0,!0));if(this[eb].destroyed)return new Promise(function(et,es){eu.nextTick(function(){ei[eV]?es(ei[eV]):et(ey(void 0,!0))})});var ef=this[eg];if(ef)et=new Promise(ew(ef,this));else{var ed=this[eb].read();if(null!==ed)return Promise.resolve(ey(ed,!1));et=new Promise(this[eL])}return this[eg]=et,et}},Symbol.asyncIterator,function(){return this}),ef(ed,"return",function(){var et=this;return new Promise(function(ei,es){et[eb].destroy(null,function(et){if(et){es(et);return}ei(ey(void 0,!0))})})}),ed),eN),eA=function(et){var ei,es=Object.create(eS,(ef(ei={},eb,{value:et,writable:!0}),ef(ei,eH,{value:null,writable:!0}),ef(ei,ez,{value:null,writable:!0}),ef(ei,eV,{value:null,writable:!0}),ef(ei,eM,{value:et._readableState.endEmitted,writable:!0}),ef(ei,eL,{value:function(et,ei){var ef=es[eb].read();ef?(es[eg]=null,es[eH]=null,es[ez]=null,et(ey(ef,!1))):(es[eH]=et,es[ez]=ei)},writable:!0}),ei));return es[eg]=null,em(et,function(et){if(et&&"ERR_STREAM_PREMATURE_CLOSE"!==et.code){var ei=es[ez];null!==ei&&(es[eg]=null,es[eH]=null,es[ez]=null,ei(et)),es[eV]=et;return}var ef=es[eH];null!==ef&&(es[eg]=null,es[eH]=null,es[ez]=null,ef(ey(void 0,!0))),es[eM]=!0}),et.on("readable",ex.bind(null,es)),es};et.exports=eA},379:function(et,ei,es){"use strict";function ef(et,ei){var es=Object.keys(et);if(Object.getOwnPropertySymbols){var ef=Object.getOwnPropertySymbols(et);ei&&(ef=ef.filter(function(ei){return Object.getOwnPropertyDescriptor(et,ei).enumerable})),es.push.apply(es,ef)}return es}function eu(et){for(var ei=1;ei0?this.tail.next=ei:this.head=ei,this.tail=ei,++this.length}},{key:"unshift",value:function(et){var ei={data:et,next:this.head};0===this.length&&(this.tail=ei),this.head=ei,++this.length}},{key:"shift",value:function(){if(0!==this.length){var et=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,et}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(et){if(0===this.length)return"";for(var ei=this.head,es=""+ei.data;ei=ei.next;)es+=et+ei.data;return es}},{key:"concat",value:function(et){if(0===this.length)return eV.alloc(0);for(var ei=eV.allocUnsafe(et>>>0),es=this.head,ef=0;es;)eL(es.data,ei,ef),ef+=es.data.length,es=es.next;return ei}},{key:"consume",value:function(et,ei){var es;return eteu.length?eu.length:et;if(ed===eu.length?ef+=eu:ef+=eu.slice(0,et),0==(et-=ed)){ed===eu.length?(++es,ei.next?this.head=ei.next:this.head=this.tail=null):(this.head=ei,ei.data=eu.slice(ed));break}++es}return this.length-=es,ef}},{key:"_getBuffer",value:function(et){var ei=eV.allocUnsafe(et),es=this.head,ef=1;for(es.data.copy(ei),et-=es.data.length;es=es.next;){var eu=es.data,ed=et>eu.length?eu.length:et;if(eu.copy(ei,ei.length-et,0,ed),0==(et-=ed)){ed===eu.length?(++ef,es.next?this.head=es.next:this.head=this.tail=null):(this.head=es,es.data=eu.slice(ed));break}++ef}return this.length-=ef,ei}},{key:eg,value:function(et,ei){return eM(this,eu({},ei,{depth:0,customInspect:!1}))}}]),et}()},25:function(et){"use strict";function ei(et,ei){var ed=this,eH=this._readableState&&this._readableState.destroyed,ez=this._writableState&&this._writableState.destroyed;return eH||ez?(ei?ei(et):et&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,eu.nextTick(em,this,et)):eu.nextTick(em,this,et)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(et||null,function(et){!ei&&et?ed._writableState?ed._writableState.errorEmitted?eu.nextTick(ef,ed):(ed._writableState.errorEmitted=!0,eu.nextTick(es,ed,et)):eu.nextTick(es,ed,et):ei?(eu.nextTick(ef,ed),ei(et)):eu.nextTick(ef,ed)}),this)}function es(et,ei){em(et,ei),ef(et)}function ef(et){(!et._writableState||et._writableState.emitClose)&&(!et._readableState||et._readableState.emitClose)&&et.emit("close")}function ed(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function em(et,ei){et.emit("error",ei)}function eH(et,ei){var es=et._readableState,ef=et._writableState;es&&es.autoDestroy||ef&&ef.autoDestroy?et.destroy(ei):et.emit("error",ei)}et.exports={destroy:ei,undestroy:ed,errorOrDestroy:eH}},698:function(et,ei,es){"use strict";var ef=es(646).q.ERR_STREAM_PREMATURE_CLOSE;function eu(et){var ei=!1;return function(){if(!ei){ei=!0;for(var es=arguments.length,ef=Array(es),eu=0;eu0,function(ei){et||(et=ei),ei&&ed.forEach(eg),em||(ed.forEach(eg),eu(et))})});return es.reduce(eL)}et.exports=ey},776:function(et,ei,es){"use strict";var ef=es(646).q.ERR_INVALID_OPT_VALUE;function eu(et,ei,es){return null!=et.highWaterMark?et.highWaterMark:ei?et[es]:null}function ed(et,ei,es,ed){var em=eu(ei,ed,es);if(null!=em){if(!(isFinite(em)&&Math.floor(em)===em)||em<0){var eH=ed?es:"highWaterMark";throw new ef(eH,em)}return Math.floor(em)}return et.objectMode?16:16384}et.exports={getHighWaterMark:ed}},678:function(et,ei,es){et.exports=es(781)},55:function(et,ei,es){var ef=es(300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},173:function(et,ei,es){et.exports=eu;var ef=es(361).EventEmitter;function eu(){ef.call(this)}es(782)(eu,ef),eu.Readable=es(709),eu.Writable=es(337),eu.Duplex=es(403),eu.Transform=es(170),eu.PassThrough=es(889),eu.finished=es(698),eu.pipeline=es(442),eu.Stream=eu,eu.prototype.pipe=function(et,ei){var es=this;function eu(ei){et.writable&&!1===et.write(ei)&&es.pause&&es.pause()}function ed(){es.readable&&es.resume&&es.resume()}es.on("data",eu),et.on("drain",ed),et._isStdio||ei&&!1===ei.end||(es.on("end",eH),es.on("close",ez));var em=!1;function eH(){em||(em=!0,et.end())}function ez(){em||(em=!0,"function"==typeof et.destroy&&et.destroy())}function eV(et){if(eM(),0===ef.listenerCount(this,"error"))throw et}function eM(){es.removeListener("data",eu),et.removeListener("drain",ed),es.removeListener("end",eH),es.removeListener("close",ez),es.removeListener("error",eV),et.removeListener("error",eV),es.removeListener("end",eM),es.removeListener("close",eM),et.removeListener("close",eM)}return es.on("error",eV),et.on("error",eV),es.on("end",eM),es.on("close",eM),et.on("close",eM),et.emit("pipe",es),et}},704:function(et,ei,es){"use strict";var ef=es(55).Buffer,eu=ef.isEncoding||function(et){switch((et=""+et)&&et.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 ed(et){var ei;if(!et)return"utf8";for(;;)switch(et){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 et;default:if(ei)return;et=(""+et).toLowerCase(),ei=!0}}function em(et){var ei=ed(et);if("string"!=typeof ei&&(ef.isEncoding===eu||!eu(et)))throw Error("Unknown encoding: "+et);return ei||et}function eH(et){var ei;switch(this.encoding=em(et),this.encoding){case"utf16le":this.text=ey,this.end=eC,ei=4;break;case"utf8":this.fillLast=eg,ei=4;break;case"base64":this.text=ex,this.end=ew,ei=3;break;default:this.write=eN,this.end=eS;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ef.allocUnsafe(ei)}function ez(et){return et<=127?0:et>>5==6?2:et>>4==14?3:et>>3==30?4:et>>6==2?-1:-2}function eV(et,ei,es){var ef=ei.length-1;if(ef=0?(eu>0&&(et.lastNeed=eu-1),eu):--ef=0?(eu>0&&(et.lastNeed=eu-2),eu):--ef=0?(eu>0&&(2===eu?eu=0:et.lastNeed=eu-3),eu):0}function eM(et,ei,es){if((192&ei[0])!=128)return et.lastNeed=0,"�";if(et.lastNeed>1&&ei.length>1){if((192&ei[1])!=128)return et.lastNeed=1,"�";if(et.lastNeed>2&&ei.length>2&&(192&ei[2])!=128)return et.lastNeed=2,"�"}}function eg(et){var ei=this.lastTotal-this.lastNeed,es=eM(this,et,ei);return void 0!==es?es:this.lastNeed<=et.length?(et.copy(this.lastChar,ei,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(et.copy(this.lastChar,ei,0,et.length),this.lastNeed-=et.length)}function eL(et,ei){var es=eV(this,et,ei);if(!this.lastNeed)return et.toString("utf8",ei);this.lastTotal=es;var ef=et.length-(es-this.lastNeed);return et.copy(this.lastChar,0,ef),et.toString("utf8",ei,ef)}function eb(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+"�":ei}function ey(et,ei){if((et.length-ei)%2==0){var es=et.toString("utf16le",ei);if(es){var ef=es.charCodeAt(es.length-1);if(ef>=55296&&ef<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1],es.slice(0,-1)}return es}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=et[et.length-1],et.toString("utf16le",ei,et.length-1)}function eC(et){var ei=et&&et.length?this.write(et):"";if(this.lastNeed){var es=this.lastTotal-this.lastNeed;return ei+this.lastChar.toString("utf16le",0,es)}return ei}function ex(et,ei){var es=(et.length-ei)%3;return 0===es?et.toString("base64",ei):(this.lastNeed=3-es,this.lastTotal=3,1===es?this.lastChar[0]=et[et.length-1]:(this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1]),et.toString("base64",ei,et.length-es))}function ew(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+this.lastChar.toString("base64",0,3-this.lastNeed):ei}function eN(et){return et.toString(this.encoding)}function eS(et){return et&&et.length?this.write(et):""}ei.s=eH,eH.prototype.write=function(et){var ei,es;if(0===et.length)return"";if(this.lastNeed){if(void 0===(ei=this.fillLast(et)))return"";es=this.lastNeed,this.lastNeed=0}else es=0;return es0&&!eu.call(et,0))for(var eb=0;eb0)for(var eC=0;eC=0&&"[object Function]"===ei.call(et.callee)),ef}},92703:function(et,ei,es){"use strict";var ef=es(50414);function eu(){}function ed(){}ed.resetWarningCache=eu,et.exports=function(){function et(et,ei,es,eu,ed,em){if(em!==ef){var eH=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw eH.name="Invariant Violation",eH}}function ei(){return et}et.isRequired=et;var es={array:et,bigint:et,bool:et,func:et,number:et,object:et,string:et,symbol:et,any:et,arrayOf:ei,element:et,elementType:et,instanceOf:ei,node:et,objectOf:ei,oneOf:ei,oneOfType:ei,shape:ei,exact:ei,checkPropTypes:ed,resetWarningCache:eu};return es.PropTypes=es,es}},45697:function(et,ei,es){et.exports=es(92703)()},50414:function(et){"use strict";var ei="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";et.exports=ei},61798:function(et,ei,es){"use strict";var ef=es(83454),eu=65536,ed=4294967295;function em(){throw Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}var eH=es(89509).Buffer,ez=es.g.crypto||es.g.msCrypto;function eV(et,ei){if(et>ed)throw RangeError("requested too many random bytes");var es=eH.allocUnsafe(et);if(et>0){if(et>eu)for(var em=0;em */ei.read=function(et,ei,es,ef,eu){var ed,em,eH=8*eu-ef-1,ez=(1<>1,eM=-7,eg=es?eu-1:0,eL=es?-1:1,eb=et[ei+eg];for(eg+=eL,ed=eb&(1<<-eM)-1,eb>>=-eM,eM+=eH;eM>0;ed=256*ed+et[ei+eg],eg+=eL,eM-=8);for(em=ed&(1<<-eM)-1,ed>>=-eM,eM+=ef;eM>0;em=256*em+et[ei+eg],eg+=eL,eM-=8);if(0===ed)ed=1-eV;else{if(ed===ez)return em?NaN:(eb?-1:1)*(1/0);em+=Math.pow(2,ef),ed-=eV}return(eb?-1:1)*em*Math.pow(2,ed-ef)},ei.write=function(et,ei,es,ef,eu,ed){var em,eH,ez,eV=8*ed-eu-1,eM=(1<>1,eL=23===eu?5960464477539062e-23:0,eb=ef?0:ed-1,ey=ef?1:-1,eC=ei<0||0===ei&&1/ei<0?1:0;for(isNaN(ei=Math.abs(ei))||ei===1/0?(eH=isNaN(ei)?1:0,em=eM):(em=Math.floor(Math.log(ei)/Math.LN2),ei*(ez=Math.pow(2,-em))<1&&(em--,ez*=2),em+eg>=1?ei+=eL/ez:ei+=eL*Math.pow(2,1-eg),ei*ez>=2&&(em++,ez/=2),em+eg>=eM?(eH=0,em=eM):em+eg>=1?(eH=(ei*ez-1)*Math.pow(2,eu),em+=eg):(eH=ei*Math.pow(2,eg-1)*Math.pow(2,eu),em=0));eu>=8;et[es+eb]=255&eH,eb+=ey,eH/=256,eu-=8);for(em=em<0;et[es+eb]=255&em,eb+=ey,em/=256,eV-=8);et[es+eb-ey]|=128*eC}},35717:function(et){"function"==typeof Object.create?et.exports=function(et,ei){ei&&(et.super_=ei,et.prototype=Object.create(ei.prototype,{constructor:{value:et,enumerable:!1,writable:!0,configurable:!0}}))}:et.exports=function(et,ei){if(ei){et.super_=ei;var es=function(){};es.prototype=ei.prototype,et.prototype=new es,et.prototype.constructor=et}}},82584:function(et,ei,es){"use strict";var ef=es(96410)(),eu=es(21924)("Object.prototype.toString"),ed=function(et){return(!ef||!et||"object"!=typeof et||!(Symbol.toStringTag in et))&&"[object Arguments]"===eu(et)},em=function(et){return!!ed(et)||null!==et&&"object"==typeof et&&"number"==typeof et.length&&et.length>=0&&"[object Array]"!==eu(et)&&"[object Function]"===eu(et.callee)},eH=function(){return ed(arguments)}();ed.isLegacyArguments=em,et.exports=eH?ed:em},95320:function(et){"use strict";var ei,es,ef=Function.prototype.toString,eu="object"==typeof Reflect&&null!==Reflect&&Reflect.apply;if("function"==typeof eu&&"function"==typeof Object.defineProperty)try{ei=Object.defineProperty({},"length",{get:function(){throw es}}),es={},eu(function(){throw 42},null,ei)}catch(et){et!==es&&(eu=null)}else eu=null;var ed=/^\s*class\b/,em=function(et){try{var ei=ef.call(et);return ed.test(ei)}catch(et){return!1}},eH=function(et){try{if(em(et))return!1;return ef.call(et),!0}catch(et){return!1}},ez=Object.prototype.toString,eV="[object Object]",eM="[object Function]",eg="[object GeneratorFunction]",eL="[object HTMLAllCollection]",eb="[object HTML document.all class]",ey="[object HTMLCollection]",eC="function"==typeof Symbol&&!!Symbol.toStringTag,ex=!(0 in[,]),ew=function(){return!1};if("object"==typeof document){var eN=document.all;ez.call(eN)===ez.call(document.all)&&(ew=function(et){if((ex||!et)&&(void 0===et||"object"==typeof et))try{var ei=ez.call(et);return(ei===eL||ei===eb||ei===ey||ei===eV)&&null==et("")}catch(et){}return!1})}et.exports=eu?function(et){if(ew(et))return!0;if(!et||"function"!=typeof et&&"object"!=typeof et)return!1;try{eu(et,null,ei)}catch(et){if(et!==es)return!1}return!em(et)&&eH(et)}:function(et){if(ew(et))return!0;if(!et||"function"!=typeof et&&"object"!=typeof et)return!1;if(eC)return eH(et);if(em(et))return!1;var ei=ez.call(et);return!!(ei===eM||ei===eg||/^\[object HTML/.test(ei))&&eH(et)}},48662:function(et,ei,es){"use strict";var ef,eu=Object.prototype.toString,ed=Function.prototype.toString,em=/^\s*(?:function)?\*/,eH=es(96410)(),ez=Object.getPrototypeOf,eV=function(){if(!eH)return!1;try{return Function("return function*() {}")()}catch(et){}};et.exports=function(et){if("function"!=typeof et)return!1;if(em.test(ed.call(et)))return!0;if(!eH)return"[object GeneratorFunction]"===eu.call(et);if(!ez)return!1;if(void 0===ef){var ei=eV();ef=!!ei&&ez(ei)}return ez(et)===ef}},23944:function(et){et.exports=function(et){if("string"!=typeof et)throw Error("[is-hex-prefixed] value must be type 'string', is currently type "+typeof et+", while checking isHexPrefixed.");return"0x"===et.slice(0,2)}},98611:function(et){"use strict";et.exports=function(et){return et!=et}},20360:function(et,ei,es){"use strict";var ef=es(55559),eu=es(4289),ed=es(98611),em=es(29415),eH=es(23194),ez=ef(em(),Number);eu(ez,{getPolyfill:em,implementation:ed,shim:eH}),et.exports=ez},29415:function(et,ei,es){"use strict";var ef=es(98611);et.exports=function(){return Number.isNaN&&Number.isNaN(NaN)&&!Number.isNaN("a")?Number.isNaN:ef}},23194:function(et,ei,es){"use strict";var ef=es(4289),eu=es(29415);et.exports=function(){var et=eu();return ef(Number,{isNaN:et},{isNaN:function(){return Number.isNaN!==et}}),et}},85692:function(et,ei,es){"use strict";var ef=es(94029),eu=es(63083),ed=es(21924),em=ed("Object.prototype.toString"),eH=es(96410)(),ez=es(27296),eV="undefined"==typeof globalThis?es.g:globalThis,eM=eu(),eg=ed("Array.prototype.indexOf",!0)||function(et,ei){for(var es=0;es-1)}},31198:function(et,ei,es){"use strict";let ef=es(64667).v4,eu=es(17741),ed=function(et,ei){if(!(this instanceof ed))return new ed(et,ei);ei||(ei={}),this.options={reviver:void 0!==ei.reviver?ei.reviver:null,replacer:void 0!==ei.replacer?ei.replacer:null,generator:void 0!==ei.generator?ei.generator:function(){return ef()},version:void 0!==ei.version?ei.version:2,notificationIdNull:"boolean"==typeof ei.notificationIdNull&&ei.notificationIdNull},this.callServer=et};et.exports=ed,ed.prototype.request=function(et,ei,es,ef){let ed;let em=this,eH=null,ez=Array.isArray(et)&&"function"==typeof ei;if(1===this.options.version&&ez)throw TypeError("JSON-RPC 1.0 does not support batching");let eV=!ez&&et&&"object"==typeof et&&"function"==typeof ei;if(ez||eV)ef=ei,eH=et;else{"function"==typeof es&&(ef=es,es=void 0);let ed="function"==typeof ef;try{eH=eu(et,ei,es,{generator:this.options.generator,version:this.options.version,notificationIdNull:this.options.notificationIdNull})}catch(et){if(ed)return ef(et);throw et}if(!ed)return eH}try{ed=JSON.stringify(eH,this.options.replacer)}catch(et){return ef(et)}return this.callServer(ed,function(et,ei){em._parseResponse(et,ei,ef)}),eH},ed.prototype._parseResponse=function(et,ei,es){let ef;if(et){es(et);return}if(!ei)return es();try{ef=JSON.parse(ei,this.options.reviver)}catch(et){return es(et)}if(3===es.length){if(!Array.isArray(ef))return es(null,ef.error,ef.result);{let et=function(et){return void 0!==et.error},ei=function(ei){return!et(ei)};return es(null,ef.filter(et),ef.filter(ei))}}es(null,ef)}},17741:function(et,ei,es){"use strict";let ef=es(64667).v4,eu=function(et,ei,es,eu){if("string"!=typeof et)throw TypeError(et+" must be a string");eu=eu||{};let ed="number"==typeof eu.version?eu.version:2;if(1!==ed&&2!==ed)throw TypeError(ed+" must be 1 or 2");let em={method:et};if(2===ed&&(em.jsonrpc="2.0"),ei){if("object"!=typeof ei&&!Array.isArray(ei))throw TypeError(ei+" must be an object, array or omitted");em.params=ei}if(void 0===es){let et="function"==typeof eu.generator?eu.generator:function(){return ef()};em.id=et(em,eu)}else 2===ed&&null===es?eu.notificationIdNull&&(em.id=null):em.id=es;return em};et.exports=eu},64667:function(et,ei,es){"use strict";es.d(ei,{v4:function(){return eg}});var ef,eu=new Uint8Array(16);function ed(){if(!ef&&!(ef="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return ef(eu)}for(var em=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,eH=function(et){return"string"==typeof et&&em.test(et)},ez=[],eV=0;eV<256;++eV)ez.push((eV+256).toString(16).substr(1));var eM=function(et){var ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,es=(ez[et[ei+0]]+ez[et[ei+1]]+ez[et[ei+2]]+ez[et[ei+3]]+"-"+ez[et[ei+4]]+ez[et[ei+5]]+"-"+ez[et[ei+6]]+ez[et[ei+7]]+"-"+ez[et[ei+8]]+ez[et[ei+9]]+"-"+ez[et[ei+10]]+ez[et[ei+11]]+ez[et[ei+12]]+ez[et[ei+13]]+ez[et[ei+14]]+ez[et[ei+15]]).toLowerCase();if(!eH(es))throw TypeError("Stringified UUID is invalid");return es},eg=function(et,ei,es){var ef=(et=et||{}).random||(et.rng||ed)();if(ef[6]=15&ef[6]|64,ef[8]=63&ef[8]|128,ei){es=es||0;for(var eu=0;eu<16;++eu)ei[es+eu]=ef[eu];return ei}return eM(ef)}},91094:function(et,ei,es){var ef,eu=es(83454);!function(){"use strict";var ed="input is invalid type",em="finalize already called",eH="object"==typeof window,ez=eH?window:{};ez.JS_SHA3_NO_WINDOW&&(eH=!1);var eV=!eH&&"object"==typeof self;!ez.JS_SHA3_NO_NODE_JS&&"object"==typeof eu&&eu.versions&&eu.versions.node?ez=es.g:eV&&(ez=self);var eM=!ez.JS_SHA3_NO_COMMON_JS&&et.exports,eg=es.amdO,eL=!ez.JS_SHA3_NO_ARRAY_BUFFER&&"undefined"!=typeof ArrayBuffer,eb="0123456789abcdef".split(""),ey=[31,7936,2031616,520093696],eC=[4,1024,262144,67108864],ex=[1,256,65536,16777216],ew=[6,1536,393216,100663296],eN=[0,8,16,24],eS=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],eA=[224,256,384,512],e_=[128,256],eE=["hex","buffer","arrayBuffer","array","digest"],eP={128:168,256:136};(ez.JS_SHA3_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(et){return"[object Array]"===Object.prototype.toString.call(et)}),eL&&(ez.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(et){return"object"==typeof et&&et.buffer&&et.buffer.constructor===ArrayBuffer});for(var eB=function(et,ei,es){return function(ef){return new eJ(et,ei,et).update(ef)[es]()}},eT=function(et,ei,es){return function(ef,eu){return new eJ(et,ei,eu).update(ef)[es]()}},eI=function(et,ei,es){return function(ei,ef,eu,ed){return eF["cshake"+et].update(ei,ef,eu,ed)[es]()}},eR=function(et,ei,es){return function(ei,ef,eu,ed){return eF["kmac"+et].update(ei,ef,eu,ed)[es]()}},eO=function(et,ei,es,ef){for(var eu=0;eu>5,this.byteCount=this.blockCount<<2,this.outputBlocks=es>>5,this.extraBytes=(31&es)>>3;for(var ef=0;ef<50;++ef)this.s[ef]=0}function eY(et,ei,es){eJ.call(this,et,ei,es)}eJ.prototype.update=function(et){if(this.finalized)throw Error(em);var ei,es=typeof et;if("string"!==es){if("object"===es){if(null===et)throw Error(ed);if(eL&&et.constructor===ArrayBuffer)et=new Uint8Array(et);else if(!Array.isArray(et)&&(!eL||!ArrayBuffer.isView(et)))throw Error(ed)}else throw Error(ed);ei=!0}for(var ef,eu,eH=this.blocks,ez=this.byteCount,eV=et.length,eM=this.blockCount,eg=0,eb=this.s;eg>2]|=et[eg]<>2]|=eu<>2]|=(192|eu>>6)<>2]|=(128|63&eu)<=57344?(eH[ef>>2]|=(224|eu>>12)<>2]|=(128|eu>>6&63)<>2]|=(128|63&eu)<>2]|=(240|eu>>18)<>2]|=(128|eu>>12&63)<>2]|=(128|eu>>6&63)<>2]|=(128|63&eu)<=ez){for(this.start=ef-ez,this.block=eH[eM],ef=0;ef>=8,es=255&et;es>0;)eu.unshift(es),et>>=8,es=255&et,++ef;return ei?eu.push(ef):eu.unshift(ef),this.update(eu),eu.length},eJ.prototype.encodeString=function(et){var ei,es=typeof et;if("string"!==es){if("object"===es){if(null===et)throw Error(ed);if(eL&&et.constructor===ArrayBuffer)et=new Uint8Array(et);else if(!Array.isArray(et)&&(!eL||!ArrayBuffer.isView(et)))throw Error(ed)}else throw Error(ed);ei=!0}var ef=0,eu=et.length;if(ei)ef=eu;else for(var em=0;em=57344?ef+=3:(eH=65536+((1023&eH)<<10|1023&et.charCodeAt(++em)),ef+=4)}return ef+=this.encode(8*ef),this.update(et),ef},eJ.prototype.bytepad=function(et,ei){for(var es=this.encode(ei),ef=0;ef>2]|=this.padding[3&ei],this.lastByteIndex===this.byteCount)for(ei=1,et[0]=et[es];ei>4&15]+eb[15&et]+eb[et>>12&15]+eb[et>>8&15]+eb[et>>20&15]+eb[et>>16&15]+eb[et>>28&15]+eb[et>>24&15];em%ei==0&&(eX(es),ed=0)}return eu&&(eH+=eb[(et=es[ed])>>4&15]+eb[15&et],eu>1&&(eH+=eb[et>>12&15]+eb[et>>8&15]),eu>2&&(eH+=eb[et>>20&15]+eb[et>>16&15])),eH},eJ.prototype.arrayBuffer=function(){this.finalize();var et,ei=this.blockCount,es=this.s,ef=this.outputBlocks,eu=this.extraBytes,ed=0,em=0,eH=this.outputBits>>3;et=new ArrayBuffer(eu?ef+1<<2:eH);for(var ez=new Uint32Array(et);em>8&255,ez[et+2]=ei>>16&255,ez[et+3]=ei>>24&255;eH%es==0&&eX(ef)}return ed&&(et=eH<<2,ei=ef[em],ez[et]=255&ei,ed>1&&(ez[et+1]=ei>>8&255),ed>2&&(ez[et+2]=ei>>16&255)),ez},eY.prototype=new eJ,eY.prototype.finalize=function(){return this.encode(this.outputBits,!0),eJ.prototype.finalize.call(this)};var eX=function(et){var ei,es,ef,eu,ed,em,eH,ez,eV,eM,eg,eL,eb,ey,eC,ex,ew,eN,eA,e_,eE,eP,eB,eT,eI,eR,eO,ej,eD,eF,eU,eq,eZ,eG,eW,eK,e$,eJ,eY,eX,eQ,e1,e2,e4,e3,e6,e0,e8,e5,e7,e9,cc,ci,cs,cf,cd,cm,cH,cz,cV,cM,cg,cL;for(ef=0;ef<48;ef+=2)eu=et[0]^et[10]^et[20]^et[30]^et[40],ed=et[1]^et[11]^et[21]^et[31]^et[41],em=et[2]^et[12]^et[22]^et[32]^et[42],eH=et[3]^et[13]^et[23]^et[33]^et[43],ez=et[4]^et[14]^et[24]^et[34]^et[44],eV=et[5]^et[15]^et[25]^et[35]^et[45],eM=et[6]^et[16]^et[26]^et[36]^et[46],eg=et[7]^et[17]^et[27]^et[37]^et[47],eL=et[8]^et[18]^et[28]^et[38]^et[48],eb=et[9]^et[19]^et[29]^et[39]^et[49],ei=eL^(em<<1|eH>>>31),es=eb^(eH<<1|em>>>31),et[0]^=ei,et[1]^=es,et[10]^=ei,et[11]^=es,et[20]^=ei,et[21]^=es,et[30]^=ei,et[31]^=es,et[40]^=ei,et[41]^=es,ei=eu^(ez<<1|eV>>>31),es=ed^(eV<<1|ez>>>31),et[2]^=ei,et[3]^=es,et[12]^=ei,et[13]^=es,et[22]^=ei,et[23]^=es,et[32]^=ei,et[33]^=es,et[42]^=ei,et[43]^=es,ei=em^(eM<<1|eg>>>31),es=eH^(eg<<1|eM>>>31),et[4]^=ei,et[5]^=es,et[14]^=ei,et[15]^=es,et[24]^=ei,et[25]^=es,et[34]^=ei,et[35]^=es,et[44]^=ei,et[45]^=es,ei=ez^(eL<<1|eb>>>31),es=eV^(eb<<1|eL>>>31),et[6]^=ei,et[7]^=es,et[16]^=ei,et[17]^=es,et[26]^=ei,et[27]^=es,et[36]^=ei,et[37]^=es,et[46]^=ei,et[47]^=es,ei=eM^(eu<<1|ed>>>31),es=eg^(ed<<1|eu>>>31),et[8]^=ei,et[9]^=es,et[18]^=ei,et[19]^=es,et[28]^=ei,et[29]^=es,et[38]^=ei,et[39]^=es,et[48]^=ei,et[49]^=es,ey=et[0],eC=et[1],e6=et[11]<<4|et[10]>>>28,e0=et[10]<<4|et[11]>>>28,ej=et[20]<<3|et[21]>>>29,eD=et[21]<<3|et[20]>>>29,cV=et[31]<<9|et[30]>>>23,cM=et[30]<<9|et[31]>>>23,e1=et[40]<<18|et[41]>>>14,e2=et[41]<<18|et[40]>>>14,eG=et[2]<<1|et[3]>>>31,eW=et[3]<<1|et[2]>>>31,ex=et[13]<<12|et[12]>>>20,ew=et[12]<<12|et[13]>>>20,e8=et[22]<<10|et[23]>>>22,e5=et[23]<<10|et[22]>>>22,eF=et[33]<<13|et[32]>>>19,eU=et[32]<<13|et[33]>>>19,cg=et[42]<<2|et[43]>>>30,cL=et[43]<<2|et[42]>>>30,cs=et[5]<<30|et[4]>>>2,cf=et[4]<<30|et[5]>>>2,eK=et[14]<<6|et[15]>>>26,e$=et[15]<<6|et[14]>>>26,eN=et[25]<<11|et[24]>>>21,eA=et[24]<<11|et[25]>>>21,e7=et[34]<<15|et[35]>>>17,e9=et[35]<<15|et[34]>>>17,eq=et[45]<<29|et[44]>>>3,eZ=et[44]<<29|et[45]>>>3,eT=et[6]<<28|et[7]>>>4,eI=et[7]<<28|et[6]>>>4,cd=et[17]<<23|et[16]>>>9,cm=et[16]<<23|et[17]>>>9,eJ=et[26]<<25|et[27]>>>7,eY=et[27]<<25|et[26]>>>7,e_=et[36]<<21|et[37]>>>11,eE=et[37]<<21|et[36]>>>11,cc=et[47]<<24|et[46]>>>8,ci=et[46]<<24|et[47]>>>8,e4=et[8]<<27|et[9]>>>5,e3=et[9]<<27|et[8]>>>5,eR=et[18]<<20|et[19]>>>12,eO=et[19]<<20|et[18]>>>12,cH=et[29]<<7|et[28]>>>25,cz=et[28]<<7|et[29]>>>25,eX=et[38]<<8|et[39]>>>24,eQ=et[39]<<8|et[38]>>>24,eP=et[48]<<14|et[49]>>>18,eB=et[49]<<14|et[48]>>>18,et[0]=ey^~ex&eN,et[1]=eC^~ew&eA,et[10]=eT^~eR&ej,et[11]=eI^~eO&eD,et[20]=eG^~eK&eJ,et[21]=eW^~e$&eY,et[30]=e4^~e6&e8,et[31]=e3^~e0&e5,et[40]=cs^~cd&cH,et[41]=cf^~cm&cz,et[2]=ex^~eN&e_,et[3]=ew^~eA&eE,et[12]=eR^~ej&eF,et[13]=eO^~eD&eU,et[22]=eK^~eJ&eX,et[23]=e$^~eY&eQ,et[32]=e6^~e8&e7,et[33]=e0^~e5&e9,et[42]=cd^~cH&cV,et[43]=cm^~cz&cM,et[4]=eN^~e_&eP,et[5]=eA^~eE&eB,et[14]=ej^~eF&eq,et[15]=eD^~eU&eZ,et[24]=eJ^~eX&e1,et[25]=eY^~eQ&e2,et[34]=e8^~e7&cc,et[35]=e5^~e9&ci,et[44]=cH^~cV&cg,et[45]=cz^~cM&cL,et[6]=e_^~eP&ey,et[7]=eE^~eB&eC,et[16]=eF^~eq&eT,et[17]=eU^~eZ&eI,et[26]=eX^~e1&eG,et[27]=eQ^~e2&eW,et[36]=e7^~cc&e4,et[37]=e9^~ci&e3,et[46]=cV^~cg&cs,et[47]=cM^~cL&cf,et[8]=eP^~ey&ex,et[9]=eB^~eC&ew,et[18]=eq^~eT&eR,et[19]=eZ^~eI&eO,et[28]=e1^~eG&eK,et[29]=e2^~eW&e$,et[38]=cc^~e4&e6,et[39]=ci^~e3&e0,et[48]=cg^~cs&cd,et[49]=cL^~cf&cm,et[0]^=eS[ef],et[1]^=eS[ef+1]};if(eM)et.exports=eF;else{for(eq=0;eqclass ei extends eu{constructor(ei,es,ef,eu,ed){super(ed),this._rate=ei,this._capacity=es,this._delimitedSuffix=ef,this._hashBitLength=eu,this._options=ed,this._state=new et,this._state.initialize(ei,es),this._finalized=!1}_transform(et,ei,es){let ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)}_flush(et){let ei=null;try{this.push(this.digest())}catch(et){ei=et}et(ei)}update(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Digest already called");return ef.isBuffer(et)||(et=ef.from(et,ei)),this._state.absorb(et),this}digest(et){if(this._finalized)throw Error("Digest already called");this._finalized=!0,this._delimitedSuffix&&this._state.absorbLastFewBits(this._delimitedSuffix);let ei=this._state.squeeze(this._hashBitLength/8);return void 0!==et&&(ei=ei.toString(et)),this._resetState(),ei}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let et=new ei(this._rate,this._capacity,this._delimitedSuffix,this._hashBitLength,this._options);return this._state.copy(et._state),et._finalized=this._finalized,et}}},5675:function(et,ei,es){var ef=es(48764).Buffer;let{Transform:eu}=es(88473);et.exports=et=>class ei extends eu{constructor(ei,es,ef,eu){super(eu),this._rate=ei,this._capacity=es,this._delimitedSuffix=ef,this._options=eu,this._state=new et,this._state.initialize(ei,es),this._finalized=!1}_transform(et,ei,es){let ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)}_flush(){}_read(et){this.push(this.squeeze(et))}update(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError("Data must be a string or a buffer");if(this._finalized)throw Error("Squeeze already called");return ef.isBuffer(et)||(et=ef.from(et,ei)),this._state.absorb(et),this}squeeze(et,ei){this._finalized||(this._finalized=!0,this._state.absorbLastFewBits(this._delimitedSuffix));let es=this._state.squeeze(et);return void 0!==ei&&(es=es.toString(ei)),es}_resetState(){return this._state.initialize(this._rate,this._capacity),this}_clone(){let et=new ei(this._rate,this._capacity,this._delimitedSuffix,this._options);return this._state.copy(et._state),et._finalized=this._finalized,et}}},34040:function(et,ei){let es=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648];ei.p1600=function(et){for(let ei=0;ei<24;++ei){let ef=et[0]^et[10]^et[20]^et[30]^et[40],eu=et[1]^et[11]^et[21]^et[31]^et[41],ed=et[2]^et[12]^et[22]^et[32]^et[42],em=et[3]^et[13]^et[23]^et[33]^et[43],eH=et[4]^et[14]^et[24]^et[34]^et[44],ez=et[5]^et[15]^et[25]^et[35]^et[45],eV=et[6]^et[16]^et[26]^et[36]^et[46],eM=et[7]^et[17]^et[27]^et[37]^et[47],eg=et[8]^et[18]^et[28]^et[38]^et[48],eL=et[9]^et[19]^et[29]^et[39]^et[49],eb=eg^(ed<<1|em>>>31),ey=eL^(em<<1|ed>>>31),eC=et[0]^eb,ex=et[1]^ey,ew=et[10]^eb,eN=et[11]^ey,eS=et[20]^eb,eA=et[21]^ey,e_=et[30]^eb,eE=et[31]^ey,eP=et[40]^eb,eB=et[41]^ey;eb=ef^(eH<<1|ez>>>31),ey=eu^(ez<<1|eH>>>31);let eT=et[2]^eb,eI=et[3]^ey,eR=et[12]^eb,eO=et[13]^ey,ej=et[22]^eb,eD=et[23]^ey,eF=et[32]^eb,eU=et[33]^ey,eq=et[42]^eb,eZ=et[43]^ey;eb=ed^(eV<<1|eM>>>31),ey=em^(eM<<1|eV>>>31);let eG=et[4]^eb,eW=et[5]^ey,eK=et[14]^eb,e$=et[15]^ey,eJ=et[24]^eb,eY=et[25]^ey,eX=et[34]^eb,eQ=et[35]^ey,e1=et[44]^eb,e2=et[45]^ey;eb=eH^(eg<<1|eL>>>31),ey=ez^(eL<<1|eg>>>31);let e4=et[6]^eb,e3=et[7]^ey,e6=et[16]^eb,e0=et[17]^ey,e8=et[26]^eb,e5=et[27]^ey,e7=et[36]^eb,e9=et[37]^ey,cc=et[46]^eb,ci=et[47]^ey;eb=eV^(ef<<1|eu>>>31),ey=eM^(eu<<1|ef>>>31);let cs=et[8]^eb,cf=et[9]^ey,cd=et[18]^eb,cm=et[19]^ey,cH=et[28]^eb,cz=et[29]^ey,cV=et[38]^eb,cM=et[39]^ey,cg=et[48]^eb,cL=et[49]^ey,cy=eC,cC=ex,cx=eN<<4|ew>>>28,cw=ew<<4|eN>>>28,ck=eS<<3|eA>>>29,cN=eA<<3|eS>>>29,cS=eE<<9|e_>>>23,cA=e_<<9|eE>>>23,c_=eP<<18|eB>>>14,cE=eB<<18|eP>>>14,cP=eT<<1|eI>>>31,cB=eI<<1|eT>>>31,cT=eO<<12|eR>>>20,cI=eR<<12|eO>>>20,cR=ej<<10|eD>>>22,cO=eD<<10|ej>>>22,cj=eU<<13|eF>>>19,cD=eF<<13|eU>>>19,cF=eq<<2|eZ>>>30,cU=eZ<<2|eq>>>30,cq=eW<<30|eG>>>2,cZ=eG<<30|eW>>>2,cG=eK<<6|e$>>>26,cW=e$<<6|eK>>>26,cK=eY<<11|eJ>>>21,c$=eJ<<11|eY>>>21,cJ=eX<<15|eQ>>>17,cY=eQ<<15|eX>>>17,cX=e2<<29|e1>>>3,cQ=e1<<29|e2>>>3,tc=e4<<28|e3>>>4,ta=e3<<28|e4>>>4,tf=e0<<23|e6>>>9,tu=e6<<23|e0>>>9,td=e8<<25|e5>>>7,tm=e5<<25|e8>>>7,tp=e7<<21|e9>>>11,tH=e9<<21|e7>>>11,tz=ci<<24|cc>>>8,tV=cc<<24|ci>>>8,tv=cs<<27|cf>>>5,tM=cf<<27|cs>>>5,tg=cd<<20|cm>>>12,tL=cm<<20|cd>>>12,tb=cz<<7|cH>>>25,tC=cH<<7|cz>>>25,tw=cV<<8|cM>>>24,tN=cM<<8|cV>>>24,tS=cg<<14|cL>>>18,tA=cL<<14|cg>>>18;et[0]=cy^~cT&cK,et[1]=cC^~cI&c$,et[10]=tc^~tg&ck,et[11]=ta^~tL&cN,et[20]=cP^~cG&td,et[21]=cB^~cW&tm,et[30]=tv^~cx&cR,et[31]=tM^~cw&cO,et[40]=cq^~tf&tb,et[41]=cZ^~tu&tC,et[2]=cT^~cK&tp,et[3]=cI^~c$&tH,et[12]=tg^~ck&cj,et[13]=tL^~cN&cD,et[22]=cG^~td&tw,et[23]=cW^~tm&tN,et[32]=cx^~cR&cJ,et[33]=cw^~cO&cY,et[42]=tf^~tb&cS,et[43]=tu^~tC&cA,et[4]=cK^~tp&tS,et[5]=c$^~tH&tA,et[14]=ck^~cj&cX,et[15]=cN^~cD&cQ,et[24]=td^~tw&c_,et[25]=tm^~tN&cE,et[34]=cR^~cJ&tz,et[35]=cO^~cY&tV,et[44]=tb^~cS&cF,et[45]=tC^~cA&cU,et[6]=tp^~tS&cy,et[7]=tH^~tA&cC,et[16]=cj^~cX&tc,et[17]=cD^~cQ&ta,et[26]=tw^~c_&cP,et[27]=tN^~cE&cB,et[36]=cJ^~tz&tv,et[37]=cY^~tV&tM,et[46]=cS^~cF&cq,et[47]=cA^~cU&cZ,et[8]=tS^~cy&cT,et[9]=tA^~cC&cI,et[18]=cX^~tc&tg,et[19]=cQ^~ta&tL,et[28]=c_^~cP&cG,et[29]=cE^~cB&cW,et[38]=tz^~tv&cx,et[39]=tV^~tM&cw,et[48]=cF^~cq&tf,et[49]=cU^~cZ&tu,et[0]^=es[2*ei],et[1]^=es[2*ei+1]}}},79653:function(et,ei,es){var ef=es(48764).Buffer;let eu=es(34040);function ed(){this.state=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],this.blockSize=null,this.count=0,this.squeezing=!1}ed.prototype.initialize=function(et,ei){for(let et=0;et<50;++et)this.state[et]=0;this.blockSize=et/8,this.count=0,this.squeezing=!1},ed.prototype.absorb=function(et){for(let ei=0;ei>>8*(this.count%4)&255,this.count+=1,this.count===this.blockSize&&(eu.p1600(this.state),this.count=0);return ei},ed.prototype.copy=function(et){for(let ei=0;ei<50;++ei)et.state[ei]=this.state[ei];et.blockSize=this.blockSize,et.count=this.count,et.squeezing=this.squeezing},et.exports=ed},62318:function(et,ei,es){"use strict";var ef=es(35717),eu=es(3349),ed=es(89509).Buffer,em=Array(16);function eH(){eu.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878}function ez(et,ei){return et<>>32-ei}function eV(et,ei,es,ef,eu,ed,em){return ez(et+(ei&es|~ei&ef)+eu+ed|0,em)+ei|0}function eM(et,ei,es,ef,eu,ed,em){return ez(et+(ei&ef|es&~ef)+eu+ed|0,em)+ei|0}function eg(et,ei,es,ef,eu,ed,em){return ez(et+(ei^es^ef)+eu+ed|0,em)+ei|0}function eL(et,ei,es,ef,eu,ed,em){return ez(et+(es^(ei|~ef))+eu+ed|0,em)+ei|0}ef(eH,eu),eH.prototype._update=function(){for(var et=em,ei=0;ei<16;++ei)et[ei]=this._block.readInt32LE(4*ei);var es=this._a,ef=this._b,eu=this._c,ed=this._d;es=eV(es,ef,eu,ed,et[0],3614090360,7),ed=eV(ed,es,ef,eu,et[1],3905402710,12),eu=eV(eu,ed,es,ef,et[2],606105819,17),ef=eV(ef,eu,ed,es,et[3],3250441966,22),es=eV(es,ef,eu,ed,et[4],4118548399,7),ed=eV(ed,es,ef,eu,et[5],1200080426,12),eu=eV(eu,ed,es,ef,et[6],2821735955,17),ef=eV(ef,eu,ed,es,et[7],4249261313,22),es=eV(es,ef,eu,ed,et[8],1770035416,7),ed=eV(ed,es,ef,eu,et[9],2336552879,12),eu=eV(eu,ed,es,ef,et[10],4294925233,17),ef=eV(ef,eu,ed,es,et[11],2304563134,22),es=eV(es,ef,eu,ed,et[12],1804603682,7),ed=eV(ed,es,ef,eu,et[13],4254626195,12),eu=eV(eu,ed,es,ef,et[14],2792965006,17),ef=eV(ef,eu,ed,es,et[15],1236535329,22),es=eM(es,ef,eu,ed,et[1],4129170786,5),ed=eM(ed,es,ef,eu,et[6],3225465664,9),eu=eM(eu,ed,es,ef,et[11],643717713,14),ef=eM(ef,eu,ed,es,et[0],3921069994,20),es=eM(es,ef,eu,ed,et[5],3593408605,5),ed=eM(ed,es,ef,eu,et[10],38016083,9),eu=eM(eu,ed,es,ef,et[15],3634488961,14),ef=eM(ef,eu,ed,es,et[4],3889429448,20),es=eM(es,ef,eu,ed,et[9],568446438,5),ed=eM(ed,es,ef,eu,et[14],3275163606,9),eu=eM(eu,ed,es,ef,et[3],4107603335,14),ef=eM(ef,eu,ed,es,et[8],1163531501,20),es=eM(es,ef,eu,ed,et[13],2850285829,5),ed=eM(ed,es,ef,eu,et[2],4243563512,9),eu=eM(eu,ed,es,ef,et[7],1735328473,14),ef=eM(ef,eu,ed,es,et[12],2368359562,20),es=eg(es,ef,eu,ed,et[5],4294588738,4),ed=eg(ed,es,ef,eu,et[8],2272392833,11),eu=eg(eu,ed,es,ef,et[11],1839030562,16),ef=eg(ef,eu,ed,es,et[14],4259657740,23),es=eg(es,ef,eu,ed,et[1],2763975236,4),ed=eg(ed,es,ef,eu,et[4],1272893353,11),eu=eg(eu,ed,es,ef,et[7],4139469664,16),ef=eg(ef,eu,ed,es,et[10],3200236656,23),es=eg(es,ef,eu,ed,et[13],681279174,4),ed=eg(ed,es,ef,eu,et[0],3936430074,11),eu=eg(eu,ed,es,ef,et[3],3572445317,16),ef=eg(ef,eu,ed,es,et[6],76029189,23),es=eg(es,ef,eu,ed,et[9],3654602809,4),ed=eg(ed,es,ef,eu,et[12],3873151461,11),eu=eg(eu,ed,es,ef,et[15],530742520,16),ef=eg(ef,eu,ed,es,et[2],3299628645,23),es=eL(es,ef,eu,ed,et[0],4096336452,6),ed=eL(ed,es,ef,eu,et[7],1126891415,10),eu=eL(eu,ed,es,ef,et[14],2878612391,15),ef=eL(ef,eu,ed,es,et[5],4237533241,21),es=eL(es,ef,eu,ed,et[12],1700485571,6),ed=eL(ed,es,ef,eu,et[3],2399980690,10),eu=eL(eu,ed,es,ef,et[10],4293915773,15),ef=eL(ef,eu,ed,es,et[1],2240044497,21),es=eL(es,ef,eu,ed,et[8],1873313359,6),ed=eL(ed,es,ef,eu,et[15],4264355552,10),eu=eL(eu,ed,es,ef,et[6],2734768916,15),ef=eL(ef,eu,ed,es,et[13],1309151649,21),es=eL(es,ef,eu,ed,et[4],4149444226,6),ed=eL(ed,es,ef,eu,et[11],3174756917,10),eu=eL(eu,ed,es,ef,et[2],718787259,15),ef=eL(ef,eu,ed,es,et[9],3951481745,21),this._a=this._a+es|0,this._b=this._b+ef|0,this._c=this._c+eu|0,this._d=this._d+ed|0},eH.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ed.allocUnsafe(16);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et},et.exports=eH},79746:function(et){function ei(et,ei){if(!et)throw Error(ei||"Assertion failed")}et.exports=ei,ei.equal=function(et,ei,es){if(et!=ei)throw Error(es||"Assertion failed: "+et+" != "+ei)}},34504:function(et,ei){"use strict";var es=ei;function ef(et,ei){if(Array.isArray(et))return et.slice();if(!et)return[];var es=[];if("string"!=typeof et){for(var ef=0;ef>8,em=255&eu;ed?es.push(ed,em):es.push(em)}return es}function eu(et){return 1===et.length?"0"+et:et}function ed(et){for(var ei="",es=0;eset.toUpperCase(),eb=(0,ed.useMemo)(()=>{if(eM)return[];let et=ez.pathname.split("/").filter(et=>""!==et).map((et,eu,ed)=>{let em=null==ei?void 0:ei[et];if(eu===ed.length-1){let[,ei]=ez.asPath.split("#"),eu=es||(em?"object"==typeof em?em[ei]:em:eL(et));return(0,ef.jsx)("span",{children:eu},et)}let eH=em||eL(et);return(0,ef.jsx)(eV(),{href:String("../").repeat(ed.length-(eu+1))+et,children:eH},et)});return eu&&et.unshift((0,ef.jsx)(eV(),{href:"/",children:(null==ei?void 0:ei["/"])||"HOME"},"home")),et},[ez.pathname,ez.asPath,es,ei,eM,eu]);return eM?null:(0,ef.jsx)(eg,{navLinks:eb,...eH})}var eg=(0,eu.ZP)(eH.aG).withConfig({displayName:"cmp___StyledBreadcrumb",componentId:"sc-1pse81j-0"})({paddingLeft:"1.5rem",paddingRight:"1.5rem",paddingTop:"1.25rem",paddingBottom:"1.25rem","@media (min-width: 768px)":{paddingLeft:"4rem",paddingRight:"4rem"}})},87531:function(et,ei,es){"use strict";es.d(ei,{Z:function(){return ed}});var ef=es(19521);let eu=ef.ZP.div.withConfig({displayName:"styles__StyledContainer",componentId:"sc-ex4pya-0"})(["",""],et=>{let{theme:ei}=et;return(0,ef.iv)([""," box-sizing:border-box;width:100%;margin:0 auto;max-width:","rem;"],{paddingLeft:"1.5rem",paddingRight:"1.5rem","@media (min-width: 768px)":{paddingLeft:"4rem",paddingRight:"4rem"}},ei.breakpoint.xxl+12.5)});var ed=eu},36470:function(et,ei,es){"use strict";es.d(ei,{WE:function(){return eH},mr:function(){return ez}});var ef=es(85893),eu=es(67294),ed=es(48847);let em=(0,eu.createContext)([ed.E3,()=>null]);function eH(et){let{children:ei}=et,[es,eH]=(0,eu.useReducer)(ed.I6,ed.E3);return(0,ef.jsx)(em.Provider,{value:[es,eH],children:ei})}function ez(){return(0,eu.useContext)(em)}},65526:function(et,ei,es){"use strict";es.d(ei,{Y:function(){return eH}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(22733);class eH{async getAll(){try{let et=await ef.aggregate.Get({address:this.account.address,keys:[this.key]});return this.parseAggregate(et)}catch(et){return[]}}async get(et){let ei=await this.getAll();return ei.find(ei=>ei.id===et)}async add(et,ei){et=Array.isArray(et)?et:[et],et=await this.parseDomains(et,ei);try{if(!et.length)return[];let ei=et.reduce((et,ei)=>{let{name:es,ref:ef,target:eu,programType:em}=ei,eH={message_id:ef,programType:em,type:eu};return eu===ed.vs.Program&&(eH.programType=ei.programType||ed.py.Instance),et[es]=eH,et},{}),es=await ef.aggregate.Publish({account:this.account,key:this.key,channel:this.channel,content:ei});return this.parseNewAggregate(es)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;let ei={[et]:null};try{await ef.aggregate.Publish({account:this.account,key:this.key,channel:this.channel,content:ei})}catch(et){throw eu.Z.RequestFailed(et)}}async checkStatus(et){let ei=await fetch("https://api.dns.public.aleph.sh/domain/check",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({name:et.name,owner:this.account.address,target:et.target})}),es=await ei.json();return es}async parseDomains(et){let ei=!(arguments.length>1)||void 0===arguments[1]||arguments[1];et=await eH.addManySchema.parseAsync(et);let es=await this.getAll(),ef=new Set(es.map(et=>et.name));return ei?et.map(et=>{if(!ef.has(et.name))return et;throw Error("Domain name already used by another resource: ".concat(et.name))}):et.filter(et=>!ef.has(et.name))}parseAggregate(et){let ei=et[this.key];return this.parseAggregateItems(ei)}parseNewAggregate(et){let ei=et.content.content;return this.parseAggregateItems(ei)}parseAggregateItems(et){return Object.entries(et).filter(et=>{let[,ei]=et;return null!==ei}).map(et=>{let[ei,es]=et;return this.parseAggregateItem(ei,es)})}parseAggregateItem(et,ei){let{message_id:es,type:ef}=ei,eu={type:ed.py.Domain,id:et,name:et,target:ef,ref:es,confirmed:!0};return ef===ed.vs.Program&&(eu.programType=ei.programType||ed.py.Instance),eu}constructor(et,ei=ed.T4,es=ed.fM){this.account=et,this.key=ei,this.channel=es}}(()=>{eH.addSchema=em.CJ})(),(()=>{eH.addManySchema=em.I})()},94443:function(et,ei,es){"use strict";es.d(ei,{E:function(){return ed}});var ef=es(59925),eu=es(33358);class ed{parseEnvVars(et){if(et&&0!==et.length)return Object.fromEntries(et.map(et=>{let{name:ei,value:es}=et;return[ei,es]}))}async parseDomains(et,ei){if(!ei||0===ei.length)return[];let es=ei.map(ei=>({...ei,ref:et}));return this.domainManager.add(es,!1)}async parseVolumes(et){if(!et||0===(et=Array.isArray(et)?et:[et]).length)return;let ei=await this.volumeManager.add(et),es=et.map((et,es)=>et.volumeType===ef.z.New?{...et,volumeType:ef.z.Existing,refHash:ei[es].id}:et);return es.map(et=>{if(et.volumeType===ef.z.Persistent){let{mountPath:ei,size:es,name:ef}=et;return{persistence:"host",mount:ei,size_mib:es,name:ef}}let{refHash:ei,mountPath:es,useLatest:eu=!1}=et;return{ref:ei,mount:es,use_latest:eu}})}parseSpecs(et){return{vcpus:et.cpu,memory:et.ram}}parseMetadata(){let et=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"Untitled",ei=arguments.length>1?arguments[1]:void 0,es=arguments.length>2?arguments[2]:void 0,ef={name:et};return ei&&ei.length>0&&(ef.tags=ei),{...es,...ef}}constructor(et,ei,es){this.account=et,this.volumeManager=ei,this.domainManager=es}}(()=>{ed.getExecutableCost=et=>{let{type:ei,isPersistent:es,specs:ed,capabilities:em={},volumes:eH=[]}=et;if(!ed)return{computeTotalCost:0,volumeTotalCost:0,perVolumeCost:[],totalCost:0};es=ei===eu.py.Instance||es;let ez=es?2e3:200,eV=Object.values(em).reduce((et,ei)=>et+Number(ei),1),eM=ez*ed.cpu*eV,eg=ei===eu.py.Instance?0:ed.storage,{perVolumeCost:eL,totalCost:eb}=ef.l.getCost({volumes:eH,sizeDiscount:eg}),ey=eb+eM;return{computeTotalCost:eM,perVolumeCost:eL,volumeTotalCost:eb,totalCost:ey}}})()},21685:function(et,ei,es){"use strict";es.d(ei,{p:function(){return eg}});var ef=es(39261),eu=es(22733),ed=es(32523),em=es(70714),eH=es(34853),ez=es(59925),eV=es(33358),eM=es(48071);class eg{static getStaticProgramConfig(){let et=!0,ei={indexer:!0},es={...(0,ed.Fk)(!0)[1]},ef={lang:eM.D.Node,type:"ref",encoding:em.Encoding.squashfs,entrypoint:"dist/run.js",programRef:"32c3ac6e4810a18d3d3f64cb4dd6b2eb111993e9f9832124d3ad5efba93ce13e"},eu=eM.Y[ef.lang].runtime,eH=[{volumeType:ez.z.Persistent,name:"data",mountPath:"/data",size:40960}];return{isPersistent:et,metadata:ei,specs:es,runtime:eu,code:ef,volumes:eH}}async getAll(){try{let et=await this.programManager.getAll();return et.filter(et=>{var ei;return!!(null===(ei=et.metadata)||void 0===ei?void 0:ei.indexer)})}catch(et){return[]}}async get(et){var ei;let es=await this.programManager.get(et);if(null==es?void 0:null===(ei=es.metadata)||void 0===ei?void 0:ei.indexer)return es}async add(et){let ei=await this.parseIndexers(et);return await this.programManager.add(ei)}async del(et){await this.programManager.del(et)}parseEnvVars(et){let ei=et.networks.map(et=>{let{id:ei,blockchain:es}=et;return es===ei?ei:"".concat(es,":").concat(ei)}).join(","),es=(0,eH.mA)(et.name),ef=et.networks.reduce((et,ei)=>(et[this.getBlockchainEnvName(ei.id,"INDEX_LOGS")]="true",et[this.getBlockchainEnvName(ei.id,"INDEX_BLOCKS")]="false",et[this.getBlockchainEnvName(ei.id,"INDEX_TRANSACTIONS")]="false",et[this.getBlockchainEnvName(ei.id,"RPC")]=ei.rpcUrl,et[this.getBlockchainEnvName(ei.id,"EXPLORER_URL")]=ei.abiUrl?ei.abiUrl:eV._G[ei.blockchain],et),{}),eu=et.accounts.map(et=>{let{network:ei,contract:es,deployer:ef,supply:eu,decimals:ed}=et;return"".concat(ei,":").concat(es,":").concat(ef,":").concat(eu,":").concat(ed)}).join(",");return Object.entries({...ef,INDEXER_ACCOUNTS:eu,INDEXER_NAMESPACE:es,INDEXER_BLOCKCHAINS:ei,INDEXER_DATA_PATH:"/data"}).map(et=>{let[ei,es]=et;return{name:ei,value:es}})}async parseIndexers(et){et=await eg.addSchema.parseAsync(et);let{name:ei,tags:es}=et,ef=this.parseEnvVars(et),{code:eu,specs:ed,runtime:em,metadata:eH,isPersistent:ez,volumes:eV}=eg.getStaticProgramConfig();return{code:eu,name:ei,tags:es,specs:ed,runtime:em,envVars:ef,volumes:eV,metadata:eH,isPersistent:ez}}getBlockchainEnvName(et,ei){return(0,eH.D1)("".concat(et,"_").concat(ei)).toUpperCase()}constructor(et,ei){this.account=et,this.programManager=ei}}(()=>{eg.addSchema=eu.Ot})(),(()=>{eg.getCost=et=>{let{specs:ei}=eg.getStaticProgramConfig();return ef.L.getCost({...et,isPersistent:!0,specs:ei})}})()},49875:function(et,ei,es){"use strict";es.d(ei,{u:function(){return eM}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(57492),ez=es(94443),eV=es(22733);class eM extends ez.E{async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:eH.MessageType.instance,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:eH.MessageType.instance,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){try{let ei=await this.parseInstance(et),es=await ef.instance.publish(ei),[eu]=await this.parseMessages([es]);return await this.parseDomains(eu.id,et.domains),eu}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async checkStatus(et){let ei=await fetch("https://scheduler.api.aleph.sh/api/v0/allocation/".concat(et.id));if(404===ei.status)return;let es=await ei.json();return es}async parseInstance(et){et=await eM.addSchema.parseAsync(et);let{account:ei,channel:es}=this,{envVars:ef,specs:eu,image:ed,sshKeys:em,name:eH,tags:ez}=et,eV=this.parseEnvVars(ef),eg=this.parseSpecs(eu),eL=this.parseMetadata(eH,ez),eb=await this.parseSSHKeys(em),ey=await this.parseVolumes(et.volumes);return{account:ei,channel:es,variables:eV,resources:eg,metadata:eL,image:ed,authorized_keys:eb,volumes:ey}}async parseVolumes(et){if(et)return et=(et=Array.isArray(et)?et:[et]).filter(et=>!et.isFake),super.parseVolumes(et)}async parseSSHKeys(et){if(!et||0===et.length)return;let ei=et.filter(et=>et.isNew&&et.isSelected);return await this.sshKeyManager.add(ei,!1),et.filter(et=>et.isSelected).map(et=>{let{key:ei}=et;return ei})}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>{let es=et.content.volumes.reduce((et,es)=>et+("size_mib"in es?es.size_mib:ei[es.ref]),0);return{id:et.item_hash,...et.content,type:ed.py.Instance,url:(0,em.DI)(et),date:(0,em._3)(et.time),size:es,confirmed:!!et.confirmed}})}constructor(et,ei,es,ef,eu,em=ed.Dl){super(et,ei,es),this.account=et,this.volumeManager=ei,this.domainManager=es,this.sshKeyManager=ef,this.fileManager=eu,this.channel=em}}(()=>{eM.addSchema=eV.OC})(),(()=>{eM.getCost=et=>ez.E.getExecutableCost({...et,type:ed.py.Instance})})()},48071:function(et,ei,es){"use strict";var ef,eu;es.d(ei,{D:function(){return eu},Y:function(){return ed}}),function(et){et.Runtime1="bd79839bf96e595a06da5ac0b6ba51dea6f7e2591bb913deccded04d831d29f4",et.Runtime2="bd79839bf96e595a06da5ac0b6ba51dea6f7e2591bb913deccded04d831d29f4 ",et.Runtime3="3c238dd3ffba73ab9b2cccb90a11e40e78aff396152de922a6d794a0a65a305e",et.Custom="custom"}(ef||(ef={})),ef.Runtime1,ef.Runtime1,ef.Runtime2,ef.Runtime2,ef.Runtime3,ef.Runtime3,ef.Custom,ef.Custom,function(et){et.Python="python",et.Node="node",et.Other="other"}(eu||(eu={}));let ed={[eu.Python]:{id:eu.Python,lang:"python",runtime:ef.Runtime1},[eu.Node]:{id:eu.Node,lang:"javascript",runtime:ef.Runtime3},[eu.Other]:{id:eu.Other,lang:"text",runtime:ef.Custom}}},39261:function(et,ei,es){"use strict";es.d(ei,{L:function(){return eL}});var ef=es(67572),eu=es(70714),ed=es(81287),em=es(33358),eH=es(34853),ez=es(57492),eV=es(94443),eM=es(22733),eg=es(48071);class eL extends eV.E{async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:ez.MessageType.program,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:ez.MessageType.program,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){try{let ei=await this.parseProgram(et),es=await ef.program.publish(ei),[eu]=await this.parseMessages([es]);return await this.parseDomains(eu.id,et.domains),eu}catch(et){throw ed.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw ed.Z.RequestFailed(et)}}async download(et){let ei=et.code.ref,es=await this.messageManager.get(ei),ef=es.content.item_hash,eu=await fetch("".concat(em.Sd).concat(ef)),ed=await eu.blob();return(0,eH.lm)(ed,"VM_".concat(et.id.slice(-12),".zip"))}async parseCode(et){if("text"===et.type)return{entrypoint:"main:app",file:new Blob([et.text],{type:"text/plain"}),encoding:eu.Encoding.plain};if("file"===et.type){let ei;if(!et.file)throw Error("Invalid function code file");let es=et.file.name;if(es.endsWith(".zip"))ei=eu.Encoding.zip;else if(es.endsWith(".sqsh"))ei=eu.Encoding.squashfs;else throw Error("Invalid function code file");return{entrypoint:et.entrypoint,file:et.file,encoding:ei}}if("ref"===et.type)return{entrypoint:et.entrypoint,encoding:et.encoding,programRef:et.programRef};throw Error("Invalid function code type")}async parseProgram(et){et=await eL.addSchema.parseAsync(et);let{account:ei,channel:es}=this,{name:ef,tags:eu,isPersistent:ed,envVars:em,specs:eH}=et,ez=this.parseEnvVars(em),{memory:eV,vcpus:eM}=this.parseSpecs(eH),eg=this.parseMetadata(ef,eu,et.metadata),eb=this.parseRuntime(et),ey=await this.parseVolumes(et.volumes),eC=await this.parseCode(et.code);return{account:ei,channel:es,runtime:eb,isPersistent:ed,variables:ez,memory:eV,vcpus:eM,volumes:ey,...eC,metadata:eg}}parseRuntime(et){let{code:ei,runtime:es}=et;if(es)return es;if(ei.lang===eg.D.Other)throw Error("Custom runtime should be added");return eg.Y[ei.lang].runtime}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>{let es=et.content.volumes.reduce((et,es)=>et+("size_mib"in es?es.size_mib:ei[es.ref]),0);return{id:et.item_hash,...et.content,type:em.py.Program,url:(0,eH.DI)(et),urlVM:"".concat(em.gC).concat(et.item_hash),date:(0,eH._3)(et.time),size:es,confirmed:!!et.confirmed}})}constructor(et,ei,es,ef,eu,ed=em.d1){super(et,ei,es),this.account=et,this.volumeManager=ei,this.domainManager=es,this.messageManager=ef,this.fileManager=eu,this.channel=ed}}(()=>{eL.addSchema=eM._G})(),(()=>{eL.getCost=et=>eV.E.getExecutableCost({...et,type:em.py.Program})})()},61941:function(et,ei,es){"use strict";es.d(ei,{X:function(){return ez}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(22733);class ez{async getAll(){try{let et=await ef.post.Get({addresses:[this.account.address],types:[this.type],channels:[this.channel]});return this.parsePosts(et.posts)}catch(et){return[]}}async get(et){let ei=await ef.post.Get({addresses:[this.account.address],types:[this.type],channels:[this.channel],hashes:[et]}),[es]=this.parsePosts(ei.posts);return es}async getByValues(et){let ei=await this.getAll();return et.map(et=>ei.find(ei=>ei.key===et))}async add(et,ei){et=Array.isArray(et)?et:[et],et=await this.parseSSHKeys(et,ei);try{let ei=await Promise.all(et.map(et=>{let{key:ei,label:es}=et;return ef.post.Publish({account:this.account,postType:this.type,channel:this.channel,content:{key:ei,label:es}})}));return this.parseNewPosts(ei)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async parseSSHKeys(et){let ei=!(arguments.length>1)||void 0===arguments[1]||arguments[1];et=await ez.addManySchema.parseAsync(et);let es=await this.getAll(),ef=new Set(es.map(et=>et.key));return ei?et.map(et=>{if(!ef.has(et.key))return et;throw Error("SSH key already exists on your collection: ".concat(et.label||et.key))}):et.filter(et=>!ef.has(et.key))}parsePosts(et){return et.map(et=>this.parsePost(et,et.content))}parseNewPosts(et){return et.map(et=>this.parsePost(et,et.content.content))}parseNewPost(et){return this.parsePost(et,et.content.content)}parsePost(et,ei){return{type:ed.py.SSHKey,id:et.item_hash,...ei,url:(0,em.DI)(et),date:(0,em._3)(et.time),confirmed:!!et.confirmed}}constructor(et,ei=ed.Wt,es=ed.GI){this.account=et,this.type=ei,this.channel=es}}(()=>{ez.addSchema=eH.ve})(),(()=>{ez.addManySchema=eH.K7})()},59925:function(et,ei,es){"use strict";es.d(ei,{l:function(){return eV},z:function(){return ed.lf}});var ef=es(67572),eu=es(81287),ed=es(33358),em=es(34853),eH=es(57492),ez=es(22733);class eV{static getVolumeSize(et){if(et.volumeType===ed.lf.New){var ei;return(0,em.Fx)((null==et?void 0:null===(ei=et.file)||void 0===ei?void 0:ei.size)||0,{from:"B",to:"MiB"})}return et.size||0}static getVolumeMiBPrice(et){return et.volumeType!==ed.lf.New||et.mountPath?20:1/3}static getPerVolumeCost(et){let{volumes:ei=[],sizeDiscount:es=0,exclude:ef=[ed.lf.Existing]}=et;return ei.map(et=>{let ei=ef.includes(et.volumeType),eu=this.getVolumeSize(et)||0,ed=this.getVolumeMiBPrice(et);if(ei)return{size:eu,price:0,discount:0,cost:0};let em=eu;es>0&&(em<=es?(es-=em,em=0):(em-=es,es=0));let eH=eu>0?1-em/eu:0,ez=eu*ed,eV=em*ed;return{size:eu,price:ez,discount:eH,cost:eV}},[])}static getCost(et){var ei;et={...et,volumes:null===(ei=et.volumes)||void 0===ei?void 0:ei.filter(et=>!et.isFake)};let es=this.getPerVolumeCost(et),ef=Math.ceil(Object.values(es).reduce((et,ei)=>et+ei.cost,0));return{perVolumeCost:es,totalCost:ef}}async getAll(){try{let et=await ef.any.GetMessages({addresses:[this.account.address],messageType:eH.MessageType.store,channels:[this.channel]});return await this.parseMessages(et.messages)}catch(et){return[]}}async get(et){let ei=await ef.any.GetMessage({hash:et,messageType:eH.MessageType.store,channel:this.channel}),[es]=await this.parseMessages([ei]);return es}async add(et){et=Array.isArray(et)?et:[et];let ei=await this.parseNewVolumes(et);if(0===ei.length)return[];try{let{account:et,channel:es}=this,eu=await Promise.all(ei.map(async ei=>{let{file:eu}=ei;return ef.store.Publish({account:et,channel:es,fileObject:eu})}));return await this.parseMessages(eu)}catch(et){throw eu.Z.RequestFailed(et)}}async del(et){et="string"==typeof et?et:et.id;try{await ef.forget.Publish({account:this.account,channel:this.channel,hashes:[et]})}catch(et){throw eu.Z.RequestFailed(et)}}async download(et){et="string"==typeof et?et:et.id;let ei=await fetch("".concat(ed.Sd).concat(et)),es=await ei.blob();return(0,em.lm)(es,"Volume_".concat(et.slice(-12),".sqsh"))}async parseNewVolumes(et){let ei=et.filter(et=>et.volumeType===ed.lf.New&&!!et.file);return et=await eV.addManySchema.parseAsync(ei),ei}async parseMessages(et){let ei=await this.fileManager.getSizesMap();return et.filter(et=>{let{content:ei}=et;return void 0!==ei}).map(et=>this.parseMessage(et,et.content,ei))}parseMessage(et,ei,es){return{id:et.item_hash,...ei,type:ed.py.Volume,volumeType:ed.lf.Existing,url:(0,em.DI)(et),date:(0,em._3)(et.time),size:es[et.item_hash],confirmed:!!et.confirmed}}constructor(et,ei,es=ed.yk){this.account=et,this.fileManager=ei,this.channel=es}}(()=>{eV.addSchema=ez.wy})(),(()=>{eV.addManySchema=ez.iq})()},33358:function(et,ei,es){"use strict";var ef,eu,ed,em;es.d(ei,{Dl:function(){return ey},GI:function(){return eb},K_:function(){return eN},MQ:function(){return em},Sd:function(){return ez},T4:function(){return eV},Wt:function(){return eM},_G:function(){return eA},d1:function(){return eC},fM:function(){return ex},gC:function(){return eH},lf:function(){return ed},py:function(){return ef},sT:function(){return eg},sv:function(){return ew},vs:function(){return eu},yk:function(){return eL}});let eH="https://aleph.sh/vm/",ez="https://api2.aleph.im/api/v0/storage/raw/",eV="domains",eM="ALEPH-SSH",eg="ALEPH-CLOUDSOLUTIONS",eL=eg,eb=eg,ey=eg,eC=eg,ex=eg,ew={"/":"SOLUTIONS","/dashboard/function":"SETUP NEW FUNCTION","/dashboard/volume":"SETUP NEW VOLUME"};!function(et){et.Volume="volume",et.Program="program",et.Instance="instance",et.SSHKey="sshKey",et.Domain="domain",et.Indexer="indexer"}(ef||(ef={})),function(et){et.IPFS="ipfs",et.Program="program",et.Instance="instance"}(eu||(eu={})),function(et){et.New="new",et.Existing="existing",et.Persistent="persistent"}(ed||(ed={}));let eN={[ef.Volume]:"Volume",[ef.Program]:"Function",[ef.Instance]:"Instance",[ef.SSHKey]:"SSH Key",[ef.Domain]:"Domain",[ef.Indexer]:"Indexer"};!function(et){et.Ethereum="ethereum",et.Bsc="bsc"}(em||(em={}));let eS="https://api.etherscan.io/api?module=contract&action=getabi&address=0x27702a26126e0B3702af63Ee09aC4d1A084EF628",eA={[em.Ethereum]:eS,[em.Bsc]:eS}},81287:function(et,ei){"use strict";ei.Z={ChainNotYetSupported:Error("Chain is not yet supported"),RequestTimeout:Error("Request timed out"),RequestFailed:et=>Error("Request failed",{cause:et})}},22733:function(et,ei,es){"use strict";es.d(ei,{CJ:function(){return eB},I:function(){return eT},K7:function(){return eP},OC:function(){return e6},Ot:function(){return ci},_G:function(){return e3},iq:function(){return eR},ve:function(){return eE},wy:function(){return eI}});var ef=es(1604),eu=es(33358),ed=es(34853),em=es(70714),eH=es(48071);let ez=ef.z.string().trim().min(1,{message:"Required field"});function eV(et){return et.optional().or(ef.z.literal(""))}let eM=ef.z.string().trim().optional(),eg=ez.regex(/^[0-9a-f]{64}$/,{message:"Invalid hash format"}),eL=ez.regex(/^((?!-))(xn--)?[a-z0-9][a-z0-9-_]{0,61}[a-z0-9]{0,1}\.(xn--)?([a-z0-9\-]{1,61}|[a-z0-9-]{1,30}\.[a-z]{2,})$/,{message:"Invalid domain format"}),eb=ez.regex(/^(?:http(s)?:\/\/)?[\w.-]+(?:\.[\w\.-]+)+[\w\-\._~:/?#[\]@!\$&'\(\)\*\+,;=.]+$/,{message:"Invalid url format"}),ey=ez.regex(/^(\/[^\/ ]*)+\/?$/,{message:"Invalid path format"}),eC=ez.regex(/^0x[a-fA-F0-9]{40}$/,{message:"Invalid address format"}),ex=ez.regex(/^[0-9]+$/,{message:"Invalid supply format"}),ew=ef.z.custom(et=>et instanceof File,"Required file").refine(et=>"application/zip"===et.type&&et.name.endsWith(".zip")||et.name.endsWith(".sqsh")||et.name.endsWith(".squashfs"),{message:"only .zip, .sqsh and .squashfs formats are valid"}).refine(et=>et.size>0,{message:"File size should be greater than 0"}),eN=ef.z.custom(et=>et instanceof File,"Required file").refine(et=>(console.log(et),"application/zip"===et.type&&et.name.endsWith(".zip")||et.name.endsWith(".sqsh")||et.name.endsWith(".squashfs")),{message:"only .zip, .sqsh and .squashfs formats are valid"}).refine(et=>et.size>0,{message:"File size should be greater than 0"}),eS=ef.z.enum([eu.py.Instance,eu.py.Program]),eA=ef.z.enum([eu.MQ.Ethereum,eu.MQ.Bsc]),e_=ef.z.record(ez,ef.z.unknown()),eE=ef.z.object({key:ez,label:eM}),eP=ef.z.array(eE),eB=ef.z.object({name:eL,target:ef.z.enum([eu.vs.IPFS,eu.vs.Program,eu.vs.Instance]),programType:eS,ref:eg}),eT=ef.z.array(eB),eI=ef.z.object({volumeType:ef.z.literal(eu.lf.New),file:ew}),eR=ef.z.array(eI),eO=eI.extend({mountPath:ey,useLatest:ef.z.coerce.boolean(),isFake:ef.z.boolean().optional()}),ej=ef.z.object({volumeType:ef.z.literal(eu.lf.Existing),refHash:eg,mountPath:ey,useLatest:ef.z.coerce.boolean(),isFake:ef.z.boolean().optional()}),eD=ef.z.object({volumeType:ef.z.literal(eu.lf.Persistent),name:ez,mountPath:ey,size:ef.z.number().gt(0),isFake:ef.z.boolean().optional()}),eF=ef.z.discriminatedUnion("volumeType",[eO,ej,eD]),eU=ef.z.array(eF),eq=eB.extend({ref:eM}),eZ=ef.z.array(eq),eG=ef.z.object({name:ez,value:ez}),eW=ef.z.array(eG),eK=ef.z.object({lang:ef.z.enum([eH.D.Python,eH.D.Node,eH.D.Other])}),e$=ef.z.discriminatedUnion("type",[eK.extend({type:ef.z.literal("file"),file:eN,entrypoint:ez}),eK.extend({type:ef.z.literal("text"),text:ez}),eK.extend({type:ef.z.literal("ref"),encoding:ef.z.enum([em.Encoding.squashfs,em.Encoding.zip,em.Encoding.plain]),programRef:eg,entrypoint:ez})]),eJ=ef.z.object({name:ez,tags:ef.z.array(ef.z.string().trim()).optional()}),eY=eE.extend({isSelected:ef.z.boolean(),isNew:ef.z.boolean()}),eX=ef.z.array(eY).refine(et=>et.some(et=>et.isSelected),{message:"At least one ssh key should be add and selected",path:["0.isSelected"]}),eQ=ef.z.coerce.boolean(),e1=eg,e2=ef.z.object({cpu:ef.z.union([ef.z.literal(1),ef.z.literal(2),ef.z.literal(4),ef.z.literal(6),ef.z.literal(8),ef.z.literal(12)]),ram:ef.z.number().gt(0),storage:ef.z.number().gt(0)}).refine(et=>{let{cpu:ei,ram:es}=et;return es===(0,ed.Fx)(2*ei,{from:"GiB",to:"MiB"})},{message:"Invalid specs"}).refine(et=>{let{cpu:ei,storage:es}=et;return es===(0,ed.Fx)(20*ei,{from:"GiB",to:"MiB"})||es===(0,ed.Fx)(2*ei,{from:"GiB",to:"MiB"})},{message:"Invalid specs"}),e4=eV(eg),e3=ef.z.object({code:e$,isPersistent:eQ,specs:e2,runtime:e4.optional(),volumes:eU.optional(),envVars:eW.optional(),domains:eZ.optional(),metadata:e_.optional()}).merge(eJ).refine(et=>{let{code:ei,runtime:es}=et;return!!es||ei.lang!==eH.D.Other},{message:"Invalid function runtime",path:["runtime"]}),e6=ef.z.object({image:e1,specs:e2,sshKeys:eX,volumes:eU.optional(),envVars:eW.optional(),domains:eZ.optional(),metadata:e_.optional()}).merge(eJ),e0=ez.regex(/^[0-9a-z-]+$/,{message:"Network id should be provided in kebab-case-format"}),e8=eb.includes("$ADDRESS",{message:'The url must contain the token "$ADDRESS" that will be replaced in runtime with token contract addresses'}),e5=ef.z.object({id:e0,blockchain:eA,rpcUrl:eb,abiUrl:eV(e8)}),e7=ef.z.array(e5),e9=ef.z.object({network:ez,contract:eC,deployer:eC,supply:ex,decimals:ef.z.number().gte(0)}),cc=ef.z.array(e9),ci=ef.z.object({networks:e7.min(1),accounts:cc.min(1)}).merge(eJ).superRefine(async(et,ei)=>{let{networks:es,accounts:eu}=et;for(let[et,ed]of Object.entries(eu)){let eu;let em=es.findIndex(et=>et.id===ed.network),eH=es[em];if(!eH)return ei.addIssue({fatal:!0,code:ef.z.ZodIssueCode.custom,message:"Invalid network. It should be one of the defined blockchain networks ids",path:["accounts.".concat(et,".network")]}),ef.z.NEVER;if(!ed.contract||!eH.abiUrl||!eH.abiUrl.includes("$ADDRESS"))return ef.z.NEVER;let ez=eH.abiUrl.replace("$ADDRESS",ed.contract),eV=await fetch(ez),eM=await eV.json();try{eu=JSON.parse(null==eM?void 0:eM.result)}catch(et){if(null==eM?void 0:eM.result.includes("rate limit"))return ef.z.NEVER}if(!eu)return ei.addIssue({fatal:!0,code:ef.z.ZodIssueCode.custom,message:"Invalid ABI url. It should return a valid ABI json inside response.body.result field",path:["networks.".concat(em,".abiUrl")]}),ef.z.NEVER}})},48847:function(et,ei,es){"use strict";es.d(ei,{MF:function(){return ef},E3:function(){return ex},I6:function(){return e_}});var ef,eu=es(61941),ed=es(59925),em=es(49875),eH=es(39261),ez=es(33358),eV=es(34853);class eM{async getAll(){let{address:et}=this.account,ei={address:et,total_size:0,files:[]};try{let es=await fetch("https://api2.aleph.im/api/v0/addresses/".concat(et,"/files")),ef=await es.json()||ei;return this.parseSizesMap(ef.files),ef}catch(et){return console.error(et),ei}}async getSizesMap(){let et=await this.mutex.acquire();try{this.lastFetch+6e4(et[ei.item_hash]=(0,eV.Fx)(ei.size,{from:"B",to:"MiB"}),et),{})}constructor(et,ei=ez.sT){this.account=et,this.channel=ei,this.sizesMapCache={},this.lastFetch=0,this.mutex=new eV.WU}}var eg=es(67572),eL=es(81287);class eb{async get(et){try{let ei=await eg.any.GetMessage({hash:et});return ei}catch(et){throw eL.Z.RequestFailed(et)}}async del(et){try{let ei=await eg.forget.Publish({account:this.account,hashes:[et.item_hash],channel:et.channel});return ei}catch(et){throw eL.Z.RequestFailed(et)}}constructor(et,ei=ez.sT){this.account=et,this.channel=ei}}var ey=es(65526),eC=es(21685);!function(et){et[et.connect=0]="connect",et[et.disconnect=1]="disconnect",et[et.setAccountBalance=2]="setAccountBalance",et[et.setAccountFiles=3]="setAccountFiles",et[et.setAccountSSHKeys=4]="setAccountSSHKeys",et[et.addAccountSSHKey=5]="addAccountSSHKey",et[et.delAccountSSHKey=6]="delAccountSSHKey",et[et.setAccountFunctions=7]="setAccountFunctions",et[et.addAccountFunction=8]="addAccountFunction",et[et.delAccountFunction=9]="delAccountFunction",et[et.setAccountVolumes=10]="setAccountVolumes",et[et.addAccountVolume=11]="addAccountVolume",et[et.delAccountVolume=12]="delAccountVolume",et[et.setAccountInstances=13]="setAccountInstances",et[et.addAccountInstance=14]="addAccountInstance",et[et.delAccountInstance=15]="delAccountInstance",et[et.setAccountDomains=16]="setAccountDomains",et[et.addAccountDomain=17]="addAccountDomain",et[et.delAccountDomain=18]="delAccountDomain"}(ef||(ef={}));let ex={account:void 0,accountBalance:void 0,accountInstances:void 0,accountFunctions:void 0,accountVolumes:void 0,accountFiles:void 0,accountSSHKeys:void 0,accountDomains:void 0,fileManager:void 0,messageManager:void 0,sshKeyManager:void 0,domainManager:void 0,volumeManager:void 0,programManager:void 0,instanceManager:void 0,indexerManager:void 0};function ew(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],es=new Map(ei.map(et=>[et.id,et]));for(let ei of et)es.set(ei.id,ei);return Array.from(es.values())}function eN(et,ei){return ew([et],ei)}function eS(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];return ei.filter(ei=>ei.id!==et)}function eA(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],es=ei.filter(et=>!et.confirmed);return ew(et,es)}let e_=function(){let et=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ex,{type:ei,payload:es}=arguments.length>1?arguments[1]:void 0;switch(ei){case ef.connect:{let{account:ei}=es,ef=new eM(ei),ez=new eb(ei),eV=new eu.X(ei),eg=new ey.Y(ei),eL=new ed.l(ei,ef),ex=new eH.L(ei,eL,eg,ez,ef),ew=new em.u(ei,eL,eg,eV,ef),eN=new eC.p(ei,ex);return{...et,account:ei,fileManager:ef,messageManager:ez,sshKeyManager:eV,domainManager:eg,volumeManager:eL,programManager:ex,instanceManager:ew,indexerManager:eN}}case ef.disconnect:return{...et,account:void 0,fileManager:void 0,messageManager:void 0,sshKeyManager:void 0,domainManager:void 0,volumeManager:void 0,programManager:void 0,instanceManager:void 0};case ef.setAccountBalance:return{...et,accountBalance:es.balance};case ef.setAccountFiles:return{...et,accountFiles:es.accountFiles};case ef.setAccountSSHKeys:{let ei=eA(es.accountSSHKeys,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.addAccountSSHKey:{let ei=eN(es.accountSSHKey,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.delAccountSSHKey:{let ei=eS(es.id,et.accountSSHKeys);return{...et,accountSSHKeys:ei}}case ef.setAccountFunctions:{let ei=eA(es.accountFunctions,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.addAccountFunction:{let ei=eN(es.accountFunction,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.delAccountFunction:{let ei=eS(es.id,et.accountFunctions);return{...et,accountFunctions:ei}}case ef.setAccountVolumes:{let ei=eA(es.accountVolumes,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.addAccountVolume:{let ei=eN(es.accountVolume,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.delAccountVolume:{let ei=eS(es.id,et.accountVolumes);return{...et,accountVolumes:ei}}case ef.setAccountInstances:{let ei=eA(es.accountInstances,et.accountInstances);return{...et,accountInstances:ei}}case ef.addAccountInstance:{let ei=eN(es.accountInstance,et.accountInstances);return{...et,accountInstances:ei}}case ef.delAccountInstance:{let ei=eS(es.id,et.accountInstances);return{...et,accountInstances:ei}}case ef.setAccountDomains:{let ei=eA(es.accountDomains,et.accountDomains);return{...et,accountDomains:ei}}case ef.addAccountDomain:{let ei=eN(es.accountDomain,et.accountDomains);return{...et,accountDomains:ei}}case ef.delAccountDomain:{let ei=eS(es.id,et.accountDomains);return{...et,accountDomains:ei}}default:return et}}},34853:function(et,ei,es){"use strict";es.d(ei,{D1:function(){return ej},DI:function(){return ex},Eb:function(){return ez},Fx:function(){return eL},Py:function(){return eT},RK:function(){return eC},WU:function(){return eR},_3:function(){return ew},bs:function(){return em},eB:function(){return ey},f6:function(){return eV},gE:function(){return eP},lm:function(){return eN},mA:function(){return eO},w2:function(){return eB},zN:function(){return eH}});var ef=es(81287),eu=es(57492),ed=es(33358);let em=function(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10,es=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return et.length<=ei||et.length<=es?et:"".concat(et.slice(0,ei),"...").concat(es>0?et.slice(-es):"")},eH=et=>em(et,6,4),ez=async et=>{try{let ei=await fetch("https://api2.aleph.im/api/v0/addresses/".concat(et,"/balance"));if(404===ei.status)return 0;let{balance:es}=await ei.json();return es}catch(et){throw ef.Z.RequestFailed(et)}},eV=async et=>{try{let ei=await fetch("https://balance1.api.aleph.cloud/solana/".concat(et)),{balance:es}=await ei.json();return es}catch(et){throw ef.Z.RequestFailed(et)}},eM={B:1,kB:1e3,MB:1e6,GB:1e9,TB:1e12,KiB:1024,MiB:1048576,GiB:1073741824,TiB:1099511627776},eg={B:"B",kB:"kB",MB:"MB",GB:"GB",TB:"TB",KiB:"kB",MiB:"MB",GiB:"GB",TiB:"TB"};function eL(et,ei){let{from:es="MiB",to:ef="GiB",displayUnit:eu=!1}=ei,ed=et*eM[es]/eM[ef];return eu?"".concat(ed.toFixed(2)," ").concat(eg[ef]):ed}function eb(et){let ei=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["B","KiB","MiB","GiB","TiB"],es="B";for(let ef of ei){if(et1&&void 0!==arguments[1]?arguments[1]:"B";if(void 0===et)return"n/a";if(0===et)return"-";let es=eL(et,{from:ei,to:"B"}),ef=eb(es);return eL(et,{from:ei,to:ef,displayUnit:!0})}let eC=et=>void 0===et?"n/a":0===et?et:et<1e3?et.toFixed(1):et<1e6?(et/1e3).toFixed(1)+"K":et<1e9?(et/1e6).toFixed(1)+"M":(et/1e9).toFixed(1)+"B",ex=et=>{let{item_hash:ei,chain:es,sender:ef,type:eu}=et;return"https://explorer.aleph.im/address/".concat(es,"/").concat(ef,"/message/").concat(eu,"/").concat(ei)},ew=et=>{let[ei,es]=new Date(1e3*et).toISOString().split("T"),[ef]=es.split(".");return"".concat(ei," ").concat(ef)},eN=(et,ei)=>{let es=document.createElement("a");es.href=window.URL.createObjectURL(et),es.download=ei,es.click()},eS=et=>et.type===eu.MessageType.store,eA=et=>et.type===eu.MessageType.program,e_=et=>et.type===eu.MessageType.instance,eE=et=>et.type===eu.MessageType.post;function eP(et){if(eS(et))return ed.py.Volume;if(eA(et))return ed.py.Program;if(e_(et))return ed.py.Instance;if(eE(et))return ed.py.SSHKey;throw Error("Unknown type")}function eB(et){return et.hasOwnProperty("persistence")}function eT(et){return et.hasOwnProperty("ephemeral")}class eI{constructor(){this.promise=new Promise((et,ei)=>{this.resolve=et,this.reject=ei})}}class eR{async acquire(){let et=new eI,ei=this.queue;return this.queue=this.queue.then(()=>et.promise),this.count++,await ei,()=>{this.count--,et.resolve()}}constructor(){this.queue=Promise.resolve(),this.count=0}}function eO(et){return et.trim().toLowerCase().replace(/[^a-z0-9_\\-]/g,"").replace(/_/g,"-")}function ej(et){return eO(et).replace(/-/g,"_")}},6477:function(et,ei,es){"use strict";es.d(ei,{$:function(){return eC}});var ef=es(36470),eu=es(57492),ed=es(24566),em=es(74931),eH=es(34853),ez=es(81287);let eV=(et,ei)=>{switch(et){case eu.Chain.ETH:return(0,ed.GetAccountFromProvider)(ei);case eu.Chain.SOL:return(0,em.GetAccountFromProvider)(ei);default:throw ez.Z.ChainNotYetSupported}},eM=async et=>{switch(et.GetChain()){case eu.Chain.ETH:return(0,eH.Eb)(et.address);case eu.Chain.SOL:return(0,eH.f6)(et.address);default:throw ez.Z.ChainNotYetSupported}};var eg=es(48847),eL=es(3837),eb=es(67294),ey=es(5678);function eC(){let[et,ei]=(0,ef.mr)(),es=(0,eL.lm)(),[ed,em]=(0,ey.Xs)("keepAccountAlive",!1),eH=(0,eb.useCallback)(et=>{es&&es.add({variant:"error",title:"Error",text:et})},[es]),ez=(0,eb.useCallback)(async et=>{let es=await eM(et);ei({type:eg.MF.setAccountBalance,payload:{balance:es}})},[ei]),eC=(0,eb.useCallback)(async()=>{let et;try{et=await eV(eu.Chain.ETH,null==window?void 0:window.ethereum)}catch(et){eH("You need an Ethereum wallet to use Aleph.im.")}if(et)return em(!0),await Promise.all([ez(et)]).catch(et=>{eH(et.message)}),ei({type:eg.MF.connect,payload:{account:et}}),et},[em,ez,ei,eH]),ex=(0,eb.useCallback)(async()=>{em(!1),ei({type:eg.MF.disconnect,payload:null})},[ei,em]),{account:ew}=et,eN=!!(null==ew?void 0:ew.address),eS=(0,eb.useCallback)(async()=>{!eN&&ed&&await eC()},[eN,ed,eC]);return{connect:eC,disconnect:ex,isConnected:eN,account:ew,tryReconnect:eS}}},32523:function(et,ei,es){"use strict";es.d(ei,{FH:function(){return ez},Fk:function(){return eH}});var ef=es(34853),eu=es(67294),ed=es(87536);function em(et,ei){return{...et,storage:(0,ef.Fx)(2*et.cpu*(ei?10:1),{from:"GiB",to:"MiB"})}}function eH(et){return[1,2,4,6,8,12].map(ei=>em({cpu:ei,ram:(0,ef.Fx)(2*ei,{from:"GiB",to:"MiB"}),storage:0},et))}function ez(et){let{name:ei="specs",control:es,defaultValue:ef,type:ez,options:eV,isPersistent:eM=!1}=et,eg=eV||eH(eM),eL=(0,ed.bc)({control:es,name:ei,defaultValue:ef}),{value:eb,onChange:ey}=eL.field;return(0,eu.useEffect)(()=>{if(!eb)return;let et=em(eb,eM);et.storage!==eb.storage&&ey(et)},[eM,eb,ey]),{specsCtrl:eL,options:eg,type:ez,isPersistent:eM}}},27234:function(et,ei,es){"use strict";es.r(ei),es.d(ei,{default:function(){return cd}});var ef=es(85893);es(69416);var eu=es(23636);es(53119);var ed=es(19521),em=es(3837),eH=es(67294),ez=es(87531);let eV=ed.ZP.footer.withConfig({displayName:"styles__StyledFooter",componentId:"sc-1l7mq5x-0"})([""," background-color:#00000033;box-sizing:border-box;width:100%;"],{paddingTop:"3rem",paddingBottom:"3rem","@media (min-width: 768px)":{paddingTop:"3rem",paddingBottom:"3rem"}}),eM=(0,ed.ZP)(em.zx).attrs(et=>({...et,kind:"neon",variant:"tertiary",color:"main0",size:"big"})).withConfig({displayName:"styles__StyledButton",componentId:"sc-1l7mq5x-1"})(()=>[{marginBottom:"1.5rem !important",display:"block !important",":last-child":{marginBottom:"0px !important"}}]),eg=ed.ZP.a.attrs(et=>({...(0,em.PT)("tp-nav")(et),href:et.href||"#"})).withConfig({displayName:"styles__StyledLink",componentId:"sc-1l7mq5x-2"})(["",""],et=>{let{theme:ei}=et;return(0,ed.iv)(["display:block;cursor:pointer;font-weight:700;white-space:nowrap;color:",";text-decoration:none;&:last-child{margin-bottom:0;}"],ei.color.text)}),eL=(0,ed.ZP)(em.JO).attrs(et=>({...et,size:"lg"})).withConfig({displayName:"styles__StyledIcon",componentId:"sc-1l7mq5x-3"})(()=>[{marginRight:"0.625rem"}]),eb=(0,ed.ZP)(em.JO).attrs(et=>({...et,size:"lg"})).withConfig({displayName:"styles__StyledIcon2",componentId:"sc-1l7mq5x-4"})(()=>[{marginLeft:"0.625rem"}]),ey=et=>{let{small:ei=!1}=et;return(0,ef.jsx)(eV,{children:(0,ef.jsx)(ez.Z,{children:ei?(0,ef.jsxs)(em.X2,{xs:1,md:2,lg:3,xsGap:"3rem",lgGap:"0",children:[(0,ef.jsx)(em.JX,{xs:1,md:2,lg:1,children:(0,ef.jsx)(ex,{children:(0,ef.jsx)(em.TR,{size:28})})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)(ew,{children:[(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://docs.aleph.im",children:["Documentation",(0,ef.jsx)(eb,{name:"external-link-square-alt"})]})}),(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://t.me/alephim",children:["Telegram Developers",(0,ef.jsx)(eb,{name:"external-link-square-alt"})]})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)(eN,{children:[(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://twitter.com/aleph_im",children:[(0,ef.jsx)(eL,{name:"twitter"}),"Twitter"]})}),(0,ef.jsx)("li",{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://medium.com/aleph-im",children:[(0,ef.jsx)(eL,{name:"medium"}),"Medium"]})})]})})]}):(0,ef.jsxs)(ef.Fragment,{children:[(0,ef.jsx)(eS,{children:(0,ef.jsx)(em.TR,{size:55})}),(0,ef.jsx)(eA,{children:(0,ef.jsxs)(em.X2,{xs:1,md:2,lg:4,xsGap:"3rem",mdGap:"1.5rem",children:[(0,ef.jsxs)(em.JX,{children:[(0,ef.jsx)(eM,{children:"Work with us"}),(0,ef.jsx)(eM,{children:"Try our dApps"}),(0,ef.jsx)(eM,{children:"Start a project"})]}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(e_,{children:(0,ef.jsx)(eg,{children:"Solutions"})}),(0,ef.jsx)(eE,{children:(0,ef.jsx)(eg,{children:"Roadmap"})}),(0,ef.jsx)(eP,{children:(0,ef.jsx)(eg,{children:"Indexing"})}),(0,ef.jsx)(eB,{children:(0,ef.jsx)(eg,{children:"Demo's"})}),(0,ef.jsx)(eT,{children:(0,ef.jsx)(eg,{children:"Team"})}),(0,ef.jsx)(eI,{children:(0,ef.jsx)(eg,{children:"Developers"})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(eR,{children:(0,ef.jsx)(eg,{children:"Jobs"})}),(0,ef.jsx)(eO,{children:(0,ef.jsx)(eg,{children:"Whitepaper"})}),(0,ef.jsx)(ej,{children:(0,ef.jsx)(eg,{children:"Token"})})]})}),(0,ef.jsx)(em.JX,{children:(0,ef.jsxs)("ul",{children:[(0,ef.jsx)(eD,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://twitter.com/aleph_im",children:[(0,ef.jsx)(eL,{name:"twitter"}),"Twitter"]})}),(0,ef.jsx)(eF,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://t.me/alephim",children:[(0,ef.jsx)(eL,{name:"telegram"}),"Telegram"]})}),(0,ef.jsx)(eU,{children:(0,ef.jsxs)(eg,{target:"_blank",href:"https://medium.com/aleph-im",children:[(0,ef.jsx)(eL,{name:"medium"}),"Medium"]})})]})})]})})]})})})};var eC=ey,ex=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv",componentId:"sc-1m9qt74-0"})({display:"flex",alignItems:"center","@media (min-width: 1024px)":{justifyContent:"flex-start"}}),ew=(0,ed.ZP)("ul").withConfig({displayName:"cmp___StyledUl",componentId:"sc-1m9qt74-1"})({display:"flex",flexDirection:"column",gap:"1.5rem","@media (min-width: 768px)":{flexDirection:"row",alignItems:"center"},"@media (min-width: 1024px)":{justifyContent:"center"}}),eN=(0,ed.ZP)("ul").withConfig({displayName:"cmp___StyledUl2",componentId:"sc-1m9qt74-2"})({display:"flex",alignItems:"center",gap:"1.5rem","@media (min-width: 768px)":{justifyContent:"flex-end"}}),eS=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv2",componentId:"sc-1m9qt74-3"})({marginBottom:"3rem"}),eA=(0,ed.ZP)("nav").withConfig({displayName:"cmp___StyledNav",componentId:"sc-1m9qt74-4"})({margin:"0px"}),e_=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi",componentId:"sc-1m9qt74-5"})({marginBottom:"1.5rem"}),eE=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi2",componentId:"sc-1m9qt74-6"})({marginBottom:"1.5rem"}),eP=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi3",componentId:"sc-1m9qt74-7"})({marginBottom:"1.5rem"}),eB=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi4",componentId:"sc-1m9qt74-8"})({marginBottom:"1.5rem"}),eT=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi5",componentId:"sc-1m9qt74-9"})({marginBottom:"1.5rem"}),eI=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi6",componentId:"sc-1m9qt74-10"})({marginBottom:"0px"}),eR=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi7",componentId:"sc-1m9qt74-11"})({marginBottom:"1.5rem"}),eO=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi8",componentId:"sc-1m9qt74-12"})({marginBottom:"1.5rem"}),ej=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi9",componentId:"sc-1m9qt74-13"})({marginBottom:"0px"}),eD=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi10",componentId:"sc-1m9qt74-14"})({marginBottom:"1.5rem"}),eF=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi11",componentId:"sc-1m9qt74-15"})({marginBottom:"1.5rem"}),eU=(0,ed.ZP)("li").withConfig({displayName:"cmp___StyledLi12",componentId:"sc-1m9qt74-16"})({marginBottom:"0px"});let eq=(0,ed.vJ)([" body,#__next{display:flex;flex-direction:column;min-height:100vh;}.unavailable-content{opacity:0.3;filter:grayscale(1);pointer-events:none;}textarea{width:100%;background:linear-gradient(to bottom,#FFFFFF33,transparent);border-radius:5px;padding:5px;border:1px solid #FFFFFF33;color:inherit;}table{max-width:100%;overflow:auto;}"]);var eZ=es(41664),eG=es.n(eZ);let eW=ed.ZP.header.withConfig({displayName:"styles__StyledHeader",componentId:"sc-1uc7qj0-0"})(["font-size:inherit;line-height:inherit;box-sizing:border-box;width:100%;margin:0;position:sticky;top:0;z-index:10;"]),eK=(0,ed.ZP)(em.wp).withConfig({displayName:"styles__StyledNavbar",componentId:"sc-1uc7qj0-1"})(["position:relative;"]),e$=(0,ed.ZP)(em.zx).attrs(et=>({...et,color:"main0",kind:"neon",size:"regular",variant:"tertiary"})).withConfig({displayName:"styles__StyledButton",componentId:"sc-1uc7qj0-2"})(["display:block;&:last-child{margin-bottom:0;}"]);var eJ=es(34853),eY=es(11163),eX=es(36470),eQ=es(6477),e1=es(5678);function e2(){let{connect:et,disconnect:ei,isConnected:es,account:ef}=(0,eQ.$)(),eu=(0,ed.Fg)(),[ez]=(0,eX.mr)(),eV=(0,eY.useRouter)(),[eM,eg]=(0,e1.Xs)("keepAccountAlive",!1);(0,eH.useEffect)(()=>{(async()=>{!ef&&eM&&eC()})()},[ef,eM]);let eL=et=>eV.pathname===et,{accountBalance:eb}=ez,ey=(0,eH.useCallback)(async()=>{if(es)eg(!1),await ei(),eV.push("/");else{eg(!0);let ei=await et();if(!ei)return;eV.push("/dashboard")}ew(!1)},[et,ei,es,eV]),eC=(0,eH.useCallback)(async()=>{if(es)await ei();else{let ei=await et();if(!ei)return}},[et,ei,es,ef]),[ex,ew]=(0,eH.useState)(!1),eN=(0,eH.useRef)(null);(0,em.O8)(()=>{ex&&ew(!1)},[eN]);let eS=()=>{ew(!ex)},eA=()=>{var ei;return null===(ei=window.ethereum)||void 0===ei||ei.on("accountsChanged",function(){et()}),window.ethereum};(0,eH.useEffect)(()=>(eA(),()=>{var ei;null===(ei=window.ethereum)||void 0===ei||ei.removeListener("accountsChanged",()=>{et()})}),[]);let[e_,eE]=(0,eH.useState)(!1),eP=(0,eH.useCallback)(et=>{eE(et)},[]),eB=(0,eH.useCallback)(()=>{eE(!1)},[eE]);return{theme:eu,account:ef,displayWalletPicker:ex,accountBalance:eb,divRef:eN,isOpen:e_,isOnPath:eL,handleToggleOpen:eP,handleConnect:ey,handleDisplayWalletPicker:eS,handleCloseMenu:eB,provider:eA}}let e4=()=>{let{theme:et,account:ei,displayWalletPicker:es,accountBalance:eu,isOpen:ed,divRef:eH,isOnPath:ez,handleToggleOpen:eV,handleCloseMenu:eM,handleConnect:eg,handleDisplayWalletPicker:eL,provider:eb}=e2();return(0,ef.jsx)(eW,{children:(0,ef.jsxs)(eK,{open:ed,onToggle:eV,logo:(0,ef.jsx)(eG(),{href:"/",children:(0,ef.jsx)(em.TR,{})}),mobileTopContent:ei?(0,ef.jsx)(em.zx,{variant:"secondary",color:"main1",kind:"neon",size:"regular",children:(0,ef.jsx)(em.JO,{name:"meteor",size:"md",color:et.color.main1})}):(0,ef.jsx)(e$,{onClick:eg,children:(0,ef.jsx)(em.JO,{name:"meteor",size:"md",color:et.color.main0})}),children:[(0,ef.jsxs)(em.o8,{withSlash:!0,onClick:eM,children:[(0,ef.jsx)(em.iV,{isActive:ez("/"),children:(0,ef.jsx)(eG(),{href:"/",children:"Solutions"},"solutions")}),(0,ef.jsx)(em.iV,{isActive:ez("/dashboard"),children:(0,ef.jsx)(eG(),{href:"/dashboard",children:"Dashboard"},"dashboard")})]}),(0,ef.jsxs)(em.o8,{onlyDesktop:!0,children:[(0,ef.jsx)(em.iV,{children:(0,ef.jsx)(e$,{forwardedAs:"button",disabled:!0,children:(0,ef.jsx)(em.JO,{name:"ethereum"})},"link")}),(0,ef.jsx)(e6,{children:(0,ef.jsxs)(em.iV,{children:[ei?(0,ef.jsxs)(em.zx,{as:"button",variant:"secondary",color:"main1",kind:"neon",size:"regular",onClick:eL,children:[(0,eJ.zN)(ei.address)," ",(0,ef.jsx)(e0,{name:"meteor",size:"lg",color:et.color.main1})]}):(0,ef.jsxs)(em.zx,{as:"button",variant:"tertiary",color:"main0",kind:"neon",size:"regular",onClick:eL,children:["Connect"," ",(0,ef.jsx)(e8,{name:"meteor",size:"lg",color:et.color.main0})]}),(0,ef.jsx)(e5,{ref:eH,children:es&&(0,ef.jsx)(em.nd,{networks:[{icon:"ethereum",name:"Ethereum",wallets:[{color:"orange",icon:"circle",name:"Metamask",provider:eb}]}],onConnect:eg,onDisconnect:eg,address:null==ei?void 0:ei.address,addressHref:"https://etherscan.io/address/".concat(null==ei?void 0:ei.address),balance:eu,size:"regular"})})]})})]})]})})};var e3=e4,e6=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv",componentId:"sc-m0h8p1-0"})({position:"relative"}),e0=(0,ed.ZP)(em.JO).withConfig({displayName:"cmp___StyledIcon",componentId:"sc-m0h8p1-1"})({marginLeft:"0.625rem"}),e8=(0,ed.ZP)(em.JO).withConfig({displayName:"cmp___StyledIcon2",componentId:"sc-m0h8p1-2"})({marginLeft:"0.625rem"}),e5=(0,ed.ZP)("div").withConfig({displayName:"cmp___StyledDiv2",componentId:"sc-m0h8p1-3"})({position:"absolute",right:"0px",marginTop:"2.5rem"});function e7(et){let{children:ei}=et,[es,eu]=(0,eH.useState)(!0);return(0,eH.useEffect)(()=>eu(!1),[]),es?(0,ef.jsx)(ef.Fragment,{children:ei}):(0,ef.jsx)(em.P_,{max:10,timeout:2e3,children:ei})}var e9=es(36001),cc=es(33358);let ci=ed.ZP.main.withConfig({displayName:"styles__StyledMain",componentId:"sc-4lx0v5-0"})(["",""],{display:"flex",flex:"1 1 0%",flexDirection:"column"}),cs=et=>{let{children:ei}=et;return(0,ef.jsx)(ci,{children:ei})};var cf=cs;function cd(et){let{Component:ei,pageProps:es}=et,eu=(0,eY.useRouter)(),eH="/dashboard/manage"!==eu.pathname;return(0,ef.jsxs)(ed.f6,{theme:em.np.dark,children:[(0,ef.jsx)(em.nz,{}),(0,ef.jsx)(eq,{}),(0,ef.jsx)(eX.WE,{children:(0,ef.jsxs)(e7,{children:[(0,ef.jsx)(e3,{}),(0,ef.jsxs)(cf,{children:[eH&&(0,ef.jsx)(e9.Z,{names:cc.sv}),(0,ef.jsx)(ei,{...es})]}),(0,ef.jsx)(eC,{small:!0})]})})]})}eu.vc.autoAddCss=!1},81516:function(et,ei){"use strict";function es(et,ei,es,ef){return!1}Object.defineProperty(ei,"__esModule",{value:!0}),ei.getDomainLocale=es,("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},95569:function(et,ei,es){"use strict";Object.defineProperty(ei,"__esModule",{value:!0}),ei.default=void 0;var ef=es(92648).Z,eu=es(17273).Z,ed=ef(es(67294)),em=es(14532),eH=es(83353),ez=es(61410),eV=es(79064),eM=es(370),eg=es(69955),eL=es(24224),eb=es(80508),ey=es(81516),eC=es(64266);let ex=new Set;function ew(et,ei,es,ef,eu){if(eu||eH.isLocalURL(ei)){if(!ef.bypassPrefetchedCheck){let eu=void 0!==ef.locale?ef.locale:"locale"in et?et.locale:void 0,ed=ei+"%"+es+"%"+eu;if(ex.has(ed))return;ex.add(ed)}Promise.resolve(et.prefetch(ei,es,ef)).catch(et=>{})}}function eN(et){let ei=et.currentTarget,es=ei.getAttribute("target");return es&&"_self"!==es||et.metaKey||et.ctrlKey||et.shiftKey||et.altKey||et.nativeEvent&&2===et.nativeEvent.which}function eS(et,ei,es,ef,eu,em,ez,eV,eM,eg){let{nodeName:eL}=et.currentTarget,eb="A"===eL.toUpperCase();if(eb&&(eN(et)||!eM&&!eH.isLocalURL(es)))return;et.preventDefault();let ey=()=>{"beforePopState"in ei?ei[eu?"replace":"push"](es,ef,{shallow:em,locale:eV,scroll:ez}):ei[eu?"replace":"push"](ef||es,{forceOptimisticNavigation:!eg})};eM?ed.default.startTransition(ey):ey()}function eA(et){return"string"==typeof et?et:ez.formatUrl(et)}let e_=ed.default.forwardRef(function(et,ei){let es,ef;let{href:eH,as:ez,children:ex,prefetch:eN,passHref:e_,replace:eE,shallow:eP,scroll:eB,locale:eT,onClick:eI,onMouseEnter:eR,onTouchStart:eO,legacyBehavior:ej=!1}=et,eD=eu(et,["href","as","children","prefetch","passHref","replace","shallow","scroll","locale","onClick","onMouseEnter","onTouchStart","legacyBehavior"]);es=ex,ej&&("string"==typeof es||"number"==typeof es)&&(es=ed.default.createElement("a",null,es));let eF=!1!==eN,eU=ed.default.useContext(eg.RouterContext),eq=ed.default.useContext(eL.AppRouterContext),eZ=null!=eU?eU:eq,eG=!eU,{href:eW,as:eK}=ed.default.useMemo(()=>{if(!eU){let et=eA(eH);return{href:et,as:ez?eA(ez):et}}let[et,ei]=em.resolveHref(eU,eH,!0);return{href:et,as:ez?em.resolveHref(eU,ez):ei||et}},[eU,eH,ez]),e$=ed.default.useRef(eW),eJ=ed.default.useRef(eK);ej&&(ef=ed.default.Children.only(es));let eY=ej?ef&&"object"==typeof ef&&ef.ref:ei,[eX,eQ,e1]=eb.useIntersection({rootMargin:"200px"}),e2=ed.default.useCallback(et=>{(eJ.current!==eK||e$.current!==eW)&&(e1(),eJ.current=eK,e$.current=eW),eX(et),eY&&("function"==typeof eY?eY(et):"object"==typeof eY&&(eY.current=et))},[eK,eY,eW,e1,eX]);ed.default.useEffect(()=>{eZ&&eQ&&eF&&ew(eZ,eW,eK,{locale:eT},eG)},[eK,eW,eQ,eT,eF,null==eU?void 0:eU.locale,eZ,eG]);let e4={ref:e2,onClick(et){ej||"function"!=typeof eI||eI(et),ej&&ef.props&&"function"==typeof ef.props.onClick&&ef.props.onClick(et),eZ&&!et.defaultPrevented&&eS(et,eZ,eW,eK,eE,eP,eB,eT,eG,eF)},onMouseEnter(et){ej||"function"!=typeof eR||eR(et),ej&&ef.props&&"function"==typeof ef.props.onMouseEnter&&ef.props.onMouseEnter(et),eZ&&(eF||!eG)&&ew(eZ,eW,eK,{locale:eT,priority:!0,bypassPrefetchedCheck:!0},eG)},onTouchStart(et){ej||"function"!=typeof eO||eO(et),ej&&ef.props&&"function"==typeof ef.props.onTouchStart&&ef.props.onTouchStart(et),eZ&&(eF||!eG)&&ew(eZ,eW,eK,{locale:eT,priority:!0,bypassPrefetchedCheck:!0},eG)}};if(eV.isAbsoluteUrl(eK))e4.href=eK;else if(!ej||e_||"a"===ef.type&&!("href"in ef.props)){let et=void 0!==eT?eT:null==eU?void 0:eU.locale,ei=(null==eU?void 0:eU.isLocaleDomain)&&ey.getDomainLocale(eK,et,null==eU?void 0:eU.locales,null==eU?void 0:eU.domainLocales);e4.href=ei||eC.addBasePath(eM.addLocale(eK,et,null==eU?void 0:eU.defaultLocale))}return ej?ed.default.cloneElement(ef,e4):ed.default.createElement("a",Object.assign({},eD,e4),es)});var eE=e_;ei.default=eE,("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},80508:function(et,ei,es){"use strict";Object.defineProperty(ei,"__esModule",{value:!0}),ei.useIntersection=eM;var ef=es(67294),eu=es(10029);let ed="function"==typeof IntersectionObserver,em=new Map,eH=[];function ez(et){let ei;let es={root:et.root||null,margin:et.rootMargin||""},ef=eH.find(et=>et.root===es.root&&et.margin===es.margin);if(ef&&(ei=em.get(ef)))return ei;let eu=new Map,ed=new IntersectionObserver(et=>{et.forEach(et=>{let ei=eu.get(et.target),es=et.isIntersecting||et.intersectionRatio>0;ei&&es&&ei(es)})},et);return ei={id:es,observer:ed,elements:eu},eH.push(es),em.set(es,ei),ei}function eV(et,ei,es){let{id:ef,observer:eu,elements:ed}=ez(es);return ed.set(et,ei),eu.observe(et),function(){if(ed.delete(et),eu.unobserve(et),0===ed.size){eu.disconnect(),em.delete(ef);let et=eH.findIndex(et=>et.root===ef.root&&et.margin===ef.margin);et>-1&&eH.splice(et,1)}}}function eM(et){let{rootRef:ei,rootMargin:es,disabled:em}=et,eH=em||!ed,[ez,eM]=ef.useState(!1),eg=ef.useRef(null),eL=ef.useCallback(et=>{eg.current=et},[]);ef.useEffect(()=>{if(ed){if(eH||ez)return;let et=eg.current;if(et&&et.tagName){let ef=eV(et,et=>et&&eM(et),{root:null==ei?void 0:ei.current,rootMargin:es});return ef}}else if(!ez){let et=eu.requestIdleCallback(()=>eM(!0));return()=>eu.cancelIdleCallback(et)}},[eH,es,ei,ez,eg.current]);let eb=ef.useCallback(()=>{eM(!1)},[]);return[eL,ez,eb]}("function"==typeof ei.default||"object"==typeof ei.default&&null!==ei.default)&&void 0===ei.default.__esModule&&(Object.defineProperty(ei.default,"__esModule",{value:!0}),Object.assign(ei.default,ei),et.exports=ei.default)},42474:function(et,ei,es){var ef="/",eu=es(48764).Buffer,ed=es(83454);!function(){var ei={7160:function(et,ei,es){var ef=ei;ef.bignum=es(711),ef.define=es(495).define,ef.base=es(853),ef.constants=es(7335),ef.decoders=es(6701),ef.encoders=es(3418)},495:function(et,ei,es){var ef=es(7160),eu=es(3782);function ed(et,ei){this.name=et,this.body=ei,this.decoders={},this.encoders={}}ei.define=function(et,ei){return new ed(et,ei)},ed.prototype._createNamed=function(et){var ei;try{ei=es(6144).runInThisContext("(function "+this.name+"(entity) {\n this._initNamed(entity);\n})")}catch(et){ei=function(et){this._initNamed(et)}}return eu(ei,et),ei.prototype._initNamed=function(ei){et.call(this,ei)},new ei(this)},ed.prototype._getDecoder=function(et){return et=et||"der",this.decoders.hasOwnProperty(et)||(this.decoders[et]=this._createNamed(ef.decoders[et])),this.decoders[et]},ed.prototype.decode=function(et,ei,es){return this._getDecoder(ei).decode(et,es)},ed.prototype._getEncoder=function(et){return et=et||"der",this.encoders.hasOwnProperty(et)||(this.encoders[et]=this._createNamed(ef.encoders[et])),this.encoders[et]},ed.prototype.encode=function(et,ei,es){return this._getEncoder(ei).encode(et,es)}},6483:function(et,ei,es){var ef=es(3782),eu=es(853).Reporter,ed=es(4300).Buffer;function em(et,ei){if(eu.call(this,ei),!ed.isBuffer(et)){this.error("Input not Buffer");return}this.base=et,this.offset=0,this.length=et.length}function eH(et,ei){if(Array.isArray(et))this.length=0,this.value=et.map(function(et){return et instanceof eH||(et=new eH(et,ei)),this.length+=et.length,et},this);else if("number"==typeof et){if(!(0<=et&&et<=255))return ei.error("non-byte EncoderBuffer value");this.value=et,this.length=1}else if("string"==typeof et)this.value=et,this.length=ed.byteLength(et);else{if(!ed.isBuffer(et))return ei.error("Unsupported type: "+typeof et);this.value=et,this.length=et.length}}ef(em,eu),ei.C=em,em.prototype.save=function(){return{offset:this.offset,reporter:eu.prototype.save.call(this)}},em.prototype.restore=function(et){var ei=new em(this.base);return ei.offset=et.offset,ei.length=this.offset,this.offset=et.offset,eu.prototype.restore.call(this,et.reporter),ei},em.prototype.isEmpty=function(){return this.offset===this.length},em.prototype.readUInt8=function(et){return this.offset+1<=this.length?this.base.readUInt8(this.offset++,!0):this.error(et||"DecoderBuffer overrun")},em.prototype.skip=function(et,ei){if(!(this.offset+et<=this.length))return this.error(ei||"DecoderBuffer overrun");var es=new em(this.base);return es._reporterState=this._reporterState,es.offset=this.offset,es.length=this.offset+et,this.offset+=et,es},em.prototype.raw=function(et){return this.base.slice(et?et.offset:this.offset,this.length)},ei.R=eH,eH.prototype.join=function(et,ei){return et||(et=new ed(this.length)),ei||(ei=0),0===this.length||(Array.isArray(this.value)?this.value.forEach(function(es){es.join(et,ei),ei+=es.length}):("number"==typeof this.value?et[ei]=this.value:"string"==typeof this.value?et.write(this.value,ei):ed.isBuffer(this.value)&&this.value.copy(et,ei),ei+=this.length)),et}},853:function(et,ei,es){var ef=ei;ef.Reporter=es(1293).b,ef.DecoderBuffer=es(6483).C,ef.EncoderBuffer=es(6483).R,ef.Node=es(9374)},9374:function(et,ei,es){var ef=es(853).Reporter,eu=es(853).EncoderBuffer,ed=es(853).DecoderBuffer,em=es(3523),eH=["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"],ez=["key","obj","use","optional","explicit","implicit","def","choice","any","contains"].concat(eH),eV=["_peekTag","_decodeTag","_use","_decodeStr","_decodeObjid","_decodeTime","_decodeNull","_decodeInt","_decodeBool","_decodeList","_encodeComposite","_encodeStr","_encodeObjid","_encodeTime","_encodeNull","_encodeInt","_encodeBool"];function eM(et,ei){var es={};this._baseState=es,es.enc=et,es.parent=ei||null,es.children=null,es.tag=null,es.args=null,es.reverseArgs=null,es.choice=null,es.optional=!1,es.any=!1,es.obj=!1,es.use=null,es.useDecoder=null,es.key=null,es.default=null,es.explicit=null,es.implicit=null,es.contains=null,es.parent||(es.children=[],this._wrap())}et.exports=eM;var eg=["enc","parent","children","tag","args","reverseArgs","choice","optional","any","obj","use","alteredUse","key","default","explicit","implicit","contains"];eM.prototype.clone=function(){var et=this._baseState,ei={};eg.forEach(function(es){ei[es]=et[es]});var es=new this.constructor(ei.parent);return es._baseState=ei,es},eM.prototype._wrap=function(){var et=this._baseState;ez.forEach(function(ei){this[ei]=function(){var es=new this.constructor(this);return et.children.push(es),es[ei].apply(es,arguments)}},this)},eM.prototype._init=function(et){var ei=this._baseState;em(null===ei.parent),et.call(this),ei.children=ei.children.filter(function(et){return et._baseState.parent===this},this),em.equal(ei.children.length,1,"Root node can have only one child")},eM.prototype._useArgs=function(et){var ei=this._baseState,es=et.filter(function(et){return et instanceof this.constructor},this);et=et.filter(function(et){return!(et instanceof this.constructor)},this),0!==es.length&&(em(null===ei.children),ei.children=es,es.forEach(function(et){et._baseState.parent=this},this)),0!==et.length&&(em(null===ei.args),ei.args=et,ei.reverseArgs=et.map(function(et){if("object"!=typeof et||et.constructor!==Object)return et;var ei={};return Object.keys(et).forEach(function(es){es==(0|es)&&(es|=0),ei[et[es]]=es}),ei}))},eV.forEach(function(et){eM.prototype[et]=function(){throw Error(et+" not implemented for encoding: "+this._baseState.enc)}}),eH.forEach(function(et){eM.prototype[et]=function(){var ei=this._baseState,es=Array.prototype.slice.call(arguments);return em(null===ei.tag),ei.tag=et,this._useArgs(es),this}}),eM.prototype.use=function(et){em(et);var ei=this._baseState;return em(null===ei.use),ei.use=et,this},eM.prototype.optional=function(){return this._baseState.optional=!0,this},eM.prototype.def=function(et){var ei=this._baseState;return em(null===ei.default),ei.default=et,ei.optional=!0,this},eM.prototype.explicit=function(et){var ei=this._baseState;return em(null===ei.explicit&&null===ei.implicit),ei.explicit=et,this},eM.prototype.implicit=function(et){var ei=this._baseState;return em(null===ei.explicit&&null===ei.implicit),ei.implicit=et,this},eM.prototype.obj=function(){var et=this._baseState,ei=Array.prototype.slice.call(arguments);return et.obj=!0,0!==ei.length&&this._useArgs(ei),this},eM.prototype.key=function(et){var ei=this._baseState;return em(null===ei.key),ei.key=et,this},eM.prototype.any=function(){return this._baseState.any=!0,this},eM.prototype.choice=function(et){var ei=this._baseState;return em(null===ei.choice),ei.choice=et,this._useArgs(Object.keys(et).map(function(ei){return et[ei]})),this},eM.prototype.contains=function(et){var ei=this._baseState;return em(null===ei.use),ei.contains=et,this},eM.prototype._decode=function(et,ei){var es,ef=this._baseState;if(null===ef.parent)return et.wrapResult(ef.children[0]._decode(et,ei));var eu=ef.default,em=!0,eH=null;if(null!==ef.key&&(eH=et.enterKey(ef.key)),ef.optional){var ez=null;if(null!==ef.explicit?ez=ef.explicit:null!==ef.implicit?ez=ef.implicit:null!==ef.tag&&(ez=ef.tag),null!==ez||ef.any){if(em=this._peekTag(et,ez,ef.any),et.isError(em))return em}else{var eV=et.save();try{null===ef.choice?this._decodeGeneric(ef.tag,et,ei):this._decodeChoice(et,ei),em=!0}catch(et){em=!1}et.restore(eV)}}if(ef.obj&&em&&(es=et.enterObject()),em){if(null!==ef.explicit){var eM=this._decodeTag(et,ef.explicit);if(et.isError(eM))return eM;et=eM}var eg=et.offset;if(null===ef.use&&null===ef.choice){if(ef.any)var eV=et.save();var eL=this._decodeTag(et,null!==ef.implicit?ef.implicit:ef.tag,ef.any);if(et.isError(eL))return eL;ef.any?eu=et.raw(eV):et=eL}if(ei&&ei.track&&null!==ef.tag&&ei.track(et.path(),eg,et.length,"tagged"),ei&&ei.track&&null!==ef.tag&&ei.track(et.path(),et.offset,et.length,"content"),ef.any||(eu=null===ef.choice?this._decodeGeneric(ef.tag,et,ei):this._decodeChoice(et,ei)),et.isError(eu))return eu;if(ef.any||null!==ef.choice||null===ef.children||ef.children.forEach(function(es){es._decode(et,ei)}),ef.contains&&("octstr"===ef.tag||"bitstr"===ef.tag)){var eb=new ed(eu);eu=this._getUse(ef.contains,et._reporterState.obj)._decode(eb,ei)}}return ef.obj&&em&&(eu=et.leaveObject(es)),null!==ef.key&&(null!==eu||!0===em)?et.leaveKey(eH,ef.key,eu):null!==eH&&et.exitKey(eH),eu},eM.prototype._decodeGeneric=function(et,ei,es){var ef=this._baseState;if("seq"===et||"set"===et)return null;if("seqof"===et||"setof"===et)return this._decodeList(ei,et,ef.args[0],es);if(/str$/.test(et))return this._decodeStr(ei,et,es);if("objid"===et&&ef.args)return this._decodeObjid(ei,ef.args[0],ef.args[1],es);if("objid"===et)return this._decodeObjid(ei,null,null,es);if("gentime"===et||"utctime"===et)return this._decodeTime(ei,et,es);if("null_"===et)return this._decodeNull(ei,es);if("bool"===et)return this._decodeBool(ei,es);else if("objDesc"===et)return this._decodeStr(ei,et,es);else if("int"===et||"enum"===et)return this._decodeInt(ei,ef.args&&ef.args[0],es);return null!==ef.use?this._getUse(ef.use,ei._reporterState.obj)._decode(ei,es):ei.error("unknown tag: "+et)},eM.prototype._getUse=function(et,ei){var es=this._baseState;return es.useDecoder=this._use(et,ei),em(null===es.useDecoder._baseState.parent),es.useDecoder=es.useDecoder._baseState.children[0],es.implicit!==es.useDecoder._baseState.implicit&&(es.useDecoder=es.useDecoder.clone(),es.useDecoder._baseState.implicit=es.implicit),es.useDecoder},eM.prototype._decodeChoice=function(et,ei){var es=this._baseState,ef=null,eu=!1;return(Object.keys(es.choice).some(function(ed){var em=et.save(),eH=es.choice[ed];try{var ez=eH._decode(et,ei);if(et.isError(ez))return!1;ef={type:ed,value:ez},eu=!0}catch(ei){return et.restore(em),!1}return!0},this),eu)?ef:et.error("Choice not matched")},eM.prototype._createEncoderBuffer=function(et){return new eu(et,this.reporter)},eM.prototype._encode=function(et,ei,es){var ef=this._baseState;if(null===ef.default||ef.default!==et){var eu=this._encodeValue(et,ei,es);if(void 0!==eu&&!this._skipDefault(eu,ei,es))return eu}},eM.prototype._encodeValue=function(et,ei,es){var eu,ed=this._baseState;if(null===ed.parent)return ed.children[0]._encode(et,ei||new ef);var eu=null;if(this.reporter=ei,ed.optional&&void 0===et){if(null===ed.default)return;et=ed.default}var em=null,eH=!1;if(ed.any)eu=this._createEncoderBuffer(et);else if(ed.choice)eu=this._encodeChoice(et,ei);else if(ed.contains)em=this._getUse(ed.contains,es)._encode(et,ei),eH=!0;else if(ed.children)em=ed.children.map(function(es){if("null_"===es._baseState.tag)return es._encode(null,ei,et);if(null===es._baseState.key)return ei.error("Child should have a key");var ef=ei.enterKey(es._baseState.key);if("object"!=typeof et)return ei.error("Child expected, but input is not object");var eu=es._encode(et[es._baseState.key],ei,et);return ei.leaveKey(ef),eu},this).filter(function(et){return et}),em=this._createEncoderBuffer(em);else if("seqof"===ed.tag||"setof"===ed.tag){if(!(ed.args&&1===ed.args.length))return ei.error("Too many args for : "+ed.tag);if(!Array.isArray(et))return ei.error("seqof/setof, but data is not Array");var ez=this.clone();ez._baseState.implicit=null,em=this._createEncoderBuffer(et.map(function(es){var ef=this._baseState;return this._getUse(ef.args[0],et)._encode(es,ei)},ez))}else null!==ed.use?eu=this._getUse(ed.use,es)._encode(et,ei):(em=this._encodePrimitive(ed.tag,et),eH=!0);if(!ed.any&&null===ed.choice){var eV=null!==ed.implicit?ed.implicit:ed.tag,eM=null===ed.implicit?"universal":"context";null===eV?null===ed.use&&ei.error("Tag could be omitted only for .use()"):null===ed.use&&(eu=this._encodeComposite(eV,eH,eM,em))}return null!==ed.explicit&&(eu=this._encodeComposite(ed.explicit,!1,"context",eu)),eu},eM.prototype._encodeChoice=function(et,ei){var es=this._baseState,ef=es.choice[et.type];return ef||em(!1,et.type+" not found in "+JSON.stringify(Object.keys(es.choice))),ef._encode(et.value,ei)},eM.prototype._encodePrimitive=function(et,ei){var es=this._baseState;if(/str$/.test(et))return this._encodeStr(ei,et);if("objid"===et&&es.args)return this._encodeObjid(ei,es.reverseArgs[0],es.args[1]);if("objid"===et)return this._encodeObjid(ei,null,null);if("gentime"===et||"utctime"===et)return this._encodeTime(ei,et);if("null_"===et)return this._encodeNull();if("int"===et||"enum"===et)return this._encodeInt(ei,es.args&&es.reverseArgs[0]);if("bool"===et)return this._encodeBool(ei);else if("objDesc"===et)return this._encodeStr(ei,et);else throw Error("Unsupported tag: "+et)},eM.prototype._isNumstr=function(et){return/^[0-9 ]*$/.test(et)},eM.prototype._isPrintstr=function(et){return/^[A-Za-z0-9 '\(\)\+,\-\.\/:=\?]*$/.test(et)}},1293:function(et,ei,es){var ef=es(3782);function eu(et){this._reporterState={obj:null,path:[],options:et||{},errors:[]}}function ed(et,ei){this.path=et,this.rethrow(ei)}ei.b=eu,eu.prototype.isError=function(et){return et instanceof ed},eu.prototype.save=function(){var et=this._reporterState;return{obj:et.obj,pathLen:et.path.length}},eu.prototype.restore=function(et){var ei=this._reporterState;ei.obj=et.obj,ei.path=ei.path.slice(0,et.pathLen)},eu.prototype.enterKey=function(et){return this._reporterState.path.push(et)},eu.prototype.exitKey=function(et){var ei=this._reporterState;ei.path=ei.path.slice(0,et-1)},eu.prototype.leaveKey=function(et,ei,es){var ef=this._reporterState;this.exitKey(et),null!==ef.obj&&(ef.obj[ei]=es)},eu.prototype.path=function(){return this._reporterState.path.join("/")},eu.prototype.enterObject=function(){var et=this._reporterState,ei=et.obj;return et.obj={},ei},eu.prototype.leaveObject=function(et){var ei=this._reporterState,es=ei.obj;return ei.obj=et,es},eu.prototype.error=function(et){var ei,es=this._reporterState,ef=et instanceof ed;if(ei=ef?et:new ed(es.path.map(function(et){return"["+JSON.stringify(et)+"]"}).join(""),et.message||et,et.stack),!es.options.partial)throw ei;return ef||es.errors.push(ei),ei},eu.prototype.wrapResult=function(et){var ei=this._reporterState;return ei.options.partial?{result:this.isError(et)?null:et,errors:ei.errors}:et},ef(ed,Error),ed.prototype.rethrow=function(et){if(this.message=et+" at: "+(this.path||"(shallow)"),Error.captureStackTrace&&Error.captureStackTrace(this,ed),!this.stack)try{throw Error(this.message)}catch(et){this.stack=et.stack}return this}},9791:function(et,ei,es){var ef=es(7335);ei.tagClass={0:"universal",1:"application",2:"context",3:"private"},ei.tagClassByName=ef._reverse(ei.tagClass),ei.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"},ei.tagByName=ef._reverse(ei.tag)},7335:function(et,ei,es){var ef=ei;ef._reverse=function(et){var ei={};return Object.keys(et).forEach(function(es){(0|es)==es&&(es|=0),ei[et[es]]=es}),ei},ef.der=es(9791)},2259:function(et,ei,es){var ef=es(3782),eu=es(7160),ed=eu.base,em=eu.bignum,eH=eu.constants.der;function ez(et){this.enc="der",this.name=et.name,this.entity=et,this.tree=new eV,this.tree._init(et.body)}function eV(et){ed.Node.call(this,"der",et)}function eM(et,ei){var es=et.readUInt8(ei);if(et.isError(es))return es;var ef=eH.tagClass[es>>6],eu=(32&es)==0;if((31&es)==31){var ed=es;for(es=0;(128&ed)==128;){if(ed=et.readUInt8(ei),et.isError(ed))return ed;es<<=7,es|=127&ed}}else es&=31;var em=eH.tag[es];return{cls:ef,primitive:eu,tag:es,tagStr:em}}function eg(et,ei,es){var ef=et.readUInt8(es);if(et.isError(ef))return ef;if(!ei&&128===ef)return null;if((128&ef)==0)return ef;var eu=127&ef;if(eu>4)return et.error("length octect is too long");ef=0;for(var ed=0;ed=31?ef.error("Multi-octet tag encoding unsupported"):(ei||(eu|=32),eu|=eH.tagClassByName[es||"universal"]<<6)}et.exports=ez,ez.prototype.encode=function(et,ei){return this.tree._encode(et,ei).join()},ef(eV,em.Node),eV.prototype._encodeComposite=function(et,ei,es,ef){var ed=eg(et,ei,es,this.reporter);if(ef.length<128){var em=new eu(2);return em[0]=ed,em[1]=ef.length,this._createEncoderBuffer([em,ef])}for(var eH=1,ez=ef.length;ez>=256;ez>>=8)eH++;var em=new eu(2+eH);em[0]=ed,em[1]=128|eH;for(var ez=1+eH,eV=ef.length;eV>0;ez--,eV>>=8)em[ez]=255&eV;return this._createEncoderBuffer([em,ef])},eV.prototype._encodeStr=function(et,ei){if("bitstr"===ei)return this._createEncoderBuffer([0|et.unused,et.data]);if("bmpstr"===ei){for(var es=new eu(2*et.length),ef=0;ef=40)return this.reporter.error("Second objid identifier OOB");et.splice(0,2,40*et[0]+et[1])}for(var ed=0,ef=0;ef=128;em>>=7)ed++}for(var eH=new eu(ed),ez=eH.length-1,ef=et.length-1;ef>=0;ef--){var em=et[ef];for(eH[ez--]=127&em;(em>>=7)>0;)eH[ez--]=128|127&em}return this._createEncoderBuffer(eH)},eV.prototype._encodeTime=function(et,ei){var es,ef=new Date(et);return"gentime"===ei?es=[eM(ef.getFullYear()),eM(ef.getUTCMonth()+1),eM(ef.getUTCDate()),eM(ef.getUTCHours()),eM(ef.getUTCMinutes()),eM(ef.getUTCSeconds()),"Z"].join(""):"utctime"===ei?es=[eM(ef.getFullYear()%100),eM(ef.getUTCMonth()+1),eM(ef.getUTCDate()),eM(ef.getUTCHours()),eM(ef.getUTCMinutes()),eM(ef.getUTCSeconds()),"Z"].join(""):this.reporter.error("Encoding "+ei+" time is not supported yet"),this._encodeStr(es,"octstr")},eV.prototype._encodeNull=function(){return this._createEncoderBuffer("")},eV.prototype._encodeInt=function(et,ei){if("string"==typeof et){if(!ei)return this.reporter.error("String int or enum given, but no values map");if(!ei.hasOwnProperty(et))return this.reporter.error("Values map doesn't contain: "+JSON.stringify(et));et=ei[et]}if("number"!=typeof et&&!eu.isBuffer(et)){var es=et.toArray();!et.sign&&128&es[0]&&es.unshift(0),et=new eu(es)}if(eu.isBuffer(et)){var ef=et.length;0===et.length&&ef++;var ed=new eu(ef);return et.copy(ed),0===et.length&&(ed[0]=0),this._createEncoderBuffer(ed)}if(et<128)return this._createEncoderBuffer(et);if(et<256)return this._createEncoderBuffer([0,et]);for(var ef=1,em=et;em>=256;em>>=8)ef++;for(var ed=Array(ef),em=ed.length-1;em>=0;em--)ed[em]=255&et,et>>=8;return 128&ed[0]&&ed.unshift(0),this._createEncoderBuffer(new eu(ed))},eV.prototype._encodeBool=function(et){return this._createEncoderBuffer(et?255:0)},eV.prototype._use=function(et,ei){return"function"==typeof et&&(et=et(ei)),et._getEncoder("der").tree},eV.prototype._skipDefault=function(et,ei,es){var ef,eu=this._baseState;if(null===eu.default)return!1;var ed=et.join();if(void 0===eu.defaultBuffer&&(eu.defaultBuffer=this._encodeValue(eu.default,ei,es).join()),ed.length!==eu.defaultBuffer.length)return!1;for(ef=0;ef=49&&em<=54?ef|=em-49+10:em>=17&&em<=22?ef|=em-17+10:ef|=15&em}return ef}function eH(et,ei,es,ef){for(var eu=0,ed=Math.min(et.length,es),em=ei;em=49?eu+=eH-49+10:eH>=17?eu+=eH-17+10:eu+=eH}return eu}ed.isBN=function(et){return et instanceof ed||null!==et&&"object"==typeof et&&et.constructor.wordSize===ed.wordSize&&Array.isArray(et.words)},ed.max=function(et,ei){return et.cmp(ei)>0?et:ei},ed.min=function(et,ei){return 0>et.cmp(ei)?et:ei},ed.prototype._init=function(et,ei,es){if("number"==typeof et)return this._initNumber(et,ei,es);if("object"==typeof et)return this._initArray(et,ei,es);"hex"===ei&&(ei=16),ef(ei===(0|ei)&&ei>=2&&ei<=36);var eu=0;"-"===(et=et.toString().replace(/\s+/g,""))[0]&&eu++,16===ei?this._parseHex(et,eu):this._parseBase(et,ei,eu),"-"===et[0]&&(this.negative=1),this.strip(),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initNumber=function(et,ei,es){et<0&&(this.negative=1,et=-et),et<67108864?(this.words=[67108863&et],this.length=1):et<4503599627370496?(this.words=[67108863&et,et/67108864&67108863],this.length=2):(ef(et<9007199254740992),this.words=[67108863&et,et/67108864&67108863,1],this.length=3),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initArray=function(et,ei,es){if(ef("number"==typeof et.length),et.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(et.length/3),this.words=Array(this.length);for(var eu,ed,em=0;em=0;em-=3)ed=et[em]|et[em-1]<<8|et[em-2]<<16,this.words[eu]|=ed<>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);else if("le"===es)for(em=0,eu=0;em>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);return this.strip()},ed.prototype._parseHex=function(et,ei){this.length=Math.ceil((et.length-ei)/6),this.words=Array(this.length);for(var es,ef,eu=0;eu=ei;eu-=6)ef=em(et,eu,eu+6),this.words[es]|=ef<>>26-ed&4194303,(ed+=24)>=26&&(ed-=26,es++);eu+6!==ei&&(ef=em(et,ei,eu+6),this.words[es]|=ef<>>26-ed&4194303),this.strip()},ed.prototype._parseBase=function(et,ei,es){this.words=[0],this.length=1;for(var ef=0,eu=1;eu<=67108863;eu*=ei)ef++;ef--,eu=eu/ei|0;for(var ed=et.length-es,em=ed%ef,ez=Math.min(ed,ed-em)+es,eV=0,eM=es;eM1&&0===this.words[this.length-1];)this.length--;return this._normSign()},ed.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},ed.prototype.inspect=function(){return(this.red?""};var ez,eV=["","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"],eM=[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],eg=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];function eL(et){for(var ei=Array(et.bitLength()),es=0;es>>eu}return ei}function eb(et,ei,es){es.negative=ei.negative^et.negative;var ef=et.length+ei.length|0;es.length=ef,ef=ef-1|0;var eu=0|et.words[0],ed=0|ei.words[0],em=eu*ed,eH=67108863&em,ez=em/67108864|0;es.words[0]=eH;for(var eV=1;eV>>26,eg=67108863&ez,eL=Math.min(eV,ei.length-1),eb=Math.max(0,eV-et.length+1);eb<=eL;eb++){var ey=eV-eb|0;eM+=(em=(eu=0|et.words[ey])*(ed=0|ei.words[eb])+eg)/67108864|0,eg=67108863&em}es.words[eV]=0|eg,ez=0|eM}return 0!==ez?es.words[eV]=0|ez:es.length--,es.strip()}ed.prototype.toString=function(et,ei){if(ei=0|ei||1,16===(et=et||10)||"hex"===et){es="";for(var es,eu=0,ed=0,em=0;em>>24-eu&16777215)||em!==this.length-1?eV[6-ez.length]+ez+es:ez+es,(eu+=2)>=26&&(eu-=26,em--)}for(0!==ed&&(es=ed.toString(16)+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}if(et===(0|et)&&et>=2&&et<=36){var eL=eM[et],eb=eg[et];es="";var ey=this.clone();for(ey.negative=0;!ey.isZero();){var eC=ey.modn(eb).toString(et);es=(ey=ey.idivn(eb)).isZero()?eC+es:eV[eL-eC.length]+eC+es}for(this.isZero()&&(es="0"+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}ef(!1,"Base should be between 2 and 36")},ed.prototype.toNumber=function(){var et=this.words[0];return 2===this.length?et+=67108864*this.words[1]:3===this.length&&1===this.words[2]?et+=4503599627370496+67108864*this.words[1]:this.length>2&&ef(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-et:et},ed.prototype.toJSON=function(){return this.toString(16)},ed.prototype.toBuffer=function(et,ei){return ef(void 0!==ez),this.toArrayLike(ez,et,ei)},ed.prototype.toArray=function(et,ei){return this.toArrayLike(Array,et,ei)},ed.prototype.toArrayLike=function(et,ei,es){var eu,ed,em=this.byteLength(),eH=es||Math.max(1,em);ef(em<=eH,"byte array longer than desired length"),ef(eH>0,"Requested array length <= 0"),this.strip();var ez="le"===ei,eV=new et(eH),eM=this.clone();if(ez){for(ed=0;!eM.isZero();ed++)eu=eM.andln(255),eM.iushrn(8),eV[ed]=eu;for(;ed=4096&&(es+=13,ei>>>=13),ei>=64&&(es+=7,ei>>>=7),ei>=8&&(es+=4,ei>>>=4),ei>=2&&(es+=2,ei>>>=2),es+ei},ed.prototype._zeroBits=function(et){if(0===et)return 26;var ei=et,es=0;return(8191&ei)==0&&(es+=13,ei>>>=13),(127&ei)==0&&(es+=7,ei>>>=7),(15&ei)==0&&(es+=4,ei>>>=4),(3&ei)==0&&(es+=2,ei>>>=2),(1&ei)==0&&es++,es},ed.prototype.bitLength=function(){var et=this.words[this.length-1],ei=this._countBits(et);return(this.length-1)*26+ei},ed.prototype.zeroBits=function(){if(this.isZero())return 0;for(var et=0,ei=0;eiet.length?this.clone().ior(et):et.clone().ior(this)},ed.prototype.uor=function(et){return this.length>et.length?this.clone().iuor(et):et.clone().iuor(this)},ed.prototype.iuand=function(et){var ei;ei=this.length>et.length?et:this;for(var es=0;eset.length?this.clone().iand(et):et.clone().iand(this)},ed.prototype.uand=function(et){return this.length>et.length?this.clone().iuand(et):et.clone().iuand(this)},ed.prototype.iuxor=function(et){this.length>et.length?(ei=this,es=et):(ei=et,es=this);for(var ei,es,ef=0;efet.length?this.clone().ixor(et):et.clone().ixor(this)},ed.prototype.uxor=function(et){return this.length>et.length?this.clone().iuxor(et):et.clone().iuxor(this)},ed.prototype.inotn=function(et){ef("number"==typeof et&&et>=0);var ei=0|Math.ceil(et/26),es=et%26;this._expand(ei),es>0&&ei--;for(var eu=0;eu0&&(this.words[eu]=~this.words[eu]&67108863>>26-es),this.strip()},ed.prototype.notn=function(et){return this.clone().inotn(et)},ed.prototype.setn=function(et,ei){ef("number"==typeof et&&et>=0);var es=et/26|0,eu=et%26;return this._expand(es+1),ei?this.words[es]=this.words[es]|1<et.length?(es=this,ef=et):(es=et,ef=this);for(var ei,es,ef,eu=0,ed=0;ed>>26;for(;0!==eu&&ed>>26;if(this.length=es.length,0!==eu)this.words[this.length]=eu,this.length++;else if(es!==this)for(;edet.length?this.clone().iadd(et):et.clone().iadd(this)},ed.prototype.isub=function(et){if(0!==et.negative){et.negative=0;var ei,es,ef=this.iadd(et);return et.negative=1,ef._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(et),this.negative=1,this._normSign();var eu=this.cmp(et);if(0===eu)return this.negative=0,this.length=1,this.words[0]=0,this;eu>0?(ei=this,es=et):(ei=et,es=this);for(var ed=0,em=0;em>26,this.words[em]=67108863&ef;for(;0!==ed&&em>26,this.words[em]=67108863&ef;if(0===ed&&em>>13,eb=0|em[1],ey=8191&eb,eC=eb>>>13,ex=0|em[2],ew=8191&ex,eN=ex>>>13,eS=0|em[3],eA=8191&eS,e_=eS>>>13,eE=0|em[4],eP=8191&eE,eB=eE>>>13,eT=0|em[5],eI=8191&eT,eR=eT>>>13,eO=0|em[6],ej=8191&eO,eD=eO>>>13,eF=0|em[7],eU=8191&eF,eq=eF>>>13,eZ=0|em[8],eG=8191&eZ,eW=eZ>>>13,eK=0|em[9],e$=8191&eK,eJ=eK>>>13,eY=0|eH[0],eX=8191&eY,eQ=eY>>>13,e1=0|eH[1],e2=8191&e1,e4=e1>>>13,e3=0|eH[2],e6=8191&e3,e0=e3>>>13,e8=0|eH[3],e5=8191&e8,e7=e8>>>13,e9=0|eH[4],cc=8191&e9,ci=e9>>>13,cs=0|eH[5],cf=8191&cs,cd=cs>>>13,cm=0|eH[6],cH=8191&cm,cz=cm>>>13,cV=0|eH[7],cM=8191&cV,cg=cV>>>13,cL=0|eH[8],cy=8191&cL,cC=cL>>>13,cx=0|eH[9],cw=8191&cx,ck=cx>>>13;es.negative=et.negative^ei.negative,es.length=19;var cN=(eV+(ef=Math.imul(eg,eX))|0)+((8191&(eu=(eu=Math.imul(eg,eQ))+Math.imul(eL,eX)|0))<<13)|0;eV=((ed=Math.imul(eL,eQ))+(eu>>>13)|0)+(cN>>>26)|0,cN&=67108863,ef=Math.imul(ey,eX),eu=(eu=Math.imul(ey,eQ))+Math.imul(eC,eX)|0,ed=Math.imul(eC,eQ);var cS=(eV+(ef=ef+Math.imul(eg,e2)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e4)|0)+Math.imul(eL,e2)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e4)|0)+(eu>>>13)|0)+(cS>>>26)|0,cS&=67108863,ef=Math.imul(ew,eX),eu=(eu=Math.imul(ew,eQ))+Math.imul(eN,eX)|0,ed=Math.imul(eN,eQ),ef=ef+Math.imul(ey,e2)|0,eu=(eu=eu+Math.imul(ey,e4)|0)+Math.imul(eC,e2)|0,ed=ed+Math.imul(eC,e4)|0;var cA=(eV+(ef=ef+Math.imul(eg,e6)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e0)|0)+Math.imul(eL,e6)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e0)|0)+(eu>>>13)|0)+(cA>>>26)|0,cA&=67108863,ef=Math.imul(eA,eX),eu=(eu=Math.imul(eA,eQ))+Math.imul(e_,eX)|0,ed=Math.imul(e_,eQ),ef=ef+Math.imul(ew,e2)|0,eu=(eu=eu+Math.imul(ew,e4)|0)+Math.imul(eN,e2)|0,ed=ed+Math.imul(eN,e4)|0,ef=ef+Math.imul(ey,e6)|0,eu=(eu=eu+Math.imul(ey,e0)|0)+Math.imul(eC,e6)|0,ed=ed+Math.imul(eC,e0)|0;var c_=(eV+(ef=ef+Math.imul(eg,e5)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e7)|0)+Math.imul(eL,e5)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e7)|0)+(eu>>>13)|0)+(c_>>>26)|0,c_&=67108863,ef=Math.imul(eP,eX),eu=(eu=Math.imul(eP,eQ))+Math.imul(eB,eX)|0,ed=Math.imul(eB,eQ),ef=ef+Math.imul(eA,e2)|0,eu=(eu=eu+Math.imul(eA,e4)|0)+Math.imul(e_,e2)|0,ed=ed+Math.imul(e_,e4)|0,ef=ef+Math.imul(ew,e6)|0,eu=(eu=eu+Math.imul(ew,e0)|0)+Math.imul(eN,e6)|0,ed=ed+Math.imul(eN,e0)|0,ef=ef+Math.imul(ey,e5)|0,eu=(eu=eu+Math.imul(ey,e7)|0)+Math.imul(eC,e5)|0,ed=ed+Math.imul(eC,e7)|0;var cE=(eV+(ef=ef+Math.imul(eg,cc)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ci)|0)+Math.imul(eL,cc)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ci)|0)+(eu>>>13)|0)+(cE>>>26)|0,cE&=67108863,ef=Math.imul(eI,eX),eu=(eu=Math.imul(eI,eQ))+Math.imul(eR,eX)|0,ed=Math.imul(eR,eQ),ef=ef+Math.imul(eP,e2)|0,eu=(eu=eu+Math.imul(eP,e4)|0)+Math.imul(eB,e2)|0,ed=ed+Math.imul(eB,e4)|0,ef=ef+Math.imul(eA,e6)|0,eu=(eu=eu+Math.imul(eA,e0)|0)+Math.imul(e_,e6)|0,ed=ed+Math.imul(e_,e0)|0,ef=ef+Math.imul(ew,e5)|0,eu=(eu=eu+Math.imul(ew,e7)|0)+Math.imul(eN,e5)|0,ed=ed+Math.imul(eN,e7)|0,ef=ef+Math.imul(ey,cc)|0,eu=(eu=eu+Math.imul(ey,ci)|0)+Math.imul(eC,cc)|0,ed=ed+Math.imul(eC,ci)|0;var cP=(eV+(ef=ef+Math.imul(eg,cf)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cd)|0)+Math.imul(eL,cf)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cd)|0)+(eu>>>13)|0)+(cP>>>26)|0,cP&=67108863,ef=Math.imul(ej,eX),eu=(eu=Math.imul(ej,eQ))+Math.imul(eD,eX)|0,ed=Math.imul(eD,eQ),ef=ef+Math.imul(eI,e2)|0,eu=(eu=eu+Math.imul(eI,e4)|0)+Math.imul(eR,e2)|0,ed=ed+Math.imul(eR,e4)|0,ef=ef+Math.imul(eP,e6)|0,eu=(eu=eu+Math.imul(eP,e0)|0)+Math.imul(eB,e6)|0,ed=ed+Math.imul(eB,e0)|0,ef=ef+Math.imul(eA,e5)|0,eu=(eu=eu+Math.imul(eA,e7)|0)+Math.imul(e_,e5)|0,ed=ed+Math.imul(e_,e7)|0,ef=ef+Math.imul(ew,cc)|0,eu=(eu=eu+Math.imul(ew,ci)|0)+Math.imul(eN,cc)|0,ed=ed+Math.imul(eN,ci)|0,ef=ef+Math.imul(ey,cf)|0,eu=(eu=eu+Math.imul(ey,cd)|0)+Math.imul(eC,cf)|0,ed=ed+Math.imul(eC,cd)|0;var cB=(eV+(ef=ef+Math.imul(eg,cH)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cz)|0)+Math.imul(eL,cH)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cz)|0)+(eu>>>13)|0)+(cB>>>26)|0,cB&=67108863,ef=Math.imul(eU,eX),eu=(eu=Math.imul(eU,eQ))+Math.imul(eq,eX)|0,ed=Math.imul(eq,eQ),ef=ef+Math.imul(ej,e2)|0,eu=(eu=eu+Math.imul(ej,e4)|0)+Math.imul(eD,e2)|0,ed=ed+Math.imul(eD,e4)|0,ef=ef+Math.imul(eI,e6)|0,eu=(eu=eu+Math.imul(eI,e0)|0)+Math.imul(eR,e6)|0,ed=ed+Math.imul(eR,e0)|0,ef=ef+Math.imul(eP,e5)|0,eu=(eu=eu+Math.imul(eP,e7)|0)+Math.imul(eB,e5)|0,ed=ed+Math.imul(eB,e7)|0,ef=ef+Math.imul(eA,cc)|0,eu=(eu=eu+Math.imul(eA,ci)|0)+Math.imul(e_,cc)|0,ed=ed+Math.imul(e_,ci)|0,ef=ef+Math.imul(ew,cf)|0,eu=(eu=eu+Math.imul(ew,cd)|0)+Math.imul(eN,cf)|0,ed=ed+Math.imul(eN,cd)|0,ef=ef+Math.imul(ey,cH)|0,eu=(eu=eu+Math.imul(ey,cz)|0)+Math.imul(eC,cH)|0,ed=ed+Math.imul(eC,cz)|0;var cT=(eV+(ef=ef+Math.imul(eg,cM)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cg)|0)+Math.imul(eL,cM)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cg)|0)+(eu>>>13)|0)+(cT>>>26)|0,cT&=67108863,ef=Math.imul(eG,eX),eu=(eu=Math.imul(eG,eQ))+Math.imul(eW,eX)|0,ed=Math.imul(eW,eQ),ef=ef+Math.imul(eU,e2)|0,eu=(eu=eu+Math.imul(eU,e4)|0)+Math.imul(eq,e2)|0,ed=ed+Math.imul(eq,e4)|0,ef=ef+Math.imul(ej,e6)|0,eu=(eu=eu+Math.imul(ej,e0)|0)+Math.imul(eD,e6)|0,ed=ed+Math.imul(eD,e0)|0,ef=ef+Math.imul(eI,e5)|0,eu=(eu=eu+Math.imul(eI,e7)|0)+Math.imul(eR,e5)|0,ed=ed+Math.imul(eR,e7)|0,ef=ef+Math.imul(eP,cc)|0,eu=(eu=eu+Math.imul(eP,ci)|0)+Math.imul(eB,cc)|0,ed=ed+Math.imul(eB,ci)|0,ef=ef+Math.imul(eA,cf)|0,eu=(eu=eu+Math.imul(eA,cd)|0)+Math.imul(e_,cf)|0,ed=ed+Math.imul(e_,cd)|0,ef=ef+Math.imul(ew,cH)|0,eu=(eu=eu+Math.imul(ew,cz)|0)+Math.imul(eN,cH)|0,ed=ed+Math.imul(eN,cz)|0,ef=ef+Math.imul(ey,cM)|0,eu=(eu=eu+Math.imul(ey,cg)|0)+Math.imul(eC,cM)|0,ed=ed+Math.imul(eC,cg)|0;var cI=(eV+(ef=ef+Math.imul(eg,cy)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cC)|0)+Math.imul(eL,cy)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cC)|0)+(eu>>>13)|0)+(cI>>>26)|0,cI&=67108863,ef=Math.imul(e$,eX),eu=(eu=Math.imul(e$,eQ))+Math.imul(eJ,eX)|0,ed=Math.imul(eJ,eQ),ef=ef+Math.imul(eG,e2)|0,eu=(eu=eu+Math.imul(eG,e4)|0)+Math.imul(eW,e2)|0,ed=ed+Math.imul(eW,e4)|0,ef=ef+Math.imul(eU,e6)|0,eu=(eu=eu+Math.imul(eU,e0)|0)+Math.imul(eq,e6)|0,ed=ed+Math.imul(eq,e0)|0,ef=ef+Math.imul(ej,e5)|0,eu=(eu=eu+Math.imul(ej,e7)|0)+Math.imul(eD,e5)|0,ed=ed+Math.imul(eD,e7)|0,ef=ef+Math.imul(eI,cc)|0,eu=(eu=eu+Math.imul(eI,ci)|0)+Math.imul(eR,cc)|0,ed=ed+Math.imul(eR,ci)|0,ef=ef+Math.imul(eP,cf)|0,eu=(eu=eu+Math.imul(eP,cd)|0)+Math.imul(eB,cf)|0,ed=ed+Math.imul(eB,cd)|0,ef=ef+Math.imul(eA,cH)|0,eu=(eu=eu+Math.imul(eA,cz)|0)+Math.imul(e_,cH)|0,ed=ed+Math.imul(e_,cz)|0,ef=ef+Math.imul(ew,cM)|0,eu=(eu=eu+Math.imul(ew,cg)|0)+Math.imul(eN,cM)|0,ed=ed+Math.imul(eN,cg)|0,ef=ef+Math.imul(ey,cy)|0,eu=(eu=eu+Math.imul(ey,cC)|0)+Math.imul(eC,cy)|0,ed=ed+Math.imul(eC,cC)|0;var cR=(eV+(ef=ef+Math.imul(eg,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ck)|0)+Math.imul(eL,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ck)|0)+(eu>>>13)|0)+(cR>>>26)|0,cR&=67108863,ef=Math.imul(e$,e2),eu=(eu=Math.imul(e$,e4))+Math.imul(eJ,e2)|0,ed=Math.imul(eJ,e4),ef=ef+Math.imul(eG,e6)|0,eu=(eu=eu+Math.imul(eG,e0)|0)+Math.imul(eW,e6)|0,ed=ed+Math.imul(eW,e0)|0,ef=ef+Math.imul(eU,e5)|0,eu=(eu=eu+Math.imul(eU,e7)|0)+Math.imul(eq,e5)|0,ed=ed+Math.imul(eq,e7)|0,ef=ef+Math.imul(ej,cc)|0,eu=(eu=eu+Math.imul(ej,ci)|0)+Math.imul(eD,cc)|0,ed=ed+Math.imul(eD,ci)|0,ef=ef+Math.imul(eI,cf)|0,eu=(eu=eu+Math.imul(eI,cd)|0)+Math.imul(eR,cf)|0,ed=ed+Math.imul(eR,cd)|0,ef=ef+Math.imul(eP,cH)|0,eu=(eu=eu+Math.imul(eP,cz)|0)+Math.imul(eB,cH)|0,ed=ed+Math.imul(eB,cz)|0,ef=ef+Math.imul(eA,cM)|0,eu=(eu=eu+Math.imul(eA,cg)|0)+Math.imul(e_,cM)|0,ed=ed+Math.imul(e_,cg)|0,ef=ef+Math.imul(ew,cy)|0,eu=(eu=eu+Math.imul(ew,cC)|0)+Math.imul(eN,cy)|0,ed=ed+Math.imul(eN,cC)|0;var cO=(eV+(ef=ef+Math.imul(ey,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ey,ck)|0)+Math.imul(eC,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eC,ck)|0)+(eu>>>13)|0)+(cO>>>26)|0,cO&=67108863,ef=Math.imul(e$,e6),eu=(eu=Math.imul(e$,e0))+Math.imul(eJ,e6)|0,ed=Math.imul(eJ,e0),ef=ef+Math.imul(eG,e5)|0,eu=(eu=eu+Math.imul(eG,e7)|0)+Math.imul(eW,e5)|0,ed=ed+Math.imul(eW,e7)|0,ef=ef+Math.imul(eU,cc)|0,eu=(eu=eu+Math.imul(eU,ci)|0)+Math.imul(eq,cc)|0,ed=ed+Math.imul(eq,ci)|0,ef=ef+Math.imul(ej,cf)|0,eu=(eu=eu+Math.imul(ej,cd)|0)+Math.imul(eD,cf)|0,ed=ed+Math.imul(eD,cd)|0,ef=ef+Math.imul(eI,cH)|0,eu=(eu=eu+Math.imul(eI,cz)|0)+Math.imul(eR,cH)|0,ed=ed+Math.imul(eR,cz)|0,ef=ef+Math.imul(eP,cM)|0,eu=(eu=eu+Math.imul(eP,cg)|0)+Math.imul(eB,cM)|0,ed=ed+Math.imul(eB,cg)|0,ef=ef+Math.imul(eA,cy)|0,eu=(eu=eu+Math.imul(eA,cC)|0)+Math.imul(e_,cy)|0,ed=ed+Math.imul(e_,cC)|0;var cj=(eV+(ef=ef+Math.imul(ew,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ew,ck)|0)+Math.imul(eN,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eN,ck)|0)+(eu>>>13)|0)+(cj>>>26)|0,cj&=67108863,ef=Math.imul(e$,e5),eu=(eu=Math.imul(e$,e7))+Math.imul(eJ,e5)|0,ed=Math.imul(eJ,e7),ef=ef+Math.imul(eG,cc)|0,eu=(eu=eu+Math.imul(eG,ci)|0)+Math.imul(eW,cc)|0,ed=ed+Math.imul(eW,ci)|0,ef=ef+Math.imul(eU,cf)|0,eu=(eu=eu+Math.imul(eU,cd)|0)+Math.imul(eq,cf)|0,ed=ed+Math.imul(eq,cd)|0,ef=ef+Math.imul(ej,cH)|0,eu=(eu=eu+Math.imul(ej,cz)|0)+Math.imul(eD,cH)|0,ed=ed+Math.imul(eD,cz)|0,ef=ef+Math.imul(eI,cM)|0,eu=(eu=eu+Math.imul(eI,cg)|0)+Math.imul(eR,cM)|0,ed=ed+Math.imul(eR,cg)|0,ef=ef+Math.imul(eP,cy)|0,eu=(eu=eu+Math.imul(eP,cC)|0)+Math.imul(eB,cy)|0,ed=ed+Math.imul(eB,cC)|0;var cD=(eV+(ef=ef+Math.imul(eA,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eA,ck)|0)+Math.imul(e_,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(e_,ck)|0)+(eu>>>13)|0)+(cD>>>26)|0,cD&=67108863,ef=Math.imul(e$,cc),eu=(eu=Math.imul(e$,ci))+Math.imul(eJ,cc)|0,ed=Math.imul(eJ,ci),ef=ef+Math.imul(eG,cf)|0,eu=(eu=eu+Math.imul(eG,cd)|0)+Math.imul(eW,cf)|0,ed=ed+Math.imul(eW,cd)|0,ef=ef+Math.imul(eU,cH)|0,eu=(eu=eu+Math.imul(eU,cz)|0)+Math.imul(eq,cH)|0,ed=ed+Math.imul(eq,cz)|0,ef=ef+Math.imul(ej,cM)|0,eu=(eu=eu+Math.imul(ej,cg)|0)+Math.imul(eD,cM)|0,ed=ed+Math.imul(eD,cg)|0,ef=ef+Math.imul(eI,cy)|0,eu=(eu=eu+Math.imul(eI,cC)|0)+Math.imul(eR,cy)|0,ed=ed+Math.imul(eR,cC)|0;var cF=(eV+(ef=ef+Math.imul(eP,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eP,ck)|0)+Math.imul(eB,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eB,ck)|0)+(eu>>>13)|0)+(cF>>>26)|0,cF&=67108863,ef=Math.imul(e$,cf),eu=(eu=Math.imul(e$,cd))+Math.imul(eJ,cf)|0,ed=Math.imul(eJ,cd),ef=ef+Math.imul(eG,cH)|0,eu=(eu=eu+Math.imul(eG,cz)|0)+Math.imul(eW,cH)|0,ed=ed+Math.imul(eW,cz)|0,ef=ef+Math.imul(eU,cM)|0,eu=(eu=eu+Math.imul(eU,cg)|0)+Math.imul(eq,cM)|0,ed=ed+Math.imul(eq,cg)|0,ef=ef+Math.imul(ej,cy)|0,eu=(eu=eu+Math.imul(ej,cC)|0)+Math.imul(eD,cy)|0,ed=ed+Math.imul(eD,cC)|0;var cU=(eV+(ef=ef+Math.imul(eI,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eI,ck)|0)+Math.imul(eR,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eR,ck)|0)+(eu>>>13)|0)+(cU>>>26)|0,cU&=67108863,ef=Math.imul(e$,cH),eu=(eu=Math.imul(e$,cz))+Math.imul(eJ,cH)|0,ed=Math.imul(eJ,cz),ef=ef+Math.imul(eG,cM)|0,eu=(eu=eu+Math.imul(eG,cg)|0)+Math.imul(eW,cM)|0,ed=ed+Math.imul(eW,cg)|0,ef=ef+Math.imul(eU,cy)|0,eu=(eu=eu+Math.imul(eU,cC)|0)+Math.imul(eq,cy)|0,ed=ed+Math.imul(eq,cC)|0;var cq=(eV+(ef=ef+Math.imul(ej,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ej,ck)|0)+Math.imul(eD,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eD,ck)|0)+(eu>>>13)|0)+(cq>>>26)|0,cq&=67108863,ef=Math.imul(e$,cM),eu=(eu=Math.imul(e$,cg))+Math.imul(eJ,cM)|0,ed=Math.imul(eJ,cg),ef=ef+Math.imul(eG,cy)|0,eu=(eu=eu+Math.imul(eG,cC)|0)+Math.imul(eW,cy)|0,ed=ed+Math.imul(eW,cC)|0;var cZ=(eV+(ef=ef+Math.imul(eU,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eU,ck)|0)+Math.imul(eq,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eq,ck)|0)+(eu>>>13)|0)+(cZ>>>26)|0,cZ&=67108863,ef=Math.imul(e$,cy),eu=(eu=Math.imul(e$,cC))+Math.imul(eJ,cy)|0,ed=Math.imul(eJ,cC);var cG=(eV+(ef=ef+Math.imul(eG,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eG,ck)|0)+Math.imul(eW,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eW,ck)|0)+(eu>>>13)|0)+(cG>>>26)|0,cG&=67108863;var cW=(eV+(ef=Math.imul(e$,cw))|0)+((8191&(eu=(eu=Math.imul(e$,ck))+Math.imul(eJ,cw)|0))<<13)|0;return eV=((ed=Math.imul(eJ,ck))+(eu>>>13)|0)+(cW>>>26)|0,cW&=67108863,ez[0]=cN,ez[1]=cS,ez[2]=cA,ez[3]=c_,ez[4]=cE,ez[5]=cP,ez[6]=cB,ez[7]=cT,ez[8]=cI,ez[9]=cR,ez[10]=cO,ez[11]=cj,ez[12]=cD,ez[13]=cF,ez[14]=cU,ez[15]=cq,ez[16]=cZ,ez[17]=cG,ez[18]=cW,0!==eV&&(ez[19]=eV,es.length++),es};function eC(et,ei,es){es.negative=ei.negative^et.negative,es.length=et.length+ei.length;for(var ef=0,eu=0,ed=0;ed>>26)|0)>>>26,em&=67108863}es.words[ed]=eH,ef=em,em=eu}return 0!==ef?es.words[ed]=ef:es.length--,es.strip()}function ex(et,ei,es){return(new ew).mulp(et,ei,es)}function ew(et,ei){this.x=et,this.y=ei}Math.imul||(ey=eb),ed.prototype.mulTo=function(et,ei){var es=this.length+et.length;return 10===this.length&&10===et.length?ey(this,et,ei):es<63?eb(this,et,ei):es<1024?eC(this,et,ei):ex(this,et,ei)},ew.prototype.makeRBT=function(et){for(var ei=Array(et),es=ed.prototype._countBits(et)-1,ef=0;ef>=1;return ef},ew.prototype.permute=function(et,ei,es,ef,eu,ed){for(var em=0;em>>=1)eu++;return 1<>>=13,es[2*em+1]=8191&ed,ed>>>=13;for(em=2*ei;em>=26,ei+=(eu/67108864|0)+(ed>>>26),this.words[es]=67108863&ed}return 0!==ei&&(this.words[es]=ei,this.length++),this},ed.prototype.muln=function(et){return this.clone().imuln(et)},ed.prototype.sqr=function(){return this.mul(this)},ed.prototype.isqr=function(){return this.imul(this.clone())},ed.prototype.pow=function(et){var ei=eL(et);if(0===ei.length)return new ed(1);for(var es=this,ef=0;ef=0);var ei,es=et%26,eu=(et-es)/26,ed=67108863>>>26-es<<26-es;if(0!==es){var em=0;for(ei=0;ei>>26-es}em&&(this.words[ei]=em,this.length++)}if(0!==eu){for(ei=this.length-1;ei>=0;ei--)this.words[ei+eu]=this.words[ei];for(ei=0;ei=0),eu=ei?(ei-ei%26)/26:0;var eu,ed=et%26,em=Math.min((et-ed)/26,this.length),eH=67108863^67108863>>>ed<em)for(this.length-=em,eV=0;eV=0&&(0!==eM||eV>=eu);eV--){var eg=0|this.words[eV];this.words[eV]=eM<<26-ed|eg>>>ed,eM=eg&eH}return ez&&0!==eM&&(ez.words[ez.length++]=eM),0===this.length&&(this.words[0]=0,this.length=1),this.strip()},ed.prototype.ishrn=function(et,ei,es){return ef(0===this.negative),this.iushrn(et,ei,es)},ed.prototype.shln=function(et){return this.clone().ishln(et)},ed.prototype.ushln=function(et){return this.clone().iushln(et)},ed.prototype.shrn=function(et){return this.clone().ishrn(et)},ed.prototype.ushrn=function(et){return this.clone().iushrn(et)},ed.prototype.testn=function(et){ef("number"==typeof et&&et>=0);var ei=et%26,es=(et-ei)/26,eu=1<=0);var ei=et%26,es=(et-ei)/26;if(ef(0===this.negative,"imaskn works only with positive numbers"),this.length<=es)return this;if(0!==ei&&es++,this.length=Math.min(es,this.length),0!==ei){var eu=67108863^67108863>>>ei<=67108864;ei++)this.words[ei]-=67108864,ei===this.length-1?this.words[ei+1]=1:this.words[ei+1]++;return this.length=Math.max(this.length,ei+1),this},ed.prototype.isubn=function(et){if(ef("number"==typeof et),ef(et<67108864),et<0)return this.iaddn(-et);if(0!==this.negative)return this.negative=0,this.iaddn(et),this.negative=1,this;if(this.words[0]-=et,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var ei=0;ei>26)-(ez/67108864|0),this.words[eu+es]=67108863&ed}for(;eu>26,this.words[eu+es]=67108863&ed;if(0===eH)return this.strip();for(ef(-1===eH),eH=0,eu=0;eu>26,this.words[eu]=67108863&ed;return this.negative=1,this.strip()},ed.prototype._wordDiv=function(et,ei){var es,ef=this.length-et.length,eu=this.clone(),em=et,eH=0|em.words[em.length-1];0!=(ef=26-this._countBits(eH))&&(em=em.ushln(ef),eu.iushln(ef),eH=0|em.words[em.length-1]);var ez=eu.length-em.length;if("mod"!==ei){(es=new ed(null)).length=ez+1,es.words=Array(es.length);for(var eV=0;eV=0;eg--){var eL=(0|eu.words[em.length+eg])*67108864+(0|eu.words[em.length+eg-1]);for(eL=Math.min(eL/eH|0,67108863),eu._ishlnsubmul(em,eL,eg);0!==eu.negative;)eL--,eu.negative=0,eu._ishlnsubmul(em,1,eg),eu.isZero()||(eu.negative^=1);es&&(es.words[eg]=eL)}return es&&es.strip(),eu.strip(),"div"!==ei&&0!==ef&&eu.iushrn(ef),{div:es||null,mod:eu}},ed.prototype.divmod=function(et,ei,es){var eu,em,eH;return(ef(!et.isZero()),this.isZero())?{div:new ed(0),mod:new ed(0)}:0!==this.negative&&0===et.negative?(eH=this.neg().divmod(et,ei),"mod"!==ei&&(eu=eH.div.neg()),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.iadd(et)),{div:eu,mod:em}):0===this.negative&&0!==et.negative?(eH=this.divmod(et.neg(),ei),"mod"!==ei&&(eu=eH.div.neg()),{div:eu,mod:eH.mod}):(this.negative&et.negative)!=0?(eH=this.neg().divmod(et.neg(),ei),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.isub(et)),{div:eH.div,mod:em}):et.length>this.length||0>this.cmp(et)?{div:new ed(0),mod:this}:1===et.length?"div"===ei?{div:this.divn(et.words[0]),mod:null}:"mod"===ei?{div:null,mod:new ed(this.modn(et.words[0]))}:{div:this.divn(et.words[0]),mod:new ed(this.modn(et.words[0]))}:this._wordDiv(et,ei)},ed.prototype.div=function(et){return this.divmod(et,"div",!1).div},ed.prototype.mod=function(et){return this.divmod(et,"mod",!1).mod},ed.prototype.umod=function(et){return this.divmod(et,"mod",!0).mod},ed.prototype.divRound=function(et){var ei=this.divmod(et);if(ei.mod.isZero())return ei.div;var es=0!==ei.div.negative?ei.mod.isub(et):ei.mod,ef=et.ushrn(1),eu=et.andln(1),ed=es.cmp(ef);return ed<0||1===eu&&0===ed?ei.div:0!==ei.div.negative?ei.div.isubn(1):ei.div.iaddn(1)},ed.prototype.modn=function(et){ef(et<=67108863);for(var ei=67108864%et,es=0,eu=this.length-1;eu>=0;eu--)es=(ei*es+(0|this.words[eu]))%et;return es},ed.prototype.idivn=function(et){ef(et<=67108863);for(var ei=0,es=this.length-1;es>=0;es--){var eu=(0|this.words[es])+67108864*ei;this.words[es]=eu/et|0,ei=eu%et}return this.strip()},ed.prototype.divn=function(et){return this.clone().idivn(et)},ed.prototype.egcd=function(et){ef(0===et.negative),ef(!et.isZero());var ei=this,es=et.clone();ei=0!==ei.negative?ei.umod(et):ei.clone();for(var eu=new ed(1),em=new ed(0),eH=new ed(0),ez=new ed(1),eV=0;ei.isEven()&&es.isEven();)ei.iushrn(1),es.iushrn(1),++eV;for(var eM=es.clone(),eg=ei.clone();!ei.isZero();){for(var eL=0,eb=1;(ei.words[0]&eb)==0&&eL<26;++eL,eb<<=1);if(eL>0)for(ei.iushrn(eL);eL-- >0;)(eu.isOdd()||em.isOdd())&&(eu.iadd(eM),em.isub(eg)),eu.iushrn(1),em.iushrn(1);for(var ey=0,eC=1;(es.words[0]&eC)==0&&ey<26;++ey,eC<<=1);if(ey>0)for(es.iushrn(ey);ey-- >0;)(eH.isOdd()||ez.isOdd())&&(eH.iadd(eM),ez.isub(eg)),eH.iushrn(1),ez.iushrn(1);ei.cmp(es)>=0?(ei.isub(es),eu.isub(eH),em.isub(ez)):(es.isub(ei),eH.isub(eu),ez.isub(em))}return{a:eH,b:ez,gcd:es.iushln(eV)}},ed.prototype._invmp=function(et){ef(0===et.negative),ef(!et.isZero());var ei,es=this,eu=et.clone();es=0!==es.negative?es.umod(et):es.clone();for(var em=new ed(1),eH=new ed(0),ez=eu.clone();es.cmpn(1)>0&&eu.cmpn(1)>0;){for(var eV=0,eM=1;(es.words[0]&eM)==0&&eV<26;++eV,eM<<=1);if(eV>0)for(es.iushrn(eV);eV-- >0;)em.isOdd()&&em.iadd(ez),em.iushrn(1);for(var eg=0,eL=1;(eu.words[0]&eL)==0&&eg<26;++eg,eL<<=1);if(eg>0)for(eu.iushrn(eg);eg-- >0;)eH.isOdd()&&eH.iadd(ez),eH.iushrn(1);es.cmp(eu)>=0?(es.isub(eu),em.isub(eH)):(eu.isub(es),eH.isub(em))}return 0>(ei=0===es.cmpn(1)?em:eH).cmpn(0)&&ei.iadd(et),ei},ed.prototype.gcd=function(et){if(this.isZero())return et.abs();if(et.isZero())return this.abs();var ei=this.clone(),es=et.clone();ei.negative=0,es.negative=0;for(var ef=0;ei.isEven()&&es.isEven();ef++)ei.iushrn(1),es.iushrn(1);for(;;){for(;ei.isEven();)ei.iushrn(1);for(;es.isEven();)es.iushrn(1);var eu=ei.cmp(es);if(eu<0){var ed=ei;ei=es,es=ed}else if(0===eu||0===es.cmpn(1))break;ei.isub(es)}return es.iushln(ef)},ed.prototype.invm=function(et){return this.egcd(et).a.umod(et)},ed.prototype.isEven=function(){return(1&this.words[0])==0},ed.prototype.isOdd=function(){return(1&this.words[0])==1},ed.prototype.andln=function(et){return this.words[0]&et},ed.prototype.bincn=function(et){ef("number"==typeof et);var ei=et%26,es=(et-ei)/26,eu=1<>>26,eH&=67108863,this.words[em]=eH}return 0!==ed&&(this.words[em]=ed,this.length++),this},ed.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},ed.prototype.cmpn=function(et){var ei,es=et<0;if(0!==this.negative&&!es)return -1;if(0===this.negative&&es)return 1;if(this.strip(),this.length>1)ei=1;else{es&&(et=-et),ef(et<=67108863,"Number is too big");var eu=0|this.words[0];ei=eu===et?0:euet.length)return 1;if(this.length=0;es--){var ef=0|this.words[es],eu=0|et.words[es];if(ef!==eu){efeu&&(ei=1);break}}return ei},ed.prototype.gtn=function(et){return 1===this.cmpn(et)},ed.prototype.gt=function(et){return 1===this.cmp(et)},ed.prototype.gten=function(et){return this.cmpn(et)>=0},ed.prototype.gte=function(et){return this.cmp(et)>=0},ed.prototype.ltn=function(et){return -1===this.cmpn(et)},ed.prototype.lt=function(et){return -1===this.cmp(et)},ed.prototype.lten=function(et){return 0>=this.cmpn(et)},ed.prototype.lte=function(et){return 0>=this.cmp(et)},ed.prototype.eqn=function(et){return 0===this.cmpn(et)},ed.prototype.eq=function(et){return 0===this.cmp(et)},ed.red=function(et){return new eB(et)},ed.prototype.toRed=function(et){return ef(!this.red,"Already a number in reduction context"),ef(0===this.negative,"red works only with positives"),et.convertTo(this)._forceRed(et)},ed.prototype.fromRed=function(){return ef(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},ed.prototype._forceRed=function(et){return this.red=et,this},ed.prototype.forceRed=function(et){return ef(!this.red,"Already a number in reduction context"),this._forceRed(et)},ed.prototype.redAdd=function(et){return ef(this.red,"redAdd works only with red numbers"),this.red.add(this,et)},ed.prototype.redIAdd=function(et){return ef(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,et)},ed.prototype.redSub=function(et){return ef(this.red,"redSub works only with red numbers"),this.red.sub(this,et)},ed.prototype.redISub=function(et){return ef(this.red,"redISub works only with red numbers"),this.red.isub(this,et)},ed.prototype.redShl=function(et){return ef(this.red,"redShl works only with red numbers"),this.red.shl(this,et)},ed.prototype.redMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.mul(this,et)},ed.prototype.redIMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.imul(this,et)},ed.prototype.redSqr=function(){return ef(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},ed.prototype.redISqr=function(){return ef(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},ed.prototype.redSqrt=function(){return ef(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},ed.prototype.redInvm=function(){return ef(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},ed.prototype.redNeg=function(){return ef(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},ed.prototype.redPow=function(et){return ef(this.red&&!et.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,et)};var eN={k256:null,p224:null,p192:null,p25519:null};function eS(et,ei){this.name=et,this.p=new ed(ei,16),this.n=this.p.bitLength(),this.k=new ed(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function eA(){eS.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function e_(){eS.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function eE(){eS.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function eP(){eS.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function eB(et){if("string"==typeof et){var ei=ed._prime(et);this.m=ei.p,this.prime=ei}else ef(et.gtn(1),"modulus must be greater than 1"),this.m=et,this.prime=null}function eT(et){eB.call(this,et),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new ed(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)}eS.prototype._tmp=function(){var et=new ed(null);return et.words=Array(Math.ceil(this.n/13)),et},eS.prototype.ireduce=function(et){var ei,es=et;do this.split(es,this.tmp),ei=(es=(es=this.imulK(es)).iadd(this.tmp)).bitLength();while(ei>this.n);var ef=ei0?es.isub(this.p):void 0!==es.strip?es.strip():es._strip(),es},eS.prototype.split=function(et,ei){et.iushrn(this.n,0,ei)},eS.prototype.imulK=function(et){return et.imul(this.k)},eu(eA,eS),eA.prototype.split=function(et,ei){for(var es=4194303,ef=Math.min(et.length,9),eu=0;eu>>22,ed=em}ed>>>=22,et.words[eu-10]=ed,0===ed&&et.length>10?et.length-=10:et.length-=9},eA.prototype.imulK=function(et){et.words[et.length]=0,et.words[et.length+1]=0,et.length+=2;for(var ei=0,es=0;es>>=26,et.words[es]=eu,ei=ef}return 0!==ei&&(et.words[et.length++]=ei),et},ed._prime=function(et){var ei;if(eN[et])return eN[et];if("k256"===et)ei=new eA;else if("p224"===et)ei=new e_;else if("p192"===et)ei=new eE;else if("p25519"===et)ei=new eP;else throw Error("Unknown prime "+et);return eN[et]=ei,ei},eB.prototype._verify1=function(et){ef(0===et.negative,"red works only with positives"),ef(et.red,"red works only with red numbers")},eB.prototype._verify2=function(et,ei){ef((et.negative|ei.negative)==0,"red works only with positives"),ef(et.red&&et.red===ei.red,"red works only with red numbers")},eB.prototype.imod=function(et){return this.prime?this.prime.ireduce(et)._forceRed(this):et.umod(this.m)._forceRed(this)},eB.prototype.neg=function(et){return et.isZero()?et.clone():this.m.sub(et)._forceRed(this)},eB.prototype.add=function(et,ei){this._verify2(et,ei);var es=et.add(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es._forceRed(this)},eB.prototype.iadd=function(et,ei){this._verify2(et,ei);var es=et.iadd(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es},eB.prototype.sub=function(et,ei){this._verify2(et,ei);var es=et.sub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es._forceRed(this)},eB.prototype.isub=function(et,ei){this._verify2(et,ei);var es=et.isub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es},eB.prototype.shl=function(et,ei){return this._verify1(et),this.imod(et.ushln(ei))},eB.prototype.imul=function(et,ei){return this._verify2(et,ei),this.imod(et.imul(ei))},eB.prototype.mul=function(et,ei){return this._verify2(et,ei),this.imod(et.mul(ei))},eB.prototype.isqr=function(et){return this.imul(et,et.clone())},eB.prototype.sqr=function(et){return this.mul(et,et)},eB.prototype.sqrt=function(et){if(et.isZero())return et.clone();var ei=this.m.andln(3);if(ef(ei%2==1),3===ei){var es=this.m.add(new ed(1)).iushrn(2);return this.pow(et,es)}for(var eu=this.m.subn(1),em=0;!eu.isZero()&&0===eu.andln(1);)em++,eu.iushrn(1);ef(!eu.isZero());var eH=new ed(1).toRed(this),ez=eH.redNeg(),eV=this.m.subn(1).iushrn(1),eM=this.m.bitLength();for(eM=new ed(2*eM*eM).toRed(this);0!==this.pow(eM,eV).cmp(ez);)eM.redIAdd(ez);for(var eg=this.pow(eM,eu),eL=this.pow(et,eu.addn(1).iushrn(1)),eb=this.pow(et,eu),ey=em;0!==eb.cmp(eH);){for(var eC=eb,ex=0;0!==eC.cmp(eH);ex++)eC=eC.redSqr();ef(ex=0;eu--){for(var eM=ei.words[eu],eg=eV-1;eg>=0;eg--){var eL=eM>>eg&1;if(em!==ef[0]&&(em=this.sqr(em)),0===eL&&0===eH){ez=0;continue}eH<<=1,eH|=eL,(++ez===es||0===eu&&0===eg)&&(em=this.mul(em,ef[eH]),ez=0,eH=0)}eV=26}return em},eB.prototype.convertTo=function(et){var ei=et.umod(this.m);return ei===et?ei.clone():ei},eB.prototype.convertFrom=function(et){var ei=et.clone();return ei.red=null,ei},ed.mont=function(et){return new eT(et)},eu(eT,eB),eT.prototype.convertTo=function(et){return this.imod(et.ushln(this.shift))},eT.prototype.convertFrom=function(et){var ei=this.imod(et.mul(this.rinv));return ei.red=null,ei},eT.prototype.imul=function(et,ei){if(et.isZero()||ei.isZero())return et.words[0]=0,et.length=1,et;var es=et.imul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),ed=eu;return eu.cmp(this.m)>=0?ed=eu.isub(this.m):0>eu.cmpn(0)&&(ed=eu.iadd(this.m)),ed._forceRed(this)},eT.prototype.mul=function(et,ei){if(et.isZero()||ei.isZero())return new ed(0)._forceRed(this);var es=et.mul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),em=eu;return eu.cmp(this.m)>=0?em=eu.isub(this.m):0>eu.cmpn(0)&&(em=eu.iadd(this.m)),em._forceRed(this)},eT.prototype.invm=function(et){return this.imod(et._invmp(this.m).mul(this.r2))._forceRed(this)}}(et=es.nmd(et),this)},1670:function(et,ei,es){!function(et,ei){"use strict";function ef(et,ei){if(!et)throw Error(ei||"Assertion failed")}function eu(et,ei){et.super_=ei;var es=function(){};es.prototype=ei.prototype,et.prototype=new es,et.prototype.constructor=et}function ed(et,ei,es){if(ed.isBN(et))return et;this.negative=0,this.words=null,this.length=0,this.red=null,null!==et&&(("le"===ei||"be"===ei)&&(es=ei,ei=10),this._init(et||0,ei||10,es||"be"))}"object"==typeof et?et.exports=ed:ei.BN=ed,ed.BN=ed,ed.wordSize=26;try{eM=es(4300).Buffer}catch(et){}function em(et,ei,es){for(var eu=0,ed=Math.min(et.length,es),em=0,eH=ei;eH=49&&eV<=54?eV-49+10:eV>=17&&eV<=22?eV-17+10:eV,em|=ez}return ef(!(240&em),"Invalid character in "+et),eu}function eH(et,ei,es,eu){for(var ed=0,em=0,eH=Math.min(et.length,es),ez=ei;ez=49?eV-49+10:eV>=17?eV-17+10:eV,ef(eV>=0&&em"}ed.isBN=function(et){return et instanceof ed||null!==et&&"object"==typeof et&&et.constructor.wordSize===ed.wordSize&&Array.isArray(et.words)},ed.max=function(et,ei){return et.cmp(ei)>0?et:ei},ed.min=function(et,ei){return 0>et.cmp(ei)?et:ei},ed.prototype._init=function(et,ei,es){if("number"==typeof et)return this._initNumber(et,ei,es);if("object"==typeof et)return this._initArray(et,ei,es);"hex"===ei&&(ei=16),ef(ei===(0|ei)&&ei>=2&&ei<=36);var eu=0;"-"===(et=et.toString().replace(/\s+/g,""))[0]&&eu++,16===ei?this._parseHex(et,eu):this._parseBase(et,ei,eu),"-"===et[0]&&(this.negative=1),this._strip(),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initNumber=function(et,ei,es){et<0&&(this.negative=1,et=-et),et<67108864?(this.words=[67108863&et],this.length=1):et<4503599627370496?(this.words=[67108863&et,et/67108864&67108863],this.length=2):(ef(et<9007199254740992),this.words=[67108863&et,et/67108864&67108863,1],this.length=3),"le"===es&&this._initArray(this.toArray(),ei,es)},ed.prototype._initArray=function(et,ei,es){if(ef("number"==typeof et.length),et.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(et.length/3),this.words=Array(this.length);for(var eu,ed,em=0;em=0;em-=3)ed=et[em]|et[em-1]<<8|et[em-2]<<16,this.words[eu]|=ed<>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);else if("le"===es)for(em=0,eu=0;em>>26-eH&67108863,(eH+=24)>=26&&(eH-=26,eu++);return this._strip()},ed.prototype._parseHex=function(et,ei){this.length=Math.ceil((et.length-ei)/6),this.words=Array(this.length);for(var es,ef,eu=0;eu=ei;eu-=6)ef=em(et,eu,eu+6),this.words[es]|=ef<>>26-ed&4194303,(ed+=24)>=26&&(ed-=26,es++);eu+6!==ei&&(ef=em(et,ei,eu+6),this.words[es]|=ef<>>26-ed&4194303),this._strip()},ed.prototype._parseBase=function(et,ei,es){this.words=[0],this.length=1;for(var ef=0,eu=1;eu<=67108863;eu*=ei)ef++;ef--,eu=eu/ei|0;for(var ed=et.length-es,em=ed%ef,ez=Math.min(ed,ed-em)+es,eV=0,eM=es;eM1&&0===this.words[this.length-1];)this.length--;return this._normSign()},ed.prototype._normSign=function(){return 1===this.length&&0===this.words[0]&&(this.negative=0),this},"undefined"!=typeof Symbol&&"function"==typeof Symbol.for?ed.prototype[Symbol.for("nodejs.util.inspect.custom")]=eV:ed.prototype.inspect=eV;var eM,eg=["","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"],eL=[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],eb=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];ed.prototype.toString=function(et,ei){if(ei=0|ei||1,16===(et=et||10)||"hex"===et){es="";for(var es,eu=0,ed=0,em=0;em>>24-eu&16777215)||em!==this.length-1?eg[6-ez.length]+ez+es:ez+es,(eu+=2)>=26&&(eu-=26,em--)}for(0!==ed&&(es=ed.toString(16)+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}if(et===(0|et)&&et>=2&&et<=36){var eV=eL[et],eM=eb[et];es="";var ey=this.clone();for(ey.negative=0;!ey.isZero();){var eC=ey.modrn(eM).toString(et);es=(ey=ey.idivn(eM)).isZero()?eC+es:eg[eV-eC.length]+eC+es}for(this.isZero()&&(es="0"+es);es.length%ei!=0;)es="0"+es;return 0!==this.negative&&(es="-"+es),es}ef(!1,"Base should be between 2 and 36")},ed.prototype.toNumber=function(){var et=this.words[0];return 2===this.length?et+=67108864*this.words[1]:3===this.length&&1===this.words[2]?et+=4503599627370496+67108864*this.words[1]:this.length>2&&ef(!1,"Number can only safely store up to 53 bits"),0!==this.negative?-et:et},ed.prototype.toJSON=function(){return this.toString(16,2)},eM&&(ed.prototype.toBuffer=function(et,ei){return this.toArrayLike(eM,et,ei)}),ed.prototype.toArray=function(et,ei){return this.toArrayLike(Array,et,ei)};var ey=function(et,ei){return et.allocUnsafe?et.allocUnsafe(ei):new et(ei)};function eC(et){for(var ei=Array(et.bitLength()),es=0;es>>eu&1}return ei}function ex(et,ei,es){es.negative=ei.negative^et.negative;var ef=et.length+ei.length|0;es.length=ef,ef=ef-1|0;var eu=0|et.words[0],ed=0|ei.words[0],em=eu*ed,eH=67108863&em,ez=em/67108864|0;es.words[0]=eH;for(var eV=1;eV>>26,eg=67108863&ez,eL=Math.min(eV,ei.length-1),eb=Math.max(0,eV-et.length+1);eb<=eL;eb++){var ey=eV-eb|0;eM+=(em=(eu=0|et.words[ey])*(ed=0|ei.words[eb])+eg)/67108864|0,eg=67108863&em}es.words[eV]=0|eg,ez=0|eM}return 0!==ez?es.words[eV]=0|ez:es.length--,es._strip()}ed.prototype.toArrayLike=function(et,ei,es){this._strip();var eu=this.byteLength(),ed=es||Math.max(1,eu);ef(eu<=ed,"byte array longer than desired length"),ef(ed>0,"Requested array length <= 0");var em=ey(et,ed);return this["_toArrayLike"+("le"===ei?"LE":"BE")](em,eu),em},ed.prototype._toArrayLikeLE=function(et,ei){for(var es=0,ef=0,eu=0,ed=0;eu>8&255),es>16&255),6===ed?(es>24&255),ef=0,ed=0):(ef=em>>>24,ed+=2)}if(es=0&&(et[es--]=em>>8&255),es>=0&&(et[es--]=em>>16&255),6===ed?(es>=0&&(et[es--]=em>>24&255),ef=0,ed=0):(ef=em>>>24,ed+=2)}if(es>=0)for(et[es--]=ef;es>=0;)et[es--]=0},Math.clz32?ed.prototype._countBits=function(et){return 32-Math.clz32(et)}:ed.prototype._countBits=function(et){var ei=et,es=0;return ei>=4096&&(es+=13,ei>>>=13),ei>=64&&(es+=7,ei>>>=7),ei>=8&&(es+=4,ei>>>=4),ei>=2&&(es+=2,ei>>>=2),es+ei},ed.prototype._zeroBits=function(et){if(0===et)return 26;var ei=et,es=0;return(8191&ei)==0&&(es+=13,ei>>>=13),(127&ei)==0&&(es+=7,ei>>>=7),(15&ei)==0&&(es+=4,ei>>>=4),(3&ei)==0&&(es+=2,ei>>>=2),(1&ei)==0&&es++,es},ed.prototype.bitLength=function(){var et=this.words[this.length-1],ei=this._countBits(et);return(this.length-1)*26+ei},ed.prototype.zeroBits=function(){if(this.isZero())return 0;for(var et=0,ei=0;eiet.length?this.clone().ior(et):et.clone().ior(this)},ed.prototype.uor=function(et){return this.length>et.length?this.clone().iuor(et):et.clone().iuor(this)},ed.prototype.iuand=function(et){var ei;ei=this.length>et.length?et:this;for(var es=0;eset.length?this.clone().iand(et):et.clone().iand(this)},ed.prototype.uand=function(et){return this.length>et.length?this.clone().iuand(et):et.clone().iuand(this)},ed.prototype.iuxor=function(et){this.length>et.length?(ei=this,es=et):(ei=et,es=this);for(var ei,es,ef=0;efet.length?this.clone().ixor(et):et.clone().ixor(this)},ed.prototype.uxor=function(et){return this.length>et.length?this.clone().iuxor(et):et.clone().iuxor(this)},ed.prototype.inotn=function(et){ef("number"==typeof et&&et>=0);var ei=0|Math.ceil(et/26),es=et%26;this._expand(ei),es>0&&ei--;for(var eu=0;eu0&&(this.words[eu]=~this.words[eu]&67108863>>26-es),this._strip()},ed.prototype.notn=function(et){return this.clone().inotn(et)},ed.prototype.setn=function(et,ei){ef("number"==typeof et&&et>=0);var es=et/26|0,eu=et%26;return this._expand(es+1),ei?this.words[es]=this.words[es]|1<et.length?(es=this,ef=et):(es=et,ef=this);for(var ei,es,ef,eu=0,ed=0;ed>>26;for(;0!==eu&&ed>>26;if(this.length=es.length,0!==eu)this.words[this.length]=eu,this.length++;else if(es!==this)for(;edet.length?this.clone().iadd(et):et.clone().iadd(this)},ed.prototype.isub=function(et){if(0!==et.negative){et.negative=0;var ei,es,ef=this.iadd(et);return et.negative=1,ef._normSign()}if(0!==this.negative)return this.negative=0,this.iadd(et),this.negative=1,this._normSign();var eu=this.cmp(et);if(0===eu)return this.negative=0,this.length=1,this.words[0]=0,this;eu>0?(ei=this,es=et):(ei=et,es=this);for(var ed=0,em=0;em>26,this.words[em]=67108863&ef;for(;0!==ed&&em>26,this.words[em]=67108863&ef;if(0===ed&&em>>13,eb=0|em[1],ey=8191&eb,eC=eb>>>13,ex=0|em[2],ew=8191&ex,eN=ex>>>13,eS=0|em[3],eA=8191&eS,e_=eS>>>13,eE=0|em[4],eP=8191&eE,eB=eE>>>13,eT=0|em[5],eI=8191&eT,eR=eT>>>13,eO=0|em[6],ej=8191&eO,eD=eO>>>13,eF=0|em[7],eU=8191&eF,eq=eF>>>13,eZ=0|em[8],eG=8191&eZ,eW=eZ>>>13,eK=0|em[9],e$=8191&eK,eJ=eK>>>13,eY=0|eH[0],eX=8191&eY,eQ=eY>>>13,e1=0|eH[1],e2=8191&e1,e4=e1>>>13,e3=0|eH[2],e6=8191&e3,e0=e3>>>13,e8=0|eH[3],e5=8191&e8,e7=e8>>>13,e9=0|eH[4],cc=8191&e9,ci=e9>>>13,cs=0|eH[5],cf=8191&cs,cd=cs>>>13,cm=0|eH[6],cH=8191&cm,cz=cm>>>13,cV=0|eH[7],cM=8191&cV,cg=cV>>>13,cL=0|eH[8],cy=8191&cL,cC=cL>>>13,cx=0|eH[9],cw=8191&cx,ck=cx>>>13;es.negative=et.negative^ei.negative,es.length=19;var cN=(eV+(ef=Math.imul(eg,eX))|0)+((8191&(eu=(eu=Math.imul(eg,eQ))+Math.imul(eL,eX)|0))<<13)|0;eV=((ed=Math.imul(eL,eQ))+(eu>>>13)|0)+(cN>>>26)|0,cN&=67108863,ef=Math.imul(ey,eX),eu=(eu=Math.imul(ey,eQ))+Math.imul(eC,eX)|0,ed=Math.imul(eC,eQ);var cS=(eV+(ef=ef+Math.imul(eg,e2)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e4)|0)+Math.imul(eL,e2)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e4)|0)+(eu>>>13)|0)+(cS>>>26)|0,cS&=67108863,ef=Math.imul(ew,eX),eu=(eu=Math.imul(ew,eQ))+Math.imul(eN,eX)|0,ed=Math.imul(eN,eQ),ef=ef+Math.imul(ey,e2)|0,eu=(eu=eu+Math.imul(ey,e4)|0)+Math.imul(eC,e2)|0,ed=ed+Math.imul(eC,e4)|0;var cA=(eV+(ef=ef+Math.imul(eg,e6)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e0)|0)+Math.imul(eL,e6)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e0)|0)+(eu>>>13)|0)+(cA>>>26)|0,cA&=67108863,ef=Math.imul(eA,eX),eu=(eu=Math.imul(eA,eQ))+Math.imul(e_,eX)|0,ed=Math.imul(e_,eQ),ef=ef+Math.imul(ew,e2)|0,eu=(eu=eu+Math.imul(ew,e4)|0)+Math.imul(eN,e2)|0,ed=ed+Math.imul(eN,e4)|0,ef=ef+Math.imul(ey,e6)|0,eu=(eu=eu+Math.imul(ey,e0)|0)+Math.imul(eC,e6)|0,ed=ed+Math.imul(eC,e0)|0;var c_=(eV+(ef=ef+Math.imul(eg,e5)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,e7)|0)+Math.imul(eL,e5)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,e7)|0)+(eu>>>13)|0)+(c_>>>26)|0,c_&=67108863,ef=Math.imul(eP,eX),eu=(eu=Math.imul(eP,eQ))+Math.imul(eB,eX)|0,ed=Math.imul(eB,eQ),ef=ef+Math.imul(eA,e2)|0,eu=(eu=eu+Math.imul(eA,e4)|0)+Math.imul(e_,e2)|0,ed=ed+Math.imul(e_,e4)|0,ef=ef+Math.imul(ew,e6)|0,eu=(eu=eu+Math.imul(ew,e0)|0)+Math.imul(eN,e6)|0,ed=ed+Math.imul(eN,e0)|0,ef=ef+Math.imul(ey,e5)|0,eu=(eu=eu+Math.imul(ey,e7)|0)+Math.imul(eC,e5)|0,ed=ed+Math.imul(eC,e7)|0;var cE=(eV+(ef=ef+Math.imul(eg,cc)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ci)|0)+Math.imul(eL,cc)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ci)|0)+(eu>>>13)|0)+(cE>>>26)|0,cE&=67108863,ef=Math.imul(eI,eX),eu=(eu=Math.imul(eI,eQ))+Math.imul(eR,eX)|0,ed=Math.imul(eR,eQ),ef=ef+Math.imul(eP,e2)|0,eu=(eu=eu+Math.imul(eP,e4)|0)+Math.imul(eB,e2)|0,ed=ed+Math.imul(eB,e4)|0,ef=ef+Math.imul(eA,e6)|0,eu=(eu=eu+Math.imul(eA,e0)|0)+Math.imul(e_,e6)|0,ed=ed+Math.imul(e_,e0)|0,ef=ef+Math.imul(ew,e5)|0,eu=(eu=eu+Math.imul(ew,e7)|0)+Math.imul(eN,e5)|0,ed=ed+Math.imul(eN,e7)|0,ef=ef+Math.imul(ey,cc)|0,eu=(eu=eu+Math.imul(ey,ci)|0)+Math.imul(eC,cc)|0,ed=ed+Math.imul(eC,ci)|0;var cP=(eV+(ef=ef+Math.imul(eg,cf)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cd)|0)+Math.imul(eL,cf)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cd)|0)+(eu>>>13)|0)+(cP>>>26)|0,cP&=67108863,ef=Math.imul(ej,eX),eu=(eu=Math.imul(ej,eQ))+Math.imul(eD,eX)|0,ed=Math.imul(eD,eQ),ef=ef+Math.imul(eI,e2)|0,eu=(eu=eu+Math.imul(eI,e4)|0)+Math.imul(eR,e2)|0,ed=ed+Math.imul(eR,e4)|0,ef=ef+Math.imul(eP,e6)|0,eu=(eu=eu+Math.imul(eP,e0)|0)+Math.imul(eB,e6)|0,ed=ed+Math.imul(eB,e0)|0,ef=ef+Math.imul(eA,e5)|0,eu=(eu=eu+Math.imul(eA,e7)|0)+Math.imul(e_,e5)|0,ed=ed+Math.imul(e_,e7)|0,ef=ef+Math.imul(ew,cc)|0,eu=(eu=eu+Math.imul(ew,ci)|0)+Math.imul(eN,cc)|0,ed=ed+Math.imul(eN,ci)|0,ef=ef+Math.imul(ey,cf)|0,eu=(eu=eu+Math.imul(ey,cd)|0)+Math.imul(eC,cf)|0,ed=ed+Math.imul(eC,cd)|0;var cB=(eV+(ef=ef+Math.imul(eg,cH)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cz)|0)+Math.imul(eL,cH)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cz)|0)+(eu>>>13)|0)+(cB>>>26)|0,cB&=67108863,ef=Math.imul(eU,eX),eu=(eu=Math.imul(eU,eQ))+Math.imul(eq,eX)|0,ed=Math.imul(eq,eQ),ef=ef+Math.imul(ej,e2)|0,eu=(eu=eu+Math.imul(ej,e4)|0)+Math.imul(eD,e2)|0,ed=ed+Math.imul(eD,e4)|0,ef=ef+Math.imul(eI,e6)|0,eu=(eu=eu+Math.imul(eI,e0)|0)+Math.imul(eR,e6)|0,ed=ed+Math.imul(eR,e0)|0,ef=ef+Math.imul(eP,e5)|0,eu=(eu=eu+Math.imul(eP,e7)|0)+Math.imul(eB,e5)|0,ed=ed+Math.imul(eB,e7)|0,ef=ef+Math.imul(eA,cc)|0,eu=(eu=eu+Math.imul(eA,ci)|0)+Math.imul(e_,cc)|0,ed=ed+Math.imul(e_,ci)|0,ef=ef+Math.imul(ew,cf)|0,eu=(eu=eu+Math.imul(ew,cd)|0)+Math.imul(eN,cf)|0,ed=ed+Math.imul(eN,cd)|0,ef=ef+Math.imul(ey,cH)|0,eu=(eu=eu+Math.imul(ey,cz)|0)+Math.imul(eC,cH)|0,ed=ed+Math.imul(eC,cz)|0;var cT=(eV+(ef=ef+Math.imul(eg,cM)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cg)|0)+Math.imul(eL,cM)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cg)|0)+(eu>>>13)|0)+(cT>>>26)|0,cT&=67108863,ef=Math.imul(eG,eX),eu=(eu=Math.imul(eG,eQ))+Math.imul(eW,eX)|0,ed=Math.imul(eW,eQ),ef=ef+Math.imul(eU,e2)|0,eu=(eu=eu+Math.imul(eU,e4)|0)+Math.imul(eq,e2)|0,ed=ed+Math.imul(eq,e4)|0,ef=ef+Math.imul(ej,e6)|0,eu=(eu=eu+Math.imul(ej,e0)|0)+Math.imul(eD,e6)|0,ed=ed+Math.imul(eD,e0)|0,ef=ef+Math.imul(eI,e5)|0,eu=(eu=eu+Math.imul(eI,e7)|0)+Math.imul(eR,e5)|0,ed=ed+Math.imul(eR,e7)|0,ef=ef+Math.imul(eP,cc)|0,eu=(eu=eu+Math.imul(eP,ci)|0)+Math.imul(eB,cc)|0,ed=ed+Math.imul(eB,ci)|0,ef=ef+Math.imul(eA,cf)|0,eu=(eu=eu+Math.imul(eA,cd)|0)+Math.imul(e_,cf)|0,ed=ed+Math.imul(e_,cd)|0,ef=ef+Math.imul(ew,cH)|0,eu=(eu=eu+Math.imul(ew,cz)|0)+Math.imul(eN,cH)|0,ed=ed+Math.imul(eN,cz)|0,ef=ef+Math.imul(ey,cM)|0,eu=(eu=eu+Math.imul(ey,cg)|0)+Math.imul(eC,cM)|0,ed=ed+Math.imul(eC,cg)|0;var cI=(eV+(ef=ef+Math.imul(eg,cy)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,cC)|0)+Math.imul(eL,cy)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,cC)|0)+(eu>>>13)|0)+(cI>>>26)|0,cI&=67108863,ef=Math.imul(e$,eX),eu=(eu=Math.imul(e$,eQ))+Math.imul(eJ,eX)|0,ed=Math.imul(eJ,eQ),ef=ef+Math.imul(eG,e2)|0,eu=(eu=eu+Math.imul(eG,e4)|0)+Math.imul(eW,e2)|0,ed=ed+Math.imul(eW,e4)|0,ef=ef+Math.imul(eU,e6)|0,eu=(eu=eu+Math.imul(eU,e0)|0)+Math.imul(eq,e6)|0,ed=ed+Math.imul(eq,e0)|0,ef=ef+Math.imul(ej,e5)|0,eu=(eu=eu+Math.imul(ej,e7)|0)+Math.imul(eD,e5)|0,ed=ed+Math.imul(eD,e7)|0,ef=ef+Math.imul(eI,cc)|0,eu=(eu=eu+Math.imul(eI,ci)|0)+Math.imul(eR,cc)|0,ed=ed+Math.imul(eR,ci)|0,ef=ef+Math.imul(eP,cf)|0,eu=(eu=eu+Math.imul(eP,cd)|0)+Math.imul(eB,cf)|0,ed=ed+Math.imul(eB,cd)|0,ef=ef+Math.imul(eA,cH)|0,eu=(eu=eu+Math.imul(eA,cz)|0)+Math.imul(e_,cH)|0,ed=ed+Math.imul(e_,cz)|0,ef=ef+Math.imul(ew,cM)|0,eu=(eu=eu+Math.imul(ew,cg)|0)+Math.imul(eN,cM)|0,ed=ed+Math.imul(eN,cg)|0,ef=ef+Math.imul(ey,cy)|0,eu=(eu=eu+Math.imul(ey,cC)|0)+Math.imul(eC,cy)|0,ed=ed+Math.imul(eC,cC)|0;var cR=(eV+(ef=ef+Math.imul(eg,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eg,ck)|0)+Math.imul(eL,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eL,ck)|0)+(eu>>>13)|0)+(cR>>>26)|0,cR&=67108863,ef=Math.imul(e$,e2),eu=(eu=Math.imul(e$,e4))+Math.imul(eJ,e2)|0,ed=Math.imul(eJ,e4),ef=ef+Math.imul(eG,e6)|0,eu=(eu=eu+Math.imul(eG,e0)|0)+Math.imul(eW,e6)|0,ed=ed+Math.imul(eW,e0)|0,ef=ef+Math.imul(eU,e5)|0,eu=(eu=eu+Math.imul(eU,e7)|0)+Math.imul(eq,e5)|0,ed=ed+Math.imul(eq,e7)|0,ef=ef+Math.imul(ej,cc)|0,eu=(eu=eu+Math.imul(ej,ci)|0)+Math.imul(eD,cc)|0,ed=ed+Math.imul(eD,ci)|0,ef=ef+Math.imul(eI,cf)|0,eu=(eu=eu+Math.imul(eI,cd)|0)+Math.imul(eR,cf)|0,ed=ed+Math.imul(eR,cd)|0,ef=ef+Math.imul(eP,cH)|0,eu=(eu=eu+Math.imul(eP,cz)|0)+Math.imul(eB,cH)|0,ed=ed+Math.imul(eB,cz)|0,ef=ef+Math.imul(eA,cM)|0,eu=(eu=eu+Math.imul(eA,cg)|0)+Math.imul(e_,cM)|0,ed=ed+Math.imul(e_,cg)|0,ef=ef+Math.imul(ew,cy)|0,eu=(eu=eu+Math.imul(ew,cC)|0)+Math.imul(eN,cy)|0,ed=ed+Math.imul(eN,cC)|0;var cO=(eV+(ef=ef+Math.imul(ey,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ey,ck)|0)+Math.imul(eC,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eC,ck)|0)+(eu>>>13)|0)+(cO>>>26)|0,cO&=67108863,ef=Math.imul(e$,e6),eu=(eu=Math.imul(e$,e0))+Math.imul(eJ,e6)|0,ed=Math.imul(eJ,e0),ef=ef+Math.imul(eG,e5)|0,eu=(eu=eu+Math.imul(eG,e7)|0)+Math.imul(eW,e5)|0,ed=ed+Math.imul(eW,e7)|0,ef=ef+Math.imul(eU,cc)|0,eu=(eu=eu+Math.imul(eU,ci)|0)+Math.imul(eq,cc)|0,ed=ed+Math.imul(eq,ci)|0,ef=ef+Math.imul(ej,cf)|0,eu=(eu=eu+Math.imul(ej,cd)|0)+Math.imul(eD,cf)|0,ed=ed+Math.imul(eD,cd)|0,ef=ef+Math.imul(eI,cH)|0,eu=(eu=eu+Math.imul(eI,cz)|0)+Math.imul(eR,cH)|0,ed=ed+Math.imul(eR,cz)|0,ef=ef+Math.imul(eP,cM)|0,eu=(eu=eu+Math.imul(eP,cg)|0)+Math.imul(eB,cM)|0,ed=ed+Math.imul(eB,cg)|0,ef=ef+Math.imul(eA,cy)|0,eu=(eu=eu+Math.imul(eA,cC)|0)+Math.imul(e_,cy)|0,ed=ed+Math.imul(e_,cC)|0;var cj=(eV+(ef=ef+Math.imul(ew,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ew,ck)|0)+Math.imul(eN,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eN,ck)|0)+(eu>>>13)|0)+(cj>>>26)|0,cj&=67108863,ef=Math.imul(e$,e5),eu=(eu=Math.imul(e$,e7))+Math.imul(eJ,e5)|0,ed=Math.imul(eJ,e7),ef=ef+Math.imul(eG,cc)|0,eu=(eu=eu+Math.imul(eG,ci)|0)+Math.imul(eW,cc)|0,ed=ed+Math.imul(eW,ci)|0,ef=ef+Math.imul(eU,cf)|0,eu=(eu=eu+Math.imul(eU,cd)|0)+Math.imul(eq,cf)|0,ed=ed+Math.imul(eq,cd)|0,ef=ef+Math.imul(ej,cH)|0,eu=(eu=eu+Math.imul(ej,cz)|0)+Math.imul(eD,cH)|0,ed=ed+Math.imul(eD,cz)|0,ef=ef+Math.imul(eI,cM)|0,eu=(eu=eu+Math.imul(eI,cg)|0)+Math.imul(eR,cM)|0,ed=ed+Math.imul(eR,cg)|0,ef=ef+Math.imul(eP,cy)|0,eu=(eu=eu+Math.imul(eP,cC)|0)+Math.imul(eB,cy)|0,ed=ed+Math.imul(eB,cC)|0;var cD=(eV+(ef=ef+Math.imul(eA,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eA,ck)|0)+Math.imul(e_,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(e_,ck)|0)+(eu>>>13)|0)+(cD>>>26)|0,cD&=67108863,ef=Math.imul(e$,cc),eu=(eu=Math.imul(e$,ci))+Math.imul(eJ,cc)|0,ed=Math.imul(eJ,ci),ef=ef+Math.imul(eG,cf)|0,eu=(eu=eu+Math.imul(eG,cd)|0)+Math.imul(eW,cf)|0,ed=ed+Math.imul(eW,cd)|0,ef=ef+Math.imul(eU,cH)|0,eu=(eu=eu+Math.imul(eU,cz)|0)+Math.imul(eq,cH)|0,ed=ed+Math.imul(eq,cz)|0,ef=ef+Math.imul(ej,cM)|0,eu=(eu=eu+Math.imul(ej,cg)|0)+Math.imul(eD,cM)|0,ed=ed+Math.imul(eD,cg)|0,ef=ef+Math.imul(eI,cy)|0,eu=(eu=eu+Math.imul(eI,cC)|0)+Math.imul(eR,cy)|0,ed=ed+Math.imul(eR,cC)|0;var cF=(eV+(ef=ef+Math.imul(eP,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eP,ck)|0)+Math.imul(eB,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eB,ck)|0)+(eu>>>13)|0)+(cF>>>26)|0,cF&=67108863,ef=Math.imul(e$,cf),eu=(eu=Math.imul(e$,cd))+Math.imul(eJ,cf)|0,ed=Math.imul(eJ,cd),ef=ef+Math.imul(eG,cH)|0,eu=(eu=eu+Math.imul(eG,cz)|0)+Math.imul(eW,cH)|0,ed=ed+Math.imul(eW,cz)|0,ef=ef+Math.imul(eU,cM)|0,eu=(eu=eu+Math.imul(eU,cg)|0)+Math.imul(eq,cM)|0,ed=ed+Math.imul(eq,cg)|0,ef=ef+Math.imul(ej,cy)|0,eu=(eu=eu+Math.imul(ej,cC)|0)+Math.imul(eD,cy)|0,ed=ed+Math.imul(eD,cC)|0;var cU=(eV+(ef=ef+Math.imul(eI,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eI,ck)|0)+Math.imul(eR,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eR,ck)|0)+(eu>>>13)|0)+(cU>>>26)|0,cU&=67108863,ef=Math.imul(e$,cH),eu=(eu=Math.imul(e$,cz))+Math.imul(eJ,cH)|0,ed=Math.imul(eJ,cz),ef=ef+Math.imul(eG,cM)|0,eu=(eu=eu+Math.imul(eG,cg)|0)+Math.imul(eW,cM)|0,ed=ed+Math.imul(eW,cg)|0,ef=ef+Math.imul(eU,cy)|0,eu=(eu=eu+Math.imul(eU,cC)|0)+Math.imul(eq,cy)|0,ed=ed+Math.imul(eq,cC)|0;var cq=(eV+(ef=ef+Math.imul(ej,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(ej,ck)|0)+Math.imul(eD,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eD,ck)|0)+(eu>>>13)|0)+(cq>>>26)|0,cq&=67108863,ef=Math.imul(e$,cM),eu=(eu=Math.imul(e$,cg))+Math.imul(eJ,cM)|0,ed=Math.imul(eJ,cg),ef=ef+Math.imul(eG,cy)|0,eu=(eu=eu+Math.imul(eG,cC)|0)+Math.imul(eW,cy)|0,ed=ed+Math.imul(eW,cC)|0;var cZ=(eV+(ef=ef+Math.imul(eU,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eU,ck)|0)+Math.imul(eq,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eq,ck)|0)+(eu>>>13)|0)+(cZ>>>26)|0,cZ&=67108863,ef=Math.imul(e$,cy),eu=(eu=Math.imul(e$,cC))+Math.imul(eJ,cy)|0,ed=Math.imul(eJ,cC);var cG=(eV+(ef=ef+Math.imul(eG,cw)|0)|0)+((8191&(eu=(eu=eu+Math.imul(eG,ck)|0)+Math.imul(eW,cw)|0))<<13)|0;eV=((ed=ed+Math.imul(eW,ck)|0)+(eu>>>13)|0)+(cG>>>26)|0,cG&=67108863;var cW=(eV+(ef=Math.imul(e$,cw))|0)+((8191&(eu=(eu=Math.imul(e$,ck))+Math.imul(eJ,cw)|0))<<13)|0;return eV=((ed=Math.imul(eJ,ck))+(eu>>>13)|0)+(cW>>>26)|0,cW&=67108863,ez[0]=cN,ez[1]=cS,ez[2]=cA,ez[3]=c_,ez[4]=cE,ez[5]=cP,ez[6]=cB,ez[7]=cT,ez[8]=cI,ez[9]=cR,ez[10]=cO,ez[11]=cj,ez[12]=cD,ez[13]=cF,ez[14]=cU,ez[15]=cq,ez[16]=cZ,ez[17]=cG,ez[18]=cW,0!==eV&&(ez[19]=eV,es.length++),es};function eN(et,ei,es){es.negative=ei.negative^et.negative,es.length=et.length+ei.length;for(var ef=0,eu=0,ed=0;ed>>26)|0)>>>26,em&=67108863}es.words[ed]=eH,ef=em,em=eu}return 0!==ef?es.words[ed]=ef:es.length--,es._strip()}function eS(et,ei,es){return eN(et,ei,es)}function eA(et,ei){this.x=et,this.y=ei}Math.imul||(ew=ex),ed.prototype.mulTo=function(et,ei){var es=this.length+et.length;return 10===this.length&&10===et.length?ew(this,et,ei):es<63?ex(this,et,ei):es<1024?eN(this,et,ei):eS(this,et,ei)},eA.prototype.makeRBT=function(et){for(var ei=Array(et),es=ed.prototype._countBits(et)-1,ef=0;ef>=1;return ef},eA.prototype.permute=function(et,ei,es,ef,eu,ed){for(var em=0;em>>=1)eu++;return 1<>>=13,es[2*em+1]=8191&ed,ed>>>=13;for(em=2*ei;em>=26,es+=(ed/67108864|0)+(em>>>26),this.words[eu]=67108863&em}return 0!==es&&(this.words[eu]=es,this.length++),ei?this.ineg():this},ed.prototype.muln=function(et){return this.clone().imuln(et)},ed.prototype.sqr=function(){return this.mul(this)},ed.prototype.isqr=function(){return this.imul(this.clone())},ed.prototype.pow=function(et){var ei=eC(et);if(0===ei.length)return new ed(1);for(var es=this,ef=0;ef=0);var ei,es=et%26,eu=(et-es)/26,ed=67108863>>>26-es<<26-es;if(0!==es){var em=0;for(ei=0;ei>>26-es}em&&(this.words[ei]=em,this.length++)}if(0!==eu){for(ei=this.length-1;ei>=0;ei--)this.words[ei+eu]=this.words[ei];for(ei=0;ei=0),eu=ei?(ei-ei%26)/26:0;var eu,ed=et%26,em=Math.min((et-ed)/26,this.length),eH=67108863^67108863>>>ed<em)for(this.length-=em,eV=0;eV=0&&(0!==eM||eV>=eu);eV--){var eg=0|this.words[eV];this.words[eV]=eM<<26-ed|eg>>>ed,eM=eg&eH}return ez&&0!==eM&&(ez.words[ez.length++]=eM),0===this.length&&(this.words[0]=0,this.length=1),this._strip()},ed.prototype.ishrn=function(et,ei,es){return ef(0===this.negative),this.iushrn(et,ei,es)},ed.prototype.shln=function(et){return this.clone().ishln(et)},ed.prototype.ushln=function(et){return this.clone().iushln(et)},ed.prototype.shrn=function(et){return this.clone().ishrn(et)},ed.prototype.ushrn=function(et){return this.clone().iushrn(et)},ed.prototype.testn=function(et){ef("number"==typeof et&&et>=0);var ei=et%26,es=(et-ei)/26,eu=1<=0);var ei=et%26,es=(et-ei)/26;if(ef(0===this.negative,"imaskn works only with positive numbers"),this.length<=es)return this;if(0!==ei&&es++,this.length=Math.min(es,this.length),0!==ei){var eu=67108863^67108863>>>ei<=67108864;ei++)this.words[ei]-=67108864,ei===this.length-1?this.words[ei+1]=1:this.words[ei+1]++;return this.length=Math.max(this.length,ei+1),this},ed.prototype.isubn=function(et){if(ef("number"==typeof et),ef(et<67108864),et<0)return this.iaddn(-et);if(0!==this.negative)return this.negative=0,this.iaddn(et),this.negative=1,this;if(this.words[0]-=et,1===this.length&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var ei=0;ei>26)-(ez/67108864|0),this.words[eu+es]=67108863&ed}for(;eu>26,this.words[eu+es]=67108863&ed;if(0===eH)return this._strip();for(ef(-1===eH),eH=0,eu=0;eu>26,this.words[eu]=67108863&ed;return this.negative=1,this._strip()},ed.prototype._wordDiv=function(et,ei){var es,ef=this.length-et.length,eu=this.clone(),em=et,eH=0|em.words[em.length-1];0!=(ef=26-this._countBits(eH))&&(em=em.ushln(ef),eu.iushln(ef),eH=0|em.words[em.length-1]);var ez=eu.length-em.length;if("mod"!==ei){(es=new ed(null)).length=ez+1,es.words=Array(es.length);for(var eV=0;eV=0;eg--){var eL=(0|eu.words[em.length+eg])*67108864+(0|eu.words[em.length+eg-1]);for(eL=Math.min(eL/eH|0,67108863),eu._ishlnsubmul(em,eL,eg);0!==eu.negative;)eL--,eu.negative=0,eu._ishlnsubmul(em,1,eg),eu.isZero()||(eu.negative^=1);es&&(es.words[eg]=eL)}return es&&es._strip(),eu._strip(),"div"!==ei&&0!==ef&&eu.iushrn(ef),{div:es||null,mod:eu}},ed.prototype.divmod=function(et,ei,es){var eu,em,eH;return(ef(!et.isZero()),this.isZero())?{div:new ed(0),mod:new ed(0)}:0!==this.negative&&0===et.negative?(eH=this.neg().divmod(et,ei),"mod"!==ei&&(eu=eH.div.neg()),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.iadd(et)),{div:eu,mod:em}):0===this.negative&&0!==et.negative?(eH=this.divmod(et.neg(),ei),"mod"!==ei&&(eu=eH.div.neg()),{div:eu,mod:eH.mod}):(this.negative&et.negative)!=0?(eH=this.neg().divmod(et.neg(),ei),"div"!==ei&&(em=eH.mod.neg(),es&&0!==em.negative&&em.isub(et)),{div:eH.div,mod:em}):et.length>this.length||0>this.cmp(et)?{div:new ed(0),mod:this}:1===et.length?"div"===ei?{div:this.divn(et.words[0]),mod:null}:"mod"===ei?{div:null,mod:new ed(this.modrn(et.words[0]))}:{div:this.divn(et.words[0]),mod:new ed(this.modrn(et.words[0]))}:this._wordDiv(et,ei)},ed.prototype.div=function(et){return this.divmod(et,"div",!1).div},ed.prototype.mod=function(et){return this.divmod(et,"mod",!1).mod},ed.prototype.umod=function(et){return this.divmod(et,"mod",!0).mod},ed.prototype.divRound=function(et){var ei=this.divmod(et);if(ei.mod.isZero())return ei.div;var es=0!==ei.div.negative?ei.mod.isub(et):ei.mod,ef=et.ushrn(1),eu=et.andln(1),ed=es.cmp(ef);return ed<0||1===eu&&0===ed?ei.div:0!==ei.div.negative?ei.div.isubn(1):ei.div.iaddn(1)},ed.prototype.modrn=function(et){var ei=et<0;ei&&(et=-et),ef(et<=67108863);for(var es=67108864%et,eu=0,ed=this.length-1;ed>=0;ed--)eu=(es*eu+(0|this.words[ed]))%et;return ei?-eu:eu},ed.prototype.modn=function(et){return this.modrn(et)},ed.prototype.idivn=function(et){var ei=et<0;ei&&(et=-et),ef(et<=67108863);for(var es=0,eu=this.length-1;eu>=0;eu--){var ed=(0|this.words[eu])+67108864*es;this.words[eu]=ed/et|0,es=ed%et}return this._strip(),ei?this.ineg():this},ed.prototype.divn=function(et){return this.clone().idivn(et)},ed.prototype.egcd=function(et){ef(0===et.negative),ef(!et.isZero());var ei=this,es=et.clone();ei=0!==ei.negative?ei.umod(et):ei.clone();for(var eu=new ed(1),em=new ed(0),eH=new ed(0),ez=new ed(1),eV=0;ei.isEven()&&es.isEven();)ei.iushrn(1),es.iushrn(1),++eV;for(var eM=es.clone(),eg=ei.clone();!ei.isZero();){for(var eL=0,eb=1;(ei.words[0]&eb)==0&&eL<26;++eL,eb<<=1);if(eL>0)for(ei.iushrn(eL);eL-- >0;)(eu.isOdd()||em.isOdd())&&(eu.iadd(eM),em.isub(eg)),eu.iushrn(1),em.iushrn(1);for(var ey=0,eC=1;(es.words[0]&eC)==0&&ey<26;++ey,eC<<=1);if(ey>0)for(es.iushrn(ey);ey-- >0;)(eH.isOdd()||ez.isOdd())&&(eH.iadd(eM),ez.isub(eg)),eH.iushrn(1),ez.iushrn(1);ei.cmp(es)>=0?(ei.isub(es),eu.isub(eH),em.isub(ez)):(es.isub(ei),eH.isub(eu),ez.isub(em))}return{a:eH,b:ez,gcd:es.iushln(eV)}},ed.prototype._invmp=function(et){ef(0===et.negative),ef(!et.isZero());var ei,es=this,eu=et.clone();es=0!==es.negative?es.umod(et):es.clone();for(var em=new ed(1),eH=new ed(0),ez=eu.clone();es.cmpn(1)>0&&eu.cmpn(1)>0;){for(var eV=0,eM=1;(es.words[0]&eM)==0&&eV<26;++eV,eM<<=1);if(eV>0)for(es.iushrn(eV);eV-- >0;)em.isOdd()&&em.iadd(ez),em.iushrn(1);for(var eg=0,eL=1;(eu.words[0]&eL)==0&&eg<26;++eg,eL<<=1);if(eg>0)for(eu.iushrn(eg);eg-- >0;)eH.isOdd()&&eH.iadd(ez),eH.iushrn(1);es.cmp(eu)>=0?(es.isub(eu),em.isub(eH)):(eu.isub(es),eH.isub(em))}return 0>(ei=0===es.cmpn(1)?em:eH).cmpn(0)&&ei.iadd(et),ei},ed.prototype.gcd=function(et){if(this.isZero())return et.abs();if(et.isZero())return this.abs();var ei=this.clone(),es=et.clone();ei.negative=0,es.negative=0;for(var ef=0;ei.isEven()&&es.isEven();ef++)ei.iushrn(1),es.iushrn(1);for(;;){for(;ei.isEven();)ei.iushrn(1);for(;es.isEven();)es.iushrn(1);var eu=ei.cmp(es);if(eu<0){var ed=ei;ei=es,es=ed}else if(0===eu||0===es.cmpn(1))break;ei.isub(es)}return es.iushln(ef)},ed.prototype.invm=function(et){return this.egcd(et).a.umod(et)},ed.prototype.isEven=function(){return(1&this.words[0])==0},ed.prototype.isOdd=function(){return(1&this.words[0])==1},ed.prototype.andln=function(et){return this.words[0]&et},ed.prototype.bincn=function(et){ef("number"==typeof et);var ei=et%26,es=(et-ei)/26,eu=1<>>26,eH&=67108863,this.words[em]=eH}return 0!==ed&&(this.words[em]=ed,this.length++),this},ed.prototype.isZero=function(){return 1===this.length&&0===this.words[0]},ed.prototype.cmpn=function(et){var ei,es=et<0;if(0!==this.negative&&!es)return -1;if(0===this.negative&&es)return 1;if(this._strip(),this.length>1)ei=1;else{es&&(et=-et),ef(et<=67108863,"Number is too big");var eu=0|this.words[0];ei=eu===et?0:euet.length)return 1;if(this.length=0;es--){var ef=0|this.words[es],eu=0|et.words[es];if(ef!==eu){efeu&&(ei=1);break}}return ei},ed.prototype.gtn=function(et){return 1===this.cmpn(et)},ed.prototype.gt=function(et){return 1===this.cmp(et)},ed.prototype.gten=function(et){return this.cmpn(et)>=0},ed.prototype.gte=function(et){return this.cmp(et)>=0},ed.prototype.ltn=function(et){return -1===this.cmpn(et)},ed.prototype.lt=function(et){return -1===this.cmp(et)},ed.prototype.lten=function(et){return 0>=this.cmpn(et)},ed.prototype.lte=function(et){return 0>=this.cmp(et)},ed.prototype.eqn=function(et){return 0===this.cmpn(et)},ed.prototype.eq=function(et){return 0===this.cmp(et)},ed.red=function(et){return new eR(et)},ed.prototype.toRed=function(et){return ef(!this.red,"Already a number in reduction context"),ef(0===this.negative,"red works only with positives"),et.convertTo(this)._forceRed(et)},ed.prototype.fromRed=function(){return ef(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},ed.prototype._forceRed=function(et){return this.red=et,this},ed.prototype.forceRed=function(et){return ef(!this.red,"Already a number in reduction context"),this._forceRed(et)},ed.prototype.redAdd=function(et){return ef(this.red,"redAdd works only with red numbers"),this.red.add(this,et)},ed.prototype.redIAdd=function(et){return ef(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,et)},ed.prototype.redSub=function(et){return ef(this.red,"redSub works only with red numbers"),this.red.sub(this,et)},ed.prototype.redISub=function(et){return ef(this.red,"redISub works only with red numbers"),this.red.isub(this,et)},ed.prototype.redShl=function(et){return ef(this.red,"redShl works only with red numbers"),this.red.shl(this,et)},ed.prototype.redMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.mul(this,et)},ed.prototype.redIMul=function(et){return ef(this.red,"redMul works only with red numbers"),this.red._verify2(this,et),this.red.imul(this,et)},ed.prototype.redSqr=function(){return ef(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},ed.prototype.redISqr=function(){return ef(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},ed.prototype.redSqrt=function(){return ef(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},ed.prototype.redInvm=function(){return ef(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},ed.prototype.redNeg=function(){return ef(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},ed.prototype.redPow=function(et){return ef(this.red&&!et.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,et)};var e_={k256:null,p224:null,p192:null,p25519:null};function eE(et,ei){this.name=et,this.p=new ed(ei,16),this.n=this.p.bitLength(),this.k=new ed(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}function eP(){eE.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}function eB(){eE.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}function eT(){eE.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}function eI(){eE.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}function eR(et){if("string"==typeof et){var ei=ed._prime(et);this.m=ei.p,this.prime=ei}else ef(et.gtn(1),"modulus must be greater than 1"),this.m=et,this.prime=null}function eO(et){eR.call(this,et),this.shift=this.m.bitLength(),this.shift%26!=0&&(this.shift+=26-this.shift%26),this.r=new ed(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)}eE.prototype._tmp=function(){var et=new ed(null);return et.words=Array(Math.ceil(this.n/13)),et},eE.prototype.ireduce=function(et){var ei,es=et;do this.split(es,this.tmp),ei=(es=(es=this.imulK(es)).iadd(this.tmp)).bitLength();while(ei>this.n);var ef=ei0?es.isub(this.p):void 0!==es.strip?es.strip():es._strip(),es},eE.prototype.split=function(et,ei){et.iushrn(this.n,0,ei)},eE.prototype.imulK=function(et){return et.imul(this.k)},eu(eP,eE),eP.prototype.split=function(et,ei){for(var es=4194303,ef=Math.min(et.length,9),eu=0;eu>>22,ed=em}ed>>>=22,et.words[eu-10]=ed,0===ed&&et.length>10?et.length-=10:et.length-=9},eP.prototype.imulK=function(et){et.words[et.length]=0,et.words[et.length+1]=0,et.length+=2;for(var ei=0,es=0;es>>=26,et.words[es]=eu,ei=ef}return 0!==ei&&(et.words[et.length++]=ei),et},ed._prime=function(et){var ei;if(e_[et])return e_[et];if("k256"===et)ei=new eP;else if("p224"===et)ei=new eB;else if("p192"===et)ei=new eT;else if("p25519"===et)ei=new eI;else throw Error("Unknown prime "+et);return e_[et]=ei,ei},eR.prototype._verify1=function(et){ef(0===et.negative,"red works only with positives"),ef(et.red,"red works only with red numbers")},eR.prototype._verify2=function(et,ei){ef((et.negative|ei.negative)==0,"red works only with positives"),ef(et.red&&et.red===ei.red,"red works only with red numbers")},eR.prototype.imod=function(et){return this.prime?this.prime.ireduce(et)._forceRed(this):(ez(et,et.umod(this.m)._forceRed(this)),et)},eR.prototype.neg=function(et){return et.isZero()?et.clone():this.m.sub(et)._forceRed(this)},eR.prototype.add=function(et,ei){this._verify2(et,ei);var es=et.add(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es._forceRed(this)},eR.prototype.iadd=function(et,ei){this._verify2(et,ei);var es=et.iadd(ei);return es.cmp(this.m)>=0&&es.isub(this.m),es},eR.prototype.sub=function(et,ei){this._verify2(et,ei);var es=et.sub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es._forceRed(this)},eR.prototype.isub=function(et,ei){this._verify2(et,ei);var es=et.isub(ei);return 0>es.cmpn(0)&&es.iadd(this.m),es},eR.prototype.shl=function(et,ei){return this._verify1(et),this.imod(et.ushln(ei))},eR.prototype.imul=function(et,ei){return this._verify2(et,ei),this.imod(et.imul(ei))},eR.prototype.mul=function(et,ei){return this._verify2(et,ei),this.imod(et.mul(ei))},eR.prototype.isqr=function(et){return this.imul(et,et.clone())},eR.prototype.sqr=function(et){return this.mul(et,et)},eR.prototype.sqrt=function(et){if(et.isZero())return et.clone();var ei=this.m.andln(3);if(ef(ei%2==1),3===ei){var es=this.m.add(new ed(1)).iushrn(2);return this.pow(et,es)}for(var eu=this.m.subn(1),em=0;!eu.isZero()&&0===eu.andln(1);)em++,eu.iushrn(1);ef(!eu.isZero());var eH=new ed(1).toRed(this),ez=eH.redNeg(),eV=this.m.subn(1).iushrn(1),eM=this.m.bitLength();for(eM=new ed(2*eM*eM).toRed(this);0!==this.pow(eM,eV).cmp(ez);)eM.redIAdd(ez);for(var eg=this.pow(eM,eu),eL=this.pow(et,eu.addn(1).iushrn(1)),eb=this.pow(et,eu),ey=em;0!==eb.cmp(eH);){for(var eC=eb,ex=0;0!==eC.cmp(eH);ex++)eC=eC.redSqr();ef(ex=0;eu--){for(var eM=ei.words[eu],eg=eV-1;eg>=0;eg--){var eL=eM>>eg&1;if(em!==ef[0]&&(em=this.sqr(em)),0===eL&&0===eH){ez=0;continue}eH<<=1,eH|=eL,(++ez===es||0===eu&&0===eg)&&(em=this.mul(em,ef[eH]),ez=0,eH=0)}eV=26}return em},eR.prototype.convertTo=function(et){var ei=et.umod(this.m);return ei===et?ei.clone():ei},eR.prototype.convertFrom=function(et){var ei=et.clone();return ei.red=null,ei},ed.mont=function(et){return new eO(et)},eu(eO,eR),eO.prototype.convertTo=function(et){return this.imod(et.ushln(this.shift))},eO.prototype.convertFrom=function(et){var ei=this.imod(et.mul(this.rinv));return ei.red=null,ei},eO.prototype.imul=function(et,ei){if(et.isZero()||ei.isZero())return et.words[0]=0,et.length=1,et;var es=et.imul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),ed=eu;return eu.cmp(this.m)>=0?ed=eu.isub(this.m):0>eu.cmpn(0)&&(ed=eu.iadd(this.m)),ed._forceRed(this)},eO.prototype.mul=function(et,ei){if(et.isZero()||ei.isZero())return new ed(0)._forceRed(this);var es=et.mul(ei),ef=es.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),eu=es.isub(ef).iushrn(this.shift),em=eu;return eu.cmp(this.m)>=0?em=eu.isub(this.m):0>eu.cmpn(0)&&(em=eu.iadd(this.m)),em._forceRed(this)},eO.prototype.invm=function(et){return this.imod(et._invmp(this.m).mul(this.r2))._forceRed(this)}}(et=es.nmd(et),this)},3500:function(et,ei,es){var ef;function eu(et){this.rand=et}if(et.exports=function(et){return ef||(ef=new eu(null)),ef.generate(et)},et.exports.Rand=eu,eu.prototype.generate=function(et){return this._rand(et)},eu.prototype._rand=function(et){if(this.rand.getBytes)return this.rand.getBytes(et);for(var ei=new Uint8Array(et),es=0;es>>24]^eM[ey>>>16&255]^eg[eC>>>8&255]^eL[255&ex]^ei[ew++],em=eV[ey>>>24]^eM[eC>>>16&255]^eg[ex>>>8&255]^eL[255&eb]^ei[ew++],eH=eV[eC>>>24]^eM[ex>>>16&255]^eg[eb>>>8&255]^eL[255&ey]^ei[ew++],ez=eV[ex>>>24]^eM[eb>>>16&255]^eg[ey>>>8&255]^eL[255&eC]^ei[ew++],eb=ed,ey=em,eC=eH,ex=ez;return ed=(ef[eb>>>24]<<24|ef[ey>>>16&255]<<16|ef[eC>>>8&255]<<8|ef[255&ex])^ei[ew++],em=(ef[ey>>>24]<<24|ef[eC>>>16&255]<<16|ef[ex>>>8&255]<<8|ef[255&eb])^ei[ew++],[ed>>>=0,em>>>=0,eH=((ef[eC>>>24]<<24|ef[ex>>>16&255]<<16|ef[eb>>>8&255]<<8|ef[255&ey])^ei[ew++])>>>0,ez=((ef[ex>>>24]<<24|ef[eb>>>16&255]<<16|ef[ey>>>8&255]<<8|ef[255&eC])^ei[ew++])>>>0]}var eH=[0,1,2,4,8,16,32,64,128,27,54],ez=function(){for(var et=Array(256),ei=0;ei<256;ei++)ei<128?et[ei]=ei<<1:et[ei]=ei<<1^283;for(var es=[],ef=[],eu=[[],[],[],[]],ed=[[],[],[],[]],em=0,eH=0,ez=0;ez<256;++ez){var eV=eH^eH<<1^eH<<2^eH<<3^eH<<4;eV=eV>>>8^255&eV^99,es[em]=eV,ef[eV]=em;var eM=et[em],eg=et[eM],eL=et[eg],eb=257*et[eV]^16843008*eV;eu[0][em]=eb<<24|eb>>>8,eu[1][em]=eb<<16|eb>>>16,eu[2][em]=eb<<8|eb>>>24,eu[3][em]=eb,eb=16843009*eL^65537*eg^257*eM^16843008*em,ed[0][eV]=eb<<24|eb>>>8,ed[1][eV]=eb<<16|eb>>>16,ed[2][eV]=eb<<8|eb>>>24,ed[3][eV]=eb,0===em?em=eH=1:(em=eM^et[et[et[eL^eM]]],eH^=et[et[eH]])}return{SBOX:es,INV_SBOX:ef,SUB_MIX:eu,INV_SUB_MIX:ed}}();function eV(et){this._key=eu(et),this._reset()}eV.blockSize=16,eV.keySize=32,eV.prototype.blockSize=eV.blockSize,eV.prototype.keySize=eV.keySize,eV.prototype._reset=function(){for(var et=this._key,ei=et.length,es=ei+6,ef=(es+1)*4,eu=[],ed=0;ed>>24,em=(ez.SBOX[em>>>24]<<24|ez.SBOX[em>>>16&255]<<16|ez.SBOX[em>>>8&255]<<8|ez.SBOX[255&em])^eH[ed/ei|0]<<24):ei>6&&ed%ei==4&&(em=ez.SBOX[em>>>24]<<24|ez.SBOX[em>>>16&255]<<16|ez.SBOX[em>>>8&255]<<8|ez.SBOX[255&em]),eu[ed]=eu[ed-ei]^em}for(var eV=[],eM=0;eM>>24]]^ez.INV_SUB_MIX[1][ez.SBOX[eL>>>16&255]]^ez.INV_SUB_MIX[2][ez.SBOX[eL>>>8&255]]^ez.INV_SUB_MIX[3][ez.SBOX[255&eL]]}this._nRounds=es,this._keySchedule=eu,this._invKeySchedule=eV},eV.prototype.encryptBlockRaw=function(et){return em(et=eu(et),this._keySchedule,ez.SUB_MIX,ez.SBOX,this._nRounds)},eV.prototype.encryptBlock=function(et){var ei=this.encryptBlockRaw(et),es=ef.allocUnsafe(16);return es.writeUInt32BE(ei[0],0),es.writeUInt32BE(ei[1],4),es.writeUInt32BE(ei[2],8),es.writeUInt32BE(ei[3],12),es},eV.prototype.decryptBlock=function(et){var ei=(et=eu(et))[1];et[1]=et[3],et[3]=ei;var es=em(et,this._invKeySchedule,ez.INV_SUB_MIX,ez.INV_SBOX,this._nRounds),ed=ef.allocUnsafe(16);return ed.writeUInt32BE(es[0],0),ed.writeUInt32BE(es[3],4),ed.writeUInt32BE(es[2],8),ed.writeUInt32BE(es[1],12),ed},eV.prototype.scrub=function(){ed(this._keySchedule),ed(this._invKeySchedule),ed(this._key)},et.exports.AES=eV},6624:function(et,ei,es){var ef=es(1387),eu=es(6911).Buffer,ed=es(1043),em=es(3782),eH=es(7225),ez=es(4734),eV=es(598);function eM(et,ei){var es=0;et.length!==ei.length&&es++;for(var ef=Math.min(et.length,ei.length),eu=0;eu16)throw Error("unable to decrypt data");for(var es=-1;++es16)return ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),ei}else if(this.cache.length>=16)return ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),ei;return null},eg.prototype.flush=function(){if(this.cache.length)return this.cache},ei.createDecipher=ey,ei.createDecipheriv=eb},2:function(et,ei,es){var ef=es(6370),eu=es(6624),ed=es(6911).Buffer,em=es(126),eH=es(1043),ez=es(1387),eV=es(8368);function eM(et,ei,es){eH.call(this),this._cache=new eL,this._cipher=new ez.AES(ei),this._prev=ed.from(es),this._mode=et,this._autopadding=!0}es(3782)(eM,eH),eM.prototype._update=function(et){this._cache.add(et);for(var ei,es,ef=[];ei=this._cache.get();)es=this._mode.encrypt(this,ei),ef.push(es);return ed.concat(ef)};var eg=ed.alloc(16,16);function eL(){this.cache=ed.allocUnsafe(0)}function eb(et,ei,es){var eH=ef[et.toLowerCase()];if(!eH)throw TypeError("invalid suite type");if("string"==typeof ei&&(ei=ed.from(ei)),ei.length!==eH.key/8)throw TypeError("invalid key length "+ei.length);if("string"==typeof es&&(es=ed.from(es)),"GCM"!==eH.mode&&es.length!==eH.iv)throw TypeError("invalid iv length "+es.length);return"stream"===eH.type?new em(eH.module,ei,es):"auth"===eH.type?new eu(eH.module,ei,es):new eM(eH.module,ei,es)}function ey(et,ei){var es=ef[et.toLowerCase()];if(!es)throw TypeError("invalid suite type");var eu=eV(ei,!1,es.key,es.iv);return eb(et,eu.key,eu.iv)}eM.prototype._final=function(){var et=this._cache.flush();if(this._autopadding)return et=this._mode.encrypt(this,et),this._cipher.scrub(),et;if(!et.equals(eg))throw this._cipher.scrub(),Error("data not multiple of block length")},eM.prototype.setAutoPadding=function(et){return this._autopadding=!!et,this},eL.prototype.add=function(et){this.cache=ed.concat([this.cache,et])},eL.prototype.get=function(){if(this.cache.length>15){var et=this.cache.slice(0,16);return this.cache=this.cache.slice(16),et}return null},eL.prototype.flush=function(){for(var et=16-this.cache.length,ei=ed.allocUnsafe(et),es=-1;++es>>0,0),ei.writeUInt32BE(et[1]>>>0,4),ei.writeUInt32BE(et[2]>>>0,8),ei.writeUInt32BE(et[3]>>>0,12),ei}function eH(et){this.h=et,this.state=ef.alloc(16,0),this.cache=ef.allocUnsafe(0)}eH.prototype.ghash=function(et){for(var ei=-1;++ei0;et--)es[et]=es[et]>>>1|(1&es[et-1])<<31;es[0]=es[0]>>>1,ei&&(es[0]=-520093696^es[0])}this.state=em(ef)},eH.prototype.update=function(et){var ei;for(this.cache=ef.concat([this.cache,et]);this.cache.length>=16;)ei=this.cache.slice(0,16),this.cache=this.cache.slice(16),this.ghash(ei)},eH.prototype.final=function(et,ei){return this.cache.length&&this.ghash(ef.concat([this.cache,eu],16)),this.ghash(em([0,et,0,ei])),this.state},et.exports=eH},598:function(et){function ei(et){for(var ei,es=et.length;es--;)if(255===(ei=et.readUInt8(es)))et.writeUInt8(0,es);else{ei++,et.writeUInt8(ei,es);break}}et.exports=ei},9825:function(et,ei,es){var ef=es(4734);ei.encrypt=function(et,ei){var es=ef(ei,et._prev);return et._prev=et._cipher.encryptBlock(es),et._prev},ei.decrypt=function(et,ei){var es=et._prev;return et._prev=ei,ef(et._cipher.decryptBlock(ei),es)}},321:function(et,ei,es){var ef=es(6911).Buffer,eu=es(4734);function ed(et,ei,es){var ed=ei.length,em=eu(ei,et._cache);return et._cache=et._cache.slice(ed),et._prev=ef.concat([et._prev,es?ei:em]),em}ei.encrypt=function(et,ei,es){for(var eu,em=ef.allocUnsafe(0);ei.length;)if(0===et._cache.length&&(et._cache=et._cipher.encryptBlock(et._prev),et._prev=ef.allocUnsafe(0)),et._cache.length<=ei.length)eu=et._cache.length,em=ef.concat([em,ed(et,ei.slice(0,eu),es)]),ei=ei.slice(eu);else{em=ef.concat([em,ed(et,ei,es)]);break}return em}},3147:function(et,ei,es){var ef=es(6911).Buffer;function eu(et,ei,es){for(var ef,eu,em,eH=-1,ez=8,eV=0;++eH>eH%8,et._prev=ed(et._prev,es?eu:em);return eV}function ed(et,ei){var es=et.length,eu=-1,ed=ef.allocUnsafe(et.length);for(et=ef.concat([et,ef.from([ei])]);++eu>7;return ed}ei.encrypt=function(et,ei,es){for(var ed=ei.length,em=ef.allocUnsafe(ed),eH=-1;++eH=0||!es.umod(et.prime1)||!es.umod(et.prime2);)es=new ef(ed(ei));return es}et.exports=eH,eH.getr=ez},9276:function(et,ei,es){et.exports=es(2908)},4078:function(et,ei,es){var ef=es(6911).Buffer,eu=es(9739),ed=es(3726),em=es(3782),eH=es(9807),ez=es(4013),eV=es(2908);function eM(et){ed.Writable.call(this);var ei=eV[et];if(!ei)throw Error("Unknown message digest");this._hashType=ei.hash,this._hash=eu(ei.hash),this._tag=ei.id,this._signType=ei.sign}function eg(et){ed.Writable.call(this);var ei=eV[et];if(!ei)throw Error("Unknown message digest");this._hash=eu(ei.hash),this._tag=ei.id,this._signType=ei.sign}function eL(et){return new eM(et)}function eb(et){return new eg(et)}Object.keys(eV).forEach(function(et){eV[et].id=ef.from(eV[et].id,"hex"),eV[et.toLowerCase()]=eV[et]}),em(eM,ed.Writable),eM.prototype._write=function(et,ei,es){this._hash.update(et),es()},eM.prototype.update=function(et,ei){return"string"==typeof et&&(et=ef.from(et,ei)),this._hash.update(et),this},eM.prototype.sign=function(et,ei){this.end();var es=eH(this._hash.digest(),et,this._hashType,this._signType,this._tag);return ei?es.toString(ei):es},em(eg,ed.Writable),eg.prototype._write=function(et,ei,es){this._hash.update(et),es()},eg.prototype.update=function(et,ei){return"string"==typeof et&&(et=ef.from(et,ei)),this._hash.update(et),this},eg.prototype.verify=function(et,ei,es){return"string"==typeof ei&&(ei=ef.from(ei,es)),this.end(),ez(ei,this._hash.digest(),et,this._signType,this._tag)},et.exports={Sign:eL,Verify:eb,createSign:eL,createVerify:eb}},9807:function(et,ei,es){var ef=es(6911).Buffer,eu=es(4873),ed=es(7166),em=es(949).ec,eH=es(1670),ez=es(9902),eV=es(9267);function eM(et,ei,es,eu,em){var eH=ez(ei);if(eH.curve){if("ecdsa"!==eu&&"ecdsa/rsa"!==eu)throw Error("wrong private key type");return eg(et,eH)}if("dsa"===eH.type){if("dsa"!==eu)throw Error("wrong private key type");return eL(et,eH,es)}if("rsa"!==eu&&"ecdsa/rsa"!==eu)throw Error("wrong private key type");et=ef.concat([em,et]);for(var eV=eH.modulus.byteLength(),eM=[0,1];et.length+eM.length+10&&es.ishrn(ef),es}function ex(et,ei){et=(et=eC(et,ei)).mod(ei);var es=ef.from(et.toArray());if(es.length=et.cmpn(0)||et.cmp(ei)>=ei)throw Error("invalid sig")}et.exports=ez},4734:function(et){et.exports=function(et,ei){for(var es=Math.min(et.length,ei.length),ef=new eu(es),ed=0;edes?ei=("rmd160"===et?new ez:eV(et)).update(ei).digest():ei.lengtheH?ei=et(ei):ei.length0;ef--)ei+=this._buffer(et,ei),es+=this._flushBuffer(eu,es);return ei+=this._buffer(et,ei),eu},eu.prototype.final=function(et){var ei,es;return(et&&(ei=this.update(et)),es="encrypt"===this.type?this._finalEncrypt():this._finalDecrypt(),ei)?ei.concat(es):es},eu.prototype._pad=function(et,ei){if(0===ei)return!1;for(;ei>>1];es=ed.r28shl(es,eH),eu=ed.r28shl(eu,eH),ed.pc2(es,eu,et.keys,em)}},ez.prototype._update=function(et,ei,es,ef){var eu=this._desState,em=ed.readUInt32BE(et,ei),eH=ed.readUInt32BE(et,ei+4);ed.ip(em,eH,eu.tmp,0),em=eu.tmp[0],eH=eu.tmp[1],"encrypt"===this.type?this._encrypt(eu,em,eH,eu.tmp,0):this._decrypt(eu,em,eH,eu.tmp,0),em=eu.tmp[0],eH=eu.tmp[1],ed.writeUInt32BE(es,em,ef),ed.writeUInt32BE(es,eH,ef+4)},ez.prototype._pad=function(et,ei){for(var es=et.length-ei,ef=ei;ef>>0,em=eb}ed.rip(eH,em,ef,eu)},ez.prototype._decrypt=function(et,ei,es,ef,eu){for(var em=es,eH=ei,ez=et.keys.length-2;ez>=0;ez-=2){var eV=et.keys[ez],eM=et.keys[ez+1];ed.expand(em,et.tmp,0),eV^=et.tmp[0],eM^=et.tmp[1];var eg=ed.substitute(eV,eM),eL=ed.permute(eg),eb=em;em=(eH^eL)>>>0,eH=eb}ed.rip(em,eH,ef,eu)}},6159:function(et,ei,es){"use strict";var ef=es(3523),eu=es(3782),ed=es(9876),em=es(1016);function eH(et,ei){ef.equal(ei.length,24,"Invalid key length");var es=ei.slice(0,8),eu=ei.slice(8,16),ed=ei.slice(16,24);"encrypt"===et?this.ciphers=[em.create({type:"encrypt",key:es}),em.create({type:"decrypt",key:eu}),em.create({type:"encrypt",key:ed})]:this.ciphers=[em.create({type:"decrypt",key:ed}),em.create({type:"encrypt",key:eu}),em.create({type:"decrypt",key:es})]}function ez(et){ed.call(this,et);var ei=new eH(this.type,this.options.key);this._edeState=ei}eu(ez,ed),et.exports=ez,ez.create=function(et){return new ez(et)},ez.prototype._update=function(et,ei,es,ef){var eu=this._edeState;eu.ciphers[0]._update(et,ei,es,ef),eu.ciphers[1]._update(es,ef,es,ef),eu.ciphers[2]._update(es,ef,es,ef)},ez.prototype._pad=em.prototype._pad,ez.prototype._unpad=em.prototype._unpad},5334:function(et,ei){"use strict";ei.readUInt32BE=function(et,ei){return(et[0+ei]<<24|et[1+ei]<<16|et[2+ei]<<8|et[3+ei])>>>0},ei.writeUInt32BE=function(et,ei,es){et[0+es]=ei>>>24,et[1+es]=ei>>>16&255,et[2+es]=ei>>>8&255,et[3+es]=255&ei},ei.ip=function(et,ei,es,ef){for(var eu=0,ed=0,em=6;em>=0;em-=2){for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>>eH+em&1;for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=et>>>eH+em&1}for(var em=6;em>=0;em-=2){for(var eH=1;eH<=25;eH+=8)ed<<=1,ed|=ei>>>eH+em&1;for(var eH=1;eH<=25;eH+=8)ed<<=1,ed|=et>>>eH+em&1}es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.rip=function(et,ei,es,ef){for(var eu=0,ed=0,em=0;em<4;em++)for(var eH=24;eH>=0;eH-=8)eu<<=1,eu|=ei>>>eH+em&1,eu<<=1,eu|=et>>>eH+em&1;for(var em=4;em<8;em++)for(var eH=24;eH>=0;eH-=8)ed<<=1,ed|=ei>>>eH+em&1,ed<<=1,ed|=et>>>eH+em&1;es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.pc1=function(et,ei,es,ef){for(var eu=0,ed=0,em=7;em>=5;em--){for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>eH+em&1;for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=et>>eH+em&1}for(var eH=0;eH<=24;eH+=8)eu<<=1,eu|=ei>>eH+em&1;for(var em=1;em<=3;em++){for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=ei>>eH+em&1;for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=et>>eH+em&1}for(var eH=0;eH<=24;eH+=8)ed<<=1,ed|=et>>eH+em&1;es[ef+0]=eu>>>0,es[ef+1]=ed>>>0},ei.r28shl=function(et,ei){return et<>>28-ei};var es=[14,11,17,4,27,23,25,0,13,22,7,18,5,9,16,24,2,20,12,21,1,8,15,26,15,4,25,19,9,1,26,16,5,11,23,8,12,7,17,0,22,3,10,14,6,20,27,24];ei.pc2=function(et,ei,ef,eu){for(var ed=0,em=0,eH=es.length>>>1,ez=0;ez>>es[ez]&1;for(var ez=eH;ez>>es[ez]&1;ef[eu+0]=ed>>>0,ef[eu+1]=em>>>0},ei.expand=function(et,ei,es){var ef=0,eu=0;ef=(1&et)<<5|et>>>27;for(var ed=23;ed>=15;ed-=4)ef<<=6,ef|=et>>>ed&63;for(var ed=11;ed>=3;ed-=4)eu|=et>>>ed&63,eu<<=6;eu|=(31&et)<<1|et>>>31,ei[es+0]=ef>>>0,ei[es+1]=eu>>>0};var ef=[14,0,4,15,13,7,1,4,2,14,15,2,11,13,8,1,3,10,10,6,6,12,12,11,5,9,9,5,0,3,7,8,4,15,1,12,14,8,8,2,13,4,6,9,2,1,11,7,15,5,12,11,9,3,7,14,3,10,10,0,5,6,0,13,15,3,1,13,8,4,14,7,6,15,11,2,3,8,4,14,9,12,7,0,2,1,13,10,12,6,0,9,5,11,10,5,0,13,14,8,7,10,11,1,10,3,4,15,13,4,1,2,5,11,8,6,12,7,6,12,9,0,3,5,2,14,15,9,10,13,0,7,9,0,14,9,6,3,3,4,15,6,5,10,1,2,13,8,12,5,7,14,11,12,4,11,2,15,8,1,13,1,6,10,4,13,9,0,8,6,15,9,3,8,0,7,11,4,1,15,2,14,12,3,5,11,10,5,14,2,7,12,7,13,13,8,14,11,3,5,0,6,6,15,9,0,10,3,1,4,2,7,8,2,5,12,11,1,12,10,4,14,15,9,10,3,6,15,9,0,0,6,12,10,11,1,7,13,13,8,15,9,1,4,3,5,14,11,5,12,2,7,8,2,4,14,2,14,12,11,4,2,1,12,7,4,10,7,11,13,6,1,8,5,5,0,3,15,15,10,13,3,0,9,14,8,9,6,4,11,2,8,1,12,11,7,10,1,13,14,7,2,8,13,15,6,9,15,12,0,5,9,6,10,3,4,0,5,14,3,12,10,1,15,10,4,15,2,9,7,2,12,6,9,8,5,0,6,13,1,3,13,4,14,14,0,7,11,5,3,11,8,9,4,14,3,15,2,5,12,2,9,8,5,12,15,3,10,7,11,0,14,4,1,10,7,1,6,13,0,11,8,6,13,4,13,11,0,2,11,14,7,15,4,0,9,8,1,13,10,3,14,12,3,9,5,7,12,5,2,10,15,6,8,1,6,1,6,4,11,11,13,13,8,12,1,3,4,7,10,14,7,10,9,15,5,6,0,8,15,0,14,5,2,9,3,2,12,13,1,2,15,8,13,4,8,6,10,15,3,11,7,1,4,10,12,9,5,3,6,14,11,5,0,0,14,12,9,7,2,7,2,11,1,4,14,1,7,9,4,12,10,14,8,2,13,0,15,6,12,10,9,13,0,15,3,3,5,5,6,8,11];ei.substitute=function(et,ei){for(var es=0,eu=0;eu<4;eu++){var ed=et>>>18-6*eu&63,em=ef[64*eu+ed];es<<=4,es|=em}for(var eu=0;eu<4;eu++){var ed=ei>>>18-6*eu&63,em=ef[256+64*eu+ed];es<<=4,es|=em}return es>>>0};var eu=[16,25,12,11,3,20,4,15,31,17,9,6,27,14,1,22,30,24,8,18,0,5,29,23,13,19,2,26,10,21,28,7];ei.permute=function(et){for(var ei=0,es=0;es>>eu[es]&1;return ei>>>0},ei.padSplit=function(et,ei,es){for(var ef=et.toString(2);ef.lengthet;)es.ishrn(1);if(es.isEven()&&es.iadd(eH),es.testn(1)||es.iadd(ez),ei.cmp(ez)){if(!ei.cmp(eV))for(;es.mod(eM).cmp(eg);)es.iadd(eb)}else for(;es.mod(ed).cmp(eL);)es.iadd(eb);if(ex(ey=es.shrn(1))&&ex(es)&&ew(ey)&&ew(es)&&em.test(ey)&&em.test(es))return es}}},949:function(et,ei,es){"use strict";var ef=ei;ef.version=es(2531).i8,ef.utils=es(4401),ef.rand=es(3500),ef.curve=es(9359),ef.curves=es(6226),ef.ec=es(4088),ef.eddsa=es(8511)},2727:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401),ed=eu.getNAF,em=eu.getJSF,eH=eu.assert;function ez(et,ei){this.type=et,this.p=new ef(ei.p,16),this.red=ei.prime?ef.red(ei.prime):ef.mont(this.p),this.zero=new ef(0).toRed(this.red),this.one=new ef(1).toRed(this.red),this.two=new ef(2).toRed(this.red),this.n=ei.n&&new ef(ei.n,16),this.g=ei.g&&this.pointFromJSON(ei.g,ei.gRed),this._wnafT1=[,,,,],this._wnafT2=[,,,,],this._wnafT3=[,,,,],this._wnafT4=[,,,,],this._bitLength=this.n?this.n.bitLength():0;var es=this.n&&this.p.div(this.n);!es||es.cmpn(100)>0?this.redN=null:(this._maxwellTrick=!0,this.redN=this.n.toRed(this.red))}function eV(et,ei){this.curve=et,this.type=ei,this.precomputed=null}et.exports=ez,ez.prototype.point=function(){throw Error("Not implemented")},ez.prototype.validate=function(){throw Error("Not implemented")},ez.prototype._fixedNafMul=function(et,ei){eH(et.precomputed);var es=et._getDoubles(),ef=ed(ei,1,this._bitLength),eu=(1<=ez;ei--)eV=(eV<<1)+ef[ei];em.push(eV)}for(var eM=this.jpoint(null,null,null),eg=this.jpoint(null,null,null),eL=eu;eL>0;eL--){for(var ez=0;ez=0;eV--){for(var ei=0;eV>=0&&0===em[eV];eV--)ei++;if(eV>=0&&ei++,ez=ez.dblp(ei),eV<0)break;var eM=em[eV];eH(0!==eM),ez="affine"===et.type?eM>0?ez.mixedAdd(eu[eM-1>>1]):ez.mixedAdd(eu[-eM-1>>1].neg()):eM>0?ez.add(eu[eM-1>>1]):ez.add(eu[-eM-1>>1].neg())}return"affine"===et.type?ez.toP():ez},ez.prototype._wnafMulAdd=function(et,ei,es,ef,eu){for(var eH=this._wnafT1,ez=this._wnafT2,eV=this._wnafT3,eM=0,eg=0;eg=1;eg-=2){var ey=eg-1,eC=eg;if(1!==eH[ey]||1!==eH[eC]){eV[ey]=ed(es[ey],eH[ey],this._bitLength),eV[eC]=ed(es[eC],eH[eC],this._bitLength),eM=Math.max(eV[ey].length,eM),eM=Math.max(eV[eC].length,eM);continue}var ex=[ei[ey],null,null,ei[eC]];0===ei[ey].y.cmp(ei[eC].y)?(ex[1]=ei[ey].add(ei[eC]),ex[2]=ei[ey].toJ().mixedAdd(ei[eC].neg())):0===ei[ey].y.cmp(ei[eC].y.redNeg())?(ex[1]=ei[ey].toJ().mixedAdd(ei[eC]),ex[2]=ei[ey].add(ei[eC].neg())):(ex[1]=ei[ey].toJ().mixedAdd(ei[eC]),ex[2]=ei[ey].toJ().mixedAdd(ei[eC].neg()));var ew=[-3,-1,-5,-7,0,7,5,1,3],eN=em(es[ey],es[eC]);eM=Math.max(eN[0].length,eM),eV[ey]=Array(eM),eV[eC]=Array(eM);for(var eS=0;eS=0;eg--){for(var eB=0;eg>=0;){for(var eT=!0,eS=0;eS=0&&eB++,eE=eE.dblp(eB),eg<0)break;for(var eS=0;eS0?eL=ez[eS][eI-1>>1]:eI<0&&(eL=ez[eS][-eI-1>>1].neg()),eE="affine"===eL.type?eE.mixedAdd(eL):eE.add(eL))}}for(var eg=0;eg=Math.ceil((et.bitLength()+1)/ei.step)},eV.prototype._getDoubles=function(et,ei){if(this.precomputed&&this.precomputed.doubles)return this.precomputed.doubles;for(var es=[this],ef=this,eu=0;eu":""},eV.prototype.isInfinity=function(){return 0===this.x.cmpn(0)&&(0===this.y.cmp(this.z)||this.zOne&&0===this.y.cmp(this.curve.c))},eV.prototype._extDbl=function(){var et=this.x.redSqr(),ei=this.y.redSqr(),es=this.z.redSqr();es=es.redIAdd(es);var ef=this.curve._mulA(et),eu=this.x.redAdd(this.y).redSqr().redISub(et).redISub(ei),ed=ef.redAdd(ei),em=ed.redSub(es),eH=ef.redSub(ei),ez=eu.redMul(em),eV=ed.redMul(eH),eM=eu.redMul(eH),eg=em.redMul(ed);return this.curve.point(ez,eV,eg,eM)},eV.prototype._projDbl=function(){var et,ei,es,ef=this.x.redAdd(this.y).redSqr(),eu=this.x.redSqr(),ed=this.y.redSqr();if(this.curve.twisted){var em=this.curve._mulA(eu),eH=em.redAdd(ed);if(this.zOne)et=ef.redSub(eu).redSub(ed).redMul(eH.redSub(this.curve.two)),ei=eH.redMul(em.redSub(ed)),es=eH.redSqr().redSub(eH).redSub(eH);else{var ez=this.z.redSqr(),eV=eH.redSub(ez).redISub(ez);et=ef.redSub(eu).redISub(ed).redMul(eV),ei=eH.redMul(em.redSub(ed)),es=eH.redMul(eV)}}else{var em=eu.redAdd(ed),ez=this.curve._mulC(this.z).redSqr(),eV=em.redSub(ez).redSub(ez);et=this.curve._mulC(ef.redISub(em)).redMul(eV),ei=this.curve._mulC(em).redMul(eu.redISub(ed)),es=em.redMul(eV)}return this.curve.point(et,ei,es)},eV.prototype.dbl=function(){return this.isInfinity()?this:this.curve.extended?this._extDbl():this._projDbl()},eV.prototype._extAdd=function(et){var ei=this.y.redSub(this.x).redMul(et.y.redSub(et.x)),es=this.y.redAdd(this.x).redMul(et.y.redAdd(et.x)),ef=this.t.redMul(this.curve.dd).redMul(et.t),eu=this.z.redMul(et.z.redAdd(et.z)),ed=es.redSub(ei),em=eu.redSub(ef),eH=eu.redAdd(ef),ez=es.redAdd(ei),eV=ed.redMul(em),eM=eH.redMul(ez),eg=ed.redMul(ez),eL=em.redMul(eH);return this.curve.point(eV,eM,eL,eg)},eV.prototype._projAdd=function(et){var ei,es,ef=this.z.redMul(et.z),eu=ef.redSqr(),ed=this.x.redMul(et.x),em=this.y.redMul(et.y),eH=this.curve.d.redMul(ed).redMul(em),ez=eu.redSub(eH),eV=eu.redAdd(eH),eM=this.x.redAdd(this.y).redMul(et.x.redAdd(et.y)).redISub(ed).redISub(em),eg=ef.redMul(ez).redMul(eM);return this.curve.twisted?(ei=ef.redMul(eV).redMul(em.redSub(this.curve._mulA(ed))),es=ez.redMul(eV)):(ei=ef.redMul(eV).redMul(em.redSub(ed)),es=this.curve._mulC(ez).redMul(eV)),this.curve.point(eg,ei,es)},eV.prototype.add=function(et){return this.isInfinity()?et:et.isInfinity()?this:this.curve.extended?this._extAdd(et):this._projAdd(et)},eV.prototype.mul=function(et){return this._hasDoubles(et)?this.curve._fixedNafMul(this,et):this.curve._wnafMul(this,et)},eV.prototype.mulAdd=function(et,ei,es){return this.curve._wnafMulAdd(1,[this,ei],[et,es],2,!1)},eV.prototype.jmulAdd=function(et,ei,es){return this.curve._wnafMulAdd(1,[this,ei],[et,es],2,!0)},eV.prototype.normalize=function(){if(this.zOne)return this;var et=this.z.redInvm();return this.x=this.x.redMul(et),this.y=this.y.redMul(et),this.t&&(this.t=this.t.redMul(et)),this.z=this.curve.one,this.zOne=!0,this},eV.prototype.neg=function(){return this.curve.point(this.x.redNeg(),this.y,this.z,this.t&&this.t.redNeg())},eV.prototype.getX=function(){return this.normalize(),this.x.fromRed()},eV.prototype.getY=function(){return this.normalize(),this.y.fromRed()},eV.prototype.eq=function(et){return this===et||0===this.getX().cmp(et.getX())&&0===this.getY().cmp(et.getY())},eV.prototype.eqXToP=function(et){var ei=et.toRed(this.curve.red).redMul(this.z);if(0===this.x.cmp(ei))return!0;for(var es=et.clone(),ef=this.curve.redN.redMul(this.z);;){if(es.iadd(this.curve.n),es.cmp(this.curve.p)>=0)return!1;if(ei.redIAdd(ef),0===this.x.cmp(ei))return!0}},eV.prototype.toP=eV.prototype.normalize,eV.prototype.mixedAdd=eV.prototype.add},9359:function(et,ei,es){"use strict";var ef=ei;ef.base=es(2727),ef.short=es(4720),ef.mont=es(6653),ef.edwards=es(2705)},6653:function(et,ei,es){"use strict";var ef=es(711),eu=es(3782),ed=es(2727),em=es(4401);function eH(et){ed.call(this,"mont",et),this.a=new ef(et.a,16).toRed(this.red),this.b=new ef(et.b,16).toRed(this.red),this.i4=new ef(4).toRed(this.red).redInvm(),this.two=new ef(2).toRed(this.red),this.a24=this.i4.redMul(this.a.redAdd(this.two))}function ez(et,ei,es){ed.BasePoint.call(this,et,"projective"),null===ei&&null===es?(this.x=this.curve.one,this.z=this.curve.zero):(this.x=new ef(ei,16),this.z=new ef(es,16),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)))}eu(eH,ed),et.exports=eH,eH.prototype.validate=function(et){var ei=et.normalize().x,es=ei.redSqr(),ef=es.redMul(ei).redAdd(es.redMul(this.a)).redAdd(ei);return 0===ef.redSqrt().redSqr().cmp(ef)},eu(ez,ed.BasePoint),eH.prototype.decodePoint=function(et,ei){return this.point(em.toArray(et,ei),1)},eH.prototype.point=function(et,ei){return new ez(this,et,ei)},eH.prototype.pointFromJSON=function(et){return ez.fromJSON(this,et)},ez.prototype.precompute=function(){},ez.prototype._encode=function(){return this.getX().toArray("be",this.curve.p.byteLength())},ez.fromJSON=function(et,ei){return new ez(et,ei[0],ei[1]||et.one)},ez.prototype.inspect=function(){return this.isInfinity()?"":""},ez.prototype.isInfinity=function(){return 0===this.z.cmpn(0)},ez.prototype.dbl=function(){var et=this.x.redAdd(this.z).redSqr(),ei=this.x.redSub(this.z).redSqr(),es=et.redSub(ei),ef=et.redMul(ei),eu=es.redMul(ei.redAdd(this.curve.a24.redMul(es)));return this.curve.point(ef,eu)},ez.prototype.add=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.diffAdd=function(et,ei){var es=this.x.redAdd(this.z),ef=this.x.redSub(this.z),eu=et.x.redAdd(et.z),ed=et.x.redSub(et.z).redMul(es),em=eu.redMul(ef),eH=ei.z.redMul(ed.redAdd(em).redSqr()),ez=ei.x.redMul(ed.redISub(em).redSqr());return this.curve.point(eH,ez)},ez.prototype.mul=function(et){for(var ei=et.clone(),es=this,ef=this.curve.point(null,null),eu=this,ed=[];0!==ei.cmpn(0);ei.iushrn(1))ed.push(ei.andln(1));for(var em=ed.length-1;em>=0;em--)0===ed[em]?(es=es.diffAdd(ef,eu),ef=ef.dbl()):(ef=es.diffAdd(ef,eu),es=es.dbl());return ef},ez.prototype.mulAdd=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.jumlAdd=function(){throw Error("Not supported on Montgomery curve")},ez.prototype.eq=function(et){return 0===this.getX().cmp(et.getX())},ez.prototype.normalize=function(){return this.x=this.x.redMul(this.z.redInvm()),this.z=this.curve.one,this},ez.prototype.getX=function(){return this.normalize(),this.x.fromRed()}},4720:function(et,ei,es){"use strict";var ef=es(4401),eu=es(711),ed=es(3782),em=es(2727),eH=ef.assert;function ez(et){em.call(this,"short",et),this.a=new eu(et.a,16).toRed(this.red),this.b=new eu(et.b,16).toRed(this.red),this.tinv=this.two.redInvm(),this.zeroA=0===this.a.fromRed().cmpn(0),this.threeA=0===this.a.fromRed().sub(this.p).cmpn(-3),this.endo=this._getEndomorphism(et),this._endoWnafT1=[,,,,],this._endoWnafT2=[,,,,]}function eV(et,ei,es,ef){em.BasePoint.call(this,et,"affine"),null===ei&&null===es?(this.x=null,this.y=null,this.inf=!0):(this.x=new eu(ei,16),this.y=new eu(es,16),ef&&(this.x.forceRed(this.curve.red),this.y.forceRed(this.curve.red)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.inf=!1)}function eM(et,ei,es,ef){em.BasePoint.call(this,et,"jacobian"),null===ei&&null===es&&null===ef?(this.x=this.curve.one,this.y=this.curve.one,this.z=new eu(0)):(this.x=new eu(ei,16),this.y=new eu(es,16),this.z=new eu(ef,16)),this.x.red||(this.x=this.x.toRed(this.curve.red)),this.y.red||(this.y=this.y.toRed(this.curve.red)),this.z.red||(this.z=this.z.toRed(this.curve.red)),this.zOne=this.z===this.curve.one}ed(ez,em),et.exports=ez,ez.prototype._getEndomorphism=function(et){if(this.zeroA&&this.g&&this.n&&1===this.p.modn(3)){if(et.beta)ei=new eu(et.beta,16).toRed(this.red);else{var ei,es,ef,ed=this._getEndoRoots(this.p);ei=(ei=0>ed[0].cmp(ed[1])?ed[0]:ed[1]).toRed(this.red)}if(et.lambda)es=new eu(et.lambda,16);else{var em=this._getEndoRoots(this.n);0===this.g.mul(em[0]).x.cmp(this.g.x.redMul(ei))?es=em[0]:(es=em[1],eH(0===this.g.mul(es).x.cmp(this.g.x.redMul(ei))))}return ef=et.basis?et.basis.map(function(et){return{a:new eu(et.a,16),b:new eu(et.b,16)}}):this._getEndoBasis(es),{beta:ei,lambda:es,basis:ef}}},ez.prototype._getEndoRoots=function(et){var ei=et===this.p?this.red:eu.mont(et),es=new eu(2).toRed(ei).redInvm(),ef=es.redNeg(),ed=new eu(3).toRed(ei).redNeg().redSqrt().redMul(es);return[ef.redAdd(ed).fromRed(),ef.redSub(ed).fromRed()]},ez.prototype._getEndoBasis=function(et){for(var ei,es,ef,ed,em,eH,ez,eV,eM,eg=this.n.ushrn(Math.floor(this.n.bitLength()/2)),eL=et,eb=this.n.clone(),ey=new eu(1),eC=new eu(0),ex=new eu(0),ew=new eu(1),eN=0;0!==eL.cmpn(0);){var eS=eb.div(eL);eV=eb.sub(eS.mul(eL)),eM=ex.sub(eS.mul(ey));var eA=ew.sub(eS.mul(eC));if(!ef&&0>eV.cmp(eg))ei=ez.neg(),es=ey,ef=eV.neg(),ed=eM;else if(ef&&2==++eN)break;ez=eV,eb=eL,eL=eV,ex=ey,ey=eM,ew=eC,eC=eA}em=eV.neg(),eH=eM;var e_=ef.sqr().add(ed.sqr());return em.sqr().add(eH.sqr()).cmp(e_)>=0&&(em=ei,eH=es),ef.negative&&(ef=ef.neg(),ed=ed.neg()),em.negative&&(em=em.neg(),eH=eH.neg()),[{a:ef,b:ed},{a:em,b:eH}]},ez.prototype._endoSplit=function(et){var ei=this.endo.basis,es=ei[0],ef=ei[1],eu=ef.b.mul(et).divRound(this.n),ed=es.b.neg().mul(et).divRound(this.n),em=eu.mul(es.a),eH=ed.mul(ef.a),ez=eu.mul(es.b),eV=ed.mul(ef.b);return{k1:et.sub(em).sub(eH),k2:ez.add(eV).neg()}},ez.prototype.pointFromX=function(et,ei){(et=new eu(et,16)).red||(et=et.toRed(this.red));var es=et.redSqr().redMul(et).redIAdd(et.redMul(this.a)).redIAdd(this.b),ef=es.redSqrt();if(0!==ef.redSqr().redSub(es).cmp(this.zero))throw Error("invalid point");var ed=ef.fromRed().isOdd();return(ei&&!ed||!ei&&ed)&&(ef=ef.redNeg()),this.point(et,ef)},ez.prototype.validate=function(et){if(et.inf)return!0;var ei=et.x,es=et.y,ef=this.a.redMul(ei),eu=ei.redSqr().redMul(ei).redIAdd(ef).redIAdd(this.b);return 0===es.redSqr().redISub(eu).cmpn(0)},ez.prototype._endoWnafMulAdd=function(et,ei,es){for(var ef=this._endoWnafT1,eu=this._endoWnafT2,ed=0;ed":""},eV.prototype.isInfinity=function(){return this.inf},eV.prototype.add=function(et){if(this.inf)return et;if(et.inf)return this;if(this.eq(et))return this.dbl();if(this.neg().eq(et)||0===this.x.cmp(et.x))return this.curve.point(null,null);var ei=this.y.redSub(et.y);0!==ei.cmpn(0)&&(ei=ei.redMul(this.x.redSub(et.x).redInvm()));var es=ei.redSqr().redISub(this.x).redISub(et.x),ef=ei.redMul(this.x.redSub(es)).redISub(this.y);return this.curve.point(es,ef)},eV.prototype.dbl=function(){if(this.inf)return this;var et=this.y.redAdd(this.y);if(0===et.cmpn(0))return this.curve.point(null,null);var ei=this.curve.a,es=this.x.redSqr(),ef=et.redInvm(),eu=es.redAdd(es).redIAdd(es).redIAdd(ei).redMul(ef),ed=eu.redSqr().redISub(this.x.redAdd(this.x)),em=eu.redMul(this.x.redSub(ed)).redISub(this.y);return this.curve.point(ed,em)},eV.prototype.getX=function(){return this.x.fromRed()},eV.prototype.getY=function(){return this.y.fromRed()},eV.prototype.mul=function(et){return(et=new eu(et,16),this.isInfinity())?this:this._hasDoubles(et)?this.curve._fixedNafMul(this,et):this.curve.endo?this.curve._endoWnafMulAdd([this],[et]):this.curve._wnafMul(this,et)},eV.prototype.mulAdd=function(et,ei,es){var ef=[this,ei],eu=[et,es];return this.curve.endo?this.curve._endoWnafMulAdd(ef,eu):this.curve._wnafMulAdd(1,ef,eu,2)},eV.prototype.jmulAdd=function(et,ei,es){var ef=[this,ei],eu=[et,es];return this.curve.endo?this.curve._endoWnafMulAdd(ef,eu,!0):this.curve._wnafMulAdd(1,ef,eu,2,!0)},eV.prototype.eq=function(et){return this===et||this.inf===et.inf&&(this.inf||0===this.x.cmp(et.x)&&0===this.y.cmp(et.y))},eV.prototype.neg=function(et){if(this.inf)return this;var ei=this.curve.point(this.x,this.y.redNeg());if(et&&this.precomputed){var es=this.precomputed,ef=function(et){return et.neg()};ei.precomputed={naf:es.naf&&{wnd:es.naf.wnd,points:es.naf.points.map(ef)},doubles:es.doubles&&{step:es.doubles.step,points:es.doubles.points.map(ef)}}}return ei},eV.prototype.toJ=function(){return this.inf?this.curve.jpoint(null,null,null):this.curve.jpoint(this.x,this.y,this.curve.one)},ed(eM,em.BasePoint),ez.prototype.jpoint=function(et,ei,es){return new eM(this,et,ei,es)},eM.prototype.toP=function(){if(this.isInfinity())return this.curve.point(null,null);var et=this.z.redInvm(),ei=et.redSqr(),es=this.x.redMul(ei),ef=this.y.redMul(ei).redMul(et);return this.curve.point(es,ef)},eM.prototype.neg=function(){return this.curve.jpoint(this.x,this.y.redNeg(),this.z)},eM.prototype.add=function(et){if(this.isInfinity())return et;if(et.isInfinity())return this;var ei=et.z.redSqr(),es=this.z.redSqr(),ef=this.x.redMul(ei),eu=et.x.redMul(es),ed=this.y.redMul(ei.redMul(et.z)),em=et.y.redMul(es.redMul(this.z)),eH=ef.redSub(eu),ez=ed.redSub(em);if(0===eH.cmpn(0))return 0!==ez.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var eV=eH.redSqr(),eM=eV.redMul(eH),eg=ef.redMul(eV),eL=ez.redSqr().redIAdd(eM).redISub(eg).redISub(eg),eb=ez.redMul(eg.redISub(eL)).redISub(ed.redMul(eM)),ey=this.z.redMul(et.z).redMul(eH);return this.curve.jpoint(eL,eb,ey)},eM.prototype.mixedAdd=function(et){if(this.isInfinity())return et.toJ();if(et.isInfinity())return this;var ei=this.z.redSqr(),es=this.x,ef=et.x.redMul(ei),eu=this.y,ed=et.y.redMul(ei).redMul(this.z),em=es.redSub(ef),eH=eu.redSub(ed);if(0===em.cmpn(0))return 0!==eH.cmpn(0)?this.curve.jpoint(null,null,null):this.dbl();var ez=em.redSqr(),eV=ez.redMul(em),eM=es.redMul(ez),eg=eH.redSqr().redIAdd(eV).redISub(eM).redISub(eM),eL=eH.redMul(eM.redISub(eg)).redISub(eu.redMul(eV)),eb=this.z.redMul(em);return this.curve.jpoint(eg,eL,eb)},eM.prototype.dblp=function(et){if(0===et||this.isInfinity())return this;if(!et)return this.dbl();if(this.curve.zeroA||this.curve.threeA){for(var ei=this,es=0;es=0)return!1;if(es.redIAdd(eu),0===this.x.cmp(es))return!0}},eM.prototype.inspect=function(){return this.isInfinity()?"":""},eM.prototype.isInfinity=function(){return 0===this.z.cmpn(0)}},6226:function(et,ei,es){"use strict";var ef,eu=ei,ed=es(7028),em=es(9359),eH=es(4401).assert;function ez(et){"short"===et.type?this.curve=new em.short(et):"edwards"===et.type?this.curve=new em.edwards(et):this.curve=new em.mont(et),this.g=this.curve.g,this.n=this.curve.n,this.hash=et.hash,eH(this.g.validate(),"Invalid curve"),eH(this.g.mul(this.n).isInfinity(),"Invalid curve, G*N != O")}function eV(et,ei){Object.defineProperty(eu,et,{configurable:!0,enumerable:!0,get:function(){var es=new ez(ei);return Object.defineProperty(eu,et,{configurable:!0,enumerable:!0,value:es}),es}})}eu.PresetCurve=ez,eV("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:ed.sha256,gRed:!1,g:["188da80e b03090f6 7cbf20eb 43a18800 f4ff0afd 82ff1012","07192b95 ffc8da78 631011ed 6b24cdd5 73f977a1 1e794811"]}),eV("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:ed.sha256,gRed:!1,g:["b70e0cbd 6bb4bf7f 321390b9 4a03c1d3 56c21122 343280d6 115c1d21","bd376388 b5f723fb 4c22dfe6 cd4375a0 5a074764 44d58199 85007e34"]}),eV("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:ed.sha256,gRed:!1,g:["6b17d1f2 e12c4247 f8bce6e5 63a440f2 77037d81 2deb33a0 f4a13945 d898c296","4fe342e2 fe1a7f9b 8ee7eb4a 7c0f9e16 2bce3357 6b315ece cbb64068 37bf51f5"]}),eV("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:ed.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"]}),eV("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:ed.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"]}),eV("curve25519",{type:"mont",prime:"p25519",p:"7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed",a:"76d06",b:"1",n:"1000000000000000 0000000000000000 14def9dea2f79cd6 5812631a5cf5d3ed",hash:ed.sha256,gRed:!1,g:["9"]}),eV("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:ed.sha256,gRed:!1,g:["216936d3cd6e53fec0a4e231fdd6dc5c692cc7609525a7b2c9562d608f25d51a","6666666666666666666666666666666666666666666666666666666666666658"]});try{ef=es(9702)}catch(et){ef=void 0}eV("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:ed.sha256,beta:"7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee",lambda:"5363ad4cc05c30e0a5261c028812645a122e22ea20816678df02967c1b23bd72",basis:[{a:"3086d221a7d46bcde86c90e49284eb15",b:"-e4437ed6010e88286f547fa90abfe4c3"},{a:"114ca50f7a8e2f3f657c1108d9d44cfd8",b:"3086d221a7d46bcde86c90e49284eb15"}],gRed:!1,g:["79be667ef9dcbbac55a06295ce870b07029bfcdb2dce28d959f2815b16f81798","483ada7726a3c4655da4fbfc0e1108a8fd17b448a68554199c47d08ffb10d4b8",ef]})},4088:function(et,ei,es){"use strict";var ef=es(711),eu=es(4910),ed=es(4401),em=es(6226),eH=es(3500),ez=ed.assert,eV=es(4724),eM=es(7526);function eg(et){if(!(this instanceof eg))return new eg(et);"string"==typeof et&&(ez(em.hasOwnProperty(et),"Unknown curve "+et),et=em[et]),et instanceof em.PresetCurve&&(et={curve:et}),this.curve=et.curve.curve,this.n=this.curve.n,this.nh=this.n.ushrn(1),this.g=this.curve.g,this.g=et.curve.g,this.g.precompute(et.curve.n.bitLength()+1),this.hash=et.hash||et.curve.hash}et.exports=eg,eg.prototype.keyPair=function(et){return new eV(this,et)},eg.prototype.keyFromPrivate=function(et,ei){return eV.fromPrivate(this,et,ei)},eg.prototype.keyFromPublic=function(et,ei){return eV.fromPublic(this,et,ei)},eg.prototype.genKeyPair=function(et){et||(et={});for(var ei=new eu({hash:this.hash,pers:et.pers,persEnc:et.persEnc||"utf8",entropy:et.entropy||eH(this.hash.hmacStrength),entropyEnc:et.entropy&&et.entropyEnc||"utf8",nonce:this.n.toArray()}),es=this.n.byteLength(),ed=this.n.sub(new ef(2));;){var em=new ef(ei.generate(es));if(!(em.cmp(ed)>0))return em.iaddn(1),this.keyFromPrivate(em)}},eg.prototype._truncateToN=function(et,ei){var es=8*et.byteLength()-this.n.bitLength();return(es>0&&(et=et.ushrn(es)),!ei&&et.cmp(this.n)>=0)?et.sub(this.n):et},eg.prototype.sign=function(et,ei,es,ed){"object"==typeof es&&(ed=es,es=null),ed||(ed={}),ei=this.keyFromPrivate(ei,es),et=this._truncateToN(new ef(et,16));for(var em=this.n.byteLength(),eH=ei.getPrivate().toArray("be",em),ez=et.toArray("be",em),eV=new eu({hash:this.hash,entropy:eH,nonce:ez,pers:ed.pers,persEnc:ed.persEnc||"utf8"}),eg=this.n.sub(new ef(1)),eL=0;;eL++){var eb=ed.k?ed.k(eL):new ef(eV.generate(this.n.byteLength()));if(!(0>=(eb=this._truncateToN(eb,!0)).cmpn(1)||eb.cmp(eg)>=0)){var ey=this.g.mul(eb);if(!ey.isInfinity()){var eC=ey.getX(),ex=eC.umod(this.n);if(0!==ex.cmpn(0)){var ew=eb.invm(this.n).mul(ex.mul(ei.getPrivate()).iadd(et));if(0!==(ew=ew.umod(this.n)).cmpn(0)){var eN=(ey.getY().isOdd()?1:0)|(0!==eC.cmp(ex)?2:0);return ed.canonical&&ew.cmp(this.nh)>0&&(ew=this.n.sub(ew),eN^=1),new eM({r:ex,s:ew,recoveryParam:eN})}}}}}},eg.prototype.verify=function(et,ei,es,eu){et=this._truncateToN(new ef(et,16)),es=this.keyFromPublic(es,eu);var ed=(ei=new eM(ei,"hex")).r,em=ei.s;if(0>ed.cmpn(1)||ed.cmp(this.n)>=0||0>em.cmpn(1)||em.cmp(this.n)>=0)return!1;var eH=em.invm(this.n),ez=eH.mul(et).umod(this.n),eV=eH.mul(ed).umod(this.n);if(!this.curve._maxwellTrick){var eg=this.g.mulAdd(ez,es.getPublic(),eV);return!eg.isInfinity()&&0===eg.getX().umod(this.n).cmp(ed)}var eg=this.g.jmulAdd(ez,es.getPublic(),eV);return!eg.isInfinity()&&eg.eqXToP(ed)},eg.prototype.recoverPubKey=function(et,ei,es,eu){ez((3&es)===es,"The recovery param is more than two bits"),ei=new eM(ei,eu);var ed=this.n,em=new ef(et),eH=ei.r,eV=ei.s,eg=1&es,eL=es>>1;if(eH.cmp(this.curve.p.umod(this.curve.n))>=0&&eL)throw Error("Unable to find sencond key candinate");eH=eL?this.curve.pointFromX(eH.add(this.curve.n),eg):this.curve.pointFromX(eH,eg);var eb=ei.r.invm(ed),ey=ed.sub(em).mul(eb).umod(ed),eC=eV.mul(eb).umod(ed);return this.g.mulAdd(ey,eH,eC)},eg.prototype.getKeyRecoveryParam=function(et,ei,es,ef){if(null!==(ei=new eM(ei,ef)).recoveryParam)return ei.recoveryParam;for(var eu,ed=0;ed<4;ed++){try{eu=this.recoverPubKey(et,ei,ed)}catch(et){continue}if(eu.eq(es))return ed}throw Error("Unable to find valid recovery factor")}},4724:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401).assert;function ed(et,ei){this.ec=et,this.priv=null,this.pub=null,ei.priv&&this._importPrivate(ei.priv,ei.privEnc),ei.pub&&this._importPublic(ei.pub,ei.pubEnc)}et.exports=ed,ed.fromPublic=function(et,ei,es){return ei instanceof ed?ei:new ed(et,{pub:ei,pubEnc:es})},ed.fromPrivate=function(et,ei,es){return ei instanceof ed?ei:new ed(et,{priv:ei,privEnc:es})},ed.prototype.validate=function(){var et=this.getPublic();return et.isInfinity()?{result:!1,reason:"Invalid public key"}:et.validate()?et.mul(this.ec.curve.n).isInfinity()?{result:!0,reason:null}:{result:!1,reason:"Public key * N != O"}:{result:!1,reason:"Public key is not a point"}},ed.prototype.getPublic=function(et,ei){return("string"==typeof et&&(ei=et,et=null),this.pub||(this.pub=this.ec.g.mul(this.priv)),ei)?this.pub.encode(ei,et):this.pub},ed.prototype.getPrivate=function(et){return"hex"===et?this.priv.toString(16,2):this.priv},ed.prototype._importPrivate=function(et,ei){this.priv=new ef(et,ei||16),this.priv=this.priv.umod(this.ec.curve.n)},ed.prototype._importPublic=function(et,ei){if(et.x||et.y){"mont"===this.ec.curve.type?eu(et.x,"Need x coordinate"):("short"===this.ec.curve.type||"edwards"===this.ec.curve.type)&&eu(et.x&&et.y,"Need both x and y coordinate"),this.pub=this.ec.curve.point(et.x,et.y);return}this.pub=this.ec.curve.decodePoint(et,ei)},ed.prototype.derive=function(et){return et.mul(this.priv).getX()},ed.prototype.sign=function(et,ei,es){return this.ec.sign(et,this,ei,es)},ed.prototype.verify=function(et,ei){return this.ec.verify(et,ei,this)},ed.prototype.inspect=function(){return""}},7526:function(et,ei,es){"use strict";var ef=es(711),eu=es(4401),ed=eu.assert;function em(et,ei){if(et instanceof em)return et;this._importDER(et,ei)||(ed(et.r&&et.s,"Signature without r or s"),this.r=new ef(et.r,16),this.s=new ef(et.s,16),void 0===et.recoveryParam?this.recoveryParam=null:this.recoveryParam=et.recoveryParam)}function eH(){this.place=0}function ez(et,ei){var es=et[ei.place++];if(!(128&es))return es;var ef=15&es;if(0===ef||ef>4)return!1;for(var eu=0,ed=0,em=ei.place;ed>>=0;return!(eu<=127)&&(ei.place=em,eu)}function eV(et){for(var ei=0,es=et.length-1;!et[ei]&&!(128&et[ei+1])&&ei>>3);for(et.push(128|es);--es;)et.push(ei>>>(es<<3)&255);et.push(ei)}et.exports=em,em.prototype._importDER=function(et,ei){et=eu.toArray(et,ei);var es=new eH;if(48!==et[es.place++])return!1;var ed=ez(et,es);if(!1===ed||ed+es.place!==et.length||2!==et[es.place++])return!1;var em=ez(et,es);if(!1===em)return!1;var eV=et.slice(es.place,em+es.place);if(es.place+=em,2!==et[es.place++])return!1;var eM=ez(et,es);if(!1===eM||et.length!==eM+es.place)return!1;var eg=et.slice(es.place,eM+es.place);if(0===eV[0]){if(!(128&eV[1]))return!1;eV=eV.slice(1)}if(0===eg[0]){if(!(128&eg[1]))return!1;eg=eg.slice(1)}return this.r=new ef(eV),this.s=new ef(eg),this.recoveryParam=null,!0},em.prototype.toDER=function(et){var ei=this.r.toArray(),es=this.s.toArray();for(128&ei[0]&&(ei=[0].concat(ei)),128&es[0]&&(es=[0].concat(es)),ei=eV(ei),es=eV(es);!es[0]&&!(128&es[1]);)es=es.slice(1);var ef=[2];eM(ef,ei.length),(ef=ef.concat(ei)).push(2),eM(ef,es.length);var ed=ef.concat(es),em=[48];return eM(em,ed.length),em=em.concat(ed),eu.encode(em,et)}},8511:function(et,ei,es){"use strict";var ef=es(7028),eu=es(6226),ed=es(4401),em=ed.assert,eH=ed.parseBytes,ez=es(9917),eV=es(9314);function eM(et){if(em("ed25519"===et,"only tested with ed25519 so far"),!(this instanceof eM))return new eM(et);var et=eu[et].curve;this.curve=et,this.g=et.g,this.g.precompute(et.n.bitLength()+1),this.pointClass=et.point().constructor,this.encodingLength=Math.ceil(et.n.bitLength()/8),this.hash=ef.sha512}et.exports=eM,eM.prototype.sign=function(et,ei){et=eH(et);var es=this.keyFromSecret(ei),ef=this.hashInt(es.messagePrefix(),et),eu=this.g.mul(ef),ed=this.encodePoint(eu),em=this.hashInt(ed,es.pubBytes(),et).mul(es.priv()),ez=ef.add(em).umod(this.curve.n);return this.makeSignature({R:eu,S:ez,Rencoded:ed})},eM.prototype.verify=function(et,ei,es){et=eH(et),ei=this.makeSignature(ei);var ef=this.keyFromPublic(es),eu=this.hashInt(ei.Rencoded(),ef.pubBytes(),et),ed=this.g.mul(ei.S());return ei.R().add(ef.pub().mul(eu)).eq(ed)},eM.prototype.hashInt=function(){for(var et=this.hash(),ei=0;ei(eu>>1)-1?(eu>>1)-ez:ez,ed.isubn(eH)):eH=0,ef[em]=eH,ed.iushrn(1)}return ef}function ez(et,ei){var es=[[],[]];et=et.clone(),ei=ei.clone();for(var ef=0,eu=0;et.cmpn(-ef)>0||ei.cmpn(-eu)>0;){var ed,em,eH=et.andln(3)+ef&3,ez=ei.andln(3)+eu&3;if(3===eH&&(eH=-1),3===ez&&(ez=-1),(1&eH)==0)ed=0;else{var eV=et.andln(7)+ef&7;ed=(3===eV||5===eV)&&2===ez?-eH:eH}if(es[0].push(ed),(1&ez)==0)em=0;else{var eV=ei.andln(7)+eu&7;em=(3===eV||5===eV)&&2===eH?-ez:ez}es[1].push(em),2*ef===ed+1&&(ef=1-ef),2*eu===em+1&&(eu=1-eu),et.iushrn(1),ei.iushrn(1)}return es}function eV(et,ei,es){var ef="_"+ei;et.prototype[ei]=function(){return void 0!==this[ef]?this[ef]:this[ef]=es.call(this)}}function eM(et){return"string"==typeof et?ef.toArray(et,"hex"):et}function eg(et){return new eu(et,"hex","le")}ef.assert=ed,ef.toArray=em.toArray,ef.zero2=em.zero2,ef.toHex=em.toHex,ef.encode=em.encode,ef.getNAF=eH,ef.getJSF=ez,ef.cachedProperty=eV,ef.parseBytes=eM,ef.intFromLE=eg},8368:function(et,ei,es){var ef=es(6911).Buffer,eu=es(3533);function ed(et,ei,es,ed){if(ef.isBuffer(et)||(et=ef.from(et,"binary")),ei&&(ef.isBuffer(ei)||(ei=ef.from(ei,"binary")),8!==ei.length))throw RangeError("salt should be Buffer with 8 byte length");for(var em=es/8,eH=ef.alloc(em),ez=ef.alloc(ed||0),eV=ef.alloc(0);em>0||ed>0;){var eM=new eu;eM.update(eV),eM.update(et),ei&&eM.update(ei),eV=eM.digest();var eg=0;if(em>0){var eL=eH.length-em;eg=Math.min(em,eV.length),eV.copy(eH,eL,0,eg),em-=eg}if(eg0){var eb=ez.length-ed,ey=Math.min(ed,eV.length-eg);eV.copy(ez,eb,eg,eg+ey),ed-=ey}}return eV.fill(0),{key:eH,iv:ez}}et.exports=ed},9029:function(et,ei,es){"use strict";var ef=es(6911).Buffer,eu=es(3726).Transform;function ed(et,ei){if(!ef.isBuffer(et)&&"string"!=typeof et)throw TypeError(ei+" must be a string or a buffer")}function em(et){eu.call(this),this._block=ef.allocUnsafe(et),this._blockSize=et,this._blockOffset=0,this._length=[0,0,0,0],this._finalized=!1}es(3782)(em,eu),em.prototype._transform=function(et,ei,es){var ef=null;try{this.update(et,ei)}catch(et){ef=et}es(ef)},em.prototype._flush=function(et){var ei=null;try{this.push(this.digest())}catch(et){ei=et}et(ei)},em.prototype.update=function(et,ei){if(ed(et,"Data"),this._finalized)throw Error("Digest already called");ef.isBuffer(et)||(et=ef.from(et,ei));for(var es=this._block,eu=0;this._blockOffset+et.length-eu>=this._blockSize;){for(var em=this._blockOffset;em0;++eH)this._length[eH]+=ez,(ez=this._length[eH]/4294967296|0)>0&&(this._length[eH]-=4294967296*ez);return this},em.prototype._update=function(){throw Error("_update is not implemented")},em.prototype.digest=function(et){if(this._finalized)throw Error("Digest already called");this._finalized=!0;var ei=this._digest();void 0!==et&&(ei=ei.toString(et)),this._block.fill(0),this._blockOffset=0;for(var es=0;es<4;++es)this._length[es]=0;return ei},em.prototype._digest=function(){throw Error("_digest is not implemented")},et.exports=em},7028:function(et,ei,es){var ef=ei;ef.utils=es(263),ef.common=es(1330),ef.sha=es(301),ef.ripemd=es(3079),ef.hmac=es(3092),ef.sha1=ef.sha.sha1,ef.sha256=ef.sha.sha256,ef.sha224=ef.sha.sha224,ef.sha384=ef.sha.sha384,ef.sha512=ef.sha.sha512,ef.ripemd160=ef.ripemd.ripemd160},1330:function(et,ei,es){"use strict";var ef=es(263),eu=es(3523);function ed(){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}ei.BlockHash=ed,ed.prototype.update=function(et,ei){if(et=ef.toArray(et,ei),this.pending?this.pending=this.pending.concat(et):this.pending=et,this.pendingTotal+=et.length,this.pending.length>=this._delta8){var es=(et=this.pending).length%this._delta8;this.pending=et.slice(et.length-es,et.length),0===this.pending.length&&(this.pending=null),et=ef.join32(et,0,et.length-es,this.endian);for(var eu=0;eu>>24&255,ef[eu++]=et>>>16&255,ef[eu++]=et>>>8&255,ef[eu++]=255&et}else for(ed=8,ef[eu++]=255&et,ef[eu++]=et>>>8&255,ef[eu++]=et>>>16&255,ef[eu++]=et>>>24&255,ef[eu++]=0,ef[eu++]=0,ef[eu++]=0,ef[eu++]=0;edthis.blockSize&&(et=(new this.Hash).update(et).digest()),eu(et.length<=this.blockSize);for(var ei=et.length;ei>>3}function eg(et){return ef(et,17)^ef(et,19)^et>>>10}ei.ft_1=eu,ei.ch32=ed,ei.maj32=em,ei.p32=eH,ei.s0_256=ez,ei.s1_256=eV,ei.g0_256=eM,ei.g1_256=eg},263:function(et,ei,es){"use strict";var ef=es(3523),eu=es(3782);function ed(et,ei){return(64512&et.charCodeAt(ei))==55296&&!(ei<0)&&!(ei+1>=et.length)&&(64512&et.charCodeAt(ei+1))==56320}function em(et,ei){if(Array.isArray(et))return et.slice();if(!et)return[];var es=[];if("string"==typeof et){if(ei){if("hex"===ei)for((et=et.replace(/[^a-z0-9]+/gi,"")).length%2!=0&&(et="0"+et),eu=0;eu>6|192,es[ef++]=63&em|128):ed(et,eu)?(em=65536+((1023&em)<<10)+(1023&et.charCodeAt(++eu)),es[ef++]=em>>18|240,es[ef++]=em>>12&63|128,es[ef++]=em>>6&63|128,es[ef++]=63&em|128):(es[ef++]=em>>12|224,es[ef++]=em>>6&63|128,es[ef++]=63&em|128)}}else for(eu=0;eu>>24|et>>>8&65280|et<<8&16711680|(255&et)<<24)>>>0}function eV(et,ei){for(var es="",ef=0;ef>>0;return eH}function eb(et,ei){for(var es=Array(4*et.length),ef=0,eu=0;ef>>24,es[eu+1]=ed>>>16&255,es[eu+2]=ed>>>8&255,es[eu+3]=255&ed):(es[eu+3]=ed>>>24,es[eu+2]=ed>>>16&255,es[eu+1]=ed>>>8&255,es[eu]=255&ed)}return es}function ey(et,ei){return et>>>ei|et<<32-ei}function eC(et,ei){return et<>>32-ei}function ex(et,ei){return et+ei>>>0}function ew(et,ei,es){return et+ei+es>>>0}function eN(et,ei,es,ef){return et+ei+es+ef>>>0}function eS(et,ei,es,ef,eu){return et+ei+es+ef+eu>>>0}function eA(et,ei,es,ef){var eu=et[ei],ed=ef+et[ei+1]>>>0,em=(ed>>0,et[ei+1]=ed}function e_(et,ei,es,ef){return(ei+ef>>>0>>0}function eE(et,ei,es,ef){return ei+ef>>>0}function eP(et,ei,es,ef,eu,ed,em,eH){var ez,eV=ei;return et+es+eu+em+(ez=0+((eV=eV+ef>>>0)>>0)>>0)>>0}function eB(et,ei,es,ef,eu,ed,em,eH){return ei+ef+ed+eH>>>0}function eT(et,ei,es,ef,eu,ed,em,eH,ez,eV){var eM,eg=ei;return et+es+eu+em+ez+(eM=0+((eg=eg+ef>>>0)>>0)>>0)>>0)>>0}function eI(et,ei,es,ef,eu,ed,em,eH,ez,eV){return ei+ef+ed+eH+eV>>>0}function eR(et,ei,es){return(ei<<32-es|et>>>es)>>>0}function eO(et,ei,es){return(et<<32-es|ei>>>es)>>>0}function ej(et,ei,es){return et>>>es}function eD(et,ei,es){return(et<<32-es|ei>>>es)>>>0}ei.inherits=eu,ei.toArray=em,ei.toHex=eH,ei.htonl=ez,ei.toHex32=eV,ei.zero2=eM,ei.zero8=eg,ei.join32=eL,ei.split32=eb,ei.rotr32=ey,ei.rotl32=eC,ei.sum32=ex,ei.sum32_3=ew,ei.sum32_4=eN,ei.sum32_5=eS,ei.sum64=eA,ei.sum64_hi=e_,ei.sum64_lo=eE,ei.sum64_4_hi=eP,ei.sum64_4_lo=eB,ei.sum64_5_hi=eT,ei.sum64_5_lo=eI,ei.rotr64_hi=eR,ei.rotr64_lo=eO,ei.shr64_hi=ej,ei.shr64_lo=eD},4910:function(et,ei,es){"use strict";var ef=es(7028),eu=es(6545),ed=es(3523);function em(et){if(!(this instanceof em))return new em(et);this.hash=et.hash,this.predResist=!!et.predResist,this.outLen=this.hash.outSize,this.minEntropy=et.minEntropy||this.hash.hmacStrength,this._reseed=null,this.reseedInterval=null,this.K=null,this.V=null;var ei=eu.toArray(et.entropy,et.entropyEnc||"hex"),es=eu.toArray(et.nonce,et.nonceEnc||"hex"),ef=eu.toArray(et.pers,et.persEnc||"hex");ed(ei.length>=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._init(ei,es,ef)}et.exports=em,em.prototype._init=function(et,ei,es){var ef=et.concat(ei).concat(es);this.K=Array(this.outLen/8),this.V=Array(this.outLen/8);for(var eu=0;eu=this.minEntropy/8,"Not enough entropy. Minimum is: "+this.minEntropy+" bits"),this._update(et.concat(es||[])),this._reseed=1},em.prototype.generate=function(et,ei,es,ef){if(this._reseed>this.reseedInterval)throw Error("Reseed is required");"string"!=typeof ei&&(ef=es,es=ei,ei=null),es&&(es=eu.toArray(es,ef||"hex"),this._update(es));for(var ed=[];ed.length>>32-ei}function eV(et,ei,es,ef,eu,ed,em){return ez(et+(ei&es|~ei&ef)+eu+ed|0,em)+ei|0}function eM(et,ei,es,ef,eu,ed,em){return ez(et+(ei&ef|es&~ef)+eu+ed|0,em)+ei|0}function eg(et,ei,es,ef,eu,ed,em){return ez(et+(ei^es^ef)+eu+ed|0,em)+ei|0}function eL(et,ei,es,ef,eu,ed,em){return ez(et+(es^(ei|~ef))+eu+ed|0,em)+ei|0}ef(eH,eu),eH.prototype._update=function(){for(var et=em,ei=0;ei<16;++ei)et[ei]=this._block.readInt32LE(4*ei);var es=this._a,ef=this._b,eu=this._c,ed=this._d;es=eV(es,ef,eu,ed,et[0],3614090360,7),ed=eV(ed,es,ef,eu,et[1],3905402710,12),eu=eV(eu,ed,es,ef,et[2],606105819,17),ef=eV(ef,eu,ed,es,et[3],3250441966,22),es=eV(es,ef,eu,ed,et[4],4118548399,7),ed=eV(ed,es,ef,eu,et[5],1200080426,12),eu=eV(eu,ed,es,ef,et[6],2821735955,17),ef=eV(ef,eu,ed,es,et[7],4249261313,22),es=eV(es,ef,eu,ed,et[8],1770035416,7),ed=eV(ed,es,ef,eu,et[9],2336552879,12),eu=eV(eu,ed,es,ef,et[10],4294925233,17),ef=eV(ef,eu,ed,es,et[11],2304563134,22),es=eV(es,ef,eu,ed,et[12],1804603682,7),ed=eV(ed,es,ef,eu,et[13],4254626195,12),eu=eV(eu,ed,es,ef,et[14],2792965006,17),ef=eV(ef,eu,ed,es,et[15],1236535329,22),es=eM(es,ef,eu,ed,et[1],4129170786,5),ed=eM(ed,es,ef,eu,et[6],3225465664,9),eu=eM(eu,ed,es,ef,et[11],643717713,14),ef=eM(ef,eu,ed,es,et[0],3921069994,20),es=eM(es,ef,eu,ed,et[5],3593408605,5),ed=eM(ed,es,ef,eu,et[10],38016083,9),eu=eM(eu,ed,es,ef,et[15],3634488961,14),ef=eM(ef,eu,ed,es,et[4],3889429448,20),es=eM(es,ef,eu,ed,et[9],568446438,5),ed=eM(ed,es,ef,eu,et[14],3275163606,9),eu=eM(eu,ed,es,ef,et[3],4107603335,14),ef=eM(ef,eu,ed,es,et[8],1163531501,20),es=eM(es,ef,eu,ed,et[13],2850285829,5),ed=eM(ed,es,ef,eu,et[2],4243563512,9),eu=eM(eu,ed,es,ef,et[7],1735328473,14),ef=eM(ef,eu,ed,es,et[12],2368359562,20),es=eg(es,ef,eu,ed,et[5],4294588738,4),ed=eg(ed,es,ef,eu,et[8],2272392833,11),eu=eg(eu,ed,es,ef,et[11],1839030562,16),ef=eg(ef,eu,ed,es,et[14],4259657740,23),es=eg(es,ef,eu,ed,et[1],2763975236,4),ed=eg(ed,es,ef,eu,et[4],1272893353,11),eu=eg(eu,ed,es,ef,et[7],4139469664,16),ef=eg(ef,eu,ed,es,et[10],3200236656,23),es=eg(es,ef,eu,ed,et[13],681279174,4),ed=eg(ed,es,ef,eu,et[0],3936430074,11),eu=eg(eu,ed,es,ef,et[3],3572445317,16),ef=eg(ef,eu,ed,es,et[6],76029189,23),es=eg(es,ef,eu,ed,et[9],3654602809,4),ed=eg(ed,es,ef,eu,et[12],3873151461,11),eu=eg(eu,ed,es,ef,et[15],530742520,16),ef=eg(ef,eu,ed,es,et[2],3299628645,23),es=eL(es,ef,eu,ed,et[0],4096336452,6),ed=eL(ed,es,ef,eu,et[7],1126891415,10),eu=eL(eu,ed,es,ef,et[14],2878612391,15),ef=eL(ef,eu,ed,es,et[5],4237533241,21),es=eL(es,ef,eu,ed,et[12],1700485571,6),ed=eL(ed,es,ef,eu,et[3],2399980690,10),eu=eL(eu,ed,es,ef,et[10],4293915773,15),ef=eL(ef,eu,ed,es,et[1],2240044497,21),es=eL(es,ef,eu,ed,et[8],1873313359,6),ed=eL(ed,es,ef,eu,et[15],4264355552,10),eu=eL(eu,ed,es,ef,et[6],2734768916,15),ef=eL(ef,eu,ed,es,et[13],1309151649,21),es=eL(es,ef,eu,ed,et[4],4149444226,6),ed=eL(ed,es,ef,eu,et[11],3174756917,10),eu=eL(eu,ed,es,ef,et[2],718787259,15),ef=eL(ef,eu,ed,es,et[9],3951481745,21),this._a=this._a+es|0,this._b=this._b+ef|0,this._c=this._c+eu|0,this._d=this._d+ed|0},eH.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ed.allocUnsafe(16);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et},et.exports=eH},1354:function(et,ei,es){var ef=es(711),eu=es(3500);function ed(et){this.rand=et||new eu.Rand}et.exports=ed,ed.create=function(et){return new ed(et)},ed.prototype._randbelow=function(et){var ei=Math.ceil(et.bitLength()/8);do var es=new ef(this.rand.generate(ei));while(es.cmp(et)>=0);return es},ed.prototype._randrange=function(et,ei){var es=ei.sub(et);return et.add(this._randbelow(es))},ed.prototype.test=function(et,ei,es){var eu=et.bitLength(),ed=ef.mont(et),em=new ef(1).toRed(ed);ei||(ei=Math.max(1,eu/48|0));for(var eH=et.subn(1),ez=0;!eH.testn(ez);ez++);for(var eV=et.shrn(ez),eM=eH.toRed(ed),eg=!0;ei>0;ei--){var eL=this._randrange(new ef(2),eH);es&&es(eL);var eb=eL.toRed(ed).redPow(eV);if(0!==eb.cmp(em)&&0!==eb.cmp(eM)){for(var ey=1;ey0;ei--){var eM=this._randrange(new ef(2),em),eg=et.gcd(eM);if(0!==eg.cmpn(1))return eg;var eL=eM.toRed(eu).redPow(ez);if(0!==eL.cmp(ed)&&0!==eL.cmp(eV)){for(var eb=1;eb>8,em=255&eu;ed?es.push(ed,em):es.push(em)}return es}function eu(et){return 1===et.length?"0"+et:et}function ed(et){for(var ei="",es=0;esei||es!=es)throw TypeError("Bad key length")}},2127:function(et,ei,es){var ef={md5:16,sha1:20,sha224:28,sha256:32,sha384:48,sha512:64,rmd160:20,ripemd160:20},eu=es(4873),ed=es(6911).Buffer,em=es(5349),eH=es(7007),ez=es(5407);function eV(et,ei,es,eV,eM){em(es,eV),et=ez(et,eH,"Password"),ei=ez(ei,eH,"Salt"),eM=eM||"sha1";var eg=ed.allocUnsafe(eV),eL=ed.allocUnsafe(ei.length+4);ei.copy(eL,0,0,ei.length);for(var eb=0,ey=ef[eM],eC=Math.ceil(eV/ey),ex=1;ex<=eC;ex++){eL.writeUInt32BE(ex,ei.length);for(var ew=eu(eM,et).update(eL).digest(),eN=ew,eS=1;eS=ei.length){ed++;break}var em=ei.slice(2,eu-1);if(("0002"!==ef.toString("hex")&&!es||"0001"!==ef.toString("hex")&&es)&&ed++,em.length<8&&ed++,ed)throw Error("decryption error");return ei.slice(eu)}function eb(et,ei){et=eM.from(et),ei=eM.from(ei);var es=0,ef=et.length;et.length!==ei.length&&(es++,ef=Math.min(et.length,ei.length));for(var eu=-1;++eueb||new em(ei).cmp(ez.modulus)>=0)throw Error("decryption error");ed=es?eV(new em(ei),ez):eH(ei,ez);var ey=eM.alloc(eb-ed.length);if(ed=eM.concat([ey,ed],eb),4===eu)return eg(ez,ed);if(1===eu)return eL(ez,ed,es);if(3===eu)return ed;throw Error("unknown padding")}},3995:function(et,ei,es){var ef=es(9902),eu=es(7223),ed=es(9739),em=es(5520),eH=es(6386),ez=es(711),eV=es(1607),eM=es(7166),eg=es(6911).Buffer;function eL(et,ei){var es=et.modulus.byteLength(),ef=ei.length,eV=ed("sha1").update(eg.alloc(0)).digest(),eM=eV.length,eL=2*eM;if(ef>es-eL-2)throw Error("message too long");var eb=eg.alloc(es-ef-eL-2),ey=es-eM-1,eC=eu(eM),ex=eH(eg.concat([eV,eb,eg.alloc(1,1),ei],ey),em(eC,ey)),ew=eH(eC,em(ex,eM));return new ez(eg.concat([eg.alloc(1),ew,ex],es))}function eb(et,ei,es){var ef,eu=ei.length,ed=et.modulus.byteLength();if(eu>ed-11)throw Error("message too long");return ef=es?eg.alloc(ed-eu-3,255):ey(ed-eu-3),new ez(eg.concat([eg.from([0,es?1:2]),ef,eg.alloc(1),ei],ed))}function ey(et){for(var ei,es=eg.allocUnsafe(et),ef=0,ed=eu(2*et),em=0;ef=0)throw Error("data too long for modulus")}else throw Error("unknown padding");return es?eM(ed,em):eV(ed,em)}},1607:function(et,ei,es){var ef=es(711),eu=es(6911).Buffer;function ed(et,ei){return eu.from(et.toRed(ef.mont(ei.modulus)).redPow(new ef(ei.publicExponent)).fromRed().toArray())}et.exports=ed},6386:function(et){et.exports=function(et,ei){for(var es=et.length,ef=-1;++efem)throw RangeError("requested too many random bytes");var es=ez.allocUnsafe(et);if(et>0){if(et>eu)for(var ef=0;efeM||et<0)throw TypeError("offset must be a uint32");if(et>ez||et>ei)throw RangeError("offset out of range")}function eL(et,ei,es){if("number"!=typeof et||et!=et)throw TypeError("size must be a number");if(et>eM||et<0)throw TypeError("size must be a uint32");if(et+ei>es||et>ez)throw RangeError("buffer too small")}function eb(et,ei,ef,eu){if(!eH.isBuffer(et)&&!(et instanceof es.g.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');if("function"==typeof ei)eu=ei,ei=0,ef=et.length;else if("function"==typeof ef)eu=ef,ef=et.length-ei;else if("function"!=typeof eu)throw TypeError('"cb" argument must be a function');return eg(ei,et.length),eL(ef,ei,et.length),ey(et,ei,ef,eu)}function ey(et,ei,es,ef){var eu=et.buffer,em=new Uint8Array(eu,ei,es);if(eV.getRandomValues(em),ef){ed.nextTick(function(){ef(null,et)});return}return et}function eC(et,ei,ef){if(void 0===ei&&(ei=0),!eH.isBuffer(et)&&!(et instanceof es.g.Uint8Array))throw TypeError('"buf" argument must be a Buffer or Uint8Array');return eg(ei,et.length),void 0===ef&&(ef=et.length-ei),eL(ef,ei,et.length),ey(et,ei,ef)}eV&&eV.getRandomValues?(ei.randomFill=eb,ei.randomFillSync=eC):(ei.randomFill=eu,ei.randomFillSync=eu)},4646:function(et){"use strict";let ei={};function es(et,es,ef){function eu(et,ei,ef){return"string"==typeof es?es:es(et,ei,ef)}ef||(ef=Error);class ed extends ef{constructor(et,ei,es){super(eu(et,ei,es))}}ed.prototype.name=ef.name,ed.prototype.code=et,ei[et]=ed}function ef(et,ei){if(!Array.isArray(et))return`of ${ei} ${String(et)}`;{let es=et.length;return(et=et.map(et=>String(et)),es>2)?`one of ${ei} ${et.slice(0,es-1).join(", ")}, or `+et[es-1]:2===es?`one of ${ei} ${et[0]} or ${et[1]}`:`of ${ei} ${et[0]}`}}function eu(et,ei,es){return et.substr(!es||es<0?0:+es,ei.length)===ei}function ed(et,ei,es){return(void 0===es||es>et.length)&&(es=et.length),et.substring(es-ei.length,es)===ei}function em(et,ei,es){return"number"!=typeof es&&(es=0),!(es+ei.length>et.length)&&-1!==et.indexOf(ei,es)}es("ERR_INVALID_OPT_VALUE",function(et,ei){return'The value "'+ei+'" is invalid for option "'+et+'"'},TypeError),es("ERR_INVALID_ARG_TYPE",function(et,ei,es){let eH,ez;if("string"==typeof ei&&eu(ei,"not ")?(eH="must not be",ei=ei.replace(/^not /,"")):eH="must be",ed(et," argument"))ez=`The ${et} ${eH} ${ef(ei,"type")}`;else{let es=em(et,".")?"property":"argument";ez=`The "${et}" ${es} ${eH} ${ef(ei,"type")}`}return ez+`. Received type ${typeof es}`},TypeError),es("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),es("ERR_METHOD_NOT_IMPLEMENTED",function(et){return"The "+et+" method is not implemented"}),es("ERR_STREAM_PREMATURE_CLOSE","Premature close"),es("ERR_STREAM_DESTROYED",function(et){return"Cannot call "+et+" after a stream was destroyed"}),es("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),es("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),es("ERR_STREAM_WRITE_AFTER_END","write after end"),es("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),es("ERR_UNKNOWN_ENCODING",function(et){return"Unknown encoding: "+et},TypeError),es("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),et.exports.q=ei},2403:function(et,ei,es){"use strict";var ef=Object.keys||function(et){var ei=[];for(var es in et)ei.push(es);return ei};et.exports=eM;var eu=es(1709),em=es(7337);es(3782)(eM,eu);for(var eH=ef(em.prototype),ez=0;ez0){if("string"==typeof ei||eH.objectMode||Object.getPrototypeOf(ei)===eL.prototype||(ei=ey(ei)),ef)eH.endEmitted?eT(et,new eB):eF(et,eH,ei,!0);else if(eH.ended)eT(et,new eE);else{if(eH.destroyed)return!1;eH.reading=!1,eH.decoder&&!es?(ei=eH.decoder.write(ei),eH.objectMode||0!==ei.length?eF(et,eH,ei,!1):eJ(et,eH)):eF(et,eH,ei,!1)}}else ef||(eH.reading=!1,eJ(et,eH));return!eH.ended&&(eH.length=eq?et=eq:(et--,et|=et>>>1,et|=et>>>2,et|=et>>>4,et|=et>>>8,et|=et>>>16,et++),et}function eG(et,ei){return et<=0||0===ei.length&&ei.ended?0:ei.objectMode?1:et!=et?ei.flowing&&ei.length?ei.buffer.head.data.length:ei.length:(et>ei.highWaterMark&&(ei.highWaterMark=eZ(et)),et<=ei.length)?et:ei.ended?ei.length:(ei.needReadable=!0,0)}function eW(et,ei){if(em("onEofChunk"),!ei.ended){if(ei.decoder){var es=ei.decoder.end();es&&es.length&&(ei.buffer.push(es),ei.length+=ei.objectMode?1:es.length)}ei.ended=!0,ei.sync?eK(et):(ei.needReadable=!1,ei.emittedReadable||(ei.emittedReadable=!0,e$(et)))}}function eK(et){var ei=et._readableState;em("emitReadable",ei.needReadable,ei.emittedReadable),ei.needReadable=!1,ei.emittedReadable||(em("emitReadable",ei.flowing),ei.emittedReadable=!0,ed.nextTick(e$,et))}function e$(et){var ei=et._readableState;em("emitReadable_",ei.destroyed,ei.length,ei.ended),!ei.destroyed&&(ei.length||ei.ended)&&(et.emit("readable"),ei.emittedReadable=!1),ei.needReadable=!ei.flowing&&!ei.ended&&ei.length<=ei.highWaterMark,e3(et)}function eJ(et,ei){ei.readingMore||(ei.readingMore=!0,ed.nextTick(eY,et,ei))}function eY(et,ei){for(;!ei.reading&&!ei.ended&&(ei.length0,ei.resumeScheduled&&!ei.paused?ei.flowing=!0:et.listenerCount("data")>0&&et.resume()}function e1(et){em("readable nexttick read 0"),et.read(0)}function e2(et,ei){ei.resumeScheduled||(ei.resumeScheduled=!0,ed.nextTick(e4,et,ei))}function e4(et,ei){em("resume",ei.reading),ei.reading||et.read(0),ei.resumeScheduled=!1,et.emit("resume"),e3(et),ei.flowing&&!ei.reading&&et.read(0)}function e3(et){var ei=et._readableState;for(em("flow",ei.flowing);ei.flowing&&null!==et.read(););}function e6(et,ei){var es;return 0===ei.length?null:(ei.objectMode?es=ei.buffer.shift():!et||et>=ei.length?(es=ei.decoder?ei.buffer.join(""):1===ei.buffer.length?ei.buffer.first():ei.buffer.concat(ei.length),ei.buffer.clear()):es=ei.buffer.consume(et,ei.decoder),es)}function e0(et){var ei=et._readableState;em("endReadable",ei.endEmitted),ei.endEmitted||(ei.ended=!0,ed.nextTick(e8,ei,et))}function e8(et,ei){if(em("endReadableNT",et.endEmitted,et.length),!et.endEmitted&&0===et.length&&(et.endEmitted=!0,ei.readable=!1,ei.emit("end"),et.autoDestroy)){var es=ei._writableState;(!es||es.autoDestroy&&es.finished)&&ei.destroy()}}function e5(et,ei){for(var es=0,ef=et.length;es=es.highWaterMark:es.length>0)||es.ended))return em("read: emitReadable",es.length,es.ended),0===es.length&&es.ended?e0(this):eK(this),null;if(0===(et=eG(et,es))&&es.ended)return 0===es.length&&e0(this),null;var eu=es.needReadable;return em("need readable",eu),(0===es.length||es.length-et0?e6(et,es):null)?(es.needReadable=es.length<=es.highWaterMark,et=0):(es.length-=et,es.awaitDrain=0),0===es.length&&(es.ended||(es.needReadable=!0),ef!==et&&es.ended&&e0(this)),null!==ei&&this.emit("data",ei),ei},ej.prototype._read=function(et){eT(this,new eP("_read()"))},ej.prototype.pipe=function(et,ei){var es=this,ef=this._readableState;switch(ef.pipesCount){case 0:ef.pipes=et;break;case 1:ef.pipes=[ef.pipes,et];break;default:ef.pipes.push(et)}ef.pipesCount+=1,em("pipe count=%d opts=%j",ef.pipesCount,ei);var eu=ei&&!1===ei.end||et===ed.stdout||et===ed.stderr?ew:ez;function eH(et,ei){em("onunpipe"),et===es&&ei&&!1===ei.hasUnpiped&&(ei.hasUnpiped=!0,eL())}function ez(){em("onend"),et.end()}ef.endEmitted?ed.nextTick(eu):es.once("end",eu),et.on("unpipe",eH);var eV=eX(es);et.on("drain",eV);var eg=!1;function eL(){em("cleanup"),et.removeListener("close",eC),et.removeListener("finish",ex),et.removeListener("drain",eV),et.removeListener("error",ey),et.removeListener("unpipe",eH),es.removeListener("end",ez),es.removeListener("end",ew),es.removeListener("data",eb),eg=!0,ef.awaitDrain&&(!et._writableState||et._writableState.needDrain)&&eV()}function eb(ei){em("ondata");var eu=et.write(ei);em("dest.write",eu),!1===eu&&((1===ef.pipesCount&&ef.pipes===et||ef.pipesCount>1&&-1!==e5(ef.pipes,et))&&!eg&&(em("false write response, pause",ef.awaitDrain),ef.awaitDrain++),es.pause())}function ey(ei){em("onerror",ei),ew(),et.removeListener("error",ey),0===eM(et,"error")&&eT(et,ei)}function eC(){et.removeListener("finish",ex),ew()}function ex(){em("onfinish"),et.removeListener("close",eC),ew()}function ew(){em("unpipe"),es.unpipe(et)}return es.on("data",eb),eR(et,"error",ey),et.once("close",eC),et.once("finish",ex),et.emit("pipe",es),ef.flowing||(em("pipe resume"),es.resume()),et},ej.prototype.unpipe=function(et){var ei=this._readableState,es={hasUnpiped:!1};if(0===ei.pipesCount)return this;if(1===ei.pipesCount)return et&&et!==ei.pipes||(et||(et=ei.pipes),ei.pipes=null,ei.pipesCount=0,ei.flowing=!1,et&&et.emit("unpipe",this,es)),this;if(!et){var ef=ei.pipes,eu=ei.pipesCount;ei.pipes=null,ei.pipesCount=0,ei.flowing=!1;for(var ed=0;ed0,!1!==ef.flowing&&this.resume()):"readable"!==et||ef.endEmitted||ef.readableListening||(ef.readableListening=ef.needReadable=!0,ef.flowing=!1,ef.emittedReadable=!1,em("on readable",ef.length,ef.reading),ef.length?eK(this):ef.reading||ed.nextTick(e1,this)),es},ej.prototype.addListener=ej.prototype.on,ej.prototype.removeListener=function(et,ei){var es=eg.prototype.removeListener.call(this,et,ei);return"readable"===et&&ed.nextTick(eQ,this),es},ej.prototype.removeAllListeners=function(et){var ei=eg.prototype.removeAllListeners.apply(this,arguments);return("readable"===et||void 0===et)&&ed.nextTick(eQ,this),ei},ej.prototype.resume=function(){var et=this._readableState;return et.flowing||(em("resume"),et.flowing=!et.readableListening,e2(this,et)),et.paused=!1,this},ej.prototype.pause=function(){return em("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(em("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},ej.prototype.wrap=function(et){var ei=this,es=this._readableState,ef=!1;for(var eu in et.on("end",function(){if(em("wrapped end"),es.decoder&&!es.ended){var et=es.decoder.end();et&&et.length&&ei.push(et)}ei.push(null)}),et.on("data",function(eu){em("wrapped data"),es.decoder&&(eu=es.decoder.write(eu)),(!es.objectMode||null!=eu)&&(es.objectMode||eu&&eu.length)&&(ei.push(eu)||(ef=!0,et.pause()))}),et)void 0===this[eu]&&"function"==typeof et[eu]&&(this[eu]=function(ei){return function(){return et[ei].apply(et,arguments)}}(eu));for(var ed=0;ed-1))throw new eB(et);return this._writableState.defaultEncoding=et,this},Object.defineProperty(eO.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(eO.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),eO.prototype._write=function(et,ei,es){es(new eN("_write()"))},eO.prototype._writev=null,eO.prototype.end=function(et,ei,es){var ef=this._writableState;return"function"==typeof et?(es=et,et=null,ei=null):"function"==typeof ei&&(es=ei,ei=null),null!=et&&this.write(et,ei),ef.corked&&(ef.corked=1,this.uncork()),ef.ending||e2(this,ef,es),this},Object.defineProperty(eO.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(eO.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(et){this._writableState&&(this._writableState.destroyed=et)}}),eO.prototype.destroy=ey.destroy,eO.prototype._undestroy=ey.undestroy,eO.prototype._destroy=function(et,ei){ei(et)}},6871:function(et,ei,es){"use strict";function ef(et,ei,es){return ei in et?Object.defineProperty(et,ei,{value:es,enumerable:!0,configurable:!0,writable:!0}):et[ei]=es,et}var eu,em=es(9698),eH=Symbol("lastResolve"),ez=Symbol("lastReject"),eV=Symbol("error"),eM=Symbol("ended"),eg=Symbol("lastPromise"),eL=Symbol("handlePromise"),eb=Symbol("stream");function ey(et,ei){return{value:et,done:ei}}function eC(et){var ei=et[eH];if(null!==ei){var es=et[eb].read();null!==es&&(et[eg]=null,et[eH]=null,et[ez]=null,ei(ey(es,!1)))}}function ex(et){ed.nextTick(eC,et)}function ew(et,ei){return function(es,ef){et.then(function(){if(ei[eM]){es(ey(void 0,!0));return}ei[eL](es,ef)},ef)}}var eN=Object.getPrototypeOf(function(){}),eS=Object.setPrototypeOf((ef(eu={get stream(){return this[eb]},next:function(){var et,ei=this,es=this[eV];if(null!==es)return Promise.reject(es);if(this[eM])return Promise.resolve(ey(void 0,!0));if(this[eb].destroyed)return new Promise(function(et,es){ed.nextTick(function(){ei[eV]?es(ei[eV]):et(ey(void 0,!0))})});var ef=this[eg];if(ef)et=new Promise(ew(ef,this));else{var eu=this[eb].read();if(null!==eu)return Promise.resolve(ey(eu,!1));et=new Promise(this[eL])}return this[eg]=et,et}},Symbol.asyncIterator,function(){return this}),ef(eu,"return",function(){var et=this;return new Promise(function(ei,es){et[eb].destroy(null,function(et){if(et){es(et);return}ei(ey(void 0,!0))})})}),eu),eN),eA=function(et){var ei,es=Object.create(eS,(ef(ei={},eb,{value:et,writable:!0}),ef(ei,eH,{value:null,writable:!0}),ef(ei,ez,{value:null,writable:!0}),ef(ei,eV,{value:null,writable:!0}),ef(ei,eM,{value:et._readableState.endEmitted,writable:!0}),ef(ei,eL,{value:function(et,ei){var ef=es[eb].read();ef?(es[eg]=null,es[eH]=null,es[ez]=null,et(ey(ef,!1))):(es[eH]=et,es[ez]=ei)},writable:!0}),ei));return es[eg]=null,em(et,function(et){if(et&&"ERR_STREAM_PREMATURE_CLOSE"!==et.code){var ei=es[ez];null!==ei&&(es[eg]=null,es[eH]=null,es[ez]=null,ei(et)),es[eV]=et;return}var ef=es[eH];null!==ef&&(es[eg]=null,es[eH]=null,es[ez]=null,ef(ey(void 0,!0))),es[eM]=!0}),et.on("readable",ex.bind(null,es)),es};et.exports=eA},4379:function(et,ei,es){"use strict";function ef(et,ei){var es=Object.keys(et);if(Object.getOwnPropertySymbols){var ef=Object.getOwnPropertySymbols(et);ei&&(ef=ef.filter(function(ei){return Object.getOwnPropertyDescriptor(et,ei).enumerable})),es.push.apply(es,ef)}return es}function eu(et){for(var ei=1;ei0?this.tail.next=ei:this.head=ei,this.tail=ei,++this.length}},{key:"unshift",value:function(et){var ei={data:et,next:this.head};0===this.length&&(this.tail=ei),this.head=ei,++this.length}},{key:"shift",value:function(){if(0!==this.length){var et=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,et}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(et){if(0===this.length)return"";for(var ei=this.head,es=""+ei.data;ei=ei.next;)es+=et+ei.data;return es}},{key:"concat",value:function(et){if(0===this.length)return eV.alloc(0);for(var ei=eV.allocUnsafe(et>>>0),es=this.head,ef=0;es;)eL(es.data,ei,ef),ef+=es.data.length,es=es.next;return ei}},{key:"consume",value:function(et,ei){var es;return eteu.length?eu.length:et;if(ed===eu.length?ef+=eu:ef+=eu.slice(0,et),0==(et-=ed)){ed===eu.length?(++es,ei.next?this.head=ei.next:this.head=this.tail=null):(this.head=ei,ei.data=eu.slice(ed));break}++es}return this.length-=es,ef}},{key:"_getBuffer",value:function(et){var ei=eV.allocUnsafe(et),es=this.head,ef=1;for(es.data.copy(ei),et-=es.data.length;es=es.next;){var eu=es.data,ed=et>eu.length?eu.length:et;if(eu.copy(ei,ei.length-et,0,ed),0==(et-=ed)){ed===eu.length?(++ef,es.next?this.head=es.next:this.head=this.tail=null):(this.head=es,es.data=eu.slice(ed));break}++ef}return this.length-=ef,ei}},{key:eg,value:function(et,ei){return eM(this,eu({},ei,{depth:0,customInspect:!1}))}}]),et}()},7025:function(et){"use strict";function ei(et,ei){var eu=this,eH=this._readableState&&this._readableState.destroyed,ez=this._writableState&&this._writableState.destroyed;return eH||ez?(ei?ei(et):et&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,ed.nextTick(em,this,et)):ed.nextTick(em,this,et)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(et||null,function(et){!ei&&et?eu._writableState?eu._writableState.errorEmitted?ed.nextTick(ef,eu):(eu._writableState.errorEmitted=!0,ed.nextTick(es,eu,et)):ed.nextTick(es,eu,et):ei?(ed.nextTick(ef,eu),ei(et)):ed.nextTick(ef,eu)}),this)}function es(et,ei){em(et,ei),ef(et)}function ef(et){(!et._writableState||et._writableState.emitClose)&&(!et._readableState||et._readableState.emitClose)&&et.emit("close")}function eu(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function em(et,ei){et.emit("error",ei)}function eH(et,ei){var es=et._readableState,ef=et._writableState;es&&es.autoDestroy||ef&&ef.autoDestroy?et.destroy(ei):et.emit("error",ei)}et.exports={destroy:ei,undestroy:eu,errorOrDestroy:eH}},9698:function(et,ei,es){"use strict";var ef=es(4646).q.ERR_STREAM_PREMATURE_CLOSE;function eu(et){var ei=!1;return function(){if(!ei){ei=!0;for(var es=arguments.length,ef=Array(es),eu=0;eu0,function(ei){et||(et=ei),ei&&ed.forEach(eg),em||(ed.forEach(eg),eu(et))})});return es.reduce(eL)}et.exports=ey},6776:function(et,ei,es){"use strict";var ef=es(4646).q.ERR_INVALID_OPT_VALUE;function eu(et,ei,es){return null!=et.highWaterMark?et.highWaterMark:ei?et[es]:null}function ed(et,ei,es,ed){var em=eu(ei,ed,es);if(null!=em){if(!(isFinite(em)&&Math.floor(em)===em)||em<0){var eH=ed?es:"highWaterMark";throw new ef(eH,em)}return Math.floor(em)}return et.objectMode?16:16384}et.exports={getHighWaterMark:ed}},4678:function(et,ei,es){et.exports=es(2781)},3726:function(et,ei,es){var ef=es(2781);"disable"===ed.env.READABLE_STREAM&&ef?(et.exports=ef.Readable,Object.assign(et.exports,ef),et.exports.Stream=ef):((ei=et.exports=es(1709)).Stream=ef||ei,ei.Readable=ei,ei.Writable=es(7337),ei.Duplex=es(2403),ei.Transform=es(1170),ei.PassThrough=es(7889),ei.finished=es(9698),ei.pipeline=es(8442))},3225:function(et,ei,es){"use strict";var ef=es(4300).Buffer,eu=es(3782),ed=es(9029),em=Array(16),eH=[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],ez=[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],eV=[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],eM=[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],eg=[0,1518500249,1859775393,2400959708,2840853838],eL=[1352829926,1548603684,1836072691,2053994217,0];function eb(){ed.call(this,64),this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520}function ey(et,ei){return et<>>32-ei}function eC(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei^es^ef)+ed+em|0,eH)+eu|0}function ex(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei&es|~ei&ef)+ed+em|0,eH)+eu|0}function ew(et,ei,es,ef,eu,ed,em,eH){return ey(et+((ei|~es)^ef)+ed+em|0,eH)+eu|0}function eN(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei&ef|es&~ef)+ed+em|0,eH)+eu|0}function eS(et,ei,es,ef,eu,ed,em,eH){return ey(et+(ei^(es|~ef))+ed+em|0,eH)+eu|0}eu(eb,ed),eb.prototype._update=function(){for(var et,ei,es=em,ef=0;ef<16;++ef)es[ef]=this._block.readInt32LE(4*ef);for(var eu=0|this._a,ed=0|this._b,eb=0|this._c,eA=0|this._d,e_=0|this._e,eE=0|this._a,eP=0|this._b,eB=0|this._c,eT=0|this._d,eI=0|this._e,eR=0;eR<80;eR+=1)eR<16?(et=eC(eu,ed,eb,eA,e_,es[eH[eR]],eg[0],eV[eR]),ei=eS(eE,eP,eB,eT,eI,es[ez[eR]],eL[0],eM[eR])):eR<32?(et=ex(eu,ed,eb,eA,e_,es[eH[eR]],eg[1],eV[eR]),ei=eN(eE,eP,eB,eT,eI,es[ez[eR]],eL[1],eM[eR])):eR<48?(et=ew(eu,ed,eb,eA,e_,es[eH[eR]],eg[2],eV[eR]),ei=ew(eE,eP,eB,eT,eI,es[ez[eR]],eL[2],eM[eR])):eR<64?(et=eN(eu,ed,eb,eA,e_,es[eH[eR]],eg[3],eV[eR]),ei=ex(eE,eP,eB,eT,eI,es[ez[eR]],eL[3],eM[eR])):(et=eS(eu,ed,eb,eA,e_,es[eH[eR]],eg[4],eV[eR]),ei=eC(eE,eP,eB,eT,eI,es[ez[eR]],eL[4],eM[eR])),eu=e_,e_=eA,eA=ey(eb,10),eb=ed,ed=et,eE=eI,eI=eT,eT=ey(eB,10),eB=eP,eP=ei;var eO=this._b+eb+eT|0;this._b=this._c+eA+eI|0,this._c=this._d+e_+eE|0,this._d=this._e+eu+eP|0,this._e=this._a+ed+eB|0,this._a=eO},eb.prototype._digest=function(){this._block[this._blockOffset++]=128,this._blockOffset>56&&(this._block.fill(0,this._blockOffset,64),this._update(),this._blockOffset=0),this._block.fill(0,this._blockOffset,56),this._block.writeUInt32LE(this._length[0],56),this._block.writeUInt32LE(this._length[1],60),this._update();var et=ef.alloc?ef.alloc(20):new ef(20);return et.writeInt32LE(this._a,0),et.writeInt32LE(this._b,4),et.writeInt32LE(this._c,8),et.writeInt32LE(this._d,12),et.writeInt32LE(this._e,16),et},et.exports=eb},5055:function(et,ei,es){var ef=es(4300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},6911:function(et,ei,es){/*! safe-buffer. MIT License. Feross Aboukhadijeh */var ef=es(4300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},2858:function(et,ei,es){var ef=es(6911).Buffer;function eu(et,ei){this._block=ef.alloc(et),this._finalSize=ei,this._blockSize=et,this._len=0}eu.prototype.update=function(et,ei){"string"==typeof et&&(ei=ei||"utf8",et=ef.from(et,ei));for(var es=this._block,eu=this._blockSize,ed=et.length,em=this._len,eH=0;eH=this._finalSize&&(this._update(this._block),this._block.fill(0));var es=8*this._len;if(es<=4294967295)this._block.writeUInt32BE(es,this._blockSize-4);else{var ef=(4294967295&es)>>>0,eu=(es-ef)/4294967296;this._block.writeUInt32BE(eu,this._blockSize-8),this._block.writeUInt32BE(ef,this._blockSize-4)}this._update(this._block);var ed=this._hash();return et?ed.toString(et):ed},eu.prototype._update=function(){throw Error("_update must be implemented by subclass")},et.exports=eu},4371:function(et,ei,es){var ef=et.exports=function(et){var ei=ef[et=et.toLowerCase()];if(!ei)throw Error(et+" is not supported (we accept pull requests)");return new ei};ef.sha=es(4018),ef.sha1=es(4179),ef.sha224=es(532),ef.sha256=es(1843),ef.sha384=es(7455),ef.sha512=es(9934)},4018:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[1518500249,1859775393,-1894007588,-899497514],eH=Array(80);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et){return et<<5|et>>>27}function eM(et){return et<<30|et>>>2}function eg(et,ei,es,ef){return 0===et?ei&es|~ei&ef:2===et?ei&es|ei&ef|es&ef:ei^es^ef}ef(ez,eu),ez.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0;ez<16;++ez)ei[ez]=et.readInt32BE(4*ez);for(;ez<80;++ez)ei[ez]=ei[ez-3]^ei[ez-8]^ei[ez-14]^ei[ez-16];for(var eL=0;eL<80;++eL){var eb=~~(eL/20),ey=eV(es)+eg(eb,ef,eu,ed)+eH+ei[eL]+em[eb]|0;eH=ed,ed=eu,eu=eM(ef),ef=es,es=ey}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(20);return et.writeInt32BE(0|this._a,0),et.writeInt32BE(0|this._b,4),et.writeInt32BE(0|this._c,8),et.writeInt32BE(0|this._d,12),et.writeInt32BE(0|this._e,16),et},et.exports=ez},4179:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[1518500249,1859775393,-1894007588,-899497514],eH=Array(80);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et){return et<<1|et>>>31}function eM(et){return et<<5|et>>>27}function eg(et){return et<<30|et>>>2}function eL(et,ei,es,ef){return 0===et?ei&es|~ei&ef:2===et?ei&es|ei&ef|es&ef:ei^es^ef}ef(ez,eu),ez.prototype.init=function(){return this._a=1732584193,this._b=4023233417,this._c=2562383102,this._d=271733878,this._e=3285377520,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0;ez<16;++ez)ei[ez]=et.readInt32BE(4*ez);for(;ez<80;++ez)ei[ez]=eV(ei[ez-3]^ei[ez-8]^ei[ez-14]^ei[ez-16]);for(var eb=0;eb<80;++eb){var ey=~~(eb/20),eC=eM(es)+eL(ey,ef,eu,ed)+eH+ei[eb]+em[ey]|0;eH=ed,ed=eu,eu=eg(ef),ef=es,es=eC}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(20);return et.writeInt32BE(0|this._a,0),et.writeInt32BE(0|this._b,4),et.writeInt32BE(0|this._c,8),et.writeInt32BE(0|this._d,12),et.writeInt32BE(0|this._e,16),et},et.exports=ez},532:function(et,ei,es){var ef=es(3782),eu=es(1843),ed=es(2858),em=es(6911).Buffer,eH=Array(64);function ez(){this.init(),this._w=eH,ed.call(this,64,56)}ef(ez,eu),ez.prototype.init=function(){return this._a=3238371032,this._b=914150663,this._c=812702999,this._d=4144912697,this._e=4290775857,this._f=1750603025,this._g=1694076839,this._h=3204075428,this},ez.prototype._hash=function(){var et=em.allocUnsafe(28);return et.writeInt32BE(this._a,0),et.writeInt32BE(this._b,4),et.writeInt32BE(this._c,8),et.writeInt32BE(this._d,12),et.writeInt32BE(this._e,16),et.writeInt32BE(this._f,20),et.writeInt32BE(this._g,24),et},et.exports=ez},1843:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[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],eH=Array(64);function ez(){this.init(),this._w=eH,eu.call(this,64,56)}function eV(et,ei,es){return es^et&(ei^es)}function eM(et,ei,es){return et&ei|es&(et|ei)}function eg(et){return(et>>>2|et<<30)^(et>>>13|et<<19)^(et>>>22|et<<10)}function eL(et){return(et>>>6|et<<26)^(et>>>11|et<<21)^(et>>>25|et<<7)}function eb(et){return(et>>>7|et<<25)^(et>>>18|et<<14)^et>>>3}function ey(et){return(et>>>17|et<<15)^(et>>>19|et<<13)^et>>>10}ef(ez,eu),ez.prototype.init=function(){return this._a=1779033703,this._b=3144134277,this._c=1013904242,this._d=2773480762,this._e=1359893119,this._f=2600822924,this._g=528734635,this._h=1541459225,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._a,ef=0|this._b,eu=0|this._c,ed=0|this._d,eH=0|this._e,ez=0|this._f,eC=0|this._g,ex=0|this._h,ew=0;ew<16;++ew)ei[ew]=et.readInt32BE(4*ew);for(;ew<64;++ew)ei[ew]=ey(ei[ew-2])+ei[ew-7]+eb(ei[ew-15])+ei[ew-16]|0;for(var eN=0;eN<64;++eN){var eS=ex+eL(eH)+eV(eH,ez,eC)+em[eN]+ei[eN]|0,eA=eg(es)+eM(es,ef,eu)|0;ex=eC,eC=ez,ez=eH,eH=ed+eS|0,ed=eu,eu=ef,ef=es,es=eS+eA|0}this._a=es+this._a|0,this._b=ef+this._b|0,this._c=eu+this._c|0,this._d=ed+this._d|0,this._e=eH+this._e|0,this._f=ez+this._f|0,this._g=eC+this._g|0,this._h=ex+this._h|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(32);return et.writeInt32BE(this._a,0),et.writeInt32BE(this._b,4),et.writeInt32BE(this._c,8),et.writeInt32BE(this._d,12),et.writeInt32BE(this._e,16),et.writeInt32BE(this._f,20),et.writeInt32BE(this._g,24),et.writeInt32BE(this._h,28),et},et.exports=ez},7455:function(et,ei,es){var ef=es(3782),eu=es(9934),ed=es(2858),em=es(6911).Buffer,eH=Array(160);function ez(){this.init(),this._w=eH,ed.call(this,128,112)}ef(ez,eu),ez.prototype.init=function(){return this._ah=3418070365,this._bh=1654270250,this._ch=2438529370,this._dh=355462360,this._eh=1731405415,this._fh=2394180231,this._gh=3675008525,this._hh=1203062813,this._al=3238371032,this._bl=914150663,this._cl=812702999,this._dl=4144912697,this._el=4290775857,this._fl=1750603025,this._gl=1694076839,this._hl=3204075428,this},ez.prototype._hash=function(){var et=em.allocUnsafe(48);function ei(ei,es,ef){et.writeInt32BE(ei,ef),et.writeInt32BE(es,ef+4)}return ei(this._ah,this._al,0),ei(this._bh,this._bl,8),ei(this._ch,this._cl,16),ei(this._dh,this._dl,24),ei(this._eh,this._el,32),ei(this._fh,this._fl,40),et},et.exports=ez},9934:function(et,ei,es){var ef=es(3782),eu=es(2858),ed=es(6911).Buffer,em=[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],eH=Array(160);function ez(){this.init(),this._w=eH,eu.call(this,128,112)}function eV(et,ei,es){return es^et&(ei^es)}function eM(et,ei,es){return et&ei|es&(et|ei)}function eg(et,ei){return(et>>>28|ei<<4)^(ei>>>2|et<<30)^(ei>>>7|et<<25)}function eL(et,ei){return(et>>>14|ei<<18)^(et>>>18|ei<<14)^(ei>>>9|et<<23)}function eb(et,ei){return(et>>>1|ei<<31)^(et>>>8|ei<<24)^et>>>7}function ey(et,ei){return(et>>>1|ei<<31)^(et>>>8|ei<<24)^(et>>>7|ei<<25)}function eC(et,ei){return(et>>>19|ei<<13)^(ei>>>29|et<<3)^et>>>6}function ex(et,ei){return(et>>>19|ei<<13)^(ei>>>29|et<<3)^(et>>>6|ei<<26)}function ew(et,ei){return et>>>0>>0?1:0}ef(ez,eu),ez.prototype.init=function(){return this._ah=1779033703,this._bh=3144134277,this._ch=1013904242,this._dh=2773480762,this._eh=1359893119,this._fh=2600822924,this._gh=528734635,this._hh=1541459225,this._al=4089235720,this._bl=2227873595,this._cl=4271175723,this._dl=1595750129,this._el=2917565137,this._fl=725511199,this._gl=4215389547,this._hl=327033209,this},ez.prototype._update=function(et){for(var ei=this._w,es=0|this._ah,ef=0|this._bh,eu=0|this._ch,ed=0|this._dh,eH=0|this._eh,ez=0|this._fh,eN=0|this._gh,eS=0|this._hh,eA=0|this._al,e_=0|this._bl,eE=0|this._cl,eP=0|this._dl,eB=0|this._el,eT=0|this._fl,eI=0|this._gl,eR=0|this._hl,eO=0;eO<32;eO+=2)ei[eO]=et.readInt32BE(4*eO),ei[eO+1]=et.readInt32BE(4*eO+4);for(;eO<160;eO+=2){var ej=ei[eO-30],eD=ei[eO-30+1],eF=eb(ej,eD),eU=ey(eD,ej);ej=ei[eO-4],eD=ei[eO-4+1];var eq=eC(ej,eD),eZ=ex(eD,ej),eG=ei[eO-14],eW=ei[eO-14+1],eK=ei[eO-32],e$=ei[eO-32+1],eJ=eU+eW|0,eY=eF+eG+ew(eJ,eU)|0;eY=(eY=eY+eq+ew(eJ=eJ+eZ|0,eZ)|0)+eK+ew(eJ=eJ+e$|0,e$)|0,ei[eO]=eY,ei[eO+1]=eJ}for(var eX=0;eX<160;eX+=2){eY=ei[eX],eJ=ei[eX+1];var eQ=eM(es,ef,eu),e1=eM(eA,e_,eE),e2=eg(es,eA),e4=eg(eA,es),e3=eL(eH,eB),e6=eL(eB,eH),e0=em[eX],e8=em[eX+1],e5=eV(eH,ez,eN),e7=eV(eB,eT,eI),e9=eR+e6|0,cc=eS+e3+ew(e9,eR)|0;cc=(cc=(cc=cc+e5+ew(e9=e9+e7|0,e7)|0)+e0+ew(e9=e9+e8|0,e8)|0)+eY+ew(e9=e9+eJ|0,eJ)|0;var ci=e4+e1|0,cs=e2+eQ+ew(ci,e4)|0;eS=eN,eR=eI,eN=ez,eI=eT,ez=eH,eT=eB,eH=ed+cc+ew(eB=eP+e9|0,eP)|0,ed=eu,eP=eE,eu=ef,eE=e_,ef=es,e_=eA,es=cc+cs+ew(eA=e9+ci|0,e9)|0}this._al=this._al+eA|0,this._bl=this._bl+e_|0,this._cl=this._cl+eE|0,this._dl=this._dl+eP|0,this._el=this._el+eB|0,this._fl=this._fl+eT|0,this._gl=this._gl+eI|0,this._hl=this._hl+eR|0,this._ah=this._ah+es+ew(this._al,eA)|0,this._bh=this._bh+ef+ew(this._bl,e_)|0,this._ch=this._ch+eu+ew(this._cl,eE)|0,this._dh=this._dh+ed+ew(this._dl,eP)|0,this._eh=this._eh+eH+ew(this._el,eB)|0,this._fh=this._fh+ez+ew(this._fl,eT)|0,this._gh=this._gh+eN+ew(this._gl,eI)|0,this._hh=this._hh+eS+ew(this._hl,eR)|0},ez.prototype._hash=function(){var et=ed.allocUnsafe(64);function ei(ei,es,ef){et.writeInt32BE(ei,ef),et.writeInt32BE(es,ef+4)}return ei(this._ah,this._al,0),ei(this._bh,this._bl,8),ei(this._ch,this._cl,16),ei(this._dh,this._dl,24),ei(this._eh,this._el,32),ei(this._fh,this._fl,40),ei(this._gh,this._gl,48),ei(this._hh,this._hl,56),et},et.exports=ez},3704:function(et,ei,es){"use strict";var ef=es(5055).Buffer,eu=ef.isEncoding||function(et){switch((et=""+et)&&et.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 ed(et){var ei;if(!et)return"utf8";for(;;)switch(et){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 et;default:if(ei)return;et=(""+et).toLowerCase(),ei=!0}}function em(et){var ei=ed(et);if("string"!=typeof ei&&(ef.isEncoding===eu||!eu(et)))throw Error("Unknown encoding: "+et);return ei||et}function eH(et){var ei;switch(this.encoding=em(et),this.encoding){case"utf16le":this.text=ey,this.end=eC,ei=4;break;case"utf8":this.fillLast=eg,ei=4;break;case"base64":this.text=ex,this.end=ew,ei=3;break;default:this.write=eN,this.end=eS;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ef.allocUnsafe(ei)}function ez(et){return et<=127?0:et>>5==6?2:et>>4==14?3:et>>3==30?4:et>>6==2?-1:-2}function eV(et,ei,es){var ef=ei.length-1;if(ef=0?(eu>0&&(et.lastNeed=eu-1),eu):--ef=0?(eu>0&&(et.lastNeed=eu-2),eu):--ef=0?(eu>0&&(2===eu?eu=0:et.lastNeed=eu-3),eu):0}function eM(et,ei,es){if((192&ei[0])!=128)return et.lastNeed=0,"�";if(et.lastNeed>1&&ei.length>1){if((192&ei[1])!=128)return et.lastNeed=1,"�";if(et.lastNeed>2&&ei.length>2&&(192&ei[2])!=128)return et.lastNeed=2,"�"}}function eg(et){var ei=this.lastTotal-this.lastNeed,es=eM(this,et,ei);return void 0!==es?es:this.lastNeed<=et.length?(et.copy(this.lastChar,ei,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(et.copy(this.lastChar,ei,0,et.length),this.lastNeed-=et.length)}function eL(et,ei){var es=eV(this,et,ei);if(!this.lastNeed)return et.toString("utf8",ei);this.lastTotal=es;var ef=et.length-(es-this.lastNeed);return et.copy(this.lastChar,0,ef),et.toString("utf8",ei,ef)}function eb(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+"�":ei}function ey(et,ei){if((et.length-ei)%2==0){var es=et.toString("utf16le",ei);if(es){var ef=es.charCodeAt(es.length-1);if(ef>=55296&&ef<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1],es.slice(0,-1)}return es}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=et[et.length-1],et.toString("utf16le",ei,et.length-1)}function eC(et){var ei=et&&et.length?this.write(et):"";if(this.lastNeed){var es=this.lastTotal-this.lastNeed;return ei+this.lastChar.toString("utf16le",0,es)}return ei}function ex(et,ei){var es=(et.length-ei)%3;return 0===es?et.toString("base64",ei):(this.lastNeed=3-es,this.lastTotal=3,1===es?this.lastChar[0]=et[et.length-1]:(this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1]),et.toString("base64",ei,et.length-es))}function ew(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+this.lastChar.toString("base64",0,3-this.lastNeed):ei}function eN(et){return et.toString(this.encoding)}function eS(et){return et&&et.length?this.write(et):""}ei.s=eH,eH.prototype.write=function(et){var ei,es;if(0===et.length)return"";if(this.lastNeed){if(void 0===(ei=this.fillLast(et)))return"";es=this.lastNeed,this.lastNeed=0}else es=0;return es1)for(var es=1;esString(et)),es>2)?`one of ${ei} ${et.slice(0,es-1).join(", ")}, or `+et[es-1]:2===es?`one of ${ei} ${et[0]} or ${et[1]}`:`of ${ei} ${et[0]}`}}function eu(et,ei,es){return et.substr(!es||es<0?0:+es,ei.length)===ei}function ed(et,ei,es){return(void 0===es||es>et.length)&&(es=et.length),et.substring(es-ei.length,es)===ei}function em(et,ei,es){return"number"!=typeof es&&(es=0),!(es+ei.length>et.length)&&-1!==et.indexOf(ei,es)}es("ERR_INVALID_OPT_VALUE",function(et,ei){return'The value "'+ei+'" is invalid for option "'+et+'"'},TypeError),es("ERR_INVALID_ARG_TYPE",function(et,ei,es){let eH,ez;if("string"==typeof ei&&eu(ei,"not ")?(eH="must not be",ei=ei.replace(/^not /,"")):eH="must be",ed(et," argument"))ez=`The ${et} ${eH} ${ef(ei,"type")}`;else{let es=em(et,".")?"property":"argument";ez=`The "${et}" ${es} ${eH} ${ef(ei,"type")}`}return ez+`. Received type ${typeof es}`},TypeError),es("ERR_STREAM_PUSH_AFTER_EOF","stream.push() after EOF"),es("ERR_METHOD_NOT_IMPLEMENTED",function(et){return"The "+et+" method is not implemented"}),es("ERR_STREAM_PREMATURE_CLOSE","Premature close"),es("ERR_STREAM_DESTROYED",function(et){return"Cannot call "+et+" after a stream was destroyed"}),es("ERR_MULTIPLE_CALLBACK","Callback called multiple times"),es("ERR_STREAM_CANNOT_PIPE","Cannot pipe, not readable"),es("ERR_STREAM_WRITE_AFTER_END","write after end"),es("ERR_STREAM_NULL_VALUES","May not write null values to stream",TypeError),es("ERR_UNKNOWN_ENCODING",function(et){return"Unknown encoding: "+et},TypeError),es("ERR_STREAM_UNSHIFT_AFTER_END_EVENT","stream.unshift() after end event"),et.exports.q=ei},403:function(et,ei,es){"use strict";var ef=Object.keys||function(et){var ei=[];for(var es in et)ei.push(es);return ei};et.exports=eM;var ed=es(709),em=es(337);es(782)(eM,ed);for(var eH=ef(em.prototype),ez=0;ez0){if("string"==typeof ei||eH.objectMode||Object.getPrototypeOf(ei)===eL.prototype||(ei=ey(ei)),ef)eH.endEmitted?eT(et,new eB):eF(et,eH,ei,!0);else if(eH.ended)eT(et,new eE);else{if(eH.destroyed)return!1;eH.reading=!1,eH.decoder&&!es?(ei=eH.decoder.write(ei),eH.objectMode||0!==ei.length?eF(et,eH,ei,!1):eJ(et,eH)):eF(et,eH,ei,!1)}}else ef||(eH.reading=!1,eJ(et,eH));return!eH.ended&&(eH.length=eq?et=eq:(et--,et|=et>>>1,et|=et>>>2,et|=et>>>4,et|=et>>>8,et|=et>>>16,et++),et}function eG(et,ei){return et<=0||0===ei.length&&ei.ended?0:ei.objectMode?1:et!=et?ei.flowing&&ei.length?ei.buffer.head.data.length:ei.length:(et>ei.highWaterMark&&(ei.highWaterMark=eZ(et)),et<=ei.length)?et:ei.ended?ei.length:(ei.needReadable=!0,0)}function eW(et,ei){if(em("onEofChunk"),!ei.ended){if(ei.decoder){var es=ei.decoder.end();es&&es.length&&(ei.buffer.push(es),ei.length+=ei.objectMode?1:es.length)}ei.ended=!0,ei.sync?eK(et):(ei.needReadable=!1,ei.emittedReadable||(ei.emittedReadable=!0,e$(et)))}}function eK(et){var ei=et._readableState;em("emitReadable",ei.needReadable,ei.emittedReadable),ei.needReadable=!1,ei.emittedReadable||(em("emitReadable",ei.flowing),ei.emittedReadable=!0,eu.nextTick(e$,et))}function e$(et){var ei=et._readableState;em("emitReadable_",ei.destroyed,ei.length,ei.ended),!ei.destroyed&&(ei.length||ei.ended)&&(et.emit("readable"),ei.emittedReadable=!1),ei.needReadable=!ei.flowing&&!ei.ended&&ei.length<=ei.highWaterMark,e3(et)}function eJ(et,ei){ei.readingMore||(ei.readingMore=!0,eu.nextTick(eY,et,ei))}function eY(et,ei){for(;!ei.reading&&!ei.ended&&(ei.length0,ei.resumeScheduled&&!ei.paused?ei.flowing=!0:et.listenerCount("data")>0&&et.resume()}function e1(et){em("readable nexttick read 0"),et.read(0)}function e2(et,ei){ei.resumeScheduled||(ei.resumeScheduled=!0,eu.nextTick(e4,et,ei))}function e4(et,ei){em("resume",ei.reading),ei.reading||et.read(0),ei.resumeScheduled=!1,et.emit("resume"),e3(et),ei.flowing&&!ei.reading&&et.read(0)}function e3(et){var ei=et._readableState;for(em("flow",ei.flowing);ei.flowing&&null!==et.read(););}function e6(et,ei){var es;return 0===ei.length?null:(ei.objectMode?es=ei.buffer.shift():!et||et>=ei.length?(es=ei.decoder?ei.buffer.join(""):1===ei.buffer.length?ei.buffer.first():ei.buffer.concat(ei.length),ei.buffer.clear()):es=ei.buffer.consume(et,ei.decoder),es)}function e0(et){var ei=et._readableState;em("endReadable",ei.endEmitted),ei.endEmitted||(ei.ended=!0,eu.nextTick(e8,ei,et))}function e8(et,ei){if(em("endReadableNT",et.endEmitted,et.length),!et.endEmitted&&0===et.length&&(et.endEmitted=!0,ei.readable=!1,ei.emit("end"),et.autoDestroy)){var es=ei._writableState;(!es||es.autoDestroy&&es.finished)&&ei.destroy()}}function e5(et,ei){for(var es=0,ef=et.length;es=es.highWaterMark:es.length>0)||es.ended))return em("read: emitReadable",es.length,es.ended),0===es.length&&es.ended?e0(this):eK(this),null;if(0===(et=eG(et,es))&&es.ended)return 0===es.length&&e0(this),null;var eu=es.needReadable;return em("need readable",eu),(0===es.length||es.length-et0?e6(et,es):null)?(es.needReadable=es.length<=es.highWaterMark,et=0):(es.length-=et,es.awaitDrain=0),0===es.length&&(es.ended||(es.needReadable=!0),ef!==et&&es.ended&&e0(this)),null!==ei&&this.emit("data",ei),ei},ej.prototype._read=function(et){eT(this,new eP("_read()"))},ej.prototype.pipe=function(et,ei){var es=this,ef=this._readableState;switch(ef.pipesCount){case 0:ef.pipes=et;break;case 1:ef.pipes=[ef.pipes,et];break;default:ef.pipes.push(et)}ef.pipesCount+=1,em("pipe count=%d opts=%j",ef.pipesCount,ei);var ed=ei&&!1===ei.end||et===eu.stdout||et===eu.stderr?ew:ez;function eH(et,ei){em("onunpipe"),et===es&&ei&&!1===ei.hasUnpiped&&(ei.hasUnpiped=!0,eL())}function ez(){em("onend"),et.end()}ef.endEmitted?eu.nextTick(ed):es.once("end",ed),et.on("unpipe",eH);var eV=eX(es);et.on("drain",eV);var eg=!1;function eL(){em("cleanup"),et.removeListener("close",eC),et.removeListener("finish",ex),et.removeListener("drain",eV),et.removeListener("error",ey),et.removeListener("unpipe",eH),es.removeListener("end",ez),es.removeListener("end",ew),es.removeListener("data",eb),eg=!0,ef.awaitDrain&&(!et._writableState||et._writableState.needDrain)&&eV()}function eb(ei){em("ondata");var eu=et.write(ei);em("dest.write",eu),!1===eu&&((1===ef.pipesCount&&ef.pipes===et||ef.pipesCount>1&&-1!==e5(ef.pipes,et))&&!eg&&(em("false write response, pause",ef.awaitDrain),ef.awaitDrain++),es.pause())}function ey(ei){em("onerror",ei),ew(),et.removeListener("error",ey),0===eM(et,"error")&&eT(et,ei)}function eC(){et.removeListener("finish",ex),ew()}function ex(){em("onfinish"),et.removeListener("close",eC),ew()}function ew(){em("unpipe"),es.unpipe(et)}return es.on("data",eb),eR(et,"error",ey),et.once("close",eC),et.once("finish",ex),et.emit("pipe",es),ef.flowing||(em("pipe resume"),es.resume()),et},ej.prototype.unpipe=function(et){var ei=this._readableState,es={hasUnpiped:!1};if(0===ei.pipesCount)return this;if(1===ei.pipesCount)return et&&et!==ei.pipes||(et||(et=ei.pipes),ei.pipes=null,ei.pipesCount=0,ei.flowing=!1,et&&et.emit("unpipe",this,es)),this;if(!et){var ef=ei.pipes,eu=ei.pipesCount;ei.pipes=null,ei.pipesCount=0,ei.flowing=!1;for(var ed=0;ed0,!1!==ef.flowing&&this.resume()):"readable"!==et||ef.endEmitted||ef.readableListening||(ef.readableListening=ef.needReadable=!0,ef.flowing=!1,ef.emittedReadable=!1,em("on readable",ef.length,ef.reading),ef.length?eK(this):ef.reading||eu.nextTick(e1,this)),es},ej.prototype.addListener=ej.prototype.on,ej.prototype.removeListener=function(et,ei){var es=eg.prototype.removeListener.call(this,et,ei);return"readable"===et&&eu.nextTick(eQ,this),es},ej.prototype.removeAllListeners=function(et){var ei=eg.prototype.removeAllListeners.apply(this,arguments);return("readable"===et||void 0===et)&&eu.nextTick(eQ,this),ei},ej.prototype.resume=function(){var et=this._readableState;return et.flowing||(em("resume"),et.flowing=!et.readableListening,e2(this,et)),et.paused=!1,this},ej.prototype.pause=function(){return em("call pause flowing=%j",this._readableState.flowing),!1!==this._readableState.flowing&&(em("pause"),this._readableState.flowing=!1,this.emit("pause")),this._readableState.paused=!0,this},ej.prototype.wrap=function(et){var ei=this,es=this._readableState,ef=!1;for(var eu in et.on("end",function(){if(em("wrapped end"),es.decoder&&!es.ended){var et=es.decoder.end();et&&et.length&&ei.push(et)}ei.push(null)}),et.on("data",function(eu){em("wrapped data"),es.decoder&&(eu=es.decoder.write(eu)),(!es.objectMode||null!=eu)&&(es.objectMode||eu&&eu.length)&&(ei.push(eu)||(ef=!0,et.pause()))}),et)void 0===this[eu]&&"function"==typeof et[eu]&&(this[eu]=function(ei){return function(){return et[ei].apply(et,arguments)}}(eu));for(var ed=0;ed-1))throw new eB(et);return this._writableState.defaultEncoding=et,this},Object.defineProperty(eO.prototype,"writableBuffer",{enumerable:!1,get:function(){return this._writableState&&this._writableState.getBuffer()}}),Object.defineProperty(eO.prototype,"writableHighWaterMark",{enumerable:!1,get:function(){return this._writableState.highWaterMark}}),eO.prototype._write=function(et,ei,es){es(new eN("_write()"))},eO.prototype._writev=null,eO.prototype.end=function(et,ei,es){var ef=this._writableState;return"function"==typeof et?(es=et,et=null,ei=null):"function"==typeof ei&&(es=ei,ei=null),null!=et&&this.write(et,ei),ef.corked&&(ef.corked=1,this.uncork()),ef.ending||e2(this,ef,es),this},Object.defineProperty(eO.prototype,"writableLength",{enumerable:!1,get:function(){return this._writableState.length}}),Object.defineProperty(eO.prototype,"destroyed",{enumerable:!1,get:function(){return void 0!==this._writableState&&this._writableState.destroyed},set:function(et){this._writableState&&(this._writableState.destroyed=et)}}),eO.prototype.destroy=ey.destroy,eO.prototype._undestroy=ey.undestroy,eO.prototype._destroy=function(et,ei){ei(et)}},871:function(et,ei,es){"use strict";function ef(et,ei,es){return ei in et?Object.defineProperty(et,ei,{value:es,enumerable:!0,configurable:!0,writable:!0}):et[ei]=es,et}var ed,em=es(698),eH=Symbol("lastResolve"),ez=Symbol("lastReject"),eV=Symbol("error"),eM=Symbol("ended"),eg=Symbol("lastPromise"),eL=Symbol("handlePromise"),eb=Symbol("stream");function ey(et,ei){return{value:et,done:ei}}function eC(et){var ei=et[eH];if(null!==ei){var es=et[eb].read();null!==es&&(et[eg]=null,et[eH]=null,et[ez]=null,ei(ey(es,!1)))}}function ex(et){eu.nextTick(eC,et)}function ew(et,ei){return function(es,ef){et.then(function(){if(ei[eM]){es(ey(void 0,!0));return}ei[eL](es,ef)},ef)}}var eN=Object.getPrototypeOf(function(){}),eS=Object.setPrototypeOf((ef(ed={get stream(){return this[eb]},next:function(){var et,ei=this,es=this[eV];if(null!==es)return Promise.reject(es);if(this[eM])return Promise.resolve(ey(void 0,!0));if(this[eb].destroyed)return new Promise(function(et,es){eu.nextTick(function(){ei[eV]?es(ei[eV]):et(ey(void 0,!0))})});var ef=this[eg];if(ef)et=new Promise(ew(ef,this));else{var ed=this[eb].read();if(null!==ed)return Promise.resolve(ey(ed,!1));et=new Promise(this[eL])}return this[eg]=et,et}},Symbol.asyncIterator,function(){return this}),ef(ed,"return",function(){var et=this;return new Promise(function(ei,es){et[eb].destroy(null,function(et){if(et){es(et);return}ei(ey(void 0,!0))})})}),ed),eN),eA=function(et){var ei,es=Object.create(eS,(ef(ei={},eb,{value:et,writable:!0}),ef(ei,eH,{value:null,writable:!0}),ef(ei,ez,{value:null,writable:!0}),ef(ei,eV,{value:null,writable:!0}),ef(ei,eM,{value:et._readableState.endEmitted,writable:!0}),ef(ei,eL,{value:function(et,ei){var ef=es[eb].read();ef?(es[eg]=null,es[eH]=null,es[ez]=null,et(ey(ef,!1))):(es[eH]=et,es[ez]=ei)},writable:!0}),ei));return es[eg]=null,em(et,function(et){if(et&&"ERR_STREAM_PREMATURE_CLOSE"!==et.code){var ei=es[ez];null!==ei&&(es[eg]=null,es[eH]=null,es[ez]=null,ei(et)),es[eV]=et;return}var ef=es[eH];null!==ef&&(es[eg]=null,es[eH]=null,es[ez]=null,ef(ey(void 0,!0))),es[eM]=!0}),et.on("readable",ex.bind(null,es)),es};et.exports=eA},379:function(et,ei,es){"use strict";function ef(et,ei){var es=Object.keys(et);if(Object.getOwnPropertySymbols){var ef=Object.getOwnPropertySymbols(et);ei&&(ef=ef.filter(function(ei){return Object.getOwnPropertyDescriptor(et,ei).enumerable})),es.push.apply(es,ef)}return es}function eu(et){for(var ei=1;ei0?this.tail.next=ei:this.head=ei,this.tail=ei,++this.length}},{key:"unshift",value:function(et){var ei={data:et,next:this.head};0===this.length&&(this.tail=ei),this.head=ei,++this.length}},{key:"shift",value:function(){if(0!==this.length){var et=this.head.data;return 1===this.length?this.head=this.tail=null:this.head=this.head.next,--this.length,et}}},{key:"clear",value:function(){this.head=this.tail=null,this.length=0}},{key:"join",value:function(et){if(0===this.length)return"";for(var ei=this.head,es=""+ei.data;ei=ei.next;)es+=et+ei.data;return es}},{key:"concat",value:function(et){if(0===this.length)return eV.alloc(0);for(var ei=eV.allocUnsafe(et>>>0),es=this.head,ef=0;es;)eL(es.data,ei,ef),ef+=es.data.length,es=es.next;return ei}},{key:"consume",value:function(et,ei){var es;return eteu.length?eu.length:et;if(ed===eu.length?ef+=eu:ef+=eu.slice(0,et),0==(et-=ed)){ed===eu.length?(++es,ei.next?this.head=ei.next:this.head=this.tail=null):(this.head=ei,ei.data=eu.slice(ed));break}++es}return this.length-=es,ef}},{key:"_getBuffer",value:function(et){var ei=eV.allocUnsafe(et),es=this.head,ef=1;for(es.data.copy(ei),et-=es.data.length;es=es.next;){var eu=es.data,ed=et>eu.length?eu.length:et;if(eu.copy(ei,ei.length-et,0,ed),0==(et-=ed)){ed===eu.length?(++ef,es.next?this.head=es.next:this.head=this.tail=null):(this.head=es,es.data=eu.slice(ed));break}++ef}return this.length-=ef,ei}},{key:eg,value:function(et,ei){return eM(this,eu({},ei,{depth:0,customInspect:!1}))}}]),et}()},25:function(et){"use strict";function ei(et,ei){var ed=this,eH=this._readableState&&this._readableState.destroyed,ez=this._writableState&&this._writableState.destroyed;return eH||ez?(ei?ei(et):et&&(this._writableState?this._writableState.errorEmitted||(this._writableState.errorEmitted=!0,eu.nextTick(em,this,et)):eu.nextTick(em,this,et)),this):(this._readableState&&(this._readableState.destroyed=!0),this._writableState&&(this._writableState.destroyed=!0),this._destroy(et||null,function(et){!ei&&et?ed._writableState?ed._writableState.errorEmitted?eu.nextTick(ef,ed):(ed._writableState.errorEmitted=!0,eu.nextTick(es,ed,et)):eu.nextTick(es,ed,et):ei?(eu.nextTick(ef,ed),ei(et)):eu.nextTick(ef,ed)}),this)}function es(et,ei){em(et,ei),ef(et)}function ef(et){(!et._writableState||et._writableState.emitClose)&&(!et._readableState||et._readableState.emitClose)&&et.emit("close")}function ed(){this._readableState&&(this._readableState.destroyed=!1,this._readableState.reading=!1,this._readableState.ended=!1,this._readableState.endEmitted=!1),this._writableState&&(this._writableState.destroyed=!1,this._writableState.ended=!1,this._writableState.ending=!1,this._writableState.finalCalled=!1,this._writableState.prefinished=!1,this._writableState.finished=!1,this._writableState.errorEmitted=!1)}function em(et,ei){et.emit("error",ei)}function eH(et,ei){var es=et._readableState,ef=et._writableState;es&&es.autoDestroy||ef&&ef.autoDestroy?et.destroy(ei):et.emit("error",ei)}et.exports={destroy:ei,undestroy:ed,errorOrDestroy:eH}},698:function(et,ei,es){"use strict";var ef=es(646).q.ERR_STREAM_PREMATURE_CLOSE;function eu(et){var ei=!1;return function(){if(!ei){ei=!0;for(var es=arguments.length,ef=Array(es),eu=0;eu0,function(ei){et||(et=ei),ei&&ed.forEach(eg),em||(ed.forEach(eg),eu(et))})});return es.reduce(eL)}et.exports=ey},776:function(et,ei,es){"use strict";var ef=es(646).q.ERR_INVALID_OPT_VALUE;function eu(et,ei,es){return null!=et.highWaterMark?et.highWaterMark:ei?et[es]:null}function ed(et,ei,es,ed){var em=eu(ei,ed,es);if(null!=em){if(!(isFinite(em)&&Math.floor(em)===em)||em<0){var eH=ed?es:"highWaterMark";throw new ef(eH,em)}return Math.floor(em)}return et.objectMode?16:16384}et.exports={getHighWaterMark:ed}},678:function(et,ei,es){et.exports=es(781)},55:function(et,ei,es){var ef=es(300),eu=ef.Buffer;function ed(et,ei){for(var es in et)ei[es]=et[es]}function em(et,ei,es){return eu(et,ei,es)}eu.from&&eu.alloc&&eu.allocUnsafe&&eu.allocUnsafeSlow?et.exports=ef:(ed(ef,ei),ei.Buffer=em),em.prototype=Object.create(eu.prototype),ed(eu,em),em.from=function(et,ei,es){if("number"==typeof et)throw TypeError("Argument must not be a number");return eu(et,ei,es)},em.alloc=function(et,ei,es){if("number"!=typeof et)throw TypeError("Argument must be a number");var ef=eu(et);return void 0!==ei?"string"==typeof es?ef.fill(ei,es):ef.fill(ei):ef.fill(0),ef},em.allocUnsafe=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return eu(et)},em.allocUnsafeSlow=function(et){if("number"!=typeof et)throw TypeError("Argument must be a number");return ef.SlowBuffer(et)}},173:function(et,ei,es){et.exports=eu;var ef=es(361).EventEmitter;function eu(){ef.call(this)}es(782)(eu,ef),eu.Readable=es(709),eu.Writable=es(337),eu.Duplex=es(403),eu.Transform=es(170),eu.PassThrough=es(889),eu.finished=es(698),eu.pipeline=es(442),eu.Stream=eu,eu.prototype.pipe=function(et,ei){var es=this;function eu(ei){et.writable&&!1===et.write(ei)&&es.pause&&es.pause()}function ed(){es.readable&&es.resume&&es.resume()}es.on("data",eu),et.on("drain",ed),et._isStdio||ei&&!1===ei.end||(es.on("end",eH),es.on("close",ez));var em=!1;function eH(){em||(em=!0,et.end())}function ez(){em||(em=!0,"function"==typeof et.destroy&&et.destroy())}function eV(et){if(eM(),0===ef.listenerCount(this,"error"))throw et}function eM(){es.removeListener("data",eu),et.removeListener("drain",ed),es.removeListener("end",eH),es.removeListener("close",ez),es.removeListener("error",eV),et.removeListener("error",eV),es.removeListener("end",eM),es.removeListener("close",eM),et.removeListener("close",eM)}return es.on("error",eV),et.on("error",eV),es.on("end",eM),es.on("close",eM),et.on("close",eM),et.emit("pipe",es),et}},704:function(et,ei,es){"use strict";var ef=es(55).Buffer,eu=ef.isEncoding||function(et){switch((et=""+et)&&et.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 ed(et){var ei;if(!et)return"utf8";for(;;)switch(et){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 et;default:if(ei)return;et=(""+et).toLowerCase(),ei=!0}}function em(et){var ei=ed(et);if("string"!=typeof ei&&(ef.isEncoding===eu||!eu(et)))throw Error("Unknown encoding: "+et);return ei||et}function eH(et){var ei;switch(this.encoding=em(et),this.encoding){case"utf16le":this.text=ey,this.end=eC,ei=4;break;case"utf8":this.fillLast=eg,ei=4;break;case"base64":this.text=ex,this.end=ew,ei=3;break;default:this.write=eN,this.end=eS;return}this.lastNeed=0,this.lastTotal=0,this.lastChar=ef.allocUnsafe(ei)}function ez(et){return et<=127?0:et>>5==6?2:et>>4==14?3:et>>3==30?4:et>>6==2?-1:-2}function eV(et,ei,es){var ef=ei.length-1;if(ef=0?(eu>0&&(et.lastNeed=eu-1),eu):--ef=0?(eu>0&&(et.lastNeed=eu-2),eu):--ef=0?(eu>0&&(2===eu?eu=0:et.lastNeed=eu-3),eu):0}function eM(et,ei,es){if((192&ei[0])!=128)return et.lastNeed=0,"�";if(et.lastNeed>1&&ei.length>1){if((192&ei[1])!=128)return et.lastNeed=1,"�";if(et.lastNeed>2&&ei.length>2&&(192&ei[2])!=128)return et.lastNeed=2,"�"}}function eg(et){var ei=this.lastTotal-this.lastNeed,es=eM(this,et,ei);return void 0!==es?es:this.lastNeed<=et.length?(et.copy(this.lastChar,ei,0,this.lastNeed),this.lastChar.toString(this.encoding,0,this.lastTotal)):void(et.copy(this.lastChar,ei,0,et.length),this.lastNeed-=et.length)}function eL(et,ei){var es=eV(this,et,ei);if(!this.lastNeed)return et.toString("utf8",ei);this.lastTotal=es;var ef=et.length-(es-this.lastNeed);return et.copy(this.lastChar,0,ef),et.toString("utf8",ei,ef)}function eb(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+"�":ei}function ey(et,ei){if((et.length-ei)%2==0){var es=et.toString("utf16le",ei);if(es){var ef=es.charCodeAt(es.length-1);if(ef>=55296&&ef<=56319)return this.lastNeed=2,this.lastTotal=4,this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1],es.slice(0,-1)}return es}return this.lastNeed=1,this.lastTotal=2,this.lastChar[0]=et[et.length-1],et.toString("utf16le",ei,et.length-1)}function eC(et){var ei=et&&et.length?this.write(et):"";if(this.lastNeed){var es=this.lastTotal-this.lastNeed;return ei+this.lastChar.toString("utf16le",0,es)}return ei}function ex(et,ei){var es=(et.length-ei)%3;return 0===es?et.toString("base64",ei):(this.lastNeed=3-es,this.lastTotal=3,1===es?this.lastChar[0]=et[et.length-1]:(this.lastChar[0]=et[et.length-2],this.lastChar[1]=et[et.length-1]),et.toString("base64",ei,et.length-es))}function ew(et){var ei=et&&et.length?this.write(et):"";return this.lastNeed?ei+this.lastChar.toString("base64",0,3-this.lastNeed):ei}function eN(et){return et.toString(this.encoding)}function eS(et){return et&&et.length?this.write(et):""}ei.s=eH,eH.prototype.write=function(et){var ei,es;if(0===et.length)return"";if(this.lastNeed){if(void 0===(ei=this.fillLast(et)))return"";es=this.lastNeed,this.lastNeed=0}else es=0;return es0&&!eu.call(et,0))for(var eb=0;eb0)for(var eC=0;eC=0&&"[object Function]"===ei.call(et.callee)),ef}},92703:function(et,ei,es){"use strict";var ef=es(50414);function eu(){}function ed(){}ed.resetWarningCache=eu,et.exports=function(){function et(et,ei,es,eu,ed,em){if(em!==ef){var eH=Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw eH.name="Invariant Violation",eH}}function ei(){return et}et.isRequired=et;var es={array:et,bigint:et,bool:et,func:et,number:et,object:et,string:et,symbol:et,any:et,arrayOf:ei,element:et,elementType:et,instanceOf:ei,node:et,objectOf:ei,oneOf:ei,oneOfType:ei,shape:ei,exact:ei,checkPropTypes:ed,resetWarningCache:eu};return es.PropTypes=es,es}},45697:function(et,ei,es){et.exports=es(92703)()},50414:function(et){"use strict";var ei="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED";et.exports=ei},61798:function(et,ei,es){"use strict";var ef=es(83454),eu=65536,ed=4294967295;function em(){throw Error("Secure random number generation is not supported by this browser.\nUse Chrome, Firefox or Internet Explorer 11")}var eH=es(89509).Buffer,ez=es.g.crypto||es.g.msCrypto;function eV(et,ei){if(et>ed)throw RangeError("requested too many random bytes");var es=eH.allocUnsafe(et);if(et>0){if(et>eu)for(var em=0;em

A domain should be linked to an existing resource. Try to create an instance or function first

\ No newline at end of file +

A domain should be linked to an existing resource. Try to create an instance or function first

\ No newline at end of file diff --git a/dashboard/function/index.html b/dashboard/function/index.html index 0ce8aca0..2d993317 100644 --- a/dashboard/function/index.html +++ b/dashboard/function/index.html @@ -1,4 +1,4 @@ -

01Code to execute

If your code has any dependencies, you can upload them separately in the volume section below to ensure a faster creation.

To get started, compress your code into a zip or squashfs (.sqsh) file and upload it here.

Language *
Define an entry point *
Upload your code *
Learn more

02Type of scheduling

Configure if this program should be running continuously, persistent, or only on-demand in response to a user request or an event.

03Select an instance size

Select the hardware resources allocated to your functions, ensuring optimal performance and efficient resource usage tailored to your specific needs.

Cores
Memory
Hold
1 x86 64bit2.00 GB200 ALEPH
2 x86 64bit4.00 GB400 ALEPH
4 x86 64bit8.00 GB800 ALEPH
6 x86 64bit12.00 GB1200 ALEPH
8 x86 64bit16.00 GB1600 ALEPH
12 x86 64bit24.00 GB2400 ALEPH

04Name and tags

Organize and identify your functions more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 functions.

Function name *
Tags

05Advanced Configuration Options

Customize your function with our Advanced Configuration Options. Add volumes, environment variables, and custom domains to meet your specific needs.

Runtime hash
Add volumes
Good news! Your selected package already includes 2.00 GB of storage at no additional cost. Feel free to add it here.
Learn more
Add environment variables

Define key-value pairs that act as configuration settings for your web3 function. Environment variables offer a convenient way to store information, manage configurations, and modify your application's behaviour without altering the source code.

Custom domain

Configure a user-friendly domain name for your web3 function, providing a more accessible and professional way for users to interact with your application.

Estimated holding requirements

This amount needs to be present in your wallet until the function is removed. Tokens won't be locked nor consumed. The function will be garbage collected once funds are removed from the wallet.

UNLOCKED
current wallet
0 ALEPH
FUNCTION
1x86-64bit.2GB-RAM
200.0 ALEPH
TYPE
on-demand
-
Total Staked
200.0 ALEPH
\ No newline at end of file +

01Code to execute

If your code has any dependencies, you can upload them separately in the volume section below to ensure a faster creation.

To get started, compress your code into a zip or squashfs (.sqsh) file and upload it here.

Language *
Define an entry point *
Upload your code *
Learn more

02Type of scheduling

Configure if this program should be running continuously, persistent, or only on-demand in response to a user request or an event.

03Select an instance size

Select the hardware resources allocated to your functions, ensuring optimal performance and efficient resource usage tailored to your specific needs.

Cores
Memory
Hold
1 x86 64bit2.00 GB200 ALEPH
2 x86 64bit4.00 GB400 ALEPH
4 x86 64bit8.00 GB800 ALEPH
6 x86 64bit12.00 GB1200 ALEPH
8 x86 64bit16.00 GB1600 ALEPH
12 x86 64bit24.00 GB2400 ALEPH

04Name and tags

Organize and identify your functions more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 functions.

Function name *
Tags

05Advanced Configuration Options

Customize your function with our Advanced Configuration Options. Add volumes, environment variables, and custom domains to meet your specific needs.

Runtime hash
Add volumes
Good news! Your selected package already includes 2.00 GB of storage at no additional cost. Feel free to add it here.
Learn more
Add environment variables

Define key-value pairs that act as configuration settings for your web3 function. Environment variables offer a convenient way to store information, manage configurations, and modify your application's behaviour without altering the source code.

Custom domain

Configure a user-friendly domain name for your web3 function, providing a more accessible and professional way for users to interact with your application.

Estimated holding requirements

This amount needs to be present in your wallet until the function is removed. Tokens won't be locked nor consumed. The function will be garbage collected once funds are removed from the wallet.

UNLOCKED
current wallet
0 ALEPH
FUNCTION
1x86-64bit.2GB-RAM
200.0 ALEPH
TYPE
on-demand
-
Total Staked
200.0 ALEPH
\ No newline at end of file diff --git a/dashboard/index.html b/dashboard/index.html index 18468038..e383cae1 100644 --- a/dashboard/index.html +++ b/dashboard/index.html @@ -1,4 +1,4 @@ -

Acquire aleph.im tokens for versatile access to resources within a defined duration. These tokens remain in your wallet without being locked or consumed, providing you with flexibility in utilizing aleph.im's infrastructure. If you choose to remove the tokens from your wallet, the allocated resources will be efficiently reclaimed. Feel free to use or hold the tokens according to your needs, even when not actively using Aleph.im's resources.

\ No newline at end of file +

Acquire aleph.im tokens for versatile access to resources within a defined duration. These tokens remain in your wallet without being locked or consumed, providing you with flexibility in utilizing aleph.im's infrastructure. If you choose to remove the tokens from your wallet, the allocated resources will be efficiently reclaimed. Feel free to use or hold the tokens according to your needs, even when not actively using Aleph.im's resources.

\ No newline at end of file diff --git a/dashboard/indexer/index.html b/dashboard/indexer/index.html index 62f9c57a..6817a351 100644 --- a/dashboard/indexer/index.html +++ b/dashboard/indexer/index.html @@ -1,4 +1,4 @@ -

01Define Your Blockchain Network

Specify the blockchain network where you aim to attach accounts. You can index unique accounts tailored to each environment. This flexible approach allows for nuanced tracking across multiple networks, whether on a main net or testnet. Please provide the necessary details including the network's ID, RPC URL, and blockchain type.

Network ID *
Blockchain *
ethereum
  • ethereum
  • bsc
  • RPC node url *
    Custom ABI url
    Incl. the placeholder $ADDRESS in the URL. The system will replace it with the token address you provide in step 02, autofilling the form.

    02Configure Your Token Account

    Define the core parameters associated with the token, like the contract address, deployer's details, and initial supply. This foundational data assists in bootstrapping the state of your token, guaranteeing precise and consistent tracking over time. Ensure you detail the blockchain type, token's contract address, deployer address, initial supply, and token decimal places.

    Network ID *
    Select network ID
  • Contract address *
    Deployer address *
    Initial token supply *
    Token decimals *

    03Name and tags

    Organize and identify your indexers more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 indexers.

    Indexer name *
    Tags

    Estimated holding requirements

    This amount needs to be present in your wallet until the indexer is removed. Tokens won't be locked nor consumed. The indexer will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    FUNCTION
    2x86-64bit.4GB-RAM
    4.0K ALEPH
    STORAGEPERSISTENT
    40.00 GB
    0 ALEPH
    TYPE
    persistent
    -
    Total Staked
    4.0K ALEPH
    \ No newline at end of file +data-styled.g218[id="cmp___StyledP3-sc-r8nm2v-5"]{content:"kcRKLx,"}/*!sc*/ +

    01Define Your Blockchain Network

    Specify the blockchain network where you aim to attach accounts. You can index unique accounts tailored to each environment. This flexible approach allows for nuanced tracking across multiple networks, whether on a main net or testnet. Please provide the necessary details including the network's ID, RPC URL, and blockchain type.

    Network ID *
    Blockchain *
    ethereum
  • ethereum
  • bsc
  • RPC node url *
    Custom ABI url
    Incl. the placeholder $ADDRESS in the URL. The system will replace it with the token address you provide in step 02, autofilling the form.

    02Configure Your Token Account

    Define the core parameters associated with the token, like the contract address, deployer's details, and initial supply. This foundational data assists in bootstrapping the state of your token, guaranteeing precise and consistent tracking over time. Ensure you detail the blockchain type, token's contract address, deployer address, initial supply, and token decimal places.

    Network ID *
    Select network ID
  • Contract address *
    Deployer address *
    Initial token supply *
    Token decimals *

    03Name and tags

    Organize and identify your indexers more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 indexers.

    Indexer name *
    Tags

    Estimated holding requirements

    This amount needs to be present in your wallet until the indexer is removed. Tokens won't be locked nor consumed. The indexer will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    FUNCTION
    2x86-64bit.4GB-RAM
    4.0K ALEPH
    STORAGEPERSISTENT
    40.00 GB
    0 ALEPH
    TYPE
    persistent
    -
    Total Staked
    4.0K ALEPH
    \ No newline at end of file diff --git a/dashboard/instance/index.html b/dashboard/instance/index.html index a8cee8c2..89525277 100644 --- a/dashboard/instance/index.html +++ b/dashboard/instance/index.html @@ -1,4 +1,4 @@ -

    01Choose an image

    Chose a base image for your VM. It’s the base system that you will be able to customize.

    Debian 11 “Bullseye” image image logoDebian 11 “Bullseye”
    Debian 12 “Bookworm” image image logoDebian 12 “Bookworm”
    Ubuntu 22.04 LTS image image logoUbuntu 22.04 LTS

    02Select an instance size

    Please select one of the available instance size as a base for your VM. You will be able to customize the volumes later.

    Cores
    Memory
    Storage
    Hold
    1 x86 64bit2.00 GB20.00 GB2000 ALEPH
    2 x86 64bit4.00 GB40.00 GB4000 ALEPH
    4 x86 64bit8.00 GB80.00 GB8000 ALEPH
    6 x86 64bit12.00 GB120.00 GB12000 ALEPH
    8 x86 64bit16.00 GB160.00 GB16000 ALEPH
    12 x86 64bit24.00 GB240.00 GB24000 ALEPH

    03Name and tags

    Organize and identify your instances more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 instances.

    Instance name *
    Tags

    04Advanced Configuration Options

    Customize your instance with our Advanced Configuration Options. Add volumes, SSH keys, environment variables, and custom domains to meet your specific needs.

    Add volumes

    This system volume is included with your setup. You can easily expand your storage capacity to meet your application's requirements by adding additional volumes below.

    Volume name *
    Mount *
    Size (GB) *
    Learn more
    Add environment variables

    Define key-value pairs that act as configuration settings for your web3 instance. Environment variables offer a convenient way to store information, manage configurations, and modify your application's behaviour without altering the source code.

    Configure SSH Key

    Access your cloud instances securely. Give existing key’s below access to this instance or add new keys. Remember, storing private keys safely is crucial for security. If you need help, our support team is always ready to assist.

    Custom domain

    You have the ability to configure a domain name to access your cloud instances. By setting up a user-friendly custom domain, accessing your instances becomes easier and more intuitive. It&s another way we&re making web3 cloud management as straightforward as possible.

    Estimated holding requirements

    This amount needs to be present in your wallet until the instance is removed. Tokens won't be locked nor consumed. The instance will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    INSTANCE
    1x86-64bit.2GB-RAM.20GB-HDD
    2.0K ALEPH
    Total Staked
    2.0K ALEPH
    \ No newline at end of file +data-styled.g285[id="cmp___StyledP5-sc-a5vd7w-17"]{content:"hxKdzb,"}/*!sc*/ +

    01Choose an image

    Chose a base image for your VM. It’s the base system that you will be able to customize.

    Debian 11 “Bullseye” image image logoDebian 11 “Bullseye”
    Debian 12 “Bookworm” image image logoDebian 12 “Bookworm”
    Ubuntu 22.04 LTS image image logoUbuntu 22.04 LTS

    02Select an instance size

    Please select one of the available instance size as a base for your VM. You will be able to customize the volumes later.

    Cores
    Memory
    Storage
    Hold
    1 x86 64bit2.00 GB20.00 GB2000 ALEPH
    2 x86 64bit4.00 GB40.00 GB4000 ALEPH
    4 x86 64bit8.00 GB80.00 GB8000 ALEPH
    6 x86 64bit12.00 GB120.00 GB12000 ALEPH
    8 x86 64bit16.00 GB160.00 GB16000 ALEPH
    12 x86 64bit24.00 GB240.00 GB24000 ALEPH

    03Name and tags

    Organize and identify your instances more effectively by assigning a unique name, obtaining a hash reference, and defining multiple tags. This helps streamline your development process and makes it easier to manage your web3 instances.

    Instance name *
    Tags

    04Advanced Configuration Options

    Customize your instance with our Advanced Configuration Options. Add volumes, SSH keys, environment variables, and custom domains to meet your specific needs.

    Add volumes

    This system volume is included with your setup. You can easily expand your storage capacity to meet your application's requirements by adding additional volumes below.

    Volume name *
    Mount *
    Size (GB) *
    Learn more
    Add environment variables

    Define key-value pairs that act as configuration settings for your web3 instance. Environment variables offer a convenient way to store information, manage configurations, and modify your application's behaviour without altering the source code.

    Configure SSH Key

    Access your cloud instances securely. Give existing key’s below access to this instance or add new keys. Remember, storing private keys safely is crucial for security. If you need help, our support team is always ready to assist.

    Custom domain

    You have the ability to configure a domain name to access your cloud instances. By setting up a user-friendly custom domain, accessing your instances becomes easier and more intuitive. It&s another way we&re making web3 cloud management as straightforward as possible.

    Estimated holding requirements

    This amount needs to be present in your wallet until the instance is removed. Tokens won't be locked nor consumed. The instance will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    INSTANCE
    1x86-64bit.2GB-RAM.20GB-HDD
    2.0K ALEPH
    Total Staked
    2.0K ALEPH
    \ No newline at end of file diff --git a/dashboard/manage/index.html b/dashboard/manage/index.html index 9332cd29..07fa2d70 100644 --- a/dashboard/manage/index.html +++ b/dashboard/manage/index.html @@ -1,4 +1,4 @@ - \ No newline at end of file +data-styled.g406[id="cmp___StyledNoisyContainer-sc-u79f6i-0"]{content:"gXbaSo,"}/*!sc*/ + \ No newline at end of file diff --git a/dashboard/ssh/index.html b/dashboard/ssh/index.html index 90075cc6..94d9b35d 100644 --- a/dashboard/ssh/index.html +++ b/dashboard/ssh/index.html @@ -1,4 +1,4 @@ -

    01Configure SSH Key

    Access your cloud instances securely. Give existing key’s below access to this instance or add new keys. Remember, storing private keys safely is crucial for security. If you need help, our support team is always ready to assist.

    SSH Public Key *
    Label
    \ No newline at end of file +data-styled.g155[id="cmp___StyledDiv2-sc-16fsdtu-4"]{content:"bYUixU,"}/*!sc*/ +

    01Configure SSH Key

    Access your cloud instances securely. Give existing key’s below access to this instance or add new keys. Remember, storing private keys safely is crucial for security. If you need help, our support team is always ready to assist.

    SSH Public Key *
    Label
    \ No newline at end of file diff --git a/dashboard/volume/index.html b/dashboard/volume/index.html index f892fff4..b1c0618b 100644 --- a/dashboard/volume/index.html +++ b/dashboard/volume/index.html @@ -1,4 +1,4 @@ -

    01Add volume

    Create and configure new volumes for your web3 function by either uploading a dependency file or a squashfs volume. Volumes play a crucial role in managing dependencies and providing a volume within your application.

    Estimated holding requirements

    This amount needs to be present in your wallet until the volume is removed. Tokens won 't be locked nor consumed. The volume will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    STORAGEVOLUME
    -
    0 ALEPH
    Total Staked
    0 ALEPH
    \ No newline at end of file +data-styled.g407[id="cmp___StyledSection-sc-1jshimy-0"]{content:"iZTXZy,"}/*!sc*/ +

    01Add volume

    Create and configure new volumes for your web3 function by either uploading a dependency file or a squashfs volume. Volumes play a crucial role in managing dependencies and providing a volume within your application.

    Estimated holding requirements

    This amount needs to be present in your wallet until the volume is removed. Tokens won 't be locked nor consumed. The volume will be garbage collected once funds are removed from the wallet.

    UNLOCKED
    current wallet
    0 ALEPH
    STORAGEVOLUME
    -
    0 ALEPH
    Total Staked
    0 ALEPH
    \ No newline at end of file diff --git a/index.html b/index.html index 7ff8c0a0..cfb2ab37 100644 --- a/index.html +++ b/index.html @@ -1,4 +1,4 @@ -Aleph.im | Cloud Solutions

    Infrastructure solutions

    Aleph.im offers cutting-edge computing and storage solutions for your web3 needs. Our unique payment model supports the holder tier, allowing you to use our services simply by holding ALEPH tokens in your wallet. The longer you hold the tokens, the longer you can enjoy our services without any additional payment. Discover the power of Aleph.im’s solutions today and experience cost-effective and reliable web3 cloud services like never before.

    ComputingSolutions

    With Aleph.im's computing services, you can process data quickly and securely using on-demand and persistent functions, virtual machine instances, and confidential VMs.

    Function

    An isolated environment created for a function to execute in response to an event and can run in two modes: on-demand or persistent.

    Instance

    A virtual machine that runs on a Aleph.im's infrastructure and can be configured with CPUs, memory, storage, and networking.

    Confidential VM

    A virtual machine running for an extended period with their memory, storage, and execution fully encrypted and isolated from the host.

    Indexing illustration
    SOLANA - ETHEREUM - BINANCE SMART CHAIN

    Indexing framework

    Consider using the Aleph Indexer Framework for indexing blockchain data. It's open-source, multi-chain, and provides an easy-to-use solution for building high-performance, decentralized indexers on Aleph.im's infrastructure.

    StorageSolutions

    With support for immutable, temporary, and persistent volumes, as well as databases using key-value pairs, Aleph.im provides a flexible and powerful storage solution for a wide range of use cases.

    Immutable volume

    Immutable volumes store unchangeable data on IPFS, pinned to multiple nodes for reliable access and reproducible execution.

    Dependencies volume

    Package your dependencies to an immutable volume upfront to reference it easily and speed up creation time of an instance or function.

    IPFS pinning

    Avoid data being removed or garbage collected using the decentralized pinning solution, and ensure your data stay persistent.

    Temporarily volume

    A volume that is created temporarily to hold data or files for a short period of time. After this time the volume is deleted.

    \ No newline at end of file +data-styled.g186[id="cmp___StyledTextGradient2-sc-1g24l22-22"]{content:"iEAAHb,"}/*!sc*/ +

    Infrastructure solutions

    Aleph.im offers cutting-edge computing and storage solutions for your web3 needs. Our unique payment model supports the holder tier, allowing you to use our services simply by holding ALEPH tokens in your wallet. The longer you hold the tokens, the longer you can enjoy our services without any additional payment. Discover the power of Aleph.im’s solutions today and experience cost-effective and reliable web3 cloud services like never before.

    ComputingSolutions

    With Aleph.im's computing services, you can process data quickly and securely using on-demand and persistent functions, virtual machine instances, and confidential VMs.

    Function

    An isolated environment created for a function to execute in response to an event and can run in two modes: on-demand or persistent.

    Instance

    A virtual machine that runs on a Aleph.im's infrastructure and can be configured with CPUs, memory, storage, and networking.

    Confidential VM

    A virtual machine running for an extended period with their memory, storage, and execution fully encrypted and isolated from the host.

    Indexing illustration
    SOLANA - ETHEREUM - BINANCE SMART CHAIN

    Indexing framework

    Consider using the Aleph Indexer Framework for indexing blockchain data. It's open-source, multi-chain, and provides an easy-to-use solution for building high-performance, decentralized indexers on Aleph.im's infrastructure.

    StorageSolutions

    With support for immutable, temporary, and persistent volumes, as well as databases using key-value pairs, Aleph.im provides a flexible and powerful storage solution for a wide range of use cases.

    Immutable volume

    Immutable volumes store unchangeable data on IPFS, pinned to multiple nodes for reliable access and reproducible execution.

    Dependencies volume

    Package your dependencies to an immutable volume upfront to reference it easily and speed up creation time of an instance or function.

    IPFS pinning

    Avoid data being removed or garbage collected using the decentralized pinning solution, and ensure your data stay persistent.

    Temporarily volume

    A volume that is created temporarily to hold data or files for a short period of time. After this time the volume is deleted.

    \ No newline at end of file